@font-face { font-family: Poppins; font-style: normal; font-weight: 300; font-display: swap; src: url(/fonts/poppins-300-latin.v24.woff2) format("woff2"); }
@font-face { font-family: Poppins; font-style: normal; font-weight: 400; font-display: swap; src: url(/fonts/poppins-400-latin.v24.woff2) format("woff2"); }
@font-face { font-family: Poppins; font-style: normal; font-weight: 500; font-display: swap; src: url(/fonts/poppins-500-latin.v24.woff2) format("woff2"); }
/* JetBrains Mono (variable) for all text except the two large headings, which stay Poppins 700.
   Poppins 300/400/500 are kept in /fonts for switching back. */
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 100 800; font-display: swap; src: url(/fonts/jetbrainsmono-latin.v24.woff2) format("woff2"); }
@font-face { font-family: Poppins; font-style: normal; font-weight: 700; font-display: swap; src: url(/fonts/poppins-700-latin.v24.woff2) format("woff2"); }

:root {
  --navy: #0b0f45;  /* matches the Lost Christmas page */
  --cream: #fffbef;
  --yellow: #ffec02;
  --text-dark: #0b0f45;
  --grey: #767676;
  --hamlet-bg: #010302;  /* matches the black in the Hamlet images */
  --white: #ffffff;
  --blue: #1384dc;
  --border: 22px;
  --radius: 10px;
  --edge: 1px solid #707070;

  /* Headings scale between the 430px and 1920px mockups. */
  --h-intro: clamp(3.1875rem, 2.72rem + 1.745vw, 4.8125rem);  /* 51px -> 77px */
  --h-dates: clamp(2.25rem, 1.8rem + 1.9vw, 3.5rem);  /* 36px -> 56px; two headings (Lost Christmas screenings, Hamlet) */
}

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

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

body {
  margin: 0;
  background: var(--navy);
  color: var(--white);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-weight: 400;
  line-height: 1.25;
}

p, h1, h2, h3, ul { margin: 0; padding: 0; }

a { color: inherit; text-underline-offset: 0.15em; }
a:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; border-radius: 2px; }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

/* ---------- Single column (default, < 1200px) ---------- */

.col { padding: 0 24px; }
.col--navy { padding-top: 16px; }
.col--cream { padding-bottom: 56px; }

.hamlet, .dates, .footer { margin-inline: auto; text-align: center; }

/* Hero, one column: stacked when upright, side by side when sideways, both at the same width,
   followed by the Lost Christmas dates. The two-column hero is further down.
   Breakpoint and orientation must match POSTER_SIZES in render.js. */
.posters {
  --w: 100vw;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  /* Edge to edge: cancel the navy column's padding. */
  margin: -16px -24px 0;
}
@media (orientation: landscape) {
  .posters {
    --w: calc((100vw - 48px) / 2);
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    padding-top: 16px;
  }
}
.posters__link { display: block; }
.posters__link:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; border-radius: 0; }
.posters__img {
  display: block;
  width: var(--w);
  height: auto;
}

/* Lost Christmas poster: no rotation any more; both posters always show. */
/* Diagonal yellow strip across the bottom of the Lost Christmas image (same strip as on the Lost Christmas page banner).
   It is part of the whole-image link, not a second link. The overlay covers just the image, so the strip's corners are clipped to it. */
.swap__link { position: relative; }
.swap__strips { position: absolute; inset: 0; overflow: hidden; container-type: inline-size; pointer-events: none; }
.swap__strip {
  position: absolute; left: -4%; width: 108%; bottom: 13%;
  transform: rotate(-3.5deg);
  padding: 0.76em 1.2em 0.64em; text-align: center;  /* caps have no descenders, so a little more space above than below centres them */
  background: #faf08f; color: #0c0a4d;
  font-family: "JetBrains Mono", ui-monospace, monospace; font-weight: 700; text-transform: uppercase;
  font-size: 0.7rem; font-size: clamp(0.5rem, 2.9cqw, 1rem);
  letter-spacing: 0.05em; line-height: 1.3; text-wrap: balance;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.4);
}

/* Pulse on the strip, once: 2s after load it grows quickly (0.28s) then eases back to normal over 0.72s. */
@keyframes swap-pulse {
  0%   { transform: rotate(-3.5deg) scale(1); animation-timing-function: ease-out; }
  28%  { transform: rotate(-3.5deg) scale(1.07); animation-timing-function: ease-out; }
  100% { transform: rotate(-3.5deg) scale(1); }
}
@media (prefers-reduced-motion: no-preference) {
  .swap__strip { animation: swap-pulse 1s 2s 1 both; }
}

