/* =========================================================
   David Gahnassia — Editorial portfolio
   Apple-grade minimal. Type-led. One accent.
   ========================================================= */

:root {
  --bg:       #F2EFE9;
  --bg-deep:  #ECE7DD;
  --ink:      #121211;
  --ink-2:    #44423B;
  --ink-3:    #7C7A6F;
  --hair:     #C8C2B4;
  --hair-2:   #DCD5C6;
  --accent:   #B8421C;
  --paper:    #FBF8F2;

  --serif: "Fraunces", "Times New Roman", ui-serif, serif;
  --sans:  "Inter Tight", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;

  --max:   1320px;
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --rail-h: 64px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 18px;
  line-height: 1.55;
  font-weight: 400;
  font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }

a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  transition: opacity .25s ease;
}
a:hover { opacity: .55; }

strong { font-weight: 600; }
em     { font-style: italic; }

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding-left:  var(--gutter);
  padding-right: var(--gutter);
}

/* ---------- Reveal motion ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition:
    opacity 1.2s cubic-bezier(.2,.7,.2,1),
    transform 1.2s cubic-bezier(.2,.7,.2,1);
  will-change: opacity, transform;
}
.reveal.is-in {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Top rail ---------- */
.rail {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--rail-h);
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--gutter);
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-2);
  background: linear-gradient(to bottom, rgba(242,239,233,.92), rgba(242,239,233,0));
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  pointer-events: none;
}
.rail__mark {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 18px;
  letter-spacing: .02em;
  color: var(--ink);
  text-transform: none;
}
.rail__meta { display: flex; gap: .75rem; align-items: center; }
.dot { color: var(--ink-3); }

.rail__link {
  pointer-events: auto;
  color: var(--ink-2);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  padding-bottom: 2px;
  letter-spacing: .14em;
  font-size: 11.5px;
  transition: color .25s ease, border-color .25s ease;
}
.rail__link:hover {
  color: var(--ink);
  border-bottom-color: var(--ink);
  opacity: 1;
}

/* ---------- Kicker (small label) ---------- */
.kicker {
  font-size: 11.5px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--ink-3);
  font-weight: 500;
  margin: 0 0 2.5rem;
}

