:root {
    --bg:            #0a0a0b;
    --bg-raise:      #111113;
    --bg-raise-2:    #18181b;
    --text:          #f4f4f5;
    --muted:         #8b8b95;
    --accent:        #dc2626;
    --accent-dim:    rgba(220, 38, 38, 0.14);
    --accent-hover:  #ef4444;
    --accent-deep:   #991b1b;
    --danger:        #dc2626;
    --danger-text:   #fca5a5;
    --warning:       #d97706;
    --border:        rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.15);
    --code-bg:       #0e0e10;
    --input-bg:      #1a1a1e;
    --light-1:       #fafafa;
    --light-2:       #ffffff;
    --on-light:      #0a0a0b;
    --on-accent:     #fff5f5;

    --radius:        10px;
    --radius-sm:     6px;
    --radius-lg:     14px;
    --font-display:  "Space Grotesk", sans-serif;
    --font-body:     "DM Sans", system-ui, sans-serif;
    --font-mono:     "JetBrains Mono", "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 14px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; transition: color .14s ease; }
a:hover { color: var(--accent-hover); }

.app {
    display: grid;
    grid-template-columns: 248px 1fr;
    min-height: 100vh;
    position: relative;
}

.sidebar {
    background: var(--bg-raise);
    border-right: 1px solid var(--border);
    padding: 24px 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: sticky;
    top: 0;
    height: 100vh;
}

.brand {
    display: flex;
    align-items: baseline;
    gap: 10px;
    padding: 0 10px 24px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 16px;
}
.brand-mark {
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 21px;
    letter-spacing: -0.02em;
}
.brand-mark .at { color: var(--accent); }
.brand-link { text-decoration: none; color: inherit; }
.brand-link:hover { color: inherit; }
.brand-sub {
    font-size: 10px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-weight: 500;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    color: var(--muted);
    font-weight: 500;
    font-size: 13.5px;
    border: 1px solid transparent;
    transition: background .14s ease, color .14s ease, border-color .14s ease;
}
.nav-item:hover {
    background: var(--bg-raise-2);
    color: var(--text);
    border-color: var(--border);
}
.nav-item.active {
    background: var(--accent-dim);
    color: var(--text);
    border-color: rgba(220, 38, 38, 0.28);
}
.nav-icon {
    width: 16px;
    height: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    opacity: .85;
}
.nav-item.active .nav-icon { opacity: 1; color: var(--accent); }

.sidebar-foot {
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid var(--border);
    color: var(--muted);
    font-size: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.sidebar-foot form { margin: 0; }
.sidebar-foot .who {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 4px 10px;
    color: var(--text);
}
.sidebar-foot .avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-dim);
    border: 1px solid rgba(220, 38, 38, 0.28);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: var(--accent);
    font-size: 12px;
    font-family: var(--font-display);
}
.sidebar-foot .host {
    padding: 6px 10px;
    font-size: 11px;
    letter-spacing: 0.04em;
    color: var(--muted);
}

.main {
    padding: 32px 40px 64px;
    max-width: 1280px;
}

.page-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 28px;
    gap: 20px;
    flex-wrap: wrap;
}
.page-head h1 {
    margin: 0;
    font-family: var(--font-display);
    font-size: 26px;
    font-weight: 600;
    letter-spacing: -0.03em;
}
.page-head .sub {
    color: var(--muted);
    font-size: 13px;
    margin-top: 4px;
}

.card {
    background: var(--bg-raise);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}
