/* bogeybuddies.golf, 2026-11-18b: the immersive layer. The course pictures are the GAME'S renderer (live canvas, or a
   poster frame from it); the page keeps the game's Sunday-strip chrome from site.css: ink outlines, cream cards, one
   hard shadow. All copy is real HTML; the canvases are aria-hidden decoration over it. */

/* ---------- header: sound toggle ---------- */
.sound-toggle { display: inline-flex; align-items: center; gap: 6px; font: 800 14px/1 var(--font); color: var(--ink); background: var(--cream);
  border: 3px solid var(--ink); border-radius: 12px 9px 13px 10px; padding: 7px 10px; box-shadow: 0 3px 0 var(--ink); cursor: pointer; white-space: nowrap; }
.sound-toggle[hidden] { display: none; }
.sound-toggle[aria-pressed="true"] { background: var(--sun); }
.sound-toggle i { width: 14px; height: 12px; background: var(--ink); clip-path: polygon(0 30%, 35% 30%, 75% 0, 75% 100%, 35% 70%, 0 70%); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 720px) { .top { padding-right: 12px; } }

/* ---------- 1. the flyover ---------- */
.fly { position: relative; background: #cfe5ea; }
.fly-stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; z-index: 0; }
.fly-poster, .fly-poster img, .fly-canvas, .snow { position: absolute; inset: 0; width: 100%; height: 100%; }
.fly-poster img { object-fit: cover; object-position: 50% 60%; }
.fly-canvas { display: block; opacity: 0; transition: opacity .5s ease; }
.fly.is-live .fly-canvas { opacity: 1; }
.snow { pointer-events: none; display: none; }
:root[data-season="holiday"] .snow { display: block; }
.fly-hud { position: absolute; right: 16px; top: 84px; display: grid; gap: 8px; justify-items: end; z-index: 1; opacity: 0; transition: opacity .4s; }
.fly.is-live .fly-hud { opacity: 1; }
.hud-card { display: grid; background: var(--cream); border: 3px solid var(--ink); border-radius: 9px 12px 8px 11px; box-shadow: 3px 3px 0 var(--ink); padding: 6px 12px 7px; }
.hud-card b { font-size: 18px; font-weight: 900; line-height: 1.1; }
.hud-card span { font-size: 13px; font-weight: 700; }
.hud-meter { width: 120px; height: 12px; border: 3px solid var(--ink); border-radius: 8px; background: var(--cream); overflow: hidden; }
.hud-meter i { display: block; height: 100%; width: 0; background: var(--sun); }
.fly-beats { position: relative; z-index: 2; margin-top: -100vh; margin-top: -100svh; }
.beat { min-height: 100vh; min-height: 100svh; display: flex; align-items: center; width: 100%; max-width: 1160px; margin: 0 auto; padding: 96px 16px 48px; }
.js .beat-2, .js .beat-3 { min-height: 125vh; min-height: 125svh; }
.beat-card { width: min(470px, 100%); background: var(--cream); border: 3px solid var(--ink); border-radius: 12px 8px 14px 10px; box-shadow: 6px 6px 0 var(--ink); padding: 18px 20px 20px; }
.beat-card h2 { font-size: clamp(28px, 3.6vw, 40px); margin-bottom: 10px; }
.beat-card p { margin: 0 0 10px; }
.beat-card .kicker { margin-bottom: 10px; }
.beat-card .fine { text-align: left; margin: 8px 0 0; font-size: 14px; }
.beat-card .btn { margin-top: 6px; }
.fly-stats b { font-size: 1.25em; font-weight: 900; color: var(--hot); }
.beat-1 { align-items: flex-start; }
.beat-hero { background: none; border: 0; box-shadow: none; padding: 0; width: min(560px, 100%); }
.beat-hero .lockup { width: min(320px, 70%); margin-bottom: 8px; filter: drop-shadow(0 6px 0 rgba(27,16,48,.3)); }
.beat-hero h1 { font-size: clamp(34px, 5vw, 58px); color: var(--cream); text-shadow: var(--outline); margin-bottom: 14px; }
.beat-hero .lede { margin-bottom: 14px; }
.scroll-cue { display: inline-flex; align-items: center; gap: 10px; font-weight: 900; color: var(--cream); text-shadow: var(--outline); font-size: 18px; }
.scroll-cue i { width: 22px; height: 34px; border: 3px solid var(--ink); border-radius: 12px; background: var(--cream); position: relative; }
.scroll-cue i::after { content: ""; position: absolute; left: 50%; top: 6px; width: 6px; height: 8px; margin-left: -3px; border-radius: 3px; background: var(--hot); }
@media (prefers-reduced-motion: no-preference) { .scroll-cue i::after { animation: cue 1.4s ease-in-out infinite; } }
@keyframes cue { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(12px); opacity: 0; } 100% { opacity: 0; } }
.beat-card.reveal { opacity: 0; transform: translateY(26px); transition: opacity .5s ease, transform .5s ease; }
.beat-card.reveal.is-in { opacity: 1; transform: none; }
@media (max-width: 720px) {
  .beat { align-items: flex-end; padding-bottom: 28px; }
  .beat-1 { align-items: flex-end; }
  .beat-hero .lockup { width: 190px; }
  .beat-hero h1 { font-size: 32px; }
  .beat-hero .lede { font-size: 16px; padding: 10px 12px; }
  .fly-hud { top: 72px; right: 12px; }
  .hud-card b { font-size: 15px; } .hud-meter { width: 96px; }
  .beat-card { padding: 14px 16px 16px; box-shadow: 4px 4px 0 var(--ink); }
}

