/* ============================================================
   senggack.org — The Thought Bureau
   pop-art under mood, centered spine, asymmetric collage bleed
   ============================================================ */

:root {
    --manila:        #e8d9b8;
    --bureau-cream:  #f5ebd2;
    --dusk-coral:    #ed5e4a;
    --marigold:      #f4a02d;
    --tobacco:       #5c3a24;
    --dossier-black: #1a1410;
    --twilight-wine: #7a2c3d;

    --tremble-x: 0px;
    --tremble-y: 0px;

    --column: 64ch;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
    background: var(--manila);
    color: var(--tobacco);
    font-family: "Cormorant Garamond", Georgia, serif;
    font-style: italic;
    font-weight: 400;
    font-size: clamp(1.05rem, 1.5vw, 1.25rem);
    line-height: 1.65;
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

/* paper grain over everything */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 1;
    background-image:
        radial-gradient(circle, rgba(92,58,36,0.05) 30%, transparent 31%),
        radial-gradient(circle, rgba(122,44,61,0.03) 28%, transparent 29%);
    background-size: 3px 3px, 5px 5px;
    background-position: 0 0, 1px 2px;
    mix-blend-mode: multiply;
}

/* ============================================================
   Halftone bands — full viewport horizontal strips
   ============================================================ */
.halftone-band {
    position: absolute;
    left: -10vw;
    right: -10vw;
    pointer-events: none;
    z-index: 0;
    transform: translate3d(var(--tremble-x), 0, 0);
}
.band-1 {
    top: 480px; height: 220px;
    background-image:
        radial-gradient(circle, var(--dusk-coral) 30%, transparent 31%),
        radial-gradient(circle, var(--dusk-coral) 30%, transparent 31%);
    background-size: 9px 9px, 9px 9px;
    background-position: 0 0, 3px 2px;
    opacity: 0.55;
    transform: translate3d(var(--tremble-x), 0, 0) rotate(-0.4deg);
}
.band-2 {
    top: 1300px; height: 240px;
    background-image:
        radial-gradient(circle, var(--marigold) 32%, transparent 33%),
        radial-gradient(circle, var(--marigold) 32%, transparent 33%);
    background-size: 11px 11px, 11px 11px;
    background-position: 0 0, 4px 3px;
    opacity: 0.45;
    transform: translate3d(calc(var(--tremble-x) * -1), 0, 0) rotate(0.3deg);
}
.band-3 {
    top: 2200px; height: 200px;
    background-image:
        radial-gradient(circle, var(--dusk-coral) 28%, transparent 29%),
        radial-gradient(circle, var(--marigold) 28%, transparent 29%);
    background-size: 8px 8px, 8px 8px;
    background-position: 0 0, 3px 2px;
    opacity: 0.5;
    transform: translate3d(var(--tremble-x), 0, 0) rotate(-0.5deg);
}
.band-4 {
    top: 3100px; height: 220px;
    background-image:
        radial-gradient(circle, var(--marigold) 30%, transparent 31%),
        radial-gradient(circle, var(--dusk-coral) 30%, transparent 31%);
    background-size: 10px 10px, 10px 10px;
    background-position: 0 0, 4px 2px;
    opacity: 0.42;
    transform: translate3d(calc(var(--tremble-x) * -1), 0, 0) rotate(0.4deg);
}

/* ============================================================
   Margin collage cutouts — only on wide screens
   ============================================================ */
.margin-cutout {
    position: absolute;
    z-index: 2;
    pointer-events: none;
    display: none;
}
@media (min-width: 1200px) {
    .margin-cutout { display: block; }
}
.ticket-stub {
    width: 180px;
    top: 380px;
    right: 40px;
    transform: rotate(8deg);
    filter: drop-shadow(2px 3px 0 rgba(92,58,36,0.4));
}
.polaroid {
    width: 130px;
    top: 1480px;
    left: 30px;
    transform: rotate(-6deg);
    filter: drop-shadow(2px 3px 0 rgba(92,58,36,0.4));
}
.polaroid-frame {
    background: var(--bureau-cream);
    padding: 8px 8px 22px;
    border: 1px solid rgba(92,58,36,0.3);
}
.polaroid-image {
    width: 100%;
    height: 110px;
    background-image:
        radial-gradient(circle, rgba(26,20,16,0.3) 30%, transparent 31%),
        linear-gradient(180deg, var(--marigold), var(--dusk-coral) 60%, var(--twilight-wine));
    background-size: 4px 4px, 100% 100%;
}
.polaroid-caption {
    text-align: center;
    font-family: "Caveat", cursive;
    font-style: normal;
    font-size: 0.95rem;
    color: var(--tobacco);
    margin-top: 6px;
    letter-spacing: 1px;
}
.korean-fragment {
    top: 2380px;
    right: 60px;
    width: auto;
    font-family: "Caveat", cursive;
    font-style: normal;
    font-weight: 700;
    font-size: 1.6rem;
    color: var(--twilight-wine);
    transform: rotate(-7deg);
    opacity: 0.85;
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
    position: relative;
    text-align: center;
    padding: clamp(3rem, 8vw, 7rem) 1.5rem clamp(2.5rem, 6vw, 5rem);
    z-index: 3;
    isolation: isolate;
}

