/* ============================================================
   Crepuscolo Gotico — foglio di stile unico
   Paletta: inchiostro, osso, cenere, vino.
   ============================================================ */

@font-face {
  font-family: "Cormorant Garamond";
  src: url("/assets/fonts/cormorant-garamond-400.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Cormorant Garamond";
  src: url("/assets/fonts/cormorant-garamond-400-italic.woff2") format("woff2");
  font-weight: 300 700;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("/assets/fonts/jost-400.woff2") format("woff2");
  font-weight: 200 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #07060a;
  --ink-2: #0b090e;
  --coal: #121016;
  --bone: #ece5d8;
  --bone-dim: #d6ccbd;
  --ash: #9a9188;
  --ash-dim: #8a8178;
  --wine: #6e1b2a;
  --wine-bright: #b23a4b;
  --line: rgba(236, 229, 216, 0.14);
  --line-soft: rgba(236, 229, 216, 0.075);
  --serif: "Cormorant Garamond", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans: "Jost", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --page: min(1180px, 90vw);
  --gutter: clamp(18px, 4vw, 48px);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

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

body {
  margin: 0;
  background: var(--ink);
  color: var(--bone);
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.7;
  font-weight: 400;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(60% 45% at 78% 4%, rgba(110, 27, 42, 0.16), transparent 70%),
    radial-gradient(45% 40% at 8% 92%, rgba(46, 30, 66, 0.22), transparent 72%),
    radial-gradient(90% 70% at 50% 50%, #0a0810 0%, var(--ink) 70%);
}

::selection {
  background: var(--wine);
  color: var(--bone);
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--bone);
  text-decoration: none;
}

p,
h1,
h2,
h3,
blockquote,
figure {
  margin: 0;
}

button {
  font: inherit;
  color: inherit;
}

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

.skip {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--bone);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 12px;
  transform: translateY(-160%);
  transition: transform 0.2s;
}
.skip:focus {
  transform: none;
}

/* ---------- grana e braci ---------- */

.grain {
  position: fixed;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  opacity: 0.055;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
}

.embers {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.5;
}

/* ---------- testata ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 78px;
  padding: 0 var(--gutter);
  background: rgba(7, 6, 10, 0.66);
  border-bottom: 1px solid var(--line-soft);
  backdrop-filter: blur(14px) saturate(120%);
  -webkit-backdrop-filter: blur(14px) saturate(120%);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.sigil {
  color: var(--bone);
  flex: none;
  filter: drop-shadow(0 0 14px rgba(178, 58, 75, 0.18));
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}
.brand-name {
  font-family: var(--sans);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.brand-latin {
  font-family: var(--serif);
  font-style: italic;
  font-size: 12.5px;
  color: var(--ash);
  margin-top: 3px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 34px;
}
.nav a {
  position: relative;
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: var(--ash);
  transition: color 0.25s var(--ease);
  padding: 6px 0;
}
.nav-num {
  font-size: 8.5px;
  color: var(--ash-dim);
  letter-spacing: 0.08em;
}
.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: var(--wine-bright);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--ease);
}
.nav a:hover {
  color: var(--bone);
}
.nav a:hover::after,
.nav a.is-active::after {
  transform: scaleX(1);
}
.nav a.is-active {
  color: var(--bone);
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 12px;
}

.motion-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 13px;
  border: 1px solid var(--line);
  border-radius: 100px;
  background: transparent;
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ash);
  cursor: pointer;
  transition: color 0.25s, border-color 0.25s;
}
.motion-toggle:hover {
  color: var(--bone);
  border-color: rgba(236, 229, 216, 0.3);
}
.motion-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--wine-bright);
  box-shadow: 0 0 8px var(--wine-bright);
  animation: pulse 3.2s ease-in-out infinite;
}
html[data-motion="off"] .motion-dot {
  background: var(--ash-dim);
  box-shadow: none;
  animation: none;
}

.nav-toggle {
  display: none;
  width: 40px;
  height: 36px;
  padding: 9px 8px;
  border: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  justify-content: space-between;
}
.nav-toggle span {
  display: block;
  height: 1px;
  background: var(--bone);
  transition: transform 0.3s var(--ease), opacity 0.3s;
}
.nav-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(8px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-8px) rotate(-45deg);
}

/* ---------- tipografia di servizio ---------- */

.kicker {
  font-family: var(--sans);
  font-size: 10.5px;
  font-weight: 400;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ash);
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--sans);
  font-size: 10.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--bone);
  margin-top: 26px;
}
.link-arrow span {
  color: var(--wine-bright);
  transition: transform 0.35s var(--ease);
}
a:hover .link-arrow span,
.link-arrow:hover span {
  transform: translateX(6px);
}

