/* ===== LegacyCapitalTrades Main Stylesheet ===== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
    --primary: #0B1F3B;
    --secondary: #1E4D8C;
    --accent: #00C896;
    --loss: #FF4D4F;
    --bg-dark: #0F172A;
    --bg-card: #1a2540;
    --bg-card-hover: #1f2d4d;
    --border: #2a3a5c;
    --text: #FFFFFF;
    --text-muted: #94a3b8;
    --text-dim: #64748b;
    --radius: 10px;
    --shadow: 0 4px 24px rgba(0,0,0,0.3);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-dark);
    color: var(--text);
    font-size: 15px;
    line-height: 1.6;
    overflow-x: hidden;
}

a { color: var(--accent); text-decoration: none; transition: .2s; }
a:hover { color: #00e6ad; }

img { max-width: 100%; }

/* ===== Utility ===== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.text-center { text-align: center; }
.text-accent { color: var(--accent); }
.text-loss { color: var(--loss); }
.text-muted { color: var(--text-muted); }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 32px; }

/* ===== Flash Messages ===== */
.flash-msg {
    padding: 14px 20px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    font-size: 14px;
    font-weight: 500;
}
.flash-success { background: rgba(0,200,150,.15); border: 1px solid var(--accent); color: var(--accent); }
.flash-error { background: rgba(255,77,79,.15); border: 1px solid var(--loss); color: var(--loss); }