/* ---------- Display type ---------- */
.display, .display-sm {
  font-family: var(--serif);
  font-weight: 350;
  font-variation-settings: "opsz" 144, "SOFT" 0;
  letter-spacing: -0.025em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
.display {
  font-size: clamp(2.5rem, 7vw, 6.6rem);
  line-height: 0.98;
}
.display-sm {
  font-size: clamp(2rem, 4.2vw, 4rem);
  line-height: 1.02;
}
.display em, .display-sm em {
  font-style: italic;
  font-weight: 350;
  font-variation-settings: "opsz" 144;
}

/* ---------- INTRO (hero replacement) ---------- */
.intro {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: calc(var(--rail-h) + clamp(2rem, 6vh, 4rem)) 0 clamp(3rem, 6vh, 5rem);
}
.intro__grid {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: clamp(2.5rem, 6vw, 7rem);
  align-items: center;
}
.intro__words {
  display: grid;
  gap: clamp(1.25rem, 2.4vh, 2rem);
}
.intro__hi {
  margin: 0;
  font-family: var(--sans);
  font-weight: 700;
  font-size: clamp(1.4rem, 2.5vw, 2.1rem);
  letter-spacing: -0.02em;
  color: var(--ink);
}
.wave {
  display: inline-block;
  transform-origin: 70% 70%;
  animation: wave 2.6s ease-in-out 0.6s 3;
}
@keyframes wave {
  0%, 100% { transform: rotate(0); }
  10%, 30% { transform: rotate(16deg); }
  20%, 40% { transform: rotate(-8deg); }
  50% { transform: rotate(0); }
}
.intro__title {
  margin: 0;
  font-family: var(--sans);
  font-weight: 700;
  font-size: clamp(2.6rem, 5.4vw, 5.4rem);
  letter-spacing: -0.04em;
  line-height: 0.98;
  color: var(--ink);
}
.intro__body {
  display: grid;
  gap: 1.1rem;
  max-width: 56ch;
  color: #7a5e34;
  font-size: clamp(1.02rem, 1.25vw, 1.18rem);
  line-height: 1.6;
  margin-top: .25rem;
}
.intro__body p { margin: 0; }
.intro__body a {
  color: inherit;
  border-bottom-color: currentColor;
  text-decoration: none;
}
.intro__stats {
  margin: 1rem 0 0;
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(1.3rem, 2vw, 1.85rem);
  letter-spacing: -0.02em;
  color: var(--ink);
}
.intro__more {
  display: inline-block;
  margin: .25rem 0 0;
  font-family: var(--sans);
  font-size: 1rem;
  color: var(--ink);
  border-bottom: 1px solid var(--ink);
  padding-bottom: 1px;
  width: max-content;
  transition: opacity .25s ease;
}
.intro__more:hover { opacity: .65; }
.intro__social {
  display: flex;
  gap: 1.25rem;
  margin: .5rem 0 0;
}
.intro__social a {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-bottom: none;
  color: var(--ink-2);
  transition: color .25s ease, transform .25s ease;
}
.intro__social a:hover {
  color: var(--ink);
  transform: translateY(-1px);
  opacity: 1;
}

.intro__photo {
  margin: 0;
  width: 100%;
  max-width: 460px;
  aspect-ratio: 3 / 4;
  justify-self: end;
  border-radius: 50% 50% 4px 4px / 38% 38% 4px 4px;
  overflow: hidden;
  background: #6e4a2a;
  box-shadow:
    0 1px 2px rgba(0,0,0,.04),
    0 18px 60px -18px rgba(60,40,20,.22);
}
.intro__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media (max-width: 880px) {
  .intro__grid {
    grid-template-columns: 1fr;
    gap: clamp(2rem, 5vh, 3.5rem);
  }
  .intro__photo {
    max-width: 320px;
    justify-self: center;
    order: -1;
  }
}

/* ---------- Sections (rhythm) ---------- */
section {
  padding: clamp(5rem, 12vh, 11rem) 0;
}
.statement, .stat, .thesis, .pillars, .credentials, .family, .closing, .timeline {
  position: relative;
}

/* ---------- 01 — Opening statement ---------- */
.statement .display { max-width: 18ch; }
.statement .lede {
  margin-top: 2.5rem;
  max-width: 56ch;
  font-size: clamp(1.05rem, 1.4vw, 1.25rem);
  line-height: 1.55;
  color: var(--ink-2);
}

/* ---------- Figures ---------- */
.figure { padding: 0; }
.figure figure { margin: 0; position: relative; }

/* Media wrapper — calm, blends into the page */
.figure__media {
  position: relative;
  overflow: hidden;
  background: var(--bg-deep);
}
.figure__media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  /* Pull image colors closer to the cream palette */
  filter: saturate(0.9) contrast(1.0);
}
.grain { display: none; }

/* Soft warm wash that blends image colors with the page */
.figure__media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg,
    rgba(242, 239, 233, 0.10) 0%,
    rgba(242, 239, 233, 0.00) 12%,
    rgba(242, 239, 233, 0.00) 88%,
    rgba(242, 239, 233, 0.10) 100%);
  mix-blend-mode: normal;
  z-index: 1;
}

/* ---------- Captions (plain, full-width) ---------- */
.figure figcaption {
  display: block;
  max-width: var(--max);
  margin: 1.5rem auto 0;
  padding: 0 var(--gutter);
  font-size: 13.5px;
  letter-spacing: .01em;
  color: var(--ink-2);
  line-height: 1.5;
}
.figure figcaption .cap-text {
  display: block;
  font-size: 13.5px;
  letter-spacing: .01em;
  color: var(--ink-2);
  max-width: 72ch;
}
.figure figcaption .cap-text em { font-style: italic; }

