/* 25 Years of Metropolis x 10 Years of Canopy - Sankeys, Manchester.
   metropolis-mcr.com, Sell Out Events Ltd (CRM u46, page 242). 26 Nov 2026.

   FULL-SCREEN (Adam, 26 Nov): the page IS the poster. Army of Few's
   HIGH_RES_LAYERED.psd (2953x3691) is rebuilt live from its pieces: the plate
   is the page ground (#131313 + the PSD's own grain tile), the three red Sankeys
   photos, the lockup (<h1>), the Sankeys mark and the two rules each sit at
   their PSD coordinate times --s ("one PSD pixel on screen"). Frames, rules and
   the centre pane's shadow are CSS, from the PSD layer effects.

   Two arrangements, same coordinates:
   - STACKED (phones, tablets, squarish windows): the collage runs the width of
     the screen, PSD x 0-2953, cropped at PSD y 180-3460; the form follows.
   - TWO-UP (wide, aspect >= 5/4, >= 900px; and landscape phones): the collage
     is the full height of the viewport anchored bottom-left, so the left pane
     bleeds off the left edge, the hall bleeds off the bottom and the top rule
     runs off the right edge. The sign-up is a fourth framed pane in the open
     plate on the right (it may overlap the hall's right edge on narrower
     windows, the way the panes overlap each other in the artwork).

   Palette, sampled from the graded layers (the PSD's EXCLUSION #262626 @ 54%
   is baked into every image, so the CSS uses the graded values):
     plate #131313 . art red #C4253A (frames, rules, button) . hall stroke #C51515
     lit red #E0283F (large type only, 4.0:1) . ink #EBEBEB . muted #A3A3A3
   Art red on the plate is 2.2:1, so it never carries text; white on it is 8.5:1.
   Type: Albert Sans (OFL), the free near-match for the artwork's Elza. The
   lockup itself stays an image in its real face. */

@font-face {
  font-family: "Albert Sans";
  src: url("/assets/fonts/AlbertSans-var.woff2?v=20261126-1") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --plate: #131313;
  --red: #C4253A;
  --hall: #C51515;
  --lit: #E0283F;
  --ink: #EBEBEB;
  --muted: #A3A3A3;
  --line: #3A3A3A;
  --field: #1C1C1C;
  --err: #FF6B78;
  --font: "Albert Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;

  /* STACKED scene maths (defaults). --s = one PSD pixel. */
  --sw: min(100vw, 620px, 57.6svh);             /* scene height <= ~64svh: form starts on screen 1 */
  --s: calc(var(--sw) / 2953);
  --ox: calc((100vw - var(--sw)) / 2);
  --oy: calc(var(--s) * -180);
  --fw: max(1.5px, calc(var(--s) * 6));          /* pane frame */
  --rw: max(1px, calc(var(--s) * 4));            /* rule */
  --foot: 56px;                                  /* footer band height (two-up layouts) */
  --vh: calc(100svh - var(--foot));              /* screen above the footer */
}