.card-pad { padding: 20px 22px; }
.card-head {
    padding: 15px 22px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.card-head h2 {
    margin: 0;
    font-family: var(--font-display);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: -0.01em;
}

.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}
@media (max-width: 980px) { .stats { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .stats { grid-template-columns: 1fr; } }

.stat {
    background: var(--bg-raise);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px 20px;
}
.stat .label {
    color: var(--muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 500;
}
.stat .value {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: 600;
    margin-top: 8px;
    letter-spacing: -0.03em;
    font-feature-settings: "tnum";
}
.stat .delta {
    color: var(--muted);
    font-size: 12px;
    margin-top: 4px;
}
.stat .value.value-sm {
    font-size: 22px;
    line-height: 1.2;
}
.stats-3 {
    grid-template-columns: repeat(3, 1fr);
}
@media (max-width: 820px) { .stats-3 { grid-template-columns: 1fr; } }

.panel-title {
    margin: 0 0 8px;
    font-family: var(--font-display);
    font-size: 16px;
    font-weight: 600;
}
.info-list {
    list-style: none;
    margin: 16px 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.info-list li {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    font-size: 13px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}
.info-list li:last-child { border-bottom: none; padding-bottom: 0; }

.grid-2 {
    display: grid;
    grid-template-columns: 1.35fr 1fr;
    gap: 20px;
}
@media (max-width: 1080px) { .grid-2 { grid-template-columns: 1fr; } }

table.atlas {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
table.atlas th, table.atlas td {
    padding: 11px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}
table.atlas th {
    background: var(--bg-raise-2);
    color: var(--muted);
    font-weight: 500;
    font-size: 10.5px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}
table.atlas tr:last-child td { border-bottom: none; }
table.atlas tbody tr:hover td { background: var(--bg-raise-2); }
table.atlas td.mono {
    font-family: var(--font-mono);
    color: var(--muted);
    font-size: 12px;
}
table.atlas td.num { text-align: right; font-variant-numeric: tabular-nums; }

.pill {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.02em;
    border: 1px solid transparent;
}
.pill.ok {
    background: var(--accent-dim);
    color: var(--accent);
    border-color: rgba(220, 38, 38, 0.28);
}
.pill.warn {
    background: rgba(217, 165, 83, 0.12);
    color: #e8c48a;
    border-color: rgba(217, 165, 83, 0.25);
}
.pill.bad {
    background: rgba(217, 108, 108, 0.12);
    color: var(--danger-text);
    border-color: rgba(217, 108, 108, 0.25);
}
.pill.muted {
    background: var(--bg-raise-2);
    color: var(--muted);
    border-color: var(--border);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    height: 36px;
    padding: 0 15px;
    border: 1px solid var(--border);
    background: var(--bg-raise-2);
    color: var(--text);
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: background .14s ease, border-color .14s ease, transform .06s ease;
    text-decoration: none;
}
.btn:hover {
    background: #1a1d22;
    border-color: var(--border-strong);
}
.btn:active { transform: translateY(1px); }

.btn.primary {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--on-light);
}
.btn.primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
}

.btn.danger {
    color: var(--danger-text);
    border-color: rgba(217, 108, 108, 0.3);
    background: rgba(217, 108, 108, 0.08);
}
.btn.danger:hover { background: rgba(217, 108, 108, 0.14); }
.btn.ghost { background: transparent; }
.btn.sm { height: 30px; padding: 0 11px; font-size: 12px; }

.input,
input[type="text"],
input[type="password"],
input[type="number"],
input[type="search"],
select,
textarea {
    width: 100%;
    height: 38px;
    padding: 0 13px;
    background: var(--input-bg);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font: inherit;
    outline: none;
    transition: border-color .14s ease, background .14s ease;
}
textarea { height: auto; padding: 11px 13px; resize: vertical; line-height: 1.5; }

textarea.code-editor {
    min-height: 360px;
    padding: 16px 18px;
    font-family: var(--font-mono);
    font-size: 13.5px;
    line-height: 1.65;
    background: var(--code-bg);
    tab-size: 4;
    -moz-tab-size: 4;
    white-space: pre;
    overflow: auto;
}
.input:focus, input:focus, select:focus, textarea:focus {
    border-color: rgba(220, 38, 38, 0.5);
    background: #1c1f24;
}
.input.sm { height: 32px; padding: 0 10px; font-size: 12px; }

.form-row {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}
.form-row .grow { flex: 1; min-width: 160px; }
.form-row label {
    display: block;
    color: var(--muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 6px;
    font-weight: 500;
}

.inline-form {
    display: inline-flex;
    gap: 6px;
    align-items: center;
}

.flashes {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}
.flash {
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 11px 15px;
    background: var(--bg-raise);
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.flash::before {
    content: "";
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--muted);
    flex-shrink: 0;
}
.flash.success {
    border-color: rgba(220, 38, 38, 0.35);
    color: #fecaca;
}
.flash.success::before { background: var(--accent); }
.flash.error {
    border-color: rgba(217, 108, 108, 0.3);
    color: var(--danger-text);
}
.flash.error::before { background: var(--danger); }

.login-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
    position: relative;
}
.login-card {
    width: 100%;
    max-width: 400px;
    background: var(--bg-raise);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 36px 32px 30px;
    position: relative;
    z-index: 1;
}
.login-brand {
    margin-bottom: 28px;
}
.login-brand .mark {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: 600;
    letter-spacing: -0.03em;
}
.login-brand .mark .at { color: var(--accent); }
.login-brand .sub {
    color: var(--muted);
    font-size: 12px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-top: 6px;
    font-weight: 500;
}
.login-card label {
    display: block;
    margin: 16px 0 7px;
    color: var(--muted);
    font-size: 11px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    font-weight: 500;
}
.login-card .btn.primary {
    width: 100%;
    height: 42px;
    margin-top: 22px;
    font-weight: 600;
}
.login-foot {
    margin-top: 22px;
    color: var(--muted);
    font-size: 11.5px;
    letter-spacing: 0.05em;
}

.err-wrap {
    min-height: 100vh;
    display: grid;
    place-items: center;
    text-align: center;
    position: relative;
    padding: 24px;
}
.err-inner { position: relative; z-index: 1; }
.err-code {
    font-family: var(--font-display);
    font-size: 80px;
    color: var(--accent);
    line-height: 1;
    letter-spacing: -0.04em;
}
.err-msg {
    color: var(--muted);
    margin-top: 10px;
    font-size: 15px;
}

.muted { color: var(--muted); }
.right { text-align: right; }
.row-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.divider {
    height: 1px;
    background: var(--border);
    margin: 16px 0;
}
details.collapse > summary {
    cursor: pointer;
    list-style: none;
    color: var(--accent);
    font-size: 12px;
    padding: 4px 0;
}
details.collapse > summary::-webkit-details-marker { display: none; }
details.collapse[open] > summary { color: var(--text); }

@media (max-width: 820px) {
    .app { grid-template-columns: 1fr; }
    .sidebar {
        position: relative;
        height: auto;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 8px;
        padding: 16px;
    }
    .brand {
        border-bottom: none;
        margin-bottom: 0;
        padding-bottom: 0;
        width: 100%;
    }
    .sidebar-foot { display: none; }
    .main { padding: 24px 18px 48px; }
}

/* ── Public site (x3-style) ── */
.site-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 14px max(24px, 5vw);
    background: rgba(10, 10, 11, 0.9);
    border-bottom: 1px solid var(--border);
}
.site-links-mid {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}
@media (max-width: 820px) {
    .site-links-mid { display: none; }
}
.site-logo {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 22px;
    letter-spacing: -0.03em;
    color: var(--text);
    text-decoration: none;
}
.site-logo:hover { color: var(--text); }
.site-logo .at { color: var(--accent); }
.site-logo.sm { font-size: 18px; }
.site-links {
    display: flex;
    align-items: center;
    gap: 28px;
}
.site-links a { color: var(--muted); font-weight: 500; font-size: 14px; text-decoration: none; }
.site-links a:hover { color: var(--text); }
.inline-nav-form { margin: 0; display: inline; }
.site-flashes {
    max-width: 1200px;
    margin: 0 auto;
    padding: 12px max(24px, 5vw) 0;
    position: relative;
    z-index: 10;
}
.site-foot {
    border-top: 1px solid var(--border);
    padding: 48px max(24px, 5vw);
    margin-top: 0;
}
.site-foot-inner {
    max-width: 1120px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
}
.site-foot-links {
    display: flex;
    gap: 22px;
    flex-wrap: wrap;
}
.site-foot-links a {
    color: var(--muted);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
}
.site-foot-links a:hover { color: var(--text); }

.x3-hero {
    padding: 72px max(24px, 5vw) 56px;
    position: relative;
    z-index: 1;
}
.x3-hero-inner {
    max-width: 1200px;
    margin: 0 auto;
}
.x3-tag {
    margin: 0 0 20px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 500;
}
.x3-hero h1 {
    font-family: var(--font-display);
    font-size: clamp(48px, 8vw, 88px);
    font-weight: 700;
    letter-spacing: -0.045em;
    line-height: 0.95;
    margin: 0;
    max-width: 720px;
}
.x3-hero h1 .accent { color: var(--accent); }
.x3-lead {
    color: var(--muted);
    font-size: 17px;
    line-height: 1.65;
    max-width: 560px;
    margin: 28px 0 0;
}
.x3-actions {
    display: flex;
    gap: 18px;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 32px;
}
.btn.lg { height: 46px; padding: 0 24px; font-size: 15px; font-weight: 600; }

.ghost-link {
    color: var(--muted);
    font-size: 13.5px;
    font-weight: 500;
    border-bottom: 1px solid var(--border-strong);
    padding-bottom: 2px;
    transition: color .14s ease, border-color .14s ease;
}
.ghost-link:hover { color: var(--text); border-color: var(--text); }

.x3-feature-list { margin-top: 0; }
.x3-feature-list li {
    border-top: 1px solid var(--border);
    padding: 18px 0;
    display: block;
}
.x3-feature-list li:last-child { border-bottom: 1px solid var(--border); }
.x3-feature-list strong { display: block; font-size: 15px; font-weight: 600; margin-bottom: 4px; color: var(--text); }
.x3-feature-list p { color: var(--muted); margin: 0; font-size: 13.5px; line-height: 1.6; }
.x3-feature-list code {
    background: var(--code-bg);
    padding: 1px 6px;
    border-radius: 4px;
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--accent);
}

