/* archaic.studio — Field Station for Vanishing Forms
   Stratigraphic descent through warm earth tones.
   Palette and motifs follow DESIGN.md exactly. */

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

:root {
    /* Palette — exact hex values from DESIGN.md */
    --oxide:        #9b4a2c;  /* Iron Oxide Red */
    --ochre:        #c8a45c;  /* Field Ochre */
    --bone:         #d4c9b5;  /* Bone */
    --earth-dark:   #3b2f2f;  /* Excavation Dark */
    --carbon:       #1c1410;  /* Carbon Ink */
    --clay:         #6b4c3b;  /* Sediment 2 — Clay Layer */
    --vellum:       #f4efe4;  /* Vellum */
    --sandy:        #a0785a;  /* Sediment 1 — Sandy Layer */

    /* Type scale */
    --display: "Playfair Display SC", "Playfair Display", Georgia, serif;
    --body:    "Source Serif 4", "Source Serif Pro", Georgia, serif;
    --mono:    "Courier Prime", "Courier New", monospace;
    --hand:    "Caveat", "Bradley Hand", cursive;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--body);
    color: var(--carbon);
    background: var(--vellum);
    line-height: 1.75;
    font-size: 1.05rem;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    overflow-x: hidden;
    position: relative;
}

::selection {
    background: var(--ochre);
    color: var(--carbon);
}

/* =============================================================
   PERSISTENT GRID OVERLAY
   The archaeologist's measurement string — floats above content,
   parallaxed independently on scroll.
   ============================================================= */
.grid-overlay {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 5;
    background-image:
        repeating-linear-gradient(
            to right,
            transparent 0,
            transparent 59px,
            rgba(212, 201, 181, 0.32) 59px,
            rgba(212, 201, 181, 0.32) 60px
        ),
        repeating-linear-gradient(
            to bottom,
            transparent 0,
            transparent 59px,
            rgba(212, 201, 181, 0.32) 59px,
            rgba(212, 201, 181, 0.32) 60px
        );
    will-change: transform;
    mix-blend-mode: multiply;
}

/* =============================================================
   SITE MARKER — fixed catalogue header strip
   ============================================================= */
.site-marker {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 20;
    padding: 14px 28px;
    background: linear-gradient(
        to bottom,
        rgba(244, 239, 228, 0.96),
        rgba(244, 239, 228, 0.78) 70%,
        rgba(244, 239, 228, 0)
    );
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}

.marker-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-family: var(--mono);
    font-size: 0.78rem;
    letter-spacing: 0.18em;
    color: var(--carbon);
    text-transform: uppercase;
}

.marker-label {
    font-weight: 700;
}

.marker-coord {
    color: var(--clay);
}

/* =============================================================
   THE DIG SITE — HERO
   Top-down view of an excavation grid.
   ============================================================= */
.dig-site {
    position: relative;
    min-height: 100vh;
    padding: 88px 4vw 80px;
    background:
        radial-gradient(ellipse at 20% 18%, rgba(244, 239, 228, 0.55), transparent 55%),
        radial-gradient(ellipse at 78% 82%, rgba(107, 76, 59, 0.35), transparent 60%),
        linear-gradient(140deg, #d8c4a8 0%, #b89572 38%, #8a6a4d 70%, #5a4030 100%);
    overflow: hidden;
    isolation: isolate;
}

/* Subtle vignette / lamp effect */
.dig-site::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(
        ellipse at 50% 45%,
        rgba(244, 239, 228, 0.25) 0%,
        transparent 55%
    );
    pointer-events: none;
    z-index: 1;
}

/* Hand-drawn paper grain */
.dig-site::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        repeating-linear-gradient(
            45deg,
            rgba(28, 20, 16, 0.025) 0,
            rgba(28, 20, 16, 0.025) 1px,
            transparent 1px,
            transparent 4px
        ),
        repeating-linear-gradient(
            -45deg,
            rgba(28, 20, 16, 0.02) 0,
            rgba(28, 20, 16, 0.02) 1px,
            transparent 1px,
            transparent 6px
        );
    pointer-events: none;
    z-index: 2;
    mix-blend-mode: multiply;
}