*, *::before, *::after { box-sizing: border-box; }
html {
  background: var(--plate);
  color-scheme: dark;
  -webkit-text-size-adjust: 100%;
  overflow-x: clip;
}
body {
  margin: 0;
  min-height: 100svh;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: transparent;           /* html carries the plate (gotcha 16) */
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img { max-width: none; }
a { color: inherit; }

/* The PSD's OVER GRAIN layer (overlay, 82/255) as a page-wide tile. Above the
   collage, below the form so field text stays clean. */
.grain {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: url("/assets/images/grain.webp?v=20261126-1") repeat 0 0 / 320px 320px;
  mix-blend-mode: overlay;
  opacity: .32;
}

/* ============================================================
   SCENE (stacked defaults)
   ============================================================ */
.stage { position: relative; }
.scene {
  position: relative;
  height: calc(var(--s) * 3280);                 /* PSD y 180 -> 3460 */
  overflow: clip;
}
.scene > * { position: absolute; margin: 0; }
.pane { display: block; height: auto; }
.pane--left,
.pane--right {
  width: calc(var(--s) * 2174);
  outline: var(--fw) solid var(--hall);          /* PSD: Stroke, outside */
}
.pane--left  { left: calc(var(--ox) + var(--s) * -1943); top: calc(var(--oy) + var(--s) * 273); }
.pane--right {
  left: calc(var(--ox) + var(--s) * 1291);
  top:  calc(var(--oy) + var(--s) * 982);
  /* stacked crop ends at PSD y 3460, 86.8% down this pane: melt it out first */
  -webkit-mask-image: linear-gradient(to bottom, #000 62%, transparent 86%);
          mask-image: linear-gradient(to bottom, #000 62%, transparent 86%);
}
.pane--mid {
  left: calc(var(--ox) + var(--s) * 452);
  top:  calc(var(--oy) + var(--s) * 1335);
  width: calc(var(--s) * 2002);
  border: var(--fw) solid var(--red);            /* PSD: Stroke, inside */
  box-shadow: 0 calc(var(--s) * 12) calc(var(--s) * 92) rgba(0, 0, 0, .8);   /* PSD: Drop Shadow 92 */
}
.lockup {
  left: calc(var(--ox) + var(--s) * 452);
  top:  calc(var(--oy) + var(--s) * 397);
  width: calc(var(--s) * 1997);
  font-size: 0;
  line-height: 0;
}
.lockup img { display: block; width: 100%; height: auto; }
.sankeys {
  left: calc(var(--ox) + var(--s) * 452);
  top:  calc(var(--oy) + var(--s) * 3230);
  width: calc(var(--s) * 503);
  height: auto;
}
.rule { display: block; height: var(--rw); background: var(--red); }
.rule--top    { left: calc(var(--ox) + var(--s) * 1281); right: 0; top: calc(var(--oy) + var(--s) * 269); }
.rule--bottom { left: 0; width: calc(var(--ox) + var(--s) * 955); top: calc(var(--oy) + var(--s) * 3435); }

/* One orchestrated moment: the panes strike on like the hall's tubes. Opacity
   only (a held visibility keyframe is unreliable, gotcha 40). */
@media (prefers-reduced-motion: no-preference) {
  .pane { animation: strike 1.15s linear both; }
  .pane--left  { animation-delay: .05s; }
  .pane--right { animation-delay: .22s; }
  .pane--mid   { animation-delay: .42s; }
  .lockup, .sankeys, .rule { animation: settle .8s ease-out .1s both; }
}
@keyframes strike {
  0%   { opacity: 0; }
  7%   { opacity: .85; }
  11%  { opacity: .08; }
  20%  { opacity: .9; }
  25%  { opacity: .3; }
  38%  { opacity: 1; }
  100% { opacity: 1; }
}
@keyframes settle { from { opacity: 0; } to { opacity: 1; } }

/* ============================================================
   SHEET + PANEL
   ============================================================ */
.sheet {
  position: relative;
  z-index: 2;
  padding: 4px 16px 24px;
}
.panel {
  position: relative;
  isolation: isolate;                 /* nothing inside can be covered (gotcha 5) */
  max-width: 460px;
  margin: 0 auto;
  padding: 24px 20px 22px;
  background: var(--plate);
  border: 2px solid var(--red);
  box-shadow: 0 18px 70px rgba(0, 0, 0, .7);
}
.panel__state { display: none; }
.panel[data-form-state="idle"]    .panel__idle,
.panel[data-form-state="otp"]     .panel__otp,
.panel[data-form-state="success"] .panel__success { display: block; }

.panel__title {
  margin: 0 0 12px;
  font-weight: 700;
  font-size: clamp(2.1rem, 9vw, 2.75rem);
  line-height: .98;
  letter-spacing: -.04em;             /* the lockup's Elza tracking, -40 */
  color: #FFFFFF;
  text-wrap: balance;
}
.panel__title em { font-style: normal; color: var(--lit); }
/* Client copy (26 Nov): a longer second line, so the idle title steps down a size. */
.panel__title--copy { font-size: clamp(1.85rem, 7.6vw, 2.35rem); }
.panel__lede--lines { line-height: 1.6; }
.panel__lede { margin: 0 0 4px; font-size: 15.5px; line-height: 1.5; color: #C9C9C9; }
.panel__hint { margin: 12px 0 0; font-size: 14px; color: var(--muted); }
.panel__success-note {
  margin: 0 0 12px; padding: 10px 12px;
  font-size: 14px; color: var(--ink);
  border-left: 3px solid var(--red); background: var(--field);
}

/* ---------- nights: the artwork's date row, as switches ---------- */
.nights { margin: 18px 0 14px; padding: 0; border: 0; min-width: 0; }
.nights legend { padding: 0; }
.nights__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}
.night {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 17px 2px 9px;
  background: var(--field);
  border: 1px solid var(--line);
  cursor: pointer;
  -webkit-user-select: none;
          user-select: none;
  transition: border-color .15s ease, background-color .15s ease;
}
.night:hover { border-color: #5C5C5C; }
.night input {                          /* the real checkbox, invisible over the tile */
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  margin: 0; opacity: 0; cursor: pointer;
}
.night__tube {                          /* a fluorescent tube, off until picked */
  position: absolute;
  top: 7px; left: 24%; right: 24%;
  height: 3px;
  border-radius: 2px;
  background: #2E2E2E;
}
.night__num {
  font-weight: 700;
  font-size: clamp(1.05rem, 5vw, 1.35rem);
  line-height: 1.1;
  letter-spacing: -.045em;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}
.night__day { margin-top: 2px; font-size: 11.5px; line-height: 1.3; color: var(--muted); white-space: nowrap; }

.night input:checked ~ .night__tube {
  background: #FFF3F4;
  box-shadow: 0 0 5px 1px rgba(255, 96, 110, .95), 0 0 16px 4px rgba(209, 20, 42, .7);
}
.night input:checked ~ .night__num { color: #FFFFFF; }
.night input:checked ~ .night__day { color: var(--ink); }
.night:has(input:checked) { border-color: var(--red); background: #211215; }
.night:has(input:focus-visible) { outline: 2px solid #FFFFFF; outline-offset: 2px; }
.nights.is-error .night { border-color: var(--err); }
@media (prefers-reduced-motion: no-preference) {
  .night input:checked ~ .night__tube { animation: tube .34s linear both; }
}
@keyframes tube {
  0% { opacity: .2; } 18% { opacity: 1; } 30% { opacity: .35; } 46% { opacity: 1; } 58% { opacity: .65; } 100% { opacity: 1; }
}

/* ---------- fields ---------- */
.form__row { margin: 0 0 12px; }
.form__label {
  display: block;
  margin: 0 0 6px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink);
}
.form__input {
  display: block;
  width: 100%;
  height: 48px;
  padding: 0 14px;
  font-family: var(--font);
  font-size: 16px;                      /* >= 16px: no iOS zoom on focus */
  color: var(--ink);
  background: var(--field);
  border: 1px solid var(--line);
  border-radius: 0;
  -webkit-appearance: none;
          appearance: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.form__input::placeholder { color: #767676; opacity: 1; }
.form__input:focus { outline: none; border-color: var(--lit); box-shadow: 0 0 0 1px var(--lit); }
/* Chrome autofill: the field is opaque #1C1C1C on an opaque panel, so the
   flattened colour IS #1C1C1C (build-contract). */
.form__input:-webkit-autofill,
.form__input:-webkit-autofill:hover,
.form__input:-webkit-autofill:focus,
.form__input:-webkit-autofill:active {
  -webkit-box-shadow: 0 0 0 1000px #1C1C1C inset !important;
          box-shadow: 0 0 0 1000px #1C1C1C inset !important;
  -webkit-text-fill-color: #EBEBEB !important;
  caret-color: #EBEBEB;
  transition: background-color 9999s ease-in-out 0s;
}
.form__input--otp { letter-spacing: .3em; font-size: 20px; text-align: center; }
.form__error { margin: 6px 0 0; font-size: 13.5px; line-height: 1.4; color: var(--err); }
.form__error--global { margin-top: 12px; text-align: center; }
.hp-row { display: none !important; }   /* honeypot: display:none, never off-screen (gotcha 2) */

.form__row--check { margin: 16px 0 18px; }
.form__check {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink);
  cursor: pointer;
}
.form__check input {
  flex: 0 0 auto;
  width: 20px; height: 20px;
  margin: 1px 0 0;
  accent-color: var(--red);
  cursor: pointer;
}
.form__note { margin: 8px 0 0 31px; font-size: 13px; line-height: 1.5; color: var(--muted); }
.form__note a { color: var(--ink); text-decoration: underline; text-underline-offset: 2px; }
.form__note a:hover, .form__note a:focus-visible { color: #FFFFFF; text-decoration-thickness: 2px; }

.form__resend { margin: 14px 0 0; font-size: 14px; color: var(--muted); text-align: center; }
.form__resend-btn {
  font: inherit; color: var(--ink); background: none; border: 0; padding: 0;
  text-decoration: underline; text-underline-offset: 2px; cursor: pointer;
}
.form__resend-btn:disabled { color: #6E6E6E; cursor: default; text-decoration: none; }

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 52px;
  padding: 12px 18px;
  font-family: var(--font);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: -.01em;
  white-space: nowrap;
  color: #FFFFFF;
  background: var(--red);
  border: 0;
  border-radius: 0;
  cursor: pointer;
  transition: background-color .15s ease, transform .1s ease;
}
.btn:hover:not(:disabled), .btn:focus-visible { background: #D63047; color: #FFFFFF; }
.btn:active:not(:disabled) { transform: translateY(1px); }
.btn:focus-visible { outline: 2px solid #FFFFFF; outline-offset: 3px; }
.btn:disabled { opacity: .7; cursor: default; }

/* ============================================================
   intl-tel-input v25, dark
   ============================================================ */
.iti { width: 100%; display: block; }
.iti input.form__input { padding-left: calc(52px + 0.7rem); }  /* app.js re-measures */
.iti__country-container { z-index: 3; }
.iti--inline-dropdown .iti__dropdown-content { z-index: 50; }
.iti__dropdown-content.iti__hide { display: none !important; }   /* gotcha 19 */
.iti__dropdown-content {
  background: var(--field);
  border: 1px solid #4A4A4A;
  border-radius: 0;
  box-shadow: 0 14px 40px rgba(0, 0, 0, .7);
  overflow: hidden;
}
.iti__search-input {
  padding: 10px 30px 10px 32px;        /* keep the vendor's icon reservations (gotcha 33) */
  width: 100%;
  font-family: var(--font);
  font-size: 15px;
  color: var(--ink);
  background: var(--plate);
  border: 0;
  border-bottom: 1px solid #4A4A4A;
}
.iti__search-input::placeholder { color: #8A8A8A; }
.iti__search-input:focus { outline: none; box-shadow: inset 0 -2px 0 var(--lit); }
.iti__country-list { background: var(--field); max-height: 240px; }
.iti__country { padding: 9px 12px; font-family: var(--font); font-size: 15px; color: var(--ink); }
.iti__country:hover,
.iti__country.iti__highlight { background: #2A2A2A; }
.iti__dial-code { color: var(--muted); }
.iti__country-name { color: var(--ink); }
.iti__selected-country { border-radius: 0; }
.iti__selected-country:hover,
.iti__selected-country-primary:hover { background: rgba(255, 255, 255, .06); }
.iti__selected-dial-code { color: var(--ink); font-family: var(--font); font-weight: 600; font-size: 16px; }
.iti__arrow { border-top-color: var(--ink); }
.iti__arrow--up { border-bottom-color: var(--ink); }

/* ============================================================
   FOOTER: house pattern, credit in a pill
   ============================================================ */
.foot {
  position: relative;
  z-index: 2;                          /* over the grain and any bleeding pane */
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px 16px;
  min-height: var(--foot);
  padding: 12px clamp(16px, 3vw, 36px);
  background: #000;
  border-top: 1px solid var(--red);    /* the poster's rule, closing the page */
}
.foot__left { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px; }
.foot__legal { margin: 0; font-size: 13px; color: var(--muted); }
.foot__legal a { color: var(--ink); text-decoration: none; }
.foot__legal a:hover, .foot__legal a:focus-visible { color: #FFFFFF; text-decoration: underline; }
.site-built { margin: 0; }
.site-built a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px;
  font-size: 11.5px;
  color: #FFFFFF;
  text-decoration: none;
  border: 1px solid #5A5A5A;
  border-radius: 999px;
  transition: border-color .15s ease;
}
.site-built a:hover, .site-built a:focus-visible { border-color: var(--red); color: #FFFFFF; }
.site-built img { display: block; opacity: .9; }   /* dark build: credit as drawn */

@media (max-width: 480px) {          /* stack + centre on every phone width */
  .foot { flex-direction: column; justify-content: center; text-align: center; }
  .foot__left { flex-direction: column; justify-content: center; }
}
@media (max-width: 359px) {
  .panel { padding: 20px 14px 18px; }
  .nights__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ============================================================
   TWO-UP: wide screens. Collage = full viewport height, anchored bottom-left.
   --sh is capped so PSD x 0-2700 always fits beside the panel; the panel may
   cover the hall pane's right-hand ~765 PSD px, never the lockup (ends 2449)
   or the centre pane (ends 2454).
   ============================================================ */
@media (min-width: 900px) and (min-aspect-ratio: 5/4) and (min-height: 521px) {
  :root {
    --pw: 440px;
    --pr: clamp(24px, 4vw, 72px);
    --sh: min(var(--vh), calc((100vw - 470px) * 1.367));
    --s: calc(var(--sh) / 3691);
    --ox: 0px;
    --oy: calc(var(--vh) - var(--sh));
    --fw: max(1.5px, calc(var(--s) * 7));
  }
  .stage { min-height: var(--vh); }
  .scene { position: absolute; inset: 0 0 auto 0; height: var(--vh); }   /* ends at the footer: panes bleed into its edge */
  .pane--right { -webkit-mask-image: none; mask-image: none; }
  .sheet {
    min-height: var(--vh);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px var(--pr) 22px min(calc(var(--s) * 2620), calc(100vw - var(--pw) - var(--pr)));
  }
  .panel { width: var(--pw); max-width: none; margin: 0; padding: 30px 30px 26px; }
  .panel__title { font-size: clamp(2.4rem, 3.4vw, 3rem); }
  .panel__title--copy { font-size: 2.05rem; }   /* 380px panel text column: one-line "We’re doing this for you." */
}

/* ============================================================
   LANDSCAPE PHONES (gotcha 27): two-up on a short screen. After the desktop
   block so it wins at equal specificity.
   ============================================================ */
@media (min-width: 600px) and (min-aspect-ratio: 5/4) and (max-height: 520px) {
  :root {
    --pw: 340px;
    --pr: 16px;
    --sh: min(var(--vh), calc((100vw - 370px) * 1.367));
    --s: calc(var(--sh) / 3691);
    --ox: 0px;
    --oy: calc(var(--vh) - var(--sh));
  }
  .stage { min-height: var(--vh); }
  .scene { position: absolute; inset: 0 0 auto 0; height: var(--vh); }   /* ends at the footer: panes bleed into its edge */
  .pane--right { -webkit-mask-image: none; mask-image: none; }
  .sheet {
    min-height: var(--vh);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 12px var(--pr) 14px min(calc(var(--s) * 2620), calc(100vw - var(--pw) - var(--pr)));
  }
  .panel { width: var(--pw); max-width: none; margin: 0; padding: 16px 16px 14px; }
  .panel__title { font-size: 1.85rem; margin-bottom: 8px; }
  .panel__title--copy { font-size: 1.6rem; }
  .panel__lede { font-size: 14px; }
  .nights { margin: 12px 0 10px; }
  .night { padding: 14px 2px 7px; }
  .night__num { font-size: 1.05rem; }
  .form__input { height: 44px; }
  .form__row--check { margin: 12px 0 14px; }
  .btn { min-height: 46px; }
}
