@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700;800&family=Manrope:wght@400;500;600;700&display=swap');

:root {
    --primary-color: #0d6efd;
    --primary-dark: #0a58ca;
    --primary-light: #3d8bfd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --dark-color: #212529;
    --light-color: #f8f9fa;
    --bg-app: #0b0f16;
    --bg-dark: #1a1d29;
    --bg-darker: #13151f;
    --surface: rgba(19, 21, 31, 0.78);
    --surface-2: rgba(26, 29, 41, 0.75);
    --surface-3: rgba(19, 21, 31, 0.92);
    --text-light: #f8f9fa;
    --text-muted: #adb5bd;
    --border-color: #2d3142;
    --border-soft: rgba(45, 49, 66, 0.7);
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 24px 60px rgba(0, 0, 0, 0.45);
    --radius-sm: 10px;
    --radius-md: 14px;
    --radius-lg: 18px;
    --chart-height: 600px;
    --input-bg: rgba(15, 18, 26, 0.95);
    --input-border: rgba(73, 80, 87, 0.8);
    --background-color: rgba(19, 21, 31, 0.96);
    --text-color: #f8f9fa;
    --primary-rgb: 13, 110, 253;
    --tv-bg: #131722;
    --tv-pane: #1e222d;
    --tv-border: #2a2e39;
    --tv-text: #d1d4dc;
    --tv-text-muted: #787b86;
    --tv-green: #00c853;
    --tv-red: #ff3d00;
    --tv-blue: #2962ff;
    --tv-hover: #2a2e39;
    --asset-item-height: 52px;
}
/* KYC status pill */
.kyc-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid var(--border-soft);
    background: var(--surface-2);
    color: var(--text-light);
    font-weight: 600;
    font-size: 13px;
}
.kyc-status i {
    font-size: 18px;
}
.kyc-status .kyc-action {
    margin-left: 8px;
    padding: 4px 10px;
    border-radius: 999px;
    border: 1px solid var(--border-soft);
    text-decoration: none;
    color: var(--text-light);
    background: rgba(255,255,255,0.04);
}
.kyc-status .kyc-action:hover {
    background: rgba(255,255,255,0.08);
    border-color: var(--primary-color);
    color: var(--primary-color);
}
.kyc-status.kyc-approved {
    background: rgba(25, 135, 84, 0.12);
    border-color: rgba(25, 135, 84, 0.35);
    color: var(--success-color);
}
.kyc-status.kyc-pending {
    background: rgba(255, 193, 7, 0.12);
    border-color: rgba(255, 193, 7, 0.35);
    color: var(--warning-color);
}
.kyc-status.kyc-rejected {
    background: rgba(220, 53, 69, 0.12);
    border-color: rgba(220, 53, 69, 0.35);
    color: var(--danger-color);
}
.profile-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0 18px;
}
.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}
.profile-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px;
}
.profile-hero-left {
    display: flex;
    align-items: center;
    gap: 16px;
}
.profile-identity .profile-email {
    color: var(--text-muted);
}
.settings-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
}
.settings-card .card-body {
    padding: 20px;
}
@media (max-width: 992px) {
    .settings-grid {
        grid-template-columns: 1fr;
    }
    .profile-hero {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Light Theme */
body[data-theme="light"] {
    --primary-color: #0d6efd;
    --primary-dark: #0a58ca;
    --primary-light: #3d8bfd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --dark-color: #212529;
    --light-color: #f8f9fa;
    --bg-app: #ffffff;
    --bg-dark: #f8f9fa;
    --bg-darker: #e9ecef;
    --surface: rgba(255, 255, 255, 0.9);
    --surface-2: rgba(248, 249, 250, 0.95);
    --surface-3: rgba(233, 236, 239, 0.98);
    --text-light: #212529;
    --text-muted: #6c757d;
    --border-color: #dee2e6;
    --border-soft: rgba(222, 226, 230, 0.7);
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 24px 60px rgba(0, 0, 0, 0.15);
    --input-bg: #ffffff;
    --input-border: #ced4da;
    --background-color: #ffffff;
    --text-color: #212529;
}

body[data-theme="light"] {
    background:
        radial-gradient(1200px 600px at 15% 10%, rgba(13, 110, 253, 0.08) 0%, rgba(13, 110, 253, 0) 55%),
        radial-gradient(900px 500px at 85% 20%, rgba(25, 135, 84, 0.06) 0%, rgba(25, 135, 84, 0) 60%),
        radial-gradient(900px 700px at 70% 90%, rgba(220, 53, 69, 0.04) 0%, rgba(220, 53, 69, 0) 60%),
        linear-gradient(180deg, var(--bg-app) 0%, #f8f9fa 60%, #e9ecef 100%);
}

/* Dark Theme */
body[data-theme="dark"] {
    --primary-color: #0d6efd;
    --primary-dark: #0a58ca;
    --primary-light: #3d8bfd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --dark-color: #212529;
    --light-color: #f8f9fa;
    --bg-app: #0d1117;
    --bg-dark: #161b22;
    --bg-darker: #010409;
    --surface: rgba(22, 27, 34, 0.95);
    --surface-2: rgba(13, 17, 23, 0.98);
    --surface-3: rgba(1, 4, 9, 0.99);
    --text-light: #f0f6fc;
    --text-muted: #8b949e;
    --border-color: #30363d;
    --border-soft: rgba(48, 54, 61, 0.7);
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 24px 60px rgba(0, 0, 0, 0.7);
    --input-bg: #0d1117;
    --input-border: #30363d;
    --background-color: #0d1117;
    --text-color: #f0f6fc;
    background:
        radial-gradient(1200px 600px at 15% 10%, rgba(138, 43, 226, 0.15) 0%, rgba(138, 43, 226, 0) 55%),
        radial-gradient(900px 500px at 85% 20%, rgba(75, 0, 130, 0.12) 0%, rgba(75, 0, 130, 0) 60%),
        radial-gradient(900px 700px at 70% 90%, rgba(72, 61, 139, 0.08) 0%, rgba(72, 61, 139, 0) 60%),
        linear-gradient(180deg, var(--bg-app) 0%, #161b22 60%, #010409 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background:
        radial-gradient(1200px 600px at 15% 10%, rgba(13, 110, 253, 0.18) 0%, rgba(13, 110, 253, 0) 55%),
        radial-gradient(900px 500px at 85% 20%, rgba(25, 135, 84, 0.14) 0%, rgba(25, 135, 84, 0) 60%),
        radial-gradient(900px 700px at 70% 90%, rgba(220, 53, 69, 0.10) 0%, rgba(220, 53, 69, 0) 60%),
        linear-gradient(180deg, var(--bg-app) 0%, #0d1117 60%, #0a0e14 100%);
    color: var(--text-light);
    line-height: 1.6;
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6,
.panel-title,
.app-header-title,
.app-logo-title,
.page-title,
.nav-section-title {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-weight: 700;
}

.app-layout {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    min-height: 100vh;
}

.app-sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    padding: 18px 14px;
    background: var(--bg-dark);
    border-right: 1px solid var(--border-color);
    box-shadow: 0 0 24px rgba(0,0,0,0.25);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.sidebar-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.sidebar-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    background: var(--bg-darker);
    color: var(--text-light);
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}
.sidebar-nav .nav-link:hover {
    background: #0f1420;
    color: #ffffff;
}
.sidebar-nav .nav-link.active {
    background: #0c1220;
    border-color: rgba(13,110,253,0.45);
    box-shadow: 0 10px 24px rgba(13,110,253,0.18);
    color: #4dabf7;
    font-weight: 700;
}

.sidebar-account {
    margin-top: auto;
    background: var(--surface-3);
    border: 1px solid var(--border-soft);
    border-radius: 12px;
    padding: 10px;
    position: relative;
}
.sidebar-account-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    background: transparent;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    padding: 4px 2px;
}
.sidebar-account-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(13, 110, 253, 1), rgba(61, 139, 253, 1));
    color: #fff;
    font-weight: 700;
}
.sidebar-account-name {
    flex: 1;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.sidebar-account .dropdown-menu {
    position: absolute;
    bottom: calc(100% + 8px);
    top: auto;
    right: 0;
    left: auto;
    z-index: 1100;
    display: none;
    min-width: 160px;
    background: var(--bg-dark);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    color: var(--text-light);
}
.sidebar-account .dropdown-menu.show {
    display: block;
    color: var(--text-light);
    background: var(--bg-dark);
}
.sidebar-account .dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 10px 12px;
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    transition: background 0.2s;
    font-size: 14px;
}
.sidebar-account .dropdown-item i {
    color: var(--text-light);
}
.sidebar-account .dropdown-item:hover {
    background: var(--surface-2);
}
.app-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--radius-md);
    text-decoration: none;
    color: var(--text-light);
    background: linear-gradient(135deg, rgba(13, 110, 253, 0.12) 0%, rgba(13, 110, 253, 0.02) 65%);
    border: 1px solid rgba(13, 110, 253, 0.22);
}