.dig-grid {
    position: relative;
    z-index: 3;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-template-rows: repeat(6, 1fr);
    width: min(78vmin, 760px);
    height: min(78vmin, 760px);
    margin: 60px auto 30px;
    border: 1.5px solid rgba(244, 239, 228, 0.65);
    background:
        repeating-linear-gradient(
            to right,
            transparent 0,
            transparent calc(16.6666% - 0.5px),
            rgba(244, 239, 228, 0.55) calc(16.6666% - 0.5px),
            rgba(244, 239, 228, 0.55) 16.6666%
        ),
        repeating-linear-gradient(
            to bottom,
            transparent 0,
            transparent calc(16.6666% - 0.5px),
            rgba(244, 239, 228, 0.55) calc(16.6666% - 0.5px),
            rgba(244, 239, 228, 0.55) 16.6666%
        );
    transform: perspective(900px) rotateX(2deg);
    transform-style: preserve-3d;
    transition: transform 240ms cubic-bezier(0.2, 0.8, 0.2, 1);
    will-change: transform;
    box-shadow:
        0 30px 80px rgba(28, 20, 16, 0.35),
        inset 0 0 60px rgba(28, 20, 16, 0.2);
}

.cell {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cell-mark {
    font-family: var(--mono);
    font-size: 1.1rem;
    color: rgba(244, 239, 228, 0.55);
    letter-spacing: 0;
}

.cell[data-cell="A1"]::before,
.cell[data-cell="F6"]::after {
    content: "";
    position: absolute;
    width: 8px;
    height: 8px;
    border: 1.2px solid rgba(244, 239, 228, 0.75);
}
.cell[data-cell="A1"]::before { top: -4px; left: -4px; }
.cell[data-cell="F6"]::after { bottom: -4px; right: -4px; }

/* Cell coordinate labels — only on first row & first column */
.cell[data-cell^="A"]::after {
    content: attr(data-cell);
    position: absolute;
    top: -22px;
    left: 50%;
    transform: translateX(-50%);
    font-family: var(--mono);
    font-size: 0.62rem;
    color: rgba(244, 239, 228, 0.7);
    letter-spacing: 0.1em;
}
.cell[data-cell="A1"]::after { content: "A"; }
.cell[data-cell="A2"]::after { content: "B"; }
.cell[data-cell="A3"]::after { content: "C"; }
.cell[data-cell="A4"]::after { content: "D"; }
.cell[data-cell="A5"]::after { content: "E"; }
.cell[data-cell="A6"]::after { content: "F"; }

/* Studio name lives in lower-left cell (F1) */
.name-cell {
    align-items: flex-start;
    justify-content: flex-start;
    padding: 10px 12px;
    text-align: left;
    flex-direction: column;
}

.studio-name {
    font-family: var(--display);
    font-size: clamp(1.05rem, 2.4vw, 1.6rem);
    font-weight: 700;
    color: var(--vellum);
    line-height: 1.05;
    letter-spacing: 0.02em;
    text-shadow: 0 1px 2px rgba(28, 20, 16, 0.4);
}

.studio-meta {
    font-family: var(--mono);
    font-size: 0.62rem;
    margin-top: 6px;
    color: rgba(244, 239, 228, 0.78);
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

/* Hero corner annotations */
.hero-anno {
    position: absolute;
    z-index: 4;
    font-family: var(--mono);
    font-size: 0.72rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: rgba(28, 20, 16, 0.7);
}
.hero-anno-tl { top: 60px; left: 28px; }
.hero-anno-tr { top: 60px; right: 28px; }
.hero-anno-br { bottom: 84px; right: 28px; }

.hand-note {
    font-family: var(--hand);
    font-size: 1.1rem;
    color: var(--oxide);
    line-height: 1.2;
    pointer-events: none;
}

.hand-hero {
    position: absolute;
    top: 18%;
    right: 6vw;
    transform: rotate(-4deg);
    max-width: 200px;
    z-index: 4;
    color: var(--carbon);
    opacity: 0.85;
}

.descend {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 4;
    text-align: center;
    color: var(--vellum);
}

.descend-text {
    display: block;
    font-family: var(--mono);
    font-size: 0.74rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    opacity: 0.85;
}

.descend-arrow {
    display: block;
    margin-top: 6px;
    font-size: 1.3rem;
    animation: descendBob 2.4s ease-in-out infinite;
}

@keyframes descendBob {
    0%, 100% { transform: translateY(0); opacity: 0.6; }
    50%      { transform: translateY(8px); opacity: 1; }
}

/* =============================================================
   STRATIGRAPHIC BANDS
   Layered earth between sections, uneven gradient stops.
   ============================================================= */
.strata {
    position: relative;
    width: 100%;
    height: 56px;
    overflow: hidden;
    z-index: 4;
}

.strata-label {
    position: absolute;
    top: 50%;
    right: 4vw;
    transform: translateY(-50%);
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--vellum);
    background: rgba(28, 20, 16, 0.55);
    padding: 4px 12px;
    border: 1px solid rgba(244, 239, 228, 0.25);
}

.strata-1 {
    background: linear-gradient(
        to bottom,
        #c8a45c 0%,
        #c8a45c 22%,
        #a0785a 22%,
        #a0785a 58%,
        #8a6a4d 58%,
        #8a6a4d 100%
    );
}
.strata-2 {
    background: linear-gradient(
        to bottom,
        #a0785a 0%,
        #a0785a 35%,
        #6b4c3b 35%,
        #6b4c3b 62%,
        #5a4030 62%,
        #5a4030 100%
    );
}
.strata-3 {
    background: linear-gradient(
        to bottom,
        #6b4c3b 0%,
        #6b4c3b 28%,
        #4f3a2e 28%,
        #4f3a2e 60%,
        #3b2f2f 60%,
        #3b2f2f 100%
    );
}
.strata-4 {
    background: linear-gradient(
        to bottom,
        #3b2f2f 0%,
        #3b2f2f 30%,
        #2a201d 30%,
        #2a201d 64%,
        #1c1410 64%,
        #1c1410 100%
    );
}

/* Hairline cracks rendered with a second gradient */
.strata::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: repeating-linear-gradient(
        88deg,
        transparent 0,
        transparent 24px,
        rgba(28, 20, 16, 0.18) 24px,
        rgba(28, 20, 16, 0.18) 25px,
        transparent 25px,
        transparent 80px
    );
    mix-blend-mode: multiply;
}

