/* ══════════════════════════════════════════════════════════
   OKX Arbitration Evidence System — Shared Exhibit Styles
   ══════════════════════════════════════════════════════════ */

:root {
    --red: #b91c1c; --red-light: #f8f9fa; --red-mid: #f1f3f5;
    --green: #1DB954; --green-light: #f0fdf4;
    --navy: #111827; --slate: #1a1a1a; --gray: #666666; --gray-light: #999999;
    --bg: #ffffff; --bg-alt: #f5f5f5; --border: #e5e5e5;
    --blue: #1d4ed8; --blue-light: #eff6ff;
    --amber: #92400e; --amber-light: #fffbeb;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: 'Noto Sans SC', 'Inter', system-ui, -apple-system, sans-serif;
    background: var(--bg); color: var(--slate);
    font-size: 15px; line-height: 1.8;
    -webkit-font-smoothing: antialiased;
}

/* ── Global Navigation ── */
.global-nav {
    position: sticky; top: 0; z-index: 200;
    background: #111827;
    border-bottom: 1px solid #2a2a2a;
    height: 60px;
    font-size: 15px;
}
.global-nav-inner {
    max-width: 1100px; margin: 0 auto;
    padding: 0 24px; height: 100%;
    display: flex; align-items: center; position: relative;
}
.global-nav-brand {
    color: #fff; font-weight: 700; font-size: 16px; text-decoration: none;
    white-space: nowrap; display: flex; align-items: center; gap: 8px;
    flex-shrink: 0;
}

