/* ============================================================
   CryptoVault -- Modern UI v2
   Binance DNA + contemporary polish
   ============================================================ */

:root {
    --bg-primary:       #0B0E11;
    --bg-secondary:     #1E2329;
    --bg-tertiary:      #2B3139;
    --bg-quaternary:    #363C45;
    --accent-yellow:    #F0B90B;
    --accent-yellow-h:  #D4A009;
    --accent-yellow-dim:#F0B90B22;
    --text-primary:     #EAECEF;
    --text-secondary:   #848E9C;
    --green:            #0ECB81;
    --green-dim:        #0ECB8122;
    --red:              #F6465D;
    --red-dim:          #F6465D22;
    --blue:             #1890FF;
    --blue-dim:         #1890FF22;
    --sidebar-width:    240px;
    --radius-sm:        6px;
    --radius-md:        10px;
    --radius-lg:        16px;
    --shadow-card:      0 4px 24px rgba(0,0,0,0.35);
    --shadow-glow:      0 0 32px rgba(240,185,11,0.12);
    --transition:       all 0.2s cubic-bezier(0.4,0,0.2,1);
}

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

html { scroll-behavior: smooth; }

body {
    background: var(--bg-primary);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    line-height: 1.6;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* -- Scrollbar ------------------------------------------------ */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--bg-quaternary); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-secondary); }

/* -- Selection ----------------------------------------------- */
::selection { background: rgba(240,185,11,0.2); color: var(--text-primary); }

/* ============================================================
   LAYOUT
   ============================================================ */
.app-layout { display: flex; min-height: 100vh; }

.main-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: hidden;
}

.page-content { padding: 28px; flex: 1; }