/* ---------- Cover figure — respects native 3:2, contained ---------- */
.figure--cover figure {
  max-width: 1380px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.figure--cover .figure__media {
  width: 100%;
  aspect-ratio: 3 / 2;
  max-height: 78vh;
  border-radius: 10px;
  box-shadow:
    0 1px 2px rgba(60, 40, 20, .06),
    0 30px 80px -28px rgba(80, 50, 20, .18);
}
.figure--cover .figure__media img {
  object-position: center 35%;
}

/* Tall variant — narrower container, intimate feel */
.figure--tall figure {
  max-width: 920px;
}
.figure--tall .figure__media {
  aspect-ratio: 3 / 2;
  max-height: 75vh;
}
.figure--tall .figure__media img {
  object-position: center 38%;
}

/* ---------- Wide figure — contained, with top/bottom feather mask ---------- */
.figure--wide figure {
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.figure--wide .figure__media {
  width: 100%;
  aspect-ratio: 3 / 2;
  max-height: 70vh;
  /* The signature fade — image emerges from cream and dissolves back into it */
  -webkit-mask-image: linear-gradient(180deg,
    transparent 0%,
    #000 8%,
    #000 92%,
    transparent 100%);
          mask-image: linear-gradient(180deg,
    transparent 0%,
    #000 8%,
    #000 92%,
    transparent 100%);
}
.figure--wide .figure__media img {
  object-position: center 32%;
}
/* When the image is masked at the edges, the cream wash overlay would
   conflict — disable it on wide figures only */
.figure--wide .figure__media::after { display: none; }

/* Opt-out of the fade for specific figures — clean rounded card instead */
.figure--no-fade .figure__media {
  -webkit-mask-image: none;
          mask-image: none;
  border-radius: 10px;
  box-shadow:
    0 1px 2px rgba(60, 40, 20, .06),
    0 30px 80px -28px rgba(80, 50, 20, .18);
}
.figure--no-fade .figure__media::after { display: block; }

@media (max-width: 720px) {
  .figure--cover .figure__media,
  .figure--wide  .figure__media,
  .figure--tall  .figure__media { aspect-ratio: 4 / 3; max-height: 78vh; }
}

/* ---------- Stat block ---------- */
.stat__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: clamp(2rem, 6vw, 6rem);
  align-items: center;
}
.stat__num {
  font-family: var(--serif);
  font-weight: 280;
  font-variation-settings: "opsz" 144;
  font-size: clamp(7rem, 22vw, 18rem);
  line-height: 0.82;
  letter-spacing: -0.05em;
  color: var(--ink);
  display: flex;
  align-items: flex-start;
}
.stat__num .minus {
  color: var(--accent);
  font-weight: 300;
  margin-right: .04em;
}
.stat__num .pct {
  font-size: 0.42em;
  align-self: flex-start;
  margin-top: .25em;
  margin-left: .08em;
  color: var(--ink-2);
  font-weight: 300;
}
.stat__body p {
  margin-top: 1.6rem;
  max-width: 44ch;
  color: var(--ink-2);
  font-size: 1.05rem;
  line-height: 1.62;
}
.stat__body strong { color: var(--ink); font-weight: 500; }

@media (max-width: 860px) {
  .stat__grid { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* ---------- Pull quote / thesis ---------- */
.thesis {
  background: var(--bg-deep);
  padding-bottom: clamp(3rem, 7vh, 6rem); /* tightened — connects to FIG 02 below */
}
.pullquote {
  margin: 0 auto;
  max-width: min(1000px, 82vw);
  text-align: left;
}
.pullquote p {
  font-family: var(--serif);
  font-weight: 320;
  font-variation-settings: "opsz" 144;
  font-size: clamp(1.6rem, 3.4vw, 3rem);
  line-height: 1.18;
  letter-spacing: -0.018em;
  color: var(--ink-2);
  margin: 0;
}
.pullquote em { font-style: italic; color: var(--ink); }
.pullquote__before { max-width: 22ch; }
.pullquote__after  { max-width: 22ch; margin-top: 1.2em !important; }

/* The climax — "infer the unknown" on its own line, larger, with word-by-word fade-in */
.pullquote__climax {
  margin: .35em 0 !important;
  max-width: none !important;
  font-style: italic;
  font-weight: 380;
  font-size: clamp(2.6rem, 6vw, 5.4rem) !important;
  line-height: 0.98;
  letter-spacing: -0.035em;
  color: var(--ink);
  font-feature-settings: "ss01";
}
.climax-word {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.4em);
  transition:
    opacity 0.9s cubic-bezier(.22,.7,.2,1),
    transform 0.9s cubic-bezier(.22,.7,.2,1);
  margin-right: 0.18em;
}
.climax-word:last-child { margin-right: 0; }
.reveal.is-in .climax-word { opacity: 1; transform: translateY(0); }
.reveal.is-in .climax-word:nth-child(1) { transition-delay: 0.55s; }
.reveal.is-in .climax-word:nth-child(2) { transition-delay: 0.85s; }
.reveal.is-in .climax-word:nth-child(3) { transition-delay: 1.15s; }

.pullquote footer {
  margin-top: 2.5rem;
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* Bridge — small transition between the quote and the on-stage photo */
.thesis__bridge {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin: clamp(3.5rem, 7vh, 5.5rem) auto 0;
  max-width: 680px;
  width: 100%;
}
.thesis__bridge-line {
  flex: 1;
  height: 1px;
  background: var(--ink);
  opacity: .25;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 1.2s cubic-bezier(.22,.7,.2,1) 1.4s;
}
.reveal.is-in .thesis__bridge-line { transform: scaleX(1); }
.thesis__bridge-text {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(13px, 1.05vw, 15px);
  color: var(--ink-2);
  letter-spacing: .02em;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 1s ease 1.6s;
}
.reveal.is-in .thesis__bridge-text { opacity: 1; }

@media (max-width: 720px) {
  .pullquote__before, .pullquote__after { max-width: none; }
  .thesis__bridge { gap: .9rem; }
  .thesis__bridge-text { font-size: 11.5px; letter-spacing: 0; }
}

/* ---------- Timeline ---------- */
.timeline .display-sm { max-width: 16ch; margin-bottom: 4rem; }
.tl {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2px;
  background: var(--hair-2);
  border-top: 1px solid var(--hair-2);
  border-bottom: 1px solid var(--hair-2);
}
.tl__item {
  background: var(--bg);
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: clamp(1.5rem, 4vw, 4rem);
  padding: clamp(1.75rem, 3.5vw, 3rem) 0;
  align-items: start;
}
.tl__year {
  display: flex;
  align-items: baseline;
  gap: .5rem;
  font-family: var(--serif);
  font-weight: 350;
  font-size: clamp(2rem, 3vw, 2.8rem);
  letter-spacing: -0.02em;
  color: var(--ink);
  line-height: 1;
}
.tl__y-small {
  font-size: 0.42em;
  letter-spacing: .04em;
  color: var(--ink-3);
  font-weight: 400;
  font-family: var(--sans);
  text-transform: uppercase;
}
.tl__body h4 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.4rem, 2vw, 1.9rem);
  letter-spacing: -0.01em;
  margin: 0 0 .3rem;
  line-height: 1.15;
}
.tl__body h4 .tl__place {
  font-style: italic;
  font-weight: 300;
  color: var(--ink-3);
  font-size: 0.78em;
}
.tl__role {
  font-size: 12px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0 0 1.1rem;
}
.tl__body p:last-child {
  max-width: 64ch;
  color: var(--ink-2);
  font-size: 1.02rem;
  line-height: 1.62;
  margin: 0;
}
.tl__body p strong { color: var(--ink); font-weight: 500; }

.tl__item--current .tl__y { color: var(--accent); }
.tl__item--current .tl__body h4::after {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  margin-left: .75rem;
  vertical-align: middle;
  transform: translateY(-3px);
  animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: .35; transform: translateY(-3px) scale(0.9); }
  50%      { opacity: 1;   transform: translateY(-3px) scale(1.15); }
}

