/* ============================================================
   RESET & BASE
============================================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
/* The hidden attribute must always win, even over author display rules */
[hidden] { display: none !important; }
button { font: inherit; cursor: pointer; }
a { color: inherit; }
ul, ol { list-style: none; }
img, svg { display: block; }
input, select { font: inherit; }
details > summary { cursor: pointer; list-style: none; }
details > summary::-webkit-details-marker { display: none; }

/* ============================================================
   DESIGN SYSTEM
============================================================ */
:root {
    color-scheme: dark;

    /* Surfaces */
    --bg:        #0a0a0f;
    --surface:   #14141c;
    --surface-2: #1c1c28;

    /* Neon palette — primary cyan, secondary magenta */
    --neon-1:      #00f0ff;
    --neon-2:      #ff2bd6;
    --neon-hazard: #ffdd00;
    --neon-error:  #ff3b3b;
    --neon-ok:     #00ff9c;

    /* Text — never pure white */
    --text:       #c8d2e0;
    --text-muted: #4a5a6e;
    --text-dim:   #2a3040;

    /* Borders */
    --border:    rgba(0, 240, 255, 0.1);
    --border-hi: rgba(0, 240, 255, 0.22);

    /* Typography */
    --font-display: 'Orbitron', sans-serif;
    --font-mono:    'JetBrains Mono', 'SFMono-Regular', Consolas, monospace;
    --font-body:    'Inter', 'Segoe UI', Roboto, Arial, sans-serif;

    /* Static glows — animate via pseudo-element opacity, not the shadow itself */
    --glow-cyan: 0 0 6px rgba(0,240,255,.8), 0 0 18px rgba(0,240,255,.35), 0 0 40px rgba(0,240,255,.12);
    --glow-mag:  0 0 6px rgba(255,43,214,.8), 0 0 18px rgba(255,43,214,.35);
    --glow-haz:  0 0 6px rgba(255,221,0,.8),  0 0 18px rgba(255,221,0,.35);
    --glow-err:  0 0 6px rgba(255,59,59,.8),   0 0 18px rgba(255,59,59,.35);

    /* Angled clip-path corners */
    --clip-card: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 14px 100%, 0 calc(100% - 14px));
    --clip-btn:  polygon(0 0, calc(100% - 7px) 0,  100% 7px,  100% 100%, 7px 100%,  0 calc(100% - 7px));

    /* Layout */
    --header-h: 64px;

    /* Legacy aliases — keep so any stray references still resolve */
    --ink:          var(--text);
    --ink-soft:     var(--text);
    --muted:        var(--text-muted);
    --accent:       var(--neon-1);
    --accent-dim:   rgba(0,240,255,.08);
    --accent-btn:   rgba(0,240,255,.12);
    --accent-btn-h: rgba(0,240,255,.2);
    --danger:       var(--neon-error);
    --danger-dim:   rgba(255,59,59,.1);
    --success:      var(--neon-ok);
    --premium:      var(--neon-hazard);
    --surface-soft: var(--surface-2);
    --surface-hi:   var(--surface-2);
    --line:         var(--border);
    --line-hi:      var(--border-hi);
    --radius-sm:    4px;
    --radius-md:    8px;
    --radius-lg:    12px;
    --shadow-sm:    0 2px 8px rgba(0,0,0,.45);
    --shadow-md:    0 4px 24px rgba(0,0,0,.55);
    --shadow-lg:    0 12px 48px rgba(0,0,0,.65);
}

/* Slightly lighter dark variant for "light" toggle */
body.light {
    color-scheme: dark;
    --bg:        #111118;
    --surface:   #18182a;
    --surface-2: #20203a;
    --text:       #d8e2f0;
    --text-muted: #5a6a80;
    --border:    rgba(0,240,255,.14);
    --border-hi: rgba(0,240,255,.28);
}

/* ============================================================
   MATRIX CANVAS
============================================================ */
#matrix-rain {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: -1;
    pointer-events: none;
    opacity: .07;
}

/* ============================================================
   SCANLINE TEXTURE (very subtle, behind content)
============================================================ */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9998;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(0,0,0,.025) 2px,
        rgba(0,0,0,.025) 4px
    );
}

/* ============================================================
   BODY
============================================================ */
body {
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.6;
}

/* ============================================================
   CONTAINERS
============================================================ */
.container       { width: min(680px,  100% - 32px); margin-inline: auto; }
.container--wide { width: min(1140px, 100% - 48px); margin-inline: auto; }

/* ============================================================
   TYPOGRAPHY
============================================================ */
h1 {
    font-family: var(--font-display);
    font-size: clamp(1.7rem, 4.5vw, 3rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.01em;
    color: var(--text);
}
h2 {
    font-family: var(--font-display);
    font-size: clamp(1.2rem, 2.5vw, 1.7rem);
    font-weight: 700;
    line-height: 1.2;
    margin-top: 6px;
    color: var(--text);
}
h3 { font-size: 1.05rem; font-weight: 700; line-height: 1.3; }
h4 {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.eyebrow, .section-kicker {
    display: block;
    font-family: var(--font-mono);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--neon-1);
    margin-bottom: 8px;
    text-shadow: 0 0 10px rgba(0,240,255,.5);
}

/* ============================================================
   BUTTONS
============================================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 38px;
    padding: 0 16px;
    border: 1px solid var(--border-hi);
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: .82rem;
    letter-spacing: .05em;
    white-space: nowrap;
    clip-path: var(--clip-btn);
    transition: background 150ms, border-color 150ms, color 150ms, transform 120ms;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }
.btn:disabled { opacity: .4; cursor: not-allowed; transform: none; }

.btn.primary {
    background: rgba(0,240,255,.1);
    border-color: var(--neon-1);
    color: var(--neon-1);
}
.btn.primary:hover:not(:disabled) {
    background: rgba(0,240,255,.18);
    box-shadow: var(--glow-cyan);
}

.btn.ghost {
    background: transparent;
    color: var(--text-muted);
}
.btn.ghost:hover:not(:disabled) {
    background: var(--surface-2);
    border-color: var(--neon-1);
    color: var(--text);
}

.btn-sm { min-height: 30px; padding: 0 12px; font-size: .78rem; }

.btn-premium {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 34px;
    padding: 0 14px;
    border: 1px solid var(--neon-hazard);
    background: rgba(255,221,0,.07);
    color: var(--neon-hazard);
    font-family: var(--font-mono);
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .06em;
    white-space: nowrap;
    clip-path: var(--clip-btn);
    transition: background 150ms, box-shadow 150ms;
}
.btn-premium:hover { background: rgba(255,221,0,.14); box-shadow: var(--glow-haz); }

/* ============================================================
   HEADER
============================================================ */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(10,10,15,.88);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    height: var(--header-h);
    width: min(1140px, 100% - 48px);
    margin-inline: auto;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}
