/* ============================================
   BlackOps Market — TYPESET v2
   Editorial design with section-level variety
   ============================================ */

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

/* --- SELF-HOSTED FONTS --- */
/* 3 WOFF2 files, Latin subset only. Budget: 2 families + 1 mono = ~108 KB total */
@font-face {
    font-family: 'Outfit';
    src: url('fonts/outfit-latin.woff2') format('woff2');
    font-weight: 400 600;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
    /* Metric overrides — match system-ui fallback to prevent CLS */
    size-adjust: 100%;
    ascent-override: 90%;
    descent-override: 22%;
    line-gap-override: 0%;
}

@font-face {
    font-family: 'Newsreader';
    src: url('fonts/newsreader-latin.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
    /* Metric overrides — match Georgia fallback to prevent CLS */
    size-adjust: 105%;
    ascent-override: 92%;
    descent-override: 25%;
    line-gap-override: 0%;
}

@font-face {
    font-family: 'JetBrains Mono';
    src: url('fonts/jetbrainsmono-latin.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
    /* Metric overrides — match Consolas fallback to prevent CLS */
    size-adjust: 97%;
    ascent-override: 95%;
    descent-override: 25%;
    line-gap-override: 0%;
}

/* --- DESIGN TOKENS --- */
:root {
    --bg: #131516;
    --bg-surface: #191B1E;
    --bg-panel: #1C1F22;
    --bg-inset: #111314;

    --teal: #2D6A6A;
    --teal-light: #3D8A8A;
    --teal-mid: #358080;
    --teal-dim: #245555;
    --teal-ghost: rgba(45, 106, 106, 0.06);
    --teal-border: rgba(45, 106, 106, 0.2);

    --green: #4AA366;
    --green-dim: rgba(74, 163, 102, 0.12);
    --red: #C45454;

    --text: #BDB8AF;
    --text-strong: #E3DFD7;
    --text-body: #C8C3BA;
    --text-muted: #7D7872;
    --text-dim: #4E4A45;

    --rule: rgba(255, 255, 255, 0.055);
    --rule-mid: rgba(255, 255, 255, 0.09);

    --font-headline: 'Newsreader', 'Georgia', serif;
    --font-body: 'Outfit', system-ui, sans-serif;
    --font-mono: 'JetBrains Mono', 'Consolas', monospace;

    --col-body: 700px;
    --col-wide: 980px;
    --col-max: 1100px;
    --pad: 1.5rem;
}

/* --- BASE --- */
html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 1.0625rem;
    line-height: 1.82;
    color: var(--text-body);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

::selection {
    background: rgba(45, 106, 106, 0.35);
    color: var(--text-strong);
}

/* --- TYPOGRAPHY --- */
h1,
h2,
h3 {
    font-family: var(--font-headline);
    color: var(--text-strong);
    font-weight: 400;
    line-height: 1.25;
}

h1 {
    font-size: clamp(2rem, 5vw, 2.65rem);
    letter-spacing: -0.025em;
    line-height: 1.12;
}

h2 {
    font-size: clamp(1.3rem, 2.6vw, 1.55rem);
    margin-bottom: 1.1rem;
    letter-spacing: -0.01em;
}

h3 {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--teal-light);
    margin-top: 2.2rem;
    margin-bottom: 0.75rem;
    letter-spacing: 0.01em;
}

p {
    margin-bottom: 1.25rem;
    max-width: 64ch;
}

strong {
    color: var(--text-strong);
    font-weight: 600;
}

code {
    font-family: var(--font-mono);
    font-size: 0.85em;
    color: var(--teal-light);
}

code.node-address {
    font-size: 0.92em;
    letter-spacing: 0.01em;
    word-break: break-all;
}

/* --- LINKS --- */
a {
    color: var(--teal-light);
    text-decoration: underline;
    text-decoration-color: var(--teal-dim);
    text-underline-offset: 3px;
    text-decoration-thickness: 1px;
    transition: text-decoration-color 0.15s ease, color 0.15s ease;
}

a:hover {
    color: var(--text-strong);
    text-decoration-color: var(--text-muted);
}

/* --- OVERLINE LABEL --- */
.overline {
    display: block;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.68rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--teal);
    margin-bottom: 0.6rem;
}

/* --- LEAD PARAGRAPH (first para, larger) --- */
.lead {
    font-size: 1.15rem;
    line-height: 1.75;
    color: var(--text);
}

/* --- HERO SUBTITLE (secondary intro line) --- */
.hero-subtitle {
    font-size: 1.08rem;
    line-height: 1.75;
    color: var(--text-muted);
    margin-top: 0.75rem;
}

