/* The same homepage stage; only the real-mountain study controls are new. */
#mountain-images{position:absolute;inset:0;z-index:-2;pointer-events:none}
.winter-study .mountain-image{z-index:auto;opacity:0;object-position:var(--mountain-crop,50%) 15%;transition:opacity 650ms cubic-bezier(.16,1,.3,1)}
.winter-study .mountain-image.is-current{opacity:1}
.winter-study .season-picker{width:380px}
.winter-study .season-buttons{grid-template-columns:repeat(3,minmax(0,1fr));gap:4px 18px}
.winter-study .season-buttons button{font-size:12px;white-space:nowrap}
#mountain-status{font-size:11px;line-height:1.5;margin:7px 0 0;color:var(--chalk)}
#mountain-status:empty{display:none}
.winter-study footer .conditions{max-width:55%}
@media(max-width:600px){
 .winter-study .arrival{padding-top:250px;gap:0}
 .winter-study .season-picker{width:100%;margin-top:22px}
 .winter-study .mountain-image{object-position:var(--mountain-crop,50%) 15%}
 .winter-study footer{align-items:start;flex-direction:column;gap:8px}
 .winter-study footer .conditions{max-width:100%;flex-direction:row;flex-wrap:wrap;gap:3px 12px}
 .winter-study .footer-actions{width:100%;justify-content:space-between;gap:16px}
 .winter-study .footer-actions a{max-width:none;white-space:nowrap;text-align:left;font-size:11px}
}