.app-logo-mark {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(13, 110, 253, 1) 0%, rgba(61, 139, 253, 1) 100%);
    box-shadow: 0 14px 35px rgba(13, 110, 253, 0.24);
}

.app-logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.05;
}

.app-logo-title {
    font-weight: 800;
    letter-spacing: 0.2px;
}

.app-logo-subtitle {
    font-size: 12px;
    color: var(--text-muted);
}

.nav-section-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted);
    margin: 16px 12px 8px;
    font-weight: 600;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: var(--radius-sm);
    transition: all 0.2s;
    font-weight: 500;
    font-size: 14px;
    position: relative;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #ffffff;
}

.nav-link.active {
    background: linear-gradient(135deg, rgba(13, 110, 253, 0.25), rgba(61, 139, 253, 0.15));
    color: #4dabf7;
    font-weight: 700;
    box-shadow: 0 10px 24px rgba(13, 110, 253, 0.18);
}

.nav-link i {
    font-size: 18px;
}

.app-main {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.app-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.0));
    border-bottom: 1px solid var(--border-soft);
    padding: 12px 16px;
    border-radius: var(--radius-md);
}

.app-header-title {
    font-size: 20px;
    font-weight: 700;
}

.app-header .app-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-menu-btn {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--surface-2);
    border: 1px solid var(--border-soft);
    color: var(--text-light);
}

.balance-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, rgba(13, 110, 253, 0.18), rgba(13, 110, 253, 0.08));
    border: 1px solid rgba(13, 110, 253, 0.25);
    padding: 8px 12px;
    border-radius: 12px;
    box-shadow: 0 8px 18px rgba(13, 110, 253, 0.15);
}
.balance-label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 600;
}
.balance-value {
    font-size: 18px;
    font-weight: 800;
    color: var(--text-light);
}

.theme-lang-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.theme-dropdown-toggle,
.lang-dropdown-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--surface-3);
    border: 1px solid var(--border-soft);
    color: var(--text-light);
    padding: 8px 12px;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.theme-dropdown-toggle:hover,