.brand-mark {
    width: 36px;
    height: 36px;
    border: 1px solid var(--neon-1);
    background: rgba(0,240,255,.08);
    color: var(--neon-1);
    display: grid;
    place-items: center;
    box-shadow: var(--glow-cyan);
    clip-path: var(--clip-btn);
    flex-shrink: 0;
}
/* Hide the envelope line behind the padlock body */
.brand-mark .lock-body { fill: var(--bg); }
.brand-name {
    display: block;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: .88rem;
    line-height: 1.1;
    color: var(--text);
    letter-spacing: .05em;
}
.brand-tagline {
    display: block;
    font-family: var(--font-mono);
    font-size: .64rem;
    color: var(--text-muted);
    letter-spacing: .06em;
}

.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-link {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 12px;
    font-family: var(--font-mono);
    font-size: .78rem;
    font-weight: 600;
    letter-spacing: .04em;
    color: var(--text-muted);
    text-decoration: none;
    transition: color 150ms, background 150ms;
}
.nav-link:hover { color: var(--neon-1); background: rgba(0,240,255,.05); }

.header-right { display: flex; align-items: center; gap: 8px; }

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 30px;
    padding: 0 10px;
    border: 1px solid var(--border);
    background: var(--surface);
    font-family: var(--font-mono);
    font-size: .7rem;
    color: var(--text-muted);
    letter-spacing: .04em;
    clip-path: var(--clip-btn);
}
.status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--neon-hazard);
    flex-shrink: 0;
    transition: background 300ms;
}
.status-dot.ok    { background: var(--neon-ok);    box-shadow: 0 0 6px var(--neon-ok); }
.status-dot.error { background: var(--neon-error); box-shadow: 0 0 6px var(--neon-error); }

.icon-btn {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-muted);
    clip-path: var(--clip-btn);
    font-size: .95rem;
    transition: border-color 150ms, color 150ms;
}
.icon-btn:hover { border-color: var(--neon-1); color: var(--neon-1); }

.icon-dark, .icon-light { line-height: 1; }
body.light .icon-dark  { display: none; }
body:not(.light) .icon-light { display: none; }

.hamburger-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4px;
}
.hamburger-btn span {
    display: block;
    width: 18px;
    height: 2px;
    background: var(--text-muted);
    transition: background 150ms;
}
.hamburger-btn:hover span { background: var(--neon-1); }

.mobile-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 16px 16px;
    border-top: 1px solid var(--border);
    background: rgba(10,10,15,.96);
}
.mobile-nav .nav-link { font-size: .9rem; }
.mobile-nav .btn-premium { align-self: flex-start; }

/* ============================================================
   AD SLOTS
============================================================ */
.ad-slot {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    color: var(--text-muted);
    font-size: .76rem;
}
.ad-leaderboard { min-height: 90px; }
.ad-infeed {
    min-height: 280px;
    margin: 24px 0;
    border: 1px dashed var(--border);
}
.ad-label {
    position: absolute;
    top: 6px; left: 10px;
    font-family: var(--font-mono);
    font-size: .66rem;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: var(--text-muted);
    opacity: .4;
}
@media (max-width: 600px) { .ad-leaderboard { display: none; } }

/* ============================================================
   HERO
============================================================ */
.hero {
    padding: 60px 0 44px;
    text-align: center;
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
}
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 70% 55% at 50% 0%, rgba(0,240,255,.05) 0%, transparent 70%);
    pointer-events: none;
}

.hero-br { display: none; }
@media (min-width: 640px) { .hero-br { display: inline; } }

.hero .eyebrow { margin-bottom: 16px; }

/* Glitch headline */
.hero-headline {
    display: block;
    margin-bottom: 20px;
    animation: glitch-headline 8s steps(1) infinite;
}
@keyframes glitch-headline {
    0%, 85%, 100% { text-shadow: 0 0 30px rgba(0,240,255,.18); }
    87%  { text-shadow: -4px 0 var(--neon-2), 4px 0 rgba(0,240,255,.6); transform: translateX(-2px); }
    89%  { text-shadow: 3px 0 var(--neon-2), -3px 0 rgba(0,240,255,.6); transform: translateX(2px) skewX(-1deg); }
    91%  { text-shadow: 0 0 28px rgba(0,240,255,.25); transform: none; }
}

.hero-sub {
    max-width: 500px;
    margin-inline: auto;
    color: var(--text-muted);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 32px;
}

.hero-badges {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}
.badge-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 110px;
    padding: 12px 16px;
    border: 1px solid var(--border);
    background: var(--surface);
    clip-path: var(--clip-card);
    position: relative;
}
.badge-item::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0,240,255,.03);
    pointer-events: none;
}
.badge-item strong {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--neon-1);
    text-shadow: 0 0 12px rgba(0,240,255,.5);
}
.badge-item span {
    font-family: var(--font-mono);
    font-size: .68rem;
    color: var(--text-muted);
    margin-top: 3px;
    letter-spacing: .05em;
}

/* ============================================================
   APP WRAP
============================================================ */
.app-wrap { padding: 32px 0 0; }
.app-wrap > .container { display: flex; flex-direction: column; gap: 16px; }