/* Feather the wordmark protection into the scene, including brighter overcast skies. */
.winter-study .shade{background:linear-gradient(180deg,rgba(9,18,28,.6),rgba(9,18,28,.48) 90px,transparent 240px,transparent 54%,rgba(9,18,28,.7))}
@media(max-width:600px){.winter-study .shade{background:linear-gradient(180deg,rgba(9,18,28,.6),rgba(9,18,28,.48) 90px,transparent 240px,transparent 40%,#09121ccb)}}

.winter-study canvas.mountain-image{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}
.motion-toggle{display:block;border:0;background:none;padding:10px 0;min-height:44px;font-size:11px;color:var(--glacier);text-decoration:underline;text-underline-offset:4px;margin-top:4px}

.motion-actions{display:flex;gap:24px;align-items:center}
#motion-controls{position:absolute;z-index:2;right:var(--edge);top:120px;width:326px;max-height:calc(100% - 200px);overflow:auto;overscroll-behavior:contain;background:rgba(16,28,39,.97);border:1px solid #d5e6e933;padding:22px 24px;scrollbar-width:thin;scrollbar-color:#859da6 #17212c;box-shadow:0 16px 60px #050e1940}
#motion-controls .panel-intro{margin:14px 0 20px}
.motion-element{margin-bottom:18px}.motion-element legend{margin-bottom:8px;font-size:13px;color:var(--chalk)}
.motion-range{display:flex;justify-content:space-between;align-items:center;font-size:12px;gap:16px}.motion-range output{min-width:3em;text-align:right}
.motion-help{font-size:11px;line-height:1.6;color:var(--glacier);margin:10px 0 0}
.motion-panel-actions{display:flex;justify-content:space-between;gap:20px;margin-top:15px}.motion-panel-actions button{min-height:44px}
@media(max-width:600px){#motion-controls{top:112px;left:18px;right:18px;width:auto;max-height:calc(100% - 190px);padding:20px 22px}}

#motion-controls .panel-heading{position:sticky;top:-22px;background:#101c27;z-index:1;padding:12px 0;margin-top:-12px}

#motion-controls{display:flex;flex-direction:column;max-height:calc(100% - 150px);overflow:hidden;border:0}
#motion-controls .panel-heading{position:static;flex-shrink:0;margin:0;padding:0;background:none}
.motion-panel-body{min-height:0;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin}
#motion-controls .panel-intro{font-size:12px;margin:10px 0 12px}
.motion-panel-body .motion-element{margin-bottom:10px}
.motion-panel-body .motion-element legend{margin-bottom:2px}
.motion-panel-body .check-label{min-height:26px}
.motion-panel-body input[type=range]{margin:5px 0 0;height:24px}
.motion-panel-footer{flex-shrink:0}.motion-panel-actions{margin-top:8px}
@media(max-width:600px){#motion-controls{max-height:calc(100% - 155px)}}

/* Explanations belong to the lab controls, above the sliders rather than the landscape. */
.motion-label,.motion-element legend{display:flex;align-items:center;gap:5px}
.motion-explain{display:inline-flex;align-items:center;justify-content:center;width:26px;height:26px;padding:5px;border:0;background:none;color:var(--glacier);cursor:help;border-radius:50%}
.motion-explain svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.5}
.motion-explain:hover,.motion-explain:focus-visible{color:var(--chalk);background:#d5e6e919}
#motion-tooltip{position:absolute;z-index:5;left:18px;right:18px;padding:14px 16px;background:#263b49;color:var(--chalk);box-shadow:0 8px 24px #050e1955;font-size:12px;line-height:1.6;pointer-events:auto}
#motion-tooltip strong{display:block;font-weight:500;margin-bottom:4px;color:#fff}

/* Four choices, with speed nested under the motion it controls. */
#motion-controls{width:340px;top:110px;padding:22px 24px;max-height:calc(100% - 135px)}
#motion-controls .panel-intro{margin:10px 0 20px;color:var(--glacier)}
.motion-panel-body .motion-element{margin-bottom:18px}
.motion-element legend{width:100%;justify-content:space-between}
.motion-range{font-size:11px;color:var(--glacier);gap:8px;margin-top:3px}
.motion-range output{flex:1;text-align:center;font-variant-numeric:tabular-nums}
.motion-element.is-still .motion-range,.motion-element.is-still input[type=range]{opacity:.45}
.scene-choice{margin:0 0 16px}.scene-choice legend{width:100%;display:flex;align-items:center;justify-content:space-between;font-size:13px;color:var(--chalk)}
.scene-options{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}
.scene-options button{min-height:38px;background:none;border:0;border-bottom:1px solid #d5e6e947;color:var(--glacier);padding:7px 0;text-align:left;font-size:12px}
.scene-options button:hover{color:var(--chalk)}
.scene-options button[aria-pressed=true]{border-bottom:2px solid var(--chalk);color:var(--chalk)}
.scene-choice:disabled .scene-options{opacity:.45}
.scene-wind-note{font-size:12px;margin:0}
.motion-panel-actions{gap:12px}.motion-panel-actions button{white-space:nowrap}
.winter-study[data-light=warm] img.mountain-image{filter:sepia(.12) brightness(1.035)}
.winter-study[data-light=moody] img.mountain-image{filter:brightness(.84) saturate(.88)}
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
@media(max-width:600px){#motion-controls{width:auto;top:112px;max-height:calc(100% - 145px);padding:20px 22px}}

#motion-controls .motion-help{font-size:12px}

/* Comfortable touch targets; the panel body scrolls on shorter phones. */
@media(pointer:coarse),(max-width:600px){
 .motion-explain{width:44px;height:44px;flex-shrink:0}
 .motion-panel-body .check-label{min-height:44px}
 .motion-panel-body input[type=range]{height:44px}
 .scene-options button{min-height:44px}
}

@media(max-width:600px){
 #motion-controls{position:fixed;top:max(90px,env(safe-area-inset-top));max-height:calc(100dvh - 108px - env(safe-area-inset-bottom))}
}
@media(max-height:600px){
 #motion-controls{position:fixed;top:max(18px,env(safe-area-inset-top));max-height:calc(100dvh - 36px - env(safe-area-inset-bottom))}
}

/* Phone composition: the landscape stays open; choosing and tuning are disclosures. */
.mobile-mountain-picker,.picker-region{display:none}
#mountain-picker{position:fixed;inset:auto 0 0;width:100%;max-width:none;max-height:84svh;margin:0;padding:24px 24px max(24px,env(safe-area-inset-bottom));border:0;background:#101c27;color:var(--chalk);overflow:auto;overscroll-behavior:contain;scrollbar-color:#859da6 #101c27}
#mountain-picker::backdrop{background:#07121a80}
#mountain-picker .panel-heading{margin-bottom:12px}
#mountain-picker h2{font-size:28px}
#mountain-picker-location{font-size:13px;line-height:1.5;color:var(--glacier);margin:0 0 20px}
#mountain-picker legend{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
#mountain-picker .season-buttons{display:flex;flex-direction:column;gap:0}
#mountain-picker .season-buttons button{position:relative;min-height:64px;padding:12px 32px 12px 0;font-size:17px;white-space:normal;line-height:1.4}
#mountain-picker .picker-region{display:block;margin-top:3px;font-size:12px;color:var(--glacier)}
#mountain-picker .season-buttons button[aria-pressed=true]::after{content:'';position:absolute;right:6px;top:23px;width:6px;height:12px;border:solid var(--chalk);border-width:0 1.5px 1.5px 0;transform:rotate(45deg)}
@media(max-width:600px),(max-width:900px) and (max-height:500px){
 .winter-study .season-picker>#mountain-choices{display:none}
 .winter-study .landscape-page{min-height:100svh}
 .winter-study header{padding:26px 24px 0}
 .winter-study .wordmark{font-size:30px}
 .winter-study .arrival{display:flex;flex-direction:column;align-items:stretch;gap:28px;margin-top:auto;padding:clamp(130px,29svh,250px) 24px max(24px,env(safe-area-inset-bottom))}
 .winter-study h1{font-size:34px;line-height:1.08}
 .winter-study .scene-caption{font-size:14px;line-height:1.55;max-width:33ch;margin-top:14px;text-wrap:pretty}
 .winter-study .season-picker{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:12px 20px;width:100%;margin:0;padding-top:14px;border-top:1px solid #d5e6e94d}
 .mobile-mountain-picker{display:grid;position:relative;gap:5px;width:100%;padding:6px 30px 6px 0;min-height:58px;border:0;background:none;text-align:left}
 .mobile-mountain-picker>span{font-size:12px;color:var(--glacier)}
 .mobile-mountain-picker strong{font-size:17px;line-height:1.35;font-weight:400}
 .mobile-mountain-picker svg{position:absolute;right:4px;top:22px;width:18px;height:18px;stroke:currentColor;stroke-width:1.4;fill:none}
 .winter-study .motion-actions{margin:0;display:block}
 .winter-study #motion-tune{font-size:14px;padding:12px 0;margin:0;min-height:48px;text-decoration:none}
 .winter-study #mountain-status{grid-column:1/-1;margin:0;font-size:12px}
 .winter-study footer{display:none}
 .winter-study .shade{background:linear-gradient(180deg,#09121c99,transparent 26%,transparent 42%,#09121cd9 84%,#09121cf2)}
 #motion-controls{position:fixed;inset:auto 0 0;width:100%;max-height:88svh;background:#101c27;padding:24px 24px max(24px,env(safe-area-inset-bottom));margin:0}
 #motion-controls .panel-intro{font-size:14px}
 #motion-controls .check-label,#motion-controls .scene-choice legend{font-size:14px}
 #motion-controls .scene-options button{font-size:14px}
 #motion-controls .motion-panel-footer>.motion-toggle{font-size:13px;margin-top:8px}
}
@media(max-width:360px){.winter-study .arrival{padding-left:20px;padding-right:20px;gap:22px}.winter-study h1{font-size:31px}.winter-study .scene-caption{font-size:13px}.winter-study .season-picker{column-gap:12px}.winter-study #motion-tune{font-size:13px}}
@media(max-width:900px) and (max-height:500px){.winter-study .arrival{padding-top:60px}.winter-study h1{font-size:30px}}

/* Keep the title and close action reachable as the resort list grows. */
#mountain-picker[open]{display:flex;flex-direction:column;overflow:hidden}
#mountain-picker .panel-heading,#mountain-picker-location{flex-shrink:0}
#mountain-picker-list{min-height:0;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin}