.lang-dropdown-toggle:hover {
    background: rgba(255,255,255,0.06);
}
.theme-dropdown-menu,
.lang-dropdown-menu,
.dropdown-menu {
    background: var(--surface-3);
    border: 1px solid var(--border-soft);
    border-radius: 10px;
    padding: 6px;
    min-width: 160px;
}
.dropdown-menu {
    display: none;
    position: absolute;
    z-index: 1000;
}
.dropdown-menu.show {
    display: block;
}
.header {
    display:flex;
    justify-content:space-between;
    align-items:center;
    padding:16px 24px;
    flex-wrap:wrap;
    gap:12px;
}
.brand {
    display:flex;
    align-items:center;
    gap:10px;
    text-decoration:none;
    color: var(--text-light);
}
.brand-mark {
    width:34px;
    height:34px;
    border-radius:12px;
    background: linear-gradient(135deg, rgba(13,110,253,1), rgba(61,139,253,1));
    box-shadow: 0 14px 35px rgba(13,110,253,.24);
}
.brand-title { font-weight:800; }
.theme-lang-actions { display:flex; align-items:center; gap:8px; }
.hero { padding:64px 24px; text-align:center; }
.hero h1 { font-size:42px; margin-bottom:12px; }
.hero p { color: var(--text-muted); font-size:18px; }
.actions { display:flex; gap:12px; justify-content:center; margin-top:24px; }
.actions a { display:inline-block; padding:12px 18px; border-radius:12px; text-decoration:none; font-weight:700; }
.btn-primary { background: var(--primary-color); color:#fff; }
.btn-secondary { background: var(--surface-2); color: var(--text-light); border:1px solid var(--border-soft); }
.stats { display:grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap:16px; padding:24px; max-width:1000px; margin:0 auto; }
.stat { background: var(--surface-3); border:1px solid var(--border-soft); border-radius:14px; padding:18px; box-shadow: var(--shadow); }
.stat-title { font-size:12px; color: var(--text-muted); text-transform:uppercase; letter-spacing:0.6px; }
.stat-value { font-size:32px; font-weight:800; margin-top:8px; }
.section { padding:40px 24px; max-width:1100px; margin:0 auto; }
.section h2 { font-size:28px; margin-bottom:12px; }
.section p.sub { color: var(--text-muted); }
.feature-grid { display:grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap:16px; margin-top:18px; }
.feature { background: var(--surface-3); border:1px solid var(--border-soft); border-radius:14px; padding:18px; display:flex; gap:12px; align-items:flex-start; }
.feature i { font-size:22px; }
.feature-title { font-weight:800; }
.feature-sub { color: var(--text-muted); }
.faq { display:grid; gap:10px; margin-top:18px; }
.faq details { background: var(--surface-3); border:1px solid var(--border-soft); border-radius:12px; padding:12px 14px; }
.faq summary { cursor:pointer; font-weight:700; }
.testimonials { padding:24px; }
.testimonial-slider { overflow:hidden; }
.slider-track { display:flex; gap:16px; animation: slide 40s linear infinite; }
.testimonial { min-width:280px; flex:0 0 auto; background: var(--surface-3); border:1px solid var(--border-soft); border-radius:14px; padding:16px; }
@keyframes slide { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
.footer { margin-top:auto; padding:24px; text-align:center; color: var(--text-muted); }
@media (max-width: 768px) {
    .hero h1 { font-size:32px; }
    .hero p { font-size:16px; }
}

/* Home page improvements */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}
.home-hero {
    padding: 48px 20px;
    text-align: center;
}
.hero-banner {
    padding: 72px 0;
    background:
        radial-gradient(1200px 600px at 100% -100%, rgba(13,110,253,.25), transparent 70%),
        linear-gradient(180deg, rgba(13,110,253,.08), rgba(13,110,253,0));
}
.hero-grid {
    display: grid;
    grid-template-columns: 1.25fr 1fr;
    align-items: center;
    gap: 24px;
}
.hero-banner .hero-text {
    text-align: start;
}
.hero-banner .actions {
    justify-content: flex-start;
}
.hero-art {
    height: 280px;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(13,110,253,.35), rgba(61,139,253,.35));
    border: 1px solid var(--border-soft);
    box-shadow: 0 18px 40px rgba(13,110,253,.25);
}
.home-hero .actions {
    flex-wrap: wrap;
}
.home-stats {
    padding: 20px;
    gap: 12px;
}
.home-stats .container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
}
.home-section {
    padding: 28px 20px;
    max-width: 1100px;
    margin: 0 auto;
}
.testimonial {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.testimonial .stars {
    display: inline-flex;
    gap: 2px;
}
.testimonial .star {
    color: #ffc107;
    font-size: 16px;
}
.testimonial .author {
    color: var(--text-muted);
    font-size: 13px;
}
.feature-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.feature {
    align-items: center;
}
.feature-title {
    font-weight: 800;
}
.feature-sub {
    color: var(--text-muted);
}
@media (max-width: 992px) {
    .hero-grid {
        grid-template-columns: 1fr;
    }
    .hero-art {
        display: none;
    }
    .hero-banner .hero-text {
        text-align: center;
    }
    .hero-banner .actions {
        justify-content: center;
    }
}
@media (max-width: 576px) {
    .header {
        padding: 12px 14px;
    }
    .theme-lang-actions {
        width: 100%;
        justify-content: center;
        gap: 6px;
    }
    .actions {
        gap: 8px;
    }
    .testimonial {
        min-width: 240px;
    }
}
.theme-dropdown-item,
.lang-dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 8px 10px;
    border: none;
    background: transparent;
    color: var(--text-light);
    border-radius: 8px;
    cursor: pointer;
}
.theme-dropdown-item:hover,
.lang-dropdown-item:hover {
    background: rgba(255,255,255,0.06);
}
.lang-dropdown-flag {
    width: 18px;
    height: 18px;
    border-radius: 3px;
    object-fit: cover;
}

.app-content-grid {
    display: grid;
    grid-template-columns: 320px 1fr 340px;
    grid-template-rows: auto 1fr;
    gap: 24px;
    grid-template-areas:
        "market chart trade"
        "positions positions positions";
    height: calc(100vh - 100px); /* Adjust based on header height */
}

