/* 1.0.065 — shared compact header, short winner feedback. */
.sga .world-header.world-header-unified{display:flex;flex-wrap:nowrap;align-items:center;gap:clamp(6px,1.1vw,18px);min-height:60px;padding:8px clamp(8px,1.5vw,24px);position:relative;z-index:8;overflow:visible}
.sga .world-header-unified .world-brand{flex:none;gap:7px}.sga .world-header-unified .world-brand strong{font-size:clamp(16px,1.5vw,22px);white-space:nowrap}.sga .world-header-unified .world-mark{width:38px;height:38px;flex:none}.sga .world-header-unified .world-header-right{margin-left:auto;flex:none;gap:7px}.sga .world-header-unified .sga-version{display:none}
.sga .world-header-unified>.world-nav{flex:1 1 auto;display:flex;align-items:center;justify-content:flex-start;flex-wrap:nowrap;gap:3px;min-width:0;padding:0;border:0;background:transparent!important}.sga .world-header-unified>.world-nav .world-nav-item{min-height:44px;padding:7px clamp(5px,.7vw,13px);gap:5px;white-space:nowrap;font-size:13px}.sga .world-header-unified>.world-nav .world-nav-item span{font-size:17px}.sga .world-header-unified>.world-nav .world-current-game{display:none}.sga .world-header-unified .sw-extra-menu{flex:none}.sga .world-header-unified .sw-extra-menu summary{min-width:40px;width:40px;height:40px;min-height:40px}.sga .world-header-unified .sw-extra-menu nav a{color:#edf2ff;text-decoration:none}
@container sga (max-width:1090px){.sga .world-header.world-header-unified{flex-wrap:wrap;gap:6px;padding:6px 10px}.sga .world-header-unified>.world-nav{order:5;flex:1 0 100%;display:flex;justify-content:space-between;gap:3px}.sga .world-header-unified>.world-nav .world-nav-item{flex:1 1 0;min-width:0;justify-content:center;font-size:12px;padding:5px 3px;min-height:44px}.sga .world-header-unified .world-header-right{margin-left:auto}.sga .world-header-unified .world-brand strong{font-size:16px}.sga .world-header-unified .world-mark{width:32px;height:32px}}
@container sga (max-width:650px){.sga .world-header-unified>.world-nav .world-nav-item{flex-direction:column;gap:3px;font-size:10px;min-height:45px}.sga .world-header-unified .world-header-right{gap:4px}.sga .world-header-unified .world-brand{gap:5px}.sga .world-header-unified .world-brand strong{font-size:14px}.sga .world-header-unified .sw-extra-menu summary{width:36px;min-width:36px;height:40px;min-height:40px}.sga .world-header-unified .world-mark{width:30px;height:30px}.sga .world-header-unified .world-avatar{min-width:38px;padding:5px 7px}.sga .world-header-unified .world-online-label{display:none}}
@container sga (max-width:380px){.sga .world-header-unified .world-brand strong{font-size:12px}.sga .world-header-unified .world-mark{width:26px;height:28px;font-size:18px}.sga .world-header-unified .world-coin-chip{padding:4px;max-width:65px}.sga .world-header-unified .world-header-right{gap:3px}.sga .world-header.world-header-unified{padding-inline:6px;gap:4px}}
.sga.world-fullscreen-active>.world-header.world-header-unified{display:none!important}
/* Non-blocking overlay, visible in native or CSS fullscreen. No game input interception. */
.sga .sw-victory{position:fixed;inset:0;z-index:10000;pointer-events:none;overflow:hidden;isolation:isolate;background:radial-gradient(ellipse at 62% 35%,#f5c95f28,transparent 66%);animation:sw-victory-life 1.9s both;color:#fff}
.sga .sw-victory.sw-victory-race{position:absolute;inset:0;z-index:10;background:linear-gradient(100deg,transparent 15%,#18254b28 85%)}.sga .sw-victory-finish .sw-victory-label{border-color:#96d7e8;background:#16405a}.sga .sw-victory-figure{position:absolute;right:5%;bottom:8%;height:78%;width:44%;max-width:420px;animation:sw-mascot-sway 1.9s ease-in-out both;transform-origin:50% 96%}.sga .sw-victory-race .sw-victory-figure{right:4%;bottom:13%;height:74%;width:36%}.sga .sw-victory-mascot,.sga .sw-victory-flag{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;object-position:center;filter:drop-shadow(0 4px 10px #0006)}.sga .sw-victory-flag{clip-path:polygon(19% 0,79% 0,79% 19%,61% 15%,28% 15%,17% 21%);transform-origin:27% 15%;animation:sw-flag-wave .65s ease-in-out infinite alternate}
.sga .sw-victory-label{position:absolute;left:50%;top:11%;transform:translateX(-50%);display:flex;align-items:center;gap:10px;padding:12px clamp(14px,3vw,35px);border-radius:18px;border:2px solid #ffe5a1;background:linear-gradient(150deg,#8055e7,#3d2589);box-shadow:0 5px 30px #ffc64b50;color:white;white-space:nowrap;font-size:clamp(20px,4vw,50px);font-weight:900;line-height:1.1;text-shadow:0 2px 3px #231645}.sga .sw-victory-cup{font-size:1.2em}.sga .sw-victory-particles{position:absolute;inset:0;overflow:hidden}.sga .sw-confetti{position:absolute;top:-4%;left:var(--x);width:9px;height:15px;background:var(--color);border-radius:2px;animation:sw-confetti-fall 1.55s var(--delay) linear both}.sga .sw-firework{position:absolute;left:var(--x);top:var(--y);width:0;height:0;animation:sw-firework-burst 1.05s calc(var(--delay) + 320ms) ease-out both}.sga .sw-firework-ray{position:absolute;left:0;top:0;width:clamp(24px,6vw,85px);height:3px;border-radius:100%;background:linear-gradient(90deg,transparent,var(--color),#fff);transform-origin:left center;transform:rotate(var(--angle));box-shadow:0 0 9px var(--color)}.sga .sw-rocket{position:absolute;bottom:12%;left:var(--x);height:24px;width:5px;background:linear-gradient(white,var(--color),transparent);border-radius:4px;animation:sw-rocket-rise .5s var(--delay) ease-out both}
.sga .mr-pickup-pop{position:absolute;z-index:8;left:50%;top:44%;transform:translate(-50%,-50%);display:grid;justify-items:center;pointer-events:none;animation:sw-pickup-bump .9s both;color:#ffdf75;filter:drop-shadow(0 0 12px #facc15aa)}.sga .mr-pickup-repair{color:#b2ffcf;filter:drop-shadow(0 0 10px #55e7a4aa)}.sga .mr-pickup-art{width:clamp(85px,19vw,155px);max-height:140px;object-fit:contain}.sga .mr-pickup-label{font-size:clamp(22px,4vw,40px);font-weight:900;line-height:1;text-shadow:0 2px 4px #102131,0 0 4px #102131}.sga .mr-condition.mr-heal-pulse{animation:sw-heal-pulse .9s ease-out both}
@keyframes sw-victory-life{0%{opacity:0}8%,84%{opacity:1}100%{opacity:0}}@keyframes sw-mascot-sway{0%{transform:translateY(10%) rotate(-2deg) scale(.94)}16%,65%{transform:translateY(0) rotate(1deg) scale(1)}40%,85%{transform:translateY(-1%) rotate(-1.5deg) scale(1)}100%{transform:translateY(2%) rotate(0)}}@keyframes sw-flag-wave{from{transform:rotate(-2deg) skewY(-1deg)}to{transform:rotate(2deg) skewY(1deg)}}@keyframes sw-confetti-fall{0%{transform:translateY(0) rotate(var(--rot));opacity:.95}100%{transform:translate(var(--dx),105vh) rotate(calc(var(--rot) + 520deg));opacity:.15}}@keyframes sw-firework-burst{0%{transform:scale(.08);opacity:0}15%{opacity:.95}80%{opacity:.7}100%{transform:scale(1.4);opacity:0}}@keyframes sw-rocket-rise{0%{transform:translateY(0);opacity:1}95%{opacity:1}100%{transform:translateY(-52vh);opacity:0}}@keyframes sw-pickup-bump{0%{transform:translate(-50%,-50%) scale(.55);opacity:0}20%{transform:translate(-50%,-55%) scale(1.16);opacity:1}35%,70%{transform:translate(-50%,-60%) scale(1);opacity:1}100%{transform:translate(-50%,-80%) scale(.94);opacity:0}}@keyframes sw-heal-pulse{0%,100%{box-shadow:none}25%{box-shadow:0 0 0 3px #91f5bc,0 0 25px #72f2b5;background:#236744}65%{box-shadow:0 0 12px #72f2b5}}
@media(max-width:600px) and (orientation:portrait){.sga .sw-victory-figure{right:9%;width:75%;height:68%;bottom:9%}.sga .sw-victory-race .sw-victory-figure{width:57%;height:65%;bottom:16%;right:4%}.sga .sw-victory-label{top:12%;font-size:clamp(20px,6vw,34px)}}@media(max-height:500px) and (orientation:landscape){.sga .sw-victory-label{top:8%;font-size:clamp(18px,4vh,29px);padding:7px 16px}.sga .sw-victory-figure{height:84%;bottom:5%}.sga .sw-victory-race .sw-victory-figure{height:76%;bottom:10%}}
@media(prefers-reduced-motion:reduce){.sga .sw-victory,.sga .sw-victory-figure,.sga .sw-victory-flag,.sga .mr-pickup-pop,.sga .mr-condition.mr-heal-pulse{animation:none!important}.sga .sw-victory-flag,.sga .sw-victory-particles{display:none}.sga .mr-condition.mr-heal-pulse{outline:2px solid #91f5bc}}

/* Reveal the actual finish-line scene for the short winner presentation, then restore the result dialog. */
.sga .mr-viewport:has(>.sw-victory-race)>.mr-overlay:has(#mr-finished:not([hidden])){background:transparent;pointer-events:none}.sga .mr-viewport:has(>.sw-victory-race) #mr-finished{visibility:hidden}

/* Separately rigged cloth and head from the approved transparent illustration. */
.sga .sw-victory-rig{position:absolute;inset:0;opacity:0;filter:drop-shadow(0 4px 10px #0006)}.sga .sw-rig-ready>.sw-victory-mascot{opacity:0}.sga .sw-rig-ready>.sw-victory-rig{opacity:1}.sga .sw-victory-rig>img{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;object-position:center;filter:none}.sga .sw-victory-rig>.sw-victory-flag{clip-path:none;transform-origin:27% 13%;animation:sw-flag-rig .58s ease-in-out infinite alternate}.sga .sw-victory-head{transform-origin:50% 38%;animation:sw-head-nod .85s ease-in-out infinite alternate}
@keyframes sw-flag-rig{from{transform:rotate(-1.5deg) skewY(-.6deg)}to{transform:rotate(1.6deg) skewY(.6deg)}}@keyframes sw-head-nod{from{transform:rotate(-.8deg) translateY(0)}to{transform:rotate(.9deg) translateY(-.2%)}}
@media(max-width:600px) and (orientation:portrait){.sga .sw-victory-race .sw-victory-figure{width:43%;height:58%;right:2%;bottom:21%}}
@media(prefers-reduced-motion:reduce){.sga .sw-rig-ready>.sw-victory-mascot{opacity:1}.sga .sw-victory-rig{display:none}}
