/* ================= GOOGLE FONTS IMPORT ================= */
/* Cormorant Garamond: Elegant Calligraphy | Inter: Clean Sans | Fira Code: Crisp Data */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,600;0,700;1,400;1,600&family=Fira+Code:wght@400;500&family=Inter:wght@300;400;500;600&display=swap');

/* ================= OVERLAYS (Login & Subscription) ================= */
.login-overlay, .sub-overlay {
    position: fixed; 
    top: 0; 
    left: 0; 
    right: 0; 
    bottom: 0;
    display: flex; 
    z-index: 9999;
    background-color: rgba(19, 19, 20, 0.95); /* Gemini App Background */
    backdrop-filter: blur(8px);
    transition: transform 0.6s cubic-bezier(0.77, 0, 0.175, 1), opacity 0.4s;
}

.sub-overlay {
    background-color: rgba(19, 19, 20, 0.9);
}

.hidden { 
    transform: translateY(-100%); 
    opacity: 0; 
    pointer-events: none; 
}

/* --- Login Left Side: Branding --- */
.login-brand {
    flex: 6; 
    background: linear-gradient(to right, rgba(19, 19, 20, 0.95) 20%, rgba(30, 31, 32, 0.85)), url('bg.jpg') center/cover no-repeat;
    background-color: #131314; 
    display: flex; 
    flex-direction: column; 
    justify-content: space-between;
    align-items: center; /* Centered */
    text-align: center; /* Centered */
    padding: 60px 80px; 
    color: #FFFFFF;
    border-right: 1px solid #444746; /* Neutral Grey Frame */
}

.brand-title { 
    font-size: 56px; 
    font-weight: 700; 
    margin-bottom: 10px; 
    color: #E3E3E3; /* Pale Grey */
    letter-spacing: 1px;
    font-family: 'Cormorant Garamond', serif;
}

.brand-subtitle { 
    font-size: 26px; 
    margin-bottom: 40px; 
    color: #C4C7C5; 
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
}

.brand-text { 
    font-size: 16px; 
    line-height: 1.8; 
    color: #8E918F; 
    max-width: 85%; 
    margin-bottom: 20px; 
    font-family: 'Inter', sans-serif;
    font-weight: 300;
}

.brand-divider { 
    width: 60px; 
    height: 1px; 
    background-color: #444746; 
    margin: 30px auto; /* Centered */
}

.brand-subheading { 
    font-size: 22px; 
    color: #FFFFFF; 
    margin-bottom: 10px; 
    font-family: 'Cormorant Garamond', serif;
}

.brand-footer { 
    font-size: 20px; 
    font-style: italic; 
    color: #E3E3E3; 
    font-weight: 600; 
    font-family: 'Cormorant Garamond', serif;
}

/* --- Login Right Side: Form --- */
.login-form-container {
    flex: 4; 
    background-color: #1E1F20; /* Surface Grey */
    display: flex; 
    align-items: center; 
    justify-content: center;
    text-align: center; /* Centered */
    padding: 40px; 
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.4); 
}

.form-wrapper { 
    width: 100%; 
    max-width: 400px; 
    margin: 0 auto;
}

.form-wrapper h2 { 
    font-size: 36px; 
    margin-bottom: 5px; 
    color: #FFFFFF; 
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
}

.form-subtitle { 
    color: #8E918F; 
    margin-bottom: 30px; 
    font-size: 14px; 
    font-family: 'Inter', sans-serif;
}

.input-group { 
    margin-bottom: 20px; 
    text-align: center; /* Centered */
}

.input-group label { 
    display: block; 
    margin-bottom: 8px; 
    color: #C4C7C5; 
    font-size: 12px; 
    font-weight: 600; 
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.input-group input, .input-group select, .input-group textarea {
    width: 100%; 
    padding: 14px 15px; 
    background-color: #282A2C; /* Text Field Grey */
    border: 1px solid #444746;
    color: #FFFFFF; 
    border-radius: 4px; 
    box-sizing: border-box; 
    font-size: 14px; 
    font-family: 'Fira Code', monospace;
    transition: all 0.3s ease;
    text-align: center; /* Centered */
}

.input-group input:focus, .input-group select:focus, .input-group textarea:focus { 
    outline: none; 
    border-color: #E3E3E3; 
    background-color: #1E1F20;
    box-shadow: 0 5px 15px rgba(227, 227, 227, 0.1); /* White/Grey Glow */
}

.form-actions {
    display: flex;
    justify-content: center; /* Centered */
    align-items: center;
    margin-bottom: 30px;
    font-family: 'Inter', sans-serif;
}

.remember-me {
    color: #8E918F;
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 13px;
}

.remember-me input {
    margin-right: 8px;
    cursor: pointer;
    accent-color: #E3E3E3;
}

.forgot-link {
    color: #E3E3E3;
    text-decoration: none;
    font-size: 13px;
    transition: color 0.2s;
}
.forgot-link:hover { color: #FFFFFF; }

.primary-btn {
    width: 100%; 
    padding: 14px; 
    background-color: #E3E3E3; 
    color: #131314; 
    border: none;
    border-radius: 4px;
    font-size: 13px; 
    font-weight: 600; 
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: pointer;
    box-shadow: 0 8px 20px -5px rgba(0, 0, 0, 0.4); 
    transition: all 0.3s ease;
}

.primary-btn:hover { 
    background-color: #FFFFFF; 
    transform: translateY(-2px) scale(1.05); /* Added scaling */
    box-shadow: 0 12px 25px -5px rgba(0, 0, 0, 0.5);
}

.primary-btn:active { 
    transform: translateY(1px) scale(0.98);
    box-shadow: 0 4px 10px -5px rgba(0, 0, 0, 0.4);
}

.primary-btn:disabled { 
    background-color: #444746;
    color: #8E918F;
    box-shadow: none;
    cursor: not-allowed; 
    transform: none;
}

.register-prompt { 
    margin-top: 25px; 
    text-align: center; 
    color: #8E918F; 
    font-size: 13px; 
    font-family: 'Inter', sans-serif;
}

.register-prompt a { 
    color: #E3E3E3; 
    text-decoration: none; 
    font-weight: 600; 
}

/* ================= SUBSCRIPTION PAYWALL ================= */
.sub-overlay { 
    justify-content: center; 
    align-items: center; 
    z-index: 9998; 
}

.sub-container {
    background-color: #1E1F20; 
    padding: 50px; 
    border: 1px solid #444746;
    border-radius: 8px;
    width: 80%; 
    max-width: 900px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.6); 
    text-align: center; 
    position: relative;
}

.close-sub-btn { 
    position: absolute; 
    top: 20px; 
    right: 20px; 
    background: none; 
    border: none;
    color: #8E918F; 
    font-size: 24px; 
    cursor: pointer; 
    transition: color 0.2s;
}
.close-sub-btn:hover { color: #FFFFFF; transform: scale(1.1); }

.sub-title { 
    font-size: 42px; 
    color: #FFFFFF; 
    margin-bottom: 10px; 
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
}

.sub-subtitle { 
    color: #8E918F; 
    font-size: 16px; 
    margin-bottom: 40px; 
    font-family: 'Inter', sans-serif;
}

.pricing-cards { 
    display: flex; 
    gap: 20px; 
    justify-content: center; 
    flex-wrap: wrap; 
}

.price-card {
    background-color: #282A2C; 
    border: 1px solid #444746; 
    border-radius: 6px;
    padding: 35px 25px;
    flex: 0 1 280px; 
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    position: relative;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5); 
    transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}

.price-card:hover { 
    transform: translateY(-5px) scale(1.05); /* Added scaling */
    border-color: #E3E3E3;
    box-shadow: 0 15px 35px -10px rgba(227, 227, 227, 0.1);
}

.price-card h3 { 
    color: #FFFFFF; 
    font-size: 22px; 
    margin-bottom: 15px; 
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
    text-align: center;
}

.price-card .price { 
    font-size: 38px; 
    color: #E3E3E3; 
    font-weight: 400; 
    margin-bottom: 20px; 
    font-family: 'Cormorant Garamond', serif;
    text-align: center;
}

.price-card .price span { 
    font-size: 16px; 
    color: #8E918F; 
    font-family: 'Inter', sans-serif;
}

.price-card .features { 
    list-style: none; 
    padding: 0; 
    margin: 0 0 30px 0; 
    text-align: center; /* Centered */
    color: #C4C7C5; 
    font-size: 14px; 
    width: 100%; 
    font-family: 'Inter', sans-serif;
}

.price-card .features li { 
    margin-bottom: 12px; 
    border-bottom: 1px solid #1E1F20;
    padding-bottom: 8px;
}

.popular { 
    border: 1px solid #E3E3E3; 
    transform: scale(1.05); 
    z-index: 2; 
    box-shadow: 0 15px 40px -10px rgba(227, 227, 227, 0.1);
}

.popular:hover { 
    transform: scale(1.1) translateY(-5px); /* Adjusted scaling */
}

.popular-badge {
    position: absolute; 
    top: -12px; 
    background-color: #E3E3E3; 
    color: #131314; 
    font-size: 10px; 
    font-weight: 600; 
    padding: 4px 12px; 
    border-radius: 20px;
    letter-spacing: 1px;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
}

.select-tier-btn {
    width: 100%; 
    padding: 12px; 
    background-color: transparent; 
    color: #E3E3E3; 
    border: 1px solid #5F6368; 
    border-radius: 4px;
    cursor: pointer; 
    font-weight: 600; 
    font-size: 13px;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: auto;
    transition: all 0.3s ease;
}

.select-tier-btn:hover, .popular .select-tier-btn { 
    background-color: #E3E3E3; 
    color: #131314;
    box-shadow: 0 8px 20px -5px rgba(227, 227, 227, 0.2);
    transform: scale(1.05);
}

.provisioning-box { 
    background-color: #282A2C; 
    border: 1px solid #444746; 
    padding: 35px; 
    border-radius: 6px;
    max-width: 500px; 
    margin: 0 auto; 
    text-align: center; /* Centered */
    box-shadow: 0 15px 35px -10px rgba(0, 0, 0, 0.5);
}

.provisioning-box h3 { 
    color: #FFFFFF; 
    margin-bottom: 25px; 
    text-align: center;
    font-family: 'Cormorant Garamond', serif;
    font-size: 26px;
}

.promo-section { 
    display: flex; 
    justify-content: center; /* Centered */
    gap: 10px; 
    margin-bottom: 10px; 
}

.promo-section input { 
    flex: 1; 
    padding: 12px; 
    background-color: #1E1F20; 
    border: 1px solid #444746; 
    border-radius: 4px;
    color: #FFFFFF; 
    font-family: 'Fira Code', monospace;
    font-size: 13px;
    text-align: center; /* Centered */
}

.promo-section button { 
    padding: 10px 20px; 
    background-color: #444746; 
    color: #FFFFFF; 
    border: none; 
    border-radius: 4px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: background 0.2s, transform 0.3s;
}

.promo-section button:hover {
    background-color: #E3E3E3;
    color: #131314;
    transform: scale(1.05);
}

.promo-msg { 
    font-size: 13px; 
    color: #10B981; 
    margin-bottom: 20px; 
    text-align: center; 
    font-family: 'Inter', sans-serif;
}

.checkout-btn { 
    background-color: #10B981; 
    color: #FFFFFF; 
    box-shadow: 0 8px 20px -5px rgba(16, 185, 129, 0.3);
}
.checkout-btn:hover {
    background-color: #059669;
    transform: scale(1.05);
}

/* ================= DASHBOARD LAYOUT ================= */
body {
    font-family: 'Inter', sans-serif; 
    margin: 0;
    padding: 0;
    background-color: #131314; /* Deep Canvas */
    color: #FFFFFF; /* White Ink */
    height: 100vh;
    overflow: hidden; 
}

h1, h2, h3, h4 {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 600;
    text-align: center; /* Centered Everything */
}

.dashboard-wrapper {
    display: flex;
    height: 100vh;
    width: 100vw;
}

/* SIDEBAR STYLES */
.sidebar {
    width: 270px;
    background-color: #1E1F20; 
    display: flex;
    flex-direction: column;
    border-right: 1px solid #444746;
    overflow-y: auto;
    z-index: 10;
    box-shadow: 4px 0 20px rgba(0,0,0,0.2);
}

.sidebar-header {
    padding: 30px 20px;
    background-color: #1E1F20; 
    border-bottom: 1px solid #444746;
    text-align: center;
}

.sidebar-header h2 {
    margin: 0;
    font-size: 22px;
    color: #FFFFFF;
    font-weight: 700;
    letter-spacing: 1px;
}

.sidebar-menu {
    list-style: none;
    padding: 20px 0;
    margin: 0;
}

.sidebar-menu li {
    border-bottom: none;
}

/* Tier 1 Links & Parents */
.nav-link, .nav-parent {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 25px;
    color: #C4C7C5;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    border-left: 3px solid transparent;
    transition: all 0.3s ease;
}

.nav-link:hover, .nav-parent:hover {
    color: #FFFFFF;
    background-color: #282A2C;
}

.nav-link.active {
    background: linear-gradient(90deg, rgba(227,227,227,0.1) 0%, rgba(255,255,255,0) 100%);
    color: #E3E3E3;
    border-left: 3px solid #E3E3E3;
}

.nav-parent.expanded {
    color: #E3E3E3;
}

.chevron {
    font-size: 10px;
    transition: transform 0.3s ease;
}

.nav-parent.expanded .chevron {
    transform: rotate(180deg);
}

/* Tier 1 Sub-menu */
.sub-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    background-color: transparent;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-in-out;
}

