/*
Theme Name: &Dimes
Theme URI: https://anddimes.com/
Author: &Dimes
Description: One-page site for &Dimes, a Sydney venue music studio. Gouache palette, Side A / Side B layout, synthesised intro loops.
Version: 1.1.19
Requires at least: 6.0
Requires PHP: 7.4
License: All rights reserved
Text Domain: anddimes
*/

/* &Dimes: chalky gouache on cream paper.
   Layout: full-bleed colour blocks (Cream, Grape, Bubblegum) stacked down the page,
   content held to one centred column. The offset print shadow lives on the logo only. */

/* Self-hosted fonts (SIL Open Font License, see fonts/OFL-*.txt): Latin subsets made from Google Fonts' sources.
   Served from the site itself, so there's no render-blocking trip to Google. */
@font-face { font-family: "Unbounded"; font-weight: 900; font-style: normal; font-display: swap; src: url("fonts/unbounded-900.woff") format("woff"); }
@font-face { font-family: "Lexend"; font-weight: 800; font-style: normal; font-display: swap; src: url("fonts/lexend-800-amp.woff") format("woff"); unicode-range: U+0026; }
@font-face { font-family: "DM Sans"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/dm-sans-400.woff") format("woff"); }
@font-face { font-family: "DM Sans"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/dm-sans-500.woff") format("woff"); }

:root {
  --grape: #5233A6;      /* primary: logo, headlines, buttons, dark sections */
  --bubblegum: #FF8FB8;  /* secondary: ampersand, highlights, hover, accent sections */
  --leaf: #7FC4A0;       /* small accent only: halftone, tags, small details */
  --cream: #FAF6EE;      /* page background, never pure white */

  --display: "Unbounded", "Arial Black", sans-serif;
  --amp: "Lexend", "Arial Rounded MT Bold", sans-serif;
  --body: "DM Sans", "Helvetica Neue", Arial, sans-serif;

  --radius: 12px;
  --max: 1120px;
  --gutter: clamp(16px, 4vw, 48px);
  /* side padding that centres content inside a full-bleed band */
  --band: max(var(--gutter), calc((100% - var(--max)) / 2 + var(--gutter)));

  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; overflow-x: clip; scroll-padding-top: 76px; }
@media (max-width: 640px) { html { scroll-padding-top: 124px; } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--cream);
  color: var(--grape);
  font-family: var(--body);
  font-weight: 400;
  font-size: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration-thickness: 0.08em; text-underline-offset: 0.2em; }
a:hover { text-decoration-color: var(--bubblegum); }

:focus-visible { outline: 3px solid var(--bubblegum); outline-offset: 3px; }

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 1.02;
  margin: 0;
  text-wrap: balance;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: var(--gutter); top: -100px; z-index: 60;
  background: var(--grape); color: var(--cream); padding: 0.5em 1em; border-radius: var(--radius);
}
.skip:focus { top: 12px; }

/* ---------- Logo ----------
   Bubblegum Lexend ampersand, a touch larger, tucked behind the "D".
   "Dimes" in Grape Unbounded with the two-colour misprint offset. */

.logo {
  display: inline-flex;
  align-items: baseline;
  white-space: nowrap;
  text-decoration: none;
  line-height: 1;
}
.logo__amp {
  font-family: var(--amp);
  font-weight: 800;
  font-size: 1.18em;
  color: var(--bubblegum);
  margin-right: -0.2em;
  position: relative;
  z-index: 0;
}
.logo__dimes {
  font-family: var(--display);
  font-weight: 900;
  letter-spacing: -0.04em;
  color: var(--grape);
  position: relative;
  z-index: 1;
  text-shadow: -3px -3px 0 var(--leaf), 4px 4px 0 var(--bubblegum);
}
/* the big hero logo keeps the same misprint in proportion to its size */
.hero__word .logo__dimes {
  text-shadow: -0.022em -0.022em 0 var(--leaf), 0.03em 0.03em 0 var(--bubblegum);
}
/* reversed on Grape: "Dimes" goes Cream with the same offsets */
.logo--on-grape .logo__dimes { color: var(--cream); }
/* reversed on Bubblegum: the ampersand and pink offset switch to Cream */
.logo--on-bubblegum .logo__amp { color: var(--cream); }
.logo--on-bubblegum .logo__dimes { text-shadow: -3px -3px 0 var(--leaf), 4px 4px 0 var(--cream); }

/* ---------- Halftone corners: Leaf dots on a 10px grid, never behind body text ---------- */