.dl { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin: 0; align-items: baseline; font-size: 13px; }
.dl dt { color: var(--muted); font-size: 11.5px; text-transform: uppercase; letter-spacing: 0.10em; }
.dl dd { margin: 0; font-family: var(--font-mono); font-size: 12.5px; color: var(--text); }

.x3-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    margin-top: 64px;
    max-width: 900px;
    background: var(--border);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}
@media (max-width: 720px) { .x3-stats { grid-template-columns: repeat(2, 1fr); } }
.x3-stat {
    background: var(--bg-raise);
    padding: 24px 20px;
    text-align: center;
}
.x3-stat-val {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.02em;
}
.x3-stat-lbl {
    color: var(--muted);
    font-size: 12px;
    margin-top: 6px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.x3-section {
    padding: 80px max(24px, 5vw);
    position: relative;
    z-index: 1;
}
.x3-section-alt {
    background: var(--bg-raise);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}
.x3-section-inner {
    max-width: 1200px;
    margin: 0 auto;
}
.x3-kicker {
    margin: 0 0 10px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.06em;
}
.x3-section-title {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: 600;
    letter-spacing: -0.03em;
    margin: 0 0 32px;
}

.x3-num-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
@media (max-width: 980px) { .x3-num-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .x3-num-grid { grid-template-columns: 1fr; } }
.x3-num-card {
    background: var(--bg-raise);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px 24px;
    min-height: 180px;
}
.x3-section-alt .x3-num-card { background: var(--bg); }
.x3-num {
    display: block;
    font-family: var(--font-display);
    font-size: 13px;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 16px;
}
.x3-num-card h3 {
    margin: 0 0 10px;
    font-family: var(--font-display);
    font-size: 17px;
    font-weight: 600;
}
.x3-num-card p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.6;
}

