/* ============================================================
   LUCKY WHEEL V2
   ============================================================ */

.wrapper--v2 {

    --page-bg: #070707;
    --card-bg: #111111;
    --card-bg-2: #171717;

    --border-color:
        rgba(255, 255, 255, 0.08);

    --text-main: #ffffff;

    --text-muted:
        rgba(255, 255, 255, 0.62);

    --gold:
        var(--theme-primary, #f5b700);

    --gold-2:
        var(--theme-secondary, #ff7a00);

    --gold-light:
        var(--theme-accent, #ffd84d);

    min-height: 100vh;

    color: var(--text-main);

    background:

        radial-gradient(
            circle at 80% 15%,
            rgba(255, 174, 0, 0.12),
            transparent 30%
        ),

        radial-gradient(
            circle at 15% 60%,
            rgba(255, 120, 0, 0.07),
            transparent 30%
        ),

        var(--page-bg);

    overflow-x: hidden;
}


/* ============================================================
   TOPBAR
   ============================================================ */

.wrapper--v2 .topbar {

    width: 100%;

    padding:
        18px
        24px
        8px;
}


.wrapper--v2 .topbar__inner {

    width:
        min(1180px, 100%);

    margin: 0 auto;

    display: flex;

    align-items: center;
    justify-content: center;
}


.wrapper--v2 .brand {

    display: inline-flex;

    align-items: center;
    justify-content: center;

    text-decoration: none;
}


.wrapper--v2 .brand__logo {

    display: block;

    max-width: 190px;
    max-height: 65px;

    object-fit: contain;
}


.wrapper--v2 .brand__text {

    font-size: 24px;

    font-weight: 900;

    letter-spacing: 1px;

    color: #fff;
}


/* ============================================================
   HERO
   ============================================================ */

.wrapper--v2 .hero {

    /* Was capped at 1180px, centered via margin:0 auto — on anything wider
       than that (most desktop screens) the whole hero sat in a fixed-width
       island with large empty margins on both sides, and the wheel column
       was squeezed to roughly half of that already-narrow box. Widened so
       the layout actually uses more of a wide viewport instead of just
       padding it with empty space. */
    width:
        min(
            1700px,
            calc(100% - 40px)
        );

    margin: 0 auto;

    display: grid;

    /* Was 0.85fr/1.15fr (before that, 0.95fr/1.05fr) — the promo column
       now holds only the promo image (the proof-card/trust-badges that
       used to stack below it moved into their own row lower on the
       page), and the wheel column's own content (grand prize badge,
       wheel) has grown noticeably since that ratio was tuned. An even
       split gives the promo image's own portrait aspect ratio more width
       to grow into instead of staying width-bound while the wheel column
       grows taller next to it. */
    grid-template-columns:
        minmax(0, 1fr)
        minmax(0, 1fr);

    /* Top-align, not center — with align-items:center each column was
       vertically centered within the row's height (= the taller column's
       own height), so whichever column was shorter got pushed down by
       half the difference. That's what put "GRAND PRIZE" and "SPIN & WIN"
       at different heights once .stage's margin-top (added for the
       wheel-frame overflow fix) made the wheel column taller than the
       promo column. Top-aligning keeps both columns' first element flush
       at the same height regardless of which one ends up taller. */
    align-items: start;

    gap:
        clamp(
            30px,
            5vw,
            80px
        );

    padding:
        30px
        0
        40px;
}


/* No promo_image configured (see hero__promo-col's @if in
   lucky-wheel_v2's blade) — collapse the 2-column grid down to one
   centered column instead of leaving the wheel column stranded against
   the grid's original left edge. */
.wrapper--v2 .hero--centered {

    grid-template-columns: minmax(0, 1fr);

    justify-items: center;

    /* Wheel column's own content (grand prize badge, wheel, spin
       button) was designed to fill roughly half of .hero's normal
       1700px width — left at that, a single centered column reads too
       wide/sparse. Capped down to what .hero__wheel-col actually needs. */
    max-width: 720px;
}


/* ============================================================
   LEFT COLUMN
   ============================================================ */

.wrapper--v2 .hero__promo-col {

    order: 1;

    display: flex;

    flex-direction: column;

    gap: 18px;

    width: 100%;
}


/* ============================================================
   PROMO CARD
   ============================================================ */

.wrapper--v2 .promo-card {

    position: relative;

    width: 100%;

    overflow: hidden;

    border-radius: 24px;

    background:

        linear-gradient(
            145deg,
            rgba(255, 255, 255, 0.08),
            rgba(255, 255, 255, 0.025)
        );

    border:
        1px solid var(--border-color);

    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.35);
}


/* A configured promo_image is a full self-contained banner (see the
   blade's @if($promoImage) branch) — no card chrome around it, just the
   image itself, edge to edge. Also fills whatever height the PROMO/WHEEL
   HEIGHT SYNC script sets on .hero__promo-col (see further down), so the
   image (via .promo-card__image--fit below) shrinks to match the wheel
   column's height instead of dictating a taller one of its own. */
.wrapper--v2 .promo-card--image-only {

    height: 100%;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 0;

    background: none;

    border: 0;

    box-shadow: none;
}


.wrapper--v2 .promo-card__image {

    position: relative;

    width: 100%;

    aspect-ratio: 16 / 9;

    overflow: hidden;

    background:
        linear-gradient(
            135deg,
            #191919,
            #0d0d0d
        );
}


.wrapper--v2 .promo-card__image img {

    display: block;

    width: 100%;
    height: 100%;

    object-fit: contain;
}


/* A configured promo_image drops the fixed 16:9 box entirely (see the
   blade's @if($promoImage) branch, which also drops the separate "LIMITED
   PROMOTION / SPIN & WIN" text block below it) — sized to the image's own
   natural proportions instead, so a tall/portrait banner like the current
   one isn't stuck letterboxed inside a landscape box with nothing below
   it to justify the extra space. */
.wrapper--v2 .promo-card__image--fit {

    aspect-ratio: auto;

    max-width: 100%;
    max-height: 100%;

    background: none;
}


.wrapper--v2 .promo-card__image--fit img {

    width: auto;
    height: 100%;

    max-width: 100%;
    max-height: 100%;

    /* Shrinks to fit whatever height .hero__promo-col ends up
       constrained to (see .promo-card--image-only and the PROMO/WHEEL
       HEIGHT SYNC script) while keeping its own aspect ratio — never
       cropped, just scaled down. */
    object-fit: contain;
}


.wrapper--v2 .image-placeholder {

    width: 100%;
    height: 100%;

    display: flex;

    flex-direction: column;

    align-items: center;
    justify-content: center;

    gap: 10px;

    color:
        rgba(
            255,
            255,
            255,
            0.35
        );

    font-size: 13px;

    font-weight: 800;

    letter-spacing: 1px;

    text-align: center;

    background:

        repeating-linear-gradient(
            45deg,
            rgba(255,255,255,0.025),
            rgba(255,255,255,0.025) 10px,
            transparent 10px,
            transparent 20px
        );
}


.wrapper--v2 .image-placeholder__icon {

    font-size: 34px;

    opacity: 0.5;
}


/* ============================================================
   PROMO CONTENT
   ============================================================ */

.wrapper--v2 .promo-card__content {

    padding:
        22px
        24px
        25px;
}


.wrapper--v2 .promo-card__tag {

    display: inline-flex;

    padding:
        6px
        10px;

    margin-bottom: 10px;

    border-radius: 999px;

    color: #111;

    background:

        linear-gradient(
            135deg,
            var(--gold-light),
            var(--gold)
        );

    font-size: 10px;

    font-weight: 900;

    letter-spacing: 0.8px;
}


.wrapper--v2 .promo-card__content h2 {

    margin: 0;

    color: #fff;

    font-size:
        clamp(
            28px,
            4vw,
            44px
        );

    line-height: 0.95;

    font-weight: 950;

    letter-spacing: -1.5px;
}


.wrapper--v2 .promo-card__content p {

    margin:
        12px
        0
        0;

    max-width: 440px;

    color:
        var(--text-muted);

    font-size: 14px;

    line-height: 1.6;
}


/* ============================================================
   PROOF CARD
   ============================================================ */

.wrapper--v2 .proof-card {

    width: 100%;

    overflow: hidden;

    border-radius: 20px;

    background:

        linear-gradient(
            145deg,
            rgba(255, 255, 255, 0.055),
            rgba(255, 255, 255, 0.02)
        );

    border:
        1px solid var(--border-color);

    box-shadow:
        0 15px 45px rgba(0, 0, 0, 0.25);
}


.wrapper--v2 .proof-card__header {

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 15px;

    padding:
        12px
        16px;

    border-bottom:
        1px solid var(--border-color);
}


.wrapper--v2 .proof-card__eyebrow {

    display: block;

    margin-bottom: 3px;

    color:
        var(--gold-light);

    font-size: 8px;

    font-weight: 900;

    letter-spacing: 1.2px;
}


.wrapper--v2 .proof-card__header h3 {

    margin: 0;

    color: #fff;

    font-size: 14px;

    font-weight: 850;
}


.wrapper--v2 .proof-card__live {

    display: inline-flex;

    align-items: center;

    gap: 5px;

    padding:
        4px
        7px;

    border-radius: 999px;

    color: #8fffaf;

    background:
        rgba(45, 210, 90, 0.08);

    font-size: 8px;

    font-weight: 900;

    letter-spacing: 0.6px;
}


.wrapper--v2 .proof-card__live span {

    width: 6px;
    height: 6px;

    border-radius: 50%;

    background: #38e879;

    box-shadow:
        0 0 10px
        rgba(56, 232, 121, 0.7);
}


.wrapper--v2 .proof-card__image {

    position: relative;

    width: 100%;

    /* Was 16/7 (then 16/9, then 2.4/1) — the card keeps its full 50% share
       of .bottom-row's width (~800px on a wide desktop), so shrinking it
       overall means cutting its HEIGHT, not its width. aspect-ratio alone
       wasn't enough — going much wider than 2.4/1 would crop the
       win-proof screenshots (tall receipt/game-history photos, object-fit
       below is cover) too aggressively to stay readable, so this adds a
       hard max-height on top instead of relying on an even more extreme
       ratio. */
    aspect-ratio: 3 / 2;

    /* 3/2 matches the live win-proof photos (1076x714), so nothing is
       cropped; the cap keeps the card from getting tall on wide desktops
       (the img below is object-fit: contain, so a capped box letterboxes
       instead of cropping). */
    max-height: 360px;

    background: #0c0c0c;

    overflow: hidden;
}


.wrapper--v2 .proof-card__image img {

    display: block;

    width: 100%;
    height: 100%;

    object-fit: contain;
}

/* Win-proof screenshots ($winProofImages — the admin's win_proof_images
   config, or the bundled defaults) stack in the same box, one visible at
   a time, cycled by the script further down. */
.wrapper--v2 .proof-card__image-slide {

    position: absolute;
    inset: 0;

    opacity: 0;

    transition: opacity 0.5s ease-in-out;

    pointer-events: none;
}

.wrapper--v2 .proof-card__image-slide.is-active {

    opacity: 1;

    pointer-events: auto;
}

/* Prev/next nav — overlaid on the image, only rendered at all (see
   wheel_v2.blade.php) when there's more than one win-proof image to
   navigate between. */
.wrapper--v2 .proof-card__nav {

    position: absolute;
    top: 50%;

    transform: translateY(-50%);

    z-index: 3;

    width: 34px;
    height: 34px;

    display: flex;

    align-items: center;
    justify-content: center;

    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 50%;

    background: rgba(0, 0, 0, 0.45);

    color: #fff;

    font-size: 13px;

    cursor: pointer;

    transition: background 0.2s ease, border-color 0.2s ease;
}

.wrapper--v2 .proof-card__nav:hover {

    background: rgba(0, 0, 0, 0.7);
    border-color: var(--gold);
}

.wrapper--v2 .proof-card__nav--prev {

    left: 10px;
}

.wrapper--v2 .proof-card__nav--next {

    right: 10px;
}


.wrapper--v2 .image-placeholder--proof {

    font-size: 11px;
}


.wrapper--v2 .proof-card__footer {

    display: flex;

    align-items: center;

    justify-content: space-between;

    padding:
        14px
        18px;

    gap: 15px;
}


.wrapper--v2 .proof-user {

    display: flex;

    align-items: center;

    gap: 10px;
}


.wrapper--v2 .proof-user__avatar {

    width: 34px;
    height: 34px;

    display: flex;

    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    border-radius: 50%;

    color: #111;

    background:

        linear-gradient(
            135deg,
            var(--gold-light),
            var(--gold)
        );

    font-size: 13px;

    font-weight: 900;
}


.wrapper--v2 .proof-user strong {

    display: block;

    color: #fff;

    font-size: 12px;
}


.wrapper--v2 .proof-user small {

    display: block;

    margin-top: 2px;

    color:
        var(--text-muted);

    font-size: 10px;
}


.wrapper--v2 .proof-status {

    padding:
        6px
        9px;

    border-radius: 999px;

    color: #8fffaf;

    background:
        rgba(45, 210, 90, 0.08);

    font-size: 8px;

    font-weight: 900;

    letter-spacing: 0.8px;
}


/* ============================================================
   WHEEL COLUMN
   ============================================================ */

.wrapper--v2 .hero__wheel-col {

    order: 2;

    position: relative;

    display: flex;

    flex-direction: column;

    align-items: center;

    width: 100%;

    min-width: 0;
}


/* =========================================
   GRAND PRIZE
========================================= */

/* True 6-point hexagon (measured from the reference art — a single sharp
   point on each side, not a flat vertical edge/8-point banner): wide flat
   top, tapering down to a narrower flat bottom, via one diagonal down to
   the side point then one long diagonal down to the bottom corner.

   Two reference boxes: .grand-prize itself (outer white — now the real
   element's own background+clip-path, not a pseudo-element, so it and
   the gold body right below it share the exact same box with only a 3px
   inset between them) and .grand-prize__surface (inner champagne + gold
   middle, via its own ::before/::after). KNOWN REMAINING LIMITATION,
   confirmed not just theoretical: .grand-prize and .grand-prize__surface
   are still two DIFFERENT reference boxes, so the inner pair isn't
   guaranteed to be a perfectly parallel offset of the outer pair — a
   uniform pixel inset changes a box's aspect ratio slightly (more so the
   shorter its height relative to its width, which this badge is), so the
   diagonal point's angle drifts a few px between the outer and inner
   pairs specifically. Measured on this badge's actual proportions: ~4px
   of drift at the point. The flat top/bottom edges are unaffected (0%/
   100% doesn't depend on aspect ratio). The mathematically exact fix is a
   single SVG hexagon path instead of any HTML+clip-path layering at all —
   not done here, a bigger rewrite than this pass; flagged so this
   trade-off is a known, chosen one, not an oversight.

   .grand-prize itself also carries clip-path (not just its border
   layers) specifically so it clips its OWN contents — glow/shimmer can't
   visually escape the hexagon this way, which an earlier version of this
   badge had trouble with (the shimmer's translateX(-120%)-to-translateX
   (120%) sweep moving the whole clipped element could escape whichever
   ancestor happened to establish the actual clipping context). The
   shimmer below no longer moves the element at all — see its own comment.

   border/box-shadow still can't be used for any of these lines — they
   only paint where a clip-path polygon's edge coincides with the
   element's actual rectangle edge (here, just the flat top/bottom), never
   along the diagonal cuts, since border needs a real box edge to draw on
   and the diagonals aren't one. Fills (background) DO clip to the polygon
   correctly on every edge, which is what every layer below actually is —
   a fill, not a border. */
.wrapper--v2 .grand-prize {
    /* Point pulled out to 27% (was 13%, then 20%, then 22%) — 27% is the
       ceiling: past ~30-35% the badge starts reading as a shield instead
       of a prize banner, per direct feedback on this exact shape. 27% is
       the sweet spot — distinctive six-sided silhouette, still reads as
       wide/banner-shaped rather than tall/shield-shaped. Shared via this
       custom property (inherited by every descendant below, pseudo-
       elements included) so both reference boxes use the exact same
       polygon rather than it being retyped per layer. */
    --hex-clip: polygon(
        8% 0%, 92% 0%,
        100% 27%,
        84% 100%, 16% 100%,
        0% 27%
    );

    position: relative;
    width: min(100%, 440px);
    /* Was 28px, then 18px — settled at 24px per direct feedback. .stage's
       own margin-top below already carries the real frame-overflow
       clearance, so this is just decorative spacing on top of that. */
    margin: 0 auto 24px;
    padding: 0;
    text-align: center;

    /* New stacking context scoped to this badge, so the negative
       z-index on ::before below stacks relative to THIS box, not the
       page — without isolation, a negative z-index can paint behind
       unrelated ancestor content instead of just behind its own siblings
       here. */
    isolation: isolate;

    /* This element now IS the outer white/silver layer (was a separate
       ::before pseudo-element sized to inset:0 of this same box — folded
       in directly since nothing else needed that pseudo-element slot,
       one fewer layer). Also carries the clip-path that contains this
       badge's own contents — see the top comment on why that matters for
       the shimmer specifically. */
    clip-path: var(--hex-clip);

    background: linear-gradient(180deg, #ffffff 0%, #fffdf5 50%, #e8e8e8 100%);

    /* Glow moved from box-shadow (didn't respect the polygon shape — see
       the comment above) to drop-shadow (does), same visual intent. */
    filter:
        drop-shadow(0 0 10px color-mix(in srgb, var(--gold) 45%, transparent))
        drop-shadow(0 0 25px color-mix(in srgb, var(--gold) 22%, transparent));
}

/* GOLD BODY (the gap between the outer and inner lines) — inset 3px in
   from .grand-prize's own box above, same reference box otherwise (this
   is the pair of layers that DOES share one exact reference box — see
   the top comment on why the inner pair below doesn't get the same
   guarantee).
   Was theme-driven (var(--gold)/--gold-light/--gold-2, derived from the
   admin's theme_color — see the :root block in wheel_v2.blade.php).
   Switched to a fixed richer/darker gold progression per direct feedback:
   the previous theme gold read as too yellow/orange for the inner
   champagne line below to stand out against. TRADE-OFF: this badge's gold
   no longer follows the admin's configured theme_color the way the spin
   button and other gold accents on the page still do — flagged, not
   silently done. */
.wrapper--v2 .grand-prize::before {
    content: "";
    position: absolute;
    inset: 3px;
    z-index: -1;

    clip-path: var(--hex-clip);

    background: linear-gradient(180deg, #ffe79a 0%, #ffc928 25%, #e5a900 62%, #b87800 100%);
}

/* Inert pass-through wrappers now — .grand-prize's own background and
   its ::before above replaced what these used to render themselves (see
   the top comment on why). Kept in the DOM rather than removed, so this
   stays a CSS-only change. */
.wrapper--v2 .grand-prize__ring,
.wrapper--v2 .grand-prize__inner-line {
    padding: 0;
    background: transparent;
}

.wrapper--v2 .grand-prize__surface {
    position: relative;
    /* Content padding — unrelated to the border layers, this is just
       breathing room for the label/amount text inside. */
    padding: 28px 30px 24px;

    /* Was hidden — no longer needed for this element specifically to
       contain anything (.grand-prize's own clip-path above now does that
       job for the whole badge), and hidden here was clipping to this
       element's plain rectangle box, not its hexagon, which could crop
       the inner border/shimmer layers slightly at the corners. */
    overflow: visible;

    background: transparent;
}

/* INNER CHAMPAGNE LINE — inset in from .grand-prize__surface's own box
   (the second reference box this hexagon is built from — see the top
   comment's KNOWN REMAINING LIMITATION on why this pair isn't guaranteed
   to be a perfectly parallel offset of the outer pair above). Was a flat
   rgba(255,255,255,.92) on .grand-prize__inner-line itself — too close in
   brightness to the gold surface either side of it to read as a distinct
   line. A gradient with genuine highlight/shadow gives it dimension, and
   champagne/ivory (rather than pure white) sits better against the
   warmer gold now used throughout — "gold -> champagne highlight -> gold"
   instead of "gold -> barely visible white -> gold". */
.wrapper--v2 .grand-prize__surface::before {
    content: "";
    position: absolute;
    inset: 7px;
    z-index: 0;

    clip-path: var(--hex-clip);

    background: linear-gradient(180deg, #fffdf2 0%, #ffffff 40%, #f2d78d 100%);
}

/* GOLD MIDDLE (the actual "content surface" gold, behind the label/
   amount text) — inset in from .grand-prize__surface::before above, same
   reference box otherwise. Same fixed gold family as .grand-prize::before
   — see its comment for why this stopped being theme-driven. */
.wrapper--v2 .grand-prize__surface::after {
    content: "";
    position: absolute;
    inset: 9px;
    z-index: 0;

    clip-path: var(--hex-clip);

    background: linear-gradient(180deg, #ffe79a 0%, #ffc928 28%, #e5a900 65%, #b87800 100%);
}

/* Shimmer sweep — restored from the pre-hexagon design (dropped when the
   shape was redesigned, brought back per request). A real element (see
   wheel_v2.blade.php's .grand-prize__shine div), not a ::before/::after
   on .grand-prize or .grand-prize__surface — both of those elements'
   pseudo-element slots are already spoken for by the border layers
   above, so the shimmer needed a real DOM home.

   Deliberately does NOT move the element itself (no transform:
   translateX() — that was the earlier version's actual bug: translating
   an absolutely-positioned, clip-path'd element ±120% moves its whole
   box, including its clip-path, so at the animation's extremes the
   visible sweep could momentarily sit outside whichever ancestor actually
   established the clipping context, rather than staying contained within
   this badge). Instead this element stays put (inset:3px, matching the
   gold body layer it sweeps across) and only its background-position
   animates — the hexagon itself never moves, only the light band painted
   inside it does, and .grand-prize's own clip-path (see its comment)
   contains it regardless. z-index:1 sits it above the inner
   champagne/gold-middle layers (z-index:0) but below the label/amount
   text (z-index:2) — same visual order as before. White sweep, not gold —
   gold-on-gold barely shows. */
.wrapper--v2 .grand-prize__shine {
    position: absolute;
    inset: 3px;
    z-index: 1;

    clip-path: var(--hex-clip);

    pointer-events: none;

    background: linear-gradient(
        110deg,
        transparent 30%,
        rgba(255, 255, 255, 0) 42%,
        rgba(255, 255, 255, 0.38) 50%,
        rgba(255, 255, 255, 0) 58%,
        transparent 70%
    );

    background-size: 250% 100%;
    background-position: 100% 0;

    animation: grandPrizeShine 3.5s ease-in-out infinite;
}

@keyframes grandPrizeShine {
    0%,
    15% {
        background-position: 100% 0;
    }

    55%,
    100% {
        background-position: 0% 0;
    }
}


/* =========================================================
   GRAND PRIZE — custom admin-uploaded grand_prize_image
   (replaces the whole procedural hexagon badge above — see the blade's
   @if($grandPrizeImage) branch. No hexagon/gold-layer CSS applies here;
   this is an image with the dynamic amount overlaid on the empty gold
   plate space measured below its "GRAND PRIZE" lettering.)
   ========================================================= */

/* A fully separate class from .grand-prize, deliberately — not a
   .grand-prize + modifier pair. That was the actual bug behind the
   "yellow polygon outside the grand prize" report: this element shared
   the .grand-prize class with the procedural badge below, so it was
   inheriting that rule's clip-path (the hexagon shape) and filter (a
   gold-colored drop-shadow glow) too, and only fighting them off via a
   specificity tie-break that was clearly not reliably winning in
   practice — the glow was visibly still showing around this image, which
   is a plain rectangle with no clip-path of its own, so a hexagon-shaped
   gold glow around it could only have come from the base rule leaking
   through. A totally separate class removes that risk outright instead
   of relying on always winning a specificity fight. */
.wrapper--v2 .grand-prize-custom {
    position: relative;
    /* Was 440px (matching .stage's old width), then 520px. Sized on its
       own now, not tied to the wheel. */
    width: min(100%, 640px);

    /* Negative — pulls this closer to .stage below. .hero__wheel-col is a
       flex column, so flex items never collapse adjacent margins the way
       normal block siblings would; this margin and .stage's own 118px
       top margin (necessary clearance for the wheel-frame's crown, which
       overflows above .stage itself regardless of what's above it — NOT
       safe to shrink, see its own comment) fully add together instead.
       This is the only side of that gap safe to tighten, since it's
       purely decorative spacing rather than overlap-prevention. */
    margin: 0 auto -25px;

    text-align: center;
}

/* Locked to the current grand_prize_image's own 1918:820 canvas ratio so
   this wrapper always shares the exact box the <img> renders at — the
   amount's percentage position below is measured against THIS box, not
   the image's natural size, so they only land correctly together. A
   differently-shaped future image needs this ratio (and the amount's
   position) re-measured. */
.wrapper--v2 .grand-prize-custom__media {
    position: relative;
    width: 100%;
    aspect-ratio: 1918 / 820;
}

.wrapper--v2 .grand-prize-custom__image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* #grandPrizeAmount, same element the increment/shrink-to-fit script
   (further down) already targets — this class is just this branch's
   styling for it, no longer sharing anything with the procedural badge's
   .grand-prize__amount (see the top comment on .grand-prize-custom for
   why that mattered). Positioned over the empty gold plate band measured
   directly off the current image — roughly 45%-57% down, inside the
   plate's widest span before it tapers toward the gift-box graphic. White
   + dark shadow (not gold-gradient-clipped text) since this sits directly
   ON the image's own gold plate — gold-on-gold would have the exact same
   low-contrast problem already fixed once this session for the
   procedural badge's own inner border. */
.wrapper--v2 .grand-prize-custom__amount {
    position: absolute;
    top: 45%;
    left: 15%;
    width: 70%;

    transform: translateY(-50%);

    margin: 0;
    text-align: center;

    /* Bumped up along with .grand-prize-custom's own size above. */
    font-size: clamp(18px, 5vw, 40px);
    line-height: 1;
    font-weight: 950;
    letter-spacing: 0.5px;
    text-transform: uppercase;

    color: #fff;

    /* Layered for an engraved-on-gold look — a dark contact line right
       under the white for definition, a soft warm glow around the whole
       word so it lifts off the plate instead of just sitting flat on it,
       and a drop line for depth. Was a flatter 2-shadow version. */
    text-shadow:
        0 1px 0 #ffffff,
        0 2px 0 #7a3d00,
        0 3px 1px #7a3d00,
        0 4px 8px rgba(0, 0, 0, 0.55),
        0 0 18px rgba(255, 200, 60, 0.55);

    white-space: nowrap;
    overflow: hidden;

    animation: grandPrizePulse 2s ease-in-out infinite;
}


/* =========================================
   LABEL
========================================= */

.wrapper--v2 .grand-prize__label {
    position: relative;
    z-index: 2;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    margin-bottom: 9px;

    font-size: 15px;
    font-weight: 900;
    letter-spacing: 4px;
    text-transform: uppercase;

    color: #754200;

    text-shadow:
        0 1px 0 rgba(255, 255, 255, 0.7);
}

.wrapper--v2 .grand-prize__star {
    font-size: 16px;
    color: #fff;
    text-shadow: 0 1px 3px rgba(120, 60, 0, 0.35);
}


/* =========================================
   AMOUNT
========================================= */

.wrapper--v2 .grand-prize__amount {
    position: relative;
    z-index: 2;

    /* The visible hexagon border is narrower than .grand-prize's own
       rectangular box at most heights (clip-path cuts the corners away —
       overflow:hidden on the parent only clips to that rectangle, not to
       the polygon), so at full width/size this text was rendering past
       the visible border into the background. max-width keeps it inside
       a safely narrower zone; the shrink-to-fit script further down
       (grandPrizeAmount's update script) handles amounts too long even
       for that, since the figure keeps growing over time. */
    max-width: 84%;
    margin: 0 auto;

    font-size: clamp(25px, 5vw, 39px);
    line-height: 1;
    font-weight: 900;
    letter-spacing: -1px;

    color: #ffffff;

    text-shadow:
        0 2px 0 #b76500,
        0 3px 0 #9a5100,
        0 5px 10px rgba(100, 45, 0, 0.30);

    white-space: nowrap;
    overflow: hidden;

    animation: grandPrizePulse 2s ease-in-out infinite;
}

@keyframes grandPrizePulse {
    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.025);
    }
}


/* =========================================
   SUBTITLE
========================================= */

.wrapper--v2 .grand-prize__subtitle {
    position: relative;
    z-index: 2;

    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    margin-top: 10px;

    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;

    color: rgba(255, 255, 255, 0.65);
}

.wrapper--v2 .grand-prize__subtitle span {
    font-size: 14px;
}


/* =========================================
   MOBILE
========================================= */

@media (max-width: 600px) {
    .wrapper--v2 .grand-prize {
        width: calc(100% - 20px);
        margin-bottom: 22px;
    }

    /* Content padding now lives on .grand-prize__surface (the innermost
       layer), not .grand-prize itself — see the nested-layer border
       structure above. */
    .wrapper--v2 .grand-prize__surface {
        padding: 20px 18px 18px;
    }

    .wrapper--v2 .grand-prize__label {
        font-size: 12px;
        letter-spacing: 2px;
    }

    .wrapper--v2 .grand-prize__star {
        font-size: 15px;
    }

    .wrapper--v2 .grand-prize__amount {
        font-size: clamp(26px, 9vw, 40px);
        letter-spacing: -1px;
    }

    .wrapper--v2 .grand-prize__subtitle {
        font-size: 10px;
    }
}


/* ============================================================
   WHEEL STAGE
   ============================================================ */

.wrapper--v2 .stage {

    position: relative;

    /* Frame-vs-disc alignment (.wheel-frame's fixed 158.86% width — see the
       spec comment above it) only holds together if .stage/.wheel/.wheel__inner
       all keep scaling proportionally — so resizing "the wheel" means
       resizing .stage here (and its breakpoints below), never .wheel-frame's
       own percentage. Bumped back up now that .hero itself is wider and the
       wheel column has more room (was 380px, tuned down from 470px when
       .hero was still capped at 1180px and everything felt cramped
       together) — this lets it actually grow into that extra space. */
    width:
        min(
            100%,
            520px
        );

    /* lucky-wheel.css's old desktop .stage rule (unscoped) sets an
       explicit height up to 72rem — that wins over aspect-ratio outright
       since aspect-ratio only fills in a dimension still left auto.
       Explicit reset here rather than relying on specificity, since it's
       easy to lose this override when this file gets regenerated. */
    height: auto;
    aspect-ratio: 1 / 1;

    display: flex;

    align-items: center;
    justify-content: center;

    /* .wheel-frame is centered on .wheel and sized at 158.86% of it (the
       current fixed spec — see the comment above .wheel-frame itself,
       updated along with the actual wheelframe.png in use), so it
       overflows .stage's own box on every side — not just sideways. The
       frame's crown decoration pokes up above .stage's own top edge,
       which was invading the grand-prize badge's small margin-bottom
       above it. Push the stage down instead of just padding the badge.
       This value (like .spin-center's margin-top below the wheel, and
       .stage's own width just above) was scaled up proportionally
       (520/440) from what worked at the previous 440px stage width,
       rather than re-derived from the frame spec's geometry — if this
       520px changes again, scale these three together by the same ratio
       first, and only re-derive from scratch if that stops looking
       right. */
    margin: 118px auto 0;

    /* Explicit (was already the default — nothing here sets overflow, so
       this is defensive) since the oversized frame overflowing this box
       on every side depends on it never becoming hidden. */
    overflow: visible;
}


/* ============================================================
   GLOW
   ============================================================ */

.wrapper--v2 .wheel-glow {

    position: absolute;

    width: 94%;
    height: 94%;

    border-radius: 50%;

    background:

        radial-gradient(
            circle,
            rgba(255, 190, 0, 0.22),
            rgba(255, 120, 0, 0.10) 45%,
            transparent 70%
        );

    filter: blur(22px);

    pointer-events: none;
}


/* ============================================================
   POINTER
   ============================================================ */

/* Admin-uploaded pointer image only — no default CSS-drawn triangle (see
   wheel_v2.blade.php's @if(!empty($wheelArrowImage))), so this only ever
   needs to size/position an <img>, not draw a shape. */
.wrapper--v2 .wheel-pointer {

    position: absolute;

    top: -3px;

    left: 50%;

    transform:
        translateX(-50%);

    width: 38px;

    height: auto;

    max-width: none;

    z-index: 30;

    filter:
        drop-shadow(
            0 4px 5px
            rgba(0,0,0,0.5)
        );
}


/* ============================================================
   WHEEL
   ============================================================ */

.wrapper--v2 .wheel {

    position: relative;

    /* lucky-wheel.css's old desktop .wheel rule (unscoped) sets
       position:absolute; top:45%; left:50%; transform:translate(-50%,-50%)
       — this overrides position above but nothing here overrode
       top/left/transform, so those percentage offsets kept applying and
       skewed the wheel off-center. Also scoped that rule out at the
       source (see lucky-wheel.css), but resetting explicitly here too
       since this file gets regenerated independently of that fix. */
    top: auto;
    left: auto;
    transform: none;

    /* .wheel__inner (the colored disc/segments) is already 100% of this
       box, so growing it means growing this percentage of .stage — was
       94%. .wheel-frame scales proportionally off this same box (158.86% of
       it, fixed spec — see the comment above .wheel-frame), so the frame's
       hollow keeps matching the disc exactly as this grows, same as it did
       at 94%. */
    width: 99%;
    height: 99%;

    flex:
        0 0 auto;

    border-radius: 50%;

    display: flex;

    align-items: center;
    justify-content: center;

    z-index: 2;

    filter:
        drop-shadow(
            0 20px 35px
            rgba(0, 0, 0, 0.45)
        );
}


/* ============================================================
   WHEEL FRAME (custom admin-uploaded ring, optional)
   ============================================================ */

/*
 * WHEEL FRAME IMAGE SPEC — fixed contract, not auto-detected per image.
 * Re-measured (flood-fill on the alpha channel, seeded off-center to dodge
 * the decorative badge sitting in the hollow, not eyeballed) from the
 * current wheelframe.png (1355x1161): bounding box of the flood-filled
 * hollow is x 241-1093, y 143-991 — a circular hollow whose diameter is
 * 853/1355 = 62.95% of the canvas width. A previous pass over this exact
 * same bounding box rounded that down to "~62.7%", which was close enough
 * to look almost right but not close enough to actually close the gap —
 * do the division instead of eyeballing a round-looking number next time.
 *
 * The hollow is NOT exactly canvas-centered either: bbox center is
 * 667/567, vs the canvas's own geometric center at 677.5/580.5 — as a
 * fraction of the canvas, that's 667/1355 = 49.23% across, 567/1161 =
 * 48.84% down, not 50%/50%. Small (~1 percentage point), but at this
 * element's rendered size (~137% of .wheel's height) that's enough to
 * show as a lopsided gap — none at the bottom, a visible sliver at the
 * top — when centered assuming a perfectly centered hollow. translate()
 * below targets the HOLLOW's own center, not the canvas's, to correct
 * for that.
 *
 * Every future wheel-frame upload (any client) must be exported to THIS
 * spec — same canvas aspect ratio (~1355:1161, i.e. ~1.167:1, effectively
 * unchanged from the old ~827:709 spec), hollow diameter ~62.95% of width,
 * hollow centered at 50%/50% of the canvas (that's the target for new
 * exports — the "-49.23%, -48.84%" below is a correction for THIS specific
 * image's slightly-off hollow, not part of the spec to replicate; a
 * properly-centered future export should use -50%/-50%, and only get a
 * different offset if ITS hollow also measures off-center). Doesn't need
 * to be exactly 1355x1161px; any size at that same ratio works, since
 * sizing here is percentage-based off .wheel's own box.
 *
 * The frame is oversized on purpose — its canvas includes decorative
 * badges (coins, partner stickers) floating outside the ring itself, which
 * are meant to spill past the wheel's own circular edge into the
 * surrounding page, same as in the reference art. 100/62.95 ~= 158.86% is
 * the scale-up needed so the hollow's ~62.95%-of-canvas diameter ends up
 * matching .wheel's own 100% (i.e. the colored disc exactly fills the
 * hollow, no gap).
 */
.wrapper--v2 .wheel-frame {

    position: absolute;

    top: 50%;
    left: 50%;

    /* -49.23%/-48.84%, not -50%/-50% — see the hollow-centering note above.
       Shifts the image down/right slightly from dead-canvas-center so the
       hollow's own center (not the canvas's) lands on .wheel's center.
       Re-measured (flood-fill, seeded off-center to dodge the badge sitting
       in the hollow) directly off the current wheelframe.png: hollow bbox
       x[241..1093] y[143..991] on the 1355x1161 canvas — 62.95% diameter,
       center at 49.23%/48.84%. Was 62.7%/49.2%/48.8% (an earlier, slightly
       looser measurement) — the ~0.25 point difference was enough to leave
       a visible dark gap between the disc and the ring's inner edge. */
    transform: translate(-49.23%, -48.84%);

    width: 158.86%;
    height: auto;

    /* lucky-wheel.css's global reset (unscoped `img { max-width: 100%;
       height: auto; }`) was capping the 158.86% width straight back down to
       100% of .wheel's own box — that's exactly why the frame kept
       rendering small and stuck behind the disc instead of extending
       outside it. */
    max-width: none;
    max-height: none;

    pointer-events: none;

    /* .wheel__inner has position:relative but no z-index of its own, so it
       doesn't trap its children into their own stacking context — meaning
       .wheel-label (z-index: 8) and .wheel-divider (z-index: 3) inside it
       actually stack directly against this sibling .wheel-frame within
       .wheel's shared context, not against each other in isolation. Needs
       to clear both (was 3, so labels rendered on top of the ring instead
       of tucking cleanly under it) while staying below the center hub
       badge (z-index: 10) and the pointer (z-index: 30). */
    z-index: 9;
}


/* ============================================================
   WHEEL INNER
   ============================================================ */

.wrapper--v2 .wheel__inner {

    position: relative;

    width: 100%;
    height: 100%;

    aspect-ratio: 1 / 1;

    flex:
        0 0 auto;

    border-radius: 50%;

    overflow: hidden;

    background:

        conic-gradient(

            #f7b500 0deg,

            #ff6b00 45deg,

            #ffd84d 90deg,

            #e83e00 135deg,

            #f7b500 180deg,

            #ff6b00 225deg,

            #ffd84d 270deg,

            #e83e00 315deg,

            #f7b500 360deg
        );

    /* Was 8px/.14 — box-sizing:border-box means this band eats into the
       colored disc itself (not drawn outside it), so at this element's
       ~515px size an 8px semi-transparent WHITE border visibly washed out
       every segment's outer edge toward a lighter/yellowish tint right
       where it should stay saturated — barely noticeable against the
       already-light yellow segments, but read as "orange/red bleeding
       into yellow" against the darker ones. Thin + fainter keeps a subtle
       rim without lightening the segment colors themselves. */
    border:
        2px solid
        rgba(255,255,255,0.08);

    /* The 35px/.45 inset blur here used to read as a wide dark ring eating
       into the segment colors right where they should meet the frame's
       gold band — at this element's ~515px rendered size that blur radius
       is nearly as wide as the visible gap to the frame, so it looked like
       a sizing/color bug rather than the intended subtle "glossy dome"
       edge shade. Shrunk blur + opacity so it reads as a shade, not a band. */
    box-shadow:

        inset
        0 0 0 4px
        rgba(0,0,0,0.28),

        inset
        0 0 12px
        rgba(0,0,0,0.22),

        0 0 0 4px
        rgba(255,190,0,0.12);
}


/* ============================================================
   SEGMENTS — real config segments
   (see Design 1's .spin-slice-shine/.spin-divider/.spin-label in
   lucky-wheel.css — same technique, ported here since the old skewY
   pie-slice approach below (.wheel-segment, default-only now) never
   reliably tracked per-segment color/text-color/count once real config
   segments came into play.)
   ============================================================ */

.wrapper--v2 .wheel-slice-shine {

    position: absolute;

    inset: 0;

    transform-origin: 50% 50%;

    pointer-events: none;
}


.wrapper--v2 .wheel-divider {

    position: absolute;

    top: 0;
    left: 50%;

    width: 1px;
    height: 50%;

    background:

        linear-gradient(
            to bottom,
            rgba(255, 255, 255, 0.78),
            rgba(255, 218, 111, 0.3) 45%,
            rgba(0, 11, 47, 0.34) 100%
        );

    transform-origin: 50% 100%;

    z-index: 3;
}


/* Radial label — rides its own spoke outward from the hub, like a real
   prize wheel, instead of being counter-rotated back to horizontal.
   Labels past the 180deg mark read inverted at rest; that's inherent to
   a real wheel and self-corrects as it spins. */
.wrapper--v2 .wheel-label {

    position: absolute;

    top: 50%;
    left: 50%;

    width: 44%;

    padding-left: 17%;

    height: 0;

    transform-origin: 0% 0%;

    text-align: center;

    pointer-events: none;

    z-index: 8;
}


.wrapper--v2 .wheel-label > span {

    display: inline-block;

    max-width: 100%;

    font-size:

        clamp(
            calc(var(--segment-font-size) * 0.75),
            1vw,
            var(--segment-font-size)
        );

    line-height: 1.05;

    font-weight: 950;

    text-transform: uppercase;

    white-space: normal;

    overflow-wrap: break-word;
    word-break: break-word;

    padding: 0.1em 0.2em;

    text-shadow:
        0 1px 2px rgba(0, 0, 0, 0.86),
        0 0 5px rgba(0, 13, 45, 0.42);

    transform: translateY(-50%);
}


/* ============================================================
   SEGMENTS — default placeholder (no config segments)
   ============================================================ */

.wrapper--v2 .wheel-segment {

    position: absolute;

    left: 50%;
    top: 50%;

    width: 50%;
    height: 50%;

    transform-origin:
        0 100%;

    display: flex;

    align-items: center;
    justify-content: center;

    padding-left: 20%;

    color: #fff;

    font-size:
        clamp(
            9px,
            1.1vw,
            14px
        );

    font-weight: 950;

    text-align: center;

    text-transform: uppercase;

    text-shadow:
        0 2px 4px
        rgba(0,0,0,0.65);

    pointer-events: none;
}


.wrapper--v2 .wheel-segment span {

    display: block;

    width: 80px;

    line-height: 1.05;

    text-align: center;
}


/* ============================================================
   HUB
   ============================================================ */

.wrapper--v2 .wheel-hub {

    position: absolute;

    width: 23%;

    aspect-ratio: 1 / 1;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    z-index: 10;

    background:

        linear-gradient(
            145deg,
            #ffe27a,
            var(--gold),
            #d87a00
        );

    border:
        5px solid
        rgba(255,255,255,0.95);

    box-shadow:

        0 7px 20px
        rgba(0,0,0,0.45),

        inset
        0 2px 3px
        rgba(255,255,255,0.5);
}


.wrapper--v2 .wheel-hub__inner {

    width: 74%;
    height: 74%;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    color: #fff;

    background:

        linear-gradient(
            145deg,
            #e88900,
            #a94d00
        );

    font-size:
        clamp(
            10px,
            1.5vw,
            16px
        );

    font-weight: 950;

    letter-spacing: 0.5px;

    text-shadow:
        0 2px 3px
        rgba(0,0,0,0.4);
}


/* ============================================================
   SPIN BUTTON
   ============================================================ */

.wrapper--v2 .spin-center {

    position: relative;

    /* lucky-wheel.css's old .spin-center rule (unscoped, unconditional —
       applies at every width) sets position:absolute; top:50%; left:50%;
       transform:translate(-50%,-50%); height:22% — this overrode position
       but nothing here overrode top/left/transform/height, so the button
       kept rendering shifted off to the side. Also scoped that rule out
       at the source (see lucky-wheel.css). */
    top: auto;
    left: auto;
    transform: none;
    height: auto;

    z-index: 20;

    display: flex;

    flex-direction: column;

    align-items: center;
    justify-content: center;

    width: 195px;

    min-height: 76px;

    /* .wheel-frame overflows past .stage's own bottom edge (same overflow
       as .stage's own top margin above — see the comment on
       .wrapper--v2 .stage) since margin here is measured from .stage's
       layout box, not its visual overflow. Scaled up proportionally
       (520/440) from the 110px that worked at the previous 440px stage
       width, same as .stage's own top margin just above — see that
       comment for why this is scaled rather than re-derived. */
    margin-top: 130px;

    border: 0;

    border-radius: 18px;

    cursor: pointer;

    color: #15100a;

    background:

        linear-gradient(
            180deg,
            #ffe77d 0%,
            var(--gold) 50%,
            #e48b00 100%
        );

    box-shadow:

        0 12px 25px
        rgba(0,0,0,0.35),

        0 0 30px
        rgba(255,190,0,0.22);

    transition:
        transform 0.2s ease,
        filter 0.2s ease,
        box-shadow 0.2s ease;

    overflow: hidden;

    animation: spinCenterPulse 1.8s ease-in-out infinite;
}

@keyframes spinCenterPulse {
    0%,
    100% {
        transform: scale(1);
        box-shadow:
            0 12px 25px rgba(0, 0, 0, 0.35),
            0 0 30px rgba(255, 190, 0, 0.22);
    }

    50% {
        transform: scale(1.045);
        box-shadow:
            0 12px 25px rgba(0, 0, 0, 0.35),
            0 0 42px rgba(255, 190, 0, 0.45);
    }
}

/* Pause the invite-to-click pulse once the wheel is actually spinning or
   the button is disabled — a scaling button under the pointer while the
   player is mid-spin/waiting reads as broken, not inviting. */
.wrapper--v2 .spin-center.disabled,
.wrapper--v2 .spin-center:active {
    animation-play-state: paused;
}


.wrapper--v2 .spin-center:hover {

    transform:
        translateY(-3px)
        scale(1.03);

    filter:
        brightness(1.08);

    box-shadow:

        0 16px 30px
        rgba(0,0,0,0.4),

        0 0 40px
        rgba(255,190,0,0.35);
}


.wrapper--v2 .spin-center:active {

    transform:
        translateY(1px)
        scale(0.98);
}


.wrapper--v2 .spin-center:disabled {

    cursor: not-allowed;

    opacity: 0.75;
}


.wrapper--v2 .spin-center__shine {

    position: absolute;

    top: -50%;
    left: -50%;

    width: 35%;
    height: 200%;

    transform:
        rotate(25deg);

    background:
        rgba(255,255,255,0.3);

    animation:
        spinButtonShine
        3s
        ease-in-out
        infinite;
}


@keyframes spinButtonShine {

    0%,
    55% {
        left: -50%;
    }

    75%,
    100% {
        left: 130%;
    }

}


.wrapper--v2 .spin-center__text {

    position: relative;

    z-index: 2;

    font-size: 27px;

    font-weight: 950;

    line-height: 1;
}


.wrapper--v2 .spin-center__sub {

    position: relative;

    z-index: 2;

    margin-top: 3px;

    font-size: 8px;

    font-weight: 900;

    letter-spacing: 2px;
}


/* ============================================================
   WHEEL MESSAGE
   ============================================================ */

.wrapper--v2 .wheel-message {

    width:
        min(
            100%,
            400px
        );

    display: flex;

    align-items: center;

    gap: 11px;

    margin-top: 18px;

    padding:
        13px
        15px;

    border-radius: 14px;

    background:
        rgba(255,255,255,0.035);

    border:
        1px solid
        rgba(255,255,255,0.07);
}


.wrapper--v2 .wheel-message__icon {

    font-size: 22px;
}


.wrapper--v2 .wheel-message strong {

    display: block;

    color: #fff;

    font-size: 11px;
}


.wrapper--v2 .wheel-message small {

    display: block;

    margin-top: 3px;

    color:
        var(--text-muted);

    font-size: 9px;
}


/* ============================================================
   COUNTDOWN
   ============================================================ */

.wrapper--v2 .countdown-section {

    width:
        min(
            900px,
            calc(100% - 40px)
        );

    margin: 0 auto;

    padding:
        5px
        0
        25px;
}


.wrapper--v2 .countdown-card {

    padding: 20px;

    border-radius: 20px;

    /* Was a subtle translucent-white card — now the same theme gold
       gradient as the spin button/grand prize. Text colors below
       (label/numbers/unit labels/separator) switched from
       white/gold-on-dark to dark-on-gold to match. */
    background:

        linear-gradient(
            180deg,
            #ffe77d 0%,
            var(--gold) 50%,
            #e48b00 100%
        );

    border:
        1px solid
        rgba(255, 255, 255, 0.25);

    text-align: center;
}


.wrapper--v2 .countdown-card__label {

    display: block;

    margin-bottom: 13px;

    color: #2b1500;

    font-size: 9px;

    font-weight: 900;

    letter-spacing: 1.6px;
}


.wrapper--v2 .countdown {

    display: flex;

    align-items: center;
    justify-content: center;

    gap: 10px;
}


.wrapper--v2 .countdown__item {

    min-width: 65px;
}


.wrapper--v2 .countdown__item strong {

    display: block;

    color: #2b1500;

    font-size:
        clamp(
            23px,
            4vw,
            34px
        );

    line-height: 1;

    font-weight: 950;

    text-shadow:
        0 1px 0 rgba(255, 255, 255, 0.35);
}


.wrapper--v2 .countdown__item span {

    display: block;

    margin-top: 5px;

    color:
        rgba(43, 21, 0, 0.65);

    font-size: 8px;

    font-weight: 800;

    letter-spacing: 0.8px;
}


.wrapper--v2 .countdown__separator {

    color: #2b1500;

    font-size: 22px;

    font-weight: 900;

    margin-top: -10px;
}


/* ============================================================
   PRIZE POOL
   ============================================================ */

.wrapper--v2 .prize-pool {

    width:
        min(
            900px,
            calc(100% - 40px)
        );

    margin: 0 auto;

    padding:
        0
        0
        25px;
}


.wrapper--v2 .prize-pool__inner {

    display: flex;

    align-items: center;

    gap: 13px;

    padding:
        17px
        20px;

    border-radius: 17px;

    background:

        linear-gradient(
            135deg,
            rgba(255,184,0,0.1),
            rgba(255,105,0,0.05)
        );

    border:
        1px solid
        rgba(255,184,0,0.16);
}


.wrapper--v2 .prize-pool__icon {

    font-size: 28px;
}


.wrapper--v2 .prize-pool__text strong {

    display: block;

    color: #fff;

    font-size: 12px;

    font-weight: 900;
}


.wrapper--v2 .prize-pool__text span {

    display: block;

    margin-top: 3px;

    color:
        var(--text-muted);

    font-size: 10px;
}


/* ============================================================
   PAYMENT
   ============================================================ */

.wrapper--v2 .payment-section {

    width:
        min(
            900px,
            calc(100% - 40px)
        );

    margin: 0 auto;

    padding-bottom: 25px;
}


.wrapper--v2 .payment-card {

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 20px;

    padding:
        18px
        20px;

    border-radius: 17px;

    background:
        rgba(255,255,255,0.03);

    border:
        1px solid
        rgba(255,255,255,0.06);
}


.wrapper--v2 .payment-card__text span {

    display: block;

    color:
        var(--gold-light);

    font-size: 8px;

    font-weight: 900;

    letter-spacing: 1px;
}


.wrapper--v2 .payment-card__text strong {

    display: block;

    margin-top: 4px;

    color: #fff;

    font-size: 12px;
}


.wrapper--v2 .payment-methods {

    display: flex;

    align-items: center;

    justify-content: flex-end;

    flex-wrap: wrap;

    gap: 7px;
}


.wrapper--v2 .payment-method {

    padding:
        7px
        9px;

    border-radius: 6px;

    color:
        rgba(255,255,255,0.65);

    background:
        rgba(255,255,255,0.06);

    font-size: 7px;

    font-weight: 900;
}


/* ============================================================
   LIVE PLAYER + TRUST / LICENSE BADGES
   (the proof-card here is the same "Live Player / Recent Winner" card
   that used to sit in the hero's left column below the promo card — moved
   out to its own row, right above the footer, alongside the trust badges,
   once the promo card started height-matching the wheel column (see the
   PROMO/WHEEL HEIGHT SYNC script) and no longer had room below it for
   this card to sit naturally.)
   ============================================================ */

.wrapper--v2 .bottom-row {

    width:
        min(
            1700px,
            calc(100% - 40px)
        );

    margin: 0 auto;

    padding: 10px 0 25px;

    display: flex;

    align-items: center;

    gap: 30px;
}


/* Overrides .proof-card's own width:100% (correct when it was the sole
   content filling the hero column it used to live in) — here it's one of
   two flex siblings, not the whole row. Equal 1 1 0 basis on both this
   and .trust-badges below splits the row 50/50 regardless of either
   side's own content width (was a fixed 420px here + flex:1 on
   trust-badges, which let the badges strip's own wide image push it to
   take up far more than half the row). */
.wrapper--v2 .bottom-row .proof-card {

    width: auto;

    /* Still fills its full even half of .bottom-row (kept a true 50/50
       split — no max-width cap here). "Smaller" comes from shrinking the
       card's own internal sizing instead: see .proof-card__image's
       shorter aspect-ratio and the reduced padding/font-sizes on
       .proof-card__header/__eyebrow/h3 below. */
    flex: 1 1 0;

    min-width: 0;
}


.wrapper--v2 .bottom-row .trust-badges {

    flex: 1 1 0;

    min-width: 0;

    text-align: center;
}


.wrapper--v2 .trust-badges__image {

    max-width: 100%;

    height: auto;
}


/* No footer_image configured — .trust-badges (above) drops out of the
   markup entirely, leaving .proof-card as .bottom-row's only child.
   Its own flex:1 1 0 (bottom-row .proof-card above) would otherwise
   still stretch it to the row's full width; centered and capped here
   to the same width it holds in the normal 50/50 split. */
.wrapper--v2 .bottom-row--centered {

    justify-content: center;
}

.wrapper--v2 .bottom-row--centered .proof-card {

    flex: 0 1 auto;

    /* 540px = the 3/2 image box at its 360px max-height (see
       .proof-card__image), so the win-proof photo fills the card edge to
       edge with no dark side bars. */
    width: min(100%, 540px);
}


/* ============================================================
   FOOTER
   ============================================================ */

.wrapper--v2 .footer {

    padding:
        30px
        20px
        40px;

    border-top:
        1px solid
        rgba(255,255,255,0.06);
}


.wrapper--v2 .footer__inner {

    width:
        min(
            900px,
            100%
        );

    margin: 0 auto;

    text-align: center;
}


.wrapper--v2 .footer__brand img {

    /* lucky-wheel.css's global reset (unscoped `img { display: block; }`)
       makes this a block element, so .footer__inner's text-align:center
       (which only centers inline content) has no effect on it — that's
       why the text below it centered correctly but the logo itself sat
       flush at the left edge. A block element needs its own auto margins
       to center. */
    margin: 0 auto;

    max-width: 130px;
    max-height: 45px;

    object-fit: contain;

    opacity: 0.7;
}


.wrapper--v2 .footer__brand span {

    color:
        rgba(255,255,255,0.55);

    font-size: 14px;

    font-weight: 900;
}


.wrapper--v2 .footer p {

    margin:
        10px
        0
        0;

    color:
        rgba(255,255,255,0.35);

    font-size: 9px;
}


/* ============================================================
   RESULT POPUP
   ============================================================ */

.wrapper--v2 ~ .result-popup {

    position: fixed;

    inset: 0;

    z-index: 9999;

    display: flex;

    align-items: center;
    justify-content: center;

    padding: 20px;

    visibility: hidden;

    opacity: 0;

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease;
}


.wrapper--v2 ~ .result-popup.is-open {

    visibility: visible;

    opacity: 1;
}


.result-popup__overlay {

    position: absolute;

    inset: 0;

    background:
        rgba(0,0,0,0.78);

    backdrop-filter:
        blur(6px);
}


.result-popup__box {

    position: relative;

    z-index: 2;

    width:
        min(
            430px,
            100%
        );

    padding:
        35px
        25px
        28px;

    text-align: center;

    border-radius: 25px;

    background:

        linear-gradient(
            145deg,
            #1c1c1c,
            #0d0d0d
        );

    border:
        1px solid
        rgba(255,200,50,0.2);

    box-shadow:
        0 30px 80px
        rgba(0,0,0,0.6);
}


.result-popup__close {

    position: absolute;

    top: 10px;
    right: 13px;

    width: 35px;
    height: 35px;

    border: 0;

    border-radius: 50%;

    color:
        rgba(255,255,255,0.65);

    background:
        rgba(255,255,255,0.05);

    cursor: pointer;

    font-size: 24px;
}


/* Hidden (not removed from the DOM) for the custom popup_image branch —
   the button element must stay present since the popup's JS requires
   #closeResultPopup to exist (see the RESULT POPUP script's early-return
   guard) and still attaches its click handler either way. The dark
   overlay behind the card is still click-to-close, so this doesn't strand
   the visitor without a way to dismiss it. */
.result-popup__box--custom .result-popup__close {

    display: none;
}


.result-popup__icon {

    font-size: 48px;

    margin-bottom: 10px;
}


.result-popup__eyebrow {

    color:
        var(--gold-light);

    font-size: 9px;

    font-weight: 900;

    letter-spacing: 1.5px;
}


.result-popup__box h2 {

    margin:
        8px
        0;

    color: #fff;

    font-size: 32px;

    font-weight: 950;
}


.result-popup__box p {

    margin:
        0
        0
        22px;

    color:
        var(--text-muted);

    font-size: 13px;
}


.result-popup__cta {

    width: 100%;

    min-height: 52px;

    border: 0;

    border-radius: 14px;

    color: #15100a;

    background:

        linear-gradient(
            180deg,
            #ffe77d,
            var(--gold)
        );

    font-size: 13px;

    font-weight: 950;

    cursor: pointer;
}


/* ============================================================
   RESULT POPUP — custom admin-uploaded popup_image
   (a whole pre-built card, not a background behind the default
   icon/eyebrow/title/box chrome — see the blade's @if($popupImage) branch)
   ============================================================ */

.result-popup__box--custom {

    width: auto;

    padding: 0;

    background: none;

    border: 0;

    box-shadow: none;

    display: flex;

    flex-direction: column;

    align-items: center;

    gap: 18px;
}


/* Attention shake — plays when the visitor clicks the dark overlay outside
   this card (see the RESULT POPUP script's overlay click handler). Not
   dismissible that way on purpose (no close button either — see
   .result-popup__close's override above), so this is the "no, focus back
   here" feedback instead of just doing nothing. */
.result-popup__box--shake {

    animation:
        resultPopupShake
        0.5s
        ease;
}


@keyframes resultPopupShake {

    0%,
    100% {
        transform: translateX(0);
    }

    20%,
    60% {
        transform: translateX(-10px);
    }

    40%,
    80% {
        transform: translateX(10px);
    }
}


.result-popup__custom-media {

    position: relative;

    width:
        min(
            360px,
            88vw
        );

    /* Locks this wrapper to the same box as .result-popup__custom-image
       inside it (1039:1513, the current popup_image's own canvas ratio) —
       a future popup_image at a different ratio needs this recomputed to
       match, same as the wheel frame's spec. */
    aspect-ratio: 1039 / 1513;

    max-height: 78vh;
}


.result-popup__custom-image {

    display: block;

    width: 100%;
    height: 100%;

    object-fit: contain;

    filter:

        drop-shadow(
            0 30px 60px
            rgba(0, 0, 0, 0.6)
        );
}


/* Positioned over the transparent cutout left in the middle of the image
   for exactly this — measured via flood-fill on popup_image's alpha
   channel: ~18%-82% across, ~58%-73% down the canvas. Re-measure if
   popup_image is ever swapped for one with a differently-placed cutout. */
.result-popup__custom-message {

    position: absolute;

    left: 18%;
    top: 57.8%;

    width: 64%;
    height: 15.2%;

    margin: 0;

    display: flex;

    align-items: center;
    justify-content: center;

    /* Fills the cutout with the theme gold (matches the spin button/grand
       prize gradient) instead of leaving it showing the dark overlay
       behind the popup through the transparent hole. */
    border-radius: 10px;

    background:

        linear-gradient(
            180deg,
            #ffe77d 0%,
            var(--gold) 50%,
            #e48b00 100%
        );

    color: #2b1500;

    font-size:
        clamp(
            18px,
            5vw,
            26px
        );

    font-weight: 950;

    text-align: center;

    text-transform: uppercase;

    text-shadow:
        0 1px 0 rgba(255, 255, 255, 0.35),
        0 2px 3px rgba(0, 0, 0, 0.25);
}


/* Admin-chosen prize-text color (popup_text_color), set as --popup-text-color
   on the box. Scoped under --custom so it outranks the generic
   ".result-popup__box p" muted color; with no custom color it falls back to
   the dark brown the classic gold box already uses. The framed layout sets
   its own white default further down. */
.result-popup__box--custom .result-popup__custom-message {

    color: var(--popup-text-color, #2b1500);
}


/* CLASSIC layout (default) — the CTA lives inside .result-popup__custom-media
   in the markup but is pulled back out below the card, matching the original
   look. Bottom padding reserves its space (52px button + 18px gap) since an
   absolutely-positioned child no longer counts toward the box height. */
.result-popup__box--classic {

    padding-bottom: 70px;
}


.result-popup__box--classic .result-popup__cta--custom {

    position: absolute;

    top: 100%;
    left: 0;

    width: 100%;

    margin-top: 18px;
}


/* FRAMED layout — for art with a lower frame/banner: plain big prize text
   (no gold box) in the middle frame, and the CTA inside the lower frame.
   Regions measured off the "ONG MARI" art (1039:1513). Scoped under
   --framed so it outranks the generic ".result-popup__box p" rule
   (13px muted text) and the base .result-popup__cta's 52px min-height. */
/* Card-relative sizing: 1cqw = 1% of the art's own width, so the prize
   text scales with the card (not the viewport) and a short label like
   "TRY AGAIN" stays on one line instead of wrapping into the frame. */
.result-popup__box--framed .result-popup__custom-media {

    container-type: inline-size;
}


.result-popup__box--framed .result-popup__custom-message {

    left: 17%;
    top: 33%;

    width: 66%;
    height: 37%;

    border-radius: 0;

    background: none;

    color: var(--popup-text-color, #fff);

    /* vw clamp first as the fallback for browsers without container
       query units. */
    font-size:
        clamp(
            26px,
            8vw,
            34px
        );

    font-size: 9cqw;

    line-height: 1.1;

    /* Long prize names ("300% WELCOME BONUS") wrap evenly on two lines. */
    text-wrap: balance;

    text-shadow:
        0 2px 0 rgba(120, 20, 0, 0.9),
        0 4px 10px rgba(0, 0, 0, 0.55);
}


.result-popup__box--framed .result-popup__cta--custom {

    position: absolute;

    /* left + width/2 = 50% — centered on the art's own axis. */
    left: 19%;
    top: 77%;

    width: 62%;
    height: 8%;

    min-height: 0;

    padding: 0;

    border-radius: 8px;

    /* One line only — the label is shrunk to fit by fitPopupText() in the
       RESULT POPUP script (this is just its starting/maximum size), so a long
       CTA like "KLAIM BONUS SEKARANG" scales down instead of wrapping out of
       the frame. */
    white-space: nowrap;

    line-height: 1;

    overflow: hidden;

    padding: 0 3%;

    font-size:
        clamp(
            13px,
            4vw,
            18px
        );
}


/* ============================================================
   SOCIAL PROOF
   ============================================================ */

.wrapper--v2 ~ .social-proof {

    position: fixed;

    left: 20px;
    bottom: 20px;

    z-index: 500;

    max-width: 280px;

    transform:
        translateY(20px);

    opacity: 0;

    pointer-events: none;

    transition:
        opacity 0.3s ease,
        transform 0.3s ease;
}


.wrapper--v2 ~ .social-proof.is-visible {

    transform:
        translateY(0);

    opacity: 1;
}


.wrapper--v2 ~ .social-proof
.social-proof__inner {

    display: flex;

    align-items: center;

    gap: 10px;

    padding:
        10px
        13px;

    border-radius: 13px;

    background:
        rgba(20,20,20,0.95);

    border:
        1px solid
        rgba(255,255,255,0.08);

    box-shadow:
        0 12px 35px
        rgba(0,0,0,0.4);

    backdrop-filter:
        blur(10px);
}


.social-proof__avatar {

    width: 30px;
    height: 30px;

    flex-shrink: 0;

    display: flex;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    color: #111;

    background:

        linear-gradient(
            135deg,
            var(--gold-light),
            var(--gold)
        );

    font-size: 11px;

    font-weight: 900;
}


.social-proof__content strong {

    display: block;

    color: #fff;

    font-size: 10px;
}


.social-proof__content span {

    display: block;

    margin-top: 2px;

    color:
        rgba(255,255,255,0.55);

    font-size: 9px;
}


.social-proof__check {

    margin-left: auto;

    color: #5df28c;

    font-size: 13px;

    font-weight: 900;
}


/* ============================================================
   TABLET
   ============================================================ */

@media (max-width: 900px) {

    .wrapper--v2 .hero {

        grid-template-columns: 1fr;

        gap: 25px;

        width:
            min(
                600px,
                calc(100% - 30px)
            );

        padding-top: 20px;
    }


    .wrapper--v2 .hero__wheel-col {

        order: 1;
    }


    .wrapper--v2 .hero__promo-col {

        order: 2;

        /* PROMO/WHEEL HEIGHT SYNC script only applies its max-height
           above this breakpoint (columns are stacked here, not
           side-by-side, so matching heights makes no sense) — clear it
           explicitly too in case a resize crosses this breakpoint while
           it's still set. */
        max-height: none !important;
    }


    .wrapper--v2 .bottom-row {

        flex-direction: column;

        align-items: stretch;
    }


    .wrapper--v2 .bottom-row .proof-card {

        flex-basis: auto;
    }


    .wrapper--v2 .stage {

        width:
            min(
                100%,
                350px
            );

        /* Same frame-overflow clearance as the desktop rule above,
           recomputed for this width (~0.22 * 350). */
        margin-top: 80px;
    }


    .wrapper--v2 .spin-center {

        /* Same frame-overflow clearance as .stage's own margin-top just
           above (0.22 * 350) plus the same ~10px gap as the desktop rule. */
        margin-top: 90px;
    }


    .wrapper--v2 .promo-card__content h2 {

        font-size: 34px;
    }

}


/* ============================================================
   MOBILE
   ============================================================ */

@media (max-width: 600px) {

    .wrapper--v2 .topbar {

        padding:
            14px
            15px
            3px;
    }


    .wrapper--v2 .brand__logo {

        max-width: 145px;
        max-height: 48px;
    }


    .wrapper--v2 .hero {

        width:
            calc(100% - 24px);

        gap: 20px;

        padding:
            15px
            0
            25px;
    }


    .wrapper--v2 .grand-prize {

        width: 100%;

        box-sizing: border-box;

        margin-bottom: 10px;
    }

    /* Content padding now lives on .grand-prize__surface (the innermost
       layer), not .grand-prize itself — see the nested-layer border
       structure above. */
    .wrapper--v2 .grand-prize__surface {

        padding:
            14px
            18px;
    }


    .wrapper--v2 .grand-prize strong {

        font-size: 29px;
    }


    .wrapper--v2 .stage {

        width:
            min(
                100%,
                290px
            );

        aspect-ratio: 1 / 1;

        /* Same frame-overflow clearance as the desktop rule above,
           recomputed for this width (~0.22 * 290). */
        margin-top: 65px;
    }


    .wrapper--v2 .wheel {

        width: 99%;
        height: 99%;
    }


    .wrapper--v2 .wheel__inner {

        width: 100%;
        height: 100%;

        border-width: 1px;
    }


    .wrapper--v2 .wheel-pointer {

        top: -1px;

        width: 32px;
    }


    .wrapper--v2 .wheel-segment {

        font-size: 9px;
    }


    .wrapper--v2 .wheel-segment span {

        width: 62px;
    }


    .wrapper--v2 .spin-center {

        width: 170px;

        min-height: 68px;

        /* Was 0 — the frame still overflows ~0.22 * 290 (.stage's width at
           this breakpoint) past .stage's bottom edge here too, so the
           button sat directly on top of that overflow. */
        margin-top: 75px;
    }


    .wrapper--v2 .spin-center__text {

        font-size: 24px;
    }


    .wrapper--v2 .wheel-message {

        margin-top: 12px;

        padding:
            11px
            13px;
    }


    .wrapper--v2 .promo-card,
    .wrapper--v2 .proof-card {

        border-radius: 18px;
    }


    .wrapper--v2 .promo-card__content {

        padding:
            18px
            19px
            20px;
    }


    .wrapper--v2 .promo-card__content h2 {

        font-size: 31px;
    }


    .wrapper--v2 .proof-card__header {

        padding:
            14px
            15px;
    }


    .wrapper--v2 .proof-card__footer {

        padding:
            12px
            15px;
    }


    .wrapper--v2 .countdown-section,
    .wrapper--v2 .prize-pool,
    .wrapper--v2 .payment-section {

        width:
            calc(100% - 24px);
    }


    .wrapper--v2 .countdown-card {

        padding:
            17px
            10px;
    }


    .wrapper--v2 .countdown {

        gap: 5px;
    }


    .wrapper--v2 .countdown__item {

        min-width: 53px;
    }


    .wrapper--v2 .countdown__item strong {

        font-size: 23px;
    }


    .wrapper--v2 .countdown__separator {

        font-size: 17px;
    }


    .wrapper--v2 .payment-card {

        flex-direction: column;

        align-items: flex-start;
    }


    .wrapper--v2 .payment-methods {

        width: 100%;

        justify-content: flex-start;
    }


    /* Was left:12px + right:12px + max-width:none — stretched the toast
       edge-to-edge on every phone width, so on a wide phone it read as
       a full banner instead of the small floating card the desktop
       version is. Kept as a compact corner card here too, just capped
       tighter than desktop's 280px so it still clears the screen edges
       with room to spare. */
    .wrapper--v2 ~ .social-proof {

        left: 12px;
        right: auto;
        bottom: 12px;

        max-width: min(260px, calc(100% - 24px));
    }


    .wrapper--v2 ~ .social-proof .social-proof__inner {

        padding:
            9px
            12px;

        gap: 8px;
    }


    .wrapper--v2 ~ .social-proof .social-proof__avatar {

        width: 26px;
        height: 26px;

        font-size: 10px;
    }


    .wrapper--v2 ~ .social-proof .social-proof__content strong {

        font-size: 9px;
    }


    .wrapper--v2 ~ .social-proof .social-proof__content span {

        font-size: 8px;
    }

}


/* ============================================================
   SMALL PHONES
   ============================================================ */

@media (max-width: 380px) {

    .wrapper--v2 .stage {

        width: 240px;

        max-width: 100%;

        /* Same frame-overflow clearance as the desktop rule above,
           recomputed for this width (~0.22 * 240). */
        margin-top: 55px;
    }


    .wrapper--v2 .spin-center {

        width: 150px;

        /* Same frame-overflow clearance as .stage's own margin-top above
           (0.22 * 240) plus the same ~10px gap as the other breakpoints. */
        margin-top: 65px;
    }


    .wrapper--v2 .countdown__item {

        min-width: 47px;
    }


    .wrapper--v2 .countdown__item strong {

        font-size: 20px;
    }


    .wrapper--v2 .grand-prize strong {

        font-size: 25px;
    }

}

