/* ══════════════════════════════════════════════════════════════
   Alloa House & Tower — editorial heritage
   Palette: ink stone · warm parchment · burnished heraldic gold
   ══════════════════════════════════════════════════════════════ */

:root {
  --ink:        #17130d;
  --stone:      #211b12;
  --parchment:  #efe7d6;
  --parchment-2:#e6dbc4;
  --gold:       #a9803e;
  --gold-lit:   #c99a4d;
  --azure:      #3a4a5c;   /* heraldic slate-blue accent */
  --rule:       rgba(23,19,13,0.16);
  --serif:      "Spectral", Georgia, serif;
  --display:    "Fraunces", Georgia, serif;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--parchment);
  color: var(--ink);
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(1.02rem, 0.6vw + 0.9rem, 1.18rem);
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

b { font-weight: 500; color: #000; }

/* film grain overlay ------------------------------------------- */
.grain {
  position: fixed;
  inset: 0;
  z-index: 9;
  pointer-events: none;
  opacity: 0.045;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ── NAVBAR ───────────────────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 1rem clamp(1.5rem, 4vw, 3.5rem);
  color: var(--parchment);
  transition: background 0.4s ease, color 0.4s ease, box-shadow 0.4s ease, padding 0.3s ease;
}
/* solid state once past the hero */
.nav--solid {
  background: rgba(239,231,214,0.92);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: var(--ink);
  box-shadow: 0 1px 0 var(--rule), 0 8px 24px -18px rgba(0,0,0,0.5);
  padding-block: 0.7rem;
}

.nav__brand {
  font-family: var(--display);
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: inherit;
  text-decoration: none;
  white-space: nowrap;
}
.nav__brand span { color: var(--gold); }
.nav--solid .nav__brand span { color: var(--gold); }

.nav__links {
  display: flex;
  align-items: center;
  gap: clamp(0.9rem, 1.8vw, 1.9rem);
  list-style: none;
  margin: 0; padding: 0;
}
.nav__links a {
  position: relative;
  color: inherit;
  text-decoration: none;
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  opacity: 0.82;
  padding: 0.3em 0;
  transition: opacity 0.25s ease;
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 0; height: 1px;
  background: var(--gold);
  transition: width 0.3s cubic-bezier(.2,.7,.2,1);
}
.nav__links a:hover { opacity: 1; }
.nav__links a:hover::after,
.nav__links a.is-active::after { width: 100%; }
.nav__links a.is-active { opacity: 1; color: var(--gold); }
.nav--solid .nav__links a.is-active { color: var(--gold); }

/* hamburger (hidden on desktop) */
.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  width: 30px; height: 26px;
  padding: 4px;
  background: none;
  border: none;
  cursor: pointer;
}
.nav__toggle span {
  display: block;
  height: 1.5px;
  width: 100%;
  background: currentColor;
  transition: transform 0.3s ease, opacity 0.3s ease;
}
.nav--open .nav__toggle span:nth-child(1) { transform: translateY(5.5px) rotate(45deg); }
.nav--open .nav__toggle span:nth-child(2) { opacity: 0; }
.nav--open .nav__toggle span:nth-child(3) { transform: translateY(-5.5px) rotate(-45deg); }