.sub-menu.open {
    max-height: 1500px; 
}

.sub-menu .nav-link {
    padding: 10px 20px 10px 45px; 
    font-size: 12px;
    color: #8E918F;
    border-left: 3px solid transparent;
    text-transform: none; 
    letter-spacing: 0.5px;
}

.sub-menu .nav-link:hover {
    color: #FFFFFF;
}

.sub-menu .nav-link.active {
    color: #E3E3E3;
    background-color: transparent;
    border-left: 3px solid #E3E3E3;
}

/* Tier 2 Links & Parents */
.nav-parent-tier2 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px 10px 45px; 
    color: #8E918F;
    text-decoration: none;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    border-left: 3px solid transparent;
    transition: all 0.3s ease;
}

.nav-parent-tier2:hover {
    color: #FFFFFF;
}

.nav-parent-tier2.expanded {
    color: #E3E3E3;
}

.chevron-tier2 {
    font-size: 8px;
    transition: transform 0.3s ease;
}

.nav-parent-tier2.expanded .chevron-tier2 {
    transform: rotate(180deg);
}

/* Tier 2 Sub-menu */
.sub-menu-tier2 {
    list-style: none;
    padding: 0;
    margin: 0;
    background-color: transparent; 
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    border-left: 1px solid #444746;
    margin-left: 45px;
}

.sub-menu-tier2.open {
    max-height: 500px; 
}

.sub-menu-tier2 .nav-link {
    padding: 8px 20px 8px 20px;
    font-size: 12px;
    color: #8E918F;
}

.sub-menu-tier2 .nav-link:hover {
    color: #FFFFFF;
}

.sub-menu-tier2 .nav-link.active {
    background-color: transparent;
    border-left: none;
    color: #E3E3E3;
}


/* MAIN CONTENT AREA - Strict Boundary */
.main-content {
    flex: 1;
    overflow-y: auto;
    padding: 40px 50px;
    background-color: transparent;
}

.content-section {
    display: none;
    width: 100%; /* Ensure full use up to max-width */
    animation: fadeIn 0.4s ease-in-out;
}

.content-section.active {
    display: block;
}

/* Inner Tabs (Set & Command vs Status & Stats) */
.inner-tab-content {
    display: none;
    animation: fadeIn 0.4s ease-in-out;
}
.inner-tab-content.active {
    display: block;
}

/* CP Section Card for specific control panel blocks */
.cp-section-card {
    background-color: #1E1F20; 
    border: 1px solid #444746; 
    border-radius: 6px; 
    padding: 25px;
    margin: 0 auto 15px auto !important; /* Tighter margins between cards */
    max-width: 1000px; 
    width: 100%; 
    box-sizing: border-box;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Helper for sections to center content and control spacing */
.section {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 100%;
    margin-bottom: 10px; /* Super tight vertical spacing */
}

.section h3 {
    margin: 0 0 15px 0; /* Tighter header spacing */
}

/* ================= EXISTING CONTROL PANEL STYLES ================= */

/* SUB-TABS NAVIGATION */
.sub-tabs {
    display: flex;
    justify-content: center; /* Centered */
    margin: 0 auto 20px auto; /* Tighter centered margin */
    border-bottom: 1px solid #444746;
    max-width: 1000px; /* Locked to Feed Width */
    width: 100%;
}

.sub-tab-btn {
    background: transparent;
    border: none;
    color: #8E918F;
    padding: 12px 24px;
    cursor: pointer;
    font-size: 16px;
    font-family: 'Cormorant Garamond', serif;
    margin: 0 7.5px; /* Symmetrical margin for centering */
    font-weight: 600;
    transition: all 0.3s ease;
    width: max-content; 
    border-bottom: 2px solid transparent;
}

.sub-tab-btn:hover {
    color: #FFFFFF;
    transform: scale(1.05); /* Added scaling */
}

.sub-tab-btn.active {
    color: #E3E3E3;
    border-bottom: 2px solid #E3E3E3;
}

.sub-tab-content { display: none; }
.sub-tab-content.active { display: block; animation: fadeIn 0.4s ease-in-out; }

/* Leader indicator */
.ea-leader {
    margin: 0;
    padding: 8px 15px;
    background: #1E1F20;
    border: 1px solid #444746;
    border-radius: 4px;
    color: #C4C7C5;
    font-size: 13px;
    font-family: 'Fira Code', monospace;
    width: max-content; 
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    text-align: center;
}

/* DROPDOWNS & GRIDS - Trimmed Dimensions */
.symbol-dropdowns-row {
    display: flex;
    justify-content: center; /* Centered */
    flex-wrap: wrap; 
    gap: 15px;
    margin-bottom: 10px; /* Tighter spacing */
    align-items: center; /* Centered */
}

.dropdown {
    position: relative;
    flex: 0 1 auto; 
    width: max-content; 
    margin-bottom: 10px;
}

.dropdown-header {
    background-color: #1E1F20;
    padding: 10px 16px;
    border: 1px solid #444746;
    cursor: pointer;
    border-radius: 4px;
    user-select: none;
    color: #FFFFFF;
    font-size: 13px;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2); 
    width: max-content; 
    transition: all 0.3s ease;
    text-align: center;
}
.dropdown-header:hover {
    border-color: #E3E3E3;
    transform: scale(1.05); /* Expand on hover */
}

/* Dropdowns specifically excluded from centering content per request */
.dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #1E1F20;
    border: 1px solid #444746;
    width: max-content; 
    min-width: 100%; 
    max-height: 240px;
    overflow-y: auto;
    z-index: 200;
    box-shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.5); 
    border-radius: 4px;
    margin-top: 5px;
    text-align: left; /* Keep dropdowns left-aligned */
}

.dropdown-content.active { display: block; animation: fadeIn 0.2s ease; }

.ea-item {
    padding: 10px 16px;
    border-bottom: 1px solid #282A2C;
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer; 
    color: #C4C7C5;
    font-family: 'Fira Code', monospace;
    font-size: 13px;
    white-space: nowrap; 
    transition: background 0.2s;
}

.ea-item:hover { 
    background-color: #282A2C; 
    color: #E3E3E3;
}

.ea-item input[type="checkbox"] {
    cursor: pointer;
    margin: 0;
    accent-color: #E3E3E3;
}

.ea-item span {
    flex-grow: 1; 
}

/* FAVORITES BOX - Fixed Width Standard & Bounded */
.favorites-box {
    background-color: #1E1F20;
    border: 1px dashed #5F6368;
    padding: 15px; /* Tighter padding */
    min-height: 40px; /* Reduced empty height */
    width: 100%; /* Force fill up to max-width */
    max-width: 1000px; 
    border-radius: 6px;
    display: flex;
    flex-wrap: wrap; 
    justify-content: center; /* Centered Items */
    align-items: center;
    gap: 10px;
    margin: 0 auto 10px auto; /* Tighter margins */
    box-shadow: inset 0 2px 10px rgba(0,0,0,0.2);
    box-sizing: border-box; /* Strict bounding */
}

.favorite-btn {
    background-color: #282A2C;
    color: #C4C7C5;
    border: 1px solid #444746;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-family: 'Fira Code', monospace;
    font-size: 12px;
    transition: all 0.3s ease;
    width: max-content; 
    margin: 0; /* Reset margins inside flex box */
}

.favorite-btn.active { 
    background-color: #E3E3E3; 
    color: #131314;
    border-color: #E3E3E3;
    box-shadow: 0 4px 10px rgba(227, 227, 227, 0.2);
}

.favorite-btn:hover {
    transform: scale(1.05) translateY(-2px); /* Stand out */
}

.placeholder {
    color: #8E918F;
    margin: 0;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    width: 100%;
    text-align: center;
    word-break: break-word; /* Prevent overflow */
    white-space: normal; /* Allow text wrapping */
}