/* ============================================================
   SIDEBAR
   ============================================================ */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-secondary);
    position: fixed;
    top: 0; left: 0; bottom: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(255,255,255,0.04);
    transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 22px 20px 18px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.logo-text {
    font-size: 1.15rem;
    font-weight: 800;
    background: linear-gradient(135deg, #F0B90B, #FFD700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 0.3px;
}

.admin-badge {
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 2px;
    color: var(--accent-yellow);
    padding: 6px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    text-transform: uppercase;
    background: linear-gradient(90deg, rgba(240,185,11,0.08), transparent);
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    padding: 10px 8px;
    gap: 2px;
    flex: 1;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
    position: relative;
}

.nav-item:hover { background: rgba(255,255,255,0.04); color: var(--text-primary); }

.nav-item.active {
    background: linear-gradient(135deg, rgba(240,185,11,0.12), rgba(240,185,11,0.06));
    color: var(--accent-yellow);
    font-weight: 600;
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: 0; top: 20%; bottom: 20%;
    width: 3px;
    background: var(--accent-yellow);
    border-radius: 0 3px 3px 0;
}

.nav-icon { width: 16px; text-align: center; font-size: 0.85rem; }

.sidebar-divider { height: 1px; background: rgba(255,255,255,0.05); margin: 8px 16px; }

.sidebar-footer {
    padding: 12px 8px;
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.sidebar-user {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    margin-bottom: 4px;
}

.user-avatar-sm {
    width: 32px; height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, #F0B90B, #D4A009);
    color: #0B0E11;
    display: flex; align-items: center; justify-content: center;
    font-weight: 800;
    font-size: 0.78rem;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(240,185,11,0.3);
}

.admin-avatar { background: linear-gradient(135deg, #F0B90B, #FF8C00); }

.sidebar-username {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 130px;
}

.sidebar-role { font-size: 0.68rem; color: var(--text-secondary); margin-top: 1px; }

.logout-btn { color: var(--red) !important; margin-top: 2px; }
.logout-btn:hover { background: rgba(246,70,93,0.08) !important; color: var(--red) !important; }

.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    z-index: 99;
    backdrop-filter: blur(2px);
}

/* ============================================================
   TOPBAR
   ============================================================ */
.topbar {
    background: rgba(11,14,17,0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    height: 58px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
    position: sticky;
    top: 0;
    z-index: 50;
}

.topbar-left { display: flex; align-items: center; gap: 12px; overflow: hidden; flex: 1; }

.hamburger-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.1rem;
    cursor: pointer;
    padding: 6px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.hamburger-btn:hover { background: var(--bg-tertiary); }

/* -- Ticker -------------------------------------------------- */
.ticker-wrapper {
    overflow: hidden;
    flex: 1;
    -webkit-mask-image: linear-gradient(90deg, transparent, black 5%, black 95%, transparent);
    mask-image: linear-gradient(90deg, transparent, black 5%, black 95%, transparent);
}

.ticker-track {
    display: flex;
    gap: 32px;
    animation: ticker-scroll 35s linear infinite;
    white-space: nowrap;
    width: max-content;
}

.ticker-track:hover { animation-play-state: paused; }

@keyframes ticker-scroll {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

.ticker-item { display: inline-flex; align-items: center; gap: 6px; font-size: 0.73rem; }
.ticker-symbol { font-weight: 700; color: var(--text-primary); }
.ticker-price { color: var(--text-secondary); }
.ticker-change.positive { color: var(--green); }
.ticker-change.negative { color: var(--red); }

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

.topbar-icon-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1rem;
    cursor: pointer;
    padding: 7px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.topbar-icon-btn:hover { color: var(--text-primary); background: var(--bg-tertiary); }

/* -- User dropdown ------------------------------------------- */
.user-dropdown { position: relative; }

.user-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-tertiary);
    border: 1px solid rgba(255,255,255,0.06);
    cursor: pointer;
    color: var(--text-primary);
    padding: 6px 10px 6px 6px;
    border-radius: 20px;
    transition: var(--transition);
}
.user-dropdown-btn:hover { border-color: rgba(240,185,11,0.3); background: var(--bg-quaternary); }

.user-avatar {
    width: 28px; height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #F0B90B, #D4A009);
    color: #0B0E11;
    display: flex; align-items: center; justify-content: center;
    font-weight: 800;
    font-size: 0.72rem;
}

.dropdown-menu {
    display: none;
    position: absolute;
    right: 0; top: calc(100% + 8px);
    background: var(--bg-secondary);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-md);
    min-width: 190px;
    z-index: 200;
    box-shadow: 0 16px 48px rgba(0,0,0,0.5);
    padding: 6px 0;
    animation: dropdown-appear 0.15s cubic-bezier(0.4,0,0.2,1);
}

@keyframes dropdown-appear {
    from { opacity: 0; transform: translateY(-8px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.dropdown-menu.open { display: block; }

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.84rem;
    transition: var(--transition);
}
.dropdown-item:hover { background: var(--bg-tertiary); color: var(--text-primary); }
.dropdown-item.danger { color: var(--red); }
.dropdown-item.danger:hover { background: rgba(246,70,93,0.08); }
.dropdown-divider { height: 1px; background: rgba(255,255,255,0.06); margin: 6px 0; }

/* ============================================================
   STAT CARDS
   ============================================================ */
.stat-card {
    background: var(--bg-secondary);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--radius-md);
    padding: 20px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(240,185,11,0.3), transparent);
    opacity: 0;
    transition: var(--transition);
}

.stat-card:hover { border-color: rgba(240,185,11,0.2); transform: translateY(-2px); box-shadow: var(--shadow-glow); }
.stat-card:hover::before { opacity: 1; }

.stat-label {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 10px;
}

.stat-value {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.1;
    letter-spacing: -0.5px;
}

.stat-sub { font-size: 0.73rem; color: var(--text-secondary); margin-top: 6px; }

/* -- Badges -------------------------------------------------- */
.stat-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    border-radius: 99px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.3px;
}

.badge-green  { background: var(--green-dim);  color: var(--green);  border: 1px solid rgba(14,203,129,0.2); }
.badge-red    { background: var(--red-dim);    color: var(--red);    border: 1px solid rgba(246,70,93,0.2); }
.badge-yellow { background: var(--accent-yellow-dim); color: var(--accent-yellow); border: 1px solid rgba(240,185,11,0.2); }
.badge-blue   { background: var(--blue-dim);   color: var(--blue);   border: 1px solid rgba(24,144,255,0.2); }

/* ============================================================
   CARDS
   ============================================================ */
.card {
    background: var(--bg-secondary);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.card-header {
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-title { font-size: 0.95rem; font-weight: 700; color: var(--text-primary); }
.card-body { padding: 20px; }

/* ============================================================
   TABLES
   ============================================================ */
.table-wrapper { overflow-x: auto; }

table { width: 100%; border-collapse: collapse; font-size: 0.84rem; }

thead tr { background: linear-gradient(135deg, #232930, #1E2329); }

thead th {
    padding: 12px 16px;
    text-align: left;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-secondary);
    white-space: nowrap;
}

tbody tr {
    background: var(--bg-secondary);
    border-bottom: 1px solid rgba(255,255,255,0.03);
    transition: var(--transition);
}
tbody tr:hover { background: var(--bg-tertiary); }
tbody td { padding: 13px 16px; color: var(--text-primary); vertical-align: middle; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 20px;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, #F0B90B, #D4A009);
    color: #0B0E11;
    box-shadow: 0 4px 16px rgba(240,185,11,0.25);
}
.btn-primary:hover {
    background: linear-gradient(135deg, #FFD000, #F0B90B);
    box-shadow: 0 6px 24px rgba(240,185,11,0.4);
    transform: translateY(-1px);
}
.btn-primary:active { transform: translateY(0); }

.btn-danger {
    background: linear-gradient(135deg, #F6465D, #d63650);
    color: #fff;
    box-shadow: 0 4px 16px rgba(246,70,93,0.2);
}
.btn-danger:hover { box-shadow: 0 6px 24px rgba(246,70,93,0.35); transform: translateY(-1px); }

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid rgba(255,255,255,0.08);
}
.btn-secondary:hover { background: var(--bg-quaternary); border-color: rgba(255,255,255,0.15); transform: translateY(-1px); }

.btn-sm { padding: 5px 12px; font-size: 0.78rem; }

.btn-icon {
    padding: 7px;
    background: var(--bg-tertiary);
    border: 1px solid rgba(255,255,255,0.06);
    color: var(--text-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.82rem;
}
.btn-icon:hover { color: var(--text-primary); background: var(--bg-quaternary); border-color: rgba(255,255,255,0.15); }

.btn:disabled, .btn[disabled] { opacity: 0.45; cursor: not-allowed; transform: none !important; }

/* ============================================================
   INPUTS
   ============================================================ */
.input-field {
    width: 100%;
    background: var(--bg-tertiary);
    border: 1px solid rgba(255,255,255,0.07);
    color: var(--text-primary);
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    font-size: 0.875rem;
    font-family: 'Inter', sans-serif;
    outline: none;
    transition: var(--transition);
}
.input-field::placeholder { color: var(--text-secondary); }
.input-field:focus {
    border-color: var(--accent-yellow);
    background: #2f3640;
    box-shadow: 0 0 0 3px rgba(240,185,11,0.08);
}

.input-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

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

select.input-field {
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23848E9C' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}

/* ============================================================
   WALLET CARDS
   ============================================================ */
.wallet-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }

.wallet-card {
    background: var(--bg-secondary);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: var(--transition);
}
.wallet-card:hover {
    border-color: rgba(240,185,11,0.25);
    transform: translateY(-3px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.3), 0 0 0 1px rgba(240,185,11,0.06);
}

.wallet-card-accent { height: 3px; }
.wallet-card-body { padding: 20px; }
.wallet-coin-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.wallet-coin-symbol { font-size: 1.35rem; font-weight: 800; color: var(--text-primary); }
.wallet-coin-name { font-size: 0.72rem; color: var(--text-secondary); margin-top: 1px; }
.wallet-balance { font-size: 1.1rem; font-weight: 700; color: var(--text-primary); font-variant-numeric: tabular-nums; margin-bottom: 3px; }
.wallet-usd { font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 16px; }

.wallet-address-row {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: var(--radius-sm);
    padding: 7px 10px;
}
.wallet-address-text { font-family: 'Courier New', monospace; font-size: 0.68rem; color: var(--text-secondary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; }

.copy-btn {
    background: none; border: none; color: var(--text-secondary);
    cursor: pointer; padding: 2px 4px; transition: var(--transition); font-size: 0.75rem; flex-shrink: 0;
}
.copy-btn:hover { color: var(--accent-yellow); }

/* ============================================================
   PAGE HEADER
   ============================================================ */
.page-header { margin-bottom: 28px; }
.page-title { font-size: 1.45rem; font-weight: 800; color: var(--text-primary); letter-spacing: -0.3px; }
.page-subtitle { font-size: 0.84rem; color: var(--text-secondary); margin-top: 4px; }

/* ============================================================
   TABS
   ============================================================ */
.tabs { display: flex; border-bottom: 1px solid rgba(255,255,255,0.06); margin-bottom: 24px; }

.tab-btn {
    padding: 10px 20px;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    margin-bottom: -1px;
}
.tab-btn.active { color: var(--accent-yellow); border-bottom-color: var(--accent-yellow); }
.tab-btn:hover:not(.active) { color: var(--text-primary); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ============================================================
   PAGINATION
   ============================================================ */
.pagination {
    display: flex; align-items: center; gap: 4px;
    justify-content: flex-end; padding: 16px 20px;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.page-btn {
    padding: 5px 11px;
    border-radius: 5px;
    border: 1px solid rgba(255,255,255,0.08);
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    font-size: 0.8rem;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    display: inline-flex; align-items: center;
}
.page-btn:hover, .page-btn.active {
    background: var(--accent-yellow);
    color: var(--bg-primary);
    border-color: var(--accent-yellow);
    font-weight: 700;
}
.page-btn.disabled { opacity: 0.3; cursor: not-allowed; pointer-events: none; }

/* ============================================================
   FILTER BAR
   ============================================================ */
.filter-bar {
    display: flex; flex-wrap: wrap; gap: 12px;
    align-items: flex-end;
    background: var(--bg-secondary);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--radius-md);
    padding: 18px;
    margin-bottom: 20px;
}
.filter-group { display: flex; flex-direction: column; gap: 6px; }

/* ============================================================
   AUTH PAGES
   ============================================================ */
.auth-page {
    min-height: 100vh;
    background: radial-gradient(ellipse 80% 60% at 50% -20%, rgba(240,185,11,0.06) 0%, transparent 70%), var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    position: relative;
    overflow: hidden;
}

.auth-page::before, .auth-page::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
}
.auth-page::before {
    width: 400px; height: 400px;
    background: radial-gradient(circle, rgba(240,185,11,0.05), transparent);
    top: -100px; right: -100px;
}
.auth-page::after {
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(14,203,129,0.04), transparent);
    bottom: -80px; left: -80px;
}

.auth-card {
    background: rgba(30,35,41,0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-lg);
    padding: 42px 38px;
    width: 100%;
    max-width: 430px;
    position: relative;
    z-index: 1;
    box-shadow: 0 32px 80px rgba(0,0,0,0.5), inset 0 0 0 1px rgba(255,255,255,0.04);
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0; left: 10%; right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(240,185,11,0.4), transparent);
    border-radius: 99px;
}

.auth-logo { display: flex; align-items: center; gap: 10px; margin-bottom: 32px; justify-content: center; }
.auth-title { font-size: 1.4rem; font-weight: 800; color: var(--text-primary); margin-bottom: 6px; letter-spacing: -0.3px; }
.auth-subtitle { font-size: 0.85rem; color: var(--text-secondary); margin-bottom: 28px; }

.auth-footer { text-align: center; margin-top: 26px; font-size: 0.85rem; color: var(--text-secondary); }
.auth-footer a { color: var(--accent-yellow); text-decoration: none; font-weight: 600; }
.auth-footer a:hover { text-decoration: underline; }

.alert {
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    font-size: 0.84rem;
    margin-bottom: 18px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    border: 1px solid transparent;
}
.alert-error   { background: rgba(246,70,93,0.08); border-color: rgba(246,70,93,0.25); color: #ff7088; }
.alert-success { background: rgba(14,203,129,0.08); border-color: rgba(14,203,129,0.25); color: #3ddba0; }

/* ============================================================
   SKELETON / SPINNER
   ============================================================ */
.skeleton {
    background: linear-gradient(90deg, var(--bg-tertiary) 25%, rgba(54,60,69,0.8) 50%, var(--bg-tertiary) 75%);
    background-size: 200% 100%;
    border-radius: 4px;
    animation: skeleton-pulse 1.6s ease-in-out infinite;
}

@keyframes skeleton-pulse {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.spinner {
    display: inline-block;
    width: 16px; height: 16px;
    border: 2px solid rgba(255,255,255,0.15);
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 0.65s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   MISC
   ============================================================ */
.chart-container { position: relative; width: 100%; }
.mono { font-family: 'Courier New', monospace; font-size: 0.78rem; }
.text-green  { color: var(--green); }
.text-red    { color: var(--red); }
.text-yellow { color: var(--accent-yellow); }
.text-muted  { color: var(--text-secondary); }
.text-blue   { color: var(--blue); }
.section-gap { margin-bottom: 24px; }

/* ============================================================
   MODAL
   ============================================================ */
.modal-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.75);
    z-index: 300;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(4px);
}
.modal-backdrop.open { display: flex; }

.modal {
    background: var(--bg-secondary);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 680px;
    max-height: 85vh;
    overflow-y: auto;
    animation: modal-appear 0.2s cubic-bezier(0.34,1.56,0.64,1);
    box-shadow: 0 32px 80px rgba(0,0,0,0.6);
}

@keyframes modal-appear {
    from { opacity: 0; transform: scale(0.92) translateY(12px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
    padding: 18px 22px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    display: flex; align-items: center; justify-content: space-between;
    position: sticky; top: 0;
    background: var(--bg-secondary);
    z-index: 1;
}
.modal-close {
    background: var(--bg-tertiary); border: none; color: var(--text-secondary);
    font-size: 0.9rem; cursor: pointer; padding: 6px 8px; border-radius: var(--radius-sm);
    transition: var(--transition);
}
.modal-close:hover { color: var(--text-primary); background: var(--bg-quaternary); }
.modal-body { padding: 22px; }

/* ============================================================
   LIVE SEARCH DROPDOWN
   ============================================================ */
.search-results-dropdown {
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--bg-secondary);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: var(--radius-sm);
    z-index: 200;
    max-height: 220px;
    overflow-y: auto;
    display: none;
    box-shadow: 0 16px 48px rgba(0,0,0,0.5);
    margin-top: 4px;
}
.search-results-dropdown.open { display: block; }

.search-result-item {
    padding: 10px 14px; cursor: pointer;
    font-size: 0.84rem;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    transition: var(--transition);
}
.search-result-item:last-child { border-bottom: none; }
.search-result-item:hover { background: var(--bg-tertiary); }

/* ============================================================
   BALANCE PREVIEW
   ============================================================ */
.balance-preview {
    background: var(--bg-tertiary);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--radius-sm);
    padding: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.84rem;
}
.preview-arrow { color: var(--text-secondary); font-size: 1rem; }

/* ============================================================
   LANDING PAGE -- NAVIGATION
   ============================================================ */
.landing-nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    background: rgba(11,14,17,0.8);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 clamp(24px, 5vw, 80px);
}

/* ============================================================
   LANDING PAGE -- HERO
   ============================================================ */
.landing-hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 120px 24px 80px;
    position: relative;
    overflow: hidden;
}

.landing-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(240,185,11,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(240,185,11,0.04) 1px, transparent 1px);
    background-size: 60px 60px;
    -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
    mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
}

/* -- Glow orbs ----------------------------------------------- */
.hero-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
    animation: orb-float 8s ease-in-out infinite;
}
.hero-orb-1 { width: 500px; height: 500px; background: radial-gradient(circle, rgba(240,185,11,0.08), transparent 70%); top: -150px; left: -100px; animation-delay: 0s; }
.hero-orb-2 { width: 400px; height: 400px; background: radial-gradient(circle, rgba(14,203,129,0.06), transparent 70%); bottom: -100px; right: -80px; animation-delay: 3s; }
.hero-orb-3 { width: 300px; height: 300px; background: radial-gradient(circle, rgba(24,144,255,0.05), transparent 70%); top: 40%; left: 60%; animation-delay: 1.5s; }

@keyframes orb-float {
    0%, 100% { transform: translateY(0) scale(1); }
    50%       { transform: translateY(-20px) scale(1.05); }
}

/* -- Hero content -------------------------------------------- */
.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(240,185,11,0.1);
    border: 1px solid rgba(240,185,11,0.2);
    border-radius: 99px;
    padding: 5px 14px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-yellow);
    letter-spacing: 0.5px;
    margin-bottom: 24px;
    position: relative;
    z-index: 1;
    animation: fade-up 0.6s ease both;
}

.hero-title {
    font-size: clamp(2.8rem, 6vw, 4.5rem);
    font-weight: 900;
    color: var(--text-primary);
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
    animation: fade-up 0.6s 0.1s ease both;
}

.hero-title .gradient-text {
    background: linear-gradient(135deg, #F0B90B 0%, #FFD700 40%, #F0B90B 80%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    background-size: 200% 200%;
    animation: gradient-shift 4s ease infinite;
}

@keyframes gradient-shift {
    0%, 100% { background-position: 0% 50%; }
    50%       { background-position: 100% 50%; }
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--text-secondary);
    max-width: 560px;
    line-height: 1.7;
    margin-bottom: 36px;
    position: relative;
    z-index: 1;
    animation: fade-up 0.6s 0.2s ease both;
}

.hero-cta {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    justify-content: center;
    position: relative;
    z-index: 1;
    animation: fade-up 0.6s 0.3s ease both;
}

@keyframes fade-up {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* -- Hero buttons -------------------------------------------- */
.btn-hero-primary {
    background: linear-gradient(135deg, #F0B90B, #D4A009);
    color: #0B0E11;
    font-weight: 700;
    font-size: 1rem;
    padding: 14px 34px;
    border-radius: var(--radius-sm);
    border: none;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 8px 32px rgba(240,185,11,0.35);
    transition: var(--transition);
}
.btn-hero-primary:hover {
    box-shadow: 0 12px 48px rgba(240,185,11,0.5);
    transform: translateY(-2px);
    background: linear-gradient(135deg, #FFD000, #F0B90B);
}

.btn-hero-secondary {
    background: rgba(255,255,255,0.04);
    color: var(--text-primary);
    font-weight: 600;
    font-size: 1rem;
    padding: 14px 34px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255,255,255,0.1);
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    backdrop-filter: blur(8px);
    transition: var(--transition);
}
.btn-hero-secondary:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.2);
    transform: translateY(-2px);
}

/* -- Hero ticker strip --------------------------------------- */
.hero-ticker-strip {
    position: relative;
    z-index: 1;
    margin-top: 52px;
    width: 100%;
    max-width: 780px;
    background: rgba(30,35,41,0.7);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.07);
    border-radius: 12px;
    padding: 14px 20px;
    overflow: hidden;
    animation: fade-up 0.6s 0.4s ease both;
}