@media (max-width: 820px) {
  .nav__toggle { display: flex; }
  .nav__links {
    position: absolute;
    top: 100%; right: clamp(1rem, 4vw, 2rem);
    flex-direction: column;
    align-items: flex-end;
    gap: 0.2rem;
    padding: 1rem 1.4rem;
    background: rgba(239,231,214,0.97);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border: 1px solid var(--rule);
    box-shadow: 0 18px 40px -24px rgba(0,0,0,0.6);
    opacity: 0;
    transform: translateY(-8px);
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
  }
  .nav__links a { color: var(--ink); padding: 0.5em 0; }
  .nav--open .nav__links {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
  /* when menu open over the dark hero, keep the toggle visible */
  .nav--open:not(.nav--solid) .nav__toggle { color: var(--parchment); }
}

/* keep section headings clear of the fixed bar when jumped to */
[id] { scroll-margin-top: 4.5rem; }

/* ── HERO ─────────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100svh;
  padding: clamp(1.5rem, 4vw, 3.5rem);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--parchment);
  background:
    radial-gradient(120% 90% at 78% 8%, rgba(201,154,77,0.18), transparent 55%),
    radial-gradient(90% 70% at 10% 100%, rgba(58,74,92,0.30), transparent 60%),
    linear-gradient(160deg, #0f0c08 0%, #241c12 55%, #120e09 100%);
  overflow: hidden;
}
/* faint stone/tower silhouette from a gradient */
.hero::after {
  content: "";
  position: absolute;
  right: -6%;
  bottom: 0;
  width: min(46vw, 520px);
  height: 78%;
  background: linear-gradient(180deg, transparent, rgba(201,154,77,0.09));
  -webkit-mask: linear-gradient(180deg, transparent, #000 30%);
  mask: linear-gradient(180deg, transparent, #000 30%);
  clip-path: polygon(18% 100%, 18% 22%, 24% 22%, 24% 12%, 30% 12%, 30% 22%, 40% 22%, 40% 8%, 46% 8%, 46% 22%, 56% 22%, 56% 12%, 62% 12%, 62% 22%, 68% 22%, 68% 100%);
  pointer-events: none;
}

.hero__frame {
  position: relative;
  z-index: 2;
  margin-top: auto;
  max-width: 60rem;
  animation: rise 1.1s cubic-bezier(.2,.7,.2,1) both;
}

.eyebrow {
  font-family: var(--serif);
  font-size: 0.82rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold-lit);
  margin-bottom: 1.4rem;
  padding-left: 0.1em;
}

.hero__title {
  font-family: var(--display);
  font-weight: 300;
  line-height: 0.86;
  letter-spacing: -0.02em;
  font-size: clamp(3.6rem, 15vw, 11rem);
  text-transform: uppercase;
}
.hero__title span {
  display: block;
  font-weight: 600;
  color: var(--gold-lit);
  text-indent: 0.14em;
}
.hero__title em {
  display: block;
  font-style: italic;
  font-weight: 300;
  text-transform: none;
  font-size: 0.42em;
  letter-spacing: 0.01em;
  color: var(--parchment);
  margin-top: 0.35em;
  opacity: 0.9;
}

.hero__lede {
  max-width: 34rem;
  margin-top: 2rem;
  font-size: clamp(1.05rem, 0.7vw + 0.95rem, 1.32rem);
  line-height: 1.6;
  color: rgba(239,231,214,0.86);
  font-weight: 300;
}
.hero__lede b { color: var(--parchment); font-weight: 500; }

.hero__scroll {
  margin-top: 2.5rem;
  font-size: 0.8rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(239,231,214,0.5);
  animation: pulse 3s ease-in-out infinite;
}

.hero__meta {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 2.4rem;
  padding-top: 1.4rem;
  margin-top: 2rem;
  border-top: 1px solid rgba(201,154,77,0.28);
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(239,231,214,0.62);
  animation: rise 1.1s 0.2s cubic-bezier(.2,.7,.2,1) both;
}
.hero__meta b { color: var(--gold-lit); font-weight: 500; }

/* ── SHARED LAYOUT ────────────────────────────────────────────── */
main { position: relative; z-index: 1; }

section { padding-inline: clamp(1.5rem, 6vw, 4rem); }

.prose {
  max-width: 44rem;
  margin: clamp(4rem, 10vw, 8rem) auto clamp(3rem, 7vw, 6rem);
}
.prose p + p { margin-top: 1.4rem; }

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

.section-head {
  font-family: var(--display);
  font-weight: 300;
  font-size: clamp(1.8rem, 4vw, 3rem);
  letter-spacing: -0.01em;
  margin-bottom: 2.6rem;
  display: flex;
  align-items: baseline;
  gap: 0.7em;
}
.section-head span {
  font-size: 0.5em;
  font-weight: 500;
  color: var(--gold);
  letter-spacing: 0.05em;
}

.chron {
  max-width: 52rem;
  margin: clamp(3rem, 8vw, 7rem) auto;
}

/* ── TIMELINE ─────────────────────────────────────────────────── */
.timeline { list-style: none; position: relative; }
.timeline::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.4em;
  bottom: 0.4em;
  width: 1px;
  background: var(--rule);
}
.timeline li {
  position: relative;
  display: grid;
  grid-template-columns: 8.5rem 1fr;
  gap: 1.6rem;
  padding: 1.5rem 0 1.5rem 1.8rem;
  border-bottom: 1px solid var(--rule);
}
.timeline li::before {
  content: "";
  position: absolute;
  left: -4px;
  top: 2rem;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--parchment);
  border: 1.5px solid var(--gold);
}
.timeline__year {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.05rem;
  color: var(--azure);
  letter-spacing: 0.02em;
  padding-top: 0.15em;
}
.timeline h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.35rem;
  line-height: 1.15;
  margin-bottom: 0.4rem;
}
.timeline p { font-weight: 300; color: rgba(23,19,13,0.82); }

