@import url("https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700&family=IBM+Plex+Mono:wght@400;500;600&display=swap");

:root {
  --gold: #dec64a;
  --gold-soft: #8f8136;
  --ink: #080907;
  --panel: #12140f;
  --line: #353925;
  --muted: #979b83;
  --paper: #ece7d6;
  --danger: #d65645;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--paper);
  font-family: "IBM Plex Mono", Consolas, monospace;
  background:
    radial-gradient(circle at 12% 0%, rgb(91 84 30 / 14%), transparent 40rem),
    radial-gradient(circle at 88% 18%, rgb(53 57 37 / 35%), transparent 28rem),
    #080907;
}

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

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

a:hover {
  color: #f2e27a;
}

.site-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1.25rem;
  background: rgb(8 9 7 / 88%);
  border-bottom: 1px solid rgb(53 57 37 / 70%);
  backdrop-filter: blur(6px);
}

.site-nav .brand {
  font-family: Cinzel, Georgia, serif;
  letter-spacing: 0.18em;
  font-size: 0.78rem;
  color: var(--gold);
  text-transform: uppercase;
}

.site-nav .links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.1rem;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.site-nav .links a {
  color: var(--muted);
}

.site-nav .links a:hover {
  color: var(--gold);
}

/* —— Hero —— */
.hero {
  position: relative;
  min-height: 100dvh;
  display: grid;
  align-items: end;
  overflow: hidden;
}

.hero-media {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  filter: saturate(0.85) contrast(1.05);
  transform: scale(1.04);
  animation: hero-drift 28s ease-in-out infinite alternate;
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgb(8 9 7 / 35%) 0%, rgb(8 9 7 / 82%) 58%, #080907 100%);
}

.hero-copy {
  position: relative;
  z-index: 1;
  width: min(92vw, 68rem);
  max-width: none;
  margin-inline: auto;
  padding: 2rem 1.4rem 3.5rem;
  text-align: center;
}

.eyebrow {
  display: block;
  color: var(--gold-soft);
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
  opacity: 0;
  animation: rise 0.9s ease 0.15s forwards;
}

.hero h1 {
  margin: 0;
  font-family: Cinzel, Georgia, serif;
  font-size: clamp(2.4rem, 9vw, 4.4rem);
  letter-spacing: 0.16em;
  color: var(--gold);
  line-height: 1;
  text-shadow: 0 2px #000;
  opacity: 0;
  animation: rise 0.9s ease 0.28s forwards;
}

.hero-lead {
  margin: 1rem auto 0;
  width: min(92vw, 68rem);
  max-width: none;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.55;
  text-align: left;
  opacity: 0;
  animation: rise 0.9s ease 0.42s forwards;
}

.hero-cta {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.4rem;
  opacity: 0;
  animation: rise 0.9s ease 0.55s forwards;
}

.btn {
  border: 1px solid var(--gold-soft);
  background: #24281c;
  color: var(--gold);
  padding: 0.65rem 1rem;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.btn.ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--muted);
}