.hero-ticker-strip::before,
.hero-ticker-strip::after {
    content: '';
    position: absolute;
    top: 0; bottom: 0;
    width: 60px;
    z-index: 2;
    pointer-events: none;
}
.hero-ticker-strip::before { left: 0; background: linear-gradient(90deg, rgba(30,35,41,0.9), transparent); }
.hero-ticker-strip::after  { right: 0; background: linear-gradient(-90deg, rgba(30,35,41,0.9), transparent); }

/* -- Hero stats --------------------------------------------- */
.hero-stats {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    width: 100%;
    max-width: 780px;
    margin-top: 20px;
    position: relative;
    z-index: 1;
    animation: fade-up 0.6s 0.5s ease both;
}

.hero-stat-item {
    flex: 1;
    min-width: 140px;
    padding: 16px 24px;
    border-right: 1px solid rgba(255,255,255,0.06);
    text-align: center;
}
.hero-stat-item:last-child { border-right: none; }
.hero-stat-num { font-size: 1.4rem; font-weight: 800; color: var(--text-primary); letter-spacing: -0.5px; }
.hero-stat-lbl { font-size: 0.72rem; color: var(--text-secondary); margin-top: 2px; }

/* ============================================================
   LANDING PAGE -- FEATURES / SECTIONS
   ============================================================ */