.sunburst {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: clamp(420px, 75vw, 820px);
    height: clamp(420px, 75vw, 820px);
    z-index: -1;
    opacity: 0.18;
    pointer-events: none;
}
.sunburst-rays {
    transform-origin: 0 0;
    animation: sunburst-spin 240s linear infinite;
}
@keyframes sunburst-spin {
    to { transform: rotate(360deg); }
}

.stamp.confidential {
    display: inline-block;
    transform: rotate(-4deg);
    margin-bottom: 1.4rem;
    opacity: 0.85;
    width: clamp(180px, 26vw, 240px);
    filter: drop-shadow(1px 1px 0 rgba(122,44,61,0.3));
}
.stamp.confidential svg { width: 100%; height: auto; display: block; }

.hero-title {
    font-family: "Anton", "Arial Narrow", sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: clamp(3.5rem, 13vw, 8rem);
    line-height: 0.92;
    letter-spacing: -0.01em;
    color: var(--tobacco);
    text-transform: uppercase;
    margin: 0 auto;
    max-width: 14ch;
    position: relative;
}
.hero-title .hero-line-1,
.hero-title .hero-line-2 {
    display: block;
}
.hero-title .hero-line-2 {
    color: var(--dossier-black);
    position: relative;
}
.hero-title .hero-line-2::after {
    content: "";
    position: absolute;
    left: 12%;
    bottom: 12%;
    width: 76%;
    height: 14%;
    background: var(--dossier-black);
    mix-blend-mode: multiply;
    opacity: 0.35;
}

.hero-korean {
    font-family: "Nanum Myeongjo", "Cormorant Garamond", serif;
    font-style: italic;
    font-size: clamp(1.4rem, 2.6vw, 2rem);
    color: var(--twilight-wine);
    margin-top: 1.5rem;
    letter-spacing: 0.02em;
}
.hero-sub {
    font-family: "Cormorant Garamond", Georgia, serif;
    font-style: italic;
    font-size: clamp(1.05rem, 1.6vw, 1.3rem);
    color: var(--tobacco);
    margin-top: 1rem;
    max-width: 48ch;
    margin-inline: auto;
}
.hero-meta {
    font-family: "Big Shoulders Display", sans-serif;
    font-style: normal;
    font-weight: 800;
    font-size: clamp(0.8rem, 1.3vw, 1rem);
    letter-spacing: 0.18em;
    color: var(--tobacco);
    text-transform: uppercase;
    margin-top: 2.4rem;
    opacity: 0.78;
}

/* ============================================================
   DOSSIER — centered spine + sections
   ============================================================ */
.dossier {
    position: relative;
    z-index: 3;
    padding: 2rem 1.5rem 4rem;
    max-width: 100%;
}

.dossier-section {
    position: relative;
    margin: clamp(3rem, 7vw, 6rem) auto;
    max-width: var(--column);
    padding: 0 1rem;
}

/* Manila tab — alternating left/right */
.manila-tab {
    display: inline-block;
    background: var(--bureau-cream);
    color: var(--tobacco);
    font-family: "Big Shoulders Display", sans-serif;
    font-style: normal;
    font-weight: 800;
    font-size: clamp(0.85rem, 1.4vw, 1.05rem);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    padding: 0.55rem 1.4rem 0.45rem;
    box-shadow: 2px 2px 0 var(--tobacco);
    transform: rotate(-1.5deg);
    margin-bottom: 1.8rem;
    border: 1px solid rgba(92,58,36,0.25);
    position: relative;
    z-index: 2;
}
.manila-tab.tab-left { margin-left: 0; }
.manila-tab.tab-right {
    transform: rotate(1.5deg);
    float: right;
    margin-right: 0;
}
.dossier-section::after {
    content: "";
    display: block;
    clear: both;
}

/* ============================================================
   Folder cover — <details> styled as tilted folder
   ============================================================ */
