/* Asian Waters — asianwaters.org
   Type and colour follow the title-card spec: Trajan-style caps serif,
   off-white #F4F4F2, chapter line in dimmer #D8D8D4. No accent colour. */

:root {
  --ink:        #F4F4F2;
  --ink-dim:    #D8D8D4;
  --ink-muted:  #8E9498;
  --ink-faint:  #5A6165;
  --ground:     #101315;
  --ground-alt: #161A1C;
  --rule:       #2A3033;
  --measure:    40rem;
}

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

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

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: "EB Garamond", Georgia, "Times New Roman", serif;
  font-size: 19px;
  line-height: 1.62;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

/* ---------- structure ---------- */

.wrap { max-width: 56rem; margin: 0 auto; padding: 0 2rem; }
.narrow { max-width: var(--measure); }

section { padding: 4.5rem 0; }
section + section { border-top: 1px solid var(--rule); }

/* ---------- masthead ---------- */

header.site {
  padding: 2rem 0 1.75rem;
  border-bottom: 1px solid var(--rule);
}
header.site .wrap {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}
.wordmark {
  font-family: "Cinzel", Georgia, serif;
  font-size: 1.05rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
nav.site { display: flex; gap: 1.75rem; flex-wrap: wrap; }
nav.site a {
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-muted);
  text-decoration: none;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
}
nav.site a:hover { color: var(--ink); }
nav.site a[aria-current="page"] { color: var(--ink-dim); border-bottom-color: var(--ink-faint); }

/* ---------- title lock-up (mirrors the film title card) ---------- */

.lockup { text-align: center; padding: 6rem 0 3.5rem; }
/* the global max-width on <p> would otherwise box these left of centre;
   clearing it lets text-align:center work against the full column */
.lockup p { max-width: none; }
.lockup h1 {
  font-family: "Cinzel", Georgia, serif;
  font-weight: 400;
  font-size: clamp(2rem, 5.4vw, 3.4rem);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 1.1rem;
  line-height: 1.2;
}
.lockup .subtitle {
  font-style: italic;
  font-size: clamp(1rem, 2vw, 1.3rem);
  color: var(--ink-dim);
  margin: 0 0 1.6rem;
}
.lockup .chapterline {
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.68rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin: 0;
}

/* ---------- headings ---------- */

h2 {
  font-family: "Cinzel", Georgia, serif;
  font-weight: 400;
  font-size: 1.5rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 0 0 1.6rem;
  color: var(--ink);
}
h3 {
  font-family: "Cinzel", Georgia, serif;
  font-weight: 400;
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin: 0 0 1rem;
}

p { margin: 0 0 1.3rem; max-width: var(--measure); }

/* Prose sits in a measure-width column, centred on the same axis as the
   lock-up above it. Text stays ranged left; only the column is centred. */
section > .wrap > h2,
section > .wrap > h3,
section > .wrap > p,
section > .wrap > .credits,
section > .wrap > .notice,
section > .wrap > .todo,
section > .wrap > article:not(.chapter) {
  max-width: var(--measure);
  margin-left: auto;
  margin-right: auto;
}
/* breathing room when a sub-heading follows a paragraph */
section > .wrap > p + h3 { margin-top: 2.4rem; }

/* full-bleed elements keep the wider column but share the same centre */
section > .wrap > .player,
section > .wrap > .people { max-width: none; }
p.lede { font-size: 1.22rem; line-height: 1.55; color: var(--ink-dim); }
p:last-child { margin-bottom: 0; }

a { color: var(--ink); text-decoration-color: var(--ink-faint); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }

/* ---------- chapter index (home) ---------- */

.chapter {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
  padding: 4.5rem 0;
}
/* nudge the image down to the cap-height of the heading beside it,
   so the two columns start on the same optical line */
.chapter .media { padding-top: 0.55rem; }
.chapter + .chapter { border-top: 1px solid var(--rule); }
.chapter .body h2 { font-size: 1.7rem; margin-bottom: 0.5rem; }
.chapter .body .subtitle {
  font-style: italic;
  color: var(--ink-dim);
  margin: 0 0 1.4rem;
}
.chapter .body p { font-size: 1rem; color: var(--ink-dim); }

.more {
  display: inline-block;
  margin-top: 0.6rem;
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--ink-faint);
  padding-bottom: 3px;
}
.more:hover { border-bottom-color: var(--ink); }

/* ---------- media ---------- */

.still {
  width: 100%;
  height: auto;          /* without this the HTML height attribute wins and the frame goes tall */
  aspect-ratio: 16 / 9;
  background: var(--ground-alt);
  border: 1px solid var(--rule);
  display: block;
  object-fit: cover;
}

/* placeholder plate — replace with a real frame, then delete this class */
.slot {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1.5rem;
  color: var(--ink-faint);
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  line-height: 2;
}

.player {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--ground-alt);
  border: 1px solid var(--rule);
  margin-bottom: 1.6rem;
}
.player iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

figcaption {
  font-size: 0.85rem;
  color: var(--ink-faint);
  font-style: italic;
  margin-top: 0.7rem;
}

/* ---------- credits block ---------- */

.credits {
  border-top: 1px solid var(--rule);
  margin-top: 3.5rem;
  padding-top: 2rem;
  font-size: 0.92rem;
  color: var(--ink-muted);
}
.credits dl { display: grid; grid-template-columns: 11rem 1fr; gap: 0.55rem 1.5rem; margin: 0; }
.credits dt {
  font-family: "Cinzel", Georgia, serif;
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-faint);
  padding-top: 0.3rem;
}
.credits dd { margin: 0; color: var(--ink-dim); }

/* ---------- people ---------- */

.people { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; }
.person .portrait { width: 100%; aspect-ratio: 4 / 5; }
.person h3 { margin-top: 1.2rem; color: var(--ink); font-size: 0.95rem; letter-spacing: 0.14em; }
.person .role { font-style: italic; color: var(--ink-muted); font-size: 0.95rem; margin: -0.6rem 0 1.1rem; }
.person p { font-size: 0.98rem; color: var(--ink-dim); }

/* ---------- notice ---------- */

.notice {
  border-left: 2px solid var(--rule);
  padding: 0.3rem 0 0.3rem 1.4rem;
  color: var(--ink-muted);
  font-style: italic;
  max-width: var(--measure);
}

/* ---------- footer ---------- */

footer.site {
  border-top: 1px solid var(--rule);
  padding: 3rem 0 4rem;
  font-size: 0.86rem;
  color: var(--ink-faint);
}
footer.site .wrap { display: flex; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
footer.site a { color: var(--ink-muted); }

/* ---------- editorial note (delete before publishing) ---------- */

.todo {
  background: #1D1408;
  border: 1px solid #3A2A10;
  color: #C9A96A;
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 0.72rem;
  line-height: 1.7;
  letter-spacing: 0;
  padding: 0.9rem 1.1rem;
  margin: 1.5rem 0;
  max-width: var(--measure);
}
.todo b { color: #E4C98C; font-weight: 600; }

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

@media (max-width: 800px) {
  body { font-size: 18px; }
  .chapter { grid-template-columns: 1fr; gap: 1.8rem; padding: 3.5rem 0; }
  .chapter .media { order: -1; }
  .people { grid-template-columns: 1fr; gap: 3rem; }
  .credits dl { grid-template-columns: 1fr; gap: 0.2rem 0; }
  .credits dd { margin-bottom: 0.9rem; }
  .lockup { padding: 4rem 0 3rem; }
  section { padding: 4rem 0; }
}