.x3-split {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 48px;
    align-items: start;
}
@media (max-width: 900px) { .x3-split { grid-template-columns: 1fr; } }
.x3-split-copy h2 {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: 600;
    letter-spacing: -0.03em;
    margin: 0 0 16px;
}
.x3-bullets {
    margin: 24px 0 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 10px;
}
.x3-bullets li {
    position: relative;
    padding-left: 18px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.5;
}
.x3-bullets li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 9px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent);
}
.x3-split-panel h3 { margin-top: 4px; }
.x3-price-rows { margin-top: 20px; display: flex; flex-direction: column; gap: 0; }
.x3-price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
}
.x3-price-row.highlight {
    color: var(--accent);
    border-bottom: none;
    padding-bottom: 0;
}
.x3-price-row strong { font-family: var(--font-display); }

.x3-steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
@media (max-width: 820px) { .x3-steps { grid-template-columns: 1fr; } }
.x3-step {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    background: var(--bg-raise);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px;
}
.step-num {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--accent-dim);
    border: 1px solid rgba(220, 38, 38, 0.35);
    color: var(--accent);
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-family: var(--font-display);
    font-size: 14px;
}
.x3-step strong { display: block; margin-bottom: 4px; font-size: 15px; }
.x3-step p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }

.x3-cta {
    padding: 88px max(24px, 5vw);
    text-align: center;
    position: relative;
    z-index: 1;
    border-top: 1px solid var(--border);
}
.x3-cta-inner { max-width: 560px; margin: 0 auto; }
.x3-cta h2 {
    font-family: var(--font-display);
    font-size: 36px;
    font-weight: 700;
    letter-spacing: -0.03em;
    margin: 0;
}
.x3-cta p { margin: 12px 0 0; font-size: 15px; }