.folder-cover {
    position: relative;
    background: var(--bureau-cream);
    border: 1.5px solid var(--tobacco);
    box-shadow: 6px 6px 0 var(--tobacco);
    padding: 0;
    transition: transform 600ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
    transform-origin: top left;
}
.folder-cover[open] {
    transform: translateX(-6px) rotate(-0.4deg);
    box-shadow: 4px 4px 0 var(--tobacco);
}

.folder-cover > summary {
    list-style: none;
    cursor: pointer;
    padding: 1.6rem 1.6rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-image:
        radial-gradient(circle, rgba(237,94,74,0.2) 24%, transparent 25%);
    background-size: 14px 14px;
    background-color: var(--bureau-cream);
    transition: background-color 300ms ease;
    user-select: none;
}
.folder-cover > summary::-webkit-details-marker { display: none; }
.folder-cover > summary::marker { display: none; }
.folder-cover > summary:hover {
    background-image:
        radial-gradient(circle, rgba(237,94,74,0.32) 24%, transparent 25%);
}

.redacted-stamp {
    font-family: "Big Shoulders Display", sans-serif;
    font-style: normal;
    font-weight: 800;
    font-size: clamp(1.4rem, 3.5vw, 2.4rem);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--twilight-wine);
    border: 3px solid var(--twilight-wine);
    padding: 0.35rem 1.1rem 0.25rem;
    transform: rotate(-3deg);
    background: rgba(245,235,210,0.6);
}
.lift-instruction {
    font-family: "Caveat", cursive;
    font-style: normal;
    font-weight: 700;
    color: var(--tobacco);
    font-size: 1.3rem;
    opacity: 0.7;
    transform: rotate(-2deg);
}

.dossier-body {
    padding: 0 2rem 2.4rem;
    background: var(--bureau-cream);
    border-top: 1px dashed rgba(92,58,36,0.4);
}

.dossier-body > p {
    margin: 1.2rem 0;
    text-align: left;
    color: var(--tobacco);
    max-width: var(--column);
    font-style: italic;
}

.korean-line {
    font-family: "Nanum Myeongjo", serif;
    font-style: italic;
    color: var(--twilight-wine);
    letter-spacing: 0.02em;
    margin: 1.6rem 0 !important;
    font-size: 1.1em;
    border-left: 2px solid var(--dusk-coral);
    padding-left: 1rem;
}

/* ============================================================
   Censor bar headlines
   ============================================================ */
.censor-h2 {
    font-family: "Anton", sans-serif;
    font-style: normal;
    font-weight: 400;
    font-size: clamp(2rem, 5vw, 3.4rem);
    line-height: 0.96;
    letter-spacing: -0.005em;
    color: var(--tobacco);
    text-transform: uppercase;
    margin: 1.6rem 0 1rem;
    position: relative;
    display: inline-block;
}

/* Censor bar via ::before — width derived from data-seed for stability */
.censor-h2::before {
    content: "";
    position: absolute;
    background: var(--dossier-black);
    mix-blend-mode: multiply;
    height: 0.62em;
    transition: width 800ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
                left 800ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
    top: 0.18em;
    pointer-events: none;
}

/* deterministic per-section censor positions */
[data-seed="1"] .censor-h2::before { width: 55%; left: 20%; }
[data-seed="1"] .censor-h2:hover::before { width: 22%; left: 38%; }

[data-seed="2"] .censor-h2::before { width: 70%; left: 8%; }
[data-seed="2"] .censor-h2:hover::before { width: 28%; left: 22%; }

[data-seed="3"] .censor-h2::before { width: 30%; left: 50%; }
[data-seed="3"] .censor-h2:hover::before { width: 12%; left: 58%; }

[data-seed="4"] .censor-h2::before { width: 60%; left: 14%; }
[data-seed="4"] .censor-h2:hover::before { width: 24%; left: 28%; }

/* ============================================================
   Envelope — nested <details>
   ============================================================ */
.envelope {
    margin: 1.8rem 0 1.4rem;
    background: var(--manila);
    border: 1px solid rgba(92,58,36,0.4);
    overflow: hidden;
    position: relative;
}
.envelope::before {
    content: "";
    position: absolute;
    top: 0; left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 14px;
    background: linear-gradient(180deg, rgba(92,58,36,0.18), transparent);
    pointer-events: none;
}
.envelope > summary {
    list-style: none;
    cursor: pointer;
    padding: 0.85rem 1.1rem;
    font-family: "Big Shoulders Display", sans-serif;
    font-style: normal;
    font-weight: 800;
    font-size: clamp(0.85rem, 1.3vw, 1rem);
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--tobacco);
    background-image:
        radial-gradient(circle, rgba(244,160,45,0.18) 28%, transparent 29%);
    background-size: 8px 8px;
    background-color: var(--manila);
    transition: background-color 240ms ease;
    user-select: none;
}
.envelope > summary::-webkit-details-marker,
.envelope > summary::marker { display: none; }
.envelope > summary::before {
    content: "▸ ";
    color: var(--dusk-coral);
    margin-right: 0.4rem;
    transition: transform 300ms ease;
    display: inline-block;
}
.envelope[open] > summary::before {
    content: "▾ ";
}
.envelope > summary:hover {
    background-image:
        radial-gradient(circle, rgba(244,160,45,0.32) 28%, transparent 29%);
}

