/* Scoped seasonal layer; Standard layout and existing controls are retained. */
html[data-msf-halloween="on"] body {
 --msf-bg:#111018; --msf-surface:#191720; --msf-raised:#211d27;
 background-color:#111018!important;
 background-image:radial-gradient(ellipse at 50% 0,rgba(132,32,39,.18),transparent 52%),radial-gradient(ellipse at 0 80%,rgba(85,45,104,.1),transparent 40%)!important;
 isolation:isolate;
}
html[data-msf-halloween="on"] body[data-msf-design] :is(.msf-home-tool,.search-wrap #searchInput) {border-color:#634047!important;}
html[data-msf-halloween="on"] body[data-msf-design] .msf-home-tool {background:linear-gradient(145deg,#25212b,#191b26)!important;}
html[data-msf-halloween="on"] .msf-galea-bolt path {fill:#000!important;}
html[data-msf-halloween="on"] .msf-galea-art:has([data-member-galea="halloween-skull"]) .msf-galea-bolt {display:none;}
.hw-decoration {pointer-events:none;user-select:none;object-fit:contain;}
.hw-web-layer {position:absolute;top:0;left:0;right:0;height:280px;z-index:1000;pointer-events:none;overflow:hidden;}
.hw-web-layer * {pointer-events:none!important;}
.hw-web {position:absolute;top:-8px;width:clamp(160px,18vw,250px);height:auto;opacity:.52;}
.hw-web-left {left:-10px;}
.hw-web-right {right:-10px;transform:scaleX(-1);}
html:not([data-msf-halloween="on"]) .hw-decoration {display:none!important;}
.hw-toolbar,.hw-game-card,.hw-dialog {font-family:Outfit,system-ui,sans-serif;box-sizing:border-box;line-height:1.45;text-align:left;}
html body .hw-toolbar {position:relative;z-index:1;display:flex;align-items:center;flex-wrap:wrap;gap:12px;width:min(720px,calc(100% - 32px));margin:12px auto 24px;padding:9px 12px;border:1px solid #694248;border-radius:12px;background:#231c24;color:#f4e8e1;}
.hw-toolbar-title {display:flex;align-items:center;gap:8px;font-size:13px;letter-spacing:.025em;white-space:nowrap;}
.hw-beta {display:inline-block;font:700 9px/1.3 system-ui,sans-serif;letter-spacing:.08em;color:#ffbe87;background:#9e532a2b;border:1px solid #b8784c63;padding:3px 5px;border-radius:4px;}
.hw-toolbar-controls {display:flex;gap:6px;align-items:center;margin-left:auto;flex-wrap:wrap;}
html body .hw-button,html body .hw-close {font:600 12px/1.3 Outfit,system-ui,sans-serif;display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:44px;border:1px solid #65505b;border-radius:8px;background:#302631;color:#fff3eb;padding:9px 12px;cursor:pointer;text-transform:none;letter-spacing:0;box-shadow:none;transition:background-color 150ms ease-out,transform 120ms ease-out;}
html body .hw-toolbar .hw-button {min-height:44px;}
html body .hw-button[aria-pressed="true"] {border-color:#bc6558;background:#4b292e;}
.hw-button:active,.hw-candy:active {transform:scale(.97);}
.hw-icon {width:18px;height:18px;flex:none;filter:invert(1);}
.hw-theme-note {font-size:11px;color:#e8cdbf;flex-basis:100%;}
.hw-theme-note[hidden] {display:none;}
html body .hw-game-card {position:relative;display:flex;align-items:center;justify-content:space-between;gap:16px;width:100%;max-width:1120px;margin:24px auto 12px;padding:22px 26px;border:1px solid #694248;border-radius:16px;background:#221c25;color:#f5ebe5;overflow:hidden;}
.hw-game-copy {position:relative;z-index:1;max-width:65%;}
html body .hw-game-card h2 {font:600 20px/1.2 Outfit,system-ui,sans-serif;margin:0 0 6px;color:#fff1e7;letter-spacing:0;}
html body .hw-game-card p {font:400 13px/1.55 Outfit,system-ui,sans-serif;margin:0 0 12px;color:#d5c7c4;}
.hw-card-count {display:inline-block;font-size:12px;font-variant-numeric:tabular-nums;color:#ffc196;margin-right:12px;}
.hw-candy-art {width:230px;max-width:32%;height:auto;}
html[data-msf-halloween="on"] #searchPage:has(.hw-toggle-art) .msf-home-kicker {display:none!important;}
html[data-msf-halloween="on"] #searchPage .msf-mode-tabs:has(.hw-toggle-art) {position:relative;overflow:visible!important;margin-top:108px!important;}
.hw-toggle-art {position:absolute;width:260px;height:130px;left:50%;bottom:calc(100% - 23px);transform:translateX(-50%);z-index:2;pointer-events:none;user-select:none;}
.hw-skeleton {display:block;width:100%;height:100%;}
html:not([data-msf-halloween="on"]) .hw-toggle-art {display:none;}
html[data-msf-halloween="on"] #modControlsPage .modctl-btn {border-color:#634047;background:linear-gradient(145deg,#25212b,#191b26);}
#modControlsPage>.hw-toolbar {margin:18px auto;}
.hw-candy-slot {display:flex;align-items:center;justify-content:flex-end;position:absolute;z-index:2;}
:is(#counterHomeFooter,#methodology,#inactiveEventsPage .results-header,#tubePage,details.method,footer):has(>.hw-candy-slot) {position:relative;}
.hw-candy-footer {left:6%;bottom:28px;transform:rotate(17deg);}
.hw-candy-review {right:0;bottom:-15px;}
.hw-candy-events {right:0;bottom:-20px;transform:rotate(28deg);}
.hw-candy-tv {right:12px;bottom:4px;}
.hw-candy-guide {right:4px;bottom:0;}
details:not([open])>.hw-candy-slot {display:none;}
.hw-candy-weekly {right:0;bottom:0;}
html body .hw-candy {background:transparent;border:0;box-shadow:none;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;min-width:44px;min-height:44px;padding:9px;border-radius:50%;color:#ffb5a0;}
.hw-candy .hw-icon {width:14px;height:14px;opacity:.68;filter:invert(64%) sepia(21%) saturate(540%) hue-rotate(330deg) brightness(93%);transform:rotate(-18deg);}
.hw-candy:focus-visible .hw-icon {opacity:1;}
.hw-candy[hidden] {display:none!important;}
.hw-collected {font:600 12px/1.4 Outfit,system-ui,sans-serif;color:#ffd6af;padding:7px 10px;background:#312329;border-radius:8px;}
html body .hw-dialog {width:min(540px,calc(100% - 28px));max-height:calc(100dvh - 40px);margin:auto;padding:24px;border:1px solid #76505d;border-radius:18px;background:#201b25;color:#f8ede8;overflow:auto;box-shadow:0 18px 80px #0009;}
.hw-dialog::backdrop {background:#07050dc9;}
.hw-dialog-head {display:flex;align-items:center;justify-content:space-between;gap:12px;}
html body .hw-dialog h2 {font:600 26px/1.2 Outfit,system-ui,sans-serif;color:#fff1e7;margin:0;letter-spacing:0;}
html body .hw-close {padding:8px;min-width:44px;border-color:transparent;background:transparent;}
.hw-hunt-message {font-size:14px;color:#d8cbca;margin:16px 0;}
.hw-hunt-count {display:block;color:#ffc395;font-size:19px;font-variant-numeric:tabular-nums;margin:0 0 12px;}
.hw-hunt-list {list-style:none;margin:0;padding:0;}
.hw-hunt-list li {display:flex;gap:14px;align-items:center;justify-content:space-between;border-top:1px solid #44313e;padding:12px 0;font-size:13px;}
.hw-hunt-list a {color:#f5e6e0;text-decoration:none;display:flex;align-items:center;min-height:44px;}
.hw-item-state {color:#f5b78e;white-space:nowrap;font-size:11px;}
.hw-hunt-list [data-found="true"] .hw-item-state {color:#a8deb4;}
.hw-hints {margin-top:16px;font-size:13px;color:#d8cbca;}
.hw-hints summary {min-height:44px;cursor:pointer;padding:10px 0;box-sizing:border-box;}
.hw-hints a {display:block;min-height:44px;padding:10px 0;box-sizing:border-box;color:#f5e6e0;}
.hw-dialog-foot {margin-top:20px;border-top:1px solid #44313e;padding-top:16px;}
.hw-reward-note {font-size:11px;color:#cbb9bc;line-height:1.5;margin:12px 0 0;}
.hw-button:focus-visible,.hw-close:focus-visible,.hw-candy:focus-visible,.hw-hunt-list a:focus-visible {outline:2px solid #ffd3a0;outline-offset:3px;}
@media(hover:hover) and (pointer:fine){html body .hw-button:hover,html body .hw-close:hover{background:#54343e}.hw-candy:hover{background:#cd644325}.hw-hunt-list a:hover{text-decoration:underline}}
@media(max-width:600px){
 .hw-web {top:-5px;width:140px;opacity:.35;}.hw-web-left{left:-6px;}.hw-web-right{right:-6px;}
 html body .hw-toolbar {width:100%;padding:8px 10px;margin:10px auto 16px;gap:7px;}
 .hw-toolbar-title {font-size:12px;}.hw-toolbar-controls {gap:5px;}
 html body .hw-toolbar .hw-button {font-size:11px;padding:8px;min-height:44px;}
 html body .hw-game-card {padding:18px 16px;gap:10px;margin-top:18px;}
 .hw-game-copy {max-width:75%;}.hw-candy-art {width:105px;max-width:25%;}
 html body .hw-game-card h2 {font-size:18px;}html body .hw-game-card p {font-size:12px;}
 .hw-card-count {display:block;margin-bottom:10px;}
 html[data-msf-halloween="on"] #searchPage .msf-mode-tabs:has(.hw-toggle-art) {margin-top:98px!important;}
 .hw-toggle-art {width:230px;height:115px;bottom:calc(100% - 21px);}
 html body .hw-dialog {padding:18px;}html body .hw-dialog h2 {font-size:22px;}
}
@media(max-width:360px){.hw-toolbar-controls{margin-left:0;width:100%;}.hw-toolbar-controls .hw-button{flex:1;}.hw-candy-art{display:none;}.hw-game-copy{max-width:100%;}}
@media(prefers-reduced-motion:reduce){.hw-button,.hw-candy{transition:none!important;}}

/* Keep Halloween preview controls off the homepage. */
#searchPage > .hw-toolbar{display:none!important}

.hw-theme-choice{display:flex;align-items:center;gap:10px;padding:12px 4px;font:600 15px Outfit,system-ui,sans-serif;min-height:44px;cursor:pointer}.hw-theme-choice input{width:20px;height:20px;accent-color:#ed9852;flex:0 0 auto}.he-theme-earned{color:#ffcf97;font-weight:600}