/* ============================================================
   ADDRESS CARD
============================================================ */
.address-card {
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 28px;
    clip-path: var(--clip-card);
    position: relative;
    box-shadow: 0 0 40px rgba(0,240,255,.03), inset 0 1px 0 rgba(0,240,255,.05);
}
/* Top accent line */
.address-card::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, var(--neon-1), transparent 55%);
    opacity: .45;
}

.address-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
}

/* ============================================================
   COUNTDOWN SVG RING
============================================================ */
.countdown-wrap { flex-shrink: 0; }

.countdown-badge {
    position: relative;
    width: 88px;
    height: 88px;
}
.countdown-ring { display: block; }
.countdown-track { stroke: rgba(0,240,255,.1); }
.countdown-arc   { stroke: var(--neon-1); transition: stroke 1s linear; }

.countdown-center {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
}
.countdown-val {
    font-family: var(--font-mono);
    font-size: .86rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    color: var(--neon-1);
    line-height: 1;
    text-shadow: 0 0 8px rgba(0,240,255,.6);
}
.countdown-lbl {
    font-family: var(--font-mono);
    font-size: .52rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: .08em;
}
.countdown-badge.expiring .countdown-val {
    color: var(--neon-hazard);
    text-shadow: 0 0 8px rgba(255,221,0,.6);
}

/* ============================================================
   ADDRESS ROW
============================================================ */
.address-builder { margin-bottom: 20px; }

.address-row {
    display: flex;
    align-items: center;
    background: var(--surface-2);
    border: 1px solid var(--border-hi);
    padding: 14px 18px;
    min-height: 64px;
    flex-wrap: wrap;
    gap: 4px;
    clip-path: var(--clip-btn);
    box-shadow: inset 0 0 20px rgba(0,240,255,.02);
}

.username-wrap { display: flex; align-items: center; gap: 8px; min-width: 0; }

.username-display {
    font-family: var(--font-mono);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--neon-1);
    text-shadow: 0 0 14px rgba(0,240,255,.5);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 220px;
}

.change-link {
    border: none;
    background: none;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: .7rem;
    letter-spacing: .05em;
    padding: 2px 6px;
    transition: color 150ms;
}
.change-link:hover { color: var(--neon-1); }

.at-sep {
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-muted);
    padding: 0 2px;
    flex-shrink: 0;
}

.domain-wrap { display: flex; align-items: center; min-width: 0; }
.domain-select {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: .9rem;
    font-weight: 600;
    cursor: pointer;
    padding: 2px 20px 2px 4px;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%234a5a6e'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 4px center;
}
.domain-select:focus { outline: 1px solid var(--neon-1); outline-offset: 2px; }

.username-editor {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    flex-wrap: wrap;
}
.username-input {
    flex: 1;
    min-width: 160px;
    height: 34px;
    padding: 0 12px;
    border: 1px solid var(--border-hi);
    background: var(--surface-2);
    color: var(--text);
    font-family: var(--font-mono);
    font-size: .88rem;
    transition: border-color 150ms, box-shadow 150ms;
    clip-path: var(--clip-btn);
}
.username-input:focus {
    outline: none;
    border-color: var(--neon-1);
    box-shadow: 0 0 10px rgba(0,240,255,.2);
}
.username-input::placeholder { color: var(--text-muted); }

.username-error {
    margin-top: 6px;
    font-family: var(--font-mono);
    font-size: .78rem;
    color: var(--neon-error);
    padding: 6px 10px;
    background: rgba(255,59,59,.07);
    border-left: 2px solid var(--neon-error);
}

/* ============================================================
   QUICK ACTIONS
============================================================ */
.quick-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 38px;
    padding: 0 16px;
    border: 1px solid var(--border);
    background: var(--surface-2);
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .05em;
    clip-path: var(--clip-btn);
    transition: border-color 150ms, color 150ms, background 150ms;
    flex-shrink: 0;
    min-width: 44px; /* touch target */
}
.action-btn:hover  { border-color: var(--neon-1); color: var(--neon-1); background: rgba(0,240,255,.05); }
.action-btn:active { transform: none; }
.action-btn svg    { flex-shrink: 0; }

.action-btn.action-danger       { color: var(--neon-error); }
.action-btn.action-danger:hover { border-color: var(--neon-error); background: rgba(255,59,59,.06); }

/* Copy button — primary CTA, stands apart from the other action buttons */
.action-btn--copy {
    border-color: var(--neon-1);
    color: var(--neon-1);
    background: rgba(0,240,255,.08);
    box-shadow: 0 0 10px rgba(0,240,255,.2), inset 0 0 10px rgba(0,240,255,.04);
    padding: 0 20px;
}
.action-btn--copy:hover {
    background: rgba(0,240,255,.15) !important;
    box-shadow: var(--glow-cyan) !important;
    border-color: var(--neon-1) !important;
    color: var(--neon-1) !important;
}

/* Icon pair — clipboard shown by default, checkmark on .copied */
.icon-check { display: none; }
.action-btn.copied .icon-copy  { display: none; }
.action-btn.copied .icon-check { display: block; }

/* Copied state: green + scale-pulse animation */
.action-btn.copied {
    border-color: var(--neon-ok) !important;
    color: var(--neon-ok) !important;
    background: rgba(0,255,156,.08) !important;
    box-shadow: 0 0 14px rgba(0,255,156,.35) !important;
    animation: copy-flash 0.35s ease forwards;
}
@keyframes copy-flash {
    0%   { transform: scale(1); }
    40%  { transform: scale(1.09); }
    100% { transform: scale(1); }
}

/* Refresh spinner while loading */
.action-btn.loading svg { animation: spin 0.7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ============================================================
   ADDRESS STATS
============================================================ */
.addr-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}
.addr-stat {
    padding: 12px 14px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    clip-path: var(--clip-btn);
}
.addr-stat-lbl {
    display: block;
    font-family: var(--font-mono);
    font-size: .64rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 4px;
}
.addr-stat-val {
    display: block;
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    font-variant-numeric: tabular-nums;
}

/* ============================================================
   INBOX SECTION
============================================================ */
.inbox-section {
    background: var(--surface);
    border: 1px solid var(--border);
    overflow: hidden;
    clip-path: var(--clip-card);
    position: relative;
}
/* Magenta top accent (distinguishes inbox from address card) */
.inbox-section::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--neon-2) 40%, transparent);
    opacity: .35;
    z-index: 1;
}

