/* ==========================================================================
   Alderwick Estate — lamp-lit Victorian one-pager
   ========================================================================== */

:root {
  /* night */
  --ink: #0e1320;
  --ink-2: #151c2b;
  --ink-3: #1d2638;
  --mist: #a9b3c6;
  --moon: #e7e2d6;

  /* brass & light */
  --brass: #c9a45c;
  --brass-hi: #f0d391;
  --brass-lo: #8a6a2f;
  --lamp: #ffcd73;
  --lamp-glow: rgba(255, 196, 92, .55);

  /* estate */
  --verdigris: #4f9e8a;
  --verdigris-lo: #2f6b5c;
  --brick: #a4452f;
  --brick-lo: #6d2a1c;

  /* paper */
  --paper: #f4ecdb;
  --paper-2: #eadcbf;
  --paper-edge: #d8c49c;
  --sepia: #35261a;
  --sepia-2: #5d4632;

  --serif-display: "Cormorant Garamond", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --serif-body: "EB Garamond", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --caps: "Cinzel", "Trajan Pro", "Iowan Old Style", Georgia, serif;

  --wrap: 1160px;
  --radius: 14px;
  --nav-h: 64px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ink);
  color: var(--moon);
  font-family: var(--serif-body);
  font-size: clamp(1.06rem, .98rem + .3vw, 1.2rem);
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; line-height: 1.1; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
button { font: inherit; color: inherit; cursor: pointer; }
code, kbd {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: .82em;
}
code {
  padding: .1em .45em;
  border-radius: 6px;
  background: rgba(201, 164, 92, .14);
  border: 1px solid rgba(201, 164, 92, .3);
  white-space: nowrap;
}
kbd {
  display: inline-block;
  padding: .1em .5em .15em;
  border-radius: 6px;
  background: linear-gradient(#2a3346, #1b2232);
  border: 1px solid #3a4560;
  border-bottom-width: 3px;
  color: var(--brass-hi);
  line-height: 1.3;
  white-space: nowrap;
}
::selection { background: var(--lamp); color: var(--ink); }
:focus-visible { outline: 2px solid var(--lamp); outline-offset: 3px; border-radius: 6px; }

.skip {
  position: absolute; left: 1rem; top: -100px; z-index: 100;
  padding: .6rem 1rem; background: var(--lamp); color: var(--ink); border-radius: 8px; text-decoration: none;
}
.skip:focus { top: 1rem; }

.wrap { width: min(var(--wrap), 100% - 2.5rem); margin-inline: auto; }

.eyebrow {
  font-family: var(--caps);
  font-size: .78rem;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--brass);
  margin-bottom: .9rem;
}