.timeline--fire::before {
  background: var(--gold);
  box-shadow: 0 0 0 4px rgba(169,128,62,0.22);
}
.timeline--fire .timeline__year,
.timeline--fire h3 { color: #8a3d1c; }

/* ── FIRE FEATURE ─────────────────────────────────────────────── */
.fire {
  color: var(--parchment);
  padding-block: clamp(4rem, 10vw, 8rem);
  background:
    radial-gradient(80% 120% at 50% 120%, rgba(180,80,30,0.35), transparent 60%),
    linear-gradient(180deg, #1a130c, #241813);
}
.fire blockquote {
  max-width: 40rem;
  margin: 0 auto;
  text-align: center;
}
.fire p {
  font-family: var(--display);
  font-weight: 300;
  font-style: italic;
  font-size: clamp(1.5rem, 3.4vw, 2.4rem);
  line-height: 1.32;
  letter-spacing: -0.01em;
}
.fire sup { font-size: 0.55em; }
.fire cite {
  display: block;
  margin-top: 2rem;
  font-style: normal;
  font-size: 0.8rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold-lit);
}

/* ── CARDS ────────────────────────────────────────────────────── */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
}
.card {
  background: var(--parchment);
  padding: 2rem 1.8rem;
  transition: background 0.4s ease;
}
.card:hover { background: var(--parchment-2); }
.card h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.3rem;
  margin-bottom: 0.6rem;
  color: var(--azure);
}
.card p { font-weight: 300; font-size: 0.98rem; color: rgba(23,19,13,0.8); }

/* ── VISIT ────────────────────────────────────────────────────── */
.visit {
  max-width: 44rem;
  margin: clamp(4rem, 9vw, 7rem) auto;
  text-align: center;
}
.visit .section-head { justify-content: center; }
.visit p { font-weight: 300; margin-bottom: 2.4rem; }

.btn {
  display: inline-block;
  font-family: var(--display);
  font-size: 1.02rem;
  letter-spacing: 0.02em;
  color: var(--ink);
  text-decoration: none;
  padding: 0.9em 1.8em;
  border: 1.5px solid var(--ink);
  border-radius: 2px;
  transition: all 0.3s cubic-bezier(.2,.7,.2,1);
}
.btn:hover {
  background: var(--ink);
  color: var(--gold-lit);
  transform: translateY(-2px);
}