.small { font-size: 13px; }
.redeem-form {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.redeem-form .input { flex: 1; min-width: 200px; }
.mark-link { text-decoration: none; color: inherit; }
.mono { font-family: var(--font-mono); }
.status-pill {
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    border: 1px solid var(--border);
}
.status-pill.ok {
    background: var(--accent-dim);
    color: var(--accent);
    border-color: rgba(220, 38, 38, 0.35);
}
.status-pill.bad {
    background: rgba(255,255,255,0.04);
    color: var(--muted);
}

@media (max-width: 640px) {
    .site-nav { padding: 14px 20px; }
    .site-links { gap: 16px; }
    .x3-hero { padding-top: 48px; }
    .x3-section { padding: 56px 20px; }
    .x3-cta { padding: 64px 20px; }
}

/* ── Profile picture ───────────────────────────────────────────── */

.avatar-img {
    object-fit: cover;
    padding: 0;
}

.page-head-id {
    display: flex;
    align-items: center;
    gap: 16px;
}
.page-pfp {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: var(--accent-dim);
    border: 1px solid rgba(220, 38, 38, 0.30);
    object-fit: cover;
    flex-shrink: 0;
}
.page-pfp.page-pfp-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 600;
    color: var(--accent);
}

.pfp-row {
    display: flex;
    align-items: center;
    gap: 22px;
    margin-top: 14px;
}
.pfp-preview {
    width: 96px;
    height: 96px;
    border-radius: 18px;
    background: var(--bg-raise-2);
    border: 1px solid var(--border);
    overflow: hidden;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    font-family: var(--font-display);
    font-size: 38px;
    font-weight: 600;
}
.pfp-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pfp-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
.pfp-upload-form {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
}
.pfp-pick {
    position: relative;
    cursor: pointer;
    overflow: hidden;
}
.pfp-pick input[type="file"] {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}
.pfp-hint {
    flex-basis: 100%;
    margin-top: 4px;
}

@media (max-width: 640px) {
    .page-head-id { flex-wrap: wrap; }
    .pfp-row      { flex-direction: column; align-items: flex-start; }
}


/* ── Landing (home) — a manifest, not a slide deck ── */

.lp-wrap {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 max(20px, 4vw);
    position: relative;
    z-index: 1;
}

/* Hero — copy paired with a static overlay preview */
.lp-hero {
    position: relative;
    min-height: min(86vh, 820px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 96px 20px 72px;
    overflow: hidden;
}
.lp-hero-glow {
    position: absolute;
    inset: -18% 10% auto -5%;
    height: 52%;
    background: radial-gradient(ellipse 65% 80% at 35% 0%, rgba(220, 38, 38, 0.14), transparent 70%);
    pointer-events: none;
    z-index: 0;
}
.lp-hero-gridlines {
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    opacity: 0.28;
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 20%, transparent 75%);
}
.lp-hero-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
    align-items: center;
    gap: 64px;
}
.lp-hero-copy .lp-kicker { margin-bottom: 18px; }