/* =============================================================
   LAYERS — main stratigraphic descent
   Background darkens with depth.
   ============================================================= */
.layer {
    position: relative;
    padding: 120px 4vw 140px;
    z-index: 3;
}

/* Layer-by-layer color descent (vellum -> sandy -> clay -> earth-dark) */
.layer-01 { background: var(--vellum); color: var(--carbon); }
.layer-02 {
    background: linear-gradient(180deg, #ede1c8 0%, #d8be94 100%);
    color: var(--carbon);
}
.layer-03 {
    background: linear-gradient(180deg, #b89172 0%, #8c6649 100%);
    color: var(--vellum);
}
.layer-04 {
    background: linear-gradient(180deg, #2a201d 0%, var(--carbon) 100%);
    color: var(--vellum);
}

.layer-inner {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
}
.layer-inner.wide { max-width: 1180px; }

/* Catalogue rail: section number + label, small caps mono */
.catalogue-rail {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 36px;
    font-family: var(--mono);
    font-size: 0.76rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--clay);
}

.catalogue-rail-light { color: rgba(244, 239, 228, 0.78); }

.rail-num {
    font-weight: 700;
    color: var(--oxide);
}
.catalogue-rail-light .rail-num { color: var(--ochre); }

.rail-divider {
    flex: 0 0 60px;
    height: 1px;
    background: currentColor;
    opacity: 0.4;
}

.rail-text { flex: 1; }

/* "Excavated" content block — irregular clip-path edges */
.excavated {
    position: relative;
    padding: 40px 44px 48px;
    background: var(--vellum);
    color: var(--carbon);
    box-shadow:
        0 14px 32px rgba(28, 20, 16, 0.18),
        0 2px 4px rgba(28, 20, 16, 0.08);
    clip-path: polygon(
        0% 2%, 4% 0%, 22% 1%, 48% 0%, 76% 2%, 96% 0%, 100% 3%,
        100% 50%, 99% 80%, 100% 100%,
        82% 99%, 50% 100%, 24% 99%, 6% 100%, 0% 98%
    );
}

.excavated-dark {
    background: rgba(244, 239, 228, 0.05);
    color: var(--vellum);
    border: 1px solid rgba(244, 239, 228, 0.18);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.55);
    clip-path: none;
}

/* Specimen tag — rotated catalogue label, upper-right corner */
.specimen-tag {
    position: absolute;
    top: -14px;
    right: 18px;
    transform: rotate(-3deg);
    background: var(--vellum);
    border: 1px solid var(--bone);
    padding: 5px 12px 6px;
    box-shadow:
        0 3px 8px rgba(28, 20, 16, 0.22),
        0 1px 2px rgba(28, 20, 16, 0.12);
    font-family: var(--mono);
    line-height: 1.1;
    z-index: 4;
}

/* String tying tag to artefact */
.specimen-tag::before {
    content: "";
    position: absolute;
    bottom: -12px;
    left: 12px;
    width: 1px;
    height: 14px;
    background: var(--clay);
    transform: rotate(8deg);
    transform-origin: top center;
}

/* Hole-punch dot */
.specimen-tag::after {
    content: "";
    position: absolute;
    top: 4px;
    left: 4px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--clay);
    opacity: 0.65;
}