.features-section {
    padding: 80px clamp(24px, 6vw, 80px);
    max-width: 1100px;
    margin: 0 auto;
}

.section-eyebrow {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--accent-yellow);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 12px;
}

.section-title {
    font-size: clamp(1.8rem, 3.5vw, 2.6rem);
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.8px;
    line-height: 1.2;
    margin-bottom: 16px;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
    margin-top: 48px;
}

.feature-card {
    background: var(--bg-secondary);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: var(--radius-lg);
    padding: 28px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(240,185,11,0.03), transparent);
    opacity: 0;
    transition: var(--transition);
}

.feature-card:hover { border-color: rgba(240,185,11,0.2); transform: translateY(-4px); box-shadow: 0 16px 40px rgba(0,0,0,0.3); }
.feature-card:hover::before { opacity: 1; }

.feature-icon {
    width: 46px; height: 46px;
    background: linear-gradient(135deg, rgba(240,185,11,0.15), rgba(240,185,11,0.05));
    border: 1px solid rgba(240,185,11,0.15);
    border-radius: var(--radius-sm);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.1rem;
    color: var(--accent-yellow);
    margin-bottom: 16px;
}

.feature-title { font-size: 1rem; font-weight: 700; color: var(--text-primary); margin-bottom: 8px; }
.feature-desc  { font-size: 0.84rem; color: var(--text-secondary); line-height: 1.6; }