@media (max-width: 720px) {
  .tl__item { grid-template-columns: 1fr; gap: 1rem; }
  .tl__year { gap: .6rem; }
}

/* ---------- Right now (AIreviews) ---------- */
.now .display-sm {
  max-width: 22ch;
  margin-top: 1.5rem;
}
.now .display-sm em { color: var(--ink); }
.now__link {
  color: var(--accent);
  border-bottom: 1px solid var(--accent);
  font-style: italic;
  white-space: nowrap;
}
.now__link:hover { opacity: .65; }

.now__lede {
  margin-top: 2.5rem;
  max-width: 60ch;
  font-size: clamp(1.02rem, 1.35vw, 1.2rem);
  line-height: 1.65;
  color: var(--ink-2);
}

.now__stats {
  list-style: none;
  margin: clamp(3rem, 6vh, 5rem) 0 0;
  padding: 2.25rem 0 0;
  border-top: 1px solid var(--hair);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 3vw, 3rem);
}
.now__num {
  display: block;
  font-family: var(--serif);
  font-weight: 350;
  font-variation-settings: "opsz" 144;
  font-size: clamp(2.6rem, 4.4vw, 4rem);
  letter-spacing: -0.02em;
  color: var(--ink);
  line-height: 1;
}
.now__num .plus,
.now__num .unit {
  font-size: 0.58em;
  color: var(--ink-2);
  margin-left: .05em;
  font-weight: 400;
}
.now__lbl {
  display: block;
  margin-top: 1rem;
  font-size: 12.5px;
  letter-spacing: .04em;
  color: var(--ink-3);
  line-height: 1.5;
}