.market-container { grid-area: market; height: 100%; }
.chart-container { grid-area: chart; height: 100%; }
.trade-container { grid-area: trade; height: 100%; }
.positions-container { grid-area: positions; }


.chart-container {
    grid-area: chart;
    background: transparent;
    border-radius: var(--radius-lg);
    border: none;
    display: flex;
    flex-direction: column;
}

.trade-panel {
    grid-area: trade;
    background: var(--surface-2);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-soft);
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.market-watch-panel {
    grid-area: market;
    background: var(--surface-2);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-soft);
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.open-positions-panel {
    grid-area: positions;
    background: var(--surface-2);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-soft);
    padding: 20px;
}

/* Panel Styles */
.panel-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 16px;
}

/* Chart Header */
.chart-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    border-bottom: 1px solid var(--border-soft);
}
.asset-label {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-light);
}
.asset-price-live {
    display: flex;
    align-items: baseline;
    gap: 8px;
}
.price-value {
    font-size: 18px;
    font-weight: 700;
}
.price-change {
    font-size: 14px;
    font-weight: 500;
}
.price-change.positive { color: var(--tv-green); }
.price-change.negative { color: var(--tv-red); }

#tradingview-chart {
    flex: 1;
    height: auto;
    min-height: 0;
}

.trade-type-toggle {
    display: flex;
    gap: 8px;
}
.trade-type-toggle .btn {
    flex: 1;
    font-weight: 700;
}
.trade-type-toggle .btn.active {
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.15);
}

.trade-hints {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

@media (max-width: 992px) {
    .market-watch-panel .panel-header {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    .search-box {
        width: 100%;
        max-width: 100%;
    }
}

/* Trade Panel - Yeni Tasarım */
.trade-panel {
    background: var(--surface-2);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-soft);
    padding: 24px;
    box-shadow: var(--shadow);
}

.trade-panel .panel-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 24px;
    color: var(--text-light);
    text-align: center;
}

.trade-input-group {
    margin-bottom: 16px;
}

.trade-input-group label {
    display: block;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 6px;
    font-weight: 500;
}

.trade-input-group input {
    width: 100%;
    padding: 12px 14px;
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: var(--radius-sm);
    color: var(--text-light);
    font-size: 14px;
    transition: all 0.2s ease;
}

.trade-input-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
}

/* Checkbox'lı SL/TP Stilleri */
.sl-tp-container {
    margin-bottom: 16px;
}

.sl-tp-checkbox {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    cursor: pointer;
}

.sl-tp-checkbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin-right: 8px;
    accent-color: var(--primary-color);
}

.sl-tp-checkbox label {
    font-size: 13px;
    color: var(--text-muted);
    cursor: pointer;
    user-select: none;
}

.sl-tp-input {
    display: none;
    margin-top: 8px;
}

.sl-tp-input.show {
    display: block;
}

/* Execute Trade Butonu */
.btn-execute-trade {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    margin-top: 24px;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(13, 110, 253, 0.3);
}

.btn-execute-trade:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(13, 110, 253, 0.4);
}

.btn-execute-trade:active {
    transform: translateY(0);
}

/* Market Watch Panel */
.market-watch-panel .panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-soft);
}

.search-box {
    position: relative;
    width: 220px;
    max-width: 40%;
}
.search-box i {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 14px;
}
.search-box input {
    background: var(--input-bg);
    border: 1px solid var(--input-border);
    border-radius: var(--radius-sm);
    padding: 8px 12px 8px 34px;
    color: var(--text-light);
    font-size: 13px;
    width: 100%;
    transition: all 0.2s ease;
}
.search-box input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.1);
}

.asset-list {
    flex: 1;
    overflow-y: auto;
    padding-right: 4px;
    max-height: none;
    min-height: 0;
}

.market-watch-panel .asset-item {
    height: var(--asset-item-height);
    padding: 8px 12px;
    display: grid;
    grid-template-columns: 1fr 120px;
    column-gap: 8px;
    align-items: center;
}
.market-watch-panel .asset-list {
    max-height: calc(var(--asset-item-height) * 10);
    overflow-y: auto;
}
.asset-list::-webkit-scrollbar {
    width: 6px;
}
.asset-list::-webkit-scrollbar-track {
    background: transparent;
}
.asset-list::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 3px;
}
.asset-list::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

.asset-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 2px;
    border-left: 3px solid transparent;
}
.asset-item:hover {
    background: rgba(255, 255, 255, 0.03);
    transform: translateX(2px);
}
.asset-item.active {
    background: rgba(13, 110, 253, 0.08);
    border-left: 3px solid var(--primary-color);
}

.asset-info {
    flex: 1;
    min-width: 0;
    text-align: left;
}

.asset-symbol-name {
    display: flex;
    flex-direction: column;
    gap: 2px;
    align-items: flex-start;
}

.asset-symbol {
    font-weight: 700;
    font-size: 13px;
    color: var(--text-light);
    font-family: 'JetBrains Mono', monospace;
    line-height: 1.2;
}

.asset-name {
    font-size: 10px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 110px;
}

.asset-pricing {
    text-align: right;
    min-width: 120px;
}

.asset-price {
    font-weight: 600;
    font-size: 12px;
    font-family: 'JetBrains Mono', monospace;
    display: block;
    margin-bottom: 2px;
    line-height: 1.1;
    color: var(--text-light);
    white-space: nowrap;
}

.asset-change {
    font-size: 10px;
    font-weight: 500;
    padding: 1px 4px;
    border-radius: 4px;
    display: inline-block;
    line-height: 1.1;
}

@media (max-width: 992px) {
    .market-watch-panel .asset-item {
        grid-template-columns: 1fr 110px;
    }
    .asset-pricing {
        min-width: 110px;
    }
}