/* Overlay preview panel */
.lp-hero-panel {
    position: relative;
    z-index: 2;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: var(--bg-raise);
    overflow: hidden;
}
.lp-panel-head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 16px;
    background: var(--bg-raise-2);
    border-bottom: 1px solid var(--border);
}
.lp-panel-dots { display: flex; gap: 5px; }
.lp-panel-dots i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--border-strong);
    display: block;
}
.lp-panel-title {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    color: var(--muted);
}
.lp-panel-body { padding: 4px 16px; }
.lp-panel-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
    font-size: 13.5px;
}
.lp-panel-row:last-child { border-bottom: 0; }
.lp-panel-state {
    font-family: var(--font-mono);
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: 0.03em;
    color: var(--muted);
    padding: 3px 9px;
    border-radius: 999px;
    border: 1px solid var(--border);
    flex-shrink: 0;
}
.lp-panel-state.on {
    color: var(--accent);
    border-color: rgba(220, 38, 38, 0.35);
    background: var(--accent-dim);
}
.lp-panel-foot {
    padding: 12px 16px;
    border-top: 1px solid var(--border);
    background: var(--bg-raise-2);
    font-size: 12px;
    color: var(--muted);
}
.lp-panel-foot code {
    font-family: var(--font-mono);
    font-size: 11px;
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 1px 6px;
    color: var(--text);
}

.lp-hero-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(48px, 7vw, 80px);
    line-height: 0.94;
    letter-spacing: -0.04em;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.lp-hero-title-sub {
    font-size: clamp(16px, 2vw, 20px);
    font-weight: 500;
    letter-spacing: -0.02em;
    color: var(--muted);
    line-height: 1.3;
}
.lp-hero-lead {
    margin: 20px 0 0;
    max-width: 34rem;
    color: var(--muted);
    font-size: 15.5px;
    line-height: 1.65;
}

.lp-hero-cta {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 12px;
    margin-top: 32px;
}
.lp-btn-main {
    min-width: 160px;
    box-shadow: 0 0 0 1px rgba(220, 38, 38, 0.35), 0 12px 40px -12px rgba(220, 38, 38, 0.55);
}

/* Inline mono readout — no boxed stat table */
.lp-hero-readout {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 9px;
    margin-top: 40px;
    padding-top: 22px;
    border-top: 1px solid var(--border);
    max-width: 34rem;
    font-size: 13px;
    color: var(--muted);
}
.lp-hero-readout strong {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text);
    font-variant-numeric: tabular-nums;
}
.lp-hero-readout .sep { color: var(--border-strong); }

/* Sections */
.lp-section {
    padding: 100px 0 20px;
    position: relative;
    z-index: 1;
}
.lp-section-alt {
    margin-top: 80px;
    padding: 88px 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background: linear-gradient(180deg, var(--bg-raise) 0%, var(--bg) 100%);
}
.lp-head { margin-bottom: 40px; max-width: 36rem; }
.lp-head-center {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
    max-width: 40rem;
}
.lp-head-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 8px;
    padding-bottom: 32px;
    border-bottom: 1px solid var(--border);
}
.lp-head-row .lp-sub { max-width: 22rem; margin: 0; }
.lp-kicker {
    margin: 0 0 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: var(--accent);
}
.lp-h2 {
    font-family: var(--font-display);
    font-size: clamp(30px, 4.2vw, 42px);
    font-weight: 700;
    letter-spacing: -0.035em;
    line-height: 1.05;
    margin: 0;
}
.lp-sub {
    margin: 14px 0 0;
    color: var(--muted);
    font-size: 15px;
    line-height: 1.6;
}

/* Manifest — a divided spec list, not a card grid */
.lp-manifest {
    display: flex;
    flex-direction: column;
}
.lp-manifest-row {
    display: grid;
    grid-template-columns: 52px 1fr;
    gap: 20px;
    padding: 30px 0;
    border-bottom: 1px solid var(--border);
}
.lp-manifest-n {
    padding-top: 5px;
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--muted);
}
.lp-manifest-body h3 {
    margin: 0 0 8px;
    font-family: var(--font-display);
    font-size: 19px;
    font-weight: 600;
    letter-spacing: -0.02em;
}
.lp-manifest-body p {
    margin: 0;
    max-width: 42rem;
    font-size: 14px;
    line-height: 1.65;
    color: var(--muted);
}
.lp-manifest-row-lg .lp-manifest-n { color: var(--accent); }
.lp-manifest-row-lg .lp-manifest-body h3 { font-size: 25px; }
.lp-manifest-row-lg .lp-manifest-body p { font-size: 14.5px; }

.lp-mod-tags {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 18px 0 0;
    padding: 0;
}
.lp-mod-tags li {
    font-size: 12px;
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 999px;
    background: var(--bg-raise);
    border: 1px solid var(--border);
    color: var(--text);
}