.brand-stamp {
    display: inline-flex;
    align-items: baseline;
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 2.5px;
    line-height: 1;
    font-family: 'Inter', system-ui, sans-serif;
    text-transform: uppercase;
    flex-shrink: 0;
    white-space: nowrap;
    transition: opacity 0.2s;
}
.brand-stamp:hover { opacity: 0.8; }
.brand-stamp span {
    color: #dc2626 !important;
    font-weight: 700;
    letter-spacing: 2.5px;
}
.brand-stamp em {
    font-style: normal;
    color: rgba(255,255,255,0.3);
    font-size: 0.7em;
    font-weight: 500;
    margin-left: 10px;
    padding-left: 10px;
    border-left: 1px solid rgba(255,255,255,0.15);
    letter-spacing: 1.5px;
}
.global-nav-links {
    position: absolute; left: 52%; transform: translateX(-50%);
    display: flex; gap: 0; align-items: center; height: 100%;
}
.global-nav-link {
    color: rgba(255,255,255,0.55);
    text-decoration: none; font-size: 13px; font-weight: 600;
    padding: 0 10px; height: 100%;
    display: flex; align-items: center;
    border-bottom: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s;
    white-space: nowrap;
}
.global-nav-link:hover { color: #fff; }
.global-nav-link.active { color: #fff; border-bottom-color: #1DB954; }
.global-nav-right { display: flex; gap: 8px; align-items: center; margin-left: auto; }
.global-nav-arrow {
    color: rgba(255,255,255,0.4); text-decoration: none;
    font-size: 11px; font-weight: 500; padding: 4px 8px;
    border: 1px solid rgba(255,255,255,0.12); border-radius: 4px;
    transition: color 0.15s, border-color 0.15s;
}
.global-nav-arrow:hover { color: #fff; border-color: rgba(255,255,255,0.3); }
.btn-lang {
    color: rgba(255,255,255,0.7); text-decoration: none;
    font-size: 11px; font-weight: 700; padding: 3px 10px;
    border: 1px solid rgba(255,255,255,0.2); border-radius: 4px;
    letter-spacing: 0.5px;
    transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.btn-lang:hover { color: #fff; border-color: rgba(255,255,255,0.5); background: rgba(255,255,255,0.08); }

/* ── Discord nav button ── */
.btn-discord {
    display: inline-flex; align-items: center; gap: 5px;
    color: #fff; text-decoration: none;
    font-size: 11px; font-weight: 600; padding: 4px 12px;
    background: #5865F2; border-radius: 4px;
    transition: background 0.15s;
}
.btn-discord:hover { background: #4752c4; }
.btn-discord svg { flex-shrink: 0; }

/* ── Social floating buttons ── */
.social-float {
    position: fixed; bottom: 24px; right: 24px; z-index: 9999;
    display: flex; flex-direction: column; gap: 10px; align-items: flex-end;
}
.social-float a {
    display: flex; align-items: center; gap: 0;
    width: 48px; height: 48px; border-radius: 50%;
    color: #fff; text-decoration: none;
    justify-content: center; overflow: hidden;
    transition: width 0.3s cubic-bezier(.4,0,.2,1), border-radius 0.3s, background 0.2s;
}
.social-float a:hover {
    width: auto; border-radius: 24px; padding: 0 20px;
}
.social-float a svg { flex-shrink: 0; }
.social-float a span {
    max-width: 0; overflow: hidden; white-space: nowrap;
    font-size: 13px; font-weight: 600; letter-spacing: 0.3px;
    transition: max-width 0.3s cubic-bezier(.4,0,.2,1), margin 0.3s;
    margin-left: 0;
}
.social-float a:hover span {
    max-width: 140px; margin-left: 10px;
}
.social-tg { background: #26A5E4; }
.social-tg:hover { background: #1e96d1; }
.social-dc { background: #5865F2; }
.social-dc:hover { background: #4752c4; }
.social-x { background: #000000; }
.social-submit { background: #1d4ed8; }
.social-submit:hover { background: #1e40af; }

.social-x:hover { background: #1a1a1a; }

/* ── Toolbar ── */
.toolbar {
    position: sticky; top: 60px; z-index: 100;
    background: rgba(255,255,255,0.95); backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--border);
    padding: 8px 64px; display: flex; justify-content: space-between; align-items: center;
}
.toolbar-left { font-size: 12px; color: var(--gray); font-weight: 500; letter-spacing: 0.5px; }
.toolbar-right { display: flex; gap: 8px; align-items: center; }
.btn {
    border: none; border-radius: 4px; padding: 6px 16px;
    font-size: 12px; font-weight: 500; cursor: pointer;
    font-family: inherit; transition: opacity 0.2s;
    text-decoration: none; display: inline-block;
}
.btn:hover { opacity: 0.85; }
.btn:disabled { opacity: 0.4; cursor: wait; }
.btn-primary { background: #111827; color: #fff; }
.btn-cta { background: #1DB954; color: #fff; }
.btn-secondary { background: transparent; color: var(--gray); border: 1px solid var(--border); }
.btn-nav { background: transparent; color: var(--gray); border: 1px solid var(--border); font-size: 11px; padding: 5px 12px; }
.btn-nav:hover { background: var(--bg-alt); color: var(--navy); }

/* ── Print / PDF ── */
@media print {
    body { background: #fff; }
    .no-print { display: none !important; }
    .global-nav { display: none !important; }
    .toolbar { display: none !important; }
    .chart-wrap, .exhibit, .finding { break-inside: avoid; }
    .conclusion { break-inside: avoid; }
    .pdf-break { break-before: page; page-break-before: always; }
    @page { margin: 15mm; size: A4; }
    .page-header { padding: 28px 0 24px; }
    .content { padding: 20px 0; max-width: 100%; }
    .footer { padding: 12px 0; }
}

/* ── Header ── */
.page-header {
    background: var(--navy); color: #fff;
    padding: 48px 24px 40px;
}
.page-header-inner {
    max-width: 1100px; margin: 0 auto; padding: 0 24px;
}
.header-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; }
.exhibit-id {
    display: inline-block; background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15); border-radius: 4px;
    padding: 3px 14px; font-size: 11px; letter-spacing: 2.5px;
    font-weight: 600; margin-bottom: 16px; text-transform: uppercase;
}
h1.page-title { margin: 0; padding: 0; }
.page-title {
    font-family: 'Noto Serif SC', serif;
    font-size: 28px; font-weight: 700; line-height: 1.3; margin-bottom: 6px;
}
.page-title-en { font-size: 14px; color: rgba(255,255,255,0.35); font-weight: 400; }
.meta-box { text-align: right; font-size: 12px; color: rgba(255,255,255,0.45); line-height: 2; flex-shrink: 0; }
.meta-box strong { color: rgba(255,255,255,0.75); }

.core-finding {
    margin: 28px 0 0; background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1); border-radius: 4px;
    padding: 18px 24px;
}
.core-finding-label {
    font-size: 10px; letter-spacing: 2px; text-transform: uppercase;
    color: #f87171; font-weight: 700; margin-bottom: 6px;
}
.core-finding p { font-size: 14.5px; color: rgba(255,255,255,0.8); line-height: 1.9; }
.core-finding strong { color: #f87171; }

/* ── Content ── */
.content { max-width: 1100px; margin: 0 auto; padding: 40px 24px 48px; }

/* ── Methodology ── */
.methodology {
    background: var(--bg-alt); border: 1px solid var(--border); border-radius: 4px;
    padding: 20px 24px; margin-bottom: 32px;
}
.methodology h3 { font-size: 13px; font-weight: 600; color: var(--navy); margin-bottom: 6px; letter-spacing: 0.5px; }
.methodology p { font-size: 13px; color: var(--gray); line-height: 1.8; }
.method-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 10px; }
.method-item { font-size: 12px; color: var(--gray); }
.method-item strong { display: block; color: var(--navy); font-size: 12.5px; margin-bottom: 1px; }

/* ── Metrics ── */
.metrics-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 32px; }
.metric { border: 1px solid var(--border); border-radius: 4px; padding: 18px 20px; }
.metric.alert { border-color: var(--border); background: var(--red-light); border-left: 3px solid var(--red); }
.metric-label { font-size: 11.5px; color: var(--gray); text-transform: uppercase; letter-spacing: 0.5px; }
.metric-value { font-size: 30px; font-weight: 700; margin: 3px 0; font-family: 'Inter', sans-serif; }
.metric-value.red { color: var(--red); }
.metric-value.green { color: var(--green); }
.metric-sub { font-size: 12px; color: var(--gray); }
.tag { display: inline-block; margin-top: 5px; font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 3px; }
.tag-red { background: var(--red-mid); color: var(--red); }
.tag-green { background: #dcfce7; color: #1DB954; }

/* ── Exhibit Section ── */
.exhibit { margin-bottom: 36px; }
.exhibit-header { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 4px; }
.exhibit-num {
    flex-shrink: 0; min-width: 68px; height: 26px; padding: 0 10px;
    background: var(--navy); color: #fff; border-radius: 4px;
    display: flex; align-items: center; justify-content: center;
    font-size: 10.5px; font-weight: 600; letter-spacing: 0.5px;
}
.exhibit-info { flex: 1; }
.exhibit-name { font-family: 'Noto Serif SC', serif; font-size: 17px; font-weight: 600; color: var(--navy); }
.exhibit-desc { font-size: 13px; color: var(--gray); margin-top: 2px; line-height: 1.7; }
.chart-wrap {
    background: #fff; border: 1px solid var(--border); border-radius: 4px;
    padding: 20px; margin-top: 10px;
    touch-action: pan-y;
}
[id^="chart-"] { touch-action: pan-y !important; }
.highcharts-container { touch-action: pan-y !important; }
.chart-source {
    font-size: 11px; color: var(--gray-light); text-align: right;
    margin-top: 6px; padding-right: 4px;
}

/* ── Finding Box ── */
.finding { border-radius: 4px; padding: 14px 18px; margin-top: 14px; font-size: 13.5px; line-height: 1.9; }
.finding.red { background: var(--red-light); border-left: 3px solid var(--red); }
.finding.blue { background: var(--blue-light); border-left: 3px solid var(--blue); }
.finding.green { background: var(--green-light); border-left: 3px solid var(--green); }
.finding.amber { background: var(--amber-light); border-left: 3px solid var(--amber); }
.finding-label { font-size: 11px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase; margin-bottom: 3px; }
.finding-label.red { color: var(--red); }
.finding-label.blue { color: var(--blue); }
.finding-label.amber { color: var(--amber); }
.finding p { color: #374151; }
.finding strong { color: var(--navy); }

/* ── Incident Quote ── */
.incident-quote { background: #1a1a1a; border-radius: 4px; padding: 24px 28px; margin: 16px 0; color: #fff; }
.incident-quote .source { font-size: 10px; color: #999999; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 10px; }
.incident-quote blockquote {
    font-size: 15px; font-style: italic; line-height: 1.7; color: #e5e5e5;
    border-left: 3px solid #b91c1c; padding-left: 14px; margin-bottom: 10px;
}
.incident-quote .meta { font-size: 11px; color: #999999; line-height: 1.8; }
.incident-quote .meta a { color: #93c5fd; text-decoration: none; }

/* ── Defense Rebuttal ── */
.defense-grid { display: grid; gap: 10px; margin-top: 12px; }
.defense-item {
    border: 1px solid var(--border); border-radius: 4px; padding: 14px 18px;
    display: grid; grid-template-columns: 36px 1fr; gap: 12px; align-items: start;
}
.defense-num {
    width: 28px; height: 28px; border-radius: 4px;
    background: var(--bg-alt); border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
    font-size: 11px; font-weight: 700; color: var(--gray);
}
.defense-claim {
    font-size: 13px; font-weight: 600; color: var(--gray);
    margin-bottom: 4px; padding: 2px 0;
}
.defense-claim::before { content: '\201C'; }
.defense-claim::after { content: '\201D'; }
.defense-response { font-size: 13.5px; color: var(--slate); line-height: 1.8; }
.defense-response strong { color: var(--red); }

/* ── Summary Table ── */
.table-wrap { overflow-x: auto; margin-top: 10px; }
.ev-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.ev-table thead th {
    background: var(--navy); color: #fff; padding: 9px 12px; text-align: left;
    font-size: 11.5px; text-transform: uppercase; letter-spacing: 0.5px; font-weight: 500;
}
.ev-table thead th:first-child { border-radius: 4px 0 0 0; }
.ev-table thead th:last-child { border-radius: 0 4px 0 0; }
.ev-table tbody td { padding: 9px 12px; border-bottom: 1px solid #f5f5f5; }
.ev-table tbody tr:hover { background: var(--bg-alt); }
.ev-table .highlight { background: var(--red-light); }
.ev-table .mono { font-family: 'Inter', monospace; font-size: 12px; }
.pill { display: inline-block; padding: 2px 7px; border-radius: 3px; font-size: 10px; font-weight: 600; }
.pill-red { background: #f1f3f5; color: #991b1b; }
.pill-green { background: #dcfce7; color: #1DB954; }
.pill-amber { background: #fef3c7; color: #92400e; }

/* ── Conclusion ── */
.conclusion { background: #111827; color: #fff; border-radius: 4px; padding: 28px 32px; margin-top: 36px; }
.conclusion h2 { font-family: 'Noto Serif SC', serif; font-size: 20px; font-weight: 700; margin-bottom: 14px; }
.conclusion ol { padding-left: 18px; }
.conclusion li { margin-bottom: 10px; font-size: 14px; line-height: 1.9; color: rgba(255,255,255,0.82); }
.conclusion li strong { color: #f87171; }
.chain {
    margin-top: 18px; padding: 14px 18px; background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08); border-radius: 4px;
    font-size: 13.5px; color: rgba(255,255,255,0.65); text-align: center; letter-spacing: 0.3px;
}
.chain strong { color: #fff; }

/* ── Footer ── */
.footer {
    border-top: 1px solid var(--border); max-width: 1100px;
    margin: 36px auto 0; padding: 16px 24px;
    display: flex; justify-content: space-between;
    font-size: 10.5px; color: var(--gray);
}
.nav-back { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: rgba(255,255,255,0.35); text-decoration: none; }
.nav-back:hover { color: #fff; }

/* ── Coin Navigation Bar ── */
.coin-nav {
    display: flex; flex-wrap: wrap; gap: 6px;
    justify-content: center;
    max-width: 1100px; margin: 0 auto;
    padding: 12px 24px;
    background: var(--bg-alt); border-bottom: 1px solid var(--border);
}
.coin-nav-item {
    display: inline-block; padding: 5px 14px; border-radius: 4px;
    font-size: 12px; font-weight: 600; color: var(--gray);
    text-decoration: none; border: 1px solid var(--border);
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.coin-nav-item:hover { background: #fff; color: var(--navy); border-color: #999999; }
.coin-nav-active { background: var(--navy); color: #fff; border-color: var(--navy); }
.coin-nav-active:hover { background: var(--navy); color: #fff; }
.coin-nav-arrows {
    display: flex; justify-content: space-between; padding: 6px 64px;
    font-size: 12px; background: var(--bg-alt); border-bottom: 1px solid var(--border);
}
.coin-nav-arrows a { color: var(--gray); text-decoration: none; }
.coin-nav-arrows a:hover { color: var(--navy); }

/* ── Floating Logo ── */
.floating-logo {
    position: fixed; z-index: 9999;
    width: 120px; height: 120px;
    opacity: 1;
    pointer-events: none;
    border-radius: 6px;
    transition: opacity 0.3s;
}

/* Highcharts clean overrides */
.highcharts-button-box { fill: transparent; stroke: none; }
.highcharts-contextbutton { opacity: 0.35; }
.highcharts-contextbutton:hover { opacity: 1; }

/* ── Metrics row responsive ── */
@media (max-width: 900px) {
    .metrics-row { grid-template-columns: repeat(2, 1fr); }
    .method-grid { grid-template-columns: repeat(2, 1fr); }
    .global-nav-inner { padding: 0 16px; }
    .global-nav-link { padding: 0 8px; font-size: 11px; }
    .global-nav-brand { font-size: 12px; }
    .page-header { padding: 28px 16px 24px; }
    .content { padding: 24px 16px 32px; }
    .footer { padding: 12px 16px; }
}

/* ── Mobile ≤600px ── */
@media (max-width: 600px) {
    /* Navigation — two-row layout */
    .global-nav { height: auto; }
    .global-nav-inner {
        flex-wrap: wrap; padding: 8px 12px; gap: 0; height: auto;
    }
    /* Row 1 left: brand */
    .global-nav-brand { font-size: 13px; order: 1; }
    
    /* Row 1 right: lang + export */
    .global-nav-right { order: 2; margin-left: auto; gap: 6px; }
    .btn-lang { font-size: 10px; padding: 2px 8px; }
    .global-nav-right .btn { font-size: 10px !important; padding: 4px 10px !important; }
    .global-nav-arrow { font-size: 10px; padding: 3px 6px; }
    /* Row 2: nav links — horizontal scroll strip */
    .global-nav-links {
        position: static; transform: none; order: 3;
        width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch;
        margin-top: 8px; padding-top: 6px;
        border-top: 1px solid rgba(255,255,255,0.08);
    }
    .global-nav-links::-webkit-scrollbar { display: none; }
    .global-nav-links { scrollbar-width: none; }
    .global-nav-link {
        font-size: 12px; font-weight: 500; padding: 4px 10px;
        flex-shrink: 0; height: auto; border-bottom: none;
    }

    /* Header */
    .header-row { flex-direction: column; gap: 16px; }
    .meta-box { text-align: left; }
    .page-title { font-size: 22px; }
    .exhibit-id { font-size: 10px; padding: 2px 10px; }
    .core-finding p { font-size: 13px; }

    /* Grid */
    .metrics-row { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .method-grid { grid-template-columns: 1fr; }
    .metric-value { font-size: 24px; }
    .metric-label { font-size: 10px; }

    /* Content spacing */
    body { font-size: 14px; }
    .content { padding: 20px 14px 28px; }
    .finding { padding: 12px 14px; font-size: 13px; }
    .incident-quote { padding: 16px 18px; }
    .incident-quote blockquote { font-size: 13px; }
    .conclusion { padding: 20px 20px; }
    .conclusion h2 { font-size: 17px; }
    .conclusion li { font-size: 13px; }
    .chain { font-size: 12px; }
    .exhibit-name { font-size: 15px; }
    .exhibit-desc { font-size: 12px; }
    .defense-item { grid-template-columns: 28px 1fr; gap: 8px; padding: 10px 14px; }
    .chart-wrap { padding: 12px; }
    .toolbar { padding: 8px 14px; top: auto; }

    /* Tables */
    .ev-table { font-size: 11px; }
    .ev-table thead th { padding: 6px 8px; font-size: 9px; }
    .ev-table tbody td { padding: 6px 8px; }
    .pill { font-size: 9px; padding: 1px 5px; }

    /* Social float mobile */
    .social-float { bottom: 14px; right: 14px; gap: 6px; }
    .social-float a { width: 40px; height: 40px; }

    /* Footer */
    .footer { flex-direction: column; gap: 8px; font-size: 10px; }

    /* Floating logo — shrink on mobile */
    .floating-logo { width: 48px; height: 48px; opacity: 0.5; }
}

/* ── Mobile ≤480px ── */
@media (max-width: 480px) {
    .metrics-row { grid-template-columns: 1fr; }
}
