/* ==========================================================================
   narsikularia.com — core stylesheet
   Identity: "The Measured Drawing" — aubergine, oyster, sage & copper,
   Bodoni Moda display over Schibsted Grotesk text. Dimension-line motifs
   reference the joiner's shop drawing that the story begins with.
   ========================================================================== */

:root {
  --bg: #f1edef;
  --paper: #faf8f9;
  --mist: #e7e1e5;
  --line: #d8cfd5;
  --line-strong: #b6a9b2;

  --ink: #1e171d;
  --ink-2: #463c44;
  --muted: #655a62;

  --aub: #2a1a28;
  --aub-2: #3a2637;
  --plum: #5a3953;

  --sage: #52644b;
  --sage-2: #8ea284;
  --sage-soft: #d3dccb;
  --sage-tint: #e6ebe1;

  --copper: #955026;
  --copper-light: #dea47b;

  --on-dark: #f5eff3;
  --on-dark-2: #cbbfc8;
  --on-dark-line: rgba(245, 239, 243, 0.18);

  --display: "Bodoni Moda", "Bodoni 72", "Didot", Georgia, "Times New Roman", serif;
  --text: "Schibsted Grotesk", "Helvetica Neue", Arial, system-ui, sans-serif;

  --max: 1320px;
  --gutter: clamp(16px, 4vw, 48px);
  --nav-h: 72px;
  --space-1: clamp(56px, 8vw, 120px);
  --space-2: clamp(40px, 5vw, 72px);
  --radius: 2px;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--text);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p { margin: 0 0 1.1em; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; }
ul, ol { margin: 0; padding: 0; }
button { font: inherit; }

:focus-visible { outline: 2px solid var(--copper); outline-offset: 3px; }

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  background: var(--aub); color: var(--on-dark); padding: 10px 16px;
  text-decoration: none; font-weight: 600; border-radius: var(--radius);
}
.skip:focus { top: 12px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.wrap--narrow { max-width: 980px; }

/* ---------- Type ---------- */

.display, h1, h2 { font-family: var(--display); letter-spacing: -0.01em; }
h1 { font-size: clamp(2.6rem, 6.4vw, 5.6rem); line-height: 1.02; }
h2 { font-size: clamp(2rem, 3.8vw, 3.3rem); line-height: 1.08; }
h3 { font-family: var(--text); font-weight: 600; font-size: 1.2rem; line-height: 1.35; letter-spacing: -0.005em; }
h1 em, h2 em, .display em { font-style: italic; color: var(--plum); }

.label {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--text); font-size: 0.74rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--sage);
}
.label::before { content: ""; width: 26px; height: 1px; background: currentColor; }
.label--plain::before { display: none; }

.standfirst { font-size: clamp(1.1rem, 1.6vw, 1.32rem); line-height: 1.55; color: var(--ink-2); max-width: 44ch; }
.muted { color: var(--muted); }
.small { font-size: 0.88rem; }

.prose { max-width: 68ch; }
.prose h2 { margin: 1.6em 0 0.5em; font-size: clamp(1.7rem, 2.8vw, 2.4rem); }
.prose h3 { margin: 1.8em 0 0.5em; }
.prose > :first-child { margin-top: 0; }
.prose ul { padding-left: 1.2em; margin: 0 0 1.2em; }
.prose li { margin-bottom: 0.4em; }
.prose a, .link { color: var(--plum); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.prose a:hover, .link:hover { color: var(--copper); }

.dropcap::first-letter {
  float: left; font-family: var(--display); font-size: 4.6em; line-height: 0.82;
  padding: 0.06em 0.12em 0 0; color: var(--plum);
}

sup.ref { font-size: 0.68em; line-height: 0; margin-left: 1px; }
sup.ref a { text-decoration: none; color: var(--copper); font-weight: 600; padding: 0 1px; }
sup.ref a:hover { text-decoration: underline; }

/* ---------- Dimension-line motif ---------- */

.dim {
  display: flex; align-items: center; gap: 14px;
  font-size: 0.74rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--muted); font-weight: 600;
}
.dim::before, .dim::after {
  content: ""; flex: 1; height: 9px; min-width: 24px;
  border-bottom: 1px solid var(--line-strong);
}
.dim::before { border-left: 1px solid var(--line-strong); transform: translateY(-4px); }
.dim::after { border-right: 1px solid var(--line-strong); transform: translateY(-4px); }
.on-dark .dim, .dim--dark { color: var(--on-dark-2); }
.on-dark .dim::before, .on-dark .dim::after, .dim--dark::before, .dim--dark::after { border-color: var(--on-dark-line); }