.flourish { display: flex; align-items: center; gap: .9rem; justify-content: center; color: var(--brass); }
.flourish span { flex: none; height: 1px; width: min(120px, 20vw); background: linear-gradient(90deg, transparent, currentColor); }
.flourish span:last-child { transform: scaleX(-1); }
.flourish i { font-style: normal; font-size: 1.3rem; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  padding: .85rem 1.5rem;
  border-radius: 999px;
  font-family: var(--caps);
  font-size: .85rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s, color .25s;
}
.btn svg { width: 18px; height: 18px; fill: currentColor; }
.btn--brass {
  color: #2a1c0b;
  background: linear-gradient(180deg, var(--brass-hi), var(--brass) 55%, var(--brass-lo));
  box-shadow: 0 0 0 1px rgba(255,255,255,.25) inset, 0 10px 30px -10px var(--lamp-glow);
}
.btn--brass:hover { transform: translateY(-2px); box-shadow: 0 0 0 1px rgba(255,255,255,.35) inset, 0 16px 40px -10px var(--lamp-glow); }
.btn--ghost {
  color: var(--moon);
  background: rgba(14, 19, 32, .45);
  border-color: rgba(240, 211, 145, .45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.btn--ghost:hover { border-color: var(--lamp); color: var(--lamp); }
.btn--ghost[aria-pressed="true"] { color: var(--lamp); border-color: var(--lamp); box-shadow: 0 0 24px -6px var(--lamp-glow); }

/* ---------- lamps (section markers) ---------- */
.lamp {
  display: inline-block;
  width: .5em; height: .5em;
  margin-right: .5em;
  vertical-align: .18em;
  border-radius: 50%;
  background: #3b3f4a;
  box-shadow: inset 0 0 0 2px rgba(0,0,0,.25);
  transition: background .9s var(--ease), box-shadow .9s var(--ease);
}
.lamp.is-lit {
  background: radial-gradient(circle at 40% 35%, #fff6d8, var(--lamp) 45%, #e59a2f);
  box-shadow: 0 0 10px 2px var(--lamp-glow), 0 0 32px 6px rgba(255, 190, 80, .25);
  animation: flicker 5s infinite;
}
@keyframes flicker {
  0%, 100% { opacity: 1; }
  41% { opacity: 1; } 42% { opacity: .82; } 43% { opacity: 1; }
  77% { opacity: .92; } 78% { opacity: 1; }
}

/* ---------- nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 50;
  height: var(--nav-h);
  display: flex; align-items: center; gap: 1.5rem;
  padding: 0 clamp(1rem, 3vw, 2rem);
  transition: background .4s, box-shadow .4s, backdrop-filter .4s;
}
.nav.is-scrolled {
  background: rgba(14, 19, 32, .82);
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  box-shadow: 0 1px 0 rgba(201, 164, 92, .2);
}
.nav__brand {
  display: flex; align-items: center; gap: .55rem;
  text-decoration: none;
  font-family: var(--caps); font-weight: 700; letter-spacing: .16em; text-transform: uppercase; font-size: .95rem;
  color: var(--brass-hi);
}
.nav__mark { width: 22px; height: 22px; fill: var(--lamp); filter: drop-shadow(0 0 6px var(--lamp-glow)); }
.nav__links { display: flex; gap: 1.4rem; margin-left: auto; align-items: center; }
.nav__links a {
  font-family: var(--caps); font-size: .74rem; letter-spacing: .14em; text-transform: uppercase;
  text-decoration: none; color: rgba(231, 226, 214, .8);
  padding: .3rem 0; position: relative; white-space: nowrap;
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px;
  background: var(--lamp); transform: scaleX(0); transition: transform .3s var(--ease);
}
.nav__links a:hover, .nav__links a.is-active { color: var(--lamp); }
.nav__links a:hover::after, .nav__links a.is-active::after { transform: scaleX(1); }
.nav__links a.nav__cta {
  padding: .45rem .95rem; border: 1px solid rgba(240, 211, 145, .5); border-radius: 999px; color: var(--brass-hi);
}
.nav__links a.nav__cta::after { display: none; }
.nav__links a.nav__cta:hover { background: var(--brass); color: var(--ink); }
.nav__lamps {
  display: flex; align-items: center; gap: .5rem;
  font-size: .82rem; color: var(--mist); white-space: nowrap;
  padding-left: 1.2rem; border-left: 1px solid rgba(201, 164, 92, .25);
}
.nav__lamps b { color: var(--lamp); font-weight: 500; }
.nav__lamps-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--lamp); box-shadow: 0 0 10px var(--lamp-glow); }
.nav__lamps.is-complete { color: var(--lamp); }
.nav__toggle { display: none; }

.mobile-menu {
  position: fixed; inset: var(--nav-h) 0 auto; z-index: 49;
  display: grid; padding: .5rem 1.25rem 1.25rem;
  background: rgba(14, 19, 32, .97);
  border-bottom: 1px solid rgba(201, 164, 92, .25);
}
.mobile-menu[hidden] { display: none; }
.mobile-menu a {
  padding: .9rem 0; text-decoration: none;
  font-family: var(--caps); letter-spacing: .14em; text-transform: uppercase; font-size: .85rem;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.mobile-menu a:last-child { color: var(--lamp); border: 0; }

/* ---------- hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid; place-items: center;
  padding: calc(var(--nav-h) + 2rem) 1.25rem 6rem;
  overflow: hidden;
  isolation: isolate;
  text-align: center;
}
.hero__art { position: absolute; inset: 0; z-index: -4; }
.hero__art img {
  width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%;
  transform: scale(1.06);
  filter: brightness(.45) saturate(.55) hue-rotate(-8deg);
  transition: filter 2.6s var(--ease), transform 12s linear;
}
.hero__night {
  position: absolute; inset: 0; z-index: -3;
  background:
    radial-gradient(ellipse 80% 60% at 50% 42%, rgba(14, 19, 32, .25), rgba(14, 19, 32, .78) 70%),
    linear-gradient(180deg, rgba(14, 19, 32, .85) 0%, rgba(14, 19, 32, .25) 35%, rgba(14, 19, 32, .55) 75%, var(--ink) 100%);
  transition: opacity 2.6s var(--ease);
}
.hero__warm {
  position: absolute; inset: 0; z-index: -2; opacity: 0;
  background:
    radial-gradient(circle at 46% 58%, rgba(255, 190, 90, .35), transparent 30%),
    radial-gradient(circle at 24% 72%, rgba(255, 180, 80, .22), transparent 22%),
    radial-gradient(circle at 76% 62%, rgba(255, 180, 80, .22), transparent 24%);
  mix-blend-mode: screen;
  transition: opacity 2.6s var(--ease);
}
.hero__motes { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; pointer-events: none; }

.hero.is-lit .hero__art img { filter: brightness(.82) saturate(1.05); transform: scale(1); }
.hero.is-lit .hero__night { opacity: .78; }
.hero.is-lit .hero__warm { opacity: 1; animation: breathe 6s ease-in-out infinite 2.6s; }
@keyframes breathe { 50% { opacity: .78; } }

.hero__inner { max-width: 820px; position: relative; }
.hero__inner::before {
  content: ""; position: absolute; inset: -12% -18%; z-index: -1; pointer-events: none;
  background: radial-gradient(closest-side, rgba(10, 13, 22, .62), rgba(10, 13, 22, .35) 60%, transparent);
  opacity: 1 !important; transform: none !important; animation: none !important;
}
.hero__title {
  font-family: var(--caps);
  font-weight: 700;
  line-height: .92;
  margin-bottom: 1.1rem;
  text-transform: uppercase;
}
.hero__title span { display: block; }
.hero__title-a {
  font-size: clamp(3rem, 1.2rem + 9vw, 7.6rem);
  letter-spacing: .02em;
  background: linear-gradient(180deg, #fff3cf 0%, var(--brass-hi) 30%, var(--brass) 62%, var(--brass-lo) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 3px 0 #3a280f) drop-shadow(0 12px 28px rgba(0,0,0,.6));
}
.hero__title-b {
  font-size: clamp(1.4rem, .8rem + 3vw, 3rem);
  letter-spacing: .5em;
  margin-top: .3em;
  padding-left: .5em; /* balance tracking */
  color: var(--brass-hi);
  text-shadow: 0 2px 0 #3a280f, 0 10px 24px rgba(0,0,0,.6);
}
.hero__tagline {
  font-family: var(--serif-display);
  font-style: italic;
  font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.3rem);
  color: var(--lamp);
  margin: 1rem 0 1rem;
  text-shadow: 0 0 24px rgba(255, 190, 90, .35), 0 2px 10px rgba(0,0,0,.7);
}
.hero__lede {
  max-width: 600px; margin: 0 auto 2rem;
  color: rgba(231, 226, 214, .92);
  text-shadow: 0 1px 10px rgba(0,0,0,.8);
}
.hero__actions { display: flex; flex-wrap: wrap; gap: .9rem; justify-content: center; }

/* staged entrance */
.js .hero__inner > * { opacity: 0; transform: translateY(14px); animation: rise 1.1s var(--ease) forwards; }
.js .hero__inner > :nth-child(1) { animation-delay: .2s; }
.js .hero__inner > :nth-child(2) { animation-delay: .4s; }
.js .hero__inner > :nth-child(3) { animation-delay: .7s; }
.js .hero__inner > :nth-child(4) { animation-delay: 1.6s; }
.js .hero__inner > :nth-child(5) { animation-delay: 1.9s; }
.js .hero__inner > :nth-child(6) { animation-delay: 2.1s; }
@keyframes rise { to { opacity: 1; transform: none; } }

.hero__scroll {
  position: absolute; bottom: 1.5rem; left: 50%; transform: translateX(-50%);
  display: grid; justify-items: center; gap: .2rem;
  font-family: var(--caps); font-size: .68rem; letter-spacing: .24em; text-transform: uppercase;
  color: rgba(231, 226, 214, .7); text-decoration: none;
}
.hero__scroll svg { width: 22px; height: 22px; fill: none; stroke: var(--brass); stroke-width: 2; animation: nudge 2.4s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateY(5px); } }