.asset-change.positive {
    color: var(--success-color);
    background: rgba(25, 135, 84, 0.1);
}

.asset-change.negative {
    color: var(--danger-color);
    background: rgba(220, 53, 69, 0.1);
}

/* Open Positions Panel */
.trading-table {
    width: 100%;
    border-collapse: collapse;
}
.trading-table th, .trading-table td {
    padding: 12px 10px;
    text-align: left;
    border-bottom: 1px solid var(--border-soft);
}
.trading-table th {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
}
.trading-table .buy { color: var(--tv-green); }
.trading-table .sell { color: var(--tv-red); }
.btn-close-trade {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
}
.btn-close-trade:hover {
    color: var(--tv-red);
}

@media (max-width: 1200px) {
    .app-content-grid {
        grid-template-columns: 1fr;
        grid-template-areas:
            "chart"
            "trade"
            "market"
            "positions";
    }
}

@media (max-width: 768px) {
    .app-layout {
        grid-template-columns: 1fr;
    }
    .app-sidebar {
        position: fixed;
        left: -290px;
        top: 0;
        height: 100%;
        z-index: 1000;
        transition: left 0.3s;
    }
    .app-sidebar.open {
        left: 0;
    }
    .sidebar-toggle-btn {
        position: fixed;
        top: 12px;
        left: 12px;
        width: 40px;
        height: 40px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 10px;
        background: var(--surface-2);
        border: 1px solid var(--border-soft);
        color: var(--text-light);
        z-index: 1100;
        box-shadow: var(--shadow);
    }
    .app-main {
        padding: 16px;
    }
    .app-header-title {
        display: none;
    }
    .header-menu-btn {
        display: inline-flex;
    }
}

.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 900;
    display: none;
}
.sidebar-overlay.show {
    display: block;
}

.app-content-panel {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.panel-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.trading-table {
    width: 100%;
    border-collapse: collapse;
}

.trading-table th, .trading-table td {
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
    font-size: 14px;
}

.trading-table th {
    font-weight: 600;
    color: var(--text-secondary);
}

.trading-table td {
    color: var(--text-primary);
}

.trading-table .buy { color: var(--success-color); }
.trading-table .sell { color: var(--danger-color); }
.trading-table .positive { color: var(--success-color); }
.trading-table .negative { color: var(--danger-color); }

.btn-close-trade {
    background: var(--danger-color-muted);
    color: var(--danger-color);
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-close-trade:hover {
    background: var(--danger-color);
    color: #fff;
}

.form-modern .form-group {
    margin-bottom: 20px;
}

.form-modern .form-label {
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-muted);
}

.form-modern .form-control {
    background: var(--input-bg);
    border: 1px solid var(--border-soft);
    border-radius: 8px;
    padding: 12px 16px;
    color: var(--text-light);
    transition: all 0.2s ease;
}

.form-modern .form-control:focus {
    background: var(--card-bg);
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-color-muted);
}

.address-display-box {
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 20px;
}

.address-display-box label {
    font-weight: 600;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 8px;
}

.address-text {
    font-family: monospace;
    color: var(--primary-color);
    word-break: break-all;
}

.balance-display-box {
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 20px;
}

.balance-display-box label {
    font-weight: 600;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
}

.balance-amount {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    font-family: 'JetBrains Mono', monospace;
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: capitalize;
}

.status-badge.deposit, .status-badge.approved {
    background: var(--success-color-muted);
    color: var(--success-color);
}

.status-badge.withdraw, .status-badge.rejected {
    background: var(--danger-color-muted);
    color: var(--danger-color);
}

.status-badge.pending {
    background: var(--warning-color-muted);
    color: var(--warning-color);
}



.sidebar-toggle-btn {
    display: none;
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 1001;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 24px;
}

@media (max-width: 768px) {
    .sidebar-toggle-btn {
        display: block;
    }
}

.page-header {
    display: flex;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-soft);
}

.page-title {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Dashboard Grid System */
.dashboard-grid {
    display: grid;
    grid-template-columns: 320px 1fr 340px; /* Asset List | Chart | Trade Panel */
    gap: 20px;
    height: calc(100vh - 140px);
    min-height: 600px;
}

/* Common Card Style */
.card {
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow);
    color: var(--text-light);
}

.card-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-soft);
    font-weight: 600;
    font-size: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--surface-2);
    color: var(--text-light);
}

.card-body {
    padding: 20px;
    flex: 1;
    overflow-y: auto;
}

/* Asset List Styles */
.asset-list-container {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.asset-search-box {
    padding: 12px;
    border-bottom: 1px solid var(--border-soft);
}

.asset-list {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

.asset-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border-soft);
    cursor: pointer;
    transition: background 0.2s;
}

.asset-item:hover {
    background: rgba(255, 255, 255, 0.03);
}

.asset-item.active {
    background: rgba(13, 110, 253, 0.1);
    border-left: 3px solid var(--primary-color);
}

.asset-info h4 {
    font-size: 15px;
    margin-bottom: 4px;
    color: var(--text-light);
}

.asset-info span {
    font-size: 12px;
    color: var(--text-muted);
}

.asset-price-box {
    text-align: right;
}

.asset-price {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
    font-size: 13px;
    display: block;
    margin-bottom: 4px;
}

.asset-change {
    font-size: 13px;
    font-weight: 500;
}

.asset-change.positive { color: var(--success-color); }
.asset-change.negative { color: var(--danger-color); }

/* Chart Area */
.chart-container {
    height: 100%;
    width: 100%;
    background: var(--bg-darker);
    position: relative;
}

/* Trade Panel */
.trade-panel {
    padding: 20px;
}

.trade-form-group {
    margin-bottom: 16px;
}

.trade-label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    color: var(--text-muted);
}