.halftone {
  position: absolute;
  pointer-events: none;
  background-image: radial-gradient(circle, var(--leaf) 2.2px, transparent 2.6px);
  background-size: 10px 10px;
  z-index: 0;
}
.halftone--hero {
  top: 0;
  right: 0;
  width: min(34vw, 380px);
  height: min(30vw, 300px);
  -webkit-mask-image: radial-gradient(circle at 100% 0, #000 30%, transparent 72%);
          mask-image: radial-gradient(circle at 100% 0, #000 30%, transparent 72%);
}
.halftone--footer {
  bottom: 0;
  right: 0;
  width: min(40vw, 320px);
  height: 100%;
  -webkit-mask-image: radial-gradient(circle at 100% 100%, #000 25%, transparent 70%);
          mask-image: radial-gradient(circle at 100% 100%, #000 25%, transparent 70%);
}

/* ---------- Paper grain (switchable) ---------- */

.texture {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 50;
  overflow: hidden;
  transition: opacity 0.35s ease;
}
.texture__grain {
  position: absolute;
  inset: -50%;
  background-image: var(--grain-tile, none);
  background-size: 220px 220px;
  opacity: 0.42;
  animation: grain 0.8s steps(8) infinite;
}
@keyframes grain {
  0%   { transform: translate(0, 0); }
  17%  { transform: translate(-7%, 4%); }
  33%  { transform: translate(5%, -9%); }
  50%  { transform: translate(-11%, -3%); }
  67%  { transform: translate(8%, 10%); }
  83%  { transform: translate(-3%, 7%); }
  100% { transform: translate(0, 0); }
}
/* gouache paper: soft mottling that scrolls with the page, like pigment pooling */
body { position: relative; }
.paper {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 30;
  background-image: var(--paper-tile, none);
  background-size: 640px 640px;
  mix-blend-mode: multiply;
  opacity: 0.35;
  transition: opacity 0.35s ease;
}

/* painted, swaying edges between colour blocks */
.edge {
  position: absolute;
  left: 0;
  width: 100%;
  height: clamp(18px, 3.2vw, 44px);
  top: calc(-1 * clamp(18px, 3.2vw, 44px) + 1px);
  display: block;
  pointer-events: none;
}
.edge path { fill: currentColor; }
.side--b, .liner, .request, .footer { position: relative; }
.side--b .edge { color: var(--bubblegum); }
.liner .edge { color: var(--grape); }
.request .edge { color: var(--cream); }
.footer .edge { color: var(--grape); }
.hidden-track .edge { color: var(--cream); }

/* breathing misprint on the logo */
@keyframes misprint-sm {
  0%, 100% { text-shadow: -3px -3px 0 var(--leaf), 4px 4px 0 var(--bubblegum); }
  33% { text-shadow: -4px -2px 0 var(--leaf), 3px 5px 0 var(--bubblegum); }
  66% { text-shadow: -2px -4px 0 var(--leaf), 5px 3px 0 var(--bubblegum); }
}
@keyframes misprint-lg {
  0%, 100% { text-shadow: -0.022em -0.022em 0 var(--leaf), 0.03em 0.03em 0 var(--bubblegum); }
  33% { text-shadow: -0.03em -0.014em 0 var(--leaf), 0.022em 0.038em 0 var(--bubblegum); }
  66% { text-shadow: -0.014em -0.03em 0 var(--leaf), 0.038em 0.022em 0 var(--bubblegum); }
}
.footer__logo .logo__dimes { animation: misprint-sm 7s ease-in-out infinite; }
.hero__word .logo__dimes { animation: misprint-lg 8s ease-in-out infinite; }

/* halftone dots creep one cell, then loop */
.halftone { animation: dots 6s linear infinite; }
@keyframes dots { to { background-position: 10px 10px; } }

/* the Texture switch turns all of it off */
html[data-texture="off"] .texture,
html[data-texture="off"] .paper { opacity: 0; }
html[data-texture="off"] .texture__grain { animation-play-state: paused; }

@media (prefers-reduced-motion: reduce) {
  .texture__grain, .logo__dimes, .halftone { animation: none; }
}

.grain-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: none;
  border: 0;
  padding: 0.25rem 0;
  color: var(--grape);
  font: inherit;
  font-weight: 500;
  font-size: 0.95rem;
}
.grain-toggle__track {
  width: 2.3rem;
  height: 1.3rem;
  border: 2px solid var(--grape);
  border-radius: 999px;
  position: relative;
  background: var(--cream);
  transition: background 0.2s ease;
}
.grain-toggle__knob {
  position: absolute;
  top: 2px; left: 2px;
  width: calc(1.3rem - 8px);
  height: calc(1.3rem - 8px);
  border-radius: 50%;
  background: var(--grape);
  transition: transform 0.2s ease;
}
.grain-toggle[aria-pressed="true"] .grain-toggle__track { background: var(--bubblegum); }
.grain-toggle[aria-pressed="true"] .grain-toggle__knob { transform: translateX(1rem); }

/* ---------- Record cursor on the things you can press ---------- */

.button, .tape, .deck, .tracknav__skip, .welcome__go, .pick__btn, .pick__opt, .runsheet__send, .runsheet__mini, .runsheet__shape, .quiz__option, .masthead__cta, .sides__opt, .grain-toggle, .checkup summary {
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 28 28'%3E%3Ccircle cx='14' cy='14' r='13' fill='%235233A6' stroke='%23FAF6EE' stroke-width='1.5'/%3E%3Ccircle cx='14' cy='14' r='9' fill='none' stroke='%23FAF6EE' stroke-opacity='.35'/%3E%3Ccircle cx='14' cy='14' r='5' fill='%23FF8FB8'/%3E%3Ccircle cx='14' cy='14' r='1.4' fill='%23FAF6EE'/%3E%3C/svg%3E") 14 14, pointer;
}

/* ---------- Masthead ---------- */

.masthead {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--cream);
  border-bottom: 2px solid var(--grape);
}
.masthead__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 12px var(--gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.masthead__mark { font-size: 1.45rem; }
.masthead__mark .logo__dimes { text-shadow: -2px -2px 0 var(--leaf), 2px 2px 0 var(--bubblegum); }

.masthead__nav {
  display: flex;
  gap: clamp(0.75rem, 2vw, 1.75rem);
  align-items: center;
  font-weight: 500;
  font-size: 1rem;
}
.masthead__nav a { text-decoration: none; }
.masthead__link:hover { text-decoration: underline; text-decoration-color: var(--bubblegum); }
.masthead__cta {
  border: 2px solid var(--grape);
  padding: 0.3em 0.9em;
  border-radius: var(--radius);
  transition: background 0.15s ease;
}
.masthead__cta:hover { background: var(--bubblegum); }

/* A/B tape switch: the knob sits under whichever side is on screen */
.sides {
  position: relative;
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  border: 2px solid var(--grape);
  border-radius: 999px;
  padding: 2px;
}
.sides__knob {
  position: absolute;
  top: 2px; bottom: 2px; left: 2px;
  width: calc(50% - 2px);
  border-radius: 999px;
  background: var(--bubblegum);
  transition: transform 0.35s cubic-bezier(.5, 1.6, .5, 1);
}
.sides[data-active="b"] .sides__knob { transform: translateX(100%); }
.sides__opt {
  position: relative;
  z-index: 1;
  padding: 0.2em 0.85em;
  border-radius: 999px;
  white-space: nowrap;
  text-align: center;
}
@media (prefers-reduced-motion: reduce) { .sides__knob { transition: none; } }

@media (max-width: 900px) { .masthead__link { display: none; } }
@media (max-width: 640px) {
  .masthead__inner { flex-wrap: wrap; row-gap: 8px; }
  .masthead__nav { width: 100%; justify-content: space-between; gap: 0.5rem; }
  .masthead__cta { display: none; }
  .sides__opt { padding: 0.2em 0.7em; }
  .grain-toggle__text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
}

/* ---------- Now-playing ticker (Grape band) ---------- */

.ticker {
  overflow: hidden;
  background: var(--grape);
  color: var(--cream);
  font-weight: 500;
  font-size: 0.95rem;
}
.ticker__track { display: flex; width: max-content; animation: ticker 52s linear infinite; }
.ticker:hover .ticker__track { animation-play-state: paused; }
.ticker__list { display: flex; margin: 0; padding: 0.55rem 0; list-style: none; }
.ticker__list li { white-space: nowrap; }
.ticker__list li::after {
  content: "&";
  margin: 0 1.25rem;
  font-family: var(--amp);
  font-weight: 800;
  color: var(--bubblegum);
}
@keyframes ticker { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) {
  .ticker__track { animation: none; width: auto; }
  .ticker__list { flex-wrap: wrap; padding-inline: var(--gutter); }
  .ticker__list[aria-hidden="true"] { display: none; }
}

/* ---------- Floating cassette: turns over between the sides ---------- */

.deck {
  position: fixed;
  right: max(16px, env(safe-area-inset-right, 0px));
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 45;
  aspect-ratio: 120 / 76;
  perspective: 700px;
  border-radius: var(--radius);
  opacity: 0;
  transform: translateY(14px) scale(0.9);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.deck.is-visible { opacity: 1; transform: none; pointer-events: auto; }

.deck__card {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transform: rotate(-6deg);
  transition: transform 0.9s cubic-bezier(.6, -0.25, .3, 1.3);
}
.deck[data-side="b"] .deck__card { transform: rotate(6deg) rotateY(180deg); }
.deck:hover .deck__card { transform: rotate(-2deg) translateY(-3px); }
.deck[data-side="b"]:hover .deck__card { transform: rotate(2deg) translateY(-3px) rotateY(180deg); }

.deck__face {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
  overflow: visible;
}
.deck__face--b { transform: rotateY(180deg); }
.deck__side { font-family: var(--display); font-weight: 900; font-size: 15px; }
.deck__name { font-family: var(--display); font-weight: 900; font-size: 9px; letter-spacing: -0.02em; }

/* reels turn while the tape is turning over */
.deck__reel { transform-box: fill-box; transform-origin: center; }
.deck.is-turning .deck__reel { animation: spin 0.9s linear; }

@media (prefers-reduced-motion: reduce) {
  .deck, .deck__card { transition: none; }
  .deck.is-turning .deck__reel { animation: none; }
}

/* ---------- Now playing pill ---------- */

.player {
  position: fixed;
  left: max(16px, env(safe-area-inset-left, 0px));
  bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  z-index: 45;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--grape);
  color: var(--cream);
  border-radius: 999px;
  padding: 0.35rem 0.4rem 0.35rem 0.9rem;
  font-weight: 500;
  font-size: 0.92rem;
}
.player[hidden] { display: none; }
.player strong { font-weight: 500; color: var(--bubblegum); }
.player__eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 14px; }
.player__eq i { width: 3px; height: 100%; background: var(--leaf); border-radius: 2px; animation: eq 0.9s ease-in-out infinite; transform-origin: bottom; }
.player__eq i:nth-child(2) { animation-delay: -0.3s; }
.player__eq i:nth-child(3) { animation-delay: -0.6s; }
.player[data-side="b"] .player__eq i { animation-duration: 1.2s; }
@keyframes eq { 0%, 100% { transform: scaleY(0.3); } 50% { transform: scaleY(1); } }
.player__stop {
  font: inherit;
  font-weight: 500;
  color: var(--grape);
  background: var(--cream);
  border: 0;
  border-radius: 999px;
  padding: 0.3em 0.9em;
  cursor: pointer;
}
.player__stop:hover { background: var(--bubblegum); }
@media (prefers-reduced-motion: reduce) { .player__eq i { animation: none; transform: scaleY(0.7); } }

/* ---------- Hero (Cream) ---------- */

.hero {
  position: relative;
  padding: clamp(3rem, 9vw, 6.5rem) var(--band) clamp(4rem, 10vw, 7.5rem);
}
.hero > *:not(.halftone) { position: relative; z-index: 1; }

.hero__word {
  font-size: clamp(4.25rem, 17vw, 13rem);
  letter-spacing: 0;
  margin-left: -0.02em;
}

.hero__body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(1.5rem, 5vw, 4rem);
  margin-top: clamp(2.25rem, 5vw, 3.5rem);
  align-items: start;
}
.hero__tagline {
  margin: 0;
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(1.9rem, 4.2vw, 3.1rem);
  line-height: 1.05;
  letter-spacing: -0.035em;
}
.hero__intro { margin: 0 0 2rem; max-width: 32em; font-size: 1.1em; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 1.25rem 1.75rem; align-items: center; }
@media (max-width: 760px) { .hero__body { grid-template-columns: 1fr; } }

/* ---------- Buttons ---------- */

.button {
  display: inline-block;
  font-family: var(--body);
  font-weight: 500;
  font-size: 1.05rem;
  background: var(--grape);
  color: var(--cream);
  border: 2px solid var(--grape);
  padding: 0.8em 1.5em;
  border-radius: var(--radius);
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.button:hover { background: var(--bubblegum); color: var(--grape); text-decoration: none; }
.button:active { transform: translateY(2px); }

/* ---------- Cassette: plays the intro, flips with the sides ---------- */

.tape {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background: none;
  border: 0;
  padding: 0;
  color: var(--grape);
  font: inherit;
  font-weight: 500;
  font-size: 1rem;
}
.tape__shell { width: 80px; height: auto; transform: rotate(-4deg); transition: transform 0.2s ease; }
.tape:hover .tape__shell { transform: rotate(2deg); }
.tape__body { fill: var(--bubblegum); stroke: var(--grape); stroke-width: 3; }
.tape__label { fill: var(--cream); stroke: var(--grape); stroke-width: 2; }
.tape__text { fill: var(--grape); font-family: var(--body); font-weight: 500; font-size: 10px; }
.tape__window { fill: var(--cream); stroke: var(--grape); stroke-width: 2; }
.tape__reel circle { fill: var(--leaf); stroke: var(--grape); stroke-width: 2.5; }
.tape__reel path { stroke: var(--grape); stroke-width: 2.5; }
.tape__foot { fill: none; stroke: var(--grape); stroke-width: 2; }
.tape__reel { transform-box: fill-box; transform-origin: center; }
.tape[aria-pressed="true"] .tape__reel { animation: spin 1.1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.tape__shell.is-flipping { animation: flip 0.6s ease-in-out; }
@keyframes flip {
  0% { transform: rotate(-4deg) rotateY(0); }
  50% { transform: rotate(0deg) rotateY(90deg); }
  100% { transform: rotate(-4deg) rotateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .tape[aria-pressed="true"] .tape__reel { animation-duration: 6s; }
  .tape__shell.is-flipping { animation: none; }
}

/* ---------- Sides: A on Cream, B on Bubblegum ---------- */

.side { padding: clamp(4rem, 9vw, 7rem) var(--band); }
.side--a { background: var(--cream); }
.side--b { background: var(--bubblegum); color: var(--grape); }

.side__head {
  display: flex;
  align-items: flex-end;
  gap: clamp(0.75rem, 2vw, 1.25rem);
  margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
}
.side__letter {
  margin: 0;
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(3.75rem, 9vw, 6.5rem);
  line-height: 0.8;
  color: var(--bubblegum);
}
.side--b .side__letter { color: var(--grape); }
.side h2 { font-size: clamp(1.6rem, 3.6vw, 2.6rem); padding-bottom: 0.08em; }
.side__sub {
  display: block;
  margin: 0.45rem 0 0;
  font-family: var(--body);
  font-weight: 500;
  font-size: 1rem;
  letter-spacing: 0;
}

.side__intro { max-width: 34em; margin: 0 0 clamp(2rem, 5vw, 3rem); font-size: 1.15em; line-height: 1.6; }
.prose p { margin: 0 0 1.1em; max-width: 34em; }

.side-a__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: start;
}
@media (max-width: 860px) { .side-a__grid { grid-template-columns: 1fr; } }

/* ---------- Tracklists ---------- */

.tracklist { list-style: none; margin: 0; padding: 0; counter-reset: track; }
.track {
  counter-increment: track;
  display: grid;
  grid-template-columns: clamp(3rem, 8vw, 5.5rem) minmax(0, 1fr);
  column-gap: clamp(1rem, 3vw, 2rem);
  padding: clamp(1.5rem, 3.5vw, 2.25rem) 0;
  border-top: 2px solid var(--grape);
}
.track:last-child { border-bottom: 2px solid var(--grape); }
.track::before {
  content: "A" counter(track);
  grid-row: 1 / span 3;
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(1.5rem, 3.5vw, 2.25rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--bubblegum);
}
.tracklist[data-side="B"] .track::before { content: "B" counter(track); color: var(--grape); }

.track__top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
  margin-bottom: 0.75rem;
}
.track__name { font-size: clamp(1.3rem, 2.6vw, 1.75rem); }
/* a Leaf tag */
.track__format {
  margin: 0;
  background: var(--leaf);
  color: var(--grape);
  font-weight: 500;
  font-size: 0.85rem;
  line-height: 1.3;
  padding: 0.3em 0.75em;
  border-radius: 999px;
}
.track__what { margin: 0 0 0.75rem; max-width: 38em; }
.track__for { margin: 0; max-width: 38em; font-weight: 500; }

/* ---------- Example running order: a Bubblegum card on Cream ---------- */

.runsheet { margin: 0; justify-self: center; width: min(calc(100% - 44px), 400px); }
.runsheet__sheet {
  position: relative;
  background: var(--bubblegum);
  border-radius: var(--radius);
  padding: 2rem 1.5rem 1.25rem;
  transform: rotate(1.5deg);
}

/* taped up like a poster: Leaf tape with torn ends */
.runsheet__sheet::before,
.runsheet__sheet::after {
  content: "";
  position: absolute;
  top: -16px;
  width: 96px;
  height: 32px;
  background: rgba(127, 196, 160, 0.85);
  clip-path: polygon(0 8%, 6% 0, 12% 10%, 18% 2%, 24% 9%, 76% 4%, 82% 10%, 88% 1%, 94% 9%, 100% 3%,
                     100% 92%, 94% 100%, 88% 90%, 82% 98%, 76% 91%, 24% 96%, 18% 89%, 12% 99%, 6% 90%, 0 97%);
}
.runsheet__sheet::before { left: -22px; transform: rotate(-34deg); }
.runsheet__sheet::after { right: -22px; transform: rotate(30deg); }
.runsheet__title {
  margin: 0;
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(2.5rem, 7vw, 3.25rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
}
.runsheet__sub { margin: 0.3rem 0 1rem; font-weight: 500; font-size: 0.95rem; }
.runsheet__curve { display: block; width: 100%; height: auto; margin-bottom: 1rem; overflow: visible; touch-action: none; cursor: ns-resize; }
.runsheet__knob { fill: var(--cream); stroke: var(--grape); stroke-width: 3; cursor: ns-resize; transition: r 0.15s ease; }
.runsheet__knob:hover, .runsheet__knob:focus-visible { r: 10; }
.runsheet__knob:focus { outline: none; }
.runsheet__knob:focus-visible { stroke: var(--grape); fill: var(--leaf); }

/* ---------- Themed dropdowns ---------- */
.pick { position: relative; display: inline-block; max-width: 100%; }
.pick__native { position: absolute !important; width: 1px; height: 1px; opacity: 0; pointer-events: none; overflow: hidden; clip: rect(0 0 0 0); }
.pick__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  max-width: 100%;
  font: inherit;
  color: var(--grape);
  background: var(--cream);
  border: 2px solid var(--grape);
  border-radius: 999px;
  padding: 0.12em 0.55em 0.12em 0.7em;
  font-weight: 500;
  font-size: 0.85rem;
  line-height: 1.3;
  cursor: pointer;
}
.pick__btn:hover { background: var(--leaf); }
.pick__btn:focus-visible { outline: 3px solid var(--cream); outline-offset: 2px; }
.pick__text { white-space: nowrap; }
.pick__caret {
  flex: none;
  width: 0.7em;
  height: 0.45em;
  background: currentColor;
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transition: transform 0.2s ease;
}
.pick.is-open .pick__caret { transform: rotate(180deg); }
.pick__list[hidden] { display: none; }
.pick__list {
  position: absolute;
  z-index: 20;
  left: 0;
  top: calc(100% + 6px);
  min-width: 100%;
  max-height: 16rem;
  overflow-y: auto;
  margin: 0;
  padding: 6px;
  list-style: none;
  background: var(--cream);
  color: var(--grape);
  border: 2px solid var(--grape);
  border-radius: var(--radius);
  font-family: var(--body);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0;
  line-height: 1.3;
  outline: none;
}
.pick__list:focus-visible { box-shadow: 0 0 0 3px var(--bubblegum); }
.pick__opt {
  padding: 0.45em 0.75em;
  border-radius: 8px;
  white-space: nowrap;
  cursor: pointer;
}
.pick__opt.is-active { background: var(--bubblegum); }
.pick__opt[aria-selected="true"] { background: var(--grape); color: var(--cream); }
.pick__opt[aria-selected="true"].is-active { background: var(--grape); box-shadow: inset 0 0 0 2px var(--bubblegum); }

/* the night: a big display title that opens the list */
.pick--day { display: block; }
.pick--day .pick__btn {
  background: transparent;
  border: 0;
  border-radius: 8px;
  padding: 0 0.1em 0 0;
  gap: 0.25em;
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(2rem, 6vw, 2.75rem);
  letter-spacing: -0.04em;
  line-height: 1.05;
}
.pick--day .pick__btn:hover { background: transparent; }
.pick--day .pick__btn:hover .pick__caret { transform: translateY(2px); }
.pick--day.is-open .pick__btn:hover .pick__caret { transform: rotate(180deg); }
.pick--day .pick__caret { width: 0.42em; height: 0.26em; }
.pick--day .pick__list { min-width: 12rem; }
.pick--time .pick__list { min-width: 6rem; }

.runsheet__sub { margin: 0.3rem 0 1rem; font-weight: 500; font-size: 0.95rem; }
.runsheet__curve { display: block; width: 100%; height: auto; margin-bottom: 1rem; overflow: visible; touch-action: none; cursor: ns-resize; }
.runsheet__knob { fill: var(--cream); stroke: var(--grape); stroke-width: 3; cursor: ns-resize; transition: r 0.15s ease; }
.runsheet__knob:hover, .runsheet__knob:focus-visible { r: 10; }
.runsheet__knob:focus { outline: none; }
.runsheet__knob:focus-visible { stroke: var(--grape); fill: var(--leaf); }

.runsheet__sub { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.4rem 0.75rem; }
.runsheet__hours { display: inline-flex; align-items: center; gap: 0.35rem 0.6rem; flex-wrap: wrap; }
.runsheet__hours label { font-weight: 500; font-size: 0.85rem; }
.runsheet__hour { display: inline-flex; align-items: center; gap: 0.35rem; white-space: nowrap; }
.runsheet__send {
  margin-top: 1rem;
  width: 100%;
  font: inherit;
  font-weight: 500;
  font-size: 1rem;
  color: var(--cream);
  background: var(--grape);
  border: 2px solid var(--grape);
  border-radius: var(--radius);
  padding: 0.65em 1em;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.runsheet__send:hover { background: var(--cream); color: var(--grape); }
.runsheet__line { fill: none; stroke: var(--grape); stroke-width: 3; vector-effect: non-scaling-stroke; pointer-events: none; }
.runsheet__fill { fill: var(--leaf); pointer-events: none; }
.runsheet__list { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--grape); }
.runsheet__list li {
  display: grid;
  grid-template-columns: 4.3rem minmax(0, 1fr);
  gap: 0.75rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--grape);
  font-size: 0.95rem;
  line-height: 1.35;
}
.runsheet__time { font-weight: 500; font-variant-numeric: tabular-nums; }
.runsheet figcaption { margin-top: 1.5rem; font-size: 0.9rem; text-align: center; }

/* ---------- Rooms: hidden until there is at least one ---------- */

.rooms { margin-top: clamp(3rem, 7vw, 5rem); }
.rooms:not(:has(.room)) { display: none; }
.rooms__title { font-size: clamp(1.4rem, 3vw, 2rem); margin-bottom: 1.25rem; }
.rooms__list {
  list-style: none; margin: 0; padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr));
  gap: 1.25rem;
}
.room { border: 2px solid var(--grape); border-radius: var(--radius); padding: 1.25rem; }
.room__name { font-size: 1.25rem; margin: 0 0 0.25rem; }
.room__where { margin: 0 0 0.6rem; font-weight: 500; font-size: 0.95rem; }
.room__what { margin: 0 0 0.5rem; }
.room__result { margin: 0; font-weight: 500; }