/* ── FOOTER ───────────────────────────────────────────────────── */
.foot {
  background: var(--stone);
  color: rgba(239,231,214,0.7);
  text-align: center;
  padding: clamp(3rem, 7vw, 5rem) 1.5rem;
  font-weight: 300;
  font-size: 0.95rem;
}
.foot__mark {
  font-family: var(--display);
  font-weight: 300;
  font-size: 1.6rem;
  letter-spacing: 0.4em;
  color: var(--gold-lit);
  margin-bottom: 1.2rem;
  text-indent: 0.4em;
}
.foot__fine {
  margin-top: 1rem;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  color: rgba(239,231,214,0.4);
}
.foot a { color: var(--gold-lit); text-decoration: none; }
.foot a:hover { text-decoration: underline; }

/* ── IMAGERY: full-bleed plate ────────────────────────────────── */
figure { margin: 0; }

.plate {
  position: relative;
  margin: clamp(2rem, 6vw, 5rem) 0;
  overflow: hidden;
}
.plate img {
  display: block;
  width: 100%;
  height: clamp(320px, 60vh, 640px);
  object-fit: cover;
  filter: saturate(0.92) contrast(1.02);
}
.plate figcaption {
  position: absolute;
  left: 0; bottom: 0;
  padding: 2.4rem clamp(1.5rem, 6vw, 4rem) 1.4rem;
  width: 100%;
  color: var(--parchment);
  font-size: 0.9rem;
  letter-spacing: 0.04em;
  background: linear-gradient(0deg, rgba(10,8,5,0.82), transparent);
}

/* generic inset image (contained) */
.inset {
  max-width: 52rem;
  margin: clamp(2.5rem, 5vw, 4rem) auto 0;
}
.inset img {
  display: block;
  width: 100%;
  border: 1px solid var(--rule);
  filter: saturate(0.94);
}
.inset figcaption,
.diagram figcaption,
.gallery figcaption {
  margin-top: 0.8rem;
  font-size: 0.82rem;
  font-style: italic;
  color: rgba(23,19,13,0.62);
  letter-spacing: 0.01em;
}

/* ── DIAGRAMS (shared SVG styling) ────────────────────────────── */
.anatomy, .where { max-width: 60rem; margin: clamp(4rem,9vw,7rem) auto; }
.anatomy__intro {
  max-width: 40rem;
  font-weight: 300;
  color: rgba(23,19,13,0.82);
  margin-bottom: 2.6rem;
}
.anatomy__grid, .where__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: start;
}
.diagram svg { width: 100%; height: auto; display: block; }

/* strokes/fills for all diagram SVGs */
.d-wall  { fill: rgba(169,128,62,0.06); stroke: var(--ink); stroke-width: 2; }
.d-void  { fill: var(--parchment); stroke: rgba(23,19,13,0.18); stroke-width: 1; }
.d-ground{ stroke: var(--ink); stroke-width: 3; }
.d-floor { stroke: rgba(23,19,13,0.5); stroke-width: 1.4; }
.d-vault { fill: none; stroke: var(--azure); stroke-width: 1.6; }
.d-roof  { fill: none; stroke: #8a5a2c; stroke-width: 2; stroke-linejoin: round; }
.d-stair { fill: none; stroke: var(--azure); stroke-width: 1.4; stroke-dasharray: 3 4; }
.d-stair-step { stroke: var(--azure); stroke-width: 1.2; }
.d-well  { fill: rgba(58,74,92,0.18); stroke: var(--azure); stroke-width: 1.2; }
.d-door  { fill: rgba(23,19,13,0.72); stroke: none; }
.d-mural { fill: rgba(169,128,62,0.14); stroke: rgba(23,19,13,0.3); stroke-width: 1; }
.d-lead line { stroke: var(--gold); stroke-width: 1; }
.d-dot circle { fill: var(--gold); }
.d-label text, .d-scale-t {
  font-family: var(--serif);
  font-size: 15px;
  fill: var(--ink);
  letter-spacing: 0.01em;
}
.d-label--l { text-anchor: end; }
.d-label--plan text { font-size: 13px; fill: rgba(23,19,13,0.8); }
.d-label--plan text[text-anchor="middle"]:first-child { }
.d-scale { stroke: var(--ink); stroke-width: 2; }
.diagram--plan svg { max-width: 340px; margin-inline: auto; }

/* ── LINEAGE (portraits) ──────────────────────────────────────── */
.lineage {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: clamp(1.2rem, 3vw, 2.2rem);
  margin-top: 1rem;
}
.peer img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: top center;
  filter: sepia(0.12) saturate(0.9) contrast(1.02);
  border: 1px solid var(--rule);
}
.peer figcaption { display: flex; flex-direction: column; margin-top: 0.9rem; }
.peer__name {
  font-family: var(--display);
  font-size: 1.35rem;
  font-weight: 500;
  line-height: 1.1;
}
.peer__title {
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0.4rem 0 0.7rem;
}
.peer__note { font-weight: 300; font-size: 0.95rem; color: rgba(23,19,13,0.8); }

