/* ============================================================
   TRADERATE — shared.css
   Design tokens · Reset · Nav · Footer · Theme toggle
   Imported by: marketing.css, portal.css
   ============================================================ */


/* ── DESIGN TOKENS ─────────────────────────────────────────── */
:root {
    --teal:       #0B7B6B;
    --teal-hover: #096658;
    --teal-light: #E6F4F1;
    --blue:       #2B6CB0;
    --blue-light: #EBF4FF;
    --alert:      #C05621;
    --alert-bg:   #FFF5F0;
    --green:      #276749;
    --green-light:#F0FFF4;
    --gold:       #B7791F;

    --trust-verified:   #276749;
    --trust-merchant:   #2B6CB0;
    --trust-system:     #718096;
    --trust-unverified: #A0AEC0;

    --s1: #C53030;
    --s2: #C05621;
    --s3: #718096;

    --tier-iron:     #718096;
    --tier-bronze:   #975A16;
    --tier-silver:   #4A5568;
    --tier-gold:     #B7791F;
    --tier-platinum: #2B6CB0;
    --tier-diamond:  #553C9A;

    --font: 'Instrument Sans', sans-serif;
    --mono: 'Roboto Mono', monospace;

    --ease: 0.3s ease;
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}


/* ── LIGHT THEME (Arctic) ───────────────────────────────────── */
[data-theme="light"] {
    --bg:         #F7F9FC;
    --bg-nav:     #1A365D;
    --bg-card:    #FFFFFF;
    --border:     #CBD5E0;
    --text-1:     #1A202C;
    --text-2:     #4A5568;
    --text-muted: #A0AEC0;
    --shadow:     0 2px 10px rgba(0,0,0,0.05);
    --grid-line:  rgba(11,123,107,0.10);
    --row-spike:  #FFF5F0;

    --accent:        var(--teal);
    --accent-h:      var(--teal-hover);
    --accent-subtle: rgba(11,123,107,0.07);
}


/* ── DARK THEME (Arctic Night) ──────────────────────────────── */
[data-theme="dark"] {
    --bg:         #0D1B2A;
    --bg-nav:     #0A1628;
    --bg-card:    #132030;
    --border:     #1E3448;
    --text-1:     #EDF2F7;
    --text-2:     #90A4B7;
    --text-muted: #4A6070;
    --shadow:     0 4px 20px rgba(0,0,0,0.4);
    --grid-line:  rgba(45,212,191,0.08);
    --row-spike:  rgba(197,48,48,0.15);

    --accent:        #2DD4BF;
    --accent-h:      #14B8A6;
    --accent-subtle: rgba(45,212,191,0.10);
}


/* ── RESET ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { height: 100%; scroll-behavior: smooth; }

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text-1);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: background var(--ease), color var(--ease);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

.sr-only {
    position: absolute; width: 1px; height: 1px;
    padding: 0; margin: -1px; overflow: hidden;
    clip: rect(0,0,0,0); border: 0;
}


/* ── NAV ────────────────────────────────────────────────────── */
nav {
    position: relative;
    z-index: 10;
    height: 60px;
    background: var(--bg-nav);
    border-bottom: 2px solid var(--accent);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 36px;
    transition: background var(--ease), border-color var(--ease);
}

.logo {
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}
.logo span { color: var(--accent); }

.logo-app {
    font-size: 0.6rem;
    margin-left: 2px;
    vertical-align: super;
}

.pulse-dot {
    width: 8px; height: 8px;
    background: #3ECF6A;
    border-radius: 50%;
    box-shadow: 0 0 8px #3ECF6A;
    animation: pulse-glow 2.4s ease-in-out infinite;
    flex-shrink: 0;
}

@keyframes pulse-glow {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.3; transform: scale(0.85); }
}

.nav-right { display: flex; align-items: center; gap: 10px; }

.nav-link {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(255,255,255,0.65);
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 5px;
    transition: color 0.2s, background 0.2s;
}
.nav-link:hover { color: #fff; background: rgba(255,255,255,0.08); }
.nav-link.active { color: var(--accent); }

.theme-btn {
    width: 32px; height: 32px;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 5px;
    color: rgba(255,255,255,0.7);
    font-size: 0.9rem;
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: border-color 0.2s, color 0.2s;
    flex-shrink: 0;
}
.theme-btn:hover { border-color: var(--accent); color: var(--accent); }


/* ── FOOTER ─────────────────────────────────────────────────── */
footer {
    position: relative;
    z-index: 1;
    background: var(--bg-nav);
    border-top: 2px solid var(--accent);
    padding: 20px 36px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    transition: background var(--ease), border-color var(--ease);
}
.footer-logo { font-size: 0.95rem; font-weight: 700; letter-spacing: 0.1em; color: #fff; }
.footer-logo span { color: var(--accent); }
footer p { font-size: 0.75rem; color: rgba(255,255,255,0.3); }


/* ── SHARED BUTTONS ─────────────────────────────────────────── */
.btn-primary {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    border: none;
    padding: 13px 36px;
    border-radius: 7px;
    font-family: var(--font);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s, transform 0.1s;
    letter-spacing: 0.02em;
}
.btn-primary:hover  { background: var(--accent-h); }
.btn-primary:active { transform: scale(0.97); }


/* ── ANIMATIONS ─────────────────────────────────────────────── */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}


/* ── RESPONSIVE NAV / FOOTER ────────────────────────────────── */
@media (max-width: 600px) {
    nav, footer { padding-left: 20px; padding-right: 20px; }
    footer { flex-direction: column; text-align: center; }
}