/* ---------- Liner notes (Grape) ---------- */

.liner {
  background: var(--grape);
  color: var(--cream);
  padding: clamp(4rem, 9vw, 7rem) var(--band);
}
.liner h2 { font-size: clamp(2.25rem, 6vw, 4.25rem); margin-bottom: clamp(1.75rem, 4vw, 2.75rem); }
.liner a { color: var(--cream); }
.liner__cols { columns: 2 22rem; column-gap: clamp(2rem, 5vw, 4rem); }
.liner__cols p { break-inside: avoid; }
.liner__sign { font-weight: 500; color: var(--bubblegum); }

/* ---------- Request (Cream) ---------- */

.request { padding: clamp(4rem, 9vw, 7rem) var(--band); }
.request h2 { font-size: clamp(2.25rem, 6vw, 4.25rem); }
.request__intro { margin: 0.9rem 0 2.5rem; max-width: 32em; font-size: 1.1em; }

.request__form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem clamp(1.25rem, 3vw, 2.5rem);
  max-width: 880px;
}
.field { display: flex; flex-direction: column; gap: 0.4rem; min-width: 0; }
.field--wide, .field--choices, .request__submit { grid-column: 1 / -1; }
.field > label, .field legend { font-weight: 500; font-size: 1rem; }

.field input[type="text"], .field input[type="email"], .field textarea {
  font: inherit;
  color: var(--grape);
  background: var(--cream);
  border: 2px solid var(--grape);
  border-radius: var(--radius);
  padding: 0.6em 0.8em;
}
.field textarea { resize: vertical; }
.field input:focus-visible, .field textarea:focus-visible { outline: 3px solid var(--bubblegum); outline-offset: 2px; }
.field [aria-invalid="true"] { border-color: var(--bubblegum); border-width: 3px; }
.field input::placeholder { color: var(--grape); opacity: 0.55; }

