/* ==========================================================================
   "Check Your Score" banner (Default.aspx only)
   Source: Gaming portal mobile app (1).zip / winsphere-spin-win/css/section.css

   Differences from the source file, all page-integration only:
     - demo-shell rules (body, .sw-demo) dropped -- this lives inside the
       existing page instead of standing alone;
     - .toast kept (and given a z-index) since js/spin-win.js still uses it;
     - .banner margins keep this page's spacing, not the demo's 34px 18px 0
       (the wp-header that used to sit above the banner is commented out, so
       the top margin stops it crowding the global search bar, and the bottom
       margin separates it from the first category row);
     - .banner::after sparkles kept from the previous version of this file.

   The wheel (.wheel-wrap/.wheel/.prize/.wheel-pointer/.hub) and the
   mascot-walk/mascot-lane keyframes are gone: the wheel is not part of this
   design, and the mascot now animates via video rather than CSS.
   ========================================================================== */
:root {
    --accent: #a855f7;
    --accent-deep: #6d28d9;
    --gold: #f0b429;
    --gold-lt: #f0c14e;
    --font-d: 'Sora', system-ui, sans-serif;
    --font-b: 'DM Sans', system-ui, sans-serif;
}

.toast {
    position: fixed;
    left: 50%;
    transform: translateX(-50%);
    bottom: 34px;
    padding: 10px 16px;
    border-radius: 999px;
    background: rgba(20, 8, 38, .95);
    border: 1px solid rgba(199, 155, 255, .4);
    font: 700 12px var(--font-d);
    box-shadow: 0 14px 30px -14px #000;
    z-index: 100000;
}

.toast[hidden] {
    display: none;
}

/* ---------------- banner ---------------- */
.banner {
    margin: 24px 16px 18px;
    border-radius: 24px;
    padding: 14px 14px 0;
    position: relative;
    clip-path: inset(-90px 0 0 0 round 24px);
    display: grid;
    /* Two columns now (mascot | copy) -- the third column was the wheel.
       The source used a bare `minmax(112px, 46%)`, which is safe in its own
       440px demo shell but not here: .winsphere-page has no max-width, so on
       a desktop viewport 46% would make the mascot hundreds of pixels wide.
       min(46%, 200px) is identical up to ~435px (every real phone width) and
       frozen past that -- same cap the previous version of this file had. */
    grid-template-columns: minmax(112px, min(46%, 200px)) minmax(0, 1fr);
    gap: 6px;
    align-items: end;
    min-height: 186px;
    background: linear-gradient(118deg, #2b1055 0%, #41127a 46%, #8321b4 100%);
    border: 1px solid rgba(255, 255, 255, .14);
    box-shadow: 0 18px 40px -18px rgba(124, 58, 237, .85);
}

.banner::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(60% 80% at 20% 95%, rgba(199, 125, 255, .42), transparent 62%),
                radial-gradient(70% 90% at 92% 40%, rgba(255, 255, 255, .16), transparent 60%);
}

.banner::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(circle at 62% 22%, rgba(240, 180, 41, .75) 0 2px, transparent 3px),
                radial-gradient(circle at 48% 62%, rgba(240, 180, 41, .55) 0 2px, transparent 3px),
                radial-gradient(circle at 70% 78%, rgba(255, 255, 255, .5) 0 1.6px, transparent 3px);
}

/* mascot: static PNG, shown until the video canvas is ready (and again if the
   canvas can't be read at all) */
.banner-mascot {
    position: relative;
    z-index: 1;
    cursor: pointer;
    align-self: end;
    height: 186px;
    clip-path: inset(-90px 0 0 0);
}

.banner-mascot img {
    pointer-events: none;
    position: absolute;
    left: -26%;
    bottom: -6px;
    width: 152%;
    height: auto;
    max-width: none;
    filter: drop-shadow(0 14px 20px rgba(24, 6, 48, .7));
}

.banner.mascot-ready .banner-mascot img {
    visibility: hidden;
}

/* video mascot: black background keyed out on a canvas */
.mascot-stage {
    position: absolute;
    z-index: 3;
    pointer-events: none;
    /* Percentages here resolve against .banner, which is full-width on this
       page -- so they get the same pixel cap as the mascot column above.
       Below ~435px these are exactly the source's -5.5% / 118%. */
    left: max(-5.5%, -24px);
    bottom: 0;
    width: min(118%, 512px);
    aspect-ratio: 16/9;
    transform: translateY(8%);
}

.mascot-stage video,
.mascot-stage canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
}

/* not 0: browsers pause fully invisible muted video */
.mascot-stage video {
    opacity: .01;
}

.mascot-stage canvas {
    opacity: 0;
    transition: opacity .3s ease;
    filter: drop-shadow(0 12px 16px rgba(24, 6, 48, .55));
}

.banner.mascot-ready .mascot-stage canvas {
    opacity: 1;
}