/* ---------- pulsanti ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 15px 26px;
  border: 1px solid transparent;
  border-radius: 2px;
  font-family: var(--sans);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s, border-color 0.3s, transform 0.3s;
}
.btn span {
  color: inherit;
  opacity: 0.7;
}
.btn-solid {
  background: var(--bone);
  color: var(--ink);
  border-color: var(--bone);
}
.btn-solid:hover {
  background: #f6f0e4;
  transform: translateY(-1px);
}
.btn-ghost {
  border-color: var(--line);
  color: var(--bone);
  background: transparent;
}
.btn-ghost:hover {
  border-color: var(--wine-bright);
  background: rgba(110, 27, 42, 0.16);
}

/* ---------- hero ---------- */

.hero {
  position: relative;
  z-index: 1;
  min-height: calc(100svh - 78px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: clamp(60px, 9vh, 110px) var(--gutter) clamp(80px, 12vh, 130px);
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  z-index: -1;
  width: min(900px, 120vw);
  height: min(900px, 120vw);
  left: 50%;
  top: 42%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(110, 27, 42, 0.22) 0%, rgba(110, 27, 42, 0.06) 38%, transparent 66%);
  filter: blur(20px);
  animation: drift 22s ease-in-out infinite alternate;
  pointer-events: none;
}

.hero-arch {
  position: absolute;
  z-index: -1;
  left: 50%;
  bottom: -6%;
  width: min(520px, 78vw);
  height: min(720px, 74vh);
  transform: translateX(-50%);
  border: 1px solid var(--line-soft);
  border-bottom: none;
  border-radius: 50% 50% 0 0 / 42% 42% 0 0;
  mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent 100%);
}
.hero-arch::before {
  content: "";
  position: absolute;
  inset: 14px 14px 0;
  border: 1px solid var(--line-soft);
  border-bottom: none;
  border-radius: 50% 50% 0 0 / 42% 42% 0 0;
}

.hero-glyph {
  margin-bottom: 26px;
  opacity: 0.92;
  animation: glyphIn 1.6s var(--ease) both 0.1s;
}

.hero-kicker {
  animation: riseIn 1.2s var(--ease) both 0.25s;
}

.hero-title {
  margin: 22px 0 0;
  font-weight: 500;
  font-size: clamp(58px, 11.5vw, 148px);
  line-height: 0.84;
  letter-spacing: -0.015em;
  text-transform: uppercase;
  text-wrap: balance;
}
.hero-title .line {
  display: block;
  animation: titleIn 1.6s var(--ease) both;
}
.hero-title .line-2 {
  font-style: italic;
  text-transform: none;
  color: var(--bone-dim);
  letter-spacing: -0.01em;
  animation-delay: 0.14s;
}

.hero-sub {
  margin-top: 26px;
  font-family: var(--sans);
  font-size: 10.5px;
  letter-spacing: 0.42em;
  text-transform: uppercase;
  color: var(--ash);
  animation: riseIn 1.2s var(--ease) both 0.5s;
}

.hero-verse {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 12px;
  max-width: 40ch;
  min-height: 3.4em;
  margin-top: 38px;
  font-size: clamp(18px, 2.1vw, 24px);
  font-style: italic;
  line-height: 1.45;
  color: var(--bone-dim);
  animation: riseIn 1.4s var(--ease) both 0.65s;
}
.verse-mark {
  color: var(--wine-bright);
  font-style: normal;
  font-size: 0.7em;
}
.verse-text {
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}
.verse-text.is-out {
  opacity: 0;
  transform: translateY(6px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 44px;
  animation: riseIn 1.4s var(--ease) both 0.8s;
}

.scroll-cue {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  width: 1px;
  height: 58px;
  background: linear-gradient(to bottom, transparent, var(--line));
  overflow: hidden;
}
.scroll-cue span {
  position: absolute;
  top: 0;
  left: 0;
  width: 1px;
  height: 18px;
  background: var(--wine-bright);
  animation: cue 2.8s ease-in-out infinite;
}

/* ---------- sezioni ---------- */

.section {
  position: relative;
  z-index: 1;
  padding: clamp(70px, 9vw, 125px) var(--gutter);
  border-top: 1px solid var(--line-soft);
}
.section > * {
  max-width: var(--page);
  margin-inline: auto;
}

.section-head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: baseline;
  gap: 18px;
  padding-bottom: 18px;
  margin-bottom: clamp(34px, 5vw, 56px);
  border-bottom: 1px solid var(--line-soft);
}
.section-index {
  font-family: var(--serif);
  font-style: italic;
  font-size: 23px;
  color: var(--wine-bright);
  opacity: 0.9;
  min-width: 1.6em;
  line-height: 1;
}
.section-title {
  font-size: clamp(30px, 3.6vw, 46px);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -0.005em;
}
.section-note {
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ash-dim);
  text-align: right;
}