.field--choices { border: 0; padding: 0; margin: 0; flex-direction: row; flex-wrap: wrap; gap: 0.55rem; }
.field--choices legend { width: 100%; margin-bottom: 0.45rem; padding: 0; }
.field--choices label {
  position: relative;
  display: inline-flex;
  font-weight: 500;
  font-size: 0.95rem;
  border: 2px solid var(--grape);
  border-radius: 999px;
  padding: 0.3em 0.95em;
  cursor: pointer;
  transition: background 0.15s ease;
}
.field--choices input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.field--choices label:hover { background: rgba(255, 143, 184, 0.35); }
.field--choices label:has(input:checked) { background: var(--bubblegum); }
.field--choices label:has(input:focus-visible) { outline: 3px solid var(--bubblegum); outline-offset: 3px; }

.checkup { border: 2px dashed var(--grape); border-radius: var(--radius); padding: 0 1.1rem; }
.checkup summary {
  list-style: none;
  padding: 0.9rem 0;
  font-weight: 500;
  font-size: 1.05rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 0.75rem;
}
.checkup summary::-webkit-details-marker { display: none; }
.checkup summary::before {
  content: "+";
  display: inline-grid;
  place-items: center;
  width: 1.5rem; height: 1.5rem;
  border-radius: 50%;
  background: var(--bubblegum);
  font-weight: 500;
  transition: transform 0.2s ease;
}
.checkup[open] summary::before { transform: rotate(45deg); }
.checkup__hint { font-weight: 400; font-size: 0.9rem; }
.checkup__body { display: grid; gap: 1.4rem; padding: 0.25rem 0 1.4rem; }