/* NEW: Master EA Button Style for Selected Text */
.selected-row {
    display: flex;
    flex-direction: row; /* Side-by-Side inline */
    align-items: center; /* Centered */
    justify-content: center;
    text-align: center;
    margin: 0 auto 15px auto; /* Tighter margin */
    gap: 15px; /* Spacing between label and button */
}

.selected-row strong {
    font-size: 16px; /* Increased Size */
    color: #C4C7C5;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Inter', sans-serif;
}

.selected-text {
    background: #E3E3E3; /* Master Button Look */
    color: #131314;
    padding: 10px 25px; /* Button style padding */
    border-radius: 4px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 1px;
    display: inline-block;
    margin: 0;
    box-shadow: 0 8px 20px -5px rgba(227, 227, 227, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.selected-text:hover {
    transform: scale(1.05) translateY(-2px);
    box-shadow: 0 12px 25px -5px rgba(227, 227, 227, 0.3);
}

/* SETTINGS PANEL */
.settings-row {
    display: flex;
    justify-content: center; /* Centered */
    flex-wrap: wrap; 
    gap: 20px;
    margin: 0 auto 10px auto; /* Tighter spacing */
    max-width: 1000px; 
}

.setting-item {
    flex: 0 1 auto; 
    width: max-content;
    text-align: center; /* Centered */
}

.setting-item label {
    display: block;
    margin-bottom: 6px;
    color: #C4C7C5;
    font-size: 11px;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-align: center; /* Centered */
}

.setting-item input, .setting-item select {
    width: 140px; 
    padding: 10px 12px;
    border: 1px solid #444746;
    border-radius: 4px;
    font-family: 'Fira Code', monospace;
    font-size: 13px;
    color: #FFFFFF;
    background: #282A2C;
    transition: all 0.3s;
    text-align: center; /* Centered */
}
.setting-item input:focus, .setting-item select:focus {
    border-color: #E3E3E3;
    outline: none;
    box-shadow: 0 2px 8px rgba(227, 227, 227, 0.1);
}

/* SETTINGS BUTTON WRAPPER */
.setting-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 5px; /* Tighter */
}

/* BUTTONS */
button {
    padding: 10px 20px;
    border: 1px solid #444746 !important;
    border-radius: 4px !important;
    cursor: pointer;
    color: #FFFFFF !important;
    background-color: #1E1F20 !important;
    margin-top: 5px;
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    width: max-content; 
}

button:hover {
    background-color: #444746 !important;
    transform: translateY(-2px) scale(1.05) !important; /* Expansion & Stand out */
    box-shadow: 0 10px 20px rgba(0,0,0,0.3) !important;
}

button:active {
    transform: translateY(1px) scale(0.98) !important;
}

.remove-btn { 
    border-color: #EF4444 !important; 
    color: #EF4444 !important; 
    background: transparent !important;
    margin: 5px auto; /* Centered and tight */
    display: block;
}
.remove-btn:hover {
    background-color: rgba(239, 68, 68, 0.1) !important;
}

button:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* OVERRIDE INLINE HTML COLORS FOR THEME */
#manualBuyBtn, #activateEaBtn, #enableSignalsBtn, .btn-green { 
    background-color: transparent !important; 
    border-color: #10B981 !important;
    color: #10B981 !important; 
}
#manualBuyBtn:hover, #activateEaBtn:hover, #enableSignalsBtn:hover, .btn-green:hover:not(:disabled) {
    background-color: rgba(16, 185, 129, 0.1) !important;
    box-shadow: 0 0 15px rgba(16, 185, 129, 0.2) !important;
}

#manualSellBtn, #stopEaSymbolBtn, #disableSignalsSymbolBtn, .btn-red { 
    background-color: transparent !important; 
    border-color: #EF4444 !important;
    color: #EF4444 !important; 
}
#manualSellBtn:hover, #stopEaSymbolBtn:hover, #disableSignalsSymbolBtn:hover, .btn-red:hover:not(:disabled) {
    background-color: rgba(239, 68, 68, 0.1) !important;
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.2) !important;
}

#manualCloseAllBtn, #stopEaAllBtn, #cancelAllSignalsBtn, .btn-grey {
    background-color: transparent !important; 
    border-color: #E3E3E3 !important;
    color: #E3E3E3 !important; 
}
#manualCloseAllBtn:hover, #stopEaAllBtn:hover, #cancelAllSignalsBtn:hover, .btn-grey:hover:not(:disabled) {
    background-color: rgba(227, 227, 227, 0.1) !important;
    box-shadow: 0 0 15px rgba(227, 227, 227, 0.2) !important;
}

/* STATUS FEEDS */
.status-container {
    background: #131314; 
    border: 1px solid #444746;
    border-radius: 6px;
    margin: 0 auto 15px auto; /* Tighter and Centered */
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    max-width: 1000px; /* Locked constraint */
    width: 100%;
}

.status-header {
    background-color: #1E1F20;
    padding: 12px 20px;
    font-weight: 500;
    border-bottom: 1px solid #444746;
    color: #E3E3E3; 
    font-family: 'Cormorant Garamond', serif;
    font-size: 18px;
    letter-spacing: 1px;
    text-align: center; /* Centered */
}

.status-feed {
    background-color: transparent;
    color: #C4C7C5;
    height: 160px;
    overflow-y: auto;
    padding: 15px 20px;
    font-family: 'Fira Code', monospace;
    font-size: 13px;
    line-height: 1.6;
    text-align: center; /* Centered */
}

.signal-entry {
    border-bottom: 1px solid #1E1F20;
    padding: 6px 0;
}

.signal-text-buy { color: #10B981; font-weight: 500;} 
.signal-text-sell { color: #EF4444; font-weight: 500;} 

/* FEED TOOLBAR */
.feed-toolbar {
    display: flex;
    justify-content: center; /* Centered */
    gap: 15px;
    padding: 12px 20px;
    border-bottom: 1px solid #444746;
    background: #1E1F20;
    flex-wrap: wrap;
    align-items: center;
}

.feed-btn {
    font-size: 11px;
    padding: 6px 12px;
    margin: 0;
    height: 32px;
}

.feed-dd {
    flex: 0 0 auto;
    width: max-content; 
    margin-bottom: 0;
}

.feed-dd-header {
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center; /* Centered */
    padding: 0 15px;
    background: #131314;
    border: 1px solid #444746;
    color: #C4C7C5;
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    box-shadow: none;
}

.feed-dd-content {
    max-height: 260px;
    background: #1E1F20;
    border: 1px solid #444746;
    color: #FFFFFF;
}

/* EXECUTION ROW */
.execution-row {
    display: flex;
    justify-content: center; /* Centered */
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
    margin: 10px auto 0 auto; /* Tighter Margin */
    padding-top: 15px;
    border-top: 1px solid #444746;
    max-width: 1000px;
}

.repeat-inline {
    display: flex;
    align-items: center;
    justify-content: center; /* Centered */
    gap: 12px;
    padding: 6px 12px;
    background: #1E1F20;
    border: 1px solid #444746;
    border-radius: 4px;
    width: max-content; 
    margin-top: 5px; /* Match button margins */
}

.repeat-inline-label {
    font-weight: 600;
    color: #C4C7C5;
    font-size: 11px;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.repeat-inline-select {
    height: 30px;
    padding: 4px 10px;
    background-color: #282A2C;
    border: 1px solid #444746;
    color: #FFFFFF;
    border-radius: 4px;
    cursor: pointer;
    width: 60px;
    font-family: 'Fira Code', monospace;
    font-size: 13px;
    text-align: center;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ================= DASHBOARD VISUALS (The Gallery) ================= */
.dashboard-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center; /* Centered */
    margin: 0 auto 20px auto; /* Tighter Margin */
    border-bottom: 1px solid #444746;
    padding-bottom: 15px;
    max-width: 1000px; /* Locked to 1000px baseline */
}
.dashboard-header h2 {
    margin: 0 0 5px 0;
    color: #FFFFFF;
    font-size: 32px;
    font-weight: 600;
    letter-spacing: 0.5px;
}
.dashboard-header p {
    margin: 0;
    color: #8E918F;
    font-size: 15px;
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
}

/* Stat Cards */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* Forced 4 inline to match width */
    justify-content: center;
    gap: 20px;
    margin: 0 auto 35px auto;
    max-width: 1000px;
}

@media (max-width: 900px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 500px) {
    .stats-grid { grid-template-columns: 1fr; }
}

.stat-card {
    background-color: #1E1F20;
    border: 1px solid #444746;
    border-radius: 6px;
    padding: 20px;
    display: flex;
    flex-direction: column; /* Centered Stack */
    align-items: center;
    text-align: center;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5); 
    transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}
.stat-card:hover {
    transform: translateY(-4px) scale(1.05); /* Added scaling */
    box-shadow: 0 15px 40px -10px rgba(227, 227, 227, 0.1);
    border-color: #E3E3E3;
}
.stat-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    border: 1px solid #E3E3E3;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    margin: 0 0 15px 0; /* Adjusted for stacking */
    background: rgba(227, 227, 227, 0.1);
    color: #E3E3E3;
}
.stat-details {
    flex-grow: 1;
}
.stat-label {
    margin: 0 0 5px 0;
    font-size: 10px;
    color: #C4C7C5;
    text-transform: uppercase;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    letter-spacing: 1px;
}
.stat-value {
    margin: 0;
    font-size: 20px;
    color: #FFFFFF;
    font-weight: 500;
    font-family: 'Fira Code', monospace;
}