.trade-input {
    width: 100%;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-soft);
    padding: 12px;
    border-radius: var(--radius-sm);
    color: var(--text-light);
    font-family: 'JetBrains Mono', monospace;
}

.trade-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 24px;
}

.btn-trade {
    padding: 14px;
    border-radius: var(--radius-sm);
    border: none;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s, opacity 0.2s;
}

.btn-trade:hover { opacity: 0.9; }
.btn-trade:active { transform: scale(0.98); }

.btn-buy { background: var(--success-color); }
.btn-sell { background: var(--danger-color); }

/* Bottom Section - Tables */
.bottom-section {
    margin-top: 24px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    text-align: left;
    padding: 12px 16px;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 13px;
    border-bottom: 1px solid var(--border-soft);
}

.data-table td {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 14px;
}

.data-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

/* Utility Classes */
.text-success { color: var(--success-color) !important; }
.text-danger { color: var(--danger-color) !important; }
.fw-bold { font-weight: 600; }
.d-flex { display: flex; }
.justify-between { justify-content: space-between; }
.items-center { align-items: center; }
.gap-2 { gap: 8px; }

/* Responsive */
@media (max-width: 1200px) {
    .dashboard-grid {
        grid-template-columns: 280px 1fr;
        grid-template-rows: 1fr auto;
    }
    .trade-panel-container {
        grid-column: 1 / -1;
        height: auto;
    }
}

@media (max-width: 992px) {
    .app-layout {
        grid-template-columns: 1fr;
    }
    .app-sidebar {
        display: block;
    }
    .dashboard-grid {
        grid-template-columns: 1fr;
        height: auto;
        display: flex;
        flex-direction: column;
    }
    .chart-container {
        height: 400px;
    }
}

/* Modal Styling */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal-backdrop {
    z-index: 1990 !important;
    backdrop-filter: blur(3px);
}

.modal.active {
    display: flex;
    animation: fadeIn 0.2s ease;
}

.modal-content {
    background: var(--bg-dark);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-md);
    width: 100%;
    max-width: 450px;
}

/* New Dropdown Styles */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1000;
    display: none;
    min-width: 10rem;
    padding: .5rem 0;
    margin: .125rem 0 0;
    font-size: 1rem;
    color: var(--text-light);
    text-align: left;
    list-style: none;
    background-color: var(--bg-dark);
    background-clip: padding-box;
    border: 1px solid var(--border-soft);
    border-radius: .25rem;
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.15s ease-in-out, transform 0.15s ease-in-out;
    pointer-events: none;
}

.dropdown-menu.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

/* Ensure JS 'active' class also shows dropdowns */
.dropdown-menu.active {
    display: block;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 1000;
    display: none;
    min-width: 10rem;
    padding: .5rem 0;
    margin: .125rem 0 0;
    font-size: 1rem;
    color: var(--text-light);
    text-align: left;
    list-style: none;
    background-color: var(--bg-dark);
    background-clip: padding-box;
    border: 1px solid var(--border-soft);
    border-radius: .25rem;
    color: var(--text-light);
}

.dropdown-menu.show {
    display: block;
    box-shadow: var(--shadow-xl);
    color: var(--text-light);
    background-color: var(--bg-dark);
}

.modal-header {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-soft);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-muted);
}

.form-control {
    width: 100%;
    padding: 10px 14px;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    color: var(--text-light);
    margin-bottom: 12px;
}

.btn {
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    border: none;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
}

.btn-primary { background: var(--primary-color); color: white; }
.btn-secondary { background: var(--secondary-color); color: white; }
.btn-danger { background: var(--danger-color); color: white; }
.btn-sm { padding: 6px 12px; font-size: 13px; }

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    background: var(--bg-dark);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    animation: slideIn 0.3s ease;
}

.toast-success { border-left: 4px solid var(--success-color); }
.toast-error { border-left: 4px solid var(--danger-color); }

.price-tick {
    transition: background-color 0.3s ease;
}

.price-tick-up {
    background-color: rgba(0, 192, 111, 0.3) !important;
}

.price-tick-down {
    background-color: rgba(255, 95, 95, 0.3) !important;
@keyframes slideIn {
}

/* FAdmin Specific Styles */
.stat-card {
    display: flex;
    align-items: center;
    background: var(--surface-2);
    border-radius: var(--radius-md);
    padding: 24px;
    gap: 20px;
    border: 1px solid var(--border-soft);
}

.stat-card-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #fff;
}

.stat-card-title {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.stat-card-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-light);
}

.overview-item h6 {
    font-size: 16px;
    color: var(--text-muted);
    font-weight: 500;
}
.profile-container {
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.profile-header {
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    background: var(--surface-2);
    padding: 20px;
}
.profile-header-inner {
    display: flex;
    align-items: center;
    gap: 16px;
}
.profile-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(13,110,253,0.9), rgba(61,139,253,0.7));
    color: #fff;
    font-weight: 800;
    font-size: 26px;
    box-shadow: 0 12px 28px rgba(13,110,253,0.25);
}
.profile-identifiers {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.profile-name {
    font-size: 22px;
    font-weight: 800;
}
.profile-email {
    color: var(--text-muted);
    font-size: 14px;
}
.form-modern .form-control::placeholder {
    color: var(--text-muted);
}
.form-modern .form-control:focus {
    outline: none;
    border-color: var(--primary-light);
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.2);
}
.profile-badges {
    margin-top: 6px;
}
.profile-card {
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    background: var(--surface-2);
}
.form-modern .form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.profile-actions {
    margin-top: 18px;
    border-top: 1px solid var(--border-color);
    padding-top: 18px;
}
@media (max-width: 992px) {
    .profile-header-inner {
        flex-direction: column;
        align-items: flex-start;
    }
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-color);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.user-name {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-light);
}