.request__submit { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 2rem; margin-top: 0.5rem; }
.request__note { margin: 0; max-width: 30em; font-size: 0.95rem; }
.request__note.is-error { font-weight: 500; }

@media (max-width: 640px) { .request__form { grid-template-columns: 1fr; } }

/* ---------- Footer (Grape) ---------- */

.footer {
  position: relative;
  background: var(--grape);
  color: var(--cream);
  padding: clamp(3rem, 7vw, 4.5rem) var(--band) calc(clamp(18px, 3.2vw, 44px) + clamp(3rem, 6vw, 4.25rem));
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.75rem 2rem;
  font-size: 0.95rem;
}
.footer > *:not(.halftone) { position: relative; z-index: 1; }
.footer p { margin: 0; }
.footer__logo { font-size: clamp(2.25rem, 6vw, 3.25rem); flex-basis: 100%; margin-bottom: 0.75rem; }
.footer__line { flex: 1 1 20rem; }

/* the floating cassette's reels turn while music plays */
.is-playing .deck__reel { animation: spin 1.1s linear infinite; }
@media (prefers-reduced-motion: reduce) { .is-playing .deck__reel { animation-duration: 6s; } }


/* ---------- On the beat: things move with --pulse while the tape plays ---------- */
@media (prefers-reduced-motion: no-preference) {
  html.is-playing .halftone {
    transform: scale(calc(1 + var(--pulse, 0) * 0.05));
    opacity: calc(0.7 + var(--pulse, 0) * 0.3);
  }
  html.is-playing .halftone--hero { transform-origin: 100% 0; }
  html.is-playing .halftone--footer { transform-origin: 100% 100%; }
  html.is-playing .edge {
    transform: scaleY(calc(1 + var(--pulse, 0) * 0.4));
    transform-origin: 50% 100%;
  }
  html.is-playing .hero__word,
  html.is-playing .masthead__mark {
    transform: scale(calc(1 + var(--pulse, 0) * 0.015));
    transform-origin: 0 70%;
  }
  html.is-playing .deck.is-visible { transform: scale(calc(1 + var(--pulse, 0) * 0.05)); }
}

/* ---------- Now on the tape: current section + skip, above the floating cassette ---------- */
:root { --deck-w: clamp(64px, 9vw, 104px); }
.deck { width: var(--deck-w); }
.tracknav {
  position: fixed;
  right: max(16px, env(safe-area-inset-right, 0px));
  bottom: calc(16px + env(safe-area-inset-bottom, 0px) + var(--deck-w) * 0.633 + 12px);
  z-index: 45;
  display: flex;
  align-items: center;
  gap: 0.15rem;
  max-width: min(78vw, 20rem);
  background: var(--grape);
  color: var(--cream);
  border-radius: 999px;
  padding: 0.2rem 0.2rem 0.2rem 0.8rem;
  font-weight: 500;
  font-size: 0.82rem;
  line-height: 1.2;
  opacity: 0;
  transform: translateY(10px);
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.tracknav.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.tracknav__now { margin: 0; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tracknav__skip {
  flex: none;
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border: 0;
  border-radius: 50%;
  background: var(--bubblegum);
  color: var(--grape);
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease;
}
.tracknav__skip:hover { background: var(--cream); }
.tracknav__skip:active { transform: scale(0.92); }
.tracknav__skip:focus-visible { outline: 3px solid var(--cream); outline-offset: 2px; }
.tracknav__skip svg { width: 15px; height: 11px; fill: currentColor; }
.tracknav__skip.is-rewind svg { transform: scaleX(-1); }
@media (prefers-reduced-motion: reduce) { .tracknav { transition: none; } }

/* ---------- Hidden track ---------- */
.hidden-track { position: relative; background: var(--cream); padding: 0 var(--band) clamp(4rem, 10vw, 7rem); }
.hidden-track__silence { height: 70vh; }
.hidden-track__body { max-width: 34em; display: grid; gap: 1rem; justify-items: start; }
.hidden-track__time {
  margin: 0;
  font-family: var(--display);
  font-weight: 900;
  font-size: 1rem;
  color: var(--grape);
  letter-spacing: 0.02em;
}
.hidden-track h2 { font-size: clamp(1.75rem, 4.5vw, 3rem); }
.hidden-track p { margin: 0; }
.hidden-track__note { font-size: 0.95rem; font-weight: 500; }

/* ---------- What does your room sound like? ---------- */
.quiz {
  margin-top: clamp(3.5rem, 8vw, 5.5rem);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr);
  gap: clamp(1.5rem, 5vw, 4rem);
  align-items: start;
}
@media (max-width: 860px) { .quiz { grid-template-columns: 1fr; } }
.quiz__title { font-size: clamp(1.5rem, 3.2vw, 2.1rem); margin-bottom: 0.75rem; }
.quiz__intro p { margin: 0; max-width: 26em; }
.quiz__box[hidden] { display: none; }
.quiz__box {
  border: 2px solid var(--grape);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 3vw, 1.75rem);
  min-height: 16rem;
  display: grid;
  align-content: start;
  gap: 1rem;
}
.quiz__progress { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 6px; }
.quiz__progress i { height: 6px; border-radius: 999px; background: var(--grape); opacity: 0.18; transition: opacity 0.25s ease, background 0.25s ease; }
.quiz__progress i.is-done { opacity: 1; background: var(--bubblegum); }
.quiz__stage { display: grid; gap: 0.9rem; justify-items: start; }
.quiz__count { margin: 0; font-weight: 500; font-size: 0.9rem; }
.quiz__q {
  margin: 0;
  font-family: var(--display);
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1.1;
  font-size: clamp(1.25rem, 2.6vw, 1.6rem);
}
.quiz__q:focus, .quiz__name:focus { outline: none; }
.quiz__options { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.quiz__option {
  font: inherit;
  font-weight: 500;
  font-size: 1rem;
  color: var(--grape);
  background: var(--cream);
  border: 2px solid var(--grape);
  border-radius: 999px;
  padding: 0.45em 1.05em;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}
.quiz__option:hover { background: var(--bubblegum); }
.quiz__option:active { transform: translateY(2px); }
.quiz__option.is-picked { background: var(--bubblegum); }
.quiz__back, .quiz__link {
  font: inherit;
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--grape);
  background: none;
  border: 0;
  padding: 0.2em 0;
  text-decoration: underline;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.2em;
  cursor: pointer;
}
.quiz__back:hover, .quiz__link:hover { text-decoration-color: var(--bubblegum); }