/* ===== Buttons ===== */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all .3s;
    border: none;
    text-align: center;
    font-family: inherit;
}
.btn-primary { background: var(--accent); color: var(--primary); }
.btn-primary:hover { background: #00e6ad; color: var(--primary); transform: translateY(-1px); }
.btn-secondary { background: var(--secondary); color: #fff; }
.btn-secondary:hover { background: #2563a8; }
.btn-outline { background: transparent; border: 1.5px solid var(--accent); color: var(--accent); }
.btn-outline:hover { background: var(--accent); color: var(--primary); }
.btn-danger { background: var(--loss); color: #fff; }
.btn-danger:hover { background: #e63e40; }
.btn-sm { padding: 8px 18px; font-size: 13px; }
.btn-full { width: 100%; }

/* ===== Navbar ===== */
.navbar {
    background: rgba(11,31,59,.95);
    backdrop-filter: blur(12px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border);
}
.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    max-width: 1200px;
    margin: 0 auto;
    height: 68px;
}
.nav-logo {
    font-size: 22px;
    font-weight: 800;
    color: #fff;
    letter-spacing: -.5px;
}
.nav-logo span { color: var(--accent); }
.nav-links { display: flex; gap: 28px; align-items: center; list-style: none; }
.nav-links a { color: var(--text-muted); font-size: 14px; font-weight: 500; }
.nav-links a:hover { color: #fff; }
.nav-actions { display: flex; gap: 12px; align-items: center; }
.hamburger { display: none; flex-direction: column; gap: 5px; cursor: pointer; background: none; border: none; }
.hamburger span { width: 24px; height: 2px; background: #fff; transition: .3s; }

/* ===== Hero ===== */
.hero {
    padding: 160px 0 100px;
    background: linear-gradient(135deg, var(--bg-dark) 0%, var(--primary) 50%, #0d2847 100%);
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    top: -200px;
    right: -200px;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0,200,150,.08) 0%, transparent 70%);
    border-radius: 50%;
}
.hero-content { max-width: 650px; }
.hero h1 { font-size: 42px; font-weight: 800; line-height: 1.15; margin-bottom: 20px; }
.hero p { font-size: 16px; color: var(--text-muted); margin-bottom: 32px; line-height: 1.7; }
.hero-stats { display: flex; gap: 40px; margin-top: 40px; }
.hero-stat h3 { font-size: 28px; font-weight: 700; color: var(--accent); }
.hero-stat p { font-size: 13px; color: var(--text-muted); }

/* ===== Market Ticker ===== */
.ticker-bar {
    background: var(--primary);
    border-bottom: 1px solid var(--border);
    overflow: hidden;
    padding: 10px 0;
}
.ticker-wrap { display: flex; gap: 48px; animation: tickerScroll 30s linear infinite; white-space: nowrap; }
.ticker-item { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; }
.ticker-item .symbol { color: #fff; }
.ticker-item .price { color: var(--text-muted); }
.ticker-item .change-up { color: var(--accent); }
.ticker-item .change-down { color: var(--loss); }
@keyframes tickerScroll { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* ===== Section ===== */
.section { padding: 80px 0; }
.section-title { font-size: 30px; font-weight: 700; margin-bottom: 12px; }
.section-subtitle { font-size: 15px; color: var(--text-muted); margin-bottom: 48px; max-width: 600px; }
.section-subtitle.centered { margin-left: auto; margin-right: auto; }

/* ===== Cards ===== */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    transition: .3s;
}
.card:hover { border-color: var(--accent); transform: translateY(-3px); }

/* ===== Grid ===== */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }

/* ===== Plans ===== */
.plan-card { text-align: center; position: relative; overflow: hidden; }
.plan-card.featured { border-color: var(--accent); }
.plan-card.featured::before {
    content: 'Popular';
    position: absolute;
    top: 16px;
    right: -30px;
    background: var(--accent);
    color: var(--primary);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 36px;
    transform: rotate(45deg);
}
.plan-name { font-size: 18px; font-weight: 600; margin-bottom: 6px; }
.plan-price { font-size: 36px; font-weight: 800; color: var(--accent); margin: 16px 0; }
.plan-price span { font-size: 14px; font-weight: 400; color: var(--text-muted); }
.plan-features { list-style: none; margin: 20px 0; text-align: left; }
.plan-features li { padding: 8px 0; font-size: 14px; color: var(--text-muted); border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 8px; }
.plan-features li::before { content: '✓'; color: var(--accent); font-weight: 700; }

/* ===== Steps ===== */
.step-card { text-align: center; position: relative; }
.step-num { width: 48px; height: 48px; background: var(--accent); color: var(--primary); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 18px; margin: 0 auto 16px; }

/* ===== Testimonials ===== */
.testimonial-card { padding: 28px; }
.testimonial-text { font-size: 14px; color: var(--text-muted); line-height: 1.7; margin-bottom: 16px; font-style: italic; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.testimonial-avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--secondary); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 16px; }
.testimonial-name { font-weight: 600; font-size: 14px; }
.testimonial-role { font-size: 12px; color: var(--text-dim); }

/* ===== Footer ===== */
.footer { background: var(--primary); border-top: 1px solid var(--border); padding: 60px 0 30px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer-brand p { font-size: 14px; color: var(--text-muted); margin-top: 12px; line-height: 1.7; }
.footer-title { font-size: 15px; font-weight: 600; margin-bottom: 16px; }
.footer-links { list-style: none; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: var(--text-muted); font-size: 14px; }
.footer-links a:hover { color: var(--accent); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 24px; text-align: center; font-size: 13px; color: var(--text-dim); }

/* ===== Forms ===== */
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 13px; font-weight: 500; color: var(--text-muted); margin-bottom: 6px; }
.form-control {
    width: 100%;
    padding: 12px 16px;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: #fff;
    font-size: 14px;
    font-family: inherit;
    transition: .2s;
}
.form-control:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(0,200,150,.1); }
.form-control::placeholder { color: var(--text-dim); }
select.form-control { cursor: pointer; }
textarea.form-control { min-height: 100px; resize: vertical; }

.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 20px 40px;
}
.auth-box {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 40px;
    width: 100%;
    max-width: 440px;
}
.auth-box h2 { font-size: 24px; font-weight: 700; margin-bottom: 6px; }
.auth-box .sub { font-size: 14px; color: var(--text-muted); margin-bottom: 28px; }
.auth-footer { text-align: center; margin-top: 20px; font-size: 14px; color: var(--text-muted); }

/* ===== Dashboard ===== */
.dash-layout { display: flex; min-height: 100vh; }
.sidebar {
    width: 260px;
    background: var(--primary);
    border-right: 1px solid var(--border);
    padding: 20px 0;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    overflow-y: auto;
    z-index: 100;
}
.sidebar-logo { padding: 0 24px 24px; font-size: 20px; font-weight: 800; border-bottom: 1px solid var(--border); margin-bottom: 20px; }
.sidebar-logo span { color: var(--accent); }
.sidebar-nav { list-style: none; padding: 0 12px; }
.sidebar-nav li { margin-bottom: 2px; }
.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 16px;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
    border-radius: 8px;
    transition: .2s;
}
.sidebar-nav a:hover { background: rgba(255,255,255,.05); color: #fff; }
.sidebar-nav a.active { background: rgba(0,200,150,.1); color: var(--accent); }
.sidebar-nav a .icon { width: 20px; text-align: center; }
.sidebar-section { padding: 12px 24px 8px; font-size: 11px; font-weight: 600; color: var(--text-dim); text-transform: uppercase; letter-spacing: 1px; }

.dash-main { flex: 1; margin-left: 260px; }
.dash-header {
    background: rgba(11,31,59,.95);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    padding: 0 32px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 50;
}
.dash-header-left { display: flex; align-items: center; gap: 16px; }
.dash-header-left h2 { font-size: 17px; font-weight: 600; }
.dash-header-right { display: flex; align-items: center; gap: 20px; }

.dash-content { padding: 28px 32px; }

/* Account Mode Toggle */
.mode-toggle {
    display: flex;
    background: var(--bg-dark);
    border-radius: 8px;
    padding: 3px;
    border: 1px solid var(--border);
}
.mode-toggle button {
    padding: 7px 18px;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: .2s;
    font-family: inherit;
    background: transparent;
    color: var(--text-muted);
}
.mode-toggle button.active { background: var(--accent); color: var(--primary); }
.mode-toggle button:hover:not(.active) { color: #fff; }

/* Stat Cards */
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 28px; }
.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px;
}
.stat-card .label { font-size: 13px; color: var(--text-muted); font-weight: 500; margin-bottom: 8px; }
.stat-card .value { font-size: 24px; font-weight: 700; }
.stat-card .value.profit { color: var(--accent); }
.stat-card .value.loss { color: var(--loss); }
.stat-card .change { font-size: 12px; margin-top: 4px; }

/* Tables */
.table-wrap { overflow-x: auto; }
table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}
table th {
    text-align: left;
    padding: 12px 16px;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .5px;
    border-bottom: 1px solid var(--border);
    background: rgba(0,0,0,.15);
}
table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
    color: var(--text-muted);
}
table tr:hover td { background: rgba(255,255,255,.02); }