.specimen-tag-dark {
    background: var(--earth-dark);
    color: var(--vellum);
    border: 1px solid var(--ochre);
}

.tag-line {
    display: block;
    font-size: 0.55rem;
    letter-spacing: 0.18em;
    color: var(--clay);
    text-transform: uppercase;
}
.specimen-tag-dark .tag-line { color: var(--ochre); }

.tag-num {
    display: block;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--carbon);
    letter-spacing: 0.05em;
}
.specimen-tag-dark .tag-num { color: var(--vellum); }

.tag-sm {
    top: -10px;
    right: 10px;
    padding: 4px 9px 5px;
    transform: rotate(-4deg);
}
.tag-sm .tag-line { font-size: 0.5rem; }
.tag-sm .tag-num { font-size: 0.7rem; }

/* Layer typography */
.layer-title {
    font-family: var(--display);
    font-size: clamp(1.8rem, 4vw, 3.5rem);
    font-weight: 700;
    color: var(--carbon);
    line-height: 1.12;
    letter-spacing: 0.01em;
    margin-bottom: 22px;
    max-width: 18ch;
}
.layer-title-light { color: var(--vellum); }

.layer-lede {
    font-family: var(--body);
    font-size: 1.18rem;
    line-height: 1.65;
    color: var(--clay);
    margin-bottom: 28px;
    font-style: italic;
    max-width: 56ch;
}
.layer-lede-light { color: rgba(244, 239, 228, 0.85); }

.excavated p {
    margin-bottom: 18px;
    max-width: 60ch;
}

.excavated em {
    font-style: italic;
    color: var(--oxide);
}

.excavated-dark em {
    color: var(--ochre);
}

/* Meta-list (provenance metadata) */
.meta-list {
    margin-top: 36px;
    padding-top: 20px;
    border-top: 1px solid var(--bone);
    display: grid;
    grid-template-columns: max-content 1fr;
    gap: 8px 32px;
    font-family: var(--mono);
    font-size: 0.82rem;
}
.meta-list dt {
    color: var(--clay);
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-size: 0.72rem;
}
.meta-list dd {
    color: var(--carbon);
}