.quiz__result {
  width: 100%;
  background: var(--bubblegum);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 3vw, 1.75rem);
  display: grid;
  gap: 0.75rem;
  animation: quiz-in 0.45s cubic-bezier(.3, 1.4, .5, 1);
}
@keyframes quiz-in { from { transform: rotate(-2deg) scale(0.96); opacity: 0; } to { transform: none; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .quiz__result { animation: none; } }
.quiz__kicker { margin: 0; font-weight: 500; font-size: 0.95rem; }
.quiz__name {
  margin: 0;
  font-family: var(--display);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1;
  font-size: clamp(1.9rem, 5vw, 2.75rem);
}
.quiz__about { margin: 0; max-width: 34em; }
.quiz__curve { width: 100%; height: auto; display: block; }
.quiz__curve-fill { fill: var(--leaf); }
.quiz__curve-line { fill: none; stroke: var(--grape); stroke-width: 3; vector-effect: non-scaling-stroke; }
.quiz__facts { margin: 0; font-weight: 500; }
.quiz__tags { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.4rem; }
.quiz__tags li { background: var(--leaf); color: var(--grape); font-weight: 500; font-size: 0.85rem; padding: 0.25em 0.75em; border-radius: 999px; }
.quiz__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.25rem; margin-top: 0.25rem; }
.quiz__result .button:hover { background: var(--cream); }


/* ---------- Running order: naming, shapes, roles, moment ---------- */
.runsheet__naming { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.6rem; margin: 0.35rem 0 0.2rem; }
.runsheet__name {
  flex: 1 1 100%;
  width: 100%;
  min-width: 0;
  resize: none;
  overflow: hidden;
  line-height: 1.3;
  display: block;
  font: inherit;
  font-weight: 500;
  font-size: 1.15rem;
  color: var(--grape);
  background: transparent;
  border: 0;
  border-bottom: 2px dashed var(--grape);
  border-radius: 0;
  padding: 0.15em 0;
}
.runsheet__name:focus-visible { outline: 3px solid var(--cream); outline-offset: 2px; }
.runsheet__mini {
  font: inherit;
  font-weight: 500;
  font-size: 0.85rem;
  color: var(--grape);
  background: var(--cream);
  border: 2px solid var(--grape);
  border-radius: 999px;
  padding: 0.2em 0.75em;
  cursor: pointer;
  white-space: nowrap;
}
.runsheet__mini:hover { background: var(--leaf); }
.runsheet__mini:focus-visible, .runsheet__shape:focus-visible, .runsheet__send:focus-visible { outline: 3px solid var(--cream); outline-offset: 2px; }
.runsheet__shapes { display: flex; flex-wrap: wrap; gap: 0.35rem; margin: 0.85rem 0 0.5rem; }
.runsheet__shape {
  font: inherit;
  font-weight: 500;
  font-size: 0.8rem;
  color: var(--grape);
  background: transparent;
  border: 1.5px solid var(--grape);
  border-radius: 999px;
  padding: 0.15em 0.65em;
  cursor: pointer;
}
.runsheet__shape:hover { background: var(--cream); }
.runsheet__shape[aria-pressed="true"] { background: var(--grape); color: var(--cream); }
.runsheet__note { display: block; }
.runsheet__role {
  display: inline-block;
  vertical-align: 0.1em;
  margin-left: 0.15rem;
  background: var(--leaf);
  color: var(--grape);
  font-weight: 500;
  font-size: 0.72rem;
  line-height: 1.4;
  padding: 0 0.5em;
  border-radius: 999px;
}
.runsheet__moment + .runsheet__moment { margin-top: 0.35rem; }
.runsheet__moment { margin: 0.9rem 0 0; font-weight: 500; font-size: 0.92rem; line-height: 1.45; }
.runsheet__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; margin-top: 1rem; }
.runsheet__actions .runsheet__send { margin-top: 0; width: auto; flex: 1 1 auto; }

/* ---------- Quiz: the night idea on the result ---------- */
.quiz__night {
  background: var(--cream);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  display: grid;
  gap: 0.35rem;
  margin-top: 0.25rem;
}
.quiz__night-label { margin: 0; font-weight: 500; font-size: 0.85rem; }
.quiz__night-name {
  margin: 0;
  font-family: var(--display);
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1.1;
  font-size: clamp(1.25rem, 3vw, 1.6rem);
}
.quiz__night-line { margin: 0; }
.quiz__moments { margin: 0.15rem 0 0; padding-left: 1.1rem; }
.quiz__moments li { margin: 0.15rem 0; }
.quiz__moments li::marker { color: var(--bubblegum); content: "& "; font-family: var(--amp); font-weight: 800; }

/* small phones: keep the poster's tape inside the screen */
@media (max-width: 420px) {
  .runsheet { width: min(calc(100% - 24px), 400px); }
  .runsheet__sheet::before { left: -10px; width: 72px; }
  .runsheet__sheet::after { right: -10px; width: 72px; }
  .side-a__grid { overflow-x: clip; padding-top: 18px; margin-top: -18px; }
}

/* ---------- Secondary buttons ---------- */
.button--ghost { background: transparent; color: var(--grape); }
.button--ghost:hover { background: var(--bubblegum); }
.button--small { font-size: 0.9rem; padding: 0.45em 1em; vertical-align: middle; }
.request__chat { margin: -1.25rem 0 2.25rem; display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1rem; font-weight: 500; }