.now__role {
  margin-top: clamp(2.5rem, 5vh, 4rem);
  max-width: 60ch;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(1.15rem, 1.4vw, 1.35rem);
  line-height: 1.45;
  color: var(--ink-2);
}

@media (max-width: 720px) {
  .now__stats { grid-template-columns: 1fr; gap: 2rem; }
}

/* ---------- Pillars ---------- */
.pillars .display-sm { max-width: 22ch; margin-bottom: 4rem; }
.pillars__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 3vw, 3rem);
  border-top: 1px solid var(--hair);
  padding-top: 3rem;
}
.pillar {
  position: relative;
  padding-right: 1rem;
}
.pillar__num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.1rem;
  color: var(--accent);
  margin-bottom: 1.25rem;
  letter-spacing: .02em;
}
.pillar h4 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.3rem, 1.8vw, 1.7rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  margin: 0 0 1rem;
  color: var(--ink);
}
.pillar p {
  margin: 0;
  font-size: .98rem;
  line-height: 1.62;
  color: var(--ink-2);
  max-width: 38ch;
}

@media (max-width: 900px) {
  .pillars__grid { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* ---------- Split figure (onboarding) ---------- */
.figure--split { padding: clamp(4rem, 8vh, 8rem) 0; }
.figure__split {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
}
.figure__split figure { margin: 0; }
.figure__split .figure__media {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 10px;
  box-shadow:
    0 1px 2px rgba(60, 40, 20, .06),
    0 22px 60px -20px rgba(80, 50, 20, .16);
}
.figure__split figcaption {
  margin-top: 1.25rem;
  padding: 0;
  display: block;
}
.figure__split figcaption .cap-text {
  display: block;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.5;
  max-width: 48ch;
}
.figure__aside { padding-top: 1rem; }
.figure__pull {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 2.6vw, 2.3rem);
  font-weight: 350;
  line-height: 1.25;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 1.5rem 0 0;
}
.figure__pull em {
  font-style: italic;
  color: var(--ink-2);
}

@media (max-width: 860px) {
  .figure__split { grid-template-columns: 1fr; }
}

/* ---------- For the record (degree) ---------- */
.paper { background: var(--bg-deep); }
.paper__intro {
  max-width: 1000px;
  text-align: left;
  margin-bottom: clamp(3rem, 7vh, 6rem);
}
.paper__intro .display-sm { max-width: 18ch; margin-top: 1.5rem; }
.paper__intro .display-sm em { color: var(--ink-2); }
.paper__lede {
  margin-top: 2rem;
  max-width: 56ch;
  font-size: 1rem;
  color: var(--ink-3);
  line-height: 1.7;
  letter-spacing: .005em;
}

.paper__frame {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.paper__figure { margin: 0; position: relative; }
.paper__figure .figure__media {
  width: 100%;
  aspect-ratio: 3 / 2;
  max-height: 78vh;
  border-radius: 10px;
  box-shadow:
    0 1px 2px rgba(60, 40, 20, .06),
    0 28px 80px -22px rgba(80, 50, 20, .22),
    0 8px 24px -10px rgba(80, 50, 20, .14);
}
.paper__figure .figure__media img {
  object-position: center center;
  filter: saturate(1.0) contrast(1.02);
}
.paper__figure .grain { opacity: .08; }
.paper__placeholder {
  display: none;
  aspect-ratio: 3 / 2;
  width: 100%;
  border: 1px dashed var(--hair);
  background: var(--paper);
  color: var(--ink-3);
  font-size: 13px;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
  border-radius: 2px;
}
.paper__placeholder code {
  background: var(--bg-deep);
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 12px;
}
.paper__figure.is-missing .figure__media { display: none; }
.paper__figure.is-missing .paper__placeholder { display: flex; }
.paper__figure figcaption {
  margin-top: 1.5rem;
  padding: 0;
  display: block;
  font-size: 13.5px;
  color: var(--ink-2);
  line-height: 1.5;
}
.paper__figure figcaption .cap-text {
  display: block;
  font-size: 13.5px;
  color: var(--ink-2);
  max-width: 64ch;
}

/* ---------- Family ---------- */
.family__grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: clamp(2rem, 6vw, 6rem);
  align-items: center;
}
.family__words .display-sm { margin-top: .5rem; }
.family__body {
  margin-top: 1.75rem;
  max-width: 38ch;
  color: var(--ink-2);
  font-size: 1.02rem;
  line-height: 1.6;
}
.family__photo { position: relative; margin: 0; }
.family__photo .figure__media {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 10px;
  box-shadow:
    0 1px 2px rgba(60, 40, 20, .06),
    0 22px 60px -20px rgba(80, 50, 20, .16);
}
.family__placeholder {
  display: none;
  aspect-ratio: 3 / 4;
  width: 100%;
  border: 1px dashed var(--hair);
  background: var(--paper);
  color: var(--ink-3);
  font-size: 13px;
  letter-spacing: .02em;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  text-align: center;
  border-radius: 2px;
}
.family__photo.is-missing .family__placeholder { display: flex; }
.family__placeholder code {
  background: var(--bg-deep);
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 12px;
}
.family__photo figcaption {
  margin-top: 1.25rem;
  padding: 0;
  display: block;
  font-size: 13.5px;
  color: var(--ink-2);
  line-height: 1.5;
}
.family__photo figcaption .cap-text {
  display: block;
  font-size: 13.5px;
  color: var(--ink-2);
  max-width: 48ch;
}
.family__photo.is-missing .figure__media { display: none; }
@media (max-width: 860px) {
  .family__grid { grid-template-columns: 1fr; }
}

/* ---------- Closing ---------- */
.closing { padding-bottom: clamp(4rem, 10vh, 8rem); }
.closing .display { max-width: 14ch; }
.closing__sig {
  margin-top: clamp(3rem, 6vh, 5rem);
  display: grid;
  gap: .4rem;
}
.closing__name {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.5rem;
  font-weight: 350;
  margin: 0;
  color: var(--ink);
}
.closing__mail {
  font-size: 1.1rem;
  color: var(--ink);
  border-bottom-color: var(--accent);
  width: max-content;
}
.closing__loc {
  margin: .25rem 0 0;
  font-size: 12px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* ---------- Footer ---------- */
.foot {
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--hair-2);
  font-size: 11.5px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.foot__row { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }

/* ---------- Selection ---------- */
::selection { background: var(--ink); color: var(--bg); }
