/* Marketing site (/welcome/) - the cinematic layer.
 *
 * Sits on top of welcome.css and only on the landing page: a night stadium
 * behind the hero, the pinned "one training day" story, and a floodlit
 * closing band. Everything is drawn in CSS (no video, no images) so a phone
 * on mobile data downloads a few kilobytes for it.
 *
 * Motion has two switches. html.cine-live is added by cinematic.js only when
 * script runs and the visitor has not asked for reduced motion; without it
 * the story is a plain list and the stage stands still. The scroll-linked
 * values (--hp on the hero, --sp on the story) are written by the same file.
 */

:root {
    --night: #040814;
    --night-2: #0A1426;
    --flood: 255, 246, 214;   /* floodlight colour, as an rgb triple */
    --turf-1: #0F4D2A;
    --turf-2: #13603A;
}

/* ---------- Shared stage pieces ---------- */
.cine-stage { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.cine-stage > * { position: absolute; }

.cine-sky {
    inset: 0;
    background:
        radial-gradient(60% 50% at 50% 100%, rgba(22, 101, 52, .35), transparent 70%),
        radial-gradient(40% 35% at 18% 8%, rgba(var(--flood), .10), transparent 70%),
        radial-gradient(40% 35% at 82% 8%, rgba(var(--flood), .10), transparent 70%),
        linear-gradient(180deg, #02050D 0%, var(--night) 45%, var(--night-2) 100%);
}

/* Floodlight towers: a lamp bank and the cone of light it throws. */
.cine-flood { top: 4%; width: 0; height: 0; }
.cine-flood-l { left: 6%; }
.cine-flood-r { right: 6%; }
.cine-lamp {
    position: absolute; left: -34px; top: -10px; width: 68px; height: 34px; border-radius: 4px;
    background:
        radial-gradient(circle, #FFFDF0 0 34%, transparent 42%) 0 0 / 11.3px 11.3px,
        #1B2335;
    box-shadow: 0 0 22px 6px rgba(var(--flood), .55), 0 0 90px 30px rgba(var(--flood), .22);
}
.cine-flood-l .cine-lamp { transform: rotate(14deg); }
.cine-flood-r .cine-lamp { transform: rotate(-14deg); }
.cine-beam {
    position: absolute; left: -60vw; top: 0; width: 120vw; height: 120vh;
    transform-origin: 50% 0;
    background: linear-gradient(180deg, rgba(var(--flood), .30), rgba(var(--flood), .06) 55%, rgba(var(--flood), 0) 80%);
    clip-path: polygon(49.4% 0, 50.6% 0, 82% 100%, 18% 100%);
    filter: blur(6px);
    mix-blend-mode: screen;
}
.cine-flood-l .cine-beam { transform: rotate(-24deg); }
.cine-flood-r .cine-beam { transform: rotate(24deg); }

/* The pitch, laid back in perspective with its markings. */
.cine-pitch {
    left: 50%; bottom: -18%; width: 170%; height: 78%;
    transform: translateX(-50%) perspective(900px) rotateX(64deg);
    transform-origin: 50% 100%;
    background:
        radial-gradient(45% 60% at 28% 30%, rgba(var(--flood), .30), transparent 70%),
        radial-gradient(45% 60% at 72% 30%, rgba(var(--flood), .30), transparent 70%),
        repeating-linear-gradient(90deg, var(--turf-1) 0 6.25%, var(--turf-2) 6.25% 12.5%);
    -webkit-mask-image: linear-gradient(to top, #000 45%, transparent 100%);
            mask-image: linear-gradient(to top, #000 45%, transparent 100%);
}
.cine-pitch::before {
    /* touchlines and halfway line */
    content: ''; position: absolute; inset: 8% 10%;
    border: 3px solid rgba(255, 255, 255, .55);
    background: linear-gradient(90deg, transparent calc(50% - 1.5px), rgba(255, 255, 255, .55) calc(50% - 1.5px) calc(50% + 1.5px), transparent calc(50% + 1.5px));
}
.cine-pitch::after {
    /* centre circle */
    content: ''; position: absolute; left: 50%; top: 50%; width: 15%; aspect-ratio: 1;
    transform: translate(-50%, -50%); border-radius: 50%;
    border: 3px solid rgba(255, 255, 255, .55);
}

/* Dust drifting through the light, film grain, and the vignette. */
.cine-dust { inset: 0; opacity: .55; }
.cine-dust::before, .cine-dust::after {
    content: ''; position: absolute; inset: -50% 0 0 0;
    background-image:
        radial-gradient(1.5px 1.5px at 12% 22%, rgba(var(--flood), .9), transparent),
        radial-gradient(1px 1px at 38% 64%, rgba(var(--flood), .8), transparent),
        radial-gradient(1.5px 1.5px at 66% 18%, rgba(var(--flood), .7), transparent),
        radial-gradient(1px 1px at 84% 52%, rgba(var(--flood), .9), transparent),
        radial-gradient(2px 2px at 52% 86%, rgba(var(--flood), .5), transparent);
    background-size: 340px 340px;
}
.cine-dust::after { background-size: 520px 520px; opacity: .6; }
.cine-grain {
    inset: -50%; opacity: .07; mix-blend-mode: overlay;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.cine-vignette { inset: 0; background: radial-gradient(120% 90% at 50% 40%, transparent 55%, rgba(0, 0, 0, .55)); }

/* ---------- Hero ---------- */
.cine-hero {
    background: var(--night); color: #E2E8F0;
    min-height: calc(100vh - var(--header-h));
    min-height: calc(100svh - var(--header-h));
    display: flex; flex-direction: column; justify-content: center;
    padding-bottom: 88px;
}
.cine-hero::before, .cine-hero::after { display: none; }
.cine-hero .hero-grid { width: 100%; }
.cine-hero h1 { color: #fff; text-shadow: 0 4px 30px rgba(0, 0, 0, .45); }
.cine-hero h1 .accent { color: var(--gold); }
.cine-hero .hero-sub { color: #CBD5E1; }
.cine-hero .pill { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .16); color: #E2E8F0; box-shadow: none; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.cine-hero .btn-ghost { background: rgba(255, 255, 255, .06); color: #fff; border-color: rgba(255, 255, 255, .3); }
.cine-hero .btn-ghost:hover { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .6); }
.cine-hero .trust-list { color: #E2E8F0; }
.cine-hero .devices { filter: drop-shadow(0 40px 60px rgba(0, 0, 0, .55)); }

/* Scroll cue: desktop only, where the hero fills the screen. */
.cine-cue {
    position: absolute; left: 50%; bottom: 22px; z-index: 2; transform: translateX(-50%);
    display: none; align-items: center; gap: 10px;
    font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: rgba(255, 255, 255, .7);
}
.cine-cue:hover { color: #fff; }
.cine-cue-mouse { width: 22px; height: 34px; border: 2px solid currentColor; border-radius: 12px; display: grid; justify-items: center; padding-top: 6px; }
.cine-cue-mouse i { width: 3px; height: 7px; border-radius: 2px; background: currentColor; }
@media (min-width: 1024px) and (min-height: 700px) { .cine-cue { display: inline-flex; } }

/* ---------- One training day ---------- */
.story { position: relative; background: var(--night); color: #E2E8F0; overflow: clip; }
.story-sky, .story-sky span { position: absolute; inset: 0; }
.story-sky span { opacity: 0; transition: opacity .9s ease; }
.story-sky .sky-0 { background: radial-gradient(90% 70% at 70% 110%, rgba(234, 88, 12, .55), transparent 65%), linear-gradient(180deg, #1A1033, #3B1D3F 60%, #5B2A2A); }
.story-sky .sky-1 { background: radial-gradient(90% 70% at 70% 110%, rgba(190, 18, 60, .35), transparent 65%), linear-gradient(180deg, #0E0F2E, #24173F 60%, #2E1B33); }
.story-sky .sky-2 { background: radial-gradient(70% 60% at 50% 0%, rgba(var(--flood), .16), transparent 65%), linear-gradient(180deg, #060D1F, #0B1F3A); }
.story-sky .sky-3 { background: radial-gradient(60% 50% at 80% 20%, rgba(37, 99, 235, .25), transparent 65%), linear-gradient(180deg, #02050D, #07102A); }
.story-sky .sky-4 { background: radial-gradient(70% 60% at 75% 35%, rgba(37, 211, 102, .18), transparent 65%), radial-gradient(60% 50% at 20% 90%, rgba(245, 179, 1, .14), transparent 65%), linear-gradient(180deg, #02050D, #061325); }
.story[data-active="0"] .sky-0, .story:not([data-active]) .sky-0,
.story[data-active="1"] .sky-1,
.story[data-active="2"] .sky-2,
.story[data-active="3"] .sky-3,
.story[data-active="4"] .sky-4 { opacity: 1; }

.story-sticky { position: relative; padding: 72px 0; }
.story-grid {
    position: relative; display: grid; gap: 32px;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "head" "chapters" "stage";
}
@media (min-width: 900px) {
    .story-grid {
        grid-template-columns: minmax(0, 1fr) minmax(0, .8fr);
        grid-template-areas: "head stage" "chapters stage";
        grid-template-rows: auto 1fr; column-gap: 64px;
    }
}
.story-head { grid-area: head; }
.story-head .eyebrow { color: var(--gold); }
.story-head .h2 { color: #fff; max-width: 14ch; }
.story-chapters { grid-area: chapters; display: grid; gap: 28px; margin: 0; padding: 0; list-style: none; }
.chapter h3 { font-size: clamp(26px, 3.4vw, 40px); color: #fff; margin: 4px 0 10px; }
.chapter p { font-size: 17px; color: #CBD5E1; max-width: 46ch; }
.chapter-time {
    display: inline-block; font-family: var(--font-display); font-weight: 800; font-style: italic;
    font-size: 15px; letter-spacing: .12em; color: var(--gold);
    padding: 4px 10px; border: 1px solid rgba(245, 179, 1, .45); border-radius: 6px;
}
.story-stage { grid-area: stage; display: grid; place-items: center; }
.story-progress { display: none; }

/* The phone. */
.story-phone {
    position: relative; width: min(300px, 78vw); aspect-ratio: 9 / 18.5;
    padding: 12px; border-radius: 44px; background: #0B1220;
    box-shadow: 0 0 0 2px #1E293B, 0 50px 90px -30px rgba(0, 0, 0, .8), 0 0 120px -20px rgba(var(--flood), .25);
}
/* A status bar for the notch, then the real app screenshot, top-aligned. */
.sp-notch { position: absolute; top: 18px; left: 50%; width: 84px; height: 20px; transform: translateX(-50%); border-radius: 12px; background: #0B1220; z-index: 2; }
.sp-screens { position: relative; height: 100%; border-radius: 34px; overflow: hidden; background: #fff; }
.sp-screen { position: absolute; inset: 30px 0 0 0; }
.sp-screen:not(.is-active) { display: none; }
.sp-screen img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; }
.story-caption { margin-top: 14px; text-align: center; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: rgba(255, 255, 255, .55); }

/* The Abang Sukan chapter: mascot beside the title, three short promises. */
.chapter-ai h3 { display: flex; align-items: center; gap: 12px; }
.chapter-mascot { width: 44px; height: 44px; border-radius: 50%; flex: none; background: #fff; box-shadow: 0 0 0 3px rgba(37, 211, 102, .8), 0 10px 30px -8px rgba(37, 211, 102, .6); }
.ai-points { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.ai-points li {
    padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; color: #E2E8F0;
    background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .18);
}
.ai-points li::before { content: '\2713'; margin-right: 6px; color: #4ADE80; }

/* ---------- Closing band ---------- */
.cine-final { background: var(--night); }
.cine-final::before, .cine-final::after { display: none; }
.cine-final .cine-pitch { bottom: -40%; opacity: .55; }
.cine-final .cine-flood { top: -2%; }
.cine-final .eyebrow { color: var(--gold); }
.cine-final .container { z-index: 1; }

/* ==========================================================================
   Live: script ran and motion is welcome.
   ========================================================================== */

/* Lights switching on, one bank after the other. */
.cine-live .cine-hero .cine-flood-l { animation: flood-on 1.4s .25s steps(1, end) both; }
.cine-live .cine-hero .cine-flood-r { animation: flood-on 1.4s .65s steps(1, end) both; }
@keyframes flood-on {
    0% { opacity: 0; } 12% { opacity: .9; } 18% { opacity: .15; } 30% { opacity: 1; } 38% { opacity: .4; } 50%, 100% { opacity: 1; }
}
.cine-live .cine-dust::before { animation: dust 38s linear infinite; }
.cine-live .cine-dust::after { animation: dust 60s linear infinite; }
@keyframes dust { to { transform: translateY(33%); } }
.cine-live .cine-final .cine-flood-l .cine-beam { animation: sweep-l 9s ease-in-out infinite alternate; }
.cine-live .cine-final .cine-flood-r .cine-beam { animation: sweep-r 11s ease-in-out infinite alternate; }
@keyframes sweep-l { from { transform: rotate(-34deg); } to { transform: rotate(-12deg); } }
@keyframes sweep-r { from { transform: rotate(34deg); } to { transform: rotate(12deg); } }
.cine-live .cine-cue-mouse i { animation: cue 1.8s ease-in-out infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(10px); } }

/* Headline words arrive one by one (split by cinematic.js). */
.cine-live .cine-hero h1.hero-anim { animation: none; }
.cine-live .cine-hero h1 .w { display: inline-block; animation: word-in .8s cubic-bezier(.2, .7, .2, 1) both; animation-delay: calc(.35s + var(--i) * .07s); }
@keyframes word-in { from { opacity: 0; transform: translateY(.5em) skewX(-6deg); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }

/* Scrolling out of the hero: copy lifts away, the camera tips over the pitch. */
.cine-live .cine-hero .hero-copy,
.cine-live .cine-hero .hero-trust { transform: translateY(calc(var(--hp, 0) * -90px)); opacity: calc(1 - var(--hp, 0) * 1.3); }
.cine-live .cine-hero .hero-visual { transform: translateY(calc(var(--hp, 0) * -40px)) scale(calc(1 + var(--hp, 0) * .05)); }
.cine-live .cine-hero .cine-pitch { transform: translateX(-50%) perspective(900px) rotateX(calc(64deg - var(--hp, 0) * 14deg)); }

/* The story pins: one screen of scrolling per chapter. */
.cine-live .story { height: calc(var(--n) * 100vh); height: calc(var(--n) * 100svh); }
.cine-live .story-sticky {
    position: sticky; top: var(--header-h); padding: 0;
    height: calc(100vh - var(--header-h)); height: calc(100svh - var(--header-h));
    display: flex; align-items: center;
}
.cine-live .story-grid { width: 100%; }
.cine-live .story-phone { width: auto; height: min(560px, calc(100svh - var(--header-h) - 72px)); }
.cine-live .story-chapters { position: relative; display: block; min-height: 15em; }
.cine-live .chapter {
    position: absolute; inset: 0 0 auto 0;
    opacity: 0; transform: translateY(28px); filter: blur(4px);
    transition: opacity .6s ease, transform .6s cubic-bezier(.2, .7, .2, 1), filter .6s ease;
}
.cine-live .chapter.is-active { opacity: 1; transform: none; filter: none; }
.cine-live .sp-screen:not(.is-active) { display: block; }
.cine-live .sp-screen { opacity: 0; transform: translateX(14%) scale(.96); transition: opacity .5s ease, transform .6s cubic-bezier(.2, .7, .2, 1); }
.cine-live .sp-screen.is-active { opacity: 1; transform: none; }
.cine-live .sp-screen.is-past { transform: translateX(-14%) scale(.96); }
.cine-live .story-stage { transform: translateY(calc((var(--sp, 0) - .5) * -40px)); }

/* While the story is pinned, the sticky "Get started" bar steps aside; on
   the Abang Sukan chapter the real assistant button glows: it is the one
   the chapter is talking about, and it works. */
.story-on .mobile-cta { transform: translateY(110%) !important; }
.story-ai #abangSukan .as-launcher { animation: ai-glow 1.6s ease-in-out infinite; border-radius: 50%; }
@keyframes ai-glow {
    0%, 100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, .65), 0 10px 30px -8px rgba(0, 0, 0, .5); }
    50% { box-shadow: 0 0 0 14px rgba(37, 211, 102, 0), 0 10px 30px -8px rgba(0, 0, 0, .5); }
}

/* Progress: a rail on the right on desktop, a bar along the bottom on phones. */
.cine-live .story-progress {
    display: block; position: absolute; left: var(--gutter); right: var(--gutter); bottom: -28px; height: 3px;
    border-radius: 3px; background: rgba(255, 255, 255, .15);
}
.cine-live .story-progress i { position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(90deg, var(--gold), #FFE08A); transform-origin: 0 50%; transform: scaleX(var(--sp, 0)); }
@media (min-width: 900px) {
    .cine-live .story-progress { left: auto; right: -28px; top: 0; bottom: 0; width: 3px; height: auto; }
    .cine-live .story-progress i { background: linear-gradient(180deg, var(--gold), #FFE08A); transform-origin: 50% 0; transform: scaleY(var(--sp, 0)); }
}

/* Each chapter's own phone, with the whole screenshot. Used on phones and
   wherever the pinned stage isn't running (no script, reduced motion). */
.chapter-shot { display: none; }
.cs-phone {
    position: relative; width: min(300px, 80vw); margin: 22px auto 0; padding: 10px;
    border-radius: 40px; background: #0B1220;
    box-shadow: 0 0 0 2px #1E293B, 0 40px 80px -30px rgba(0, 0, 0, .8), 0 0 100px -30px rgba(var(--flood), .25);
}
.cs-phone img, .spot-phone img {
    display: block; width: 100%; height: auto; box-sizing: border-box;
    border-top: 26px solid #fff; border-radius: 30px; background: #fff;
}
html:not(.cine-live) .chapter-shot { display: block; }
html:not(.cine-live) .story-stage { display: none; }

/* Phones: the story is not pinned. A pinned screen only had room for a phone
   cropped at the bottom, so each chapter now shows its full screen in turn. */
@media (max-width: 899px) {
    .cine-live .story { height: auto; }
    .cine-live .story-sticky { position: relative; top: auto; height: auto; padding: 64px 0; display: block; }
    .cine-live .story-grid { gap: 28px; grid-template-areas: "head" "chapters"; }
    .cine-live .story-head .h2 { font-size: 28px; max-width: none; }
    .cine-live .story-stage, .cine-live .story-progress { display: none; }
    .cine-live .story-chapters { display: grid; gap: 64px; min-height: 0; }
    .cine-live .chapter { position: static; opacity: 1; transform: none; filter: none; }
    .cine-live .chapter h3 { font-size: 26px; margin: 6px 0 8px; }
    .cine-live .chapter p { font-size: 16px; }
    .chapter-shot { display: block; }
}

/* Heavy effects off on small screens, where they cost the most. */
@media (max-width: 639px) {
    .cine-beam { filter: none; }
    .cine-grain { display: none; }
    .cine-flood { top: 2%; }
    .cine-lamp { transform: scale(.7) !important; }
}

@media (prefers-reduced-motion: reduce) {
    .cine-dust::before, .cine-dust::after, .cine-beam { animation: none !important; }
}

/* ==========================================================================
   Feature reel: one real phone screen per feature.
   Everywhere: a row you swipe, snapping card by card. Wide screens with
   motion: the section pins and the row slides as you scroll (cinematic.js
   sets the section height, --rx on the track and --rp for the progress).
   ========================================================================== */
.reel {
    position: relative; overflow: clip; padding: 72px 0 48px; color: #E2E8F0;
    background:
        radial-gradient(50% 40% at 50% 0%, rgba(var(--flood), .12), transparent 70%),
        radial-gradient(40% 50% at 100% 100%, rgba(37, 99, 235, .18), transparent 70%),
        linear-gradient(180deg, #07102A, var(--night) 60%);
}
.reel-head { max-width: 720px; text-align: center; margin-bottom: 28px; }
.reel-head .eyebrow { color: var(--gold); }
.reel-head .h2 { color: #fff; }
.reel-head .lead { color: #CBD5E1; }
.reel-track {
    display: flex; gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    padding: 8px max(var(--gutter), calc((100vw - var(--max)) / 2 + var(--gutter))) 20px;
}
.reel-track::-webkit-scrollbar { display: none; }
.reel-track:focus-visible { outline-offset: -3px; }
.reel-card { flex: 0 0 auto; width: min(250px, 70vw); margin: 0; scroll-snap-align: center; }
.reel-phone {
    aspect-ratio: 9 / 18.6; padding: 8px; border-radius: 32px; background: #0B1220;
    box-shadow: 0 0 0 2px #1E293B, 0 40px 70px -30px rgba(0, 0, 0, .85), 0 0 80px -30px rgba(var(--flood), .3);
}
.reel-phone img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 25px; background: #fff; }
.reel-card figcaption { margin-top: 16px; }
.reel-card h3 { font-size: 22px; color: #fff; margin: 8px 0 6px; }
.reel-card p { font-size: 15px; line-height: 1.5; color: #CBD5E1; }
.reel-role {
    display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700;
    letter-spacing: .08em; text-transform: uppercase; border: 1px solid currentColor;
}
.role-admin { color: #93C5FD; }
.role-coach { color: #4ADE80; }
.role-parent { color: var(--gold); }
.role-public { color: #C4B5FD; }
.reel-foot { display: flex; align-items: center; gap: 20px; margin-top: 4px; }
.reel-progress { position: relative; flex: 1; height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .15); }
.reel-progress i { position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(90deg, var(--gold), #FFE08A); transform-origin: 0 50%; transform: scaleX(var(--rp, 0)); }
.reel .text-link { color: var(--gold); white-space: nowrap; }

@media (min-width: 900px) {
    .cine-live .reel { padding: 0; }
    .cine-live .reel-sticky {
        position: sticky; top: var(--header-h); overflow: hidden;
        height: calc(100vh - var(--header-h)); height: calc(100svh - var(--header-h));
        display: flex; flex-direction: column; justify-content: center;
    }
    .cine-live .reel-head { margin-bottom: 16px; }
    .cine-live .reel-head .lead { margin-top: 8px; }
    .cine-live .reel-track { overflow: visible; scroll-snap-type: none; transform: translateX(var(--rx, 0px)); will-change: transform; }
    .cine-live .reel-card {
        width: calc(min(54vh, 500px) * 9 / 18.6);
        opacity: .5; transform: scale(.9); transition: opacity .5s ease, transform .5s cubic-bezier(.2, .7, .2, 1);
    }
    .cine-live .reel-card.is-focus { opacity: 1; transform: none; }
    .cine-live .reel-card h3 { font-size: 20px; }
    .cine-live .reel-card p { font-size: 14px; }
}
html:not(.cine-live) .reel-progress { visibility: hidden; }  /* nothing drives it without the script */

/* ==========================================================================
   "All features" gallery: every feature with a thumbnail of its real screen,
   grouped by who uses it. A card opens the full screen in a viewer.
   ========================================================================== */
.gallery { background: linear-gradient(180deg, var(--night), #07102A); color: #E2E8F0; }
.gallery .h2 { color: #fff; }
.gallery .eyebrow { color: var(--gold); }
.gallery .lead { color: #CBD5E1; }
.gallery .text-link { color: var(--gold); }
.gal-filter { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: -12px 0 32px; }
.gal-filter[hidden] { display: none; }
.gal-filter button {
    min-height: 40px; padding: 0 16px; border-radius: 999px; font-size: 14px; font-weight: 600;
    color: #CBD5E1; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .16);
}
.gal-filter button[aria-pressed="true"] { color: var(--navy); background: var(--gold); border-color: var(--gold); }
.gal-group { margin-bottom: 44px; }
.gal-group[hidden] { display: none; }
.gal-group-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin-bottom: 16px; padding-bottom: 10px; border-bottom: 1px solid rgba(255, 255, 255, .12); }
.gal-group-head h3 { font-size: 24px; color: #fff; }
.gal-group-head span { font-size: 14px; color: #94A3B8; }
.gal-grid { display: grid; gap: 18px 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 640px) { .gal-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 900px) { .gal-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .gal-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 24px 18px; } }
.gal-card {
    display: flex; flex-direction: column; width: 100%; height: 100%; padding: 0; border: 0;
    background: transparent; text-align: left; color: inherit; border-radius: 18px;
}
.gal-thumb {
    position: relative; display: block; overflow: hidden; aspect-ratio: 300 / 420; border-radius: 18px;
    background: #0B1220; border: 6px solid #0B1220;
    box-shadow: 0 0 0 1px #1E293B, 0 22px 40px -24px rgba(0, 0, 0, .9);
    transition: transform .35s cubic-bezier(.2, .7, .2, 1), box-shadow .35s ease;
}
/* The screen fades into the frame: a hint that there is more below. */
.gal-thumb::after {
    content: ''; position: absolute; inset: auto 0 0 0; height: 30%;
    background: linear-gradient(180deg, transparent, rgba(11, 18, 32, .85));
}
.gal-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 12px; background: #fff; }
.gal-title { margin-top: 12px; font-family: var(--font-display); font-weight: 800; font-size: 18px; line-height: 1.15; color: #fff; }
.gal-line { margin-top: 4px; font-size: 13.5px; line-height: 1.45; color: #94A3B8; }
.gal-card:hover .gal-thumb, .gal-card:focus-visible .gal-thumb {
    transform: translateY(-4px); box-shadow: 0 0 0 2px var(--gold), 0 28px 50px -24px rgba(245, 179, 1, .45);
}

.gal-viewer { border: 0; padding: 0; background: transparent; max-width: min(860px, calc(100vw - 24px)); width: 100%; }
.gal-viewer::backdrop { background: rgba(2, 5, 13, .82); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.gal-viewer-card {
    position: relative; display: grid; gap: 20px; align-items: center; padding: 20px;
    border-radius: 24px; background: #0B1426; color: #E2E8F0; box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .9);
}
@media (min-width: 720px) { .gal-viewer-card { grid-template-columns: auto minmax(0, 1fr); gap: 32px; padding: 28px; } }
.gal-viewer-phone {
    justify-self: center; width: min(300px, 70vw); height: min(72vh, 600px); padding: 8px; border-radius: 34px;
    background: #02050D; box-shadow: 0 0 0 2px #1E293B; overflow: hidden;
}
.gal-viewer-phone img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 26px; background: #fff; }
.gal-viewer-copy h3 { font-size: 28px; color: #fff; }
.gal-viewer-copy p { margin-top: 8px; font-size: 16px; color: #CBD5E1; }
.gal-viewer-copy .gal-viewer-note { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: #64748B; }
.gal-viewer-nav { display: flex; align-items: center; gap: 12px; margin-top: 20px; font-size: 14px; color: #94A3B8; }
.gal-viewer .round-btn { background: rgba(255, 255, 255, .08); color: #fff; border-color: rgba(255, 255, 255, .25); }
.gal-close {
    position: absolute; top: 12px; right: 12px; z-index: 1; display: grid; place-items: center; width: 40px; height: 40px;
    border: 0; border-radius: 999px; background: rgba(255, 255, 255, .1); color: #fff;
}
@media (max-width: 719px) {
    .gal-viewer-phone { height: min(58vh, 520px); }
    .gal-viewer-copy { text-align: center; }
    .gal-viewer-nav { justify-content: center; }
}

/* ==========================================================================
   Spotlights: digital member cards and the club network (HQ).
   ========================================================================== */
.spot { position: relative; overflow: clip; padding: 88px 0; color: #E2E8F0; }
.spot-cards {
    background:
        radial-gradient(45% 50% at 85% 45%, rgba(32, 209, 239, .14), transparent 70%),
        linear-gradient(180deg, var(--night), #071B39);
}
.spot-network {
    background:
        radial-gradient(45% 50% at 15% 55%, rgba(37, 211, 102, .12), transparent 70%),
        linear-gradient(180deg, #071B39, var(--night));
}
.spot .eyebrow { color: var(--gold); }
.spot .h2 { color: #fff; }
.spot .lead { color: #CBD5E1; }
.spot-grid { display: grid; gap: 44px; align-items: center; }
@media (min-width: 900px) {
    .spot-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; }
    .spot-flip .spot-copy { order: 2; }
}
.spot-points { list-style: none; margin: 26px 0 0; padding: 0; display: grid; gap: 14px; }
.spot-points li { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; line-height: 1.5; color: #E2E8F0; }
.sp-ico {
    flex: none; width: 28px; height: 28px; margin-top: -1px; border-radius: 8px;
    display: grid; place-items: center; background: rgba(74, 222, 128, .14); color: #4ADE80;
}
.sp-ico .ico { width: 16px; height: 16px; }
.spot-visual { min-width: 0; }

/* Three real card designs, fanned. */
.card-fan { position: relative; width: min(560px, 100%); margin: 0 auto; aspect-ratio: 860 / 760; }
.card-fan-item {
    position: absolute; margin: 0; width: 82%; line-height: 0; border-radius: 3.6% / 5.7%; overflow: hidden;
    box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .75), 0 0 0 1px rgba(255, 255, 255, .08);
}
.card-fan-item svg { display: block; width: 100%; height: auto; }
.cf-1 { left: 0; top: 0; transform: rotate(-6deg); z-index: 1; }
.cf-2 { left: 9%; top: 19%; transform: rotate(-1deg); z-index: 2; }
.cf-3 { left: 18%; top: 38%; transform: rotate(4deg); z-index: 3; }
.spot-visual .story-caption { margin-top: 18px; }

/* A small tree: HQ above its states, each with its clubs. */
.net-tree { display: grid; justify-items: center; gap: 22px; width: min(440px, 100%); margin: 0 auto 30px; }
.net-node {
    display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 12px;
    font-size: 14px; font-weight: 700; color: #fff;
    background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .18);
}
.net-node .ico { width: 16px; height: 16px; }
.net-hq { position: relative; background: linear-gradient(135deg, #16A34A, #0F766E); border-color: transparent; }
.net-hq::after { content: ''; position: absolute; left: 50%; top: 100%; height: 12px; border-left: 2px solid rgba(255, 255, 255, .28); }
.net-row { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; width: 100%; }
.net-row::before { content: ''; position: absolute; top: -10px; left: 25%; right: 25%; border-top: 2px solid rgba(255, 255, 255, .28); }
.net-branch { position: relative; display: grid; justify-items: center; gap: 10px; }
.net-branch::before { content: ''; position: absolute; left: 50%; top: -10px; height: 10px; border-left: 2px solid rgba(255, 255, 255, .28); }
.net-leaves { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.net-leaves span {
    padding: 4px 10px; border-radius: 999px; font-size: 12px; color: #CBD5E1;
    background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .14);
}
.spot-phone {
    position: relative; width: min(280px, 76vw); margin: 0 auto; padding: 10px; border-radius: 40px; background: #0B1220;
    box-shadow: 0 0 0 2px #1E293B, 0 40px 80px -30px rgba(0, 0, 0, .8), 0 0 100px -30px rgba(37, 211, 102, .25);
}
.cs-phone .sp-notch, .spot-phone .sp-notch { top: 14px; }
@media (min-width: 900px) { .spot-phone { width: 240px; } .net-tree { margin-bottom: 24px; } }