/* ---------- Buttons & links ---------- */

.btn {
  display: inline-flex; align-items: center; gap: 12px; min-height: 48px;
  padding: 0 22px; border: 1px solid var(--aub); background: var(--aub); color: var(--on-dark);
  text-decoration: none; font-weight: 600; font-size: 0.95rem; border-radius: var(--radius);
  cursor: pointer; transition: background .2s, color .2s, border-color .2s;
}
.btn:hover { background: var(--plum); border-color: var(--plum); }
.btn--ghost { background: transparent; color: var(--aub); }
.btn--ghost:hover { background: var(--aub); color: var(--on-dark); }
.on-dark .btn { background: var(--on-dark); color: var(--aub); border-color: var(--on-dark); }
.on-dark .btn:hover { background: var(--copper-light); border-color: var(--copper-light); }

.arrow-link {
  display: inline-flex; align-items: center; gap: 10px; font-weight: 600;
  text-decoration: none; color: var(--plum); border-bottom: 1px solid currentColor; padding-bottom: 2px;
}
.arrow-link::after { content: "\2192"; transition: transform .2s; }
.arrow-link:hover { color: var(--copper); }
.arrow-link:hover::after { transform: translateX(4px); }
.on-dark .arrow-link { color: var(--copper-light); }

/* ==========================================================================
   Header — sticky
   ========================================================================== */

.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .25s;
}
.site-header.is-scrolled { box-shadow: 0 8px 24px -18px rgba(42, 26, 40, 0.45); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: var(--nav-h); }

.brand { display: inline-flex; align-items: baseline; gap: 10px; text-decoration: none; color: var(--aub); white-space: nowrap; }
.brand__name { font-family: var(--display); font-size: 1.5rem; line-height: 1; letter-spacing: -0.01em; }
.brand__name em { color: var(--plum); }
.brand__tag { font-size: 0.66rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--sage); font-weight: 600; }

.nav-desktop { display: none; }
.nav-desktop ul { list-style: none; display: flex; align-items: center; gap: 2px; }
.nav-desktop a {
  position: relative; display: block; padding: 8px 9px; text-decoration: none;
  font-size: 0.86rem; font-weight: 500; color: var(--ink-2); white-space: nowrap;
}
.nav-desktop a::after {
  content: ""; position: absolute; left: 9px; right: 9px; bottom: 2px; height: 1px;
  background: var(--copper); transform: scaleX(0); transform-origin: left; transition: transform .25s;
}
.nav-desktop a:hover { color: var(--aub); }
.nav-desktop a:hover::after, .nav-desktop a[aria-current="page"]::after { transform: scaleX(1); }
.nav-desktop a[aria-current="page"] { color: var(--aub); font-weight: 600; }
.nav-desktop .nav-contact { margin-left: 8px; border: 1px solid var(--aub); padding: 7px 14px; border-radius: var(--radius); color: var(--aub); }
.nav-desktop .nav-contact::after { display: none; }
.nav-desktop .nav-contact:hover, .nav-desktop .nav-contact[aria-current="page"] { background: var(--aub); color: var(--on-dark); }

.menu-toggle {
  display: inline-flex; align-items: center; gap: 12px; height: 44px; padding: 0 4px 0 14px;
  background: none; border: 1px solid var(--line-strong); border-radius: var(--radius);
  color: var(--aub); font-weight: 600; font-size: 0.82rem; letter-spacing: 0.14em; text-transform: uppercase; cursor: pointer;
}
.menu-toggle__bars { position: relative; width: 36px; height: 36px; }
.menu-toggle__bars span { position: absolute; left: 9px; right: 9px; height: 1.5px; background: currentColor; transition: transform .25s, top .25s; }
.menu-toggle__bars span:nth-child(1) { top: 14px; }
.menu-toggle__bars span:nth-child(2) { top: 21px; }