/* Practice list — numbered field method */
.practice-list {
    list-style: none;
    counter-reset: practice;
    margin-top: 16px;
}

.practice-list li {
    display: grid;
    grid-template-columns: 50px 1fr;
    gap: 16px;
    padding: 22px 0;
    border-top: 1px solid var(--bone);
    align-items: start;
}

.practice-list li:last-child {
    border-bottom: 1px solid var(--bone);
}

.practice-num {
    font-family: var(--mono);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--oxide);
    letter-spacing: 0.05em;
    padding-top: 4px;
}

.practice-h {
    font-family: var(--display);
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--carbon);
    margin-bottom: 6px;
    letter-spacing: 0.02em;
}

.practice-list p {
    margin: 0;
    color: var(--clay);
    font-size: 1rem;
}

/* =============================================================
   SPECIMEN DRAWER — portfolio
   Equal-cell grid; 1px gap is the divider via background bleed.
   ============================================================= */
.drawer-head {
    margin-bottom: 36px;
    color: var(--vellum);
}

.drawer-head .layer-title { color: var(--vellum); }
.drawer-head .layer-lede { color: rgba(244, 239, 228, 0.85); }

.drawer {
    position: relative;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1px;
    background: var(--bone);
    border: 1px solid var(--bone);
    box-shadow:
        0 24px 60px rgba(28, 20, 16, 0.45),
        inset 0 0 0 4px rgba(28, 20, 16, 0.12);
}

.specimen {
    position: relative;
    background: var(--vellum);
    padding: 28px 22px 22px;
    color: var(--carbon);
    transition:
        box-shadow 600ms ease-out,
        transform 600ms ease-out,
        background-color 600ms ease-out;
    will-change: transform, box-shadow;
    cursor: default;
    z-index: 1;
    min-height: 280px;
    display: flex;
    flex-direction: column;
}

.specimen:hover {
    background: #faf6ec;
    transform: scale(1.02);
    box-shadow: 0 8px 32px rgba(28, 20, 16, 0.3);
    z-index: 6;
}

/* Lightbox dim — pseudo on drawer when any specimen hovered */
.drawer:has(.specimen:hover)::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(28, 20, 16, 0.4);
    pointer-events: none;
    z-index: 5;
    transition: opacity 400ms ease-out;
}

.specimen-figure {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    background:
        radial-gradient(ellipse at center, rgba(244, 239, 228, 0.6) 0%, transparent 70%);
    padding: 12px;
}

.specimen-figure svg {
    width: 100%;
    max-width: 130px;
    height: auto;
    display: block;
    filter: drop-shadow(0 2px 4px rgba(28, 20, 16, 0.25));
}

.specimen-meta h3 {
    font-family: var(--display);
    font-size: 1rem;
    font-weight: 700;
    color: var(--carbon);
    margin-bottom: 4px;
    letter-spacing: 0.03em;
}

.spec-line {
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.08em;
    color: var(--clay);
    text-transform: uppercase;
    line-height: 1.5;
    margin: 0;
}

/* =============================================================
   STRATA / DEEP TIME COLUMN
   ============================================================= */
.column-diagram {
    margin: 32px 0 28px;
    border-top: 1px solid rgba(244, 239, 228, 0.2);
    border-bottom: 1px solid rgba(244, 239, 228, 0.2);
}

.col-row {
    display: grid;
    grid-template-columns: 100px 200px 1fr;
    gap: 16px;
    padding: 14px 0 14px 16px;
    align-items: baseline;
    border-bottom: 1px dashed rgba(244, 239, 228, 0.15);
    position: relative;
}

.col-row:last-child { border-bottom: none; }

.col-row::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 6px;
}