/* --- SITE HEADER --- */
.site-header {
    border-bottom: 1px solid var(--rule);
    padding: 1.15rem 0;
    background: var(--bg);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    max-width: var(--col-max);
    margin: 0 auto;
    padding: 0 var(--pad);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.site-logo {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.82rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-strong);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.site-logo img {
    width: 22px;
    height: 22px;
    border-radius: 3px;
}

.site-logo span {
    font-weight: 400;
    color: var(--text-muted);
}

.site-nav {
    display: flex;
    gap: 1.75rem;
    list-style: none;
}

.site-nav a {
    font-size: 0.8rem;
    letter-spacing: 0.03em;
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.15s ease;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
    color: var(--text-strong);
}

/* --- HERO --- */
.hero {
    padding: 3.5rem 0 0;
    max-width: var(--col-body);
    margin: 0 auto;
    padding-left: var(--pad);
    padding-right: var(--pad);
}

.hero h1 {
    animation: heroIn 0.5s ease 0.1s both;
}

.hero-verified-node {
    margin-top: 1.75rem;
    padding: 1.35rem 1.5rem;
    background: var(--bg-surface);
    border: 1px solid var(--rule-mid);
    border-left: 3px solid var(--teal);
    animation: heroIn 0.5s ease 0.3s both;
}

.node-label {
    display: block;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.45rem;
}

.node-address {
    display: block;
    font-family: var(--font-mono);
    font-size: 1rem;
    color: var(--teal-light);
    letter-spacing: 0.008em;
    word-break: break-all;
    line-height: 1.55;
    margin-bottom: 0.5rem;
}

.verification-badge {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--green);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.verification-badge::before {
    content: '';
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--green);
}

/* --- CONTENT SECTIONS --- */
:is(main, article)>section {
    max-width: var(--col-body);
    margin: 0 auto;
    padding: 2.75rem var(--pad) 0;
}

/* Remove excessive gaps — tight, precise */
:is(main, article)>section+section {
    padding-top: 2.75rem;
}

/* Section separator — subtle rule */
:is(main, article)>section:not(.hero):not(.verification-database):not(:first-child)::before {
    content: '';
    display: block;
    height: 1px;
    background: var(--rule);
    margin-bottom: 2.75rem;
}

/* --- PANEL SECTIONS (elevated, distinct) --- */
.section-panel {
    max-width: var(--col-body);
    margin: 0 auto;
    padding: 2.75rem var(--pad) 0;
}

.section-panel>.panel-body {
    background: var(--bg-panel);
    border: 1px solid var(--rule);
    padding: 2rem 2rem 0.75rem;
    margin-top: 1rem;
}

/* --- INSET SECTIONS (recessed, analytical) --- */
.section-inset {
    max-width: var(--col-body);
    margin: 0 auto;
    padding: 2.75rem var(--pad) 0;
}

.section-inset>.inset-body {
    border-left: 2px solid var(--teal-border);
    padding-left: 1.5rem;
    margin-top: 1rem;
}

/* --- VERIFICATION DATABASE TABLE --- */
.verification-database {
    max-width: var(--col-wide);
    margin: 0 auto;
    padding: 2.75rem var(--pad) 0;
}

.verification-database::before {
    content: '';
    display: block;
    max-width: var(--col-body);
    height: 1px;
    background: var(--rule);
    margin-bottom: 2.75rem;
}

.table-wrap {
    background: var(--bg-surface);
    border: 1px solid var(--rule);
    padding: 0.25rem;
    margin: 1.5rem 0;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    line-height: 1.5;
}

caption {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-dim);
    text-align: left;
    padding: 0.75rem 1rem 0.5rem;
}

thead {
    background: var(--bg-panel);
}

th {
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.7rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
    text-align: left;
    padding: 0.75rem 1rem;
    white-space: nowrap;
    border-bottom: 1px solid var(--rule-mid);
}

td {
    padding: 0.7rem 1rem;
    border-bottom: 1px solid var(--rule);
    color: var(--text-body);
    vertical-align: middle;
}

/* Subtle row hover */
tbody tr {
    transition: background 0.12s ease;
}

tbody tr:hover {
    background: rgba(255, 255, 255, 0.015);
}

td code.node-address {
    font-size: 0.8rem;
}

/* --- STATUS DOT --- */
.status-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    margin-right: 0.3rem;
    vertical-align: middle;
}

.status-dot--active {
    background: var(--green);
}

.status-dot--degraded {
    background: var(--teal-light);
}

.status-dot--offline {
    background: var(--red);
}