/* ---------- 2. play ---------- */
.band-sky { background: linear-gradient(#5f9ed4, #cfe5ea 70%, #bfe08f); }
.play h2 { color: var(--cream); text-shadow: var(--outline); }
.play-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 440px); gap: 40px; align-items: center; }
.play-copy .sub { background: var(--cream); border: 3px solid var(--ink); border-radius: 8px 12px 9px 11px; padding: 12px 14px; box-shadow: 4px 4px 0 var(--ink); }
.steps-mini { margin-top: 18px; }
.steps-mini li { padding: 10px 14px 10px 64px; }
.steps-mini li::before { top: 6px; }
.play-copy .swing-fine { width: auto; text-align: left; margin-top: 16px; font-size: 14px; }
.play .swing-frame { width: min(420px, 100%); }
.swing-poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 26px; }
.swing.is-live .swing-poster { display: none; }
@media (max-width: 900px) { .play-grid { grid-template-columns: minmax(0, 1fr); } .play-copy { order: 0; } }

/* ---------- 3. worlds ---------- */
.worlds { position: relative; background: #24402a; color: var(--cream); border-top: 4px solid var(--ink); }
.worlds-stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; z-index: 0; display: none; }
.worlds.is-live .worlds-stage { display: block; }
.worlds-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; transition: opacity .25s ease; }
.worlds-canvas.is-swap { opacity: 0; }
.worlds-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(20,14,8,.42), rgba(20,14,8,0) 55%); pointer-events: none; }
.worlds-intro { position: relative; z-index: 1; padding: 72px 0 40px; }
.worlds.is-live .worlds-intro { margin-top: -100vh; margin-top: -100svh; min-height: 100vh; min-height: 100svh; display: flex; align-items: center; }
.worlds h2 { color: var(--cream); text-shadow: var(--outline); font-size: clamp(30px, 4.4vw, 48px); margin-bottom: 14px; }
.worlds-intro .sub { background: var(--cream); color: var(--ink); border: 3px solid var(--ink); border-radius: 8px 12px 9px 11px; padding: 12px 14px; box-shadow: 4px 4px 0 var(--ink); }
.world-index { list-style: none; padding: 0; margin: 18px 0 0; display: flex; flex-wrap: wrap; gap: 8px; counter-reset: w; }
.world-index li { counter-increment: w; }
.world-index a { display: inline-flex; gap: 6px; align-items: center; font: 800 15px/1 var(--font); color: var(--ink); text-decoration: none; background: var(--cream);
  border: 3px solid var(--ink); border-radius: 12px 9px 13px 10px; padding: 8px 12px; box-shadow: 0 3px 0 var(--ink); }
.world-index a::before { content: counter(w); font-weight: 900; color: var(--hot); }
.world { position: relative; z-index: 1; width: 100%; max-width: 1160px; margin: 0 auto; padding: 24px 16px; }
.worlds.is-live .world { min-height: 140vh; min-height: 140svh; display: flex; align-items: center; }
.world-card { width: min(440px, 100%); background: var(--cream); color: var(--ink); border: 3px solid var(--ink); border-radius: 12px 8px 14px 10px;
  box-shadow: 6px 6px 0 var(--ink); padding: 16px 18px 18px; border-top: 12px solid var(--w, var(--go)); }