.col-row-1::before { background: #c8a45c; }
.col-row-2::before { background: #a0785a; }
.col-row-3::before { background: #6b4c3b; }
.col-row-4::before { background: #3b2f2f; }
.col-row-5::before { background: #1c1410; border-left: 1px solid rgba(244, 239, 228, 0.3); }

.col-depth {
    font-family: var(--mono);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--ochre);
    letter-spacing: 0.05em;
}

.col-name {
    font-family: var(--display);
    font-size: 1.05rem;
    color: var(--vellum);
}

.col-note {
    font-family: var(--body);
    font-size: 0.95rem;
    color: rgba(244, 239, 228, 0.7);
    font-style: italic;
}

.layer-coda {
    margin-top: 28px;
    color: rgba(244, 239, 228, 0.85);
    font-style: italic;
    max-width: 60ch;
}

/* =============================================================
   MARGIN ANNOTATIONS
   Caveat handwriting; absolute positioned right of column.
   ============================================================= */
.hand-note {
    font-family: var(--hand);
    font-size: 1.12rem;
    color: var(--oxide);
    line-height: 1.25;
    opacity: 0;
    transform: translateX(20px);
    transition: opacity 800ms ease-out, transform 800ms ease-out;
    pointer-events: none;
}

.hand-note.in-view {
    opacity: 0.95;
    transform: translateX(0);
}

.hand-about,
.hand-method,
.hand-spec,
.hand-strata {
    position: absolute;
    max-width: 220px;
}

/* Visible only on wider viewports per DESIGN.md spec */
.hand-pos-1, .hand-pos-2 {
    display: none;
}

@media (min-width: 1200px) {
    .hand-pos-1, .hand-pos-2 { display: block; }

    .hand-about.hand-pos-1 { right: -200px; top: 80px; transform: translateX(20px) rotate(-3deg); }
    .hand-about.hand-pos-2 { right: -200px; top: 280px; transform: translateX(20px) rotate(2deg); color: var(--clay); }
    .hand-about.hand-pos-1.in-view { transform: translateX(0) rotate(-3deg); }
    .hand-about.hand-pos-2.in-view { transform: translateX(0) rotate(2deg); }

    .hand-method.hand-pos-1 { right: -200px; top: 120px; transform: translateX(20px) rotate(-4deg); }
    .hand-method.hand-pos-2 { right: -200px; top: 340px; transform: translateX(20px) rotate(3deg); color: var(--clay); }
    .hand-method.hand-pos-1.in-view { transform: translateX(0) rotate(-4deg); }
    .hand-method.hand-pos-2.in-view { transform: translateX(0) rotate(3deg); }

    .hand-spec.hand-pos-1 { right: 0; top: 80px; transform: translateX(20px) rotate(-2deg); color: var(--vellum); }
    .hand-spec.hand-pos-2 { right: 0; bottom: 40px; transform: translateX(20px) rotate(3deg); color: var(--ochre); }
    .hand-spec.hand-pos-1.in-view { transform: translateX(0) rotate(-2deg); }
    .hand-spec.hand-pos-2.in-view { transform: translateX(0) rotate(3deg); }

    .hand-strata.hand-pos-1 { right: -180px; top: 200px; transform: translateX(20px) rotate(-3deg); color: var(--ochre); }
    .hand-strata.hand-pos-1.in-view { transform: translateX(0) rotate(-3deg); }
}

/* =============================================================
   FIELD NOTES — FOOTER / NOTEBOOK
   ============================================================= */
.field-notes {
    position: relative;
    padding: 100px 4vw 80px;
    background: linear-gradient(180deg, var(--carbon) 0%, #14100c 100%);
    color: var(--vellum);
    overflow: hidden;
}

.notebook {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
    transform: rotate(-1.2deg);
    filter: drop-shadow(0 14px 40px rgba(0, 0, 0, 0.55));
}

.notebook-inner {
    position: relative;
    background: var(--vellum);
    color: var(--carbon);
    padding: 56px 56px 48px 80px;
    background-image:
        repeating-linear-gradient(
            to bottom,
            transparent 0,
            transparent 31px,
            rgba(155, 74, 44, 0.18) 31px,
            rgba(155, 74, 44, 0.18) 32px
        );
    /* Ragged left edge — torn-page clip-path */
    clip-path: polygon(
        4% 0%, 100% 0%, 100% 100%, 6% 100%,
        2% 96%, 5% 92%, 1% 86%, 4% 80%,
        2% 74%, 5% 68%, 1% 62%, 4% 56%,
        2% 50%, 5% 44%, 1% 38%, 4% 32%,
        2% 26%, 5% 20%, 1% 14%, 4% 8%
    );
}

/* Red margin line */
.notebook-inner::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 64px;
    width: 1.5px;
    background: rgba(155, 74, 44, 0.5);
}

/* Hole-punch holes */
.notebook-inner::after {
    content: "";
    position: absolute;
    top: 80px;
    left: 28px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--earth-dark);
    box-shadow:
        0 120px 0 0 var(--earth-dark),
        0 240px 0 0 var(--earth-dark),
        0 360px 0 0 var(--earth-dark);
    opacity: 0.85;
}

.note-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-family: var(--mono);
    font-size: 0.78rem;
    letter-spacing: 0.18em;
    color: var(--clay);
    text-transform: uppercase;
    margin-bottom: 18px;
    padding-bottom: 8px;
    border-bottom: 1px dashed rgba(107, 76, 59, 0.4);
}

.note-stamp { font-weight: 700; }

.note-title {
    font-family: var(--display);
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 700;
    color: var(--carbon);
    margin-bottom: 18px;
    letter-spacing: 0.02em;
}

.note-block {
    font-family: var(--mono);
    font-size: 0.95rem;
    line-height: 2;
    color: var(--carbon);
    background: transparent;
    margin: 12px 0 22px;
    white-space: pre;
    overflow-x: auto;
}

.note-body {
    font-family: var(--body);
    font-size: 1rem;
    line-height: 1.85;
    color: var(--earth-dark);
    margin-bottom: 28px;
    max-width: 56ch;
}

.note-sign {
    font-family: var(--hand);
    font-size: 1.4rem;
    color: var(--oxide);
    transform: rotate(-2deg);
    transform-origin: left;
    display: inline-block;
}

.colophon {
    margin-top: 80px;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    font-family: var(--mono);
    font-size: 0.74rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: rgba(244, 239, 228, 0.55);
    border-top: 1px solid rgba(244, 239, 228, 0.12);
    padding-top: 24px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

/* =============================================================
   RESPONSIVE
   ============================================================= */
@media (max-width: 720px) {
    .dig-grid {
        width: 88vmin;
        height: 88vmin;
        margin-top: 90px;
    }

    .studio-name { font-size: 0.92rem; }
    .studio-meta { font-size: 0.55rem; }

    .hero-anno-tl,
    .hero-anno-tr { font-size: 0.6rem; }
    .hero-anno-tr { top: 56px; }

    .hand-hero { display: none; }

    .layer { padding: 80px 6vw 90px; }

    .excavated { padding: 32px 26px 36px; }

    .layer-title { font-size: clamp(1.5rem, 7vw, 2.2rem); }

    .practice-list li {
        grid-template-columns: 36px 1fr;
        gap: 10px;
    }

    .col-row {
        grid-template-columns: 70px 1fr;
        gap: 8px 12px;
    }

    .col-note {
        grid-column: 1 / -1;
        margin-top: 4px;
        padding-left: 0;
    }

    .notebook-inner {
        padding: 40px 28px 36px 56px;
    }

    .notebook-inner::after {
        left: 18px;
        top: 60px;
        width: 8px;
        height: 8px;
    }

    .notebook-inner::before { left: 44px; }

    .meta-list {
        grid-template-columns: 1fr;
        gap: 4px;
    }
    .meta-list dt { margin-top: 8px; }

    .marker-row { font-size: 0.66rem; }
}

@media (max-width: 420px) {
    .dig-grid { width: 92vmin; height: 92vmin; }
    .studio-name { font-size: 0.78rem; }
}
