:root {
    --ink: #171512;
    --ink-soft: #2c2924;
    --desk: #0a252d;
    --desk-deep: #031014;
    --cork: #12383e;
    --cork-dark: #09252b;
    --paper: #efe5cd;
    --paper-light: #f8f1df;
    --paper-aged: #d9c9a7;
    --red: #8d211f;
    --red-bright: #b1332f;
    --blue: #365b6d;
    --ochre: #a77a28;
    --green: #506348;
    --gold: #b77b16;
    --gold-light: #e0b64b;
    --white: #f6f0e4;
    --muted: #aaa18f;
    --line: rgba(239, 229, 205, 0.18);
    --type-display: "Playfair Display", Georgia, serif;
    --type-body: "Crimson Text", Georgia, serif;
    --type-mono: "Special Elite", "Courier New", monospace;
    --header-h: 82px;
    --timeline-h: 54px;
}

* { box-sizing: border-box; }

html, body { margin: 0; min-height: 100%; }

body {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    display: grid;
    grid-template-rows: var(--header-h) auto 28px minmax(0, 1fr) var(--timeline-h) auto;
    color: var(--white);
    font-family: var(--type-body);
    background:
        radial-gradient(circle at 50% 10%, rgba(29, 79, 85, 0.42), transparent 38%),
        linear-gradient(115deg, rgba(255, 255, 255, 0.018) 0 1px, transparent 1px 5px),
        var(--desk-deep);
}

button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible, input:focus-visible, [tabindex]:focus-visible {
    outline: 2px solid var(--paper-light);
    outline-offset: 3px;
}

.case-header {
    position: relative;
    z-index: 120;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    min-width: 0;
    padding: 0 28px;
    border-bottom: 1px solid rgba(224, 182, 75, 0.2);
    background: rgba(4, 20, 25, 0.97);
    box-shadow: 0 9px 30px rgba(0, 0, 0, 0.32);
}

.brand-lockup {
    justify-self: start;
    color: var(--white);
    font-family: var(--type-mono);
    font-size: .7rem;
    letter-spacing: .14em;
    text-decoration: none;
}
.brand-lockup span { color: var(--gold-light); }