/* ---------- in evidenza ---------- */

.feature {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  align-items: center;
  gap: clamp(28px, 5vw, 70px);
  padding: clamp(22px, 3.4vw, 44px);
  border: 1px solid var(--line-soft);
  background: linear-gradient(150deg, rgba(236, 229, 216, 0.025), transparent 55%);
  transition: border-color 0.4s, background 0.4s;
}
.feature:hover {
  border-color: var(--line);
  background: linear-gradient(150deg, rgba(236, 229, 216, 0.045), transparent 60%);
}

.feature-figure {
  position: relative;
  aspect-ratio: 4 / 5;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-soft);
  background:
    radial-gradient(70% 55% at 50% 42%, rgba(110, 27, 42, 0.3), transparent 68%),
    linear-gradient(180deg, rgba(236, 229, 216, 0.02), transparent);
  overflow: hidden;
}
.feature-arch {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 62%;
  height: 82%;
  transform: translateX(-50%);
  border: 1px solid var(--line);
  border-bottom: none;
  border-radius: 50% 50% 0 0 / 44% 44% 0 0;
}
.feature-arch::before {
  content: "";
  position: absolute;
  inset: 10px 10px 0;
  border: 1px solid var(--line-soft);
  border-bottom: none;
  border-radius: 50% 50% 0 0 / 44% 44% 0 0;
}
.feature-glyph {
  position: relative;
  color: var(--bone);
  opacity: 0.9;
  filter: drop-shadow(0 0 28px rgba(178, 58, 75, 0.28));
}
.feature-index {
  position: absolute;
  top: 14px;
  left: 16px;
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.24em;
  color: var(--ash-dim);
}

.feature-title {
  margin-top: 14px;
  font-size: clamp(38px, 4.8vw, 64px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.01em;
}
.feature-epigraph {
  margin-top: 14px;
  font-style: italic;
  font-size: clamp(18px, 1.7vw, 21px);
  color: var(--ash);
}
.feature-first {
  margin-top: 26px;
  font-size: clamp(17px, 1.5vw, 19px);
  line-height: 1.85;
  color: var(--bone-dim);
}
.feature-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 26px;
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ash-dim);
}
.feature-meta .dot {
  width: 3px;
  height: 3px;
  background: var(--wine-bright);
  border-radius: 50%;
}
.feature-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 20px;
}

.chip,
.mini-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border: 1px solid var(--line-soft);
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ash);
  transition: color 0.25s, border-color 0.25s;
}
.chip svg {
  color: var(--wine-bright);
}
a.chip:hover {
  color: var(--bone);
  border-color: var(--wine);
}

/* ---------- soglie ---------- */

.thresholds {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line-soft);
  border: 1px solid var(--line-soft);
}
.threshold {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: clamp(22px, 2.6vw, 34px);
  background: var(--ink);
  transition: background 0.35s;
  min-height: 250px;
}
.threshold:hover {
  background: #0d0b11;
}
.threshold-glyph {
  color: var(--ash-dim);
  transition: color 0.35s, transform 0.35s;
  margin-bottom: 10px;
}
.threshold:hover .threshold-glyph {
  color: var(--wine-bright);
  transform: translateY(-2px);
}
.threshold h3 {
  font-size: clamp(26px, 2.5vw, 34px);
  font-weight: 500;
  line-height: 1;
}
.threshold p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--ash);
}
.threshold-count {
  margin-top: auto;
  padding-top: 18px;
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ash-dim);
}

/* ---------- manifesto ---------- */

.manifesto {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(30px, 5vw, 70px);
  align-items: start;
}
.manifesto blockquote p {
  font-size: clamp(24px, 2.8vw, 36px);
  font-style: italic;
  line-height: 1.35;
  letter-spacing: -0.005em;
  color: var(--bone);
}
.manifesto cite {
  display: block;
  margin-top: 22px;
  font-family: var(--sans);
  font-style: normal;
  font-size: 9.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ash-dim);
}
.manifesto-copy {
  padding-top: 6px;
}
.manifesto-copy p {
  font-size: 17.5px;
  line-height: 1.85;
  color: var(--bone-dim);
  margin-bottom: 18px;
}
.manifesto-copy .link-arrow {
  margin-top: 10px;
}

