/* ============================================================
   APEXIN THEME v2
   Teal/emerald + dark navy, white cards, clean modern SaaS look.
   Single source of truth for every page — public site, user
   dashboard, and admin panel all load this one file.
============================================================ */

:root {
    --primary: #10b981;
    --primary-2: #14b8a6;
    --primary-dark: #0d9488;
    --gradient: linear-gradient(135deg, var(--primary-2), var(--primary));

    --navy: #0f172a;
    --text: #1e293b;
    --muted: #64748b;
    --bg: #f8fafc;
    --card: #ffffff;
    --border: #e2e8f0;

    --blue: #3b82f6;
    --blue-bg: #eff6ff;
    --green: #10b981;
    --green-bg: #ecfdf5;
    --purple: #8b5cf6;
    --purple-bg: #f5f3ff;
    --amber: #d97706;
    --amber-bg: #fef3e0;
    --red: #ef4444;
    --red-bg: #fef2f2;

    --radius: 16px;
    --radius-sm: 10px;
    --shadow: 0 2px 14px rgba(15, 23, 42, 0.06);
    --shadow-lg: 0 12px 40px rgba(15, 23, 42, 0.12);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background:
        radial-gradient(circle at 8% 0%, rgba(16,185,129,0.09), transparent 35%),
        radial-gradient(circle at 95% 8%, rgba(59,130,246,0.08), transparent 38%),
        radial-gradient(circle at 50% 100%, rgba(139,92,246,0.06), transparent 40%),
        var(--bg);
    background-attachment: fixed;
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }

.container { max-width: 1320px; margin: 0 auto; padding: 0 24px; }

h1, h2, h3, h4 { color: var(--navy); margin: 0; font-weight: 800; letter-spacing: -0.01em; }

/* ============================================================
   BUTTONS
============================================================ */

.btn-primary, .btn-secondary, .btn-outline, .btn-success, .btn-danger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 13px 26px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 14.5px;
    border: none;
    cursor: pointer;
    text-align: center;
    transition: transform .15s ease, box-shadow .15s ease, opacity .15s ease;
    white-space: nowrap;
}

.btn-primary { background: var(--gradient); color: #fff; box-shadow: 0 8px 20px rgba(16,185,129,0.28); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 10px 26px rgba(16,185,129,0.36); }

.btn-outline { background: #fff; color: var(--navy); border: 1.5px solid var(--border); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }

.btn-secondary { background: #fff; color: var(--navy); border: 1.5px solid var(--border); }
.btn-secondary:hover { border-color: var(--primary-dark); }

.btn-success { background: var(--green-bg); color: var(--primary-dark); }
.btn-danger { background: var(--red-bg); color: var(--red); }

.btn-sm { padding: 7px 14px; font-size: 12.5px; border-radius: 9px; }

.btn-block { width: 100%; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }

button:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }

/* ============================================================
   PUBLIC SITE — HEADER
============================================================ */

.site-header {
    background: #fff;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.site-header .navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
    gap: 20px;
    position: relative;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    font-weight: 800;
    color: var(--navy);
    flex-shrink: 0;
}

.brand img { height: 44px; width: auto; max-width: 180px; object-fit: contain; }

.nav-menu {
    list-style: none;
    display: flex;
    gap: 30px;
    margin: 0;
    padding: 0;
    flex: 1;
    justify-content: center;
}

.nav-menu a {
    font-size: 14.5px;
    font-weight: 600;
    color: var(--text);
    padding-bottom: 6px;
    border-bottom: 2px solid transparent;
}

.nav-menu a:hover, .nav-menu a.active { color: var(--primary-dark); border-color: var(--primary); }

.nav-actions { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }

.mobile-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
    color: var(--navy);
}

@media (max-width: 900px) {
    .nav-menu { display: none; }
    .nav-menu.mobile-open {
        display: flex;
        position: absolute;
        top: 64px; left: 0; right: 0;
        background: #fff;
        flex-direction: column;
        padding: 16px 24px;
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow-lg);
        gap: 4px;
    }
    .mobile-toggle { display: block; }
    .nav-actions .btn-outline { display: none; }
}

/* ============================================================
   HERO
============================================================ */

.hero {
    background: linear-gradient(180deg, #f0fdfa, #ffffff 60%);
    padding: 56px 0 30px;
    overflow: hidden;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 40px;
    align-items: center;
}

@media (max-width: 960px) {
    .hero-grid { grid-template-columns: 1fr; }
}

.eyebrow-row {
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--primary-dark);
    text-transform: uppercase;
    margin-bottom: 16px;
}