.user-email {
    font-size: 12px;
    color: var(--text-muted);
}

.btn-logout {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    text-decoration: none;
    margin-top: 10px;
}

.btn-logout:hover {
    background: rgba(220, 53, 69, 0.15);
    color: var(--danger-color);
}
   from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* Theme and Language Selector Styles */
.app-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.theme-selector {
    position: relative;
}

.theme-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    color: var(--text-light);
    cursor: pointer;
    transition: all 0.2s;
    font-size: 14px;
}

.theme-dropdown-btn:hover {
    background: var(--surface-2);
    border-color: var(--border-color);
}

.theme-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    left: auto;
    margin-top: 4px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    display: none;
    min-width: 140px;
    z-index: 1000;
}

.theme-dropdown-menu.active {
    display: block;
}

.theme-dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 10px 12px;
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    transition: background 0.2s;
    font-size: 14px;
}

.theme-dropdown-item:hover {
    background: var(--surface-2);
}

.theme-dropdown-item:first-child {
    border-radius: var(--radius-sm) var(--radius-sm) 0 0;
}

.theme-dropdown-item:last-child {
    border-radius: 0 0 var(--radius-sm) var(--radius-sm);
}

.theme-icon {
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Language Dropdown Enhancements */
.lang-dropdown {
    position: relative;
}

.lang-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    color: var(--text-light);
    cursor: pointer;
    transition: all 0.2s;
    font-size: 14px;
}

.lang-dropdown-btn:hover {
    background: var(--surface-2);
    border-color: var(--border-color);
}

.lang-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    left: auto;
    margin-top: 4px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    display: none;
    min-width: 120px;
    z-index: 1000;
}

.lang-dropdown-menu.active {
    display: block;
}

.lang-dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 10px 12px;
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    transition: background 0.2s;
    font-size: 14px;
}

.lang-dropdown-item:hover {
    background: var(--surface-2);
}

.lang-dropdown-flag {
    width: 16px;
    height: 12px;
    border-radius: 2px;
}

/* Auth Page Theme and Language Selectors */
.auth-card .theme-selector,
.auth-card .lang-dropdown {
    position: relative;
}

.auth-card .theme-dropdown-btn,
.auth-card .lang-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 5px 8px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    color: var(--text-light);
    cursor: pointer;
    transition: all 0.2s;
    font-size: 12px;
}

.auth-card .theme-dropdown-btn:hover,
.auth-card .lang-dropdown-btn:hover {
    background: var(--surface-2);
    border-color: var(--border-color);
}

.auth-card .theme-dropdown-menu,
.auth-card .lang-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: auto;
    margin-top: 4px;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    display: none;
    min-width: 140px;
    z-index: 1000;
}

@media (max-width: 576px) {
    .auth-card .theme-dropdown-menu,
    .auth-card .lang-dropdown-menu {
        left: 0;
        transform: none;
        right: auto;
        min-width: 100px;
    }
}

.auth-card .theme-dropdown-menu.active,
.auth-card .lang-dropdown-menu.active {
    display: block;
}

.auth-card .theme-dropdown-item,
.auth-card .lang-dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 6px 10px;
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    transition: background 0.2s;
    font-size: 12px;
}

.auth-card .theme-dropdown-item:hover,
.auth-card .lang-dropdown-item:hover {
    background: var(--surface-2);
}

/* RTL Support */
body[dir="rtl"] .theme-dropdown-menu,
body[dir="rtl"] .lang-dropdown-menu {
    right: auto;
    left: 0;
}

body[dir="rtl"] .theme-dropdown-item,
body[dir="rtl"] .lang-dropdown-item {
    flex-direction: row-reverse;
}

body[data-theme='light'] .auth-wrapper {
    background-color: #f8f9fa;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(138, 43, 226, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(75, 0, 130, 0.02) 0%, transparent 50%);
}

body[data-theme='dark'] .auth-wrapper {
    background-color: var(--tv-bg);
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(138, 43, 226, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(75, 0, 130, 0.05) 0%, transparent 50%);
}

.auth-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    width: 100%;
    padding: 1rem;
}

.auth-card {
    max-width: 480px;
    width: 100%;
    border: none;
    border-radius: 1rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    background-color: var(--background-color);
    color: var(--text-color);
}

body[data-theme='dark'] .auth-card {
    background-color: var(--tv-pane);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.auth-card .card-body {
    padding: 2.5rem;
}

@media (max-width: 576px) {
    .auth-card .card-body {
        padding: 1.5rem;
    }
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-logo {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
    margin-bottom: 0.5rem;
    display: block;
}

body[data-theme='dark'] .auth-logo {
    color: var(--tv-text);
}

.auth-welcome-text {
    color: var(--text-muted);
}

body[data-theme='dark'] .auth-welcome-text {
    color: var(--tv-text-muted);
}

.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    color: var(--text-muted);
}

body[data-theme='dark'] .auth-footer {
    color: var(--tv-text-muted);
}

.auth-footer a {
    color: var(--primary-color);
    font-weight: 500;
    text-decoration: none;
}

.auth-controls {
    position: relative;
    z-index: 10;
}

@media (max-width: 576px) {
    .auth-controls {
        gap: 0.5rem !important;
    }
    
    .auth-controls .theme-dropdown-btn,
    .auth-controls .lang-dropdown-btn {
        padding: 4px 8px;
        font-size: 12px;
    }
    
    .auth-controls .theme-icon,
    .auth-controls .lang-dropdown-flag {
        width: 16px;
        height: 16px;
    }
}

body[data-theme='dark'] .auth-footer a {
    color: var(--tv-blue);
}

.auth-footer a:hover {
    text-decoration: underline;
}

.password-wrapper {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 1rem;
    top: 2.75rem;
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.5rem;
    font-size: 1.2rem;
    z-index: 10;
}

body[data-theme='dark'] .password-toggle {
    color: var(--tv-text-muted);
}

.password-toggle:hover {
    color: var(--primary-color);
}

body[data-theme='dark'] .password-toggle:hover {
    color: var(--tv-blue);
}

/* KYC Page Styles */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 24px;
}