/* ---------- lumi ---------- */

.lights {
  text-align: center;
  padding: clamp(40px, 6vw, 72px) clamp(20px, 5vw, 60px);
  border: 1px solid var(--line-soft);
  background: radial-gradient(60% 120% at 50% 100%, rgba(110, 27, 42, 0.18), transparent 70%);
}
.lights-count {
  font-size: clamp(56px, 9vw, 104px);
  line-height: 1;
  font-weight: 500;
  margin: 10px 0 4px;
  color: var(--bone);
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 40px rgba(178, 58, 75, 0.35);
}
.lights-copy {
  font-size: 16px;
  line-height: 1.7;
  color: var(--ash);
  margin-bottom: 26px;
}

/* ---------- testata di pagina ---------- */

.page-head {
  position: relative;
  z-index: 1;
  max-width: var(--page);
  margin: 0 auto;
  padding: clamp(70px, 9vw, 120px) var(--gutter) clamp(40px, 5vw, 60px);
}
.page-head-narrow {
  max-width: min(760px, 90vw);
}
.page-title {
  margin-top: 18px;
  font-size: clamp(46px, 7.5vw, 92px);
  font-weight: 500;
  line-height: 0.95;
  letter-spacing: -0.015em;
}
.page-lead {
  margin-top: 26px;
  max-width: 56ch;
  font-size: clamp(17px, 1.6vw, 19px);
  line-height: 1.8;
  color: var(--ash);
}

/* ---------- archivio ---------- */

.archive {
  position: relative;
  z-index: 1;
  max-width: var(--page);
  margin: 0 auto;
  padding: 0 var(--gutter) clamp(80px, 10vw, 130px);
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 6px;
}
.filter {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 15px;
  border: 1px solid var(--line);
  border-radius: 100px;
  background: transparent;
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ash);
  cursor: pointer;
  transition: color 0.25s, border-color 0.25s, background 0.25s;
}
.filter span {
  font-size: 8.5px;
  color: var(--ash-dim);
}
.filter:hover {
  color: var(--bone);
  border-color: rgba(236, 229, 216, 0.3);
}
.filter.is-active {
  background: var(--bone);
  border-color: var(--bone);
  color: var(--ink);
}
.filter.is-active span {
  color: rgba(7, 6, 10, 0.55);
}

.filters-note {
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ash-dim);
  min-height: 1.6em;
  padding: 12px 2px 0;
}

.poem-list {
  border-top: 1px solid var(--line-soft);
}
.poem-row {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto 140px 22px;
  align-items: center;
  gap: 20px;
  padding: 26px 8px;
  border-bottom: 1px solid var(--line-soft);
  transition: background 0.3s, padding 0.3s;
}
.poem-row:hover {
  background: rgba(236, 229, 216, 0.025);
  padding-left: 16px;
}
.row-index {
  font-family: var(--serif);
  font-style: italic;
  font-size: 15px;
  color: var(--ash-dim);
}
.row-main {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.row-title {
  font-size: clamp(26px, 2.9vw, 36px);
  font-weight: 500;
  line-height: 1.05;
}
.row-epigraph {
  font-style: italic;
  font-size: 15.5px;
  color: var(--ash);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.row-chips {
  display: flex;
  gap: 6px;
}
.row-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ash-dim);
}
.row-arrow {
  color: var(--wine-bright);
  transition: transform 0.3s var(--ease);
}
.poem-row:hover .row-arrow {
  transform: translateX(5px);
}
.archive-empty {
  padding: 60px 0;
  text-align: center;
  font-style: italic;
  color: var(--ash);
}

[hidden] {
  display: none !important;
}

/* ---------- poesia ---------- */

.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  z-index: 70;
  background: transparent;
  pointer-events: none;
}
.reading-progress span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--wine), var(--wine-bright));
}

.poem {
  position: relative;
  z-index: 1;
}