/* ── HERALDRY ─────────────────────────────────────────────────── */
.heraldry {
  display: flex;
  align-items: center;
  gap: clamp(1.5rem, 4vw, 3rem);
  margin-top: clamp(3rem, 6vw, 5rem);
  padding: clamp(1.8rem, 4vw, 2.6rem);
  border: 1px solid var(--rule);
  background: rgba(169,128,62,0.05);
}
.crest { width: clamp(96px, 20vw, 150px); flex: none; }
.sh-field { fill: var(--azure); }
.sh-bend  { fill: var(--gold-lit); }
.sh-cross { fill: var(--parchment); stroke: rgba(23,19,13,0.45); stroke-width: 0.5; }
.sh-edge  { fill: none; stroke: var(--ink); stroke-width: 3; }
.heraldry__text h3 {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.5rem;
  margin-bottom: 0.6rem;
}
.heraldry__text p { font-weight: 300; color: rgba(23,19,13,0.82); max-width: 34rem; }
.heraldry__text em { color: var(--azure); font-weight: 400; }

/* ── GALLERY ──────────────────────────────────────────────────── */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(0.8rem, 2vw, 1.4rem);
  margin-top: clamp(2rem, 4vw, 3rem);
}
.gallery__item img {
  width: 100%;
  height: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  filter: saturate(0.92);
  border: 1px solid var(--rule);
}
.gallery__item--tall img { aspect-ratio: 3 / 4; }

/* ── MAP ──────────────────────────────────────────────────────── */
.diagram--map svg { border: 1px solid var(--rule); }
.m-land   { fill: rgba(169,128,62,0.05); }
.m-water  { fill: rgba(58,74,92,0.16); }
.m-shore  { fill: none; stroke: var(--azure); stroke-width: 1.4; }
.m-ferry  { fill: none; stroke: var(--ink); stroke-width: 1.4; stroke-dasharray: 4 5; }
.m-ferry-t{ font-family: var(--serif); font-style: italic; font-size: 13px; fill: rgba(23,19,13,0.7); }
.m-dot    { fill: var(--ink); }
.m-dot--key { fill: var(--gold); }
.m-place  { font-family: var(--serif); font-size: 14px; fill: var(--ink); }
.m-place--key {
  font-family: var(--display);
  font-size: 17px; font-weight: 600;
  letter-spacing: 0.14em; fill: var(--gold);
  text-anchor: middle;
}
.m-tower  { fill: var(--gold); }
.m-arrow  { fill: none; stroke: var(--ink); stroke-width: 1.4; }
.m-compass circle { fill: none; stroke: rgba(23,19,13,0.35); stroke-width: 1; }
.m-compass path { fill: var(--gold); }
.m-compass text { font-family: var(--serif); font-size: 12px; fill: var(--ink); }

/* ── IMAGE CREDITS ────────────────────────────────────────────── */
.credits {
  max-width: 52rem;
  margin: clamp(4rem, 8vw, 6rem) auto 0;
  padding-top: clamp(2rem, 4vw, 3rem);
  border-top: 1px solid var(--rule);
}
.credits__head {
  font-family: var(--display);
  font-weight: 500;
  font-size: 1.1rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}