/* ---------- sections ---------- */
.section { position: relative; padding: clamp(4.5rem, 3rem + 6vw, 8rem) 0; }
.section__head { max-width: 760px; margin: 0 auto clamp(2.5rem, 2rem + 2vw, 3.75rem); text-align: center; }
.section__head h2 {
  font-family: var(--serif-display);
  font-size: clamp(2.2rem, 1.5rem + 3vw, 3.7rem);
  font-weight: 600;
  letter-spacing: -.005em;
  margin-bottom: 1rem;
}
.section__intro { font-size: 1.12em; opacity: .85; max-width: 620px; margin-inline: auto; }

.section--night {
  background:
    radial-gradient(ellipse 60% 40% at 15% 0%, rgba(79, 158, 138, .10), transparent 70%),
    radial-gradient(ellipse 50% 40% at 90% 100%, rgba(201, 164, 92, .09), transparent 70%),
    var(--ink);
}
.section--night::before {
  /* faint stars */
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .45;
  background-image:
    radial-gradient(1px 1px at 12% 18%, #fff, transparent),
    radial-gradient(1px 1px at 72% 12%, #fff, transparent),
    radial-gradient(1px 1px at 38% 42%, #fff, transparent),
    radial-gradient(1px 1px at 88% 36%, #fff, transparent),
    radial-gradient(1px 1px at 22% 78%, #fff, transparent),
    radial-gradient(1px 1px at 58% 88%, #fff, transparent),
    radial-gradient(1.5px 1.5px at 92% 72%, #fff, transparent),
    radial-gradient(1px 1px at 5% 55%, #fff, transparent);
  background-size: 700px 700px;
}
.section--night .eyebrow { color: var(--brass); }

.section--paper {
  color: var(--sepia);
  background:
    radial-gradient(ellipse at 20% 0%, rgba(255,255,255,.55), transparent 55%),
    radial-gradient(ellipse at 100% 100%, rgba(193, 160, 100, .22), transparent 60%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .35 0 0 0 0 .25 0 0 0 0 .12 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"),
    var(--paper);
}
.section--paper .eyebrow { color: var(--brick); }
.section--paper .lamp:not(.is-lit) { background: #c8b896; }
.section--paper code { background: rgba(164, 69, 47, .08); border-color: rgba(164, 69, 47, .25); color: var(--brick-lo); }

/* scallop between sections */
.section--paper + .section--night::after,
.section--night + .section--paper::after { display: none; }

/* ---------- reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(26px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------- invitation ---------- */
.invitation { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: clamp(2rem, 4vw, 3.5rem); align-items: start; }
.letter {
  position: relative;
  padding: clamp(2rem, 1.5rem + 2.5vw, 3.5rem);
  background: linear-gradient(180deg, #fbf6ea, #f3e8cf);
  border: 1px solid var(--paper-edge);
  border-radius: 4px;
  box-shadow: 0 1px 0 #fff inset, 0 30px 60px -30px rgba(70, 45, 15, .45), 0 2px 6px rgba(70, 45, 15, .12);
  transform: rotate(-.4deg);
}
.js .letter.reveal.is-in { transform: rotate(-.4deg); }
.letter::before {
  content: ""; position: absolute; inset: 10px; border: 1px solid rgba(164, 69, 47, .22); pointer-events: none;
}
.letter__seal {
  position: absolute; top: -26px; right: 34px;
  width: 64px; height: 64px; border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--caps); font-size: 1.6rem; font-weight: 700; color: rgba(255, 220, 200, .85);
  background: radial-gradient(circle at 35% 30%, #c4553c, #8e2a1a 60%, #5c170c);
  box-shadow: 0 6px 14px rgba(80, 20, 10, .45), inset 0 -4px 8px rgba(0,0,0,.3);
  text-shadow: 0 -1px 0 rgba(0,0,0,.4);
}
.letter__seal::after {
  content: ""; position: absolute; inset: 6px; border-radius: 50%; border: 2px dashed rgba(255, 210, 190, .3);
}
.letter__kicker { font-family: var(--caps); font-size: .72rem; letter-spacing: .24em; text-transform: uppercase; color: var(--brick); }
.letter__title { font-family: var(--serif-display); font-size: clamp(2rem, 1.5rem + 2vw, 2.9rem); margin-bottom: 1.4rem; }
.letter__quote {
  margin: 0 0 1.6rem; padding: 1.2rem 1.4rem;
  border-left: 3px solid var(--brass);
  background: rgba(201, 164, 92, .1);
  font-family: var(--serif-display); font-style: italic; font-size: 1.32em; line-height: 1.4;
}
.letter__quote footer { margin-top: .6rem; font-family: var(--caps); font-style: normal; font-size: .7rem; letter-spacing: .2em; text-transform: uppercase; color: var(--sepia-2); }
.letter__sign { margin-top: 1.8rem; font-style: italic; }
.letter__sign span { font-family: var(--serif-display); font-size: 1.45em; font-style: italic; color: var(--brick-lo); }

.particulars {
  position: sticky; top: calc(var(--nav-h) + 1.5rem);
  padding: 1.8rem;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--moon);
  box-shadow: 0 30px 60px -30px rgba(20, 15, 5, .6);
  border: 1px solid rgba(201, 164, 92, .3);
}
.particulars__title { font-family: var(--caps); font-size: .8rem; letter-spacing: .26em; text-transform: uppercase; color: var(--brass); margin-bottom: 1rem; }
.particulars dl { margin: 0; display: grid; gap: 0; }
.particulars dl div { display: grid; grid-template-columns: 6.2rem 1fr; gap: .8rem; padding: .62rem 0; border-bottom: 1px dashed rgba(201, 164, 92, .2); }
.particulars dt { font-family: var(--caps); font-size: .7rem; letter-spacing: .16em; text-transform: uppercase; color: var(--mist); padding-top: .25em; }
.particulars dd { margin: 0; }
.counter { color: var(--lamp); font-weight: 500; }
.particulars__pillars { display: grid; gap: .8rem; margin-top: 1.4rem; }
.particulars__pillars div { display: grid; grid-template-columns: auto 1fr; gap: .7rem; align-items: baseline; }
.particulars__pillars b {
  font-family: var(--serif-display); font-style: italic; font-weight: 600; font-size: 1.3em; color: var(--lamp);
  min-width: 5.2rem;
}
.particulars__pillars span { color: rgba(231, 226, 214, .82); font-size: .95em; }

/* ---------- history ---------- */
.timeline {
  list-style: none; margin: 0 0 4rem; padding: 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem;
  position: relative;
}
.timeline::before {
  content: ""; position: absolute; left: 8%; right: 8%; top: 32px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--brass), transparent);
}
.timeline__item { text-align: center; padding: 0 .75rem; position: relative; }
.timeline__gen {
  display: grid; place-items: center; margin: 0 auto 1.2rem;
  width: 64px; height: 64px; border-radius: 50%;
  font-family: var(--caps); font-weight: 700; color: var(--brass-hi);
  background: var(--ink-2);
  border: 1px solid var(--brass);
  box-shadow: 0 0 0 6px var(--ink), 0 0 30px -8px var(--lamp-glow);
  position: relative;
}
.timeline__item h3 { font-family: var(--serif-display); font-size: 2rem; }
.timeline__role { font-family: var(--caps); font-size: .7rem; letter-spacing: .24em; text-transform: uppercase; color: var(--verdigris); margin: .35rem 0 .8rem; }
.timeline__item p:last-child { color: rgba(231, 226, 214, .82); }
.timeline__item:nth-child(3) .timeline__gen { border-color: var(--lamp); color: var(--lamp); }

.closing {
  display: grid; grid-template-columns: 1.5fr 1fr; gap: clamp(2rem, 4vw, 4rem); align-items: center;
  padding: clamp(2rem, 4vw, 3.5rem);
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--ink-2), var(--ink-3));
  border: 1px solid rgba(201, 164, 92, .18);
  margin-bottom: 3rem;
}
.closing__text { font-size: 1.05em; color: rgba(231, 226, 214, .9); }
.closing__text strong { color: var(--lamp); font-weight: 500; }
.closing__dropcap { font-family: var(--serif-display); font-size: 1.55em; line-height: 1.3; color: var(--moon); }
.closing__dropcap::first-letter {
  float: left; font-family: var(--caps); font-size: 3.4em; line-height: .8; padding: .08em .12em 0 0; color: var(--brass-hi);
}
.closing__note {
  margin: 0; text-align: center;
  padding: 2rem 1.5rem;
  background: linear-gradient(180deg, #f6eedc, #e9dbbb);
  color: var(--sepia);
  border-radius: 3px;
  transform: rotate(1.6deg);
  box-shadow: 0 20px 40px -18px rgba(0,0,0,.7);
  position: relative;
}
.closing__note::before {
  /* pin */
  content: ""; position: absolute; top: -9px; left: 50%; width: 18px; height: 18px; margin-left: -9px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #e7c27a, #8a6a2f); box-shadow: 0 3px 5px rgba(0,0,0,.5);
}
.closing__note p { font-family: var(--serif-display); font-style: italic; font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.1rem); line-height: 1.2; margin-bottom: .8rem; }
.closing__note figcaption { font-family: var(--caps); font-size: .66rem; letter-spacing: .22em; text-transform: uppercase; color: var(--sepia-2); }

.ledger {
  padding: clamp(1.6rem, 3vw, 2.5rem);
  border-radius: var(--radius);
  border: 1px solid rgba(79, 158, 138, .35);
  background:
    repeating-linear-gradient(0deg, transparent 0 31px, rgba(79, 158, 138, .08) 31px 32px),
    rgba(14, 19, 32, .6);
}
.ledger__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: .5rem 2rem; margin-bottom: 1.4rem; }
.ledger__head h3 { font-family: var(--caps); font-size: 1.05rem; letter-spacing: .2em; text-transform: uppercase; color: var(--verdigris); }
.ledger__head p { margin: 0; color: var(--mist); font-size: .95em; }
.ledger__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; }
.machine {
  width: 100%; display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: .9rem; align-items: center;
  text-align: left; padding: .9rem 1rem;
  border-radius: 10px;
  background: rgba(29, 38, 56, .7);
  border: 1px solid rgba(255,255,255,.06);
  transition: border-color .3s, background .3s, transform .2s;
}
.machine:hover { border-color: rgba(201, 164, 92, .5); transform: translateY(-2px); }
.machine__gear {
  grid-row: span 2;
  width: 34px; height: 34px;
  background: var(--mist);
  opacity: .5;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M10.3 1h3.4l.5 2.6 1.9.8 2.2-1.5 2.4 2.4-1.5 2.2.8 1.9 2.6.5v3.4l-2.6.5-.8 1.9 1.5 2.2-2.4 2.4-2.2-1.5-1.9.8-.5 2.6h-3.4l-.5-2.6-1.9-.8-2.2 1.5-2.4-2.4 1.5-2.2-.8-1.9L1 13.7v-3.4l2.6-.5.8-1.9-1.5-2.2 2.4-2.4 2.2 1.5 1.9-.8zM12 8a4 4 0 100 8 4 4 0 000-8z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M10.3 1h3.4l.5 2.6 1.9.8 2.2-1.5 2.4 2.4-1.5 2.2.8 1.9 2.6.5v3.4l-2.6.5-.8 1.9 1.5 2.2-2.4 2.4-2.2-1.5-1.9.8-.5 2.6h-3.4l-.5-2.6-1.9-.8-2.2 1.5-2.4-2.4 1.5-2.2-.8-1.9L1 13.7v-3.4l2.6-.5.8-1.9-1.5-2.2 2.4-2.4 2.2 1.5 1.9-.8zM12 8a4 4 0 100 8 4 4 0 000-8z'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: background .4s, opacity .4s;
}
.machine__name { font-family: var(--serif-display); font-size: 1.2em; font-weight: 600; line-height: 1.2; }
.machine__state { font-family: var(--caps); font-size: .64rem; letter-spacing: .2em; text-transform: uppercase; color: var(--mist); }
.machine.is-stirring .machine__gear { animation: stir 1.4s var(--ease); background: var(--brass); opacity: 1; }
.machine.is-stirring .machine__state { color: var(--brass-hi); }
@keyframes stir { 0% { transform: rotate(0); } 60% { transform: rotate(80deg); } 80% { transform: rotate(64deg); } 100% { transform: rotate(70deg); } }
.ledger__foot { margin: 1.2rem 0 0; color: var(--mist); font-style: italic; font-size: .95em; min-height: 1.6em; }

/* ---------- who ---------- */
.heir {
  display: grid; grid-template-columns: auto 1fr; gap: clamp(1.25rem, 3vw, 2.5rem); align-items: center;
  max-width: 860px; margin: 0 auto 3rem;
  padding: clamp(1.5rem, 3vw, 2.4rem);
  background: linear-gradient(135deg, var(--ink), var(--ink-3));
  color: var(--moon);
  border-radius: var(--radius);
  border: 1px solid rgba(201, 164, 92, .4);
  box-shadow: 0 30px 60px -30px rgba(40, 25, 5, .6);
}
.heir__crest { width: clamp(70px, 10vw, 100px); color: var(--brass); filter: drop-shadow(0 0 18px rgba(255, 190, 90, .25)); }
.heir__kicker { font-family: var(--caps); font-size: .7rem; letter-spacing: .24em; text-transform: uppercase; color: var(--verdigris); margin-bottom: .4rem; }
.heir h3 { font-family: var(--serif-display); font-size: clamp(2rem, 1.6rem + 1.5vw, 2.7rem); color: var(--brass-hi); margin-bottom: .6rem; }
.heir p:last-child { color: rgba(231, 226, 214, .88); }

.who__lead { text-align: center; font-family: var(--serif-display); font-style: italic; font-size: 1.4em; margin-bottom: 2rem; }
.envelopes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; perspective: 1200px; }
.envelope {
  position: relative; aspect-ratio: 4 / 3; min-height: 150px;
  border: 0; padding: 0; background: none;
  perspective: 1000px;
}
.envelope__inner {
  position: absolute; inset: 0; display: block;
  transform-style: preserve-3d;
  transition: transform .9s var(--ease);
}
.envelope[aria-expanded="true"] .envelope__inner { transform: rotateY(180deg); }
.envelope__front, .envelope__back {
  position: absolute; inset: 0; border-radius: 6px;
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  display: grid; place-items: center; align-content: center; gap: .6rem;
  padding: 1rem;
}
.envelope__front {
  background:
    linear-gradient(155deg, transparent 49.5%, rgba(120, 85, 40, .22) 50%, transparent 50.6%),
    linear-gradient(-155deg, transparent 49.5%, rgba(120, 85, 40, .22) 50%, transparent 50.6%),
    linear-gradient(180deg, #f7efdc, #e6d5b1);
  border: 1px solid var(--paper-edge);
  box-shadow: 0 18px 30px -16px rgba(70, 45, 15, .55);
}
.envelope:hover .envelope__front { box-shadow: 0 24px 38px -16px rgba(70, 45, 15, .65); }
.envelope__wax {
  width: 58px; height: 58px; border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--caps); font-weight: 700; font-size: 1rem; color: rgba(255, 220, 200, .9);
  background: radial-gradient(circle at 35% 30%, #c4553c, #8e2a1a 60%, #5c170c);
  box-shadow: 0 4px 10px rgba(80, 20, 10, .45), inset 0 -3px 6px rgba(0,0,0,.3);
  transition: transform .3s var(--ease);
}
.envelope:hover .envelope__wax { transform: scale(1.08) rotate(-6deg); }
.envelope__hint { font-family: var(--caps); font-size: .62rem; letter-spacing: .22em; text-transform: uppercase; color: var(--sepia-2); }
.envelope__back {
  transform: rotateY(180deg);
  background: linear-gradient(160deg, var(--ink-2), var(--ink-3));
  border: 1px solid var(--brass);
  color: var(--brass-hi);
  font-family: var(--serif-display); font-style: italic; font-size: 1.35em; line-height: 1.25; text-align: center;
}
.envelope__num {
  position: absolute; top: -12px; left: 14px; z-index: 2;
  font-family: var(--caps); font-size: .7rem; letter-spacing: .14em;
  padding: .15rem .6rem; border-radius: 999px; background: var(--brick); color: #fbeee6;
  transform: translateZ(1px);
}
.envelope[aria-expanded="true"] .envelope__num { opacity: 0; }
.who__warning {
  margin: 2.5rem auto 0; text-align: center; max-width: 560px;
  padding: .9rem 1.4rem; border-radius: 999px;
  border: 1px dashed rgba(164, 69, 47, .45); color: var(--brick-lo);
}

/* ---------- villages ---------- */
.tabs { display: none; }
.villages { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
.village {
  --accent: var(--brass);
  position: relative;
  padding: 2rem 1.75rem 1.9rem;
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(29, 38, 56, .9), rgba(21, 28, 43, .9));
  border: 1px solid rgba(255,255,255,.07);
  border-top: 3px solid var(--accent);
  overflow: hidden;
}
.village::before {
  content: ""; position: absolute; right: -40px; top: -40px; width: 160px; height: 160px; border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--accent) 30%, transparent), transparent 70%);
  pointer-events: none;
}
.village--alderwick { --accent: var(--brass); }
.village--bramblemead { --accent: #e08a5a; }
.village--ironmere { --accent: #7fa6c9; }
.village__kind { font-family: var(--caps); font-size: .64rem; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); margin-bottom: .4rem; }
.village h3 { font-family: var(--serif-display); font-size: 2.3rem; margin-bottom: 1.1rem; }
.village h4 { font-family: var(--caps); font-size: .7rem; letter-spacing: .22em; text-transform: uppercase; color: var(--mist); margin: 1.4rem 0 .6rem; }
.village > p { color: rgba(231, 226, 214, .86); }
.festivals { list-style: none; margin: 0; padding: 0; display: grid; gap: .55rem; }
.festivals li { padding-left: 1.4rem; position: relative; color: rgba(231, 226, 214, .82); }
.festivals li::before { content: "✦"; position: absolute; left: 0; top: .05em; color: var(--accent); font-size: .85em; }
.festivals b { display: block; color: var(--moon); font-weight: 500; font-family: var(--serif-display); font-size: 1.2em; }
.village__slang { margin-top: 1.3rem; padding-top: 1rem; border-top: 1px dashed rgba(255,255,255,.12); font-style: italic; color: var(--mist) !important; }
.village__slang q { color: var(--accent); font-style: normal; }

.regard { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .8rem; padding: .7rem .9rem; border-radius: 10px; background: rgba(0,0,0,.25); margin-bottom: 1.2rem; }
.regard__label { font-family: var(--caps); font-size: .6rem; letter-spacing: .18em; text-transform: uppercase; color: var(--mist); }
.regard__bar { height: 6px; border-radius: 6px; position: relative; background: linear-gradient(90deg, #6f9bc9, #9d9d9d 50%, #e9934f); opacity: .35; }
.regard__bar i {
  position: absolute; top: 50%; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%;
  background: #fff; box-shadow: 0 0 0 3px var(--ink), 0 0 12px rgba(255,255,255,.6);
  left: 50%;
  transition: left 1.4s var(--ease) .3s;
}
.regard { position: relative; }
.regard__bar { opacity: 1; background: linear-gradient(90deg, rgba(111,155,201,.55), rgba(157,157,157,.35) 50%, rgba(233,147,79,.6)); }
.js .village:not(.is-in) .regard__bar i { left: 50% !important; }
.regard[data-mood="divided"] .regard__bar i { left: 50%; animation: waver 3s ease-in-out infinite; }
.regard[data-mood="warm"] .regard__bar i { left: 80%; }
.regard[data-mood="cold"] .regard__bar i { left: 14%; }
@keyframes waver { 0%, 100% { transform: translateX(-10px); } 50% { transform: translateX(10px); } }
.regard__value { font-family: var(--serif-display); font-style: italic; font-weight: 600; font-size: 1.15em; color: var(--accent); }

.fair {
  margin-top: 2.5rem;
  display: grid; grid-template-columns: auto 1fr; gap: 1.5rem; align-items: center;
  padding: 1.6rem 2rem;
  border-radius: var(--radius);
  background: radial-gradient(ellipse at 0% 50%, rgba(240, 211, 145, .14), transparent 60%), rgba(29, 38, 56, .5);
  border: 1px solid rgba(240, 211, 145, .25);
}
.fair__apple { width: 72px; filter: drop-shadow(0 0 18px rgba(240, 200, 100, .5)); animation: bob 4s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-5px) rotate(4deg); } }
.fair h3 { font-family: var(--serif-display); font-size: 1.8rem; color: var(--brass-hi); margin-bottom: .4rem; }
.fair p { color: rgba(231, 226, 214, .86); }
.fair strong { color: var(--lamp); font-weight: 500; }

/* ---------- people ---------- */
.filters { display: flex; flex-wrap: wrap; justify-content: center; gap: .55rem; margin-bottom: 2.2rem; }
.chip {
  padding: .45rem 1rem; border-radius: 999px;
  border: 1px solid rgba(53, 38, 26, .25); background: rgba(255,255,255,.4);
  font-family: var(--caps); font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--sepia-2);
  transition: background .25s, color .25s, border-color .25s;
}
.chip:hover { border-color: var(--brick); color: var(--brick); }
.chip.is-on { background: var(--sepia); color: var(--paper); border-color: var(--sepia); }

.cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1.2rem; }
.card {
  position: relative;
  padding: 1.6rem 1.5rem 1.5rem;
  background: linear-gradient(180deg, #fffaf0, #f2e6cc);
  border: 1px solid var(--paper-edge);
  border-radius: 6px;
  box-shadow: 0 14px 30px -18px rgba(70, 45, 15, .5);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), opacity .4s;
}
.card::before { content: ""; position: absolute; inset: 6px; border: 1px solid rgba(164, 69, 47, .16); border-radius: 3px; pointer-events: none; }
.card:hover { transform: translateY(-4px) rotate(-.5deg); box-shadow: 0 24px 40px -18px rgba(70, 45, 15, .6); }
.js .card.reveal.is-in:hover { transform: translateY(-4px) rotate(-.5deg); }
.card[hidden] { display: none; }
.card__mono {
  display: grid; place-items: center; width: 48px; height: 48px; margin-bottom: 1rem;
  border-radius: 50%;
  font-family: var(--caps); font-size: .85rem; font-weight: 700; letter-spacing: .06em;
  color: var(--brass-hi); background: var(--ink); box-shadow: 0 0 0 3px #fffaf0, 0 0 0 4px var(--brass);
}
.card h3 { font-family: var(--serif-display); font-size: 1.65rem; }
.card__role { font-family: var(--caps); font-size: .64rem; letter-spacing: .18em; text-transform: uppercase; color: var(--brick); margin: .35rem 0 .8rem; }
.card p:last-child { color: var(--sepia-2); }
.card[data-place="bramblemead"] .card__mono { color: #ffd2b8; }
.card[data-place="ironmere"] .card__mono { color: #cfe0f0; }
.card--feature { background: linear-gradient(180deg, #1b2335, var(--ink)); border-color: var(--brass); color: var(--moon); }
.card--feature::before { border-color: rgba(201, 164, 92, .35); }
.card--feature .card__mono { background: var(--brass); color: var(--ink); box-shadow: 0 0 0 3px var(--ink), 0 0 0 4px var(--brass), 0 0 24px var(--lamp-glow); }
.card--feature .card__role { color: var(--lamp); }
.card--feature p:last-child { color: rgba(231, 226, 214, .85); }
.card__tag {
  position: absolute; top: 1.2rem; right: 1.2rem;
  font-family: var(--caps); font-size: .6rem; letter-spacing: .2em; text-transform: uppercase;
  padding: .25rem .6rem; border-radius: 999px; background: var(--lamp); color: var(--ink);
  box-shadow: 0 0 16px var(--lamp-glow);
}

/* ---------- customs ---------- */
.customs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.4rem; }
.custom {
  padding: clamp(1.6rem, 3vw, 2.2rem);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(29, 38, 56, .85), rgba(21, 28, 43, .85));
  border: 1px solid rgba(255,255,255,.07);
  transition: border-color .4s;
}
.custom:hover { border-color: rgba(201, 164, 92, .35); }
.custom__icon { width: 48px; height: 48px; color: var(--brass); margin-bottom: 1rem; }
.custom h3 { font-family: var(--serif-display); font-size: 1.8rem; margin-bottom: 1rem; }
.ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: .7rem; }
.ticks li { position: relative; padding-left: 1.6rem; color: rgba(231, 226, 214, .86); }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: .62em; width: 8px; height: 8px; transform: rotate(45deg);
  background: var(--verdigris); box-shadow: 0 0 8px rgba(79, 158, 138, .6);
}
.ticks strong { color: var(--lamp); font-weight: 500; }