.hero h1 {
    font-size: clamp(34px, 5vw, 52px);
    line-height: 1.08;
    margin-bottom: 18px;
}

.hero h1 .accent {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero p.lede {
    font-size: 17px;
    color: var(--muted);
    max-width: 520px;
    margin-bottom: 28px;
}

.hero-cta { display: flex; gap: 14px; margin-bottom: 34px; flex-wrap: wrap; }

.hero-features {
    display: flex;
    gap: 26px;
    flex-wrap: wrap;
    margin-bottom: 36px;
}

.hero-feature { display: flex; flex-direction: column; align-items: center; gap: 8px; width: 100px; text-align: center; }

.hero-feature-icon {
    width: 46px; height: 46px;
    border-radius: 14px;
    background: var(--green-bg);
    color: var(--primary-dark);
    display: flex; align-items: center; justify-content: center;
    font-size: 18px;
}

.hero-feature span { font-size: 12.5px; font-weight: 700; color: var(--text); line-height: 1.3; }

.hero-image { position: relative; }
.hero-image img { border-radius: 24px; width: 100%; }

.stat-strip {
    display: flex;
    gap: 0;
    border-top: 1px solid var(--border);
    margin-top: 20px;
    padding-top: 26px;
    flex-wrap: wrap;
}

.stat-strip > div {
    flex: 1;
    min-width: 130px;
    padding-right: 20px;
    border-right: 1px solid var(--border);
}
.stat-strip > div:last-child { border-right: none; }

.stat-strip b { display: block; font-size: 26px; font-weight: 800; color: var(--navy); }
.stat-strip span { font-size: 12.5px; color: var(--muted); }

/* ============================================================
   HOW IT WORKS
============================================================ */

.section { padding: 70px 0; }
.section-heading { text-align: center; max-width: 560px; margin: 0 auto 42px; }
.section-heading .eyebrow-row { text-align: center; }
.section-heading h2 { font-size: 32px; margin-bottom: 10px; }
.section-heading p { color: var(--muted); font-size: 15.5px; }

.steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 960px) { .steps-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .steps-grid { grid-template-columns: 1fr; } }

.step-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
}

.step-icon {
    width: 44px; height: 44px;
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 17px;
    margin-bottom: 14px;
}
.step-icon.c1 { background: var(--green-bg); color: var(--primary-dark); }
.step-icon.c2 { background: var(--blue-bg); color: var(--blue); }
.step-icon.c3 { background: var(--green-bg); color: var(--primary-dark); }
.step-icon.c4 { background: var(--blue-bg); color: var(--blue); }

.step-num { font-size: 12px; font-weight: 800; color: var(--muted); margin-bottom: 4px; }
.step-card h4 { font-size: 16px; margin-bottom: 8px; }
.step-card p { font-size: 13.5px; color: var(--muted); margin: 0; }

.section-cta { text-align: center; margin-top: 40px; }
.section-cta small { display: block; margin-top: 14px; color: var(--muted); font-size: 12px; letter-spacing: 0.06em; font-weight: 700; }

/* ============================================================
   PLANS / PRODUCTS GRID (public + dashboard)
============================================================ */

.products-grid, .plans-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

@media (max-width: 900px) { .products-grid, .plans-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .products-grid, .plans-grid { grid-template-columns: 1fr; } }

.product-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: box-shadow .2s ease, transform .2s ease;
}
.product-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }

.product-image { position: relative; aspect-ratio: 16/10; background: var(--bg); overflow: hidden; }
.product-image img { width: 100%; height: 100%; object-fit: cover; }

.product-badge {
    position: absolute; top: 12px; right: 12px;
    background: var(--gradient); color: #fff;
    font-size: 12px; font-weight: 800;
    padding: 5px 12px; border-radius: 999px;
}

.product-content { padding: 20px; }
.product-content h3 { font-size: 17px; margin-bottom: 8px; }
.product-content p { font-size: 13.5px; color: var(--muted); margin: 0 0 14px; min-height: 40px; }
.product-price { font-size: 13px; color: var(--muted); margin-bottom: 14px; font-weight: 600; }
.product-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.empty-products {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: var(--muted);
}
.empty-products i { font-size: 32px; margin-bottom: 12px; opacity: 0.4; }

/* ============================================================
   PAGE BANNER (products, product-details, contact, terms)
============================================================ */