.brand-kicker, .section-label, .case-number, .case-status, .timeline-caption,
.workspace-label, .search-label, .sheet-register, .card-date, .card-category {
    font-family: var(--type-mono);
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.brand-kicker { font-size: 0.66rem; color: var(--gold-light); }
.brand-name { font-family: var(--type-display); font-size: 1.15rem; }

.case-identity {
    display: grid;
    grid-template-columns: auto auto;
    column-gap: 14px;
    align-items: center;
    text-align: center;
}

.case-identity h1 {
    grid-column: 1 / -1;
    grid-row: 1;
    margin: 0;
    font-family: var(--type-display);
    font-size: clamp(1.18rem, 2vw, 1.5rem);
    letter-spacing: 0.025em;
}

.case-number, .case-status {
    grid-row: 2;
    margin-top: 3px;
    font-size: 0.58rem;
    color: var(--muted);
}

.case-number { justify-self: end; }
.case-status { justify-self: start; display: flex; align-items: center; gap: 6px; }
.case-status i { width: 6px; height: 6px; border-radius: 50%; background: #a83f35; box-shadow: 0 0 0 3px rgba(168, 63, 53, 0.14); }

.header-actions { justify-self: end; display: flex; align-items: center; gap: 10px; }
.text-button, .file-button {
    min-height: 42px;
    border: 0;
    color: var(--white);
    cursor: pointer;
}
.text-button { background: transparent; padding: 8px 10px; font-family: var(--type-mono); font-size: 0.72rem; }
.file-button {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 9px 14px;
    border-left: 3px solid var(--red);
    background: var(--gold-light);
    color: var(--ink);
    font-family: var(--type-mono);
    font-size: 0.72rem;
    box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.34);
}
.text-button:hover { color: var(--paper-aged); }
.file-button:hover { background: var(--paper-light); }

.case-brief {
    position: relative;
    z-index: 80;
    display: grid;
    grid-template-columns: minmax(300px, 1.4fr) minmax(300px, 0.8fr);
    gap: 12px 36px;
    align-items: center;
    padding: 16px 28px 14px;
    color: var(--white);
    background:
        radial-gradient(circle at 82% 25%, rgba(183, 123, 22, .1), transparent 28%),
        linear-gradient(90deg, transparent 0 49px, rgba(224, 182, 75, 0.13) 49px 50px, transparent 50px),
        repeating-linear-gradient(0deg, transparent 0 26px, rgba(224, 182, 75, 0.035) 26px 27px),
        var(--desk);
    border-bottom: 1px solid rgba(224, 182, 75, .28);
    box-shadow: 0 5px 16px rgba(0, 0, 0, 0.24);
}

.brief-copy { max-width: 740px; padding-left: 38px; }
.section-label { margin: 0 0 5px; font-size: 0.62rem; color: var(--red); }
.brief-copy h2 { margin: 0 0 5px; font-family: var(--type-display); font-size: clamp(1.22rem, 2.25vw, 1.78rem); line-height: 1.1; }
.brief-copy > p:not(.contract-note) { margin: 0; max-width: 70ch; font-size: 1rem; line-height: 1.35; color: #c8bea7; }
.brief-copy .contract-note { margin: 7px 0 0; color: #8fa39b; font-family: var(--type-mono); font-size: .55rem; line-height: 1.45; }
.contract-note code { color: #d2b963; font: inherit; overflow-wrap: anywhere; }

.brief-aside { min-width: 0; }
.case-metadata { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin: 0; border: 1px solid rgba(224, 182, 75, .24); }
.case-metadata div { padding: 8px 12px; border-right: 1px solid rgba(224, 182, 75, .2); }
.case-metadata div:last-child { border-right: 0; }
.case-metadata dt { font-family: var(--type-mono); font-size: 0.56rem; letter-spacing: 0.09em; text-transform: uppercase; color: #8fa39b; }
.case-metadata dd { margin: 4px 0 0; font-family: var(--type-display); font-size: 0.92rem; }
.support-panel { position: relative; z-index: 1; margin-top: 7px; }
.support-panel[open] { z-index: 160; }
.support-panel summary { display: flex; align-items: center; justify-content: space-between; min-height: 34px; padding: 7px 10px; border: 1px solid rgba(224,182,75,.26); color: var(--gold-light); background: rgba(3,16,20,.48); font-family: var(--type-mono); font-size: .58rem; letter-spacing: .045em; cursor: pointer; list-style: none; }
.support-panel summary::-webkit-details-marker { display: none; }
.support-panel summary:hover { background: rgba(224,182,75,.08); }
.support-toggle-mark { font-size: 1rem; font-style: normal; line-height: 1; transition: transform 180ms ease; }
.support-panel[open] .support-toggle-mark { transform: rotate(45deg); }
.support-body { position: absolute; top: calc(100% + 8px); right: 0; width: min(370px, calc(100vw - 36px)); padding: 18px; border: 1px solid #9d782c; color: var(--ink); background: var(--paper-light); box-shadow: 10px 16px 36px rgba(0,0,0,.48); }
.support-message { margin: 0 0 15px; font-size: 1rem; line-height: 1.35; }
.wallet-panel { display: grid; grid-template-columns: 126px minmax(0, 1fr); gap: 15px; align-items: start; }
.wallet-qr { display: block; width: 126px; height: 126px; object-fit: cover; border: 6px solid #121212; background: #121212; }
.wallet-network { margin: 1px 0 8px; color: var(--red); font-family: var(--type-mono); font-size: .55rem; letter-spacing: .1em; }
.wallet-details code { display: block; overflow-wrap: anywhere; color: #3f392f; font-family: var(--type-mono); font-size: .6rem; line-height: 1.48; }
.copy-wallet { min-height: 34px; margin-top: 11px; padding: 6px 9px; border: 1px solid rgba(23,21,18,.45); color: var(--ink); background: transparent; font-family: var(--type-mono); font-size: .58rem; cursor: pointer; }
.copy-wallet:hover { color: var(--paper-light); background: var(--ink); }
.wallet-caution { margin: 13px 0 0; padding-top: 10px; border-top: 1px solid rgba(23,21,18,.17); color: #6b6254; font-family: var(--type-mono); font-size: .53rem; line-height: 1.4; }
.site-end { position: relative; z-index: 100; display: grid; grid-template-columns: minmax(0,1fr); align-items: stretch; border-top: 1px solid rgba(224,182,75,.12); background: #020c0f; }
.disclaimer { margin: 0; padding: 8px 28px 7px; color: #71837c; font-family: var(--type-mono); font-size: 0.58rem; line-height: 1.35; }
.contact-button {
    position: fixed;
    right: max(22px, env(safe-area-inset-right));
    bottom: max(22px, env(safe-area-inset-bottom));
    z-index: 170;
    display: inline-flex;
    align-items: center;
    gap: 11px;
    min-height: 48px;
    padding: 11px 16px 10px;
    border: 1px solid rgba(224,182,75,.78);
    border-radius: 3px 3px 0 3px;
    color: var(--gold-light);
    background: rgba(3,16,20,.94);
    box-shadow: 0 10px 28px rgba(0,0,0,.42), inset 0 0 0 1px rgba(239,229,205,.05);
    font-family: var(--type-mono);
    font-size: .59rem;
    letter-spacing: .12em;
    text-decoration: none;
    text-transform: uppercase;
    backdrop-filter: blur(8px);
    transition: color 180ms ease, background-color 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}
.contact-button::before { content: "↗"; order: 2; font-family: var(--type-display); font-size: 1rem; line-height: 1; }
.contact-button::after {
    content: "";
    position: absolute;
    right: 13px;
    bottom: -6px;
    width: 10px;
    height: 10px;
    border-right: 1px solid currentColor;
    border-bottom: 1px solid currentColor;
    background: rgba(3,16,20,.94);
    transform: skew(-18deg) rotate(45deg);
    transition: background-color 180ms ease;
}
.contact-button:hover { color: var(--ink); background: var(--gold-light); box-shadow: 0 13px 34px rgba(0,0,0,.52); transform: translateY(-2px); }
.contact-button:hover::after { background: var(--gold-light); }

.workspace-label {
    position: relative;
    z-index: 70;
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 0 28px;
    background: #06171c;
    border-bottom: 1px solid rgba(224, 182, 75, 0.1);
    color: var(--paper-aged);
    font-size: 0.58rem;
}
.board-instruction { display: inline-flex; align-items: center; gap: 8px; color: #8e877a; letter-spacing: 0.04em; text-transform: none; }
.board-instruction::before { content: ""; width: 6px; height: 6px; flex: 0 0 6px; border-radius: 50%; background: var(--red-bright); box-shadow: 0 0 0 3px rgba(177, 51, 47, 0.15); }

.board-viewport { position: relative; min-height: 0; overflow: hidden; cursor: grab; isolation: isolate; }
.board-viewport::after { content: ""; position: absolute; inset: 0; z-index: 30; pointer-events: none; box-shadow: inset 0 0 90px rgba(0, 0, 0, 0.48); }
.board-viewport.is-dragging { cursor: grabbing; }

.board-container {
    position: absolute;
    inset: 0 auto auto 0;
    transform-origin: 0 0;
    min-width: max-content;
    min-height: 1500px;
    background:
        linear-gradient(96deg, rgba(255, 255, 255, 0.025), transparent 18%, rgba(0, 0, 0, 0.05) 45%, transparent 72%),
        radial-gradient(circle at 15% 30%, rgba(255,255,255,.05) 0 1px, transparent 2px),
        radial-gradient(circle at 72% 72%, rgba(0,0,0,.12) 0 1px, transparent 2px),
        var(--cork);
    background-size: auto, 9px 11px, 13px 15px, auto;
    box-shadow: inset 0 0 140px rgba(36, 20, 11, 0.72);
    will-change: transform;
}

.string-layer { position: absolute; inset: 0; pointer-events: none; z-index: 5; overflow: visible; }
.evidence-thread { fill: none; stroke: var(--red); stroke-width: 3.5; opacity: 0.78; filter: drop-shadow(1px 3px 1px rgba(0,0,0,.45)); }
.thread-knot { fill: var(--red-bright); stroke: #54110f; stroke-width: 2; }

.cork-board { position: relative; z-index: 10; display: flex; align-items: flex-start; gap: 120px; min-height: 1500px; padding: 74px 110px 180px; }
.month-column { position: relative; display: flex; flex-direction: column; width: 470px; flex: 0 0 470px; padding: 0 26px 80px; scroll-margin-top: calc(var(--header-h) + 8px); }
.month-column::before { content: ""; position: absolute; top: 74px; bottom: 30px; left: 50%; border-left: 1px dashed rgba(239, 229, 205, 0.17); }
.month-label { position: sticky; top: 28px; z-index: 2; margin: 0 0 42px; padding: 0 0 14px; color: rgba(246, 240, 228, 0.72); border-bottom: 1px solid rgba(246, 240, 228, 0.2); font-family: var(--type-display); font-size: 2rem; font-weight: 600; text-align: left; }
.month-label small { display: block; margin-bottom: 5px; font-family: var(--type-mono); font-size: 0.58rem; letter-spacing: 0.13em; text-transform: uppercase; color: rgba(246, 240, 228, 0.42); }

.evidence-card {
    position: relative;
    width: 330px;
    margin: 0 0 38px;
    padding: 22px 22px 25px;
    border: 0;
    color: var(--ink);
    background:
        repeating-linear-gradient(0deg, transparent 0 24px, rgba(38, 33, 25, 0.045) 24px 25px),
        linear-gradient(95deg, var(--paper-light), var(--paper));
    box-shadow: 3px 7px 16px rgba(20, 12, 7, 0.42), 0 0 0 1px rgba(71, 54, 35, 0.18);
    cursor: pointer;
    transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease;
}
.evidence-card:nth-of-type(3n + 1) { align-self: flex-start; transform: rotate(-1.1deg); }
.evidence-card:nth-of-type(3n + 2) { align-self: flex-end; transform: rotate(1.3deg); }
.evidence-card:nth-of-type(3n) { align-self: center; transform: rotate(-0.4deg); }
.evidence-card:hover, .evidence-card:focus-visible { z-index: 20; transform: translateY(-5px) rotate(0deg); box-shadow: 8px 16px 25px rgba(20, 12, 7, 0.55), 0 0 0 2px rgba(246, 240, 228, 0.58); }
.evidence-card::before { content: ""; position: absolute; top: -9px; left: 50%; width: 15px; height: 15px; transform: translateX(-50%); border-radius: 50%; background: radial-gradient(circle at 35% 30%, #e68072 0 12%, var(--red-bright) 22%, #5d1211 72%); box-shadow: 2px 4px 5px rgba(0,0,0,.45); }
.evidence-card::after { content: attr(data-index); position: absolute; top: 16px; right: -15px; padding: 5px 7px 4px; border: 1px solid rgba(23,21,18,.45); background: #e2d3b6; color: #51483b; font-family: var(--type-mono); font-size: .58rem; transform: rotate(3deg); }
.evidence-card[data-cat="clue"] { border-top: 5px solid var(--red); }
.evidence-card[data-cat="market"] { border-top: 5px solid var(--blue); }
.evidence-card[data-cat="user"] { border-top: 5px solid var(--ochre); }
.card-date { padding-bottom: 8px; margin-bottom: 11px; border-bottom: 1px solid rgba(23,21,18,.18); font-size: .66rem; color: #6b6255; }
.card-title { margin: 0 0 10px; font-family: var(--type-display); font-size: 1.3rem; line-height: 1.14; }
.card-content { display: -webkit-box; margin: 0 0 15px; overflow: hidden; -webkit-line-clamp: 4; -webkit-box-orient: vertical; font-size: 1rem; line-height: 1.42; color: #3f392f; }
.card-image { display: block; max-width: 100%; height: auto; margin: 0 0 15px; padding: 5px; background: #fff; box-shadow: 1px 2px 4px rgba(0,0,0,.25); }
.card-link { display: inline-flex; align-items: center; gap: 6px; color: var(--red); font-family: var(--type-mono); font-size: .66rem; text-decoration: none; }
.card-link:hover { text-decoration: underline; }
.card-category { position: absolute; right: 15px; bottom: -10px; padding: 4px 7px 3px; border: 1px solid currentColor; background: var(--paper-light); font-size: .55rem; transform: rotate(-2deg); }
.evidence-card[data-cat="clue"] .card-category { color: var(--red); }
.evidence-card[data-cat="market"] .card-category { color: var(--blue); }
.evidence-card[data-cat="user"] .card-category { color: #79571e; }

.zoom-controls { position: absolute; right: 20px; bottom: 18px; z-index: 50; display: grid; grid-template-columns: 40px 58px 40px auto; height: 40px; background: rgba(19,17,14,.91); border: 1px solid rgba(239,229,205,.24); box-shadow: 0 8px 18px rgba(0,0,0,.35); }
.zoom-controls button, .zoom-controls output { display: grid; place-items: center; min-width: 40px; border: 0; border-right: 1px solid rgba(239,229,205,.16); background: transparent; color: var(--paper); font-family: var(--type-mono); font-size: .72rem; }
.zoom-controls button { cursor: pointer; font-size: 1rem; }
.zoom-controls button:hover { background: var(--paper); color: var(--ink); }
.zoom-controls .reset-control { padding: 0 13px; border-right: 0; font-size: .63rem; text-transform: uppercase; letter-spacing: .08em; }

.timeline-bar { position: relative; z-index: 100; display: flex; align-items: center; min-width: 0; padding: 0 24px; background: #041317; border-top: 1px solid rgba(224,182,75,.17); }
.timeline-caption { flex: 0 0 auto; padding-right: 18px; color: #766f63; font-size: .58rem; }
.timeline-track { display: flex; align-items: center; gap: 2px; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.timeline-track::-webkit-scrollbar { display: none; }
.timeline-item { position: relative; flex: 0 0 auto; min-height: 34px; padding: 9px 14px 7px; border: 0; background: transparent; color: #8d8679; font-family: var(--type-mono); font-size: .65rem; cursor: pointer; }
.timeline-item::before { content: ""; position: absolute; top: 50%; left: 0; width: 4px; height: 4px; border-radius: 50%; background: currentColor; transform: translateY(-50%); }
.timeline-item:hover, .timeline-item.active { color: var(--paper-light); }
.timeline-item.active { background: rgba(183,123,22,.2); }

.sidebar-scrim { position: fixed; inset: 0; z-index: 180; display: block; visibility: hidden; opacity: 0; border: 0; background: rgba(8,7,6,.68); cursor: default; transition: opacity 220ms ease, visibility 220ms ease; }
.sidebar-scrim.open { visibility: visible; opacity: 1; }
.sidebar { position: fixed; top: 0; right: 0; z-index: 200; display: flex; flex-direction: column; width: min(440px, 94vw); height: 100dvh; color: var(--ink); background: var(--paper); border-left: 1px solid #a38e6b; box-shadow: -20px 0 45px rgba(0,0,0,.45); transform: translateX(102%); transition: transform 260ms cubic-bezier(.2,.8,.2,1); }
.sidebar.open { transform: translateX(0); }
.sidebar-header { display: flex; justify-content: space-between; align-items: center; padding: 24px 25px 18px; border-bottom: 1px solid rgba(23,21,18,.2); background: #dfd0b3; }
.sidebar-header h2 { margin: 0; font-family: var(--type-display); font-size: 1.7rem; }
.close-btn, .dialog-close { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid rgba(23,21,18,.35); background: transparent; color: var(--ink); font-size: 1.7rem; cursor: pointer; }
.sidebar-content { flex: 1; min-height: 0; overflow-y: auto; padding: 21px 25px 32px; }
.search-label { display: block; margin-bottom: 7px; font-size: .6rem; color: #655a49; }
#searchInput { width: 100%; height: 46px; padding: 0 13px; border: 1px solid #776b59; border-radius: 0; background: var(--paper-light); color: var(--ink); font-family: var(--type-mono); font-size: .75rem; }
.legend { display: flex; flex-wrap: wrap; gap: 7px; padding: 14px 0 18px; border-bottom: 1px solid rgba(23,21,18,.18); }
.legend-item { padding: 4px 7px; border: 1px solid currentColor; font-family: var(--type-mono); font-size: .55rem; text-transform: uppercase; letter-spacing: .06em; }
.legend-item.clue { color: var(--red); }.legend-item.market { color: var(--blue); }.legend-item.user { color: #79571e; }
.sidebar-list { display: grid; }
.sidebar-item { display: grid; grid-template-columns: 52px 1fr; gap: 12px; padding: 15px 2px; border: 0; border-bottom: 1px solid rgba(23,21,18,.14); background: transparent; color: var(--ink); text-align: left; cursor: pointer; }
.sidebar-item:hover { background: rgba(141,33,31,.055); }
.sidebar-item-number { font-family: var(--type-mono); font-size: .62rem; color: var(--red); }
.sidebar-item-title { font-family: var(--type-display); font-size: 1.02rem; line-height: 1.2; }
.sidebar-item-date { margin-top: 5px; font-family: var(--type-mono); font-size: .58rem; color: #746957; }
.empty-search { padding: 26px 0; font-style: italic; color: #6c6252; }

.evidence-dialog { width: min(680px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; overflow: visible; border: 0; background: transparent; color: var(--ink); }
.evidence-dialog::backdrop { background: rgba(10,8,6,.82); backdrop-filter: blur(2px); }
.evidence-sheet { position: relative; max-height: calc(100dvh - 32px); overflow-y: auto; padding: clamp(28px, 5vw, 52px); background:
    linear-gradient(90deg, transparent 0 45px, rgba(141,33,31,.12) 45px 46px, transparent 46px),
    repeating-linear-gradient(0deg, transparent 0 29px, rgba(23,21,18,.055) 29px 30px), var(--paper-light);
    box-shadow: 12px 20px 60px rgba(0,0,0,.5); transform: rotate(-.25deg); }
.evidence-sheet::before { content: "GOTCHU"; position: absolute; right: 38px; top: 95px; padding: 8px 10px 6px; border: 3px double rgba(141,33,31,.35); color: rgba(141,33,31,.35); font-family: var(--type-mono); font-size: 1rem; letter-spacing: .12em; transform: rotate(7deg); }
.dialog-close { position: absolute; top: 16px; right: 16px; z-index: 2; background: rgba(248,241,223,.88); }
.sheet-register { display: flex; justify-content: space-between; gap: 20px; padding-right: 54px; color: #746957; font-size: .62rem; }
#dialogCategory[data-cat="clue"] { color: var(--red); }
#dialogCategory[data-cat="market"] { color: var(--blue); }
#dialogCategory[data-cat="user"] { color: #79571e; }
.sheet-date { display: block; margin: 34px 0 8px; font-family: var(--type-mono); font-size: .72rem; color: var(--red); }
.evidence-sheet h2 { position: relative; z-index: 1; max-width: 560px; margin: 0 0 25px; font-family: var(--type-display); font-size: clamp(1.8rem, 5vw, 2.8rem); line-height: 1.06; }
.sheet-content { margin: 0; font-size: 1.28rem; line-height: 1.55; color: #383228; }
#dialogImage img { display: block; max-width: 100%; margin: 0 0 24px; padding: 8px; background: #fff; box-shadow: 2px 4px 10px rgba(0,0,0,.25); }
.sheet-footer { display: flex; justify-content: space-between; align-items: flex-end; gap: 22px; margin-top: 38px; padding-top: 15px; border-top: 1px solid rgba(23,21,18,.24); }
.source-link { display: inline-flex; align-items: center; gap: 10px; color: var(--red); font-family: var(--type-mono); font-size: .7rem; font-weight: 700; text-decoration: none; text-transform: uppercase; letter-spacing: .06em; }
.source-link:hover { text-decoration: underline; }
.verification-note { max-width: 220px; color: #746957; font-family: var(--type-mono); font-size: .58rem; text-align: right; }

@media (max-width: 860px) {
    :root { --header-h: 70px; --timeline-h: 48px; }
    body { width: 100%; height: auto; min-height: 100dvh; overflow-x: hidden; overflow-y: auto; display: block; background: var(--desk-deep); }
    .case-header { position: sticky; top: 0; grid-template-columns: 1fr auto; height: var(--header-h); padding: 0 14px; }
    .brand-lockup { display: inline-block; font-size: .62rem; }
    .case-identity { display: none; }
    .header-actions { gap: 2px; }
    .text-button { padding: 8px 6px; font-size: .62rem; }
    .file-button { width: 44px; padding: 0; justify-content: center; border-left-width: 2px; }
    .file-button span:last-child { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

    .case-brief { display: block; padding: 22px 18px 17px; background: radial-gradient(circle at 90% 10%, rgba(183,123,22,.1), transparent 38%), repeating-linear-gradient(0deg, transparent 0 25px, rgba(224,182,75,.035) 25px 26px), var(--desk); }
    .brief-copy { padding: 0; }
    .brief-copy h2 { max-width: 18ch; font-size: 1.55rem; }
    .brief-copy > p:last-child { font-size: 1rem; }
    .case-metadata { margin-top: 17px; }
    .case-metadata div { padding: 8px; }
    .case-metadata dd { font-size: .78rem; }
    .support-body { right: 0; width: 100%; }
    .site-end { grid-template-columns: 1fr; }
    .disclaimer { padding: 10px 18px 9px; font-size: .55rem; }
    .contact-button { right: max(14px, env(safe-area-inset-right)); bottom: calc(var(--timeline-h) + max(14px, env(safe-area-inset-bottom))); min-height: 46px; padding: 10px 13px 9px; }
    .workspace-label { height: 34px; padding: 0 18px; }
    .board-instruction { display: none; }

    .board-viewport { overflow: visible; min-height: 0; cursor: default; background: var(--cork-dark); }
    .board-viewport::after { box-shadow: inset 0 0 35px rgba(0,0,0,.35); }
    .board-container { position: relative; inset: auto; width: 100% !important; max-width: 100%; min-width: 0; min-height: 0; transform: none !important; background:
        radial-gradient(circle at 15% 30%, rgba(255,255,255,.045) 0 1px, transparent 2px),
        radial-gradient(circle at 72% 72%, rgba(0,0,0,.12) 0 1px, transparent 2px), var(--cork); background-size: 9px 11px, 13px 15px, auto; }
    .string-layer, .zoom-controls { display: none; }
    .cork-board { display: block; min-height: 0; padding: 12px 14px 76px; }
    .month-column { display: block; width: auto; padding: 0; }
    .month-column::before { left: 11px; top: 54px; bottom: 20px; border-color: rgba(239,229,205,.24); }
    .month-label { position: relative; top: auto; z-index: 1; margin: 0 -14px 17px; padding: 26px 18px 10px 38px; border-bottom-color: rgba(246,240,228,.22); background: linear-gradient(180deg, rgba(45,31,23,.96), rgba(69,46,32,.8)); font-size: 1.45rem; }
    .evidence-card, .evidence-card:nth-of-type(3n + 1), .evidence-card:nth-of-type(3n + 2), .evidence-card:nth-of-type(3n) { width: calc(100% - 28px); max-width: 520px; margin: 0 0 24px 28px; transform: rotate(-.35deg); align-self: auto; padding: 20px 18px 23px; }
    .evidence-card:nth-of-type(even) { transform: rotate(.35deg); }
    .evidence-card:hover { transform: translateY(-2px) rotate(0); }
    .card-title { font-size: 1.22rem; }
    .card-content { font-size: 1rem; -webkit-line-clamp: 3; }
    .timeline-bar { position: sticky; bottom: 0; z-index: 110; height: var(--timeline-h); padding: 0 10px; box-shadow: 0 -8px 22px rgba(0,0,0,.35); }
    .timeline-caption { display: none; }
    .timeline-item { padding-inline: 13px; }
    .sidebar { width: min(420px, 100vw); }
}

@media (max-width: 420px) {
    .case-status span { max-width: 105px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
    .case-metadata dd { font-size: .7rem; }
    .case-metadata dt { font-size: .48rem; }
    .evidence-dialog { width: 100vw; max-height: 100dvh; margin: 0; }
    .evidence-sheet { min-height: 100dvh; max-height: 100dvh; padding: 70px 22px 34px; transform: none; }
    .sheet-register { padding-right: 0; }
    .sheet-date { margin-top: 27px; }
    .evidence-sheet h2 { font-size: 2rem; }
    .sheet-content { font-size: 1.15rem; }
    .sheet-footer { display: grid; }
    .verification-note { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