.skillbar { display: grid; grid-template-columns: auto 1fr auto; gap: .8rem; align-items: center; margin-bottom: 1.2rem; font-family: var(--caps); font-size: .7rem; letter-spacing: .12em; color: var(--mist); }
.skillbar b { color: var(--lamp); font-weight: 500; display: inline-block; min-width: 2ch; }
.skillbar__track { height: 8px; border-radius: 8px; background: rgba(0,0,0,.35); overflow: hidden; box-shadow: inset 0 0 0 1px rgba(255,255,255,.06); }
.skillbar__track i { display: block; height: 100%; width: 2%; border-radius: 8px; background: linear-gradient(90deg, var(--verdigris), var(--brass-hi)); box-shadow: 0 0 12px rgba(240, 211, 145, .5); transition: width .2s linear; }

.salvage {
  margin-top: 1.4rem;
  padding: clamp(1.6rem, 3vw, 2.4rem);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(109, 42, 28, .22), rgba(21, 28, 43, .9));
  border: 1px solid rgba(164, 69, 47, .35);
}
.salvage__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: .5rem 2rem; margin-bottom: 1.4rem; }
.salvage__head h3 { font-family: var(--serif-display); font-size: 1.8rem; }
.salvage__head p { margin: 0; color: var(--mist); }
.placard-chip { display: inline-block; padding: 0 .5em; background: #f5f1e6; color: var(--ink); border-radius: 3px; font-weight: 500; }
.placards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.placard {
  display: grid; gap: .35rem; align-content: start;
  padding: 1.1rem 1.1rem 1rem;
  background: linear-gradient(180deg, #faf7ee, #e9e3d2);
  color: var(--ink);
  border-radius: 4px;
  box-shadow: 0 0 0 4px #c9c0a8, 0 0 0 5px #8e866f, 0 16px 28px -14px rgba(0,0,0,.7);
  margin: 5px;
  position: relative;
  transform: rotate(var(--tilt, 0deg));
  transition: transform .3s var(--ease);
}
.placard:nth-child(1) { --tilt: -1.2deg; }
.placard:nth-child(2) { --tilt: .8deg; }
.placard:nth-child(3) { --tilt: -.5deg; }
.placard:nth-child(4) { --tilt: 1.3deg; }
.placard:hover { transform: rotate(0) translateY(-3px); }
.placard::before, .placard::after {
  content: ""; position: absolute; top: 8px; width: 6px; height: 6px; border-radius: 50%; background: #777064; box-shadow: inset 0 1px 1px rgba(0,0,0,.5);
}
.placard::before { left: 8px; } .placard::after { right: 8px; }
.placard__name { font-family: var(--serif-display); font-weight: 600; font-size: 1.3rem; line-height: 1.15; margin-top: .3rem; }
.placard__warn { font-size: .95rem; color: #4a4336; font-style: italic; }
.placard__danger { display: flex; gap: 4px; margin-top: .4rem; }
.placard__danger i { width: 18px; height: 6px; border-radius: 3px; background: rgba(0,0,0,.12); }
.placard[data-danger="1"] .placard__danger i:nth-child(-n+1),
.placard[data-danger="2"] .placard__danger i:nth-child(-n+2) { background: #c58a2c; }
.placard[data-danger="3"] .placard__danger i { background: var(--brick); }
.placard--grim { background: linear-gradient(180deg, #f1ebe0, #d8cfbf); }
.placard--grim .placard__warn { color: var(--brick-lo); font-weight: 500; }

/* ---------- getting started ---------- */
.steps { list-style: none; margin: 0 auto 3rem; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.3rem; counter-reset: s; }
.step {
  display: grid; grid-template-columns: auto 1fr; gap: 1.2rem;
  padding: 1.7rem 1.6rem;
  background: rgba(255, 252, 244, .7);
  border: 1px solid var(--paper-edge);
  border-radius: var(--radius);
  box-shadow: 0 14px 30px -22px rgba(70, 45, 15, .55);
}
.step__num {
  width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center;
  font-family: var(--caps); font-weight: 700; font-size: 1.3rem;
  color: var(--ink);
  background: radial-gradient(circle at 35% 30%, var(--brass-hi), var(--brass) 60%, var(--brass-lo));
  box-shadow: 0 6px 14px -6px rgba(120, 80, 20, .7), inset 0 1px 0 rgba(255,255,255,.5);
}
.step h3 { font-family: var(--serif-display); font-size: 1.65rem; margin: .2rem 0 .5rem; }
.step p { color: var(--sepia-2); }
.step strong { color: var(--sepia); }
.step__note { font-size: .95em; padding: .55rem .8rem; border-left: 3px solid var(--verdigris); background: rgba(79, 158, 138, .1); border-radius: 0 6px 6px 0; }

.pocket {
  max-width: 900px; margin: 0 auto;
  padding: clamp(1.6rem, 3vw, 2.2rem);
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--moon);
  box-shadow: 0 30px 60px -30px rgba(40, 25, 5, .6);
  border: 1px solid rgba(201, 164, 92, .35);
}
.pocket h3 { font-family: var(--caps); font-size: .8rem; letter-spacing: .26em; text-transform: uppercase; color: var(--brass); margin-bottom: 1.2rem; text-align: center; }
.pocket__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: .9rem 1.6rem; }
.pocket__list li { display: grid; grid-template-columns: 9.6rem 1fr; align-items: center; gap: .9rem; justify-items: start; color: rgba(231, 226, 214, .85); font-size: .98em; }
.kbd--big { font-size: 1.1rem; min-width: 2.6rem; text-align: center; padding: .25em .6em .3em; }
.copy {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: 0; border: 0; background: none; color: inherit; position: relative;
}
.copy code { font-size: .9rem; color: var(--brass-hi); background: rgba(201, 164, 92, .12); border-color: rgba(201, 164, 92, .35); padding: .35em .7em; transition: background .2s, border-color .2s; }
.copy:hover code { background: rgba(201, 164, 92, .24); border-color: var(--brass); }
.copy__hint { font-family: var(--caps); font-size: .58rem; letter-spacing: .16em; text-transform: uppercase; color: var(--mist); opacity: 0; transition: opacity .2s; }
.copy:hover .copy__hint, .copy:focus-visible .copy__hint { opacity: 1; }

/* ---------- finale ---------- */
.finale {
  position: relative;
  display: grid; grid-template-columns: minmax(0, 520px) minmax(0, 1fr); gap: clamp(2rem, 5vw, 5rem); align-items: center;
  padding: clamp(4rem, 3rem + 5vw, 7rem) max(1.25rem, calc((100% - var(--wrap)) / 2));
  background:
    radial-gradient(ellipse 50% 70% at 25% 50%, rgba(255, 190, 90, .16), transparent 70%),
    var(--ink);
  overflow: hidden;
}
.finale__art img {
  width: 100%; height: auto; border-radius: 10px;
  box-shadow: 0 0 0 1px rgba(201, 164, 92, .5), 0 0 0 10px var(--ink-2), 0 0 0 11px rgba(201, 164, 92, .3), 0 40px 80px -20px rgba(0,0,0,.8), 0 0 120px -20px var(--lamp-glow);
}
.finale__text h2 { font-family: var(--serif-display); font-style: italic; font-size: clamp(2.2rem, 1.6rem + 2.6vw, 3.6rem); line-height: 1.08; color: var(--brass-hi); margin-bottom: 1.2rem; }
.finale__text p { font-size: 1.15em; color: rgba(231, 226, 214, .88); margin-bottom: 2rem; max-width: 460px; }

/* ---------- footer ---------- */
.footer {
  padding: 2.5rem 1.25rem 3rem; text-align: center;
  background: #0a0e18;
  color: var(--mist); font-size: .9rem;
  border-top: 1px solid rgba(201, 164, 92, .15);
}
.footer p { max-width: 640px; margin: 1.1rem auto 0; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 1.5rem; z-index: 60;
  transform: translate(-50%, 140%);
  padding: .75rem 1.2rem; border-radius: 999px;
  background: var(--ink-3); color: var(--moon);
  border: 1px solid var(--brass);
  box-shadow: 0 16px 40px -10px rgba(0,0,0,.7), 0 0 30px -10px var(--lamp-glow);
  font-size: .95rem;
  transition: transform .45s var(--ease);
  max-width: calc(100% - 2rem);
  text-align: center;
}
.toast.is-on { transform: translate(-50%, 0); }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1180px) {
  .nav__links { gap: 1rem; }
  .nav__lamps { display: none; }
}
@media (max-width: 1100px) {
  .nav__links { display: none; }
  .nav__lamps { display: flex; margin-left: auto; border-left: 0; padding-left: 0; }
  .nav__toggle {
    display: grid; gap: 5px; place-content: center;
    width: 44px; height: 44px; border-radius: 10px;
    border: 1px solid rgba(201, 164, 92, .35); background: rgba(14, 19, 32, .5);
  }
  .nav__toggle span { display: block; width: 20px; height: 2px; background: var(--brass-hi); border-radius: 2px; transition: transform .3s, opacity .3s; }
  .nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

}
@media (max-width: 1020px) {
  .invitation { grid-template-columns: 1fr; }
  .particulars { position: static; }
  .closing { grid-template-columns: 1fr; }
  .closing__note { max-width: 420px; margin-inline: auto; }
  .ledger__list { grid-template-columns: repeat(2, 1fr); }
  .envelopes { grid-template-columns: repeat(2, 1fr); }
  .placards { grid-template-columns: repeat(2, 1fr); }

  /* villages become tabs */
  .tabs {
    display: flex; gap: .4rem; justify-content: center; margin-bottom: 1.4rem;
    padding: .35rem; border-radius: 999px; background: rgba(29, 38, 56, .8); border: 1px solid rgba(255,255,255,.08);
    width: fit-content; margin-inline: auto; max-width: 100%;
  }
  .tab {
    border: 0; background: none; padding: .6rem 1.1rem; border-radius: 999px;
    font-family: var(--caps); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--mist);
  }
  .tab[aria-selected="true"] { background: var(--brass); color: var(--ink); }
  .villages { grid-template-columns: 1fr; max-width: 640px; margin-inline: auto; }
  .js .village.is-tab-hidden { display: none; }
}
@media (max-width: 760px) {
  .timeline { grid-template-columns: 1fr; gap: 2.2rem; }
  .timeline::before { left: 50%; right: auto; top: 0; bottom: 0; width: 1px; height: auto; background: linear-gradient(180deg, transparent, var(--brass), transparent); }
  .timeline__item { background: var(--ink); padding: .5rem 0; }
  .customs { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .pocket__list { grid-template-columns: 1fr; }
  .finale { grid-template-columns: 1fr; text-align: center; }
  .finale__art { max-width: 420px; margin-inline: auto; }
  .finale__text p { margin-inline: auto; }
  .heir { grid-template-columns: 1fr; text-align: center; justify-items: center; }
  .fair { grid-template-columns: 1fr; text-align: center; justify-items: center; }
  .particulars dl div { grid-template-columns: 5.4rem 1fr; }
}
@media (max-width: 520px) {
  .wrap { width: calc(100% - 2rem); }
  .ledger__list { grid-template-columns: 1fr; }
  .envelopes { grid-template-columns: 1fr; max-width: 340px; margin-inline: auto; }
  .placards { grid-template-columns: 1fr; }
  .hero__actions .btn { width: 100%; justify-content: center; }
  .hero__title-b { letter-spacing: .35em; padding-left: .35em; }
  .letter__seal { right: 20px; width: 54px; height: 54px; top: -22px; }
  .tab { padding: .55rem .75rem; font-size: .64rem; }
  .nav__lamps span:last-child { font-size: .78rem; }
  .copy__hint { display: none; }
  .pocket__list { gap: 1.1rem; }
  .pocket__list li { grid-template-columns: 1fr; gap: .35rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .js .reveal, .js .hero__inner > * { opacity: 1; transform: none; }
}