.inbox-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    flex-wrap: wrap;
}

/* Tabs */
.inbox-tabs { display: flex; gap: 4px; }
.tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    height: 32px;
    padding: 0 14px;
    border: 1px solid transparent;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .04em;
    clip-path: var(--clip-btn);
    transition: background 150ms, color 150ms, border-color 150ms;
}
.tab-btn:hover { background: var(--surface-2); color: var(--text); }
.tab-btn.active {
    background: rgba(0,240,255,.08);
    border-color: var(--neon-1);
    color: var(--neon-1);
}

.tab-count {
    min-width: 18px;
    height: 16px;
    padding: 0 5px;
    background: var(--neon-2);
    color: var(--bg);
    font-size: .64rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.inbox-tools { display: flex; align-items: center; gap: 10px; }
.inbox-hint {
    font-family: var(--font-mono);
    font-size: .7rem;
    color: var(--text-muted);
    white-space: nowrap;
    letter-spacing: .04em;
}

.tab-panel { display: block; }
.tab-panel[hidden] { display: none; }

/* OTP bar */
.otp-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: linear-gradient(90deg, rgba(0,240,255,.07), transparent);
    border-bottom: 1px solid var(--neon-1);
    border-left: 3px solid var(--neon-1);
    flex-wrap: wrap;
}
.otp-bar[hidden] { display: none; }
.otp-icon { font-size: 1rem; flex-shrink: 0; }
.otp-content { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 120px; }
.otp-lbl {
    font-family: var(--font-mono);
    font-size: .64rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--text-muted);
}
.otp-code {
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: .2em;
    color: var(--neon-1);
    text-shadow: var(--glow-cyan);
}
.otp-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ============================================================
   EMAIL LIST
============================================================ */
.email-list { display: flex; flex-direction: column; }
.email-list > * + * { border-top: 1px solid var(--border); }

.email-card {
    padding: 16px 20px;
    position: relative;
    border-left: 2px solid transparent;
    transition: background 150ms, border-left-color 150ms;
    animation: slideIn 260ms ease both;
}
.email-card:hover {
    background: var(--surface-2);
    border-left-color: var(--neon-1);
}

@keyframes slideIn {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: none; }
}

.email-from {
    font-family: var(--font-mono);
    font-size: .74rem;
    color: var(--text-muted);
    margin-bottom: 3px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.email-subject {
    font-weight: 700;
    font-size: .95rem;
    color: var(--text);
    margin-bottom: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.email-preview {
    font-family: var(--font-mono);
    font-size: .76rem;
    color: var(--text-muted);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 10px;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}
.email-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    flex-wrap: wrap;
}
.email-time {
    font-family: var(--font-mono);
    font-size: .7rem;
    color: var(--text-muted);
    letter-spacing: .03em;
}
.email-actions { display: flex; gap: 6px; }
.email-action-btn {
    height: 28px;
    min-width: 44px;
    padding: 0 10px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .03em;
    clip-path: var(--clip-btn);
    transition: border-color 150ms, color 150ms;
}
.email-action-btn:hover { border-color: var(--neon-1); color: var(--neon-1); }

/* Empty state */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 220px;
    padding: 40px 24px;
    text-align: center;
}
.empty-svg    { color: var(--text-muted); opacity: .3; }
.empty-title  { font-family: var(--font-mono); font-weight: 700; color: var(--text-muted); font-size: .88rem; letter-spacing: .05em; }
.empty-hint   { font-size: .84rem; color: var(--text-muted); max-width: 280px; opacity: .7; }

/* Skeleton shimmer */
.skeleton { padding: 16px 20px; position: relative; overflow: hidden; }
.skeleton-line, .skeleton-block {
    background: var(--surface-2);
    border-radius: 2px;
    margin-bottom: 10px;
}
.skeleton-line  { height: 10px; }
.skeleton-block { height: 60px; margin-bottom: 0; }
.w-30 { width: 30%; }
.w-40 { width: 40%; }
.w-70 { width: 70%; }
.skeleton::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent 20%, rgba(0,240,255,.045) 50%, transparent 80%);
    transform: translateX(-100%);
    animation: shimmer 1.6s infinite;
}
@keyframes shimmer { to { transform: translateX(100%); } }

/* ============================================================
   TOAST NOTIFICATIONS
============================================================ */
#toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9000;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
    max-width: 300px;
    width: max-content;
}
.toast {
    padding: 11px 16px;
    background: var(--surface-2);
    border: 1px solid var(--neon-1);
    border-left: 3px solid var(--neon-1);
    color: var(--text);
    font-family: var(--font-mono);
    font-size: .78rem;
    letter-spacing: .04em;
    clip-path: var(--clip-btn);
    box-shadow: var(--glow-cyan), var(--shadow-md);
    transform: translateX(110%);
    opacity: 0;
    transition: transform 300ms ease, opacity 300ms ease;
}
.toast--visible { transform: translateX(0); opacity: 1; }
.toast--mail {
    border-color: var(--neon-2);
    border-left-color: var(--neon-2);
    box-shadow: var(--glow-mag), var(--shadow-md);
}

/* ============================================================
   STATS STRIP
============================================================ */
.stats-strip {
    margin-top: 64px;
    padding: 40px 0;
    background: var(--surface);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    position: relative;
}
.stats-strip::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 50% 80% at 50% 50%, rgba(0,240,255,.025) 0%, transparent 70%);
    pointer-events: none;
}
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    text-align: center;
}
.stat-item  { display: flex; flex-direction: column; gap: 6px; }
.stat-big {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 900;
    color: var(--neon-1);
    font-variant-numeric: tabular-nums;
    line-height: 1;
    text-shadow: 0 0 22px rgba(0,240,255,.4);
}
.stat-lbl { font-family: var(--font-mono); font-size: .78rem; color: var(--text-muted); letter-spacing: .06em; }

/* ============================================================
   CONTENT SECTIONS
============================================================ */
.content-section { padding: 72px 0; }
.content-section--alt { background: var(--surface); }