.envelope-body {
    padding: 1rem 1.3rem 1.4rem;
    background: var(--bureau-cream);
    border-top: 1px dashed rgba(92,58,36,0.3);
    animation: envelope-slide 460ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
    transform-origin: top center;
}
@keyframes envelope-slide {
    from { opacity: 0; transform: translateY(-6px) scaleY(0.96); }
    to   { opacity: 1; transform: translateY(0)    scaleY(1); }
}
.envelope-body p {
    margin: 0.7rem 0;
    color: var(--tobacco);
    font-style: italic;
}

/* ============================================================
   Filed link
   ============================================================ */
.filed-link {
    display: block;
    margin: 2.2rem auto 0;
    text-align: center;
    font-family: "Big Shoulders Display", sans-serif;
    font-style: normal;
    font-weight: 800;
    font-size: 1.05rem;
    letter-spacing: 0.32em;
    color: var(--twilight-wine);
    text-decoration: none;
    border-top: 1px solid rgba(122,44,61,0.4);
    border-bottom: 1px solid rgba(122,44,61,0.4);
    padding: 0.7rem 0;
    width: fit-content;
    transition: color 260ms ease, letter-spacing 260ms ease;
}
.filed-link:hover {
    color: var(--dusk-coral);
    letter-spacing: 0.42em;
}

/* ============================================================
   Floral plate
   ============================================================ */
.floral-plate {
    margin: clamp(2.5rem, 5vw, 4rem) auto 0;
    text-align: center;
    border: 1px solid var(--tobacco);
    padding: 1.4rem 1rem 1.2rem;
    max-width: 360px;
    background: var(--bureau-cream);
    box-shadow: 3px 3px 0 var(--tobacco);
    position: relative;
}
.floral-plate::before {
    content: "";
    position: absolute;
    inset: 6px;
    border: 1px solid rgba(92,58,36,0.5);
    pointer-events: none;
}

.botanical {
    width: 200px;
    height: 280px;
    display: block;
    margin: 0 auto;
}
.floral-plate figcaption {
    font-family: "Cormorant Garamond", Georgia, serif;
    font-style: italic;
    font-size: 1rem;
    color: var(--tobacco);
    margin-top: 0.7rem;
    letter-spacing: 0.02em;
}

/* small marigold motif at bottom-right of every section */
.dossier-section::before {
    content: "✻";
    position: absolute;
    bottom: -10px;
    right: -8px;
    font-size: 1.6rem;
    color: var(--marigold);
    transform: rotate(18deg);
    opacity: 0.85;
    font-style: normal;
    text-shadow: 1px 1px 0 var(--twilight-wine);
}

/* ============================================================
   FOOTER — page end stamp
   ============================================================ */
.page-end {
    position: relative;
    z-index: 3;
    text-align: center;
    padding: clamp(3rem, 6vw, 5rem) 1rem clamp(2rem, 5vw, 4rem);
    margin-top: 3rem;
    background-image:
        radial-gradient(circle, rgba(237,94,74,0.12) 28%, transparent 29%);
    background-size: 10px 10px;
    background-color: var(--manila);
}
.torn-rule {
    width: min(720px, 90%);
    height: 16px;
    margin: 0.6rem auto;
    display: block;
}
.end-stamp {
    display: inline-block;
    transform: rotate(-2deg);
    margin: 1.2rem auto;
    filter: drop-shadow(1px 1px 0 rgba(122,44,61,0.3));
    opacity: 0.92;
}
.end-stamp svg { width: clamp(260px, 50vw, 360px); height: auto; display: block; }

/* ============================================================
   Responsive trims
   ============================================================ */
@media (max-width: 720px) {
    :root { --column: 90%; }
    .folder-cover > summary {
        flex-direction: column;
        gap: 0.6rem;
        align-items: flex-start;
    }
    .lift-instruction { align-self: flex-end; }
    .dossier-body { padding: 0 1.1rem 1.8rem; }
    .manila-tab.tab-right { float: none; }
}