/* Mobile / tablet overlay menu */
.menu-panel {
  position: fixed; inset: 0; z-index: 150; background: var(--aub); color: var(--on-dark);
  display: flex; flex-direction: column; overflow-y: auto; overscroll-behavior: contain;
  visibility: hidden; opacity: 0; transition: opacity .25s, visibility 0s linear .25s;
}
.menu-panel.is-open { visibility: visible; opacity: 1; transition: opacity .25s; }
.menu-panel__top { display: flex; align-items: center; justify-content: space-between; height: var(--nav-h); flex: none; border-bottom: 1px solid var(--on-dark-line); }
.menu-panel .brand { color: var(--on-dark); }
.menu-panel .brand__name em { color: var(--copper-light); }
.menu-panel .brand__tag { color: var(--sage-2); }
.menu-close {
  display: inline-flex; align-items: center; gap: 10px; height: 44px; padding: 0 16px;
  background: none; color: var(--on-dark); border: 1px solid var(--on-dark-line); border-radius: var(--radius);
  font-weight: 600; font-size: 0.82rem; letter-spacing: 0.14em; text-transform: uppercase; cursor: pointer;
}
.menu-close span[aria-hidden] { font-size: 1.3rem; line-height: 1; letter-spacing: 0; }
.menu-panel nav { flex: 1; padding: 20px 0 32px; }
.menu-panel ol { list-style: none; display: grid; grid-template-columns: 1fr; }
.menu-panel li { border-bottom: 1px solid var(--on-dark-line); }
.menu-panel ol a {
  display: flex; align-items: baseline; gap: 18px; padding: 12px 0; text-decoration: none;
  font-family: var(--display); font-size: clamp(1.6rem, 6vw, 2.4rem); line-height: 1.15; color: var(--on-dark);
}
.menu-panel ol a small { font-family: var(--text); font-size: 0.72rem; letter-spacing: 0.12em; color: var(--sage-2); min-width: 22px; }
.menu-panel ol a:hover, .menu-panel ol a[aria-current="page"] { color: var(--copper-light); }
.menu-panel ol a[aria-current="page"] { font-style: italic; }
.menu-panel__foot { flex: none; padding: 20px 0 28px; border-top: 1px solid var(--on-dark-line); font-size: 0.9rem; color: var(--on-dark-2); }
.menu-panel__foot a { color: var(--on-dark); }
body.menu-open { overflow: hidden; }

/* ==========================================================================
   Inner-page masthead
   ========================================================================== */

.masthead { padding: clamp(40px, 6vw, 88px) 0 clamp(32px, 4vw, 56px); border-bottom: 1px solid var(--line); }
.masthead__grid { display: grid; grid-template-columns: 1fr; gap: 28px; align-items: end; }
.masthead__no {
  font-family: var(--display); font-size: clamp(5rem, 13vw, 11rem); line-height: 0.8; color: transparent;
  -webkit-text-stroke: 1px var(--plum); letter-spacing: -0.03em; user-select: none;
}
.masthead h1 { margin: 14px 0 20px; }
.masthead .dim { margin-top: clamp(28px, 4vw, 48px); }
.crumbs { font-size: 0.8rem; color: var(--muted); margin-bottom: 18px; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: var(--line-strong); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--plum); text-decoration: underline; }

.masthead--dark { background: var(--aub); color: var(--on-dark); border-bottom: 0; }
.masthead--dark .masthead__no { -webkit-text-stroke-color: var(--copper-light); }
.masthead--dark .label { color: var(--sage-2); }
.masthead--dark h1 em { color: var(--copper-light); }
.masthead--dark .standfirst { color: var(--on-dark-2); }
.masthead--dark .crumbs, .masthead--dark .crumbs a { color: var(--on-dark-2); }

/* ==========================================================================
   Sections & shared compositions
   ========================================================================== */

.section { padding: var(--space-1) 0; }
.section--tight { padding: var(--space-2) 0; }
.section--rule { border-top: 1px solid var(--line); }
.section--paper { background: var(--paper); }
.section--sage { background: var(--sage-tint); }
.on-dark { background: var(--aub); color: var(--on-dark); }
.on-dark .label { color: var(--sage-2); }
.on-dark h2 em, .on-dark h1 em { color: var(--copper-light); }
.on-dark .muted { color: var(--on-dark-2); }