.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}
.badge-pending { background: rgba(251,191,36,.15); color: #fbbf24; }
.badge-approved { background: rgba(0,200,150,.15); color: var(--accent); }
.badge-rejected { background: rgba(255,77,79,.15); color: var(--loss); }
.badge-open { background: rgba(59,130,246,.15); color: #3b82f6; }
.badge-closed { background: rgba(148,163,184,.15); color: var(--text-muted); }

/* Trading Interface */
.trade-layout { display: grid; grid-template-columns: 280px 1fr 300px; gap: 20px; }
.asset-list {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}
.asset-list-header { padding: 16px; border-bottom: 1px solid var(--border); font-weight: 600; font-size: 14px; }
.asset-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    cursor: pointer;
    transition: .15s;
    border-bottom: 1px solid rgba(255,255,255,.03);
}
.asset-item:hover { background: rgba(255,255,255,.03); }
.asset-item.active { background: rgba(0,200,150,.08); border-left: 3px solid var(--accent); }
.asset-item .name { font-weight: 600; font-size: 14px; color: #fff; }
.asset-item .price { font-size: 13px; color: var(--text-muted); }

.chart-area {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}
.chart-area .chart-header { padding: 16px 20px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.chart-container { height: 450px; }

.trade-panel {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
}
.trade-panel h3 { font-size: 16px; font-weight: 600; margin-bottom: 18px; }
.trade-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 18px; }
.btn-buy { background: var(--accent); color: var(--primary); font-weight: 700; padding: 14px; border: none; border-radius: 8px; cursor: pointer; font-size: 15px; font-family: inherit; }
.btn-sell { background: var(--loss); color: #fff; font-weight: 700; padding: 14px; border: none; border-radius: 8px; cursor: pointer; font-size: 15px; font-family: inherit; }
.btn-buy:hover { background: #00e6ad; }
.btn-sell:hover { background: #e63e40; }

/* Notice boxes */
.notice {
    padding: 14px 18px;
    border-radius: 8px;
    font-size: 13px;
    line-height: 1.6;
    margin-bottom: 20px;
}
.notice-info { background: rgba(59,130,246,.1); border: 1px solid rgba(59,130,246,.3); color: #93bbf5; }
.notice-warning { background: rgba(251,191,36,.1); border: 1px solid rgba(251,191,36,.3); color: #fbbf24; }
.notice-success { background: rgba(0,200,150,.1); border: 1px solid rgba(0,200,150,.3); color: var(--accent); }

/* Withdrawal Method Cards */
.method-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 24px; }
.method-card {
    background: var(--bg-dark);
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: .2s;
}
.method-card:hover { border-color: var(--accent); }
.method-card.selected { border-color: var(--accent); background: rgba(0,200,150,.05); }
.method-card .method-icon { font-size: 32px; margin-bottom: 10px; }
.method-card .method-name { font-weight: 600; font-size: 15px; }

/* Page Header */
.page-header {
    padding: 120px 0 60px;
    background: linear-gradient(135deg, var(--bg-dark), var(--primary));
    text-align: center;
}
.page-header h1 { font-size: 34px; font-weight: 700; margin-bottom: 10px; }
.page-header p { font-size: 15px; color: var(--text-muted); }

/* FAQ */
.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 12px;
    overflow: hidden;
}
.faq-question {
    padding: 18px 24px;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: .2s;
}
.faq-question:hover { color: var(--accent); }
.faq-answer {
    padding: 0 24px;
    max-height: 0;
    overflow: hidden;
    transition: max-height .3s;
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.7;
}
.faq-item.open .faq-answer { max-height: 300px; padding-bottom: 18px; }

/* Admin */
.admin-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; }

/* Deposit Modal Steps */
.step-indicator { display: flex; gap: 8px; margin-bottom: 24px; }
.step-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--border); }
.step-dot.active { background: var(--accent); width: 24px; border-radius: 4px; }

/* ===== Responsive ===== */
@media (max-width: 1024px) {
    .trade-layout { grid-template-columns: 1fr; }
    .stat-grid { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .nav-links { display: none; position: fixed; top: 68px; left: 0; right: 0; background: var(--primary); flex-direction: column; padding: 20px; gap: 16px; border-bottom: 1px solid var(--border); }
    .nav-links.open { display: flex; }
    .hamburger { display: flex; }
    .hero h1 { font-size: 30px; }
    .hero-stats { flex-direction: column; gap: 20px; }
    .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
    .stat-grid { grid-template-columns: 1fr; }
    .sidebar { transform: translateX(-100%); transition: .3s; }
    .sidebar.open { transform: translateX(0); }
    .dash-main { margin-left: 0; }
    .dash-content { padding: 20px 16px; }
    .method-cards { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .auth-box { padding: 28px 20px; }
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg-dark); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

/* ===== Animations ===== */
@keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.animate-in { animation: fadeInUp .5s ease forwards; }

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}
.modal-overlay.show { display: flex; }
.modal-box {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px;
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
}
.modal-box h3 { font-size: 18px; font-weight: 700; margin-bottom: 18px; }
.modal-close { float: right; background: none; border: none; color: var(--text-muted); font-size: 20px; cursor: pointer; }