.poem-head {
  max-width: 900px;
  margin: 0 auto;
  padding: clamp(60px, 8vw, 110px) var(--gutter) clamp(30px, 4vw, 50px);
  text-align: center;
}
.crumbs {
  display: flex;
  justify-content: center;
  gap: 9px;
  margin-bottom: 26px;
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ash-dim);
}
.crumbs a:hover {
  color: var(--bone);
}
.poem-title {
  margin-top: 18px;
  font-size: clamp(48px, 8vw, 100px);
  font-weight: 500;
  line-height: 0.96;
  letter-spacing: -0.015em;
  text-wrap: balance;
}
.poem-epigraph {
  margin-top: 22px;
  font-style: italic;
  font-size: clamp(18px, 2vw, 22px);
  color: var(--ash);
}
.content-note {
  display: inline-block;
  margin-top: 26px;
  padding: 7px 12px;
  border-left: 2px solid var(--wine);
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--ash);
  text-align: left;
}
.content-note span {
  color: var(--wine-bright);
  margin-right: 6px;
}

.poem-layout {
  display: grid;
  grid-template-columns: 268px minmax(0, 1fr);
  gap: clamp(30px, 5vw, 80px);
  max-width: var(--page);
  margin: 0 auto;
  padding: 0 var(--gutter) clamp(70px, 9vw, 120px);
  align-items: start;
}

.poem-aside {
  position: sticky;
  top: 104px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 22px;
  border: 1px solid var(--line-soft);
  background: rgba(11, 9, 14, 0.6);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}
.ritual-label {
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ash-dim);
  padding-bottom: 9px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--line-soft);
}

.candle {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 15px;
  border: 1px solid var(--line);
  background: linear-gradient(160deg, rgba(110, 27, 42, 0.12), transparent 70%);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.3s, background 0.3s;
}
.candle:hover {
  border-color: var(--wine);
}
.candle[disabled] {
  cursor: wait;
  opacity: 0.7;
}
.candle-flame svg {
  overflow: visible;
}
.flame-outer {
  fill: rgba(178, 58, 75, 0.14);
  stroke: var(--wine-bright);
  stroke-width: 1;
}
.flame-inner {
  fill: var(--wine-bright);
  opacity: 0.55;
}
.candle.is-lit {
  border-color: var(--wine-bright);
  background: linear-gradient(160deg, rgba(178, 58, 75, 0.2), transparent 75%);
}
.candle.is-lit .flame-outer {
  fill: rgba(178, 58, 75, 0.55);
}
.candle.is-lit .flame-inner {
  fill: #ffd9a8;
  opacity: 1;
}
.candle.is-lit .candle-flame {
  animation: flicker 3.4s ease-in-out infinite;
}
.candle-label {
  display: block;
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--bone);
}
.candle-count {
  display: block;
  margin-top: 3px;
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ash);
}
.ritual-note {
  margin-top: 12px;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ash-dim);
}

.size-tools {
  display: flex;
  border: 1px solid var(--line);
}
.size-btn {
  flex: 1;
  padding: 9px 4px;
  border: 0;
  border-right: 1px solid var(--line-soft);
  background: transparent;
  font-family: var(--sans);
  font-size: 11px;
  color: var(--ash);
  cursor: pointer;
  transition: background 0.25s, color 0.25s;
}
.size-btn:last-child {
  border-right: 0;
}
.size-btn:hover {
  color: var(--bone);
  background: rgba(236, 229, 216, 0.05);
}
.size-btn.is-active {
  background: var(--bone);
  color: var(--ink);
}
.copy-btn {
  width: 100%;
  margin-top: 8px;
  padding: 11px;
  border: 1px solid var(--line);
  background: transparent;
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ash);
  cursor: pointer;
  transition: color 0.25s, border-color 0.25s;
}
.copy-btn:hover {
  color: var(--bone);
  border-color: var(--wine);
}

.theme-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.poem-nav {
  display: flex;
  flex-direction: column;
}
.poem-nav-link {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 12px 0;
  border-top: 1px solid var(--line-soft);
}
.poem-nav-label {
  font-family: var(--sans);
  font-size: 8.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ash-dim);
}
.poem-nav-title {
  font-size: 19px;
  font-style: italic;
  color: var(--bone-dim);
  transition: color 0.25s;
}
.poem-nav-link:hover .poem-nav-title {
  color: var(--wine-bright);
}

.poem-body {
  min-width: 0;
  border-left: 1px solid var(--line-soft);
  padding-left: clamp(20px, 4vw, 56px);
}

.poem-text {
  --ps: 1;
  max-width: 60ch;
  font-size: calc(clamp(1.06rem, 1.25vw, 1.22rem) * var(--ps));
  line-height: 1.92;
  color: #ded6c9;
  transition: font-size 0.2s var(--ease);
  hanging-punctuation: first;
}
.poem-text[data-size="-1"] {
  --ps: 0.9;
}
.poem-text[data-size="1"] {
  --ps: 1.16;
}
.stanza {
  margin-bottom: 1.55em;
  white-space: normal;
}
.stanza:last-child {
  margin-bottom: 0;
}