.section-head { display: grid; gap: 18px; margin-bottom: clamp(32px, 5vw, 64px); max-width: 820px; }

/* Figures — never cropped. Width governs; height always follows ratio. */
.fig { margin: 0; }
.fig img { width: 100%; height: auto; object-fit: contain; background: var(--mist); }
.fig figcaption { margin-top: 12px; font-size: 0.84rem; line-height: 1.5; color: var(--muted); }
.fig figcaption b { color: var(--ink-2); font-weight: 600; }
.on-dark .fig figcaption { color: var(--on-dark-2); }
.on-dark .fig figcaption b { color: var(--on-dark); }
.fig--framed { padding: 12px; background: var(--paper); border: 1px solid var(--line); }
.fig--framed img { background: none; }
/* Small source photographs are held near native size to avoid softening */
.fig--s { max-width: 340px; }
.fig--m { max-width: 420px; }

/* Measured frame: tick marks at the corners, like a shop drawing */
.measure { position: relative; padding: 18px; }
.measure::before, .measure::after {
  content: ""; position: absolute; width: 22px; height: 22px; pointer-events: none;
  border-color: var(--copper); border-style: solid;
}
.measure::before { top: 0; left: 0; border-width: 1px 0 0 1px; }
.measure::after { right: 0; bottom: 0; border-width: 0 1px 1px 0; }

/* Numbered rows (not cards) */
.rows { list-style: none; border-top: 1px solid var(--line-strong); }
.rows > li { display: grid; grid-template-columns: 1fr; gap: 10px 32px; padding: 28px 0; border-bottom: 1px solid var(--line); }
.rows__no { font-family: var(--display); font-size: 2.6rem; line-height: 1; color: var(--copper); }
.rows h3 { font-family: var(--display); font-weight: 400; font-size: clamp(1.6rem, 2.6vw, 2.1rem); line-height: 1.12; }
.rows p { margin: 0; color: var(--ink-2); }
.rows .arrow-link { margin-top: 14px; }

/* Pull quote */
.pull { margin: 0; }
.pull blockquote { margin: 0; font-family: var(--display); font-weight: 500; font-size: clamp(1.6rem, 3.4vw, 2.9rem); line-height: 1.22; }
.pull blockquote::before { content: "\201C"; display: block; font-size: 2.2em; line-height: 0.6; color: var(--copper-light); margin-bottom: 6px; }
.pull figcaption { margin-top: 28px; font-size: 0.92rem; color: var(--on-dark-2); max-width: 60ch; }
.pull figcaption b { color: var(--on-dark); font-weight: 600; }
.pull--light blockquote::before { color: var(--copper); }
.pull--light figcaption { color: var(--muted); }
.pull--light figcaption b { color: var(--ink); }

/* Ruler stats */
.ruler { position: relative; display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--ink); }
.ruler::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 12px; pointer-events: none;
  background: repeating-linear-gradient(90deg, var(--ink) 0 1px, transparent 1px 24px);
  opacity: .35;
}
.ruler__item { padding: 30px 20px 26px 0; border-bottom: 1px solid var(--line); }
.ruler__num { font-family: var(--display); font-size: clamp(2.4rem, 5vw, 4.2rem); line-height: 1; color: var(--aub); }
.ruler__num sup { font-size: 0.45em; vertical-align: top; position: relative; top: .35em; color: var(--copper); }
.ruler__cap { margin: 12px 0 0; font-size: 0.9rem; color: var(--ink-2); max-width: 26ch; }
.ruler__src { display: block; margin-top: 6px; font-size: 0.76rem; color: var(--muted); }

/* Long-form layout with sticky margin */
.longform { display: grid; grid-template-columns: 1fr; gap: 48px; }
.margin-notes { display: grid; gap: 28px; align-content: start; }
.facts { list-style: none; border-top: 1px solid var(--ink); }
.facts li { display: grid; grid-template-columns: 1fr; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 0.93rem; }
.facts dt, .facts .k { font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--sage); font-weight: 600; }
.facts .v { color: var(--ink); }