.cs-inner {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 48px;
    align-items: start;
}
.cs-text h2          { margin-bottom: 20px; }
.cs-text p           { color: var(--text-muted); line-height: 1.75; margin-bottom: 14px; }
.cs-text p:last-child{ margin-bottom: 0; }
.cs-text strong      { color: var(--text); }

.info-card {
    padding: 20px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    clip-path: var(--clip-card);
}
.info-card h3 {
    margin-bottom: 12px;
    color: var(--text);
    font-family: var(--font-mono);
    font-size: .82rem;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.alias-list { display: flex; flex-direction: column; gap: 5px; }
.alias-list li {
    font-family: var(--font-mono);
    font-size: .8rem;
    color: var(--text-muted);
    padding: 5px 10px;
    background: var(--surface);
    border-left: 2px solid var(--neon-1);
}

/* How-to steps */
.section-head-center { text-align: center; margin-bottom: 40px; }
.how-steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}
.how-step {
    position: relative;
    padding: 36px 20px 24px;
    background: var(--surface);
    border: 1px solid var(--border);
    clip-path: var(--clip-card);
    text-align: center;
    transition: border-color 200ms;
}
.how-step:hover { border-color: var(--border-hi); }
.how-step-num {
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    width: 26px;
    height: 26px;
    background: var(--neon-1);
    color: var(--bg);
    font-family: var(--font-mono);
    font-size: .78rem;
    font-weight: 900;
    display: grid;
    place-items: center;
}
.how-step-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: rgba(0,240,255,.06);
    color: var(--neon-1);
    margin: 14px auto 12px;
    clip-path: var(--clip-btn);
}
.how-step h3 { margin-bottom: 8px; font-size: .95rem; }
.how-step p  { font-size: .84rem; color: var(--text-muted); line-height: 1.55; }

/* Feature grid */
.features-section { padding: 72px 0; }
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-top: 40px;
}
.feature-card {
    padding: 24px;
    background: var(--surface);
    border: 1px solid var(--border);
    clip-path: var(--clip-card);
    transition: border-color 200ms;
}
.feature-card:hover { border-color: var(--border-hi); }
.feature-icon {
    width: 42px;
    height: 42px;
    background: rgba(0,240,255,.06);
    color: var(--neon-1);
    display: grid;
    place-items: center;
    margin-bottom: 14px;
    clip-path: var(--clip-btn);
}
.feature-card h3 { margin-bottom: 8px; font-size: .95rem; color: var(--text); }
.feature-card p  { font-size: .84rem; color: var(--text-muted); line-height: 1.55; }

/* FAQ */
.faq-section { padding: 72px 0; background: var(--surface); }
.faq-list    { margin-top: 36px; display: flex; flex-direction: column; gap: 6px; }
.faq-item {
    background: var(--surface-2);
    border: 1px solid var(--border);
    overflow: hidden;
    transition: border-color 200ms;
}
.faq-item[open] { border-color: var(--neon-1); }
.faq-q {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 20px;
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: .86rem;
    color: var(--text);
    user-select: none;
    letter-spacing: .02em;
}
.faq-q::after {
    content: "+";
    font-size: 1.2rem;
    font-weight: 400;
    color: var(--text-muted);
    flex-shrink: 0;
    transition: transform 200ms;
}
.faq-item[open] .faq-q::after { transform: rotate(45deg); color: var(--neon-1); }
.faq-a { padding: 0 20px 16px; border-top: 1px solid var(--border); }
.faq-a p  { font-size: .88rem; color: var(--text-muted); line-height: 1.7; margin-top: 12px; }
.faq-a p + p { margin-top: 8px; }
.faq-a strong { color: var(--text); }
.faq-a em     { font-style: italic; }

/* Blog */
.blog-section { padding: 72px 0; }
.section-head-flex {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 36px;
}
.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.blog-card {
    background: var(--surface);
    border: 1px solid var(--border);
    clip-path: var(--clip-card);
    overflow: visible;
    transition: border-color 200ms;
}
.blog-card:hover { border-color: var(--border-hi); }
.blog-card-img {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 110px;
    background: var(--surface-2);
    color: var(--text-muted);
    opacity: .5;
}
.blog-card-body { padding: 18px 20px; }
.blog-tag {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: .64rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--neon-2);
    margin-bottom: 8px;
}
.blog-card h3   { font-size: .92rem; margin-bottom: 8px; }
.blog-card h3 a { text-decoration: none; color: var(--text); }
.blog-card h3 a:hover { color: var(--neon-1); }
.blog-card p    { font-size: .82rem; color: var(--text-muted); line-height: 1.55; }

/* Apps */
.apps-section { padding: 72px 0; background: var(--surface); }
.apps-inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: center;
}
.apps-text p { margin-top: 12px; color: var(--text-muted); line-height: 1.65; }
.apps-grid   { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.app-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: .82rem;
    font-weight: 700;
    text-decoration: none;
    letter-spacing: .03em;
    clip-path: var(--clip-btn);
    min-height: 44px;
    transition: border-color 180ms, color 180ms;
}
.app-badge:hover { border-color: var(--neon-1); color: var(--text); }
.soon-tag {
    margin-left: auto;
    font-size: .62rem;
    font-weight: 800;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: var(--text-muted);
}

/* Footer */
.site-footer {
    padding: 56px 0 0;
    background: var(--surface);
    border-top: 1px solid var(--border);
}
.footer-top {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 48px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--border);
}
.footer-brand .brand { margin-bottom: 14px; }
.footer-desc { font-size: .84rem; color: var(--text-muted); line-height: 1.6; max-width: 280px; }
.footer-nav  { display: flex; gap: 40px; }
.footer-col  { display: flex; flex-direction: column; gap: 10px; }
.footer-col a, .footer-link-btn {
    font-family: var(--font-mono);
    font-size: .82rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: color 140ms;
    background: none;
    border: none;
    text-align: left;
    padding: 0;
    letter-spacing: .03em;
    cursor: pointer;
}
.footer-col a:hover, .footer-link-btn:hover { color: var(--neon-1); }
.footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 0;
    flex-wrap: wrap;
}
.footer-copy { font-family: var(--font-mono); font-size: .76rem; color: var(--text-muted); letter-spacing: .04em; }
.lang-select {
    height: 30px;
    padding: 0 26px 0 10px;
    border: 1px solid var(--border);
    background: var(--surface-2);
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: .78rem;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%234a5a6e'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    clip-path: var(--clip-btn);
}