.credits__intro { font-weight: 300; font-size: 0.92rem; color: rgba(23,19,13,0.72); margin-bottom: 1.2rem; }
.credits ul { list-style: none; display: grid; gap: 0.5rem; }
.credits li {
  font-size: 0.86rem;
  font-weight: 300;
  color: rgba(23,19,13,0.72);
  padding-left: 1rem;
  border-left: 2px solid var(--rule);
}
.credits b { font-weight: 500; color: var(--ink); }

/* ══════════════════════════════════════════════════════════════
   SHADOWS & LEGENDS — full-gothic interlude
   ══════════════════════════════════════════════════════════════ */
:root {
  --blood: #9a2f1e;
  --ember: #d0562f;
  --bone:  #d9cebc;
  --blackletter: "UnifrakturMaguntia", "Fraunces", serif;
}

.shadows {
  position: relative;
  isolation: isolate;
  color: var(--bone);
  padding: clamp(4.5rem, 11vw, 10rem) clamp(1.5rem, 6vw, 4rem);
  background:
    radial-gradient(75% 45% at 18% -5%, rgba(154,47,30,0.30), transparent 60%),
    radial-gradient(65% 55% at 92% 108%, rgba(208,86,47,0.16), transparent 60%),
    linear-gradient(180deg, #130b08 0%, #0a0605 55%, #0d0807 100%);
  overflow: hidden;
}
/* heavy vignette */
.shadows::before {
  content: "";
  position: absolute; inset: 0; z-index: -1;
  box-shadow: inset 0 0 200px 40px rgba(0,0,0,0.85);
  pointer-events: none;
}
/* intensified grain for this section */
.shadows__grain {
  position: absolute; inset: 0; z-index: -1;
  opacity: 0.12; mix-blend-mode: overlay; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.shadows__head {
  max-width: 46rem;
  margin: 0 auto clamp(3rem, 7vw, 6rem);
  text-align: center;
}
.shadows__eyebrow {
  font-size: 0.78rem;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--ember);
  margin-bottom: 1.6rem;
}
.shadows__title {
  font-family: var(--blackletter);
  font-weight: 400;
  line-height: 0.92;
  font-size: clamp(3.4rem, 12vw, 8rem);
  color: var(--bone);
  text-shadow: 0 0 32px rgba(208,86,47,0.45), 0 0 4px rgba(0,0,0,0.6);
}
.shadows__dek {
  max-width: 34rem;
  margin: 2rem auto 0;
  font-weight: 300;
  font-style: italic;
  font-size: clamp(1.02rem, 0.6vw + 0.9rem, 1.2rem);
  color: rgba(217,206,188,0.78);
}

/* tags / provenance pills */
.tag {
  display: inline-block;
  font-family: var(--serif);
  font-size: 0.68rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  padding: 0.34em 0.9em;
  border: 1px solid currentColor;
  border-radius: 100px;
  margin-bottom: 1.4rem;
}
.tag--legend   { color: var(--ember); }
.tag--fact     { color: var(--gold-lit); }
.tag--folklore { color: #7f93a6; }

/* shared article width within the gothic section */
.doom, .tale, .haunts {
  max-width: 46rem;
  margin: 0 auto;
  padding-block: clamp(2.5rem, 6vw, 5rem);
  border-top: 1px solid rgba(217,206,188,0.12);
}
.tale--narrow { max-width: 40rem; }

.doom__title, .tale__title, .haunts__title {
  font-family: var(--blackletter);
  font-weight: 400;
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1;
  color: var(--bone);
  margin-bottom: 1.4rem;
  text-shadow: 0 0 18px rgba(208,86,47,0.25);
}
.doom__intro, .tale__prose p, .doom__coda {
  font-weight: 300;
  color: rgba(217,206,188,0.82);
}
.doom__intro b, .tale__prose b { color: var(--bone); font-weight: 500; }
.doom__intro { max-width: 38rem; margin-bottom: 2rem; }

/* dark image plates */
.doom__plate, .tale__plate { margin: 2rem 0; position: relative; }
.doom__plate img, .tale__plate img {
  width: 100%;
  height: clamp(220px, 34vh, 340px);
  object-fit: cover;
  filter: grayscale(0.35) contrast(1.08) brightness(0.72) sepia(0.15);
  border: 1px solid rgba(217,206,188,0.14);
}
.doom__plate figcaption, .tale__plate figcaption {
  margin-top: 0.7rem;
  font-size: 0.78rem;
  font-style: italic;
  color: rgba(217,206,188,0.5);
}

/* the curse quote */
.curse {
  position: relative;
  margin: 2.5rem 0;
  padding: 0.5rem 0 0.5rem 2.2rem;
  border-left: 2px solid var(--blood);
  font-family: var(--display);
  font-weight: 300;
  font-style: italic;
  font-size: clamp(1.3rem, 2.6vw, 1.9rem);
  line-height: 1.42;
  color: var(--bone);
}
.curse em { color: var(--ember); font-style: italic; }
.curse__q {
  position: absolute;
  left: 0.3rem; top: -1.2rem;
  font-family: var(--display);
  font-size: 4rem;
  color: var(--blood);
  opacity: 0.7;
}

/* the fulfilled omens */
.omens { list-style: none; margin: 2rem 0; display: grid; gap: 0.9rem; }
.omens li {
  font-weight: 300;
  font-size: 0.98rem;
  color: rgba(217,206,188,0.82);
  padding-left: 0.4rem;
}
.omens span {
  display: inline-block;
  min-width: 7rem;
  font-family: var(--serif);
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ember);
  margin-right: 0.4rem;
}
.doom__coda {
  margin-top: 2rem;
  font-style: italic;
  font-size: 1.05rem;
  color: rgba(217,206,188,0.9);
}
.doom__coda b { color: var(--ember); font-weight: 500; }

/* tale prose */
.tale__prose p + p { margin-top: 1.2rem; }
.tale__sting {
  margin-top: 1.4rem !important;
  padding-top: 1.2rem;
  border-top: 1px solid rgba(154,47,30,0.4);
  font-style: italic;
  color: var(--ember) !important;
}
.tale__prose em, .tale__prose b em { color: var(--ember); font-style: italic; }

/* ghosts */
.haunts__list { list-style: none; margin-top: 1.5rem; display: grid; gap: 1rem; }
.haunts__list li {
  display: flex; gap: 1rem; align-items: baseline;
  font-weight: 300;
  font-style: italic;
  color: rgba(217,206,188,0.74);
}
.haunts__list span {
  flex: none;
  color: var(--blood);
  font-style: normal;
  font-size: 1.2rem;
}

/* ── MOTION ───────────────────────────────────────────────────── */
@keyframes rise {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes pulse {
  0%, 100% { opacity: 0.5; }
  50%      { opacity: 0.15; }
}

/* reveal on scroll (progressive enhancement via IntersectionObserver) */
.chron, .fire, .visit, .prose { }
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s ease, transform 0.9s cubic-bezier(.2,.7,.2,1);
}
[data-reveal].in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  [data-reveal] { opacity: 1; transform: none; }
}

/* ── RESPONSIVE ───────────────────────────────────────────────── */
@media (max-width: 820px) {
  .anatomy__grid, .where__grid, .heraldry { grid-template-columns: 1fr; }
  .heraldry { flex-direction: column; text-align: center; }
}
@media (max-width: 560px) {
  .timeline li { grid-template-columns: 1fr; gap: 0.3rem; padding-left: 1.6rem; }
  .timeline__year { color: var(--gold); font-size: 0.95rem; }
  .hero__title em { font-size: 0.5em; }
  .gallery { grid-template-columns: 1fr 1fr; }
  .gallery__item--tall { grid-column: span 2; }
}