.btn:hover {
  border-color: var(--gold);
  color: var(--gold);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes hero-drift {
  from {
    transform: scale(1.04) translate3d(0, 0, 0);
  }
  to {
    transform: scale(1.08) translate3d(-1.5%, -1%, 0);
  }
}

/* —— Layout —— */
main {
  display: block;
}

.section {
  padding: 4.5rem 1.4rem;
  max-width: 68rem;
  margin: 0 auto;
}

.section-kicker {
  color: var(--gold-soft);
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  margin: 0 0 0.5rem;
}

.section h2 {
  margin: 0 0 0.75rem;
  font-family: Cinzel, Georgia, serif;
  font-size: clamp(1.5rem, 4vw, 2.2rem);
  letter-spacing: 0.08em;
  color: var(--gold);
}

.section > .lede {
  margin: 0 0 2rem;
  max-width: 38rem;
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.9rem;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.stat {
  border-top: 1px solid var(--line);
  padding-top: 0.75rem;
}

.stat strong {
  display: block;
  font-family: Cinzel, Georgia, serif;
  color: var(--gold);
  font-size: 1.5rem;
  letter-spacing: 0.06em;
}

.stat span {
  color: var(--muted);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* —— Chapters —— */
.chapter {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 2rem 2.5rem;
  align-items: center;
  padding: 3.5rem 1.4rem;
  max-width: 68rem;
  margin: 0 auto;
  border-top: 1px solid rgb(53 57 37 / 55%);
}

.chapter.reverse {
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
}

.chapter.reverse .chapter-copy {
  order: 2;
}

.chapter.reverse .chapter-visual {
  order: 1;
}

.chapter-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.75rem;
  margin-bottom: 0.65rem;
}

.pill {
  border: 1px solid var(--line);
  color: var(--muted);
  padding: 0.2rem 0.55rem;
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.pill.danger {
  border-color: #7a2f28;
  color: #ff8a78;
}

.pill.ship {
  border-color: var(--gold-soft);
  color: var(--gold);
}

.chapter h3 {
  margin: 0 0 0.7rem;
  font-family: Cinzel, Georgia, serif;
  font-size: clamp(1.25rem, 3vw, 1.7rem);
  letter-spacing: 0.06em;
  color: #f3e7c2;
}

.chapter p {
  margin: 0 0 0.85rem;
  color: var(--muted);
  line-height: 1.55;
  font-size: 0.86rem;
}

.chapter ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.chapter li {
  position: relative;
  padding-left: 1rem;
  margin: 0.35rem 0;
  color: #cfc6a8;
  font-size: 0.78rem;
  line-height: 1.45;
}

.chapter li::before {
  content: "—";
  position: absolute;
  left: 0;
  color: var(--gold-soft);
}

.chapter-visual {
  position: relative;
}

.chapter-visual figure {
  margin: 0;
}

.chapter-visual img {
  width: 100%;
  border: 1px solid var(--line);
  background: #050705;
}

.chapter-visual figcaption {
  margin-top: 0.55rem;
  color: var(--muted);
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
}

.compare-match-height {
  align-items: end;
  justify-items: center;
}

.compare-match-height img {
  width: auto;
  height: min(420px, 70vw);
  max-width: 100%;
  object-fit: contain;
  object-position: bottom center;
}

.triptych {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 1.5rem 0 1.75rem;
}

.triptych figure,
.proc-grid figure {
  margin: 0;
}

.triptych img,
.proc-grid img {
  width: 100%;
  border: 1px solid var(--line);
  background: #050705;
  image-rendering: auto;
}

.triptych figcaption,
.proc-grid figcaption {
  margin-top: 0.45rem;
  color: var(--muted);
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.proc-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}

.hel-gif-figure {
  margin: 0 0 0.85rem;
}

.hel-gif-figure img {
  width: min(220px, 100%);
  margin: 0 auto;
  border: 1px solid var(--line);
  background: #080907;
  image-rendering: auto;
}

.figure-compact img {
  width: min(260px, 100%);
  margin: 0 auto;
  display: block;
}

.color-swatch {
  display: inline-block;
  width: 0.85em;
  height: 0.85em;
  margin: 0 0.2em;
  vertical-align: -0.1em;
  border: 1px solid var(--line);
  background: #00b140;
}

code {
  color: var(--gold-soft);
  font-size: 0.84em;
}

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

/* —— Disaster gallery —— */
.disaster {
  background: #0b0c09;
  border-top: 1px solid #5a2a24;
  border-bottom: 1px solid #5a2a24;
}

.disaster .section {
  max-width: 68rem;
}

.gallery {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 1rem;
  margin-top: 1.5rem;
}

.gallery img {
  width: 100%;
  border: 1px solid #5a2a24;
  background: #050705;
}

.gallery .note {
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 1rem 1.1rem;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.5;
}

.gallery .note strong {
  display: block;
  color: #ff8a78;
  font-family: Cinzel, Georgia, serif;
  letter-spacing: 0.08em;
  margin-bottom: 0.5rem;
}

.cast-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65rem;
  margin-top: 1.25rem;
}

.cast-row figure {
  margin: 0;
}

.cast-row img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center top;
  border: 1px solid var(--line);
  background: #0d3a28;
}

.cast-row figcaption {
  margin-top: 0.35rem;
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

/* —— Comments —— */
.comments {
  max-width: 42rem;
  margin: 0 auto;
  padding: 3.5rem 1.4rem 4rem;
  border-top: 1px solid var(--line);
}

.comment-form {
  margin: 1.5rem 0 2.25rem;
  display: grid;
  gap: 0.9rem;
}

.comment-hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.comment-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.comment-form label {
  display: grid;
  gap: 0.35rem;
  color: var(--muted);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.comment-form label em {
  font-style: normal;
  color: #6f7460;
  text-transform: none;
  letter-spacing: 0;
}

.comment-form input,
.comment-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  background: #0c0d0a;
  color: var(--paper);
  font: inherit;
  font-size: 0.86rem;
  letter-spacing: 0;
  text-transform: none;
  padding: 0.65rem 0.75rem;
  border-radius: 0;
}

.comment-form textarea {
  resize: vertical;
  min-height: 7rem;
  line-height: 1.5;
}

.comment-form input:focus,
.comment-form textarea:focus {
  outline: 1px solid var(--gold-soft);
  border-color: var(--gold-soft);
}

.comment-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem 1.1rem;
}

.comment-status {
  margin: 0;
  font-size: 0.75rem;
  color: var(--muted);
}

.comment-status[data-kind="ok"] {
  color: #b7c48a;
}

.comment-status[data-kind="error"] {
  color: #ff8a78;
}

.comment-list {
  display: grid;
  gap: 1rem;
}

.comment-item {
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 0.95rem 1.05rem;
}

.comment-item header {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.85rem;
  align-items: baseline;
  margin-bottom: 0.55rem;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.comment-item header strong {
  color: var(--gold);
  font-weight: 600;
}

.comment-email {
  color: #8a9078;
  text-transform: none;
  letter-spacing: 0;
}

.comment-item time {
  margin-left: auto;
}

.comment-item p {
  margin: 0;
  color: #d8d2bc;
  font-size: 0.86rem;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.comment-empty {
  margin: 0;
  color: var(--muted);
  font-size: 0.8rem;
}

/* —— Closing —— */
.closing {
  text-align: center;
  padding: 5rem 1.4rem 4rem;
}

.closing h2 {
  margin: 0;
  font-family: Cinzel, Georgia, serif;
  letter-spacing: 0.14em;
  color: var(--gold);
  font-size: clamp(1.6rem, 5vw, 2.4rem);
}

.closing p {
  margin: 0.9rem auto 1.5rem;
  max-width: 28rem;
  color: var(--muted);
  line-height: 1.55;
}

.site-foot {
  border-top: 1px solid var(--line);
  padding: 1.2rem 1.4rem 2rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  color: var(--muted);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

@media (max-width: 860px) {
  .stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .chapter,
  .chapter.reverse {
    grid-template-columns: 1fr;
  }

  .chapter.reverse .chapter-copy,
  .chapter.reverse .chapter-visual {
    order: initial;
  }

  .gallery,
  .cast-row,
  .triptych,
  .proc-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 520px) {
  .site-nav .links {
    display: none;
  }

  .comment-fields {
    grid-template-columns: 1fr;
  }

  .cast-row,
  .compare,
  .triptych,
  .proc-grid {
    grid-template-columns: 1fr;
  }

  .gallery {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-media img,
  .eyebrow,
  .hero h1,
  .hero-lead,
  .hero-cta,
  .reveal {
    animation: none !important;
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}