.page-banner {
    background: linear-gradient(135deg, var(--navy), #14324a);
    color: #fff;
    padding: 54px 0;
    text-align: center;
}
.page-banner h1 { color: #fff; font-size: 34px; margin-bottom: 8px; }
.page-banner p { color: #b9c6d6; margin: 0; }

/* ============================================================
   FOOTER
============================================================ */

.site-footer { background: var(--navy); color: #cbd5e1; padding: 56px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 32px; margin-bottom: 40px; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

.footer-logo { font-size: 20px; font-weight: 800; color: #fff; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.footer-logo img { height: 34px; width: auto; max-width: 150px; object-fit: contain; }
.footer-col p { font-size: 13.5px; color: #94a3b8; line-height: 1.7; }
.footer-col h4 { color: #fff; font-size: 14px; margin-bottom: 16px; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { font-size: 13.5px; color: #94a3b8; }
.footer-links a:hover { color: var(--primary-2); }

.footer-socials { display: flex; gap: 10px; margin-top: 18px; }
.footer-socials a {
    width: 34px; height: 34px; border-radius: 50%;
    background: rgba(255,255,255,0.08);
    display: flex; align-items: center; justify-content: center;
    color: #cbd5e1; font-size: 13px;
}
.footer-socials a:hover { background: var(--primary); color: #fff; }

.footer-contact { list-style: none; padding: 0; margin: 0; }
.footer-contact li { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; font-size: 13.5px; color: #94a3b8; }
.footer-contact a { color: #94a3b8; }

.footer-bottom { border-top: 1px solid rgba(255,255,255,0.08); padding-top: 20px; text-align: center; font-size: 13px; color: #64748b; }

/* ============================================================
   AUTH SPLIT LAYOUT (login / register / forgot / reset)
============================================================ */

.auth-page { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
@media (max-width: 900px) { .auth-page { grid-template-columns: 1fr; } }

.auth-form-side { display: flex; align-items: center; justify-content: center; padding: 40px 24px; background: #fff; }
.auth-form-wrap { width: 100%; max-width: 420px; }

.auth-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 36px; }
.auth-brand img { height: 56px; width: auto; max-width: 210px; object-fit: contain; }
.auth-brand .name { font-size: 22px; font-weight: 800; color: var(--navy); }
.auth-brand small { display: block; font-size: 10.5px; letter-spacing: 0.08em; color: var(--muted); text-transform: uppercase; }

.auth-form-wrap h1 { font-size: 28px; margin-bottom: 8px; }
.auth-form-wrap .accent { color: var(--primary-dark); }
.auth-form-wrap > p.sub { color: var(--muted); font-size: 14.5px; margin-bottom: 28px; }

.auth-visual-side {
    position: relative;
    overflow: hidden;
    background: var(--navy);
}
.auth-visual-side img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    max-width: none;
}
.auth-visual-side::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15,23,42,0.05) 0%, rgba(15,23,42,0.35) 55%, rgba(13,26,42,0.92) 100%);
}
.auth-visual-copy {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    z-index: 2;
    padding: 44px 48px;
    color: #fff;
}
.auth-visual-copy .tag { font-size: 11.5px; letter-spacing: 0.1em; text-transform: uppercase; color: #7dd3c0; margin-bottom: 10px; font-weight: 700; }
.auth-visual-copy h3 { color: #fff; font-size: 26px; max-width: 320px; line-height: 1.3; }

@media (max-width: 900px) { .auth-visual-side { display: none; } }

.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 7px; color: var(--navy); }

.input-icon { position: relative; }
.input-icon i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); font-size: 14px; }
.input-icon input, .input-icon select { padding-left: 40px !important; }
.input-icon .toggle-eye { left: auto; right: 14px; cursor: pointer; }

input[type="text"], input[type="email"], input[type="password"], input[type="tel"],
input[type="number"], input[type="date"], input[type="datetime-local"], select, textarea {
    width: 100%;
    padding: 13px 14px;
    border: 1.5px solid var(--border);
    border-radius: 11px;
    font-size: 14.5px;
    font-family: inherit;
    background: #fff;
    color: var(--text);
    transition: border-color .15s ease;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); }
textarea { resize: vertical; min-height: 80px; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 520px) { .form-row { grid-template-columns: 1fr; } }

.checkbox-row { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; color: var(--muted); margin-bottom: 20px; }
.checkbox-row input { margin-top: 3px; width: 17px; height: 17px; accent-color: var(--primary); }
.checkbox-row a { color: var(--primary-dark); font-weight: 700; }

.auth-divider { display: flex; align-items: center; gap: 12px; margin: 22px 0; color: var(--muted); font-size: 12.5px; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }

.auth-links { text-align: center; margin-top: 20px; font-size: 13.5px; color: var(--muted); }
.auth-links a { color: var(--primary-dark); font-weight: 700; }

.otp-input { text-align: center; letter-spacing: 10px; font-size: 20px; font-weight: 800; }

/* ============================================================
   ALERTS
============================================================ */

.alert { padding: 13px 16px; border-radius: 11px; font-size: 13.5px; font-weight: 600; margin-bottom: 18px; display: flex; align-items: center; gap: 10px; }
.alert-success, .alert.success { background: var(--green-bg); color: #047857; }
.alert-danger, .alert-error, .alert.error { background: var(--red-bg); color: #b91c1c; }

/* ============================================================
   DASHBOARD SHELL (user + admin share this)
============================================================ */

.dashboard-wrapper, .admin-wrapper { display: flex; min-height: 100vh; }

.sidebar, .admin-sidebar {
    width: 250px;
    background: linear-gradient(165deg, #0f172a 0%, #4c1d95 55%, #0d9488 100%);
    border-right: none;
    box-shadow: 4px 0 24px rgba(15,23,42,0.15);
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
    transition: transform .25s ease;
    z-index: 50;
}

.sidebar-logo, .sidebar-top { padding: 22px 24px 18px; border-bottom: 1px solid rgba(255,255,255,0.12); margin-bottom: 8px; }
.sidebar-logo a, .sidebar-logo .brand-row, .sidebar-top .sidebar-logo-row {
    display: flex; align-items: center; gap: 10px; font-size: 19px; font-weight: 800; color: #fff;
}
.sidebar-logo img, .sidebar-top img {
    height: 40px; width: auto; max-width: 170px; object-fit: contain;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.35));
    background: rgba(255,255,255,0.92);
    padding: 6px 10px;
    border-radius: 10px;
}

.sidebar-user { display: none; }

.sidebar-menu, .admin-sidebar .sidebar-menu {
    flex: 1; padding: 10px 14px; display: flex; flex-direction: column; gap: 2px;
    list-style: none; margin: 0;
}
.sidebar-menu li, .admin-sidebar .sidebar-menu li { margin: 0; padding: 0; }

.sidebar-menu a, .admin-sidebar .sidebar-menu a {
    display: flex; align-items: center; gap: 12px;
    padding: 11px 14px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    color: rgba(255,255,255,0.72);
}
.sidebar-menu a i, .admin-sidebar .sidebar-menu a i { width: 18px; text-align: center; font-size: 15px; }

.sidebar-menu a:hover, .admin-sidebar .sidebar-menu a:hover { background: rgba(255,255,255,0.1); color: #fff; }
.sidebar-menu a.active, .admin-sidebar .sidebar-menu a.active {
    background: rgba(255,255,255,0.16);
    color: #fff;
    box-shadow: inset 3px 0 0 var(--primary-2);
}

.sidebar-footer { padding: 16px; border-top: 1px solid rgba(255,255,255,0.14); }
.vip-card {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.16);
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 10px;
}
.vip-card h5 { font-size: 11.5px; text-transform: uppercase; letter-spacing: 0.05em; color: rgba(255,255,255,0.6); margin: 0 0 4px; font-weight: 700; }
.vip-card strong { display: block; font-size: 16px; color: #fff; }
.vip-card small { font-size: 11px; color: rgba(255,255,255,0.6); }

.logout-btn { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-radius: 10px; font-size: 14px; font-weight: 700; color: #fca5a5; }
.logout-btn:hover { background: rgba(248,113,113,0.15); color: #fecaca; }

.dashboard-container, .admin-main { flex: 1; min-width: 0; }

.dashboard-header, .admin-header {
    background: linear-gradient(100deg, #ecfdf5 0%, #eff6ff 50%, #f5f3ff 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(15,23,42,0.06);
    padding: 18px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    position: sticky;
    top: 0;
    z-index: 40;
}

.header-left { display: flex; align-items: center; gap: 16px; min-width: 0; }
.header-left h3, .header-left h2 { font-size: 16px; margin: 0; }
.header-left small, .header-left p { font-size: 12.5px; color: var(--muted); margin: 2px 0 0; }

#sidebarToggle, .menu-btn {
    display: none;
    background: rgba(255,255,255,0.7);
    border: none;
    width: 38px; height: 38px;
    border-radius: 10px;
    align-items: center; justify-content: center;
    cursor: pointer;
    color: var(--navy);
    font-size: 15px;
}

.header-right { display: flex; align-items: center; gap: 16px; flex-shrink: 0; }

.wallet-box { text-align: right; }
.wallet-box small { display: block; font-size: 11px; color: var(--muted); }
.wallet-box strong { font-size: 15px; color: var(--navy); }

.notification, .notif-bell {
    width: 38px; height: 38px; border-radius: 50%;
    background: rgba(255,255,255,0.7);
    display: flex; align-items: center; justify-content: center;
    position: relative;
    color: var(--navy);
}
.notification span, .notif-dot {
    position: absolute; top: 6px; right: 7px;
    width: 8px; height: 8px; border-radius: 50%; background: var(--red);
}

.profile-box, .admin-profile { display: flex; align-items: center; gap: 10px; }
.profile-box img, .admin-profile img, .avatar-initials {
    width: 38px; height: 38px; border-radius: 50%;
    object-fit: cover;
    background: var(--gradient);
    color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 13px;
}
.profile-box h4, .admin-profile h4 { font-size: 13.5px; margin: 0; }
.profile-box span, .admin-profile small { font-size: 11.5px; color: var(--muted); }

.dashboard-page, .admin-page, .admin-content, .users-page, .withdraw-page, .deposit-page, .referral-page, .products-page {
    padding: 26px 28px 60px;
}

@media (max-width: 900px) {
    .sidebar, .admin-sidebar { position: fixed; left: 0; top: 0; transform: translateX(-100%); box-shadow: var(--shadow-lg); }
    .sidebar.open, .admin-sidebar.open { transform: translateX(0); }
    #sidebarToggle, .menu-btn { display: flex; }
    .dashboard-page, .admin-page, .admin-content, .users-page, .withdraw-page, .deposit-page, .referral-page, .products-page { padding: 18px 16px 50px; }
    .dashboard-header, .admin-header { padding: 14px 16px; }
    .wallet-box { display: none; }
}

.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15,23,42,0.5);
    z-index: 45;
}
.sidebar-overlay.show { display: block; }

/* ============================================================
   WELCOME BANNER (dashboard top)
============================================================ */

.welcome-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 22px;
    align-items: stretch;
}
@media (max-width: 800px) { .welcome-row { grid-template-columns: 1fr; } }

.welcome-text h1 { font-size: 15px; font-weight: 600; color: var(--muted); margin-bottom: 4px; }
.welcome-text h2 { font-size: 26px; margin-bottom: 6px; }
.welcome-text p { color: var(--muted); font-size: 14px; margin: 0; }

.motivation-card {
    background: linear-gradient(120deg, rgba(16,185,129,0.16), rgba(59,130,246,0.12));
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255,255,255,0.5);
    border-radius: var(--radius);
    padding: 22px 26px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    overflow: hidden;
    box-shadow: 0 8px 28px rgba(15,23,42,0.06);
    position: relative;
}
.motivation-card h4 { font-size: 15px; margin-bottom: 4px; }
.motivation-card h4 span { color: var(--primary-dark); }
.motivation-card img { position: absolute; right: -10px; bottom: -20px; width: 130px; opacity: 0.9; }

/* ============================================================
   STAT CARDS
============================================================ */

.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 22px; }
@media (max-width: 960px) { .stats-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .stats-grid { grid-template-columns: 1fr; } }

.stat-card {
    background: rgba(255,255,255,0.6);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255,255,255,0.55);
    border-radius: var(--radius);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 6px 24px rgba(15,23,42,0.06);
}
.stat-card.tint-mint { background: linear-gradient(135deg, rgba(16,185,129,0.16), rgba(16,185,129,0.06)); border-color: rgba(16,185,129,0.25); }
.stat-card.tint-blue { background: linear-gradient(135deg, rgba(59,130,246,0.14), rgba(59,130,246,0.05)); border-color: rgba(59,130,246,0.22); }
.stat-card.tint-green { background: linear-gradient(135deg, rgba(16,185,129,0.14), rgba(16,185,129,0.05)); border-color: rgba(16,185,129,0.22); }
.stat-card.tint-purple { background: linear-gradient(135deg, rgba(139,92,246,0.14), rgba(139,92,246,0.05)); border-color: rgba(139,92,246,0.22); }

.stat-icon { width: 46px; height: 46px; border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; box-shadow: 0 4px 12px rgba(15,23,42,0.1); }
.stat-icon.blue { background: linear-gradient(135deg, #60a5fa, #3b82f6); color: #fff; }
.stat-icon.green { background: linear-gradient(135deg, var(--primary-2), var(--primary)); color: #fff; }
.stat-icon.purple { background: linear-gradient(135deg, #a78bfa, #8b5cf6); color: #fff; }
.stat-icon.orange { background: linear-gradient(135deg, #fbbf24, #d97706); color: #fff; }
.stat-icon.red { background: linear-gradient(135deg, #f87171, #ef4444); color: #fff; }

.stat-info span { display: block; font-size: 12.5px; color: var(--muted); font-weight: 600; margin-bottom: 2px; }
.stat-info h2 { font-size: 19px; }

/* ============================================================
   QUICK ACTIONS
============================================================ */

.quick-actions { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 24px; }
@media (max-width: 800px) { .quick-actions { grid-template-columns: 1fr 1fr; } }

.action-card {
    background: rgba(255,255,255,0.65);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(255,255,255,0.55);
    border-radius: var(--radius-sm);
    padding: 18px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
    font-size: 14px;
    color: var(--navy);
    transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
    box-shadow: 0 4px 16px rgba(15,23,42,0.05);
}
.action-card:hover { border-color: var(--primary); transform: translateY(-2px); box-shadow: 0 10px 26px rgba(15,23,42,0.1); }
.action-card i {
    width: 38px; height: 38px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 15px; flex-shrink: 0; color: #fff;
    box-shadow: 0 4px 10px rgba(15,23,42,0.12);
}
.action-card:nth-child(1) i { background: linear-gradient(135deg, var(--primary-2), var(--primary)); }
.action-card:nth-child(2) i { background: linear-gradient(135deg, #60a5fa, #3b82f6); }
.action-card:nth-child(3) i { background: linear-gradient(135deg, #fbbf24, #d97706); }
.action-card:nth-child(4) i { background: linear-gradient(135deg, #a78bfa, #8b5cf6); }

/* ============================================================
   GENERIC CARD / GLASS-CARD (shared everywhere)
============================================================ */

.glass-card, .card, .dashboard-card, .admin-table-wrap, .table-card, .amount-input-wrap {
    background: rgba(255,255,255,0.68);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(255,255,255,0.6);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: 0 8px 32px rgba(15,23,42,0.07);
}

.dashboard-card { text-align: left; }
.dashboard-card i { font-size: 20px; color: var(--primary-dark); margin-bottom: 10px; display: block; }
.dashboard-card h2 { font-size: 22px; margin-bottom: 2px; }
.dashboard-card span { font-size: 12.5px; color: var(--muted); font-weight: 600; }

.dashboard-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 20px; }
@media (max-width: 960px) { .dashboard-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .dashboard-grid { grid-template-columns: 1fr; } }

.dashboard-row { display: grid; grid-template-columns: 1.3fr 1fr; gap: 18px; margin-bottom: 20px; align-items: start; }
@media (max-width: 900px) { .dashboard-row { grid-template-columns: 1fr; } }

.section-title { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.section-title h3 { font-size: 16px; }
.section-title a { font-size: 13px; font-weight: 700; color: var(--primary-dark); }

.card.tight { padding: 0; overflow: hidden; }

.table-wrapper { overflow-x: auto; }

/* ============================================================
   TABLES
============================================================ */

table.admin-table, table.dashboard-table, table.schedule-table, table.referral-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13.5px;
    min-width: 560px;
}

.admin-table th, .dashboard-table th, .schedule-table th, .referral-table th {
    text-align: left;
    font-size: 11.5px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--muted);
    padding: 12px 14px;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
}

.admin-table td, .dashboard-table td, .schedule-table td, .referral-table td {
    padding: 13px 14px;
    border-bottom: 1px solid var(--border);
}
.admin-table tr:last-child td, .dashboard-table tr:last-child td { border-bottom: none; }

.text-center { text-align: center; }
.text-muted { color: var(--muted); }

/* ============================================================
   EMPTY STATE
============================================================ */

.empty-state { text-align: center; padding: 50px 20px; color: var(--muted); }
.empty-state i { font-size: 30px; margin-bottom: 12px; opacity: 0.35; display: block; }
.empty-state svg { margin-bottom: 12px; opacity: 0.5; }
.empty-state p { margin: 0; font-size: 14px; }
.empty-state small { font-size: 12.5px; }

/* ============================================================
   LIST ROWS (referrals, recent activity, notifications)
============================================================ */

.list-row { display: flex; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--border); }
.list-row:last-child { border-bottom: none; }
.row-main { flex: 1; min-width: 0; }
.row-title { font-weight: 700; font-size: 14px; }
.row-sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.row-amount { font-weight: 800; font-size: 14px; white-space: nowrap; }
.row-amount.positive { color: var(--primary-dark); }
.row-amount.negative { color: var(--red); }

.avatar {
    width: 40px; height: 40px; border-radius: 50%;
    background: var(--gradient); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 13px; flex-shrink: 0; overflow: hidden;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.icon-green { background: var(--green-bg); color: var(--primary-dark); }
.avatar.icon-red { background: var(--red-bg); color: var(--red); }
.avatar.icon-purple { background: var(--purple-bg); color: var(--purple); }

/* ============================================================
   BADGES
============================================================ */

.badge { display: inline-block; padding: 4px 11px; border-radius: 999px; font-size: 11.5px; font-weight: 700; }
.badge.success, .badge.green { background: var(--green-bg); color: var(--primary-dark); }
.badge.danger, .badge.red { background: var(--red-bg); color: var(--red); }
.badge.warning, .badge.amber { background: var(--amber-bg); color: var(--amber); }
.badge.gray { background: var(--bg); color: var(--muted); }

.type-badge { display: inline-block; padding: 4px 11px; border-radius: 999px; font-size: 11.5px; font-weight: 700; }
.type-badge.deposit { background: var(--green-bg); color: var(--primary-dark); }
.type-badge.withdraw { background: var(--red-bg); color: var(--red); }
.type-badge.performance { background: var(--amber-bg); color: var(--amber); }
.type-badge.referral { background: var(--purple-bg); color: var(--purple); }

/* ============================================================
   FILTERS / SEARCH / PAGINATION
============================================================ */

.filter-form .filter-grid, .filter-grid { display: grid; grid-template-columns: 2fr 1fr auto; gap: 12px; align-items: end; }
@media (max-width: 700px) { .filter-form .filter-grid, .filter-grid { grid-template-columns: 1fr; } }
.filter-form .form-group { margin-bottom: 0; }
.button-group { display: flex; }

.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 20px; flex-wrap: wrap; }
.pagination a { padding: 8px 13px; border-radius: 9px; background: #fff; border: 1px solid var(--border); font-size: 13px; font-weight: 700; color: var(--muted); }
.pagination a.active { background: var(--gradient); border-color: transparent; color: #fff; }

.search-bar { display: flex; align-items: center; gap: 10px; background: #fff; border: 1.5px solid var(--border); border-radius: 12px; padding: 12px 16px; }
.search-bar input { border: none; outline: none; flex: 1; font-size: 14px; }
.search-bar i { color: var(--muted); }

.chip-row { display: flex; gap: 8px; overflow-x: auto; margin: 14px 0; }
.chip { flex: none; padding: 8px 16px; border-radius: 999px; background: #fff; border: 1px solid var(--border); font-size: 13px; font-weight: 700; color: var(--muted); }
.chip.active { background: var(--gradient); border-color: transparent; color: #fff; }

/* ============================================================
   PAGE HEADER (dashboard sub-pages)
============================================================ */

.page-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-header h1 { font-size: 22px; margin-bottom: 4px; }
.page-header p { color: var(--muted); font-size: 13.5px; margin: 0; }
.total-users { font-size: 13.5px; color: var(--muted); }

/* ============================================================
   DEPOSIT / WITHDRAW SPECIFIC
============================================================ */

.deposit-grid, .withdraw-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 900px) { .deposit-grid, .withdraw-grid { grid-template-columns: 1fr; } }

.deposit-left, .withdraw-left, .deposit-right, .withdraw-right { min-width: 0; }

.deposit-btn, .withdraw-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    width: 100%; padding: 14px; border-radius: 12px; border: none; cursor: pointer;
    background: var(--gradient); color: #fff; font-weight: 700; font-size: 14.5px;
    box-shadow: 0 8px 20px rgba(16,185,129,0.28);
}
.deposit-btn:hover, .withdraw-btn:hover { transform: translateY(-1px); }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }

.wallet-details { margin-bottom: 4px; }

.table-header { margin-bottom: 14px; }
.table-header h3 { font-size: 16px; }
.table-responsive { overflow-x: auto; }

.card-title { display: flex; align-items: center; gap: 10px; font-size: 15.5px; font-weight: 800; color: var(--navy); margin-bottom: 18px; }
.card-title i { color: var(--primary-dark); }

.wallet-network-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px; }
.wallet-card { border: 1.5px solid var(--border); border-radius: 12px; padding: 14px; cursor: pointer; display: block; }
.wallet-card input { display: none; }
.wallet-card-content { display: flex; align-items: center; gap: 10px; }
.wallet-icon { width: 32px; height: 32px; border-radius: 8px; background: var(--green-bg); color: var(--primary-dark); display: flex; align-items: center; justify-content: center; }
.wallet-card:has(input:checked) { border-color: var(--primary); background: var(--green-bg); }

.wallet-address-box { display: flex; align-items: center; justify-content: space-between; background: var(--bg); border-radius: 10px; padding: 12px 14px; font-size: 12.5px; word-break: break-all; margin-bottom: 18px; gap: 10px; }
.wallet-copy button { background: none; border: none; color: var(--primary-dark); cursor: pointer; font-size: 14px; }

.amount-input { display: flex; align-items: center; border: 1.5px solid var(--border); border-radius: 11px; padding: 0 14px; background: #fff; }
.amount-input span { font-weight: 800; color: var(--primary-dark); margin-right: 6px; }
.amount-input input { border: none !important; padding: 13px 0 !important; }

.withdraw-summary { background: var(--bg); border-radius: 12px; padding: 14px 16px; margin: 16px 0; }
.summary-item { display: flex; justify-content: space-between; font-size: 13.5px; }

.info-list { display: flex; flex-direction: column; gap: 16px; }
.info-item { display: flex; align-items: center; gap: 12px; font-size: 13.5px; }
.info-icon { width: 38px; height: 38px; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.info-icon.blue { background: var(--blue-bg); color: var(--blue); }
.info-icon.green { background: var(--green-bg); color: var(--primary-dark); }
.info-icon.orange { background: var(--amber-bg); color: var(--amber); }
.info-icon.purple { background: var(--purple-bg); color: var(--purple); }

/* ============================================================
   REFERRALS
============================================================ */

.referral-card { background: linear-gradient(120deg, var(--navy), #123146); border-radius: var(--radius); padding: 26px; color: #fff; margin-bottom: 20px; }
.referral-header { font-size: 15px; font-weight: 700; margin-bottom: 16px; display: flex; align-items: center; gap: 8px; }
.referral-code-box { background: rgba(255,255,255,0.1); border-radius: 12px; padding: 16px; text-align: center; font-size: 22px; font-weight: 800; letter-spacing: 2px; margin-bottom: 14px; }
.referral-link-box { background: rgba(255,255,255,0.1); border-radius: 12px; padding: 12px 14px; display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 12px; word-break: break-all; }
.link-actions .copy-btn { background: var(--gradient); color: #fff; border: none; padding: 8px 14px; border-radius: 8px; font-size: 12.5px; font-weight: 700; cursor: pointer; white-space: nowrap; }

.stats-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; display: flex; align-items: center; gap: 12px; }
.stats-icon { width: 42px; height: 42px; border-radius: 11px; display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; }
.stats-icon.blue { background: var(--blue-bg); color: var(--blue); }
.stats-icon.green { background: var(--green-bg); color: var(--primary-dark); }
.stats-icon.orange { background: var(--amber-bg); color: var(--amber); }
.stats-content span { display: block; font-size: 12px; color: var(--muted); font-weight: 600; }
.stats-content h2 { font-size: 18px; }

.user-info { display: flex; align-items: center; gap: 10px; }

/* ============================================================
   PROFILE
============================================================ */

.avatar-lg { width: 90px; height: 90px; border-radius: 50%; }

/* ============================================================
   UTILITIES
============================================================ */

.mt-2 { margin-top: 10px; } .mt-3 { margin-top: 18px; } .mt-25 { margin-top: 22px; } .mt-30 { margin-top: 26px; } .mb-3 { margin-bottom: 18px; }
.d-flex { display: flex; } .gap-2 { gap: 10px; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }

.header-action { flex-shrink: 0; }

.table-actions { display: flex; gap: 6px; white-space: nowrap; }

.user-avatar {
    width: 38px; height: 38px; border-radius: 50%;
    background: var(--gradient); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 13px; flex-shrink: 0;
}

.quick-card {
    display: flex; flex-direction: column; align-items: center; gap: 10px;
    background: rgba(255,255,255,0.55);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(255,255,255,0.6);
    border-radius: var(--radius-sm);
    padding: 20px 14px;
    font-size: 13px;
    font-weight: 700;
    color: var(--navy);
    text-align: center;
    transition: transform .15s ease, box-shadow .15s ease;
}
.quick-card:hover { border-color: var(--primary); transform: translateY(-2px); box-shadow: 0 10px 24px rgba(15,23,42,0.08); }
.quick-card i {
    font-size: 18px; color: #fff;
    width: 38px; height: 38px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--primary-2), var(--primary));
    box-shadow: 0 4px 10px rgba(16,185,129,0.25);
}

/* ============================================================
   RESPONSIVE FIXES — misc
============================================================ */

@media (max-width: 640px) {
    .hero { padding: 34px 0 20px; }
    .hero-features { gap: 16px; }
    .hero-feature { width: 80px; }
    .stat-strip > div { min-width: 45%; border-right: none; padding-right: 0; margin-bottom: 14px; }
    .section { padding: 44px 0; }
    .container { padding: 0 16px; }
}