/* Why list — two-column, divided rows instead of icon cards */
.lp-why-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 56px;
}
.lp-why-row {
    display: flex;
    gap: 18px;
    padding: 26px 0;
    border-top: 1px solid var(--border);
}
.lp-why-row:nth-child(1),
.lp-why-row:nth-child(2) { border-top: 0; }
.lp-why-n {
    flex-shrink: 0;
    padding-top: 3px;
    font-family: var(--font-mono);
    font-size: 12px;
    color: var(--muted);
}
.lp-why-row h3 {
    margin: 0 0 6px;
    font-size: 16px;
    font-weight: 600;
}
.lp-why-row p {
    margin: 0;
    font-size: 13.5px;
    line-height: 1.55;
    color: var(--muted);
}

/* Setup rail — a timeline, not three boxed cards */
.lp-rail {
    list-style: none;
    margin: 44px 0 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    position: relative;
}
.lp-rail::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 10px;
    height: 1px;
    background: var(--border);
}
.lp-rail li {
    position: relative;
    padding-right: 28px;
}
.lp-rail li:last-child { padding-right: 0; }
.lp-rail-n {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 21px;
    height: 21px;
    margin-bottom: 22px;
    border-radius: 50%;
    background: var(--bg);
    border: 1px solid var(--accent);
    font-family: var(--font-mono);
    font-size: 9.5px;
    color: var(--accent);
}
.lp-rail h3 { margin: 0 0 8px; font-size: 17px; font-weight: 600; }
.lp-rail p { margin: 0; font-size: 13.5px; color: var(--muted); line-height: 1.55; }
.lp-rail code {
    font-family: var(--font-mono);
    font-size: 11.5px;
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 0 5px;
    color: var(--text);
}

/* FAQ — one continuous divided list */
.lp-faq-wrap { max-width: 720px; }
.lp-faq {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--border);
}
.lp-faq-item { border-bottom: 1px solid var(--border); }
.lp-faq-item summary {
    list-style: none;
    cursor: pointer;
    padding: 22px 4px;
    font-weight: 600;
    font-size: 14.5px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    user-select: none;
}
.lp-faq-item summary::-webkit-details-marker { display: none; }
.lp-faq-item summary::after {
    content: "+";
    flex-shrink: 0;
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 500;
    color: var(--accent);
    line-height: 1;
}
.lp-faq-item[open] summary::after { content: "−"; }
.lp-faq-item p {
    margin: 0;
    padding: 0 4px 22px;
    max-width: 40rem;
    color: var(--muted);
    font-size: 13.5px;
    line-height: 1.6;
}
.lp-faq-item code {
    font-family: var(--font-mono);
    font-size: 11.5px;
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 0 5px;
}

/* Final — a statement, not a boxed CTA card */
.lp-final {
    padding: 96px 0 120px;
    border-top: 1px solid var(--border);
}
.lp-final-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}
.lp-final-copy .lp-sub { max-width: 28rem; }
.lp-final .lp-hero-cta { margin-top: 0; justify-content: flex-start; }

@media (max-width: 900px) {
    .lp-manifest-row { grid-template-columns: 40px 1fr; }
    .lp-why-list { grid-template-columns: 1fr; }
    .lp-why-row:nth-child(2) { border-top: 1px solid var(--border); }
    .lp-rail { grid-template-columns: 1fr; gap: 28px; }
    .lp-rail::before { display: none; }
    .lp-rail li { padding-right: 0; }
    .lp-hero { min-height: auto; padding: 72px 16px 56px; }
    .lp-hero-inner { grid-template-columns: 1fr; gap: 44px; }
    .lp-hero-panel { max-width: 460px; }
    .lp-head-row { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 560px) {
    .lp-section { padding-top: 72px; }
    .lp-section-alt { margin-top: 56px; padding: 64px 0; }
}

/* ── Landing — static, interaction-only feedback ── */

@keyframes lp-fade-up {
    from { opacity: 0; transform: translateY(28px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes lp-badge-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.55); }
    50%      { box-shadow: 0 0 0 8px rgba(220, 38, 38, 0); }
}

.lp-btn-main {
    transition: background .18s ease, border-color .18s ease;
}

.lp-manifest-row {
    transition: border-color .18s ease;
}
.lp-manifest-row:hover {
    border-color: var(--border-strong);
}
.lp-mod-tags li {
    transition: border-color .18s ease, background .18s ease;
}

.lp-faq-item summary {
    transition: color .15s ease;
}
.lp-faq-item summary:hover {
    color: var(--accent);
}
.lp-faq-item summary::after {
    transition: transform .2s ease, color .15s ease;
}
.lp-faq-item[open] summary::after {
    transform: rotate(180deg);
}

/* ── Reseller: plan picker + pay screen ── */

.plan-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 28px;
    align-items: stretch;
}
@media (max-width: 980px) { .plan-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .plan-grid { grid-template-columns: 1fr; } }

