/* Spotlight 2026: hero, theme, days and footer. Mobile first; desktop from 900px. */

/* ---------- Hero: the main visual as a poster ---------- */

/*
  Built like the key visual poster: the tape lettering runs across the whole width, the ring and
  dot are cropped by the bottom and the right edge, and the three on their flying machine come
  out of the dot towards the viewer, in front of the lettering. Layers, back to front:
  ring and dot (.hero__art), lettering, the machine (.hero__flight), then the top bar and copy.
*/
.hero {
  /* The ring's outer diameter and centre; the dot sits in it in the logo's proportions. */
  --ring-d: min(150vw, 78vh);
  --ring-x: 56%;
  --ring-y: 57%;
  /* The flying machine: width and centre. The image is 1800 x 1214. */
  --flight-w: min(128vw, 82vh);
  --flight-x: 50%;
  --flight-y: 54%;
  --flight-ratio: 0.6744;

  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 100vh;
  padding: max(16px, env(safe-area-inset-top)) var(--space-page) max(20px, env(safe-area-inset-bottom));
  overflow: hidden;
  overflow: clip;
}

@supports (height: 1svh) {
  .hero {
    --ring-d: min(150vw, 78svh);
    --flight-w: min(128vw, 82svh);
    min-height: 100svh;
  }
}

.is-intro .hero__art,
.is-intro .hero__top,
.is-intro .hero__tape,
.is-intro .hero__flight,
.is-intro .hero__copy {
  visibility: hidden;
}