.banner.mascot-ready.mascot-fade .mascot-stage canvas {
    opacity: 0;
}

/* fallback when the canvas can't read the video (tainted by a cross-origin or
   file:// source) -- blend the raw video instead of keying it */
.banner.mascot-blend .mascot-stage canvas {
    display: none;
}

.banner.mascot-blend .mascot-stage video {
    opacity: 1;
    mix-blend-mode: screen;
    transition: opacity .3s ease;
}

.banner.mascot-blend.mascot-fade .mascot-stage video {
    opacity: .01;
}

.mascot-glow {
    position: absolute;
    left: 4%;
    bottom: 8px;
    width: 92%;
    height: 34%;
    border-radius: 50%;
    filter: blur(7px);
    transform-origin: 50% 50%;
    animation: mascot-glow-pulse 8s ease-in-out infinite;
    background: radial-gradient(ellipse at 50% 60%, rgba(199, 125, 255, .6), transparent 70%);
}

@keyframes mascot-glow-pulse {
    0%, 100% { transform: scaleX(1); opacity: .75; }
    25%, 75% { transform: scaleX(.9); opacity: 1; }
}

/* copy */
.banner-copy {
    position: relative;
    z-index: 2;
    min-width: 0;
    align-self: center;
    padding: 14px 4px 18px 0;
    text-align: left;
}

/* unused by the current markup, kept so a badge can be dropped back in */
.banner .pill {
    display: inline-block;
    padding: 4px 9px;
    border-radius: 999px;
    background: rgba(0, 0, 0, .3);
    font: 700 9px var(--font-d);
    letter-spacing: 1.3px;
    color: var(--gold-lt);
    white-space: nowrap;
}

.banner-title {
    margin: 0 0 4px;
    font: 800 clamp(30px, 10vw, 42px) / .95 var(--font-d);
    letter-spacing: -1.4px;
    background: linear-gradient(180deg, #fff, #e6ccff 60%, #c79bff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 6px 18px rgba(124, 58, 237, .6);
}

.banner-title span {
    display: block;
    font-weight: 600;
    font-size: .44em;
    letter-spacing: 2.4px;
    margin: 0 0 4px;
    -webkit-text-fill-color: rgba(255, 255, 255, .7);
}

.btn-gold {
    display: inline-block;   /* rendered as an <a> (asp:HyperLink) on Default.aspx */
    text-decoration: none;
    margin-top: 10px;
    border: 0;
    cursor: pointer;
    padding: 9px 16px;
    border-radius: 999px;
    white-space: nowrap;
    font: 700 12px var(--font-d);
    color: #2b0b4d;
    background: linear-gradient(120deg, #ffe9a3, var(--gold));
    box-shadow: 0 8px 18px -8px rgba(240, 180, 41, .95), inset 0 1px 0 rgba(255, 255, 255, .7);
    transition: filter .18s;
    animation: btn-blink 1.4s ease-in-out infinite;
}

/* `animation: none`, not just a filter override: keyframed properties outrank
   normal declarations in the cascade, so the hover brightness would otherwise
   be ignored while the blink is running. Dropping the animation hands filter
   back to the rule below. */
.btn-gold:hover {
    animation: none;
    filter: brightness(1.08);
}

/* As an <a>, the label would otherwise turn white (styles.css:
   ".winsphere-page a { color: inherit }") or, on hover/focus, blue and
   underlined (Bootstrap) -- a.btn-gold outranks both. */
a.btn-gold,
a.btn-gold:hover,
a.btn-gold:focus {
    color: #2b0b4d;
    text-decoration: none;
}

/* Attention pulse on the CTA -- brightness plus a widening gold halo rather
   than an on/off opacity flash, which reads as a glitch on a solid button. */
@keyframes btn-blink {
    0%, 100% {
        filter: brightness(1);
        box-shadow: 0 8px 18px -8px rgba(240, 180, 41, .95),
                    0 0 0 0 rgba(255, 214, 106, 0),
                    inset 0 1px 0 rgba(255, 255, 255, .7);
    }
    50% {
        filter: brightness(1.22);
        box-shadow: 0 8px 22px -6px rgba(240, 180, 41, 1),
                    0 0 16px 3px rgba(255, 214, 106, .75),
                    inset 0 1px 0 rgba(255, 255, 255, .9);
    }
}

.banner-shine {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .5), transparent);
    background-size: 200% 100%;
    animation: shimmer 3.4s linear infinite;
}

@keyframes shimmer {
    0% { background-position: -160% 0; }
    100% { background-position: 260% 0; }
}

/* Scoped to .banner (the source file used a bare `*`, which would have killed
   every animation and transition on the rest of this page). */
@media (prefers-reduced-motion: reduce) {
    .banner, .banner * {
        animation: none !important;
        transition: none !important;
    }
}