.poem-end {
  display: flex;
  align-items: center;
  gap: 18px;
  max-width: 60ch;
  margin: 54px 0 0;
  color: var(--wine-bright);
}
.poem-end::before,
.poem-end::after {
  content: "";
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}
.poem-end span {
  font-size: 14px;
}
.orn-diamond {
  display: block;
  width: 6px;
  height: 6px;
  background: var(--wine-bright);
  transform: rotate(45deg);
  box-shadow: 0 0 12px rgba(178, 58, 75, 0.6);
}
.poem-after {
  max-width: 60ch;
  margin-top: 40px;
  text-align: center;
}
.poem-after-line {
  font-style: italic;
  color: var(--ash);
  margin-bottom: 26px;
}

/* ---------- correlate ---------- */

.related-section {
  padding-top: clamp(50px, 7vw, 90px);
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(18px, 3vw, 34px);
}
.related {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  transition: border-color 0.3s;
}
.related:hover {
  border-color: var(--wine-bright);
}
.related-kicker {
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ash-dim);
}
.related-title {
  font-size: clamp(24px, 2.6vw, 32px);
  font-weight: 500;
  line-height: 1.05;
  transition: color 0.3s;
}
.related:hover .related-title {
  color: var(--wine-bright);
}
.related-line {
  font-size: 15px;
  font-style: italic;
  color: var(--ash);
}

/* ---------- prosa (grimorio) ---------- */

.prose {
  position: relative;
  z-index: 1;
  max-width: min(780px, 90vw);
  margin: 0 auto;
  padding: 0 var(--gutter) clamp(60px, 8vw, 110px);
}
.prose-section {
  margin-bottom: clamp(50px, 7vw, 90px);
}
.prose-index {
  font-family: var(--serif);
  font-style: italic;
  font-size: 16px;
  color: var(--wine-bright);
  margin-bottom: 8px;
}
.prose h2 {
  font-size: clamp(30px, 3.6vw, 44px);
  font-weight: 500;
  line-height: 1.05;
  margin-bottom: 22px;
}
.prose p {
  font-size: 18px;
  line-height: 1.9;
  color: var(--bone-dim);
  margin-bottom: 18px;
}
.prose a {
  color: var(--bone);
  border-bottom: 1px solid var(--wine);
  transition: border-color 0.25s, color 0.25s;
}
.prose a:hover {
  color: var(--wine-bright);
  border-color: var(--wine-bright);
}
.dropcap::first-letter {
  float: left;
  font-size: 4.3em;
  line-height: 0.78;
  padding: 6px 14px 0 0;
  color: var(--bone);
  font-weight: 500;
}

.creeds {
  margin-top: 26px;
  border-top: 1px solid var(--line);
}
.creed {
  display: grid;
  grid-template-columns: 34px 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line-soft);
}
.creed-glyph {
  color: var(--wine-bright);
}
.creed h3 {
  font-size: 24px;
  font-weight: 500;
  line-height: 1.1;
}
.creed p {
  margin: 2px 0 0;
  font-size: 15px;
  color: var(--ash);
}
.creed-count {
  font-family: var(--serif);
  font-style: italic;
  font-size: 20px;
  color: var(--ash-dim);
}

.prose-sign {
  text-align: center;
  padding-top: 30px;
  border-top: 1px solid var(--line-soft);
}
.prose-sign span {
  color: var(--wine-bright);
  font-size: 16px;
}
.prose-sign p {
  margin-top: 12px;
  font-style: italic;
  font-size: 21px;
  color: var(--bone);
}
.prose-sign em {
  font-size: 15px;
  color: var(--ash);
}

/* ---------- scriptorium ---------- */