/* --- STATUS BANNER (status page hero) --- */
.status-banner {
    background: var(--bg-surface);
    border: 1px solid var(--rule);
    border-left: 3px solid var(--green);
    padding: 1.1rem 1.5rem;
    margin-bottom: 1.75rem;
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.status-banner-label {
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.status-banner-value {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--green);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* --- CALLOUT BLOCK (key findings, warnings) --- */
.callout {
    background: var(--teal-ghost);
    border-left: 2px solid var(--teal);
    padding: 1rem 1.25rem;
    margin: 1.5rem 0;
    font-size: 0.95rem;
    color: var(--text);
}

.callout p {
    margin-bottom: 0;
}

/* --- DATA POINT (inline stat highlight) --- */
.data-point {
    font-family: var(--font-mono);
    font-size: 0.9em;
    color: var(--teal-light);
    font-weight: 700;
}

/* --- STAGE MARKER (methodology steps) --- */
.stage-label {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--teal);
    background: var(--teal-ghost);
    border: 1px solid var(--teal-border);
    padding: 0.15rem 0.55rem;
    margin-right: 0.5rem;
    vertical-align: middle;
    border-radius: 2px;
}

/* --- BREADCRUMB --- */
.breadcrumb {
    max-width: var(--col-body);
    margin: 0 auto;
    padding: 0.85rem var(--pad) 0;
    font-size: 0.72rem;
    color: var(--text-dim);
}

.breadcrumb a {
    color: var(--text-muted);
    text-decoration: none;
}

.breadcrumb a:hover {
    color: var(--text-strong);
}

.breadcrumb-sep {
    margin: 0 0.35rem;
    color: var(--text-dim);
}

/* --- LEGAL META --- */
.legal-meta {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--rule);
}

/* --- FOOTER --- */
.site-footer {
    margin-top: 3.5rem;
    border-top: 1px solid var(--rule);
    background: var(--bg-surface);
}

.footer-inner {
    max-width: var(--col-max);
    margin: 0 auto;
    padding: 2.5rem var(--pad) 2rem;
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    gap: 1.5rem 3rem;
    grid-template-areas:
        "disclaimer nav"
        "meta meta";
}

.footer-disclaimer {
    grid-area: disclaimer;
    font-size: 0.76rem;
    line-height: 1.7;
    color: var(--text-dim);
    max-width: 56ch;
}

.footer-nav-wrap {
    grid-area: nav;
}

.footer-nav {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    list-style: none;
}

.footer-nav a {
    font-size: 0.78rem;
    letter-spacing: 0.02em;
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.15s ease;
}

.footer-nav a:hover {
    color: var(--text-strong);
}

.footer-meta {
    grid-area: meta;
    font-size: 0.7rem;
    color: var(--text-dim);
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding-top: 1.25rem;
    border-top: 1px solid var(--rule);
}

/* --- CSS CONTAINMENT (Performance) --- */
:is(main, article)>section:not(.hero):not(:first-of-type) {
    contain: layout style paint;
}

:is(main, article)>section:nth-of-type(n+4) {
    content-visibility: auto;
    contain-intrinsic-size: auto 600px;
}

/* --- KEYFRAMES --- */
@keyframes heroIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    .header-inner {
        flex-direction: column;
        gap: 0.65rem;
    }

    .site-nav {
        gap: 1.1rem;
        flex-wrap: wrap;
        justify-content: center;
    }

    :is(main, article)>section,
    :is(main, article)>section+section,
    .section-panel,
    .section-inset {
        padding-top: 2rem;
    }

    :is(main, article)>section:not(.hero):not(.verification-database):not(:first-child)::before {
        margin-bottom: 2rem;
    }

    .section-panel>.panel-body {
        padding: 1.25rem 1.25rem 0.5rem;
    }

    table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    th,
    td {
        padding: 0.55rem 0.7rem;
        white-space: nowrap;
    }

    .hero-verified-node {
        padding: 1.1rem 1.2rem;
    }

    .footer-inner {
        grid-template-columns: 1fr;
        grid-template-areas:
            "nav"
            "disclaimer"
            "meta";
        gap: 1.25rem;
    }

    .footer-nav {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.5rem 1.25rem;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.55rem;
    }

    .node-address {
        font-size: 0.85rem;
    }

    .status-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.6rem;
    }
}

/* --- PRINT --- */
@media print {
    body {
        color: #111;
        background: #fff;
        font-size: 11pt;
    }

    a {
        color: #111;
    }

    code {
        color: #333;
    }

    .site-header,
    .site-footer {
        display: none;
    }

    .section-panel>.panel-body,
    .hero-verified-node,
    .table-wrap {
        border-color: #ccc;
        background: #f9f9f9;
    }
}