/* -- Coins showcase ------------------------------------------ */
.coins-showcase {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 20px;
}

.coin-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--bg-secondary);
    border: 1px solid rgba(255,255,255,0.06);
    border-radius: 99px;
    padding: 8px 16px;
    font-size: 0.84rem;
    font-weight: 600;
    transition: var(--transition);
}
.coin-pill:hover { border-color: rgba(255,255,255,0.15); transform: translateY(-2px); }
.coin-dot { width: 8px; height: 8px; border-radius: 50%; }

/* -- CTA section --------------------------------------------- */
.cta-section {
    margin: 0 clamp(24px, 6vw, 80px) 80px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, rgba(240,185,11,0.08) 0%, rgba(14,203,129,0.04) 100%);
    border: 1px solid rgba(240,185,11,0.15);
    padding: 60px 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.cta-section::before {
    content: '';
    position: absolute;
    top: -1px; left: 10%; right: 10%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent-yellow), transparent);
}

/* -- Footer -------------------------------------------------- */
.landing-footer {
    border-top: 1px solid rgba(255,255,255,0.05);
    padding: 32px clamp(24px, 6vw, 80px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}
.footer-copy { font-size: 0.8rem; color: var(--text-secondary); }
.footer-links { display: flex; gap: 20px; }
.footer-links a { font-size: 0.8rem; color: var(--text-secondary); text-decoration: none; transition: color 0.15s; }
.footer-links a:hover { color: var(--text-primary); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
    .sidebar { transform: translateX(-100%); }
    .sidebar.open { transform: translateX(0); }
    .sidebar-overlay.open { display: block; }
    .main-content { margin-left: 0; }
    .hamburger-btn { display: block; }
    .page-content { padding: 16px; }
    .wallet-grid { grid-template-columns: 1fr; }
    .filter-bar { flex-direction: column; }
    .filter-group { width: 100%; }
    .stat-value { font-size: 1.3rem; }
    .auth-card { padding: 28px 22px; }
    .hero-title { letter-spacing: -0.8px; }
    .hero-stat-item { min-width: 120px; }
    .cta-section { padding: 40px 24px; margin: 0 16px 60px; }
    .landing-footer { flex-direction: column; text-align: center; }
    .btn-hero-primary, .btn-hero-secondary { padding: 12px 24px; font-size: 0.9rem; }
}