/* Chronology */
.chrono { list-style: none; position: relative; }
.chrono > li { position: relative; display: grid; grid-template-columns: 1fr; gap: 12px; padding: 0 0 clamp(40px, 6vw, 72px) 28px; }
.chrono > li::before { content: ""; position: absolute; left: 4px; top: 12px; bottom: 0; width: 1px; background: var(--line-strong); }
.chrono > li::after { content: ""; position: absolute; left: 0; top: 8px; width: 9px; height: 9px; background: var(--copper); transform: rotate(45deg); }
.chrono > li:last-child::before { display: none; }
.chrono__year { font-family: var(--display); font-size: clamp(3rem, 7vw, 5.6rem); line-height: 0.9; color: var(--aub); letter-spacing: -0.02em; }
.chrono__year small { display: block; margin-top: 10px; font-family: var(--text); font-size: 0.74rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--sage); font-weight: 600; }
.chrono h3 { font-family: var(--display); font-weight: 400; font-size: clamp(1.5rem, 2.4vw, 2rem); line-height: 1.15; margin-bottom: 14px; }
.chrono dl { margin: 18px 0 0; display: grid; gap: 14px; }
.chrono dt { font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--sage); font-weight: 600; }
.chrono dd { margin: 4px 0 0; color: var(--ink-2); }

/* Data tables */
.table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; border-top: 1px solid var(--ink); }
.data { width: 100%; border-collapse: collapse; font-size: 0.93rem; min-width: 560px; }
.data caption { text-align: left; font-size: 0.84rem; color: var(--muted); padding: 0 0 12px; caption-side: bottom; padding-top: 12px; }
.data th, .data td { text-align: left; vertical-align: top; padding: 14px 16px 14px 0; border-bottom: 1px solid var(--line); }
.data thead th { font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--sage); font-weight: 600; }
.data td.num { font-family: var(--display); font-size: 1.5rem; line-height: 1.1; color: var(--aub); white-space: nowrap; }

/* Spec sheet */
.spec { display: grid; grid-template-columns: 1fr; border-top: 1px solid var(--ink); margin: 0; }
.spec > div { display: grid; grid-template-columns: 1fr 1.4fr; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.spec dt { font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--sage); font-weight: 600; padding-top: 4px; }
.spec dd { margin: 0; }
.on-dark .spec { border-top-color: var(--on-dark); }
.on-dark .spec > div { border-bottom-color: var(--on-dark-line); }
.on-dark .spec dt { color: var(--sage-2); }

/* Typographic wall */
.wall { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 0; font-family: var(--display); font-size: clamp(1.4rem, 3vw, 2.4rem); line-height: 1.3; }
.wall li::after { content: "/"; margin: 0 .45em; color: var(--copper); font-style: normal; }
.wall li:last-child::after { display: none; }
.wall li:nth-child(3n+2) { font-style: italic; color: var(--plum); }

/* Notes & sources */
.note {
  border-left: 3px solid var(--sage); background: var(--sage-tint); padding: 18px 22px;
  font-size: 0.93rem; color: var(--ink-2); max-width: 72ch;
}
.note p:last-child { margin: 0; }
.note strong { color: var(--ink); }

.sources { padding: var(--space-2) 0; border-top: 1px solid var(--line); background: var(--paper); }
.sources h2 { font-size: 1.6rem; margin-bottom: 20px; }
.sources ol { padding-left: 1.4em; display: grid; gap: 10px; font-size: 0.88rem; color: var(--ink-2); max-width: 90ch; }
.sources li { padding-left: 4px; }
.sources a { color: var(--plum); word-break: break-word; }
.sources li:target { background: var(--sage-tint); outline: 6px solid var(--sage-tint); }

/* Next-chapter band */
.next { border-top: 1px solid var(--line); }
.next a {
  display: grid; grid-template-columns: 1fr; gap: 10px; padding: clamp(40px, 6vw, 72px) 0; text-decoration: none; color: var(--aub);
}
.next__t { font-family: var(--display); font-size: clamp(2.2rem, 5.4vw, 4.6rem); line-height: 1; transition: color .2s; }
.next__t::after { content: " \2192"; font-family: var(--text); font-weight: 300; }
.next a:hover .next__t { color: var(--copper); }

/* ==========================================================================
   Home page
   ========================================================================== */