/* Hamlet feature: black panel in the navy column. */
.hamlet {
  position: relative;
  max-width: 1000px;
  margin-top: 32px;
  padding: 40px 20px;
  background: var(--hamlet-bg);
  border-radius: 12px;
  scroll-margin-top: 64px;
}
.hamlet__heading {
  font-family: Poppins, system-ui, sans-serif;
  color: var(--yellow);
  font-weight: 700;
  font-size: var(--h-intro);
  line-height: 1.15;
  text-transform: uppercase;
}

.hamlet__text {
  max-width: 800px;
  margin: 32px auto 0;
  font-size: 1.125rem;
}
.hamlet__text > * + * { margin-top: 1.25em; }

.hamlet__where {
  margin-top: 12px;
  color: var(--yellow);
  font-size: 1.125rem;
  text-wrap: balance;
}
.hamlet__where .part, .hamlet__credits .part { display: inline-block; }
.hamlet__only { color: var(--white); }

/* Pull quote: big yellow quote mark, white text, yellow attribution. */
.hamlet__quote {
  max-width: 640px;
  margin: 36px auto 0;
}
.hamlet__quote blockquote { margin: 0; }
.hamlet__quote blockquote::before {
  content: "\201C";
  display: block;
  height: 0.5em;
  font-family: Poppins, system-ui, sans-serif;
  font-weight: 700;
  font-size: 4.5rem;
  line-height: 1;
  color: var(--yellow);
}
.hamlet__quote blockquote p {
  font-weight: 500;
  font-size: 1.375rem;
  line-height: 1.35;
  text-wrap: balance;
}
.hamlet__quote figcaption {
  margin-top: 12px;
  color: var(--yellow);
  font-weight: 700;
  font-size: 1rem;
}
.hamlet__quote figcaption::before { content: "\2014\00a0"; }

.hamlet__img {
  display: block;
  width: 100%;
  max-width: 600px;
  height: auto;
  margin: 0 auto;
}
.hamlet__text picture { display: block; }