.scriptorium {
  position: relative;
  z-index: 1;
  max-width: min(880px, 90vw);
  margin: 0 auto;
  padding: 0 var(--gutter) clamp(70px, 9vw, 120px);
}
.mail-card {
  position: relative;
  display: grid;
  gap: 6px;
  padding: clamp(26px, 4vw, 44px);
  border: 1px solid var(--line);
  background:
    radial-gradient(70% 130% at 85% 20%, rgba(110, 27, 42, 0.28), transparent 70%),
    rgba(236, 229, 216, 0.015);
  transition: border-color 0.35s, background 0.35s;
}
.mail-card:hover {
  border-color: var(--wine-bright);
}
.mail-kicker {
  font-family: var(--sans);
  font-size: 9.5px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ash);
}
.mail-address {
  font-size: clamp(24px, 4vw, 46px);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.01em;
  word-break: break-word;
}
.mail-arrow {
  position: absolute;
  right: clamp(24px, 4vw, 44px);
  top: 50%;
  transform: translateY(-50%);
  font-size: 28px;
  color: var(--wine-bright);
  transition: transform 0.35s var(--ease);
}
.mail-card:hover .mail-arrow {
  transform: translate(6px, -50%);
}
.scriptorium-copy {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(24px, 5vw, 56px);
  margin-top: clamp(40px, 6vw, 64px);
}
.scriptorium-col h2 {
  font-size: 28px;
  font-weight: 500;
  margin-bottom: 14px;
}
.scriptorium-col p {
  font-size: 16.5px;
  line-height: 1.8;
  color: var(--ash);
  margin-bottom: 14px;
}
.scriptorium-note {
  margin-top: clamp(40px, 6vw, 64px);
  padding-top: 20px;
  border-top: 1px solid var(--line-soft);
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ash-dim);
}
.scriptorium-note a {
  color: var(--bone);
  border-bottom: 1px solid var(--wine);
}

/* ---------- 404 ---------- */

.notfound {
  position: relative;
  z-index: 1;
  min-height: 70vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px var(--gutter);
}
.notfound-code {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(90px, 18vw, 190px);
  line-height: 0.8;
  color: var(--wine);
  opacity: 0.85;
}
.notfound-title {
  margin-top: 20px;
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 500;
  line-height: 1.05;
}
.notfound-copy {
  margin-top: 18px;
  color: var(--ash);
  font-size: 17px;
}
.notfound-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

/* ---------- piede ---------- */

.site-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--line-soft);
  padding: clamp(34px, 5vw, 54px) var(--gutter);
  background: rgba(5, 4, 7, 0.5);
}
.footer-inner {
  max-width: var(--page);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr auto;
  align-items: center;
  gap: 26px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.footer-brand p {
  font-family: var(--serif);
  line-height: 1.3;
  font-size: 15px;
}
.footer-brand strong {
  font-family: var(--sans);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}
.footer-brand span {
  font-size: 13.5px;
  color: var(--ash-dim);
  font-style: italic;
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  justify-content: center;
}
.footer-nav a {
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ash);
  transition: color 0.25s;
}
.footer-nav a:hover {
  color: var(--bone);
}
.footer-meta {
  font-family: var(--sans);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ash-dim);
  text-align: right;
  line-height: 1.9;
}
.footer-candles {
  color: var(--ash);
}
.footer-candles span[aria-hidden] {
  color: var(--wine-bright);
}

/* ---------- toast ---------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  z-index: 150;
  transform: translate(-50%, 20px);
  padding: 12px 20px;
  background: var(--bone);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border-radius: 2px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s, transform 0.3s var(--ease);
  max-width: 88vw;
  text-align: center;
}
.toast.is-on {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ---------- animazioni ---------- */

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(0.8); }
}
@keyframes drift {
  from { transform: translate(-50%, -50%) scale(1); }
  to { transform: translate(-46%, -54%) scale(1.12); }
}
@keyframes cue {
  0% { transform: translateY(-20px); opacity: 0; }
  35% { opacity: 1; }
  100% { transform: translateY(60px); opacity: 0; }
}
@keyframes flicker {
  0%, 100% { transform: scaleY(1) rotate(0deg); opacity: 1; }
  25% { transform: scaleY(1.06) rotate(-1.4deg); opacity: 0.9; }
  55% { transform: scaleY(0.96) rotate(1deg); opacity: 0.98; }
  75% { transform: scaleY(1.03) rotate(-0.6deg); opacity: 0.92; }
}
@keyframes glyphIn {
  from { opacity: 0; transform: translateY(10px) scale(0.96); }
  to { opacity: 0.92; transform: none; }
}
@keyframes riseIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: none; }
}
@keyframes titleIn {
  from { opacity: 0; transform: translateY(26px); filter: blur(10px); }
  to { opacity: 1; transform: none; filter: blur(0); }
}

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

html[data-motion="off"] *,
html[data-motion="off"] *::before,
html[data-motion="off"] *::after {
  animation: none !important;
  transition-duration: 0.001ms !important;
}
html[data-motion="off"] .reveal {
  opacity: 1;
  transform: none;
}
html[data-motion="off"] {
  scroll-behavior: auto;
}
html[data-motion="off"] .embers {
  display: none;
}

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

