/* Reset & base
   ========================================================================== */

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

/* Prevent WordPress FSE blockGap / is-layout-flow from injecting 24px gaps
   between sticky full-screen sections or template parts */
.wp-site-blocks > *,
#main.is-layout-flow > *,
#main > section.is-layout-flow > * {
  margin-block-start: 0;
  margin-block-end: 0;
}

html {
  font-size: 100%;
  background-color: var(--color-night);
  -webkit-text-size-adjust: 100%;
}

/* A film page is 600vh tall, so the browser's own smooth anchor scroll takes
   several seconds to cross it and decodes every frame on the way. Hash links
   jump straight there; the reveal and stroke observers still play on arrival. */

body {
  min-height: 100vh;
  font-family: var(--font-body);
  font-size: var(--text-body);
  font-weight: var(--weight-body);
  line-height: var(--leading-body);
  letter-spacing: var(--track-body);
  color: var(--color-ivory);
  background-color: var(--color-night);
  font-kerning: normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

/* Content sections pad vertically and clip any animated overshoot */
main > section:not(.film) {
  padding-block: var(--space-section);
  overflow-x: clip;
}

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

ul[role="list"] {
  list-style: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-display);
  font-weight: var(--weight-display);
  line-height: 1.04;
  letter-spacing: var(--track-display);
  color: var(--on-surface, var(--color-ivory));
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
  color: inherit;
}

/* Focus ring: 2px solid with >=3:1 contrast against every surface (WCAG 2.2) */
:focus {
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--focus-ring, var(--color-gold));
  outline-offset: 4px;
}

/* Visually hidden, kept for screen readers */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