.hero { padding: clamp(36px, 5vw, 72px) 0 clamp(48px, 6vw, 88px); position: relative; }
.hero__grid { display: grid; grid-template-columns: 1fr; gap: 40px; align-items: end; }
.hero__name { font-family: var(--display); font-size: clamp(3.6rem, 12.5vw, 11.5rem); line-height: 0.86; letter-spacing: -0.035em; color: var(--aub); margin: 18px 0 0; }
.hero__name span { display: block; }
.hero__name span + span { font-style: italic; color: var(--plum); padding-left: 0.42em; }
.hero__lede { font-size: clamp(1.15rem, 1.8vw, 1.45rem); line-height: 1.5; color: var(--ink-2); max-width: 36ch; margin-top: 28px; }
.hero__roles { list-style: none; margin-top: 32px; border-top: 1px solid var(--ink); max-width: 520px; }
.hero__roles li { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 0.95rem; }
.hero__roles li span:last-child { color: var(--muted); text-align: right; }
.hero__portrait { justify-self: start; width: 100%; max-width: 360px; }
.hero__portrait .dim { margin-top: 12px; }

.contents { list-style: none; counter-reset: toc; border-top: 1px solid var(--line-strong); display: grid; grid-template-columns: 1fr; column-gap: 56px; }
.contents li { border-bottom: 1px solid var(--line); }
.contents a { display: grid; grid-template-columns: 44px 1fr auto; gap: 14px; align-items: baseline; padding: 18px 0; text-decoration: none; color: var(--ink); }
.contents__no { font-size: 0.78rem; color: var(--sage); font-weight: 600; letter-spacing: .08em; }
.contents__t { font-family: var(--display); font-size: 1.55rem; line-height: 1.1; }
.contents__d { display: block; font-family: var(--text); font-size: 0.88rem; color: var(--muted); margin-top: 6px; }
.contents__go { color: var(--copper); transition: transform .2s; }
.contents a:hover .contents__t { color: var(--plum); font-style: italic; }
.contents a:hover .contents__go { transform: translateX(4px); }

.split { display: grid; grid-template-columns: 1fr; gap: 40px; }

/* Mini chronology on home */
.strip { list-style: none; display: grid; grid-template-columns: 1fr; border-top: 1px solid var(--on-dark-line); }
.strip li { padding: 22px 0; border-bottom: 1px solid var(--on-dark-line); display: grid; grid-template-columns: 88px 1fr; gap: 16px; }
.strip b { font-family: var(--display); font-weight: 400; font-size: 1.9rem; line-height: 1; color: var(--copper-light); }
.strip p { margin: 0; color: var(--on-dark-2); font-size: 0.95rem; }
.strip strong { display: block; color: var(--on-dark); font-weight: 600; margin-bottom: 2px; }

/* ==========================================================================
   Page-specific compositions
   ========================================================================== */

/* Offset text + image */
.offset { display: grid; grid-template-columns: 1fr; gap: 40px; align-items: start; }

/* Documentary figure: wide image, caption in side column */
.doc { display: grid; grid-template-columns: 1fr; gap: 20px; }
.doc .fig img { box-shadow: 0 30px 60px -40px rgba(42, 26, 40, .6); }
.doc__cap { font-size: 0.9rem; color: var(--muted); border-top: 1px solid var(--line-strong); padding-top: 14px; }
.on-dark .doc__cap { color: var(--on-dark-2); border-top-color: var(--on-dark-line); }
.doc__cap b { display: block; color: var(--ink); font-weight: 600; margin-bottom: 4px; }
.on-dark .doc__cap b { color: var(--on-dark); }

/* Big figure + explanation */
.bignum { display: grid; grid-template-columns: 1fr; gap: 24px; align-items: end; }
.bignum__n { font-family: var(--display); font-size: clamp(5rem, 16vw, 13rem); line-height: 0.82; color: var(--aub); letter-spacing: -0.04em; }
.bignum__n small { font-size: 0.3em; color: var(--copper); letter-spacing: 0; }