/* ============================================================
   MODALS
============================================================ */
.modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.modal[hidden] { display: none; }
.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.75);
    backdrop-filter: blur(6px);
}
.modal-panel {
    position: relative;
    z-index: 1;
    background: var(--surface);
    border: 1px solid var(--border-hi);
    clip-path: var(--clip-card);
    box-shadow: var(--glow-cyan), var(--shadow-lg);
    display: flex;
    flex-direction: column;
    max-height: calc(100vh - 32px);
    overflow: hidden;
    animation: modal-in 180ms ease;
}
.modal-sm { width: min(360px, 100%); }
.modal-lg { width: min(600px, 100%); }
@keyframes modal-in {
    from { opacity: 0; transform: scale(.96) translateY(10px); }
    to   { opacity: 1; transform: none; }
}
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}
.modal-header h3 {
    font-family: var(--font-display);
    font-size: .88rem;
    font-weight: 700;
    color: var(--neon-1);
    text-shadow: 0 0 10px rgba(0,240,255,.4);
    letter-spacing: .05em;
}
.modal-close-btn {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    min-width: 28px;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--text-muted);
    font-size: .8rem;
    flex-shrink: 0;
    clip-path: var(--clip-btn);
    transition: border-color 150ms, color 150ms;
}
.modal-close-btn:hover { border-color: var(--neon-error); color: var(--neon-error); }
.modal-body { padding: 20px; overflow-y: auto; flex: 1; }

/* QR modal */
.qr-body     { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.qr-canvas   { overflow: hidden; background: #fff; padding: 12px; }
.qr-canvas img, .qr-canvas canvas { display: block; }
.qr-addr {
    font-family: var(--font-mono);
    font-size: .82rem;
    color: var(--neon-1);
    word-break: break-all;
}
.qr-hint { font-family: var(--font-mono); font-size: .78rem; color: var(--text-muted); max-width: 260px; }

/* Message modal */
.msg-meta {
    font-family: var(--font-mono);
    font-size: .76rem;
    color: var(--text-muted);
    margin-bottom: 14px;
    letter-spacing: .03em;
}
.msg-body {
    padding: 14px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: .84rem;
    line-height: 1.65;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    min-height: 180px;
    max-height: 50vh;
    overflow-y: auto;
    margin-bottom: 14px;
}
.msg-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* Premium modal */
.premium-sub { font-family: var(--font-mono); color: var(--text-muted); margin-bottom: 24px; font-size: .85rem; }
.pricing-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.pricing-card {
    position: relative;
    padding: 24px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    clip-path: var(--clip-card);
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.pricing-featured {
    border-color: var(--neon-hazard);
    box-shadow: 0 0 20px rgba(255,221,0,.08);
}
.pricing-badge {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--neon-hazard);
    color: var(--bg);
    font-family: var(--font-mono);
    font-size: .64rem;
    font-weight: 800;
    padding: 2px 10px;
    white-space: nowrap;
    letter-spacing: .06em;
}
.pricing-tier  { font-family: var(--font-mono); font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--text-muted); }
.pricing-price { font-family: var(--font-display); font-size: 2rem; font-weight: 900; color: var(--text); line-height: 1; }
.pricing-per   { font-size: 1rem; font-weight: 400; color: var(--text-muted); }
.pricing-features { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.pricing-features li {
    font-family: var(--font-mono);
    font-size: .82rem;
    color: var(--text-muted);
    padding-left: 18px;
    position: relative;
}
.pricing-features li::before { content: ">"; position: absolute; left: 0; color: var(--neon-1); font-weight: 800; }
.pricing-card .btn { width: 100%; }

/* ============================================================
   RESPONSIVE
============================================================ */
@media (max-width: 1000px) {
    .how-steps    { grid-template-columns: repeat(2, 1fr); }
    .features-grid{ grid-template-columns: repeat(2, 1fr); }
    .blog-grid    { grid-template-columns: repeat(2, 1fr); }
    .blog-grid > *:last-child { display: none; }
    .cs-inner     { grid-template-columns: 1fr; }
    .cs-aside     { display: none; }
    .footer-top   { grid-template-columns: 1fr; gap: 32px; }
    .apps-inner   { grid-template-columns: 1fr; }
    .apps-grid    { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
    .nav-links    { display: none; }
    .hamburger-btn{ display: flex; }
    .how-steps    { grid-template-columns: 1fr 1fr; }
    .features-grid{ grid-template-columns: 1fr 1fr; }
    .blog-grid    { grid-template-columns: 1fr; }
    .blog-grid > *:last-child { display: block; }
    .footer-nav   { flex-direction: column; gap: 24px; }
    .pricing-grid { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
    h1 { font-size: 1.65rem; }
    .hero { padding: 40px 0 28px; }
    .hero-badges  { gap: 8px; }
    .badge-item   { min-width: 90px; padding: 10px 12px; }
    .quick-actions{ gap: 6px; }
    .action-btn span { display: none; }
    .action-btn   { padding: 0 10px; }
    .addr-stats   { grid-template-columns: repeat(3, 1fr); gap: 6px; }
    .addr-stat-val{ font-size: .9rem; }
    .stats-grid   { grid-template-columns: 1fr; text-align: left; }
    .how-steps    { grid-template-columns: 1fr; }
    .features-grid{ grid-template-columns: 1fr; }
    .content-section, .features-section, .faq-section, .blog-section, .apps-section { padding: 48px 0; }
    .inbox-head   { flex-direction: column; align-items: flex-start; }
    .username-display { max-width: 140px; }
    .section-head-flex{ flex-direction: column; align-items: flex-start; gap: 8px; }
    .apps-grid    { grid-template-columns: 1fr; }
    .footer-nav   { flex-wrap: wrap; gap: 20px; }
    .footer-col   { min-width: 120px; }
    .pricing-grid { grid-template-columns: 1fr; }
    #toast-container { bottom: 16px; right: 16px; max-width: 260px; }
}

@media (max-width: 400px) {
    .action-btn   { height: 36px; padding: 0 8px; }
    .addr-stats   { grid-template-columns: 1fr 1fr; }
    .addr-stats .addr-stat:last-child { grid-column: span 2; }
}

/* ============================================================
   SCROLL PROGRESS BAR
============================================================ */
.scroll-progress {
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: transparent;
    z-index: 10;
}
.scroll-progress span {
    display: block;
    height: 100%;
    width: 0;
    background: linear-gradient(90deg, var(--neon-1), var(--neon-2));
    box-shadow: 0 0 8px rgba(0,240,255,.6);
}

/* ============================================================
   HERO ORBS + GRID (parallax layers)
============================================================ */
.hero, .page-hero, .error-page { position: relative; overflow: hidden; }
.hero-orbs { position: absolute; inset: 0; pointer-events: none; }
.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(70px);
    opacity: .35;
    will-change: transform;
    animation: orb-drift 14s ease-in-out infinite alternate;
}
.orb-1 { width: 340px; height: 340px; top: -120px; left: 8%;  background: radial-gradient(circle, rgba(0,240,255,.5), transparent 70%); }
.orb-2 { width: 280px; height: 280px; top: 30px;  right: 6%;  background: radial-gradient(circle, rgba(255,43,214,.4), transparent 70%); animation-delay: -5s; animation-duration: 18s; }
.orb-3 { width: 220px; height: 220px; bottom: -100px; left: 42%; background: radial-gradient(circle, rgba(0,255,156,.3), transparent 70%); animation-delay: -9s; animation-duration: 22s; }
@keyframes orb-drift {
    from { transform: translate3d(0, 0, 0) scale(1); }
    to   { transform: translate3d(40px, 26px, 0) scale(1.12); }
}

.hero-grid {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(0,240,255,.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,240,255,.04) 1px, transparent 1px);
    background-size: 44px 44px;
    mask-image: radial-gradient(ellipse 75% 65% at 50% 35%, black 30%, transparent 75%);
    -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 35%, black 30%, transparent 75%);
    animation: grid-pan 24s linear infinite;
}
@keyframes grid-pan { to { background-position: 44px 44px; } }

.hero-cta-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 36px;
}
.btn-lg { min-height: 46px; padding: 0 26px; font-size: .92rem; }
.magnetic { will-change: transform; transition: transform 180ms ease-out, background 150ms, box-shadow 150ms; }