.world-n { margin: 0; font-weight: 900; font-size: 14px; letter-spacing: .06em; text-transform: uppercase; }
.world-theme { margin: 2px 0 8px; font-size: 15px; }
.world-card h3 { font-size: clamp(26px, 3vw, 34px); margin-bottom: 10px; }
.sig { display: inline-block; vertical-align: middle; font-size: 13px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; background: var(--hot); color: var(--cream);
  border: 2px solid var(--ink); border-radius: 6px; padding: 3px 7px 4px; transform: rotate(-3deg); }
.holecard { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin: 0 0 10px; }
.holecard div { background: #fff; border: 2px solid var(--ink); border-radius: 8px; padding: 5px 6px; text-align: center; }
.holecard dt { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.holecard dd { margin: 0; font-weight: 900; font-size: 16px; line-height: 1.15; }
.world-card p { margin: 0 0 8px; }
.world-meta { font-size: 14px; font-weight: 700; }
.world-shot { margin-top: 10px; border: 3px solid var(--ink); border-radius: 10px; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.worlds.is-live .world-shot { display: none; }
.crown-nine { list-style: none; padding: 0; margin: 0 0 10px; display: flex; flex-wrap: wrap; gap: 4px; counter-reset: c; }
.crown-nine li { counter-increment: c; font-size: 13px; font-weight: 800; background: #fff; border: 2px solid var(--ink); border-radius: 6px; padding: 2px 6px; }
.crown-nine li::before { content: counter(c) " "; color: var(--hot); }
.world-card.reveal { opacity: 0; transform: translateY(30px) rotate(-1deg); transition: opacity .45s ease, transform .45s ease; }
.world-card.reveal.is-in { opacity: 1; transform: none; }
@media (max-width: 720px) {
  .worlds.is-live .world { align-items: flex-end; padding-bottom: 32px; }
  .holecard { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .worlds-shade { background: linear-gradient(0deg, rgba(20,14,8,.4), rgba(20,14,8,0) 50%); }
}

/* ---------- 4. locker ---------- */
.locker-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 36px; align-items: center; }
.locker-tools { display: grid; gap: 10px; margin-top: 18px; }
.locker-tools[hidden] { display: none; }
.locker-tools fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.locker-tools legend { font-weight: 900; font-size: 15px; text-transform: uppercase; letter-spacing: .06em; margin-bottom: 6px; padding: 0; }
.opts { display: flex; flex-wrap: wrap; gap: 6px; }
.opts .chip { padding: 8px 10px; font-size: 14px; min-height: 40px; }
.opts .chip i { display: inline-block; width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--ink); margin-right: 6px; vertical-align: -1px; }
.locker-tools .fine { text-align: left; margin: 4px 0 0; font-size: 14px; }
.locker-frame { position: relative; aspect-ratio: 4 / 5; border: 4px solid var(--ink); border-radius: 24px; overflow: hidden; background: linear-gradient(#5f9ed4, #cfe5ea 55%, #7fae56 56%);
  box-shadow: 7px 9px 0 var(--ink); max-width: 460px; margin: 0 auto; }
.locker-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.locker-still { position: absolute; left: 50%; bottom: 8%; width: 56%; transform: translateX(-50%); filter: drop-shadow(4px 5px 0 rgba(42,26,16,.35)); }
.locker.is-live .locker-still { display: none; }
.locker-tag { position: absolute; left: 12px; top: 12px; margin: 0; background: var(--cream); border: 3px solid var(--ink); border-radius: 9px; padding: 4px 10px; font-size: 15px; box-shadow: 3px 3px 0 var(--ink); }
.cast-h { font-size: 26px; margin: 40px 0 0; }
@media (max-width: 900px) {
  .locker-grid { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .locker-copy { display: contents; }
  .locker-copy > .kicker, .locker-copy > h2, .locker-copy > .sub { order: -2; margin-bottom: 0; }
  .locker-copy > .kicker { justify-self: start; }
  /* the golfer stays in view while you tap through the chips below it */
  .locker-stage { order: -1; position: sticky; top: 62px; z-index: 3; }
  .locker-frame { max-width: none; width: 100%; aspect-ratio: auto; height: min(42vh, 360px); }
  .locker-still { width: auto; height: 82%; }
  .locker-tools { order: 0; margin-top: 0; }
}

/* ---------- 5. knockout ---------- */
.ko-band .sub { color: var(--cream); }
.ko-modes { display: flex; gap: 8px; margin: 18px 0 0; flex-wrap: wrap; }
.ko-modes[hidden] { display: none; }
.ko-stage { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 24px; align-items: center; margin: 20px 0 28px; }
.ko-green { width: 100%; aspect-ratio: 16 / 11; border: 4px solid var(--ink); border-radius: 22px; background: #3f7436; display: block; box-shadow: 6px 8px 0 rgba(0,0,0,.4); }
.ko-read { background: var(--cream); color: var(--ink); border: 3px solid var(--ink); border-radius: 12px; box-shadow: 5px 5px 0 var(--sun); padding: 16px 18px; }
.ko-count { margin: 0 0 10px; font-size: 20px; font-weight: 800; }
.ko-count b { font-size: 46px; font-weight: 900; color: var(--hot); vertical-align: -6px; margin-right: 4px; }
.ko-ladder { list-style: none; padding: 0; margin: 0 0 12px; display: flex; flex-wrap: wrap; gap: 6px; }
.ko-ladder li { min-width: 38px; text-align: center; font-weight: 900; border: 2px solid var(--ink); border-radius: 8px; padding: 4px 6px; background: #fff; }
.ko-ladder li.is-now { background: var(--sun); transform: translateY(-2px); box-shadow: 0 3px 0 var(--ink); }
.ko-ladder li.is-past { opacity: .45; text-decoration: line-through; }
.ko-cap { margin: 0; font-size: 16px; }
.ko-read .fine { text-align: left; margin: 10px 0 0; font-size: 13px; }
.open-tv { display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; justify-content: space-between; background: var(--cream); color: var(--ink);
  border: 3px solid var(--ink); border-radius: 14px 10px 16px 12px; box-shadow: 6px 6px 0 var(--hot); padding: 18px 20px; margin-top: 28px; }
.open-tv > div { flex: 1 1 380px; }
.open-tv h3 { font-size: 26px; margin-bottom: 6px; }
.open-tv p { margin: 0; }
@media (max-width: 900px) { .ko-stage { grid-template-columns: minmax(0, 1fr); } }

/* ---------- 6. the app: phone rail ---------- */
.phone-rail { display: flex; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 28px 4px 20px; margin-top: 12px; scrollbar-width: thin; }
.phone-rail .phone { flex: 0 0 min(220px, 58vw); scroll-snap-align: center; background: var(--ink); }
.phone-rail figcaption { color: var(--cream); text-align: center; font-weight: 800; font-size: 14px; padding: 6px 4px 8px; }
#film .stores { margin: 24px 0 0; }

/* ---------- reduced motion: no scrubbing, no reveals ---------- */
@media (prefers-reduced-motion: reduce) {
  .beat-card.reveal, .world-card.reveal { opacity: 1; transform: none; transition: none; }
  .js .beat-2, .js .beat-3 { min-height: 100vh; min-height: 100svh; }
}

/* no JS: the canvases have nothing to show */
html:not(.js) .ko-green, html:not(.js) .locker-canvas, html:not(.js) .fly-canvas { display: none; }
.ko-read .ko-count { font: 800 20px/1.2 var(--font); color: var(--ink); text-shadow: none; display: block; min-width: 0; }
.ko-read .ko-count span { font: inherit; color: inherit; text-shadow: none; }

/* ---------- /tv/: the TV set shows a real hole flyover (the show's hole card camera) ---------- */
.page-tv .tvset { width: min(500px, 100%); }
.page-tv .tvset-screen { display: block; background: #1b1440; }
.page-tv .tvset-screen .tv-poster, .tv-canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: none; display: block; }
.tv-canvas { opacity: 0; transition: opacity .4s; }
.tvset-screen.is-live .tv-canvas { opacity: 1; }
.page-tv .tvset-screen .tv-bug { position: absolute; right: 8px; top: 8px; display: flex; align-items: center; gap: 4px; }
.page-tv .tvset-screen .tv-bug img { width: 26px; height: 26px; filter: drop-shadow(0 2px 0 var(--ink)); }
.page-tv .tvset-screen .tv-bug b { font-size: 15px; }
.tv-card { position: absolute; left: 8px; bottom: 8px; color: var(--ink); text-shadow: none; background: var(--cream); border: 2px solid var(--ink); border-radius: 7px; padding: 2px 8px; font-weight: 900; font-size: 13px; box-shadow: 2px 2px 0 var(--ink); }
@media (max-width: 900px) { .page-tv .tvset { width: min(420px, 92%); } }