/* Case studies */
.cases { display: grid; grid-template-columns: 1fr; gap: 40px; }
.case-index { display: none; }
.case { padding: clamp(40px, 6vw, 72px) 0; border-top: 1px solid var(--ink); }
.case:first-child { border-top: 0; padding-top: 0; }
.case__head { display: grid; gap: 12px; margin-bottom: 32px; }
.case__no { font-family: var(--display); font-style: italic; font-size: 1.3rem; color: var(--copper); }
.case__head h2 { font-size: clamp(1.9rem, 3.4vw, 2.8rem); }
.stages { margin: 0; display: grid; grid-template-columns: 1fr; border-top: 1px solid var(--line-strong); }
.stages > div { display: grid; grid-template-columns: 1fr; gap: 6px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.stages dt { font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--sage); font-weight: 600; }
.stages dd { margin: 0; color: var(--ink-2); }
.stages dd p:last-child { margin: 0; }

/* Perspective categories on Insights */
.voice { display: grid; grid-template-columns: 1fr; gap: 20px; padding: clamp(32px, 4vw, 48px) 0; border-top: 1px solid var(--line); }
.voice:first-of-type { border-top: 1px solid var(--ink); }
.tag {
  display: inline-block; font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 700;
  padding: 5px 10px; border-radius: var(--radius); border: 1px solid currentColor; justify-self: start; align-self: start;
}
.tag--his { color: var(--plum); }
.tag--ana { color: var(--sage); }
.tag--third { color: var(--copper); }
.voice blockquote { margin: 0; font-family: var(--display); font-weight: 500; font-size: clamp(1.35rem, 2.4vw, 1.9rem); line-height: 1.3; }
.voice .attr { font-size: 0.88rem; color: var(--muted); margin-top: 12px; }

.legend { display: grid; grid-template-columns: 1fr; gap: 14px; margin: 0; }
.legend > div { display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: baseline; }
.legend dd { margin: 0; font-size: 0.93rem; color: var(--ink-2); }

/* Coverage list */
.coverage { list-style: none; border-top: 1px solid var(--ink); }
.coverage li { display: grid; grid-template-columns: 1fr; gap: 4px 24px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.coverage .when { font-size: 0.8rem; color: var(--sage); font-weight: 600; letter-spacing: .06em; }
.coverage a { font-family: var(--display); font-size: 1.3rem; line-height: 1.25; color: var(--ink); text-decoration: none; }
.coverage a:hover { color: var(--plum); text-decoration: underline; text-decoration-thickness: 1px; }
.coverage .out { font-size: 0.86rem; color: var(--muted); }

/* Gallery — an even grid of matching mats; every photograph is centred and
   fitted inside its mat (contain), so nothing is cropped and rows align. */
.gallery { display: grid; grid-template-columns: 1fr; gap: 40px 32px; margin-bottom: 32px; }
.gallery .fig { margin: 0; display: flex; flex-direction: column; }
.gallery button {
  position: relative; display: block; width: 100%; aspect-ratio: 4 / 5; min-height: 0; padding: 0; overflow: hidden;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); cursor: zoom-in; transition: border-color .2s;
}
.gallery button:hover { border-color: var(--copper); }
.gallery button:focus-visible { outline-offset: 4px; }
.gallery .fig img {
  position: absolute; inset: 0; margin: auto; width: auto; height: auto;
  max-width: calc(100% - 36px); max-height: calc(100% - 36px); object-fit: contain; background: none;
}

.lightbox {
  position: fixed; inset: 0; z-index: 180; background: rgba(30, 19, 28, .96); color: var(--on-dark);
  display: none; flex-direction: column; align-items: center; justify-content: center; padding: 64px 16px 24px;
}
.lightbox.is-open { display: flex; }
.lightbox img { max-width: min(1200px, 100%); max-height: calc(100vh - 180px); width: auto; height: auto; object-fit: contain; }
.lightbox p { max-width: 70ch; text-align: center; margin: 16px 0 0; font-size: 0.9rem; color: var(--on-dark-2); }
.lightbox__close {
  position: absolute; top: 14px; right: 16px; height: 44px; padding: 0 16px; background: none; color: var(--on-dark);
  border: 1px solid var(--on-dark-line); border-radius: var(--radius); cursor: pointer; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; font-size: .78rem;
}
.lightbox__nav { display: flex; gap: 12px; margin-top: 16px; }
.lightbox__nav button { height: 44px; min-width: 44px; padding: 0 16px; background: none; color: var(--on-dark); border: 1px solid var(--on-dark-line); border-radius: var(--radius); cursor: pointer; }