.hero__art,
.hero__flight {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero__art {
  z-index: -1;
}

.hero__flight {
  z-index: 1;
}

.hero__ring-fly,
.hero__dot-fly,
.hero__machine-fly {
  position: absolute;
  will-change: transform;
}

.hero__ring-fly,
.hero__dot-fly {
  left: var(--ring-x);
  top: var(--ring-y);
}

.hero__ring-fly {
  width: var(--ring-d);
  height: var(--ring-d);
  margin: calc(var(--ring-d) / -2) 0 0 calc(var(--ring-d) / -2);
}

.hero__ring {
  width: 100%;
  height: 100%;
  border: calc(var(--ring-d) * var(--ring-stroke-ratio)) solid var(--color-blue);
  border-radius: 50%;
}

.hero__dot-fly {
  --dot-d: calc(var(--ring-d) * var(--dot-ratio));
  width: var(--dot-d);
  height: var(--dot-d);
  margin: calc(var(--dot-d) / -2) 0 0 calc(var(--dot-d) / -2);
}

/* Lime, not paper: the heroes read best against it (project owner, 29 Nov 2026: no white behind them). */
.hero__dot {
  width: 100%;
  height: 100%;
  background: var(--color-lime);
  border-radius: 50%;
}

.hero__machine-fly {
  left: var(--flight-x);
  top: var(--flight-y);
  width: var(--flight-w);
  margin: calc(var(--flight-w) * var(--flight-ratio) / -2) 0 0 calc(var(--flight-w) / -2);
}

.hero__machine img {
  width: 100%;
}

.hero__top {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.hero__wordmark {
  width: min(30vw, 132px);
}

.hero__partner {
  display: block;
  width: min(42vw, 176px);
}

.hero__nav {
  display: none;
}

.hero__tape {
  width: 100%;
}

.hero__tape img {
  width: 100%;
}

.hero__copy {
  position: relative;
  z-index: 2;
  display: grid;
  justify-items: start;
  gap: 12px;
  max-width: 34rem;
  margin-top: auto;
}

.hero__title {
  color: var(--color-pink);
  font-family: var(--font-display);
  font-size: clamp(3.25rem, 17vw, 5.5rem);
  font-weight: 400;
  line-height: var(--leading-display);
  letter-spacing: 0.012em;
}

.hero__title .wipe__inner {
  padding-top: 0.05em;
}

.hero__lede {
  max-width: 17.5rem;
  font-size: 1.0625rem;
  font-weight: 500;
  line-height: 1.38;
}

.hero__cta .rise__inner {
  padding: 2px 0;
}

/* Phones: a long first-screen button label (up to 32 letters) stays on one line inside the screen. */
@media (max-width: 899.98px) {
  .hero__cta .btn {
    max-width: 100%;
    padding: 0 16px;
    font-size: min(var(--text-body), 3.75vw);
  }
}

/* Large phones in portrait and small tablets: the same poster, scaled up. */
@media (min-width: 600px) and (max-width: 899.98px) and (min-height: 521px) {
  .hero__wordmark {
    width: min(22vw, 180px);
  }

  .hero__partner {
    width: min(28vw, 230px);
  }

  .hero__lede {
    max-width: 21rem;
    font-size: 1.25rem;
  }
}

/* Phones in landscape: the artwork moves to the right so the copy keeps the left half. */
@media (max-width: 899.98px) and (max-height: 520px) and (orientation: landscape) {
  .hero {
    --ring-d: 118vh;
    --ring-x: 72%;
    --ring-y: 62%;
    --flight-w: 60vw;
    --flight-x: 68%;
    --flight-y: 60%;

    gap: 8px;
  }

  .hero__wordmark {
    width: 13vw;
  }

  .hero__partner {
    width: 18vw;
  }

  .hero__tape {
    width: 46vw;
  }

  .hero__copy {
    gap: 8px;
  }

  .hero__title {
    font-size: 3rem;
  }

  .hero__lede {
    font-size: 0.9375rem;
  }
}

@media (min-width: 900px) {
  .hero {
    --ring-d: min(118vh, 82vw);
    --ring-x: 70%;
    --ring-y: 79%;
    --flight-w: min(58vw, 108vh);
    --flight-x: 67%;
    --flight-y: 71%;

    gap: 2vh;
    padding-top: 28px;
    padding-bottom: var(--space-page);
  }

  @supports (height: 1svh) {
    .hero {
      --ring-d: min(118svh, 82vw);
      --flight-w: min(58vw, 108svh);
    }
  }

  .hero__top {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: clamp(24px, 3vw, 48px);
  }

  .hero__wordmark {
    width: clamp(120px, 10vw, 190px);
  }

  .hero__partner {
    width: clamp(160px, 13vw, 240px);
  }

  .hero__nav {
    display: flex;
    justify-content: flex-end;
    gap: clamp(18px, 2.4vw, 40px);
  }

  .hero__nav a {
    padding: 6px 0;
    font-size: clamp(0.9375rem, 1.05vw, 1.25rem);
    font-weight: 600;
    white-space: nowrap;
    text-decoration: none;
    box-shadow: inset 0 -2px 0 transparent;
    transition: box-shadow var(--duration-fast) linear, color var(--duration-fast) linear;
  }

  .hero__nav a:hover {
    color: var(--color-pink);
    box-shadow: inset 0 -2px 0 var(--color-pink);
  }

  /* "Become a partner": the lime of the partner card, so it stands out from the white links. */
  .hero__nav a.hero__nav-accent {
    color: var(--color-lime);
    box-shadow: inset 0 -2px 0 var(--color-lime);
  }

  .hero__nav a.hero__nav-accent:hover {
    color: var(--color-pink);
    box-shadow: inset 0 -2px 0 var(--color-pink);
  }

  /* As wide as the page allows while the copy still fits under it. */
  .hero__tape {
    width: min(100%, calc((100vh - 400px) * 2.95));
  }

  .hero__copy {
    gap: 16px;
  }

  .hero__title {
    font-size: clamp(4rem, 6.6vw, 8rem);
  }

  .hero__lede {
    max-width: 18em;
    font-size: clamp(1.125rem, 1.3vw, 1.625rem);
  }
}

@media (min-width: 900px) and (max-height: 720px) {
  .hero__title {
    font-size: clamp(3.5rem, 13vh, 6rem);
  }
}

/* ---------- Theme: statement and the dance film ---------- */

/*
  The whole section is the green colourway of the identity, so the film has no frame of its own:
  its field is the section's field, and the part of its ring that runs past the film's edges is
  drawn in CSS (.about__ring) on the exact same circle. On desktop the ring is whole; on phones
  the film runs edge to edge and only the screen cuts the ring.
*/
.about {
  /* The film is painted in the identity's green and lime. It is encoded with colour tags
     (BT.601 matrix, sRGB curve) so browsers show it in those exact colours and it meets the page
     without a seam; see README, "Пересобрать ролик". */
  --film-field: var(--color-green);
  --film-ring: var(--color-lime);

  display: grid;
  gap: 44px;
  overflow: hidden;
  padding: var(--space-section) 0 calc(var(--space-section) * 0.75);
  background-color: var(--film-field);
}

.about__text {
  padding: 0 var(--space-page);
}

.about__statement {
  font-size: clamp(1.5rem, 6.4vw, 1.875rem);
  font-weight: 600;
  line-height: 1.24;
  letter-spacing: -0.005em;
}

.about__statement em {
  color: var(--color-pink);
  font-style: normal;
}

.about__body {
  max-width: 62ch;
  margin-top: 22px;
  color: var(--color-paper-soft);
  line-height: 1.62;
}

.about__film {
  position: relative;
}

.about__film-frame {
  position: relative;
  /* The film is cropped below its own title, from just above the ring to the dancers' feet. */
  aspect-ratio: 1080 / 1464;
  /* Rest state of the iris that opens on the dancers, centred on the film's dot (see js/reveals.js). */
  clip-path: circle(150% at 50% 50.8%);
}

/*
  The film's own ring, measured on the 1080 x 1464 crop: centre at 50% / 50.8%, outer diameter
  1461 px (135.28% of the film's width), stroke and dot in the logo's proportions. Only the parts
  outside the film show; the film covers the rest.
*/
.about__ring {
  --ring-d: 135.28%;

  position: absolute;
  left: 50%;
  top: 50.8%;
  width: var(--ring-d);
  aspect-ratio: 1;
  /* Percent margins are taken from the film's width, so this centres the ring on its dot. */
  margin: calc(var(--ring-d) / -2) 0 0 calc(var(--ring-d) / -2);
  border: 0 solid var(--film-ring);
  border-radius: 50%;
}

@supports (width: 1cqw) {
  .about__film-frame {
    container-type: inline-size;
  }

  .about__ring {
    border-width: calc(135.28cqw * var(--ring-stroke-ratio));
  }
}

.about__video {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  background-color: var(--film-field);
  object-fit: cover;
  object-position: 50% 100%;
}

/* Pause / play for the film (js/reveals.js): a small flat tab in the corner, like the dock. */
.about__toggle {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: rgb(3 3 3 / 0.62);
  color: var(--color-paper);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.about__toggle[hidden] {
  display: none;
}

/* Pause: two bars. */
.about__toggle::before {
  content: "";
  box-sizing: border-box;
  width: 14px;
  height: 16px;
  border-left: 5px solid currentColor;
  border-right: 5px solid currentColor;
}

/* Play: a triangle. */
.about__toggle.is-paused::before {
  width: 0;
  height: 0;
  margin-left: 4px;
  border-style: solid;
  border-width: 8px 0 8px 14px;
  border-color: transparent transparent transparent currentColor;
}

.about__toggle:hover,
.about__toggle:active {
  background: var(--color-black);
}

/* A strip of tape over the top of the ring, as if the ring were taped to the wall. */
.about__tape {
  position: absolute;
  left: 27%;
  top: -1.4%;
  width: 46%;
  rotate: -6deg;
}

@media (min-width: 900px) {
  .about {
    --film-w: min(38vw, 58vh);
    /* How far the drawn ring reaches past each side of the film: (135.28% - 100%) / 2. */
    --ring-reach: calc(var(--film-w) * 0.177);

    grid-template-columns: minmax(0, 1fr) var(--film-w);
    align-items: center;
    column-gap: calc(var(--ring-reach) + clamp(32px, 4vw, 80px));
    padding: var(--space-section) calc(var(--ring-reach) + var(--space-page)) var(--space-section) var(--space-page);
  }

  .about__text {
    padding: 0;
  }

  .about__statement {
    font-size: clamp(2rem, 3.1vw, 3rem);
    line-height: 1.18;
  }

  .about__body {
    margin-top: 32px;
    font-size: 1.125rem;
  }
}

/* ---------- Days and tickets: flat colour panels ---------- */

.days {
  display: grid;
  gap: 12px;
  padding: var(--space-section) var(--space-page) 56px;
}

.day {
  display: grid;
}

.day__inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  grid-template-rows: auto auto 1fr;
  align-content: start;
  column-gap: 8px;
  min-height: 300px;
  padding: 20px 0 0 20px;
  overflow: hidden;
}

.day--guests .day__inner {
  background: var(--color-green);
}

.day--stage .day__inner {
  background: var(--color-blue);
}

.day--tickets .day__inner {
  background: var(--color-lime);
  color: var(--color-black);
}

.day--tickets :focus-visible {
  outline-color: var(--color-black);
}

.day__date {
  grid-column: 1;
  display: flex;
  align-items: flex-end;
  gap: 12px;
  font-weight: 400;
}

.day__numeral {
  flex: none;
}

.day__numeral img {
  width: auto;
  height: clamp(88px, 26vw, 112px);
}

.day__month,
.day__title {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: var(--leading-display);
  letter-spacing: 0.015em;
}

.day__month {
  padding-bottom: 2px;
  font-size: 2.125rem;
}

.day__title {
  grid-column: 1;
  font-size: clamp(3.25rem, 16vw, 4.5rem);
}

.day__text {
  grid-column: 1;
  margin-top: 16px;
  padding-bottom: 20px;
  font-weight: 500;
  line-height: 1.45;
}

.day__link {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

.day__venue {
  grid-column: 1;
  align-self: start;
  margin-bottom: 20px;
  font-family: var(--font-label);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.day__action {
  grid-column: 1;
  align-self: start;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-bottom: 24px;
}

.day__figure {
  grid-column: 2;
  grid-row: 1 / -1;
  align-self: end;
  justify-self: end;
  width: 132%;
  margin: 0 -9% -26% 0;
  pointer-events: none;
}

.day__figure img {
  width: 100%;
}

.day__figure--mirrored {
  scale: -1 1;
}

@media (min-width: 900px) {
  .days {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 16px;
  }

  .day__inner {
    min-height: 460px;
    padding: 36px 0 0 36px;
  }

  .day__numeral img {
    height: clamp(140px, 13vw, 200px);
  }

  .day__month {
    font-size: clamp(2.75rem, 4vw, 4rem);
  }

  .day__text {
    max-width: 24rem;
    margin-top: 24px;
    font-size: 1.25rem;
  }

  .day__figure {
    width: 108%;
    margin: 0 -6% -22% 0;
  }

  .day--tickets {
    grid-column: 1 / -1;
  }

  .day--tickets .day__inner {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    min-height: 380px;
  }

  /* The tickets card is full width, so its text (up to 600 characters) gets a wider column. */
  .day--tickets .day__text {
    max-width: 36rem;
  }

  .day__title {
    font-size: clamp(5rem, 9vw, 8.5rem);
  }

  .day--tickets .day__figure {
    width: 62%;
    margin: 0 8% -46% 0;
  }
}

/* ---------- Finale: when, where and the buy button, last thing before the footer ---------- */

.finale {
  display: grid;
  justify-items: start;
  gap: 14px;
  padding: var(--space-section) var(--space-page) 48px;
}

.finale__title {
  color: var(--color-pink);
  font-family: var(--font-display);
  font-size: clamp(3.5rem, 17vw, 6rem);
  font-weight: 400;
  line-height: var(--leading-display);
  letter-spacing: 0.015em;
}

.finale__title .wipe__inner {
  padding-top: 0.05em;
}

/* The display face has no digits; they fall back to Gotham, which runs larger (as in the menu). */
.finale__digits {
  font-family: var(--font-label);
  font-size: 0.8em;
  font-weight: 700;
  letter-spacing: 0;
}

.finale__where {
  font-family: var(--font-label);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.finale__action {
  margin-top: 18px;
}

@media (min-width: 900px) {
  .finale {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: end;
    column-gap: 40px;
    padding-bottom: 72px;
  }

  .finale__title {
    grid-column: 1;
    font-size: clamp(6rem, 11vw, 11rem);
  }

  .finale__where {
    grid-column: 1;
    font-size: 1.25rem;
  }

  .finale__action {
    grid-column: 2;
    grid-row: 1 / 3;
    align-self: end;
    margin: 0 0 6px;
  }
}

/* ---------- Footer ---------- */

.footer {
  display: grid;
  gap: 32px;
  padding: 24px var(--space-page) max(40px, env(safe-area-inset-bottom));
}

.footer__credit {
  display: grid;
  justify-items: start;
  gap: 12px;
}

.footer__label {
  color: var(--color-paper-soft);
  font-size: var(--text-small);
  font-weight: 600;
}

.footer__label a {
  color: var(--color-paper);
  text-underline-offset: 3px;
}

.footer__label a:hover {
  color: var(--color-pink);
}

.footer__partner {
  display: block;
  width: min(62vw, 260px);
}

.footer__wordmark {
  width: min(44vw, 200px);
}

@media (min-width: 900px) {
  .footer {
    grid-template-columns: 1fr auto;
    align-items: end;
    padding-top: 40px;
    padding-bottom: 56px;
  }

  .footer__credit:last-child {
    justify-items: end;
  }
}