/* ---------- Contact form extras ---------- */
.field--trap { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
#form-send:disabled { opacity: 0.7; cursor: progress; }

/* ---------- Poster: messages and the share link box ---------- */
.runsheet__status { margin: 0.6rem 0 0; min-height: 1.3em; font-weight: 500; font-size: 0.9rem; line-height: 1.4; }
.runsheet__status:empty { display: none; }
.runsheet__link {
  display: block; width: 100%; margin-top: 0.35rem;
  font: inherit; font-size: 0.82rem; color: var(--grape);
  background: var(--cream); border: 2px solid var(--grape); border-radius: 8px; padding: 0.35em 0.5em;
}

/* ---------- Welcome back strip ---------- */
.welcome[hidden] { display: none; }
.welcome {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1rem;
  background: var(--bubblegum); color: var(--grape);
  padding: 0.6rem var(--band);
  font-weight: 500;
}
.welcome__text { margin: 0; }
.welcome__text strong { font-weight: 500; text-decoration: underline; text-decoration-thickness: 0.08em; text-underline-offset: 0.2em; }
.welcome__actions { display: flex; align-items: center; gap: 0.5rem; }
.welcome__go {
  font: inherit; font-weight: 500; font-size: 0.95rem;
  color: var(--cream); background: var(--grape); border: 0; border-radius: 999px; padding: 0.35em 1em; cursor: pointer;
}
.welcome__go:hover { background: var(--cream); color: var(--grape); }
.welcome__close {
  display: grid; place-items: center; width: 2rem; height: 2rem;
  background: transparent; border: 2px solid var(--grape); border-radius: 50%; color: var(--grape); cursor: pointer;
}
.welcome__close svg { width: 10px; height: 10px; stroke: currentColor; stroke-width: 2; }
.welcome__go:focus-visible, .welcome__close:focus-visible { outline: 3px solid var(--grape); outline-offset: 2px; }
@media (max-width: 480px) {
  .tracknav { font-size: 0.76rem; max-width: 64vw; padding-left: 0.65rem; }
  .tracknav__skip { width: 1.8rem; height: 1.8rem; }
}


/* ---------- Shake lines: echoes of the divider's curve (animated by script while the tape plays) ---------- */
.edge-shake {
  position: absolute;
  left: 0;
  width: 100%;
  top: calc(-1 * clamp(18px, 3.2vw, 44px) - 40px + 1px);
  height: calc(clamp(18px, 3.2vw, 44px) + 40px);
  overflow: visible;
  pointer-events: none;
  z-index: 2;
}
.edge-shake path { fill: none; stroke: currentColor; stroke-width: 4; stroke-linecap: round; opacity: 0; }
@media (max-width: 600px) { .edge-shake path { stroke-width: 3; } }
@media (prefers-reduced-motion: reduce) { .edge-shake { display: none; } }

/* hidden track: copy-the-link button reads as a text link */
.hidden-track__copy {
  font: inherit; font-weight: 500; color: var(--grape); background: none; border: 0; padding: 0;
  text-decoration: underline; text-decoration-thickness: 0.08em; text-underline-offset: 0.2em; cursor: pointer;
}
.hidden-track__copy:hover { text-decoration-color: var(--bubblegum); }
.hidden-track__copy:focus-visible { outline: 3px solid var(--bubblegum); outline-offset: 3px; border-radius: 4px; }


/* ---------- Secret disco mode: a mirror ball and flat light spots (no glows) ---------- */
.disco-lights {
  position: fixed; inset: 0; width: 100%; height: 100%;
  pointer-events: none; z-index: 35;
}
.disco-ball {
  position: fixed; z-index: 36;
  top: 0; left: 50%;
  width: clamp(72px, 9vw, 112px);
  padding: 0; border: 0; background: none; cursor: pointer;
  transform: translate(-50%, -120%);
  display: none;
}
.is-disco .disco-ball { display: block; animation: disco-drop 900ms cubic-bezier(.3, 1.4, .5, 1) forwards; }
.disco-ball__string {
  display: block; width: 2px; height: var(--disco-string, 120px);
  margin: 0 auto; background: var(--grape);
}
.disco-ball__orb { display: block; width: 100%; aspect-ratio: 1; border-radius: 50%; }
.disco-ball:focus-visible { outline: 3px solid var(--bubblegum); outline-offset: 4px; border-radius: 12px; }
@keyframes disco-drop { to { transform: translate(-50%, 0); } }
@media (prefers-reduced-motion: reduce) {
  .is-disco .disco-ball { animation: none; transform: translate(-50%, 0); }
}
@media print { .disco-ball, .disco-lights { display: none !important; } }
.hidden-track__note kbd {
  font: inherit; font-weight: 500;
  padding: 0 6px; border: 1.5px solid currentColor; border-radius: 6px;
}


/* ---------- Woof: the hidden track dancer ----------
   Bobs gently at half speed while the tape is off, dances on the beat while it plays, double time in
   disco mode. The woofer cone follows the real beat through --pulse. Still for reduced motion. */
.hidden-track__inner { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(1.5rem, 5vw, 4rem); }
.hidden-track__inner .hidden-track__body { flex: 1 1 22rem; min-width: 0; }
.hidden-track__woof { flex: 0 0 auto; width: clamp(210px, 30vw, 330px); }
/* Woof's home: the booth. Woof stands behind it, so the front hides his legs and the decks sit under his mitts. */
.booth { display: block; width: 100%; height: auto; overflow: visible; }
.booth .woof { width: 140px; height: 165.5px; }
.booth__amp { font-family: var(--amp); font-weight: 800; font-size: 64px; fill: #5233A6; }
.booth__spots circle { opacity: 0.55; animation: booth-spot 1.968s ease-in-out infinite; }
.booth__spots circle:nth-child(2) { animation-delay: -0.4s; } .booth__spots circle:nth-child(3) { animation-delay: -0.9s; }
.booth__spots circle:nth-child(4) { animation-delay: -1.3s; } .booth__spots circle:nth-child(5) { animation-delay: -1.6s; }
.is-playing .booth__spots circle { animation-duration: 0.984s; } .is-disco .booth__spots circle { animation-duration: 0.492s; }
@keyframes booth-spot { 0%, 100% { opacity: 0.2; } 50% { opacity: 0.9; } }
.woof { display: block; width: 100%; height: auto; overflow: visible; --beat: 0.984s; }
.is-playing .woof { --beat: 0.492s; }
.is-disco .woof { --beat: 0.246s; }
.woof * { transform-box: view-box; }
/* A groove rather than separate wiggles. Over two beats Woof sways his weight from side to side, rocking from the
   feet. On every beat he dips (quick down, slow up) with a little squash, and his legs bend with him instead of the
   whole body hopping. Feet stay planted; one taps out on alternate beats. Each mitt pumps on its own beat and
   settles a moment behind the body. */
.woof__shuffle { transform-origin: 110px 236px; animation: woof-sway calc(var(--beat) * 2) ease-in-out infinite; }
.woof__knees   { transform-origin: 110px 236px; animation: woof-knees var(--beat) linear infinite; }
.woof__bounce  { transform-origin: 110px 178px; animation: woof-dip var(--beat) linear infinite; }
.woof__leg--l  { animation: woof-tap-l calc(var(--beat) * 2) linear infinite; }
.woof__leg--r  { animation: woof-tap-r calc(var(--beat) * 2) linear infinite; }
.woof__arm--l  { animation: woof-pump calc(var(--beat) * 2) linear infinite; animation-delay: calc(var(--beat) * -1.9); }
.woof__arm--r  { animation: woof-pump-r calc(var(--beat) * 2) linear infinite; animation-delay: calc(var(--beat) * -0.9); }
.woof__cone    { transform: scale(calc(0.94 + var(--pulse, 0) * 0.2)); animation: none; }
@keyframes woof-sway {
  0%, 100% { transform: translateX(-4px) rotate(-2.5deg); }
  50%      { transform: translateX(4px) rotate(2.5deg); }
}
@keyframes woof-dip {
  0%   { transform: translateY(0) scale(1, 1); animation-timing-function: cubic-bezier(.2, .7, .3, 1); }
  20%  { transform: translateY(5px) scale(1.015, 0.975); animation-timing-function: cubic-bezier(.45, 0, .55, 1); }
  100% { transform: translateY(0) scale(1, 1); }
}
@keyframes woof-knees {
  0%   { transform: scaleY(1); animation-timing-function: cubic-bezier(.2, .7, .3, 1); }
  20%  { transform: scaleY(0.907); animation-timing-function: cubic-bezier(.45, 0, .55, 1); }
  100% { transform: scaleY(1); }
}
@keyframes woof-tap-l {
  0%, 55%, 100% { transform: rotate(0); }
  15%  { transform: rotate(9deg); animation-timing-function: cubic-bezier(.45, 0, .55, 1); }
  40%  { transform: rotate(0); }
}
@keyframes woof-tap-r {
  0%, 5%, 100% { transform: rotate(0); }
  65%  { transform: rotate(-9deg); animation-timing-function: cubic-bezier(.45, 0, .55, 1); }
  90%  { transform: rotate(0); }
}
@keyframes woof-pump {
  0%   { transform: rotate(5deg); animation-timing-function: cubic-bezier(.2, .8, .3, 1); }
  14%  { transform: rotate(-15deg); animation-timing-function: cubic-bezier(.45, 0, .55, 1); }
  55%  { transform: rotate(5deg); }
  100% { transform: rotate(5deg); }
}
@keyframes woof-pump-r {
  0%   { transform: rotate(-5deg); animation-timing-function: cubic-bezier(.2, .8, .3, 1); }
  14%  { transform: rotate(15deg); animation-timing-function: cubic-bezier(.45, 0, .55, 1); }
  55%  { transform: rotate(-5deg); }
  100% { transform: rotate(-5deg); }
}
@media (prefers-reduced-motion: reduce) {
  .woof g { animation: none !important; }
  .woof__cone { transform: none; }
  .booth__spots circle { animation: none; }
  .booth__dot { display: none; }
}
@media (max-width: 600px) { .hidden-track__woof { width: 220px; order: -1; } }

.footer__copy a { color: inherit; text-decoration: underline; text-underline-offset: 0.2em; }
.footer__copy a:hover { text-decoration-color: var(--bubblegum); }

/* Contrast: Grape text on the Bubblegum and Leaf blocks falls just short of AA (4.1:1).
   Inside those blocks only, Grape is drawn a touch deeper (4.9:1), which looks the same at a glance. */
.side--b, .runsheet__sheet, .track__format, .field--choices label:has(input:checked) { --grape: #472C91; color: var(--grape); }

/* ---------- Bottom controls and compact header (mobile and tablet usability) ----------
   The player and track label float along the bottom with no strip behind them. Whenever they're showing,
   the page gets matching bottom padding, so the end of the page is never hidden behind them. */
:root { --dock-h: 60px; --deck-w: clamp(64px, 8vw, 92px); }
@media (min-width: 901px) { :root { --dock-h: 76px; } }
html.is-playing body, html:has(.tracknav.is-visible) body, html:has(.deck.is-visible) body {
  padding-bottom: calc(var(--dock-h) + env(safe-area-inset-bottom, 0px));
}
/* controls sit centred in the bottom band */
.player { bottom: calc((var(--dock-h) - 2.6rem) / 2 + env(safe-area-inset-bottom, 0px)); }
/* the cassette floats just above the controls, on the right */
.deck { bottom: calc(var(--dock-h) + 10px + env(safe-area-inset-bottom, 0px)); }
.tracknav {
  bottom: calc((var(--dock-h) - 2.4rem) / 2 + env(safe-area-inset-bottom, 0px));
  right: max(16px, env(safe-area-inset-right, 0px));
}

/* small screens: one-row header, compact controls, the cassette floats above them */
@media (max-width: 640px) {
  html { scroll-padding-top: 72px; }
  .masthead__inner { flex-wrap: nowrap; padding-block: 8px; gap: 0.5rem; }
  .masthead__mark { font-size: 1.2rem; flex: none; }
  .masthead__nav { width: auto; flex: 1; justify-content: flex-end; gap: 0.5rem; }
  :root { --deck-w: 60px; }
  .deck { right: max(12px, env(safe-area-inset-right, 0px)); }
  .tracknav { right: max(12px, env(safe-area-inset-right, 0px)); max-width: calc(100vw - 184px); }
  .player { left: max(12px, env(safe-area-inset-left, 0px)); gap: 0.45rem; padding-left: 0.75rem; }
  .player__text { font-size: 0; }
  .player__text strong { font-size: 0.9rem; }
}
.sides__short { display: none; }
@media (max-width: 430px) {
  .sides__full { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .sides__short { display: inline; }
  .sides__opt { padding: 0.25em 0.6em; font-size: 0.95rem; }
}
@media (max-width: 340px) { .masthead__mark { font-size: 1.05rem; } .sides__opt { padding: 0.25em 0.5em; } }

/* the header logo link is at least 24px tall, so it is an easy tap target */
.masthead__mark { padding-block: 4px; }

/* ---------- Liner notes proof: photo, a mix on demand, where Nickles has played (each hidden until filled) ---------- */
.liner__proof { margin-top: clamp(2rem, 5vw, 3rem); display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); align-items: start; }
.liner__proof:not(:has(> :not([hidden]))) { display: none; }
.liner__photo { margin: 0; }
.liner__photo img { display: block; width: 100%; height: auto; border-radius: var(--radius); border: 3px solid var(--cream); }
.liner__mix, .liner__played { border: 2px solid var(--cream); border-radius: var(--radius); padding: 1.25rem; }
.liner__mix-title, .liner__played-title { font-family: var(--display); font-weight: 900; font-size: 1.15rem; margin: 0 0 0.75rem; }
.liner__mix-btn { background: var(--cream); color: var(--grape); border-color: var(--cream); }
.liner__mix-frame:empty { display: none; }
.liner__mix-frame iframe { display: block; width: 100%; border: 0; border-radius: 8px; margin-top: 0.75rem; }
.liner__mix-note, .liner__played-note { margin: 0.75rem 0 0; font-size: 0.9rem; opacity: 0.85; }
.liner__played-note { margin: 0 0 0.75rem; }
.liner__played-list { margin: 0; padding-left: 1.1rem; display: grid; gap: 0.35rem; }


/* ---------- Woof peeking in from the side when the page is idle (decorative) ---------- */
.peek {
  position: fixed; top: 36vh; left: 0; z-index: 46;
  width: clamp(96px, 13vw, 140px);
  transform: translateX(-115%);
  transform-origin: 0 50%;
  pointer-events: none;
  visibility: hidden;
}
.peek.is-out { visibility: visible; pointer-events: auto; }
.peek--right { left: auto; right: 0; transform: translateX(115%); transform-origin: 100% 50%; }
.peek--right svg { transform: scaleX(-1); }
.peek svg { display: block; width: 100%; height: auto; overflow: visible; }
.peek svg * { transform-box: view-box; }
@media (prefers-reduced-motion: reduce) { .peek { display: none; } }
@media print { .peek { display: none !important; } }


/* keep the sticky header clear of the WordPress admin bar when logged in */
.admin-bar .masthead { top: 32px; }
@media (max-width: 782px) { .admin-bar .masthead { top: 46px; } }