.kyc-card {
    display: flex;
    flex-direction: column;
}

.kyc-card .panel-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.kyc-card .user-info .panel-title {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.kyc-card .user-info .user-email {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin: 0;
}

.kyc-card .submission-date {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.kyc-documents {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
    flex-grow: 1;
}

.document-item p {
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-secondary);
}

.document-image {
    width: 100%;
    height: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-soft);
    object-fit: cover;
}

.kyc-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border-soft);
}

.kyc-actions .btn {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Transaction Page Styles */
.detail-cell {
    display: flex;
    flex-direction: column;
}

.detail-label {
    font-weight: 500;
    color: var(--text-primary);
}

.detail-value {
    font-size: 0.85rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.action-buttons {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

.btn-icon {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    background-color: transparent;
    border: 1px solid var(--border-soft);
    color: var(--text-secondary);
    font-size: 20px;
    transition: all 0.2s ease;
}

.btn-icon:hover {
    background-color: var(--surface-3);
    border-color: var(--border-strong);
}

.btn-icon-success {
    color: var(--green-500);
    border-color: var(--green-200);
}

.btn-icon-success:hover {
    background-color: var(--green-50);
    border-color: var(--green-300);
    color: var(--green-600);
}

.btn-icon-danger {
    color: var(--red-500);
    border-color: var(--red-200);
}

.btn-icon-danger:hover {
    background-color: var(--red-50);
    border-color: var(--red-300);
    color: var(--red-600);
}

.badge-success {
    background-color: var(--green-100);
    color: var(--green-700);
    font-weight: 500;
}

.badge-warning {
    background-color: var(--orange-100);
    color: var(--orange-700);
    font-weight: 500;
}

.rejection-summary {
    background-color: var(--surface-2);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    margin-top: 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 0.9rem;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 64px 32px;
    text-align: center;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 64px;
    margin-bottom: 24px;
    color: var(--brand-300);
}

.empty-state h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.empty-state p {
    max-width: 300px;
    margin: 0 auto;
}

/* Finance pages (Deposit / Withdraw) */
.finance-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
@media (max-width: 992px) {
    .finance-grid {
        grid-template-columns: 1fr;
    }
}

.balance-card {
    background: var(--surface-2);
    border: 1px solid var(--border-soft);
    border-radius: 12px;
    padding: 16px;
    box-shadow: var(--shadow);
}
.balance-card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}
.balance-icon {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(13,110,253,0.18), rgba(13,110,253,0.08));
    border: 1px solid rgba(13,110,253,0.25);
    color: var(--text-light);
}
.balance-card .balance-amount {
    font-size: 32px;
    font-weight: 800;
    color: var(--text-light);
}
.balance-subtitle {
    margin-top: 6px;
    font-size: 13px;
    color: var(--text-muted);
}

.pay-methods {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 12px;
}
@media (max-width: 992px) {
    .pay-methods {
        grid-template-columns: repeat(2, 1fr);
    }
}
.pay-method-card {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    border: 1px solid var(--border-soft);
    border-radius: 10px;
    background: var(--surface-3);
    color: var(--text-light);
    cursor: pointer;
    transition: all 0.2s ease;
}
.pay-method-card:hover {
    background: rgba(255,255,255,0.06);
}
.pay-method-card.active {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(13, 110, 253, 0.15);
}
.pay-method-card .label {
    font-weight: 700;
}

.address-display-box {
    position: relative;
}
.address-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}
.btn-copy {
    padding: 6px 10px;
    border-radius: 8px;
    background: transparent;
    border: 1px solid var(--border-soft);
    color: var(--text-light);
    cursor: pointer;
}
.btn-copy:hover {
    background: rgba(255,255,255,0.06);
}

/* Finance page layout: 2 columns */
.finance-page-grid {
    display: grid;
    grid-template-columns: 1.35fr 1fr;
    gap: 20px;
    align-items: start;
}

/* Header menu button */
.header-menu-btn {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    margin-right: 8px;
    border-radius: 10px;
    background: var(--surface-2);
    border: 1px solid var(--border-soft);
    color: var(--text-light);
}
.header-menu-btn i {
    font-size: 22px;
}
@media (max-width: 1200px) {
    .header-menu-btn {
        display: inline-flex;
    }
    .app-header-title {
        display: none;
    }
}
@media (max-width: 992px) {
    .finance-page-grid {
        grid-template-columns: 1fr;
    }
}
/* Mobile sidebar drawer */
@media (max-width: 1200px) {
    .app-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 280px;
        max-width: 80%;
        z-index: 1040;
        transform: translateX(-100%);
        transition: transform 0.28s ease, box-shadow 0.28s ease;
        box-shadow: none;
        border-right: 1px solid var(--border-soft);
    }
    .app-sidebar.open {
        transform: translateX(0);
        box-shadow: 0 10px 30px rgba(0,0,0,0.35);
    }
    .sidebar-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.4);
        z-index: 1030;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.2s ease, visibility 0.2s ease;
    }
    .sidebar-overlay.active {
        opacity: 1;
        visibility: visible;
    }
    .sidebar-close-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        position: absolute;
        top: 10px;
        right: 10px;
        width: 36px;
        height: 36px;
        border-radius: 10px;
        border: 1px solid var(--border-soft);
        background: var(--surface-2);
        color: var(--text-light);
        z-index: 1050;
    }
    .sidebar-close-btn i {
        font-size: 20px;
    }
    body.no-scroll {
        overflow: hidden;
        touch-action: none;
    }
}