/* Elegant Text Overrides */
.text-green { color: #10B981 !important; }
.text-red { color: #EF4444 !important; }
.text-yellow { color: #E3E3E3 !important; }

/* Charts Area */
.charts-row {
    display: flex;
    justify-content: center;
    gap: 25px;
    flex-wrap: wrap;
    margin: 0 auto;
    max-width: 1000px;
}
.chart-card {
    background-color: #1E1F20;
    border: 1px solid #444746;
    border-radius: 6px;
    padding: 30px;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    flex: 1;
    min-width: 300px;
    text-align: center; /* Centered */
}

.chart-title {
    margin: 0 auto 25px auto;
    font-size: 20px;
    color: #FFFFFF;
    border-bottom: 2px solid #E3E3E3; /* Moved border to bottom for center look */
    border-left: none;
    padding-bottom: 10px;
    padding-left: 0;
    width: max-content;
    font-weight: 600;
    font-family: 'Cormorant Garamond', serif;
}

/* Performance Table */
.performance-table {
    width: 100%;
    border-collapse: collapse;
    color: #C4C7C5;
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    margin: 0 auto;
}
.performance-table th {
    text-align: center; /* Centered */
    padding: 12px 15px;
    border-bottom: 1px solid #5F6368;
    color: #FFFFFF;
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.performance-table td {
    text-align: center; /* Centered */
    padding: 15px 15px;
    border-bottom: 1px solid #444746;
}
.performance-table td:first-child {
    font-family: 'Fira Code', monospace;
    font-weight: 500;
    color: #FFFFFF;
}
.performance-table tbody tr {
    transition: background-color 0.3s;
}
.performance-table tbody tr:hover {
    background-color: #282A2C;
}


/* ================= ACCOUNTS SECTION & GLOBAL SELECTOR ================= */
.accounts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    justify-content: center;
    gap: 25px;
    margin: 15px auto 0 auto;
    max-width: 1000px;
}
.account-card {
    background: #1E1F20;
    border: 1px solid #444746;
    border-radius: 6px;
    padding: 30px;
    position: relative;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
    text-align: center; /* Centered */
}
.account-card.active {
    border-color: #E3E3E3;
    box-shadow: 0 0 20px rgba(227, 227, 227, 0.15);
}
.acc-card-header {
    display: flex;
    flex-direction: column; /* Stacked */
    align-items: center; /* Centered */
    margin-bottom: 20px;
    gap: 10px;
}
.acc-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 1px;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
}
.badge-demo { background: #282A2C; color: #C4C7C5; border: 1px solid #5F6368; }
.badge-live { background: rgba(227, 227, 227, 0.1); color: #E3E3E3; border: 1px solid #E3E3E3; }
.acc-active-label {
    color: #E3E3E3;
    font-size: 11px;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.acc-number {
    font-size: 28px;
    font-weight: 500;
    color: #FFFFFF;
    margin-bottom: 5px;
    font-family: 'Fira Code', monospace;
}
.acc-server {
    font-size: 13px;
    color: #8E918F;
    margin-bottom: 25px;
    font-family: 'Inter', sans-serif;
}
.acc-actions {
    display: flex;
    justify-content: center;
    gap: 15px;
    border-top: 1px solid #444746;
    padding-top: 20px;
}
.btn-acc {
    flex: 1; padding: 10px; border: 1px solid #5F6368; border-radius: 4px; 
    cursor: pointer; font-weight: 600; font-size: 11px; font-family: 'Inter', sans-serif; 
    text-transform: uppercase; letter-spacing: 1px; transition: 0.3s;
    background: transparent; color: #C4C7C5;
}
.btn-acc-active { color: #E3E3E3; border-color: #E3E3E3; }
.btn-acc-active:hover { background: #E3E3E3; color: #131314; box-shadow: 0 0 15px rgba(227, 227, 227, 0.2); }
.btn-acc-edit:hover { background: #282A2C; color: #FFFFFF; }
.btn-acc-delete { border-color: #444746; color: #EF4444; margin: 0;}
.btn-acc-delete:hover { border-color: #EF4444; background: rgba(239, 68, 68, 0.1); }

.cp-global-header {
    display: flex; 
    flex-direction: row; /* Restored Row Alignment */
    justify-content: space-between; /* Space between extremes */
    align-items: center;
    background: #1E1F20; 
    padding: 15px 30px; /* Reduced Padding */
    border-radius: 6px;
    border: 1px solid #444746; 
    margin: 0 auto 20px auto; /* Tighter spacing, centered */
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    max-width: 1000px; /* Baseline Constraint */
    width: 100%;
    box-sizing: border-box;
}
.cp-active-account { display: flex; flex-direction: row; align-items: center; gap: 15px; } /* Inline */
.cp-label { font-size: 12px; color: #C4C7C5; font-weight: 600; font-family: 'Inter', sans-serif; text-transform: uppercase; letter-spacing: 1px;}
.cp-leader { margin: 0; padding: 10px 15px; font-size: 13px; background: #282A2C; border: 1px solid #5F6368; color: #C4C7C5;}
.cp-account-dropdown-header {
    background-color: #282A2C; border-color: #5F6368; color: #FFFFFF; 
    font-size: 16px; font-weight: 500; font-family: 'Fira Code', monospace;
    box-shadow: none;
    text-align: center;
}

/* ================= HOME: NEWS & UPDATES ================= */
.news-hero {
    background: linear-gradient(135deg, #1E1F20, #131314); 
    border: 1px solid #444746;
    border-top: 4px solid #E3E3E3; /* Switched to top for symmetry */
    border-left: 1px solid #444746;
    border-radius: 6px;
    padding: 50px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 15px 40px -10px rgba(0, 0, 0, 0.5); 
    max-width: 1000px;
    margin: 0 auto 30px auto;
}
.news-hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.news-hero::after {
    content: 'A';
    position: absolute; top: -50px; left: 50%; transform: translateX(-50%); /* Centered overlay */
    font-family: 'Cormorant Garamond', serif;
    font-size: 300px;
    color: rgba(255, 255, 255, 0.02); 
    pointer-events: none;
}
.badge-new {
    background: #E3E3E3; color: #131314; font-size: 11px; font-weight: 600;
    padding: 4px 12px; border: 1px solid #E3E3E3;
    border-radius: 20px;
    letter-spacing: 1px; font-family: 'Inter', sans-serif; text-transform: uppercase;
}
.hero-title { margin: 25px 0 15px 0; font-size: 42px; color: #FFFFFF; font-weight: 600;}
.hero-subtitle { color: #8E918F; font-size: 16px; line-height: 1.8; max-width: 600px; margin-bottom: 30px; font-family: 'Inter', sans-serif; font-weight: 300;}
.hero-btn { 
    width: auto; padding: 14px 35px; font-size: 13px; background: #E3E3E3 !important; color: #131314 !important; border: none !important; 
    box-shadow: 0 0 20px rgba(227, 227, 227, 0.2) !important;
}

.news-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); justify-content: center; gap: 25px; margin: 20px auto 0 auto; max-width: 1000px;
}
.news-card {
    background: #1E1F20; border: 1px solid #444746; 
    border-radius: 6px; padding: 30px;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s, border-color 0.3s;
    text-align: center; /* Centered */
    display: flex;
    flex-direction: column;
    align-items: center;
}
.news-card:hover { transform: translateY(-5px) scale(1.02); border-color: #E3E3E3; box-shadow: 0 15px 40px -10px rgba(227, 227, 227, 0.15); }
.news-tag {
    display: inline-block; font-size: 10px; font-weight: 600; text-transform: uppercase;
    padding: 4px 10px; margin-bottom: 20px; letter-spacing: 1px;
    border: 1px solid transparent; font-family: 'Inter', sans-serif;
    border-radius: 4px;
}
.tag-alert { background: rgba(239, 68, 68, 0.1); color: #EF4444; border-color: rgba(239, 68, 68, 0.2); }
.tag-update { background: rgba(227, 227, 227, 0.1); color: #E3E3E3; border-color: #E3E3E3; }
.tag-edu { background: rgba(59, 130, 246, 0.1); color: #60A5FA; border-color: rgba(59, 130, 246, 0.2); } 

.news-title { color: #FFFFFF; margin: 0 0 15px 0; font-size: 20px; font-weight: 600; font-family: 'Cormorant Garamond', serif; }
.news-excerpt { color: #8E918F; font-size: 14px; line-height: 1.7; margin: 0 0 25px 0; font-family: 'Inter', sans-serif; font-weight: 300;}
.news-date { font-size: 12px; color: #8E918F; font-family: 'Fira Code', monospace; margin-top: auto;}


/* ================= HOME: TRADING SYSTEMS ================= */
.systems-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); justify-content: center; gap: 25px; margin: 20px auto 0 auto; max-width: 1000px;
}
.system-card {
    background: #1E1F20; border: 1px solid #444746; border-top: 4px solid #E3E3E3; 
    border-radius: 6px; padding: 30px; display: flex; flex-direction: column;
    align-items: center; /* Centered */
    text-align: center;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s, box-shadow 0.3s;
}
.system-card:hover { transform: translateY(-5px) scale(1.02); box-shadow: 0 15px 40px -10px rgba(227, 227, 227, 0.15); }

.sys-header { display: flex; flex-direction: column; align-items: center; gap: 10px; margin-bottom: 20px; width: 100%; }
.sys-title { color: #FFFFFF; margin: 0 0 8px 0; font-size: 24px; font-weight: 600; font-family: 'Cormorant Garamond', serif; }
.sys-version { color: #C4C7C5; font-size: 12px; font-family: 'Fira Code', monospace; background: #131314; padding: 2px 8px; border-radius: 4px; border: 1px solid #444746;}
.sys-status {
    background: rgba(16, 185, 129, 0.1); color: #10B981; border: 1px solid #10B981;
    font-size: 10px; font-weight: 600; padding: 4px 10px; 
    border-radius: 20px; text-transform: uppercase;
    letter-spacing: 1px; font-family: 'Inter', sans-serif;
}

.sys-desc { color: #8E918F; font-size: 14px; line-height: 1.7; margin: 0 0 25px 0; flex-grow: 1; font-family: 'Inter', sans-serif; font-weight: 300;}

.sys-metrics {
    display: flex; justify-content: center; gap: 20px; background: #131314; 
    border-radius: 4px; width: 100%; box-sizing: border-box;
    padding: 15px 20px; margin-bottom: 25px; border: 1px solid #282A2C;
}
.sys-metric { display: flex; flex-direction: column; align-items: center; }
.sm-label { font-size: 10px; color: #8E918F; text-transform: uppercase; margin-bottom: 5px; font-weight: 600; font-family: 'Inter', sans-serif; letter-spacing: 0.5px;}
.sm-value { font-size: 16px; color: #FFFFFF; font-weight: 500; font-family: 'Fira Code', monospace;}

.sys-footer { display: flex; flex-direction: column; gap: 15px; align-items: center; border-top: 1px solid #444746; padding-top: 20px; width: 100%; }
.sys-pairs { font-size: 12px; color: #8E918F; font-family: 'Fira Code', monospace; }
.sys-action-btn {
    background: transparent; border: 1px solid #5F6368; color: #E3E3E3; padding: 8px 16px;
    border-radius: 4px; 
    font-size: 11px; font-weight: 600; cursor: pointer; transition: 0.3s;
    font-family: 'Inter', sans-serif; text-transform: uppercase; letter-spacing: 1px;
}
.sys-action-btn:hover { background: #E3E3E3; color: #131314; box-shadow: 0 0 15px rgba(227, 227, 227, 0.2); transform: scale(1.05);}


/* ================= TOOLBOX: CALCULATOR ================= */
.calc-container { 
    display: flex; justify-content: center; gap: 30px; flex-wrap: wrap; margin: 20px auto 0 auto; max-width: 1000px;
}
.calc-card { 
    flex: 1; min-width: 300px; background: #1E1F20; 
    border: 1px solid #444746; border-radius: 6px; padding: 40px; 
    display: flex; flex-direction: column; align-items: center; text-align: center;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    margin: 0 auto;
}
.calc-result-card { 
    flex: 1; min-width: 250px; background: #131314; 
    border: 1px solid #444746; 
    border-top: 4px solid #E3E3E3; 
    border-radius: 6px; padding: 40px; display: flex; 
    flex-direction: column; align-items: center; justify-content: center; text-align: center;
    box-shadow: 0 15px 40px -10px rgba(0, 0, 0, 0.6);
}
.result-block { margin-top: 30px; }
.result-label { 
    display: block; color: #8E918F; font-size: 12px; text-transform: uppercase; letter-spacing: 1px;
    margin-bottom: 10px; font-weight: 600; font-family: 'Inter', sans-serif;
}
.result-value { 
    display: block; font-size: 42px; font-weight: 400; 
    color: #E3E3E3 !important; font-family: 'Cormorant Garamond', serif; 
}

/* ================= ACADEMY & KYC STYLES ================= */
.edu-featured {
    background: linear-gradient(135deg, rgba(19, 19, 20, 0.9), rgba(30, 31, 32, 0.95)), url('https://images.unsplash.com/photo-1611974789855-9c2a0a7236a3?auto=format&fit=crop&w=1200&q=80') center/cover;
    border: 1px solid #444746; border-radius: 6px; padding: 50px; margin: 0 auto 40px auto;
    display: flex; flex-direction: column; align-items: center; text-align: center;
    box-shadow: 0 15px 40px -10px rgba(0, 0, 0, 0.6); color: #FFF;
    max-width: 1000px;
}
.edu-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); justify-content: center; gap: 25px; margin: 0 auto; max-width: 1000px;
}
.edu-card {
    background: #1E1F20; border: 1px solid #444746; 
    border-radius: 6px; overflow: hidden;
    transition: transform 0.3s, border-color 0.3s; cursor: pointer;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    text-align: center;
}
.edu-card:hover { transform: translateY(-5px) scale(1.02); border-color: #E3E3E3; box-shadow: 0 15px 40px -10px rgba(227, 227, 227, 0.15);}
.edu-thumb {
    height: 180px; position: relative; display: flex; align-items: center; justify-content: center;
    background: #131314; border-bottom: 1px solid #444746;
}
.edu-duration {
    position: absolute; bottom: 10px; right: 10px; background: rgba(0,0,0,0.8); border: 1px solid #5F6368;
    color: #FFFFFF; font-size: 11px; padding: 4px 8px; border-radius: 4px; font-family: 'Fira Code', monospace; font-weight: 500;
}
.play-btn-overlay {
    width: 50px; height: 50px; background: #E3E3E3; color: #131314; border: none;
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 18px; opacity: 0; transition: all 0.3s; padding-left: 4px;
    box-shadow: 0 0 20px rgba(227, 227, 227, 0.2);
}
.edu-card:hover .play-btn-overlay { opacity: 1; transform: scale(1.1); }
.edu-info { padding: 25px; display: flex; flex-direction: column; align-items: center; }
.edu-info h4 { margin: 0 0 15px 0; color: #FFFFFF; font-size: 18px; line-height: 1.5; font-weight: 600; font-family: 'Cormorant Garamond', serif; }
.progress-bar-bg {
    width: 100%; height: 4px; background: #131314; border-radius: 2px; margin-bottom: 10px; overflow: hidden;
}
.progress-bar-fill { height: 100%; background: #E3E3E3; }

/* Profile Form Grid */
.profile-form-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); 
    justify-content: center;
    gap: 20px; 
}

/* Profile & KYC */
.avatar-placeholder {
    width: 120px; height: 120px; border-radius: 50%; background: #131314;
    display: flex; align-items: center; justify-content: center; margin: 0 auto 20px auto;
    border: 1px solid #5F6368;
    color: #E3E3E3;
    box-shadow: inset 0 0 15px rgba(0,0,0,0.5);
}
.kyc-container { margin: 20px auto 0 auto; max-width: 600px; display: flex; flex-direction: column; align-items: center;}
.kyc-status-box {
    padding: 25px; margin-bottom: 25px; border: 1px solid #444746;
    border-radius: 6px; border-top: 3px solid #E3E3E3; border-left: none; /* Moved border to top for center look */
    background: #1E1F20; box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    text-align: center;
}
.kyc-status-box.pending h3 { color: #E3E3E3; margin: 0 0 10px 0; font-size: 18px; font-weight: 600; font-family: 'Cormorant Garamond', serif;}
.kyc-status-box.pending p { color: #8E918F; margin: 0; font-size: 14px; line-height: 1.6; font-family: 'Inter', sans-serif; font-weight: 300;}
.kyc-upload-zone {
    border: 1px dashed #5F6368; border-radius: 6px; padding: 50px 20px; width: 100%; box-sizing: border-box;
    text-align: center; background: #1E1F20; transition: all 0.3s; cursor: pointer;
}
.kyc-upload-zone:hover { background: #131314; border-style: solid; box-shadow: 0 0 20px rgba(227, 227, 227, 0.1); transform: scale(1.02); }
.kyc-upload-zone p { color: #FFFFFF !important; font-family: 'Cormorant Garamond', serif; font-size: 20px; margin-top: 15px;}

/* ================= TIER 3 SUB-TABS (Running & History) ================= */
.tier3-tabs {
    margin-bottom: 20px; 
    border-bottom: none; 
    gap: 10px;
}

.tier3-btn {
    background-color: #1E1F20 !important;
    border: 1px solid #444746 !important;
    color: #8E918F !important;
    border-bottom: 2px solid transparent !important;
}

.tier3-btn:hover { 
    color: #FFFFFF !important; 
    border-color: #E3E3E3 !important; 
}

.tier3-btn.active { 
    color: #131314 !important; 
    background-color: #E3E3E3 !important; 
}

/* Ensure only active content shows via display none */
.tier3-content {
    display: none;
}

.tier3-content.active {
    display: block;
}

/* ================= STATUS & STATS WORKSPACES (MT5 STYLE) ================= */
.mt5-workspace {
    background: transparent; 
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    font-family: 'Inter', sans-serif;
}

.mt5-stats-box {
    width: 100%;
    display: flex;
    flex-direction: column;
    padding: 10px 0;
}

.mt5-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 0; /* Flush to edges */
    font-size: 13px;
    color: #C4C7C5;
    border-bottom: 1px dotted #444746; /* Replicates MT5 stat dividers */
}
.mt5-stat-row:last-child {
    border-bottom: none;
}

.mt5-stat-row span:first-child {
    font-weight: 600;
    color: #8E918F;
}

.mt5-stat-row span:last-child {
    font-family: 'Fira Code', monospace;
    font-weight: 500;
    color: #FFFFFF;
}

.mt5-ribbon {
    width: 100%;
    background-color: #1E1F20;
    color: #8E918F;
    padding: 6px 15px; /* Thin, flat ribbon */
    font-size: 11px;
    text-transform: uppercase;
    font-weight: 600;
    text-align: left; /* Edge aligned */
    border-top: 1px solid #282A2C;
    border-bottom: 1px solid #282A2C;
    margin: 5px 0;
    box-sizing: border-box;
}

.mt5-list {
    width: 100%;
    display: flex;
    flex-direction: column;
}

/* 🚀 FIX: Prevent text selection on double click & removed transition */
.mt5-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0; /* Minimal borderless padding, flush edges */
    border-bottom: 1px dotted #444746;
    /* REMOVED: transition: background 0.2s ease; to prevent 1s polling flicker */
    user-select: none; /* Prevent blue highlighting on double click */
}
.mt5-item:hover {
    background-color: #1E1F20;
}

.mt5-item-left {
    flex: 1;
    text-align: left;
    cursor: pointer; /* Indicate it is clickable */
}

.mt5-item-symbol {
    font-family: 'Cormorant Garamond', serif;
    font-size: 18px; /* Slightly refined size for list */
    font-weight: 600;
    color: #FFFFFF;
}

.mt5-item-right {
    display: flex;
    align-items: center;
    gap: 20px;
    justify-content: flex-end;
}

.mt5-item-vals {
    display: flex;
    gap: 15px;
    color: #8E918F;
    font-family: 'Fira Code', monospace;
    text-align: right;
}

/* Hover expansion logic for sub-values (oPrice, sLoss, tProfit) */
.mt5-item-vals span {
    font-size: 10px; /* ~1/3 of the 28px P/L size */
    cursor: default;
    /* REMOVED transition to prevent 1s polling flicker when hovered */
    line-height: 1.3;
}

.mt5-item-vals span:hover {
    font-size: 21px; /* ~3/4 of the 28px P/L size */
    color: #FFFFFF;
}

.mt5-item-pl {
    font-family: 'Fira Code', monospace;
    font-size: 28px;
    font-weight: 600;
    min-width: 80px;
    text-align: right;
}

/* ================= 🚀 NEW: INLINE EXECUTION ROW ================= */
.inline-execution-row {
    grid-column: 1 / -1; /* Spans across the entire grid row inside the mt5-item layout */
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    background-color: #18191A; /* Slightly darker to indicate it is a sub-row */
    border-bottom: 1px dotted #444746;
    /* REMOVED: animation to prevent repeating every 1s on telemetry pull */
    box-shadow: inset 0 5px 15px rgba(0,0,0,0.3);
}

/* --- Profile / My Account UI --- */
.profile-container {
    max-width: 800px;
    margin: 0 auto;
}
.profile-header-banner {
    display: flex;
    align-items: center;
    gap: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 20px;
}
.profile-avatar {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #2c3e50, #3498db);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    color: #fff;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}
.profile-info h3 {
    margin: 0;
    font-size: 24px;
    color: #fff;
}
.profile-info p {
    margin: 5px 0 10px 0;
    color: #888;
    font-size: 14px;
}
.readonly-input {
    background: rgba(0,0,0,0.2) !important;
    color: #666 !important;
    cursor: not-allowed;
}

/* --- Role Badges --- */
.role-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.badge-owner {
    background: rgba(52, 152, 219, 0.15);
    color: #3498db;
    border: 1px solid rgba(52, 152, 219, 0.3);
}
.badge-admin {
    background: rgba(46, 204, 113, 0.15);
    color: #2ecc71;
    border: 1px solid rgba(46, 204, 113, 0.3);
}
.badge-user {
    background: rgba(149, 165, 166, 0.15);
    color: #95a5a6;
    border: 1px solid rgba(149, 165, 166, 0.3);
}

/* --- Fleet Roster Table --- */
.roster-table {
    width: 100%;
    border-collapse: collapse;
    color: #ccc;
}
.roster-table th {
    text-align: left;
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: #888;
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
}
.roster-table td {
    padding: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.02);
    vertical-align: middle;
}
.roster-identity strong {
    display: block;
    color: #fff;
    font-size: 15px;
}
.roster-identity span {
    font-size: 12px;
    color: #777;
}
.status-indicator {
    font-size: 12px;
    padding: 3px 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
}
.status-active { color: #2ecc71; }

/* --- Action 3-Dot Menu Dropdown --- */
.action-cell {
    text-align: right;
}
.action-menu-container {
    position: relative;
    display: inline-block;
}
.action-dropdown {
    display: none; /* Hidden by default */
    position: absolute;
    right: 0;
    top: 100%;
    background: #1e222d;
    min-width: 180px;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.05);
    z-index: 100;
    text-align: left;
    overflow: hidden;
}
.action-menu-container:hover .action-dropdown {
    display: block; /* Show on hover */
}
.dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    color: #ccc;
    text-decoration: none;
    font-size: 13px;
    transition: 0.2s;
}
.dropdown-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}
.dropdown-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.05);
    margin: 4px 0;
}
.text-warn { color: #f39c12 !important; }
.text-freeze { color: #00cec9 !important; }
.text-danger { color: #e74c3c !important; }









/* ==========================================================================
   CHART ART FX: PREMIUM "LUMINOUS EDGE" UI ENGINE (APPENDED)
   ========================================================================== */

:root {
    /* Color Palette */
    --gold-primary: #D4AF37;
    --gold-light: #F3E5AB;
    --gold-dark: #996515;
    --bronze: #CD7F32;
    
    /* Surfaces & Backgrounds */
    --px-panel: #16181C;
    --px-surface: #1E2025;
    
    /* Borders & Lines */
    --px-border: rgba(255, 255, 255, 0.05);
    --px-border-gold: rgba(212, 175, 55, 0.2);
    
    /* Text */
    --px-text: #EFEFEF;
    --px-text-muted: #8E918F;

    /* Status Indicators */
    --color-status-success: #10B981;
    --color-status-destructive: #EF4444;
}

/* --- Layout Helpers --- */
.premium-workspace { display: flex; flex-direction: column; gap: 20px; padding-bottom: 40px; }
.mb-20 { margin-bottom: 20px; }
.mt-15 { margin-top: 15px; }

.px-label { font-size: 10px; color: var(--px-text-muted); text-transform: uppercase; font-weight: 700; letter-spacing: 1px; }
.px-value { font-size: 13px; color: var(--px-text); font-family: 'Fira Code', monospace; }
.px-value.highlight { color: var(--gold-light); }

.px-mono { font-family: 'Fira Code', monospace; font-size: 12px; }
.px-mono.text-muted { color: var(--px-text-muted); }
.px-mono.highlight { color: var(--px-text); }

.text-success { color: var(--color-status-success) !important; }
.text-danger { color: var(--color-status-destructive) !important; }

/* --- Panels & Cards --- */
.px-panel { background: var(--px-panel); border: 1px solid var(--px-border); border-radius: 12px; overflow: hidden; box-shadow: 0 8px 24px rgba(0,0,0,0.4); }
.px-panel-header { background: rgba(255,255,255,0.02); padding: 15px 20px; border-bottom: 1px solid var(--px-border); }
.px-panel-header h3 { margin: 0; font-size: 14px; color: #fff; text-transform: uppercase; letter-spacing: 1px; display: flex; align-items: center; gap: 10px; }
.px-panel-body { padding: 20px; }

.px-grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 15px; }
.px-card { background: var(--px-surface); border: 1px solid var(--px-border); border-radius: 8px; padding: 15px; }
.px-card-title { font-size: 11px; color: #fff; text-transform: uppercase; margin-bottom: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--px-border); }

/* --- Animations --- */
.pulse-dot { width: 8px; height: 8px; background: var(--gold-primary); border-radius: 50%; box-shadow: 0 0 10px var(--gold-primary); animation: pulseGold 2s infinite; }
@keyframes pulseGold { 0% { opacity: 0.5; } 50% { opacity: 1; } 100% { opacity: 0.5; } }

/* --- Inputs & Forms --- */
.px-input-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 15px; margin-bottom: 20px; }
.px-input-group { display: flex; flex-direction: column; gap: 6px; }
.px-input-group label { font-size: 10px; color: var(--px-text-muted); text-transform: uppercase; letter-spacing: 1px; }
.px-input { background: #0D0E12; border: 1px solid var(--px-border); border-radius: 6px; padding: 10px; color: var(--gold-light); font-family: 'Fira Code', monospace; font-size: 13px; outline: none; transition: 0.2s; }
.px-input:focus { border-color: var(--gold-dark); box-shadow: inset 0 0 5px rgba(212, 175, 55, 0.1); }

/* Custom Dropdowns */
.px-dropdown { position: relative; width: 100%; }
.px-dropdown-header { background: var(--px-surface); border: 1px solid var(--px-border); border-radius: 8px; padding: 12px 15px; color: var(--px-text); font-size: 13px; display: flex; justify-content: space-between; cursor: pointer; transition: 0.2s; }
.px-dropdown-header:hover { border-color: var(--px-border-gold); }
.px-dropdown-content { position: absolute; top: calc(100% + 5px); left: 0; width: 100%; background: var(--px-panel); border: 1px solid var(--px-border-gold); border-radius: 8px; max-height: 250px; overflow-y: auto; box-shadow: 0 10px 30px rgba(0,0,0,0.8); z-index: 100; }
.px-dropdown-item { padding: 12px 15px; color: var(--px-text-muted); display: flex; align-items: center; gap: 12px; border-bottom: 1px solid var(--px-border); cursor: pointer; transition: 0.2s; }
.px-dropdown-item:hover { background: rgba(255,255,255,0.03); color: #fff; }
.px-dropdown-item.active { color: var(--gold-light); background: rgba(212, 175, 55, 0.05); }
.px-checkbox { width: 14px; height: 14px; border: 1px solid var(--px-text-muted); border-radius: 3px; display: flex; align-items: center; justify-content: center; }
.px-checkbox.checked { border-color: var(--gold-primary); background: var(--gold-primary); }

/* Selection Chips */
.px-chip-container { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; margin-bottom: 20px; }
.px-chip { background: var(--px-surface); border: 1px solid var(--px-border); color: var(--px-text-muted); padding: 8px 16px; border-radius: 20px; font-size: 12px; cursor: pointer; transition: 0.2s; font-family: 'Fira Code', monospace; }
.px-chip:hover { border-color: #555; color: #fff; }
.px-chip.active { background: rgba(212, 175, 55, 0.1); border-color: var(--gold-primary); color: var(--gold-light); box-shadow: 0 0 10px rgba(212, 175, 55, 0.1); }
.px-empty-state { width: 100%; padding: 15px; border: 1px dashed var(--px-border); border-radius: 8px; text-align: center; color: #555; font-size: 12px; }
.px-selection-display { display: flex; justify-content: space-between; align-items: center; padding: 12px 15px; background: #0D0E12; border-radius: 8px; border: 1px solid var(--px-border); }

/* Neo Toggles (Switches) */
.px-toggle-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-size: 12px; color: var(--px-text-muted); }
.px-switch { position: relative; width: 34px; height: 18px; }
.px-switch input { opacity: 0; width: 0; height: 0; }
.px-slider { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: #111; border: 1px solid #333; transition: .3s; border-radius: 18px; }
.px-slider:before { position: absolute; content: ""; height: 12px; width: 12px; left: 2px; bottom: 2px; background-color: #555; transition: .3s; border-radius: 50%; }
.px-switch input:checked + .px-slider { background-color: rgba(212, 175, 55, 0.2); border-color: var(--gold-primary); }
.px-switch input:checked + .px-slider:before { transform: translateX(16px); background-color: var(--gold-light); box-shadow: 0 0 5px var(--gold-primary); }

/* --- Stats Grid --- */
.px-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 15px; }
.px-stat-card { background: var(--px-panel); border: 1px solid var(--px-border); border-radius: 12px; padding: 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; box-shadow: inset 0 0 20px rgba(0,0,0,0.5); }
.px-stat-label { font-size: 10px; color: var(--px-text-muted); text-transform: uppercase; letter-spacing: 1px; }
.px-stat-value { font-size: 20px; font-family: 'Fira Code', monospace; font-weight: bold; color: #EFEFEF; }
.px-stat-value.highlight { color: var(--gold-primary); }

/* --- Data Lists & Grids --- */
.grid-5 { display: grid; grid-template-columns: minmax(100px, 2fr) minmax(60px, 1fr) minmax(60px, 1fr) minmax(80px, 1.2fr) minmax(90px, 1.5fr); gap: 10px; align-items: center; text-align: right; }
.grid-6 { display: grid; grid-template-columns: minmax(100px, 2fr) minmax(50px, 1fr) minmax(50px, 1fr) minmax(70px, 1.2fr) minmax(70px, 1.2fr) minmax(90px, 1.5fr); gap: 10px; align-items: center; text-align: right; }

.px-list-header { background: rgba(255,255,255,0.02); padding: 12px 20px; border-bottom: 1px solid var(--px-border); font-size: 10px; font-weight: 700; color: var(--px-text-muted); text-transform: uppercase; letter-spacing: 1px; }
.px-list-body { display: flex; flex-direction: column; }
.px-list-item { padding: 15px 20px; border-bottom: 1px solid var(--px-border); cursor: pointer; transition: 0.2s; background: transparent; }
.px-list-item:hover { background: rgba(255,255,255,0.02); }

.row-ignored-win { background: rgba(26, 42, 64, 0.2) !important; border-left: 3px solid #4B7BBE !important; }
.row-ignored-loss { background: rgba(74, 21, 21, 0.2) !important; border-left: 3px solid #A83F3F !important; }

.px-sym-title { font-size: 15px; font-weight: bold; }
.px-sym-sub { font-size: 10px; color: var(--px-text-muted); text-transform: uppercase; margin-top: 4px; font-weight: bold; letter-spacing: 1px; }
.px-pl { font-size: 16px; font-weight: bold; font-family: 'Fira Code', monospace; }

/* --- Buttons & Action Drawers --- */
.px-btn-text { background: transparent; border: none; cursor: pointer; font-size: 11px; text-transform: uppercase; font-weight: bold; }
.px-btn-text.text-danger { color: var(--color-status-destructive); }
.px-btn-text.text-danger:hover { color: #f87171; text-decoration: underline; }

.px-actions-row { display: flex; gap: 15px; justify-content: flex-end; border-top: 1px solid var(--px-border); padding-top: 20px; }

.px-action-drawer { display: flex; flex-wrap: wrap; gap: 10px; padding: 15px 20px; background: rgba(0,0,0,0.3); border-bottom: 1px solid var(--px-border); box-shadow: inset 0 5px 15px rgba(0,0,0,0.5); justify-content: flex-end; }
.px-action-drawer .px-btn { flex: 1; min-width: 120px; white-space: nowrap; }

.px-btn { padding: 10px 20px; border-radius: 6px; font-size: 11px; font-weight: bold; text-transform: uppercase; cursor: pointer; transition: 0.2s; display: flex; align-items: center; justify-content: center; gap: 8px; }
.px-btn:disabled { opacity: 0.4; cursor: not-allowed; filter: grayscale(1); }

.px-btn-solid { background: var(--px-surface); border: 1px solid var(--px-border-gold); color: var(--gold-light); }
.px-btn-solid:hover:not(:disabled) { background: rgba(212, 175, 55, 0.1); }
.px-btn-outline { background: transparent; border: 1px solid #555; color: #ccc; }
.px-btn-outline:hover:not(:disabled) { border-color: #fff; color: #fff; }

.btn-danger-outline { background: transparent; border: 1px solid rgba(239, 68, 68, 0.5); color: var(--color-status-destructive); }
.btn-danger-outline:hover:not(:disabled) { background: rgba(239, 68, 68, 0.1); }
.btn-danger-solid { background: #DC2626; border: none; color: #fff; box-shadow: 0 4px 15px rgba(220, 38, 38, 0.3); }
.btn-danger-solid:hover:not(:disabled) { background: #EF4444; transform: translateY(-2px); }

/* --- Master Terminal Bar --- */
.px-master-terminal { display: flex; flex-wrap: wrap; gap: 10px; background: var(--px-panel); padding: 15px; border-radius: 12px; border: 1px solid var(--px-border); box-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.px-btn-master { flex: 1; min-width: 150px; padding: 15px; border-radius: 8px; font-size: 12px; font-weight: 800; text-transform: uppercase; cursor: pointer; transition: 0.2s; display: flex; align-items: center; justify-content: center; gap: 8px; }
.px-btn-master:disabled { opacity: 0.4; cursor: not-allowed; filter: grayscale(1); }

.btn-gold { background: linear-gradient(135deg, #B8860B, #FFD700, #DAA520); color: #111; border: none; box-shadow: 0 4px 15px rgba(212, 175, 55, 0.2); }
.btn-gold:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(212, 175, 55, 0.4); }
.btn-dark { background: var(--px-surface); border: 1px solid #444; color: #fff; }
.btn-dark:hover:not(:disabled) { background: #333; border-color: #666; }





/* ==========================================================================
   CHART ART FX: PREMIUM "LUMINOUS EDGE" UI ENGINE (APPENDED)
   ========================================================================== */

:root {
    --gold-primary: #D4AF37; --gold-light: #F3E5AB; --gold-dark: #996515; --bronze: #CD7F32;
    --blue-primary: #3B82F6; --green-primary: #10B981; --red-primary: #EF4444; --orange-primary: #EA580C;
    --px-panel: #16181C; --px-surface: #1E2025;
    --px-border: rgba(255, 255, 255, 0.05); --px-border-gold: rgba(212, 175, 55, 0.2);
    --px-text: #EFEFEF; --px-text-muted: #8E918F;
    --color-status-success: #10B981; --color-status-destructive: #EF4444;
    --px-color-robot: #D4AF37; --px-color-manual: #3B82F6; --px-color-signals: #10B981;
}

.premium-workspace { display: flex; flex-direction: column; gap: 20px; padding-bottom: 40px; }
.mb-20 { margin-bottom: 20px; }
.mt-15 { margin-top: 15px; }

.px-label { font-size: 10px; color: var(--px-text-muted); text-transform: uppercase; font-weight: 700; letter-spacing: 1px; }
.px-value { font-size: 13px; color: var(--px-text); font-family: 'Fira Code', monospace; }
.px-value.highlight { color: var(--gold-light); }
.px-mono { font-family: 'Fira Code', monospace; font-size: 12px; }
.px-mono.text-muted { color: var(--px-text-muted); }
.px-mono.highlight { color: var(--px-text); }
.text-success { color: var(--color-status-success) !important; }
.text-danger { color: var(--color-status-destructive) !important; }

.px-panel { background: var(--px-panel); border: 1px solid var(--px-border); border-radius: 12px; overflow: hidden; box-shadow: 0 8px 24px rgba(0,0,0,0.4); }
.px-panel-header { background: rgba(255,255,255,0.02); padding: 15px 20px; border-bottom: 1px solid var(--px-border); }
.px-panel-header h3 { margin: 0; font-size: 14px; color: #fff; text-transform: uppercase; letter-spacing: 1px; display: flex; align-items: center; gap: 10px; }
.px-panel-body { padding: 20px; }

.px-grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 15px; }
.px-card { background: var(--px-surface); border: 1px solid var(--px-border); border-radius: 8px; padding: 15px; }
.px-card-title { font-size: 11px; color: #fff; text-transform: uppercase; margin-bottom: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--px-border); }

.pulse-dot { width: 8px; height: 8px; border-radius: 50%; }

.px-input-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 15px; margin-bottom: 20px; }
.px-input-group { display: flex; flex-direction: column; gap: 6px; }
.px-input-group label { font-size: 10px; color: var(--px-text-muted); text-transform: uppercase; letter-spacing: 1px; }
.px-input { background: #0D0E12; border: 1px solid var(--px-border); border-radius: 6px; padding: 10px; font-family: 'Fira Code', monospace; font-size: 13px; outline: none; transition: 0.2s; }
.px-input:focus { box-shadow: inset 0 0 5px rgba(255, 255, 255, 0.1); border-color: #555; }

.robotTradingTab .px-input { color: var(--px-color-robot); }
.robotTradingTab .px-input:focus { border-color: var(--px-color-robot); box-shadow: inset 0 0 5px rgba(212, 175, 55, 0.2); }
.manualTradingTab .px-input { color: var(--px-color-manual); }
.manualTradingTab .px-input:focus { border-color: var(--px-color-manual); box-shadow: inset 0 0 5px rgba(59, 130, 246, 0.2); }
.signalsTradingTab .px-input { color: var(--px-color-signals); }
.signalsTradingTab .px-input:focus { border-color: var(--px-color-signals); box-shadow: inset 0 0 5px rgba(16, 185, 129, 0.2); }

.px-dropdown { position: relative; width: 100%; }
.px-dropdown-header { background: var(--px-surface); border: 1px solid var(--px-border); border-radius: 8px; padding: 12px 15px; color: var(--px-text); font-size: 13px; display: flex; justify-content: space-between; cursor: pointer; transition: 0.2s; }
.px-dropdown-content { position: absolute; top: calc(100% + 5px); left: 0; width: 100%; background: var(--px-panel); border-radius: 8px; max-height: 250px; overflow-y: auto; box-shadow: 0 10px 30px rgba(0,0,0,0.8); z-index: 100; border: 1px solid var(--px-border); }
.px-dropdown-item { padding: 12px 15px; color: var(--px-text-muted); display: flex; align-items: center; gap: 12px; border-bottom: 1px solid var(--px-border); cursor: pointer; transition: 0.2s; }
.px-dropdown-item:hover { background: rgba(255,255,255,0.03); color: #fff; }
.px-checkbox { width: 14px; height: 14px; border: 1px solid var(--px-text-muted); border-radius: 3px; display: flex; align-items: center; justify-content: center; }

.robotTradingTab .px-dropdown-header:hover { border-color: rgba(212,175,55,0.4); }
.robotTradingTab .px-dropdown-content { border-color: rgba(212,175,55,0.2); }
.robotTradingTab .px-dropdown-item.active { color: var(--px-color-robot); background: rgba(212, 175, 55, 0.05); }
.robotTradingTab .px-checkbox.checked { border-color: var(--px-color-robot); background: var(--px-color-robot); }

.manualTradingTab .px-dropdown-header:hover { border-color: rgba(59,130,246,0.4); }
.manualTradingTab .px-dropdown-content { border-color: rgba(59,130,246,0.2); }
.manualTradingTab .px-dropdown-item.active { color: var(--px-color-manual); background: rgba(59, 130, 246, 0.05); }
.manualTradingTab .px-checkbox.checked { border-color: var(--px-color-manual); background: var(--px-color-manual); }

.signalsTradingTab .px-dropdown-header:hover { border-color: rgba(16,185,129,0.4); }
.signalsTradingTab .px-dropdown-content { border-color: rgba(16,185,129,0.2); }
.signalsTradingTab .px-dropdown-item.active { color: var(--px-color-signals); background: rgba(16, 185, 129, 0.05); }
.signalsTradingTab .px-checkbox.checked { border-color: var(--px-color-signals); background: var(--px-color-signals); }

.px-chip-container { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; margin-bottom: 20px; }
.px-chip { background: var(--px-surface); border: 1px solid var(--px-border); color: var(--px-text-muted); padding: 8px 16px; border-radius: 20px; font-size: 12px; cursor: pointer; transition: 0.2s; font-family: 'Fira Code', monospace; }
.px-chip:hover { border-color: #555; color: #fff; }
.px-empty-state { width: 100%; padding: 15px; border: 1px dashed var(--px-border); border-radius: 8px; text-align: center; color: #555; font-size: 12px; }
.px-selection-display { display: flex; justify-content: space-between; align-items: center; padding: 12px 15px; background: #0D0E12; border-radius: 8px; border: 1px solid var(--px-border); }

.robotTradingTab .px-chip.active { background: rgba(212, 175, 55, 0.1) !important; border-color: var(--px-color-robot) !important; color: #fff !important; box-shadow: 0 0 8px rgba(212, 175, 55, 0.2) !important; font-weight: bold; }
.manualTradingTab .px-chip.active { background: rgba(59, 130, 246, 0.1) !important; border-color: var(--px-color-manual) !important; color: #fff !important; box-shadow: 0 0 8px rgba(59, 130, 246, 0.2) !important; font-weight: bold; }
.signalsTradingTab .px-chip.active { background: rgba(16, 185, 129, 0.1) !important; border-color: var(--px-color-signals) !important; color: #fff !important; box-shadow: 0 0 8px rgba(16, 185, 129, 0.2) !important; font-weight: bold; }

.px-header-row { display: flex; justify-content: space-between; align-items: center; margin-top: 15px; margin-bottom: 10px; }
.px-toggle-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-size: 12px; color: var(--px-text-muted); }
.px-mode-toggle { display: flex; align-items: center; gap: 8px; font-size: 10px; color: var(--px-text-muted); text-transform: uppercase; font-weight: bold; letter-spacing: 1px; }

.px-switch { position: relative; width: 34px; height: 18px; }
.px-switch input { opacity: 0; width: 0; height: 0; }
.px-slider { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: #111; border: 1px solid #333; transition: .3s; border-radius: 18px; }
.px-slider:before { position: absolute; content: ""; height: 12px; width: 12px; left: 2px; bottom: 2px; background-color: #555; transition: .3s; border-radius: 50%; }

.robotTradingTab .px-mode-active { color: var(--px-color-robot); }
.robotTradingTab .px-switch input:checked + .px-slider { background-color: rgba(212, 175, 55, 0.2); border-color: var(--px-color-robot); }
.robotTradingTab .px-switch input:checked + .px-slider:before { transform: translateX(16px); background-color: var(--px-color-robot); box-shadow: 0 0 5px var(--px-color-robot); }
.manualTradingTab .px-mode-active { color: var(--px-color-manual); }
.manualTradingTab .px-switch input:checked + .px-slider { background-color: rgba(59, 130, 246, 0.2); border-color: var(--px-color-manual); }
.manualTradingTab .px-switch input:checked + .px-slider:before { transform: translateX(16px); background-color: var(--px-color-manual); box-shadow: 0 0 5px var(--px-color-manual); }
.signalsTradingTab .px-mode-active { color: var(--px-color-signals); }
.signalsTradingTab .px-switch input:checked + .px-slider { background-color: rgba(16, 185, 129, 0.2); border-color: var(--px-color-signals); }
.signalsTradingTab .px-switch input:checked + .px-slider:before { transform: translateX(16px); background-color: var(--px-color-signals); box-shadow: 0 0 5px var(--px-color-signals); }

.px-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 15px; }
.px-stat-card { background: var(--px-panel); border: 1px solid var(--px-border); border-radius: 12px; padding: 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; box-shadow: inset 0 0 20px rgba(0,0,0,0.5); }
.px-stat-label { font-size: 10px; color: var(--px-text-muted); text-transform: uppercase; letter-spacing: 1px; }
.px-stat-value { font-size: 20px; font-family: 'Fira Code', monospace; font-weight: bold; color: #EFEFEF; }

.robotTradingTab .px-stat-value.highlight { color: var(--px-color-robot); }
.manualTradingTab .px-stat-value.highlight { color: var(--px-color-manual); }
.signalsTradingTab .px-stat-value.highlight { color: var(--px-color-signals); }

.grid-5 { display: grid; grid-template-columns: minmax(100px, 2fr) minmax(60px, 1fr) minmax(60px, 1fr) minmax(80px, 1.2fr) minmax(90px, 1.5fr); gap: 10px; align-items: center; text-align: right; }
.grid-6 { display: grid; grid-template-columns: minmax(100px, 2fr) minmax(50px, 1fr) minmax(50px, 1fr) minmax(70px, 1.2fr) minmax(70px, 1.2fr) minmax(90px, 1.5fr); gap: 10px; align-items: center; text-align: right; }

.px-list-header { background: rgba(255,255,255,0.02); padding: 12px 20px; border-bottom: 1px solid var(--px-border); font-size: 10px; font-weight: 700; color: var(--px-text-muted); text-transform: uppercase; letter-spacing: 1px; }
.px-list-body { display: flex; flex-direction: column; }
.px-list-item { padding: 15px 20px; border-bottom: 1px solid var(--px-border); cursor: pointer; transition: 0.2s; background: transparent; user-select: none;}
.px-list-item:hover { background: rgba(255,255,255,0.02); }

.px-sym-title { font-size: 15px; font-weight: bold; }
.px-sym-sub { font-size: 10px; color: var(--px-text-muted); text-transform: uppercase; margin-top: 4px; font-weight: bold; letter-spacing: 1px; }
.px-pl { font-size: 16px; font-weight: bold; font-family: 'Fira Code', monospace; }

.px-action-drawer { display: flex; flex-wrap: wrap; gap: 10px; padding: 15px 20px; background: rgba(0,0,0,0.3); border-bottom: 1px solid var(--px-border); box-shadow: inset 0 5px 15px rgba(0,0,0,0.5); justify-content: flex-end; }
.px-action-drawer .px-btn { flex: 1; min-width: 120px; white-space: nowrap; }

.px-actions-row { display: flex; gap: 15px; justify-content: flex-end; border-top: 1px solid var(--px-border); padding-top: 20px; }
.px-btn { padding: 10px 20px; border-radius: 6px; font-size: 11px; font-weight: bold; text-transform: uppercase; cursor: pointer; transition: 0.2s; display: flex; align-items: center; justify-content: center; gap: 8px; }
.px-btn-text { background: transparent; border: none; cursor: pointer; font-size: 11px; text-transform: uppercase; font-weight: bold; }
.px-btn-text:hover { text-decoration: underline; }
.px-btn-outline { background: transparent; border: 1px solid #555; color: #ccc; }
.px-btn-outline:hover:not(:disabled) { border-color: #fff; color: #fff; }
.px-btn:disabled, .px-btn-master:disabled { opacity: 0.3 !important; cursor: not-allowed !important; background: transparent !important; border-color: #333 !important; color: #555 !important; box-shadow: none !important; }

.px-master-terminal { display: flex; flex-wrap: wrap; gap: 10px; background: var(--px-panel); padding: 15px; border-radius: 12px; border: 1px solid var(--px-border); box-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.px-btn-master { flex: 1; min-width: 150px; padding: 15px; border-radius: 8px; font-size: 12px; font-weight: 800; text-transform: uppercase; cursor: pointer; transition: 0.2s; display: flex; align-items: center; justify-content: center; gap: 8px; }

/* History Header Themes */
.theme-header-robot { border-bottom: 2px solid var(--px-color-robot) !important; box-shadow: inset 0 -5px 15px rgba(212, 175, 55, 0.1); }
.theme-text-robot { color: var(--px-color-robot) !important; text-shadow: 0 0 5px rgba(212, 175, 55, 0.3); }

.theme-header-manual { border-bottom: 2px solid var(--px-color-manual) !important; box-shadow: inset 0 -5px 15px rgba(59, 130, 246, 0.1); }
.theme-text-manual { color: var(--px-color-manual) !important; text-shadow: 0 0 5px rgba(59, 130, 246, 0.3); }

.theme-header-signals { border-bottom: 2px solid var(--px-color-signals) !important; box-shadow: inset 0 -5px 15px rgba(16, 185, 129, 0.1); }
.theme-text-signals { color: var(--px-color-signals) !important; text-shadow: 0 0 5px rgba(16, 185, 129, 0.3); }

/* Custom Save Buttons */
.px-btn-solid-gold { background: rgba(212, 175, 55, 0.1); border: 1px solid rgba(212, 175, 55, 0.4); color: var(--gold-primary); }
.px-btn-solid-gold:hover:not(:disabled) { background: rgba(212, 175, 55, 0.2); color: #fff; }
.px-btn-solid-blue { background: rgba(59, 130, 246, 0.1); border: 1px solid rgba(59, 130, 246, 0.4); color: var(--blue-primary); }
.px-btn-solid-blue:hover:not(:disabled) { background: rgba(59, 130, 246, 0.2); color: #fff; }
.px-btn-solid-green { background: rgba(16, 185, 129, 0.1); border: 1px solid rgba(16, 185, 129, 0.4); color: var(--green-primary); }
.px-btn-solid-green:hover:not(:disabled) { background: rgba(16, 185, 129, 0.2); color: #fff; }

/* Global Tactical Buttons (Drawers & Terminals) */
.btn-initiate { background: rgba(212, 175, 55, 0.05) !important; border: 1px solid rgba(212, 175, 55, 0.4) !important; color: var(--gold-primary) !important; box-shadow: none !important; }
.btn-initiate:hover:not(:disabled) { background: rgba(212, 175, 55, 0.15) !important; border-color: var(--gold-primary) !important; color: #EFEFEF !important; box-shadow: 0 4px 12px rgba(212, 175, 55, 0.2) !important; transform: translateY(-1px); }

.btn-buy-action { background: rgba(59, 130, 246, 0.05) !important; border: 1px solid rgba(59, 130, 246, 0.4) !important; color: var(--blue-primary) !important; box-shadow: none !important; }
.btn-buy-action:hover:not(:disabled) { background: rgba(59, 130, 246, 0.15) !important; border-color: var(--blue-primary) !important; color: #EFEFEF !important; box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2) !important; transform: translateY(-1px); }

.btn-broadcast { background: rgba(16, 185, 129, 0.05) !important; border: 1px solid rgba(16, 185, 129, 0.4) !important; color: var(--green-primary) !important; box-shadow: none !important; }
.btn-broadcast:hover:not(:disabled) { background: rgba(16, 185, 129, 0.15) !important; border-color: var(--green-primary) !important; color: #EFEFEF !important; box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2) !important; transform: translateY(-1px); }

.btn-suspend { background: rgba(153, 101, 21, 0.05) !important; border: 1px solid rgba(153, 101, 21, 0.4) !important; color: #EFEFEF !important; box-shadow: none !important; }
.btn-suspend:hover:not(:disabled) { background: rgba(153, 101, 21, 0.15) !important; border-color: var(--gold-primary) !important; color: #fff !important; box-shadow: 0 4px 12px rgba(153, 101, 21, 0.2) !important; transform: translateY(-1px); }

.btn-terminate, .btn-sell-action, .btn-disable { background: rgba(239, 68, 68, 0.05) !important; border: 1px solid rgba(239, 68, 68, 0.4) !important; color: var(--red-primary) !important; box-shadow: none !important; }
.btn-terminate:hover:not(:disabled), .btn-sell-action:hover:not(:disabled), .btn-disable:hover:not(:disabled) { background: rgba(239, 68, 68, 0.15) !important; border-color: var(--red-primary) !important; color: #EFEFEF !important; box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2) !important; transform: translateY(-1px); }

.btn-cancel-target, .btn-close-target { background: rgba(220, 38, 38, 0.05) !important; border: 1px solid rgba(220, 38, 38, 0.4) !important; color: #DC2626 !important; box-shadow: none !important; }
.btn-cancel-target:hover:not(:disabled), .btn-close-target:hover:not(:disabled) { background: rgba(220, 38, 38, 0.15) !important; border-color: #DC2626 !important; color: #EFEFEF !important; box-shadow: 0 4px 12px rgba(220, 38, 38, 0.2) !important; transform: translateY(-1px); }

.btn-kill-all, .btn-close-all, .btn-cancel-all { background: rgba(234, 88, 12, 0.05) !important; border: 1px solid rgba(234, 88, 12, 0.4) !important; color: var(--orange-primary) !important; box-shadow: none !important; }
.btn-kill-all:hover:not(:disabled), .btn-close-all:hover:not(:disabled), .btn-cancel-all:hover:not(:disabled) { background: rgba(234, 88, 12, 0.15) !important; border-color: var(--orange-primary) !important; color: #EFEFEF !important; box-shadow: 0 4px 12px rgba(234, 88, 12, 0.2) !important; transform: translateY(-1px); }

.row-ignored-win { background: rgba(26, 42, 64, 0.2) !important; border-left: 3px solid #4B7BBE !important; }
.row-ignored-loss { background: rgba(74, 21, 21, 0.2) !important; border-left: 3px solid #A83F3F !important; }