.plan-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 18px;
    padding: 24px 22px;
    opacity: 0;
    transform: translateY(20px);
    animation: lp-fade-up .6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    transition: transform 220ms var(--lift, cubic-bezier(0.22, 1, 0.36, 1)),
                border-color 220ms ease, background 220ms ease;
}
.plan-card:nth-child(1) { animation-delay: .04s; }
.plan-card:nth-child(2) { animation-delay: .10s; }
.plan-card:nth-child(3) { animation-delay: .16s; }
.plan-card:nth-child(4) { animation-delay: .22s; }
.plan-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-strong);
}
.plan-card.featured {
    border-color: rgba(220, 38, 38, 0.4);
    background: linear-gradient(180deg, rgba(220,38,38,0.08), var(--bg-raise) 65%);
    transform: scale(1.035);
}
.plan-card.featured:hover { transform: scale(1.035) translateY(-4px); }
.plan-tag {
    position: absolute;
    top: -11px;
    left: 22px;
    background: var(--accent);
    color: var(--on-accent);
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 4px 10px;
    border-radius: 999px;
}
.plan-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--muted);
    font-weight: 500;
}
.plan-price {
    font-family: var(--font-display);
    font-size: 34px;
    font-weight: 600;
    letter-spacing: -0.03em;
    font-feature-settings: "tnum";
}
.plan-price .cur { font-size: 20px; opacity: .7; margin-left: 2px; }
.plan-price-old {
    font-family: var(--font-display);
    font-size: 15px;
    color: var(--muted);
    text-decoration: line-through;
    text-decoration-color: rgba(220, 38, 38, 0.5);
    margin-top: 6px;
}
.plan-days { font-size: 12px; color: var(--muted); margin-top: -10px; }
.plan-card form { margin-top: auto; }
.plan-card .btn { width: 100%; }

.pulse-dot {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    animation: lp-badge-pulse 2s ease-out infinite;
}
.status-pill.pending {
    background: rgba(255,255,255,0.04);
    color: var(--text);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.pay-block { margin-bottom: 20px; }
.pay-block:last-child { margin-bottom: 0; }
.pay-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted);
    margin-bottom: 8px;
}
.pay-row {
    display: flex;
    align-items: stretch;
    gap: 8px;
}
.pay-value {
    flex: 1;
    background: var(--code-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 12px 14px;
    font-family: var(--font-mono);
    font-size: 14px;
    word-break: break-all;
    display: flex;
    align-items: center;
}
.pay-value.lg { font-size: 18px; font-weight: 600; }
.copy-btn {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg-raise-2);
    color: var(--muted);
    cursor: pointer;
    transition: color 150ms ease, border-color 150ms ease, transform 100ms ease;
}
.copy-btn:hover { color: var(--text); border-color: var(--border-strong); }
.copy-btn:active { transform: scale(0.94); }
.copy-btn.copied { color: var(--accent); border-color: rgba(220,38,38,0.4); }

.progress-track {
    height: 4px;
    border-radius: 999px;
    background: var(--bg-raise-2);
    overflow: hidden;
    margin-top: 14px;
}
.progress-fill {
    height: 100%;
    background: var(--accent);
    border-radius: 999px;
    width: 100%;
    transition: width 1s linear;
}

@media (prefers-reduced-motion: reduce) {
    .plan-card,
    .pulse-dot {
        animation: none !important;
    }
    .plan-card { opacity: 1 !important; transform: none !important; }
}