.hamlet__credits {
  color: var(--yellow);
  font-size: 0.9375rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.dates {
  max-width: 580px;
  margin-top: 48px;
  scroll-margin-top: 24px;
}
.show { scroll-margin-top: 24px; }

.dates__heading {
  font-family: Poppins, system-ui, sans-serif;
  color: var(--yellow);
  font-weight: 700;
  font-size: var(--h-dates);
  line-height: 1.1;
  text-transform: uppercase;
}

.dates__month {
  margin: 24px 0 8px;
  color: var(--yellow);
  font-weight: 300;
  font-size: 2.25rem;
}

.dates__list { list-style: none; }

.show { margin-top: 24px; font-size: 0.9375rem; line-height: 1.3; }
.show:first-child { margin-top: 0; }
.show__day { font-weight: 700; font-size: 1.375rem; }
.show__name { color: var(--yellow); font-weight: 500; }
/* Long location lines break evenly between parts, never inside one. */
.show__where { text-wrap: balance; }
.show__where .part { display: inline-block; max-width: 100%; }
.show__note { color: var(--yellow); }
.show__tickets, .show__status { font-weight: 700; font-size: 1.375rem; }  /* same size as .show__day */
.show__tickets a:hover, .show__tickets a:focus-visible { color: var(--yellow); }

.show--hamlet {
  margin-top: 40px;
  padding: 32px 12px;
  background: var(--hamlet-bg);
  border: 1px solid var(--hamlet-bg);
  border-radius: 12px;
}
/* All Hamlet text is yellow, at both widths; the ticket link turns white on hover. */
.show--hamlet,
.show--hamlet .show__day,
.show--hamlet .show__name,
.show--hamlet .show__where,
.show--hamlet .show__tickets,
.show--hamlet .show__status { color: var(--yellow); }
.show--hamlet .show__tickets a:hover, .show--hamlet .show__tickets a:focus-visible { color: var(--white); }

.dates__empty { margin-top: 24px; font-size: 1.25rem; }

/* Two date panels, Lost Christmas above Hamlet. One column: Lost Christmas has a yellow outline. */
.dates--lc {
  padding: 40px 16px 48px;
  border: 1px solid var(--yellow);
  border-radius: 12px;
}
.dates--hamlet { margin-top: 56px; }
.dates--lc .show__tickets a { text-decoration-thickness: 2px; }

/* One column: posters, Lost Christmas dates, Hamlet box (which carries the ticket link).
   Two columns show the dates panels in the cream column instead. */
.dates--lc-wide, .dates--hamlet { display: none; }
.dates--lc-narrow { width: calc(100% - 48px); margin-top: 16px; }  /* with the posters' gap: 32px, as below the panel */
.hamlet__tickets { margin-top: 16px; color: var(--yellow); font-weight: 700; font-size: 1.375rem; }
.hamlet__tickets a:hover, .hamlet__tickets a:focus-visible { color: var(--white); }

.footer {
  margin-top: 56px;
  color: var(--yellow);
  font-weight: 700;
  font-size: 1rem;
}

/* ---------- Two columns (>= 1200px) ---------- */

@media (min-width: 1200px) {
  body { background: var(--white); }

  .page {
    display: grid;
    /* 50/50 up to a 1600px window; beyond that the navy column stays 778px wide
       and the dates column takes the extra width. */
    grid-template-columns: min(50%, 778px) 1fr;
    min-height: 100vh;
    min-height: 100dvh;
    padding: var(--border);
  }

  .col { padding: 18px 40px 40px; }
  /* Outline runs round the outside of both columns, not down the middle. */
  .col--navy {
    background: var(--navy);
    border: var(--edge);
    border-right: 0;
    border-radius: var(--radius) 0 0 var(--radius);
  }
  .col--cream {
    display: flex;
    flex-direction: column;
    padding-top: 40px;  /* same as the side padding, so the gap above the Lost Christmas box matches the gaps beside it */
    background: var(--cream);
    color: var(--grey);
    border: var(--edge);
    border-left: 0;
    border-radius: 0 var(--radius) var(--radius) 0;
  }

  /* Posters stacked, edge to edge, up to the white border; top-left corner follows the column's rounded corner. */
  .posters {
    --w: 100%;
    flex-direction: column;
    flex-wrap: nowrap;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    padding-top: 0;
    margin: -18px -40px 0;
    overflow: hidden;
    border-top-left-radius: calc(var(--radius) - 1px);
  }
  .posters__link:focus-visible { outline-offset: -3px; }

  .hamlet {
    max-width: 800px;
    margin-top: 40px;  /* same as the column's side padding, so the gap under the posters matches the border */
    padding: 48px 40px;
    border: 1px solid var(--yellow);
  }
  .hamlet__tickets, .dates--lc-narrow { display: none; }
  .hamlet__text { font-size: 1.25rem; }
  .hamlet__where { font-size: 1.25rem; }
  .hamlet__quote blockquote p { font-size: 1.625rem; }

  .dates {
    width: 100%;
    max-width: 640px;
    margin-top: 0;
  }
  .dates--lc-wide, .dates--hamlet { display: block; }
  .dates--hamlet { margin-top: 64px; }

  .dates__heading { color: var(--grey); }

  /* Lost Christmas: a navy panel on the cream column; Hamlet stays on cream. */
  .dates--lc {
    max-width: 640px;
    padding: 48px 40px 56px;
    background: var(--navy);
    border-color: var(--navy);
    color: var(--white);
  }
  .dates--lc .dates__heading, .dates--lc .dates__month { color: var(--yellow); }
  .dates--lc .show__day, .dates--lc .show__tickets, .dates--lc .show__status { color: var(--white); }
  .dates--lc .show__where, .dates--lc .show__note { color: #d6d8ee; }
  .dates--lc .show__tickets a:hover, .dates--lc .show__tickets a:focus-visible { color: var(--yellow); }
  .dates--lc .dates__empty { color: var(--white); }
  .dates--hamlet { margin-top: 64px; }

  .dates__month {
    margin: 64px 0 28px;
    color: var(--text-dark);
  }
  .dates__heading + .dates__month { margin-top: 40px; }

  .show { margin-top: 28px; }
  .show__day { color: var(--text-dark); }
  .show__name { color: var(--blue); }
  .show__tickets a:hover, .show__tickets a:focus-visible { color: var(--blue); }
  .show__where, .show__note { color: var(--grey); }
  .show__tickets, .show__status { color: var(--text-dark); }

  .show--hamlet {
    max-width: 556px;
    margin: 48px auto 0;
    padding: 40px 24px;
  }

  .dates__empty { color: var(--text-dark); margin-top: 48px; }

  /* Pushed to the bottom of the cream column on tall windows; follows the content on short ones. */
  .footer {
    margin-top: auto;
    padding-top: 80px;
    color: var(--grey);
    font-weight: 400;
    font-size: 0.875rem;
  }
}

/* Sold-out Lost Christmas dates: yellow text (the panel behind is navy at every width). Other sold-out dates are black. */
.show__status--soldout { color: #000; }
.dates--lc .show__status--soldout { color: var(--yellow); }