/* ============================================================
   KINETIC TICKER
============================================================ */
.ticker {
    overflow: hidden;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: var(--surface);
    padding: 9px 0;
    position: relative;
}
.ticker::before, .ticker::after {
    content: "";
    position: absolute;
    top: 0; bottom: 0;
    width: 80px;
    z-index: 1;
    pointer-events: none;
}
.ticker::before { left: 0;  background: linear-gradient(90deg, var(--bg), transparent); }
.ticker::after  { right: 0; background: linear-gradient(-90deg, var(--bg), transparent); }
.ticker-track {
    display: flex;
    align-items: center;
    gap: 28px;
    width: max-content;
    animation: ticker-scroll 28s linear infinite;
}
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-track span {
    font-family: var(--font-mono);
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .18em;
    color: var(--text-muted);
    white-space: nowrap;
}
.ticker-track i { font-style: normal; font-size: .55rem; color: var(--neon-1); text-shadow: 0 0 8px rgba(0,240,255,.7); }
@keyframes ticker-scroll { to { transform: translateX(-50%); } }

/* ============================================================
   SCROLL REVEAL
============================================================ */
.reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 600ms cubic-bezier(.22,.61,.36,1), transform 600ms cubic-bezier(.22,.61,.36,1);
    transition-delay: var(--reveal-delay, 0ms);
}
.reveal.in { opacity: 1; transform: none; }

/* ============================================================
   CURSOR GLOW + 3D TILT (cards)
============================================================ */
.glow-card { position: relative; }
.glow-card::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 250ms;
    background: radial-gradient(200px circle at var(--mx, 50%) var(--my, 50%), rgba(0,240,255,.09), transparent 65%);
}
.glow-card:hover::after { opacity: 1; }
.tilt-card {
    transform-style: preserve-3d;
    will-change: transform;
    transition: transform 200ms ease-out;
}

/* Typewriter caret on the address while typing */
.username-display.typing::after {
    content: "▌";
    color: var(--neon-1);
    animation: caret-blink .7s steps(1) infinite;
}
@keyframes caret-blink { 50% { opacity: 0; } }

/* Mobile nav slide-down */
.mobile-nav { animation: nav-drop 220ms ease; transform-origin: top; }
@keyframes nav-drop {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: none; }
}

/* ============================================================
   API SECTION
============================================================ */
.api-section { padding: 72px 0; background: var(--surface); }
.section-sub {
    max-width: 520px;
    margin: 12px auto 0;
    color: var(--text-muted);
    font-size: .92rem;
    line-height: 1.65;
}
.api-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-top: 40px;
}
.api-card {
    padding: 20px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    clip-path: var(--clip-card);
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: border-color 200ms;
}
.api-card:hover { border-color: var(--border-hi); }
.api-card > p { font-size: .82rem; color: var(--text-muted); line-height: 1.55; }
.api-card code { font-family: var(--font-mono); color: var(--neon-1); font-size: .8rem; }
.api-method { display: flex; align-items: center; gap: 8px; }
.method-tag {
    font-family: var(--font-mono);
    font-size: .64rem;
    font-weight: 800;
    letter-spacing: .08em;
    color: var(--neon-ok);
    border: 1px solid rgba(0,255,156,.4);
    background: rgba(0,255,156,.07);
    padding: 2px 7px;
    flex-shrink: 0;
}
.code-block {
    margin-top: auto;
    padding: 12px 14px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-left: 2px solid var(--neon-1);
    overflow-x: auto;
    font-size: .72rem;
    line-height: 1.65;
}
.code-block code { color: var(--text-muted); font-size: inherit; white-space: pre; }
.api-note {
    margin-top: 24px;
    text-align: center;
    font-family: var(--font-mono);
    font-size: .74rem;
    color: var(--text-muted);
    letter-spacing: .04em;
}