/* ==========================================================================
   Contact
   ========================================================================== */

.contact-grid { display: grid; grid-template-columns: 1fr; gap: 56px; }
.contact-card { border-top: 1px solid var(--ink); }
.contact-card > div { padding: 18px 0; border-bottom: 1px solid var(--line); }
.contact-card .k { display: block; font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--sage); font-weight: 600; margin-bottom: 4px; }
.contact-card .v { font-family: var(--display); font-size: clamp(1.4rem, 2.6vw, 1.9rem); line-height: 1.2; color: var(--aub); text-decoration: none; word-break: break-word; }
.contact-card a.v:hover { color: var(--copper); }

.form { display: grid; grid-template-columns: 1fr; gap: 22px; }
.field { display: grid; gap: 8px; }
.field label { font-weight: 600; font-size: 0.9rem; }
.field .req { color: var(--copper); margin-left: 2px; }
.field input, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px; font: inherit; font-size: 1rem; color: var(--ink);
  background: var(--paper); border: 1px solid var(--line-strong); border-radius: var(--radius);
  transition: border-color .2s, box-shadow .2s;
}
.field textarea { min-height: 170px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--plum); box-shadow: 0 0 0 3px rgba(90, 57, 83, .18); background: #fff; }
.field [aria-invalid="true"] { border-color: #a1262b; }
.field .hint { font-size: 0.8rem; color: var(--muted); }
.field .err { font-size: 0.84rem; color: #a1262b; min-height: 0; }
.field .err:empty { display: none; }
.form__status { padding: 16px 18px; border-left: 3px solid; font-size: 0.95rem; }
.form__status[hidden] { display: none; }
.form__status--ok { border-color: var(--sage); background: var(--sage-tint); }
.form__status--err { border-color: #a1262b; background: #f6e4e4; }
.form__status p:last-child { margin: 0; }
.form__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer { background: var(--aub); color: var(--on-dark-2); padding: clamp(56px, 7vw, 96px) 0 0; font-size: 0.93rem; }
.site-footer a { color: var(--on-dark); text-decoration: none; }
.site-footer a:hover { color: var(--copper-light); text-decoration: underline; text-underline-offset: 3px; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 40px; padding-bottom: 48px; }
.footer-brand .brand__name { font-size: 2.2rem; color: var(--on-dark); }
.footer-brand .brand__name em { color: var(--copper-light); }
.footer-brand p { margin-top: 16px; max-width: 36ch; }
.footer-h { font-size: 0.7rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--sage-2); font-weight: 600; margin-bottom: 14px; }
.footer-links { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 20px; }
.footer-contact { font-style: normal; display: grid; gap: 6px; }
.footer-contact .name { color: var(--on-dark); font-weight: 600; }
.social { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; }
.social a, .social span {
  display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px;
  border: 1px solid var(--on-dark-line); border-radius: 50%; color: var(--on-dark); transition: background .2s, color .2s, border-color .2s;
}
.social a:hover { background: var(--copper-light); border-color: var(--copper-light); color: var(--aub); text-decoration: none; }
.social a:focus-visible { outline-color: var(--copper-light); }
.social span { opacity: .45; cursor: not-allowed; }
.social svg { width: 18px; height: 18px; fill: currentColor; }
.social-note { margin-top: 12px; font-size: 0.8rem; color: var(--on-dark-2); }
.footer-bar {
  display: flex; flex-wrap: wrap; gap: 12px 28px; justify-content: space-between; align-items: center;
  padding: 22px 0 26px; border-top: 1px solid var(--on-dark-line); font-size: 0.84rem;
}
.footer-bar p { margin: 0; }
.signout { background: none; border: 0; padding: 0; color: var(--on-dark-2); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font-size: 0.84rem; }
.signout:hover { color: var(--copper-light); }

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

/* Dark-section text details */
.on-dark .prose a, .on-dark .link { color: var(--copper-light); }
.on-dark .prose a:hover, .on-dark .link:hover { color: var(--on-dark); }
.on-dark .prose h3 { color: var(--on-dark); }
.on-dark sup.ref a, .masthead--dark sup.ref a { color: var(--copper-light); }
.on-dark .rows h3 { color: var(--on-dark); }