/* ---------- responsive ---------- */

@media (max-width: 1040px) {
  .thresholds {
    grid-template-columns: repeat(2, 1fr);
  }
  .feature {
    grid-template-columns: 1fr;
  }
  .feature-figure {
    aspect-ratio: 16 / 10;
    max-height: 360px;
  }
  .feature-arch {
    width: 44%;
    height: 88%;
  }
  .manifesto {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .poem-layout {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  .poem-aside {
    position: static;
    order: 2;
  }
  .poem-body {
    order: 1;
    border-left: 0;
    padding-left: 0;
    max-width: 640px;
  }
  .related-grid {
    grid-template-columns: 1fr;
    gap: 26px;
  }
  .footer-inner {
    grid-template-columns: 1fr;
    justify-items: start;
    gap: 22px;
  }
  .footer-nav {
    justify-content: flex-start;
  }
  .footer-meta {
    text-align: left;
  }
}

@media (max-width: 860px) {
  .nav {
    position: fixed;
    inset: 78px 0 auto;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px var(--gutter) 24px;
    background: rgba(7, 6, 10, 0.97);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(16px);
    transform: translateY(-12px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
  }
  .nav a {
    padding: 16px 0;
    border-bottom: 1px solid var(--line-soft);
    font-size: 12px;
  }
  .nav a::after {
    display: none;
  }
  .nav a.is-active {
    color: var(--wine-bright);
  }
  .nav-toggle {
    display: flex;
  }
  body.nav-open .nav {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
  body.nav-open {
    overflow: hidden;
  }
  .section-head {
    grid-template-columns: auto 1fr;
  }
  .section-note {
    display: none;
  }
  .poem-row {
    grid-template-columns: 36px minmax(0, 1fr) 20px;
    gap: 14px;
  }
  .row-chips,
  .row-meta {
    display: none;
  }
  .row-epigraph {
    white-space: normal;
  }
  .row-arrow {
    grid-column: 3;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 18px;
  }
  .site-header {
    height: 68px;
  }
  .nav {
    inset-block-start: 68px;
  }
  .brand-latin {
    display: none;
  }
  .motion-label {
    display: none;
  }
  .motion-toggle {
    padding: 9px;
  }
  .hero {
    min-height: calc(100svh - 68px);
  }
  .hero-title {
    font-size: clamp(38px, 13.6vw, 92px);
  }
  .hero-sub {
    font-size: 9px;
    letter-spacing: 0.3em;
  }
  .hero-verse {
    font-size: 17px;
    max-width: 30ch;
  }
  .hero-actions .btn,
  .notfound-actions .btn {
    width: 100%;
  }
  .hero-actions {
    width: 100%;
    max-width: 320px;
  }
  .thresholds {
    grid-template-columns: 1fr;
  }
  .threshold {
    min-height: 0;
  }
  .feature-title {
    font-size: 42px;
  }
  .section-head {
    gap: 12px;
  }
  .page-head {
    padding-top: 56px;
  }
  .poem-layout {
    padding-bottom: 60px;
  }
  .poem-title {
    font-size: clamp(40px, 13vw, 72px);
  }
  .poem-head {
    padding-top: 48px;
  }
  .poem-body {
    padding-bottom: 10px;
  }
  .scriptorium-copy {
    grid-template-columns: 1fr;
  }
  .mail-arrow {
    display: none;
  }
  .footer-nav {
    gap: 14px;
  }
}

/* ---------- stampa ---------- */

@media print {
  .site-header,
  .site-footer,
  .grain,
  .embers,
  .hero-glow,
  .hero-arch,
  .poem-aside,
  .reading-progress,
  .related-section,
  .scroll-cue,
  .toast,
  .skip {
    display: none !important;
  }
  body {
    background: #fff;
    color: #111;
    font-size: 12pt;
  }
  body::before {
    display: none;
  }
  .poem-head,
  .poem-layout {
    padding: 0;
    margin: 0;
  }
  .poem-layout {
    display: block;
  }
  .poem-body {
    border: 0;
    padding: 0;
    max-width: none;
  }
  .poem-text {
    color: #111;
    font-size: 13pt;
    max-width: none;
  }
  .poem-title {
    font-size: 34pt;
  }
  .poem-epigraph,
  .content-note {
    color: #444;
  }
  .poem-after {
    display: none;
  }
}