/* ============================================================
   SUBPAGES (blog / post / legal / 404)
============================================================ */
.container--narrow { width: min(760px, 100% - 32px); margin-inline: auto; }

.page-hero {
    padding: 56px 0 40px;
    border-bottom: 1px solid var(--border);
    text-align: left;
}
.page-hero--post { padding: 48px 0 36px; }
.page-title {
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3.6vw, 2.4rem);
    font-weight: 800;
    line-height: 1.15;
    color: var(--text);
    margin: 10px 0 14px;
}
.page-hero .hero-sub { margin: 0; max-width: 560px; }
.breadcrumb { margin-bottom: 18px; }
.breadcrumb a {
    font-family: var(--font-mono);
    font-size: .76rem;
    color: var(--text-muted);
    text-decoration: none;
    letter-spacing: .04em;
    transition: color 150ms;
}
.breadcrumb a:hover { color: var(--neon-1); }
.post-meta {
    font-family: var(--font-mono);
    font-size: .76rem;
    color: var(--text-muted);
    letter-spacing: .04em;
}

.blog-section--page { padding: 56px 0 72px; }
.blog-grid--page { grid-template-columns: repeat(3, 1fr); }
.blog-meta {
    display: block;
    margin-top: 10px;
    font-family: var(--font-mono);
    font-size: .68rem;
    color: var(--text-muted);
    letter-spacing: .05em;
}
.blog-card-link { display: block; text-decoration: none; color: inherit; height: 100%; }

/* Long-form prose */
.prose { padding: 40px 0 8px; }
.prose p { color: var(--text-muted); line-height: 1.8; margin-bottom: 16px; font-size: .95rem; }
.prose h2 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    color: var(--text);
    margin: 34px 0 12px;
}
.prose h2:first-child { margin-top: 0; }
.prose ul { margin: 0 0 16px 4px; display: flex; flex-direction: column; gap: 8px; }
.prose ul li {
    color: var(--text-muted);
    line-height: 1.7;
    font-size: .95rem;
    padding-left: 18px;
    position: relative;
}
.prose ul li::before { content: ">"; position: absolute; left: 0; color: var(--neon-1); font-family: var(--font-mono); font-weight: 800; }
.prose strong { color: var(--text); }
.prose em { font-style: italic; }
.prose a { color: var(--neon-1); text-decoration: none; border-bottom: 1px solid rgba(0,240,255,.3); }
.prose a:hover { border-bottom-color: var(--neon-1); }
.prose code {
    font-family: var(--font-mono);
    font-size: .84em;
    color: var(--neon-1);
    background: rgba(0,240,255,.06);
    padding: 1px 6px;
    border: 1px solid var(--border);
}
.prose table { width: 100%; border-collapse: collapse; margin: 0 0 16px; font-size: .85rem; }
.prose th, .prose td {
    text-align: left;
    padding: 10px 12px;
    border: 1px solid var(--border);
    color: var(--text-muted);
    line-height: 1.5;
}
.prose th {
    font-family: var(--font-mono);
    font-size: .7rem;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--text);
    background: var(--surface);
}

.legal-body { padding-bottom: 64px; }

/* Post CTA box */
.post-cta { margin: 40px 0; }
.post-cta-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    padding: 26px 28px;
    background: var(--surface);
    border: 1px solid var(--border-hi);
    clip-path: var(--clip-card);
    position: relative;
    box-shadow: 0 0 40px rgba(0,240,255,.04);
}
.post-cta h2 { font-family: var(--font-display); font-size: 1.05rem; color: var(--text); margin-bottom: 6px; }
.post-cta p  { font-size: .85rem; color: var(--text-muted); }

.related-posts { padding-bottom: 72px; }
.related-title { font-family: var(--font-display); font-size: 1.05rem; color: var(--text); margin-bottom: 18px; }
.blog-grid--related { grid-template-columns: 1fr 1fr; }

/* 404 */
.error-page {
    min-height: calc(100vh - var(--header-h) - 320px);
    display: flex;
    align-items: center;
    text-align: center;
    padding: 80px 0;
}
.error-page .container { position: relative; }
.error-code {
    font-family: var(--font-display);
    font-size: clamp(4rem, 14vw, 8rem);
    font-weight: 900;
    line-height: 1;
    color: var(--neon-1);
    text-shadow: 0 0 40px rgba(0,240,255,.4);
    margin-bottom: 8px;
    animation: glitch-headline 6s steps(1) infinite;
}
.error-page .page-title { margin-bottom: 12px; }
.error-page .hero-sub { margin-bottom: 28px; }

@media (max-width: 1000px) {
    .api-grid { grid-template-columns: 1fr; }
    .blog-grid--page { grid-template-columns: repeat(2, 1fr); }
    .blog-grid--page > *:last-child { display: block; }
}
@media (max-width: 768px) {
    .blog-grid--page, .blog-grid--related { grid-template-columns: 1fr; }
    .post-cta-inner { flex-direction: column; align-items: flex-start; }
}

/* ============================================================
   REDUCED MOTION
============================================================ */
@media (prefers-reduced-motion: reduce) {
    #matrix-rain { display: none; }
    body::after  { display: none; }
    .hero-headline { animation: none; text-shadow: 0 0 20px rgba(0,240,255,.15); }
    .email-card  { animation: none; }
    .skeleton::after { animation: none; }
    .action-btn.loading svg { animation: none; }
    .orb, .hero-grid, .ticker-track, .error-code { animation: none; }
    .reveal { opacity: 1; transform: none; transition: none; }
    .tilt-card, .magnetic { transform: none !important; }
    *, *::before, *::after {
        animation-duration: .01ms !important;
        transition-duration: .01ms !important;
    }
}
