/* Standalone H5: no desktop preview chrome at any viewport width. */
:root{--nav-height:calc(65px + env(safe-area-inset-bottom,0px))}
body{background:var(--bg)}
.phone-shell{width:100%;max-width:560px;min-height:100vh;margin:0 auto;border:0;border-radius:0;box-shadow:none}
#app{min-height:100dvh}
.bottom-nav,.booking-bar{width:100%;max-width:560px;left:50%}
.bottom-nav{height:var(--nav-height);padding:8px 12px calc(9px + env(safe-area-inset-bottom,0px))}
.bottom-nav a.active:after{top:-9px}
.booking-bar{bottom:var(--nav-height)}
#toast{left:50%}
.route-progress{left:max(0px,calc(50% - 280px));width:min(100%,560px);margin-left:0}
.intro-inner{max-width:560px;border:0}

.hero-bottom{justify-content:flex-end}

/* Keep account navigation fixed, with a soft edge over the scrolling cards. */
:root{--account-tabs-height:72px;--account-fade-height:28px}
.account-top{position:fixed;top:0;left:50%;transform:translateX(-50%);z-index:35;width:100%;max-width:560px;background:var(--bg)}
.account-top .app-header{height:var(--page-header-height);padding-top:env(safe-area-inset-top,0px)}
.account-top:after{content:"";position:absolute;top:100%;left:0;right:0;height:var(--account-fade-height);pointer-events:none;background:linear-gradient(to bottom,var(--bg),transparent);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);-webkit-mask-image:linear-gradient(to bottom,#000,transparent);mask-image:linear-gradient(to bottom,#000,transparent)}
.account-top-space{height:calc(var(--page-header-height) + var(--account-tabs-height));pointer-events:none}
.account-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;padding:23px var(--gutter) 0}
.account-tabs>button{position:relative;min-height:49px;padding:13px 10px;border:1px solid #3a424d;background:#171c23;color:#aab7c7;font-size:14px;line-height:1.5;text-align:center;transition:background .15s,color .15s}
.account-tabs>button[aria-selected="true"]{background:#e9edf0;border-color:#e9edf0;color:#141a21;font-weight:500}
.account-tabs>button[aria-selected="true"]:after{content:"";position:absolute;height:3px;left:-1px;right:-1px;bottom:-1px;background:linear-gradient(90deg,#78c7ed 0 33.33%,#224e9b 33.33% 66.66%,#e32b3a 66.66%)}
.account-tabs>button:focus-visible{outline:2px solid #91c6ed;outline-offset:4px}
.account-order-list{padding-top:var(--account-fade-height);padding-bottom:28px}
.account-order-list .empty-state{grid-column:1/-1}

/* Keep the page navigation available while browsing schedules and courses. */
:root{--page-header-height:calc(64px + env(safe-area-inset-top,0px))}
body:is([data-page="schedule"],[data-page="station"],[data-page="courses"],[data-page="course"]) .app-header{position:fixed;top:0;left:50%;right:auto;transform:translateX(-50%);z-index:35;width:100%;max-width:560px;height:var(--page-header-height);padding-top:env(safe-area-inset-top,0px);background:#101215;border-bottom:1px solid #ffffff14}
body:is([data-page="schedule"],[data-page="courses"]) #app{padding-top:var(--page-header-height)}
body:is([data-page="schedule"],[data-page="station"],[data-page="courses"],[data-page="course"]) .app-header>span{min-width:0;max-width:calc(100% - 100px);overflow:hidden;white-space:nowrap;text-overflow:ellipsis}
.header-spacer{width:36px;height:36px;flex:0 0 36px}
.header-title-only .header-title{text-align:center}
.contact-options>a.contact-row{display:flex;align-items:center;gap:17px;text-align:left;padding:21px 0;width:100%;border-bottom:1px solid var(--line)}
.contact-options>a.contact-row>.icon:first-child{width:24px;height:24px;color:#8faed2;stroke-width:1.2}
.contact-options>a.contact-row>span{flex:1;min-width:0}
.contact-options>a.contact-row>.icon:last-child{width:17px;height:17px;color:#6f8eaf}
.contact-row small{overflow-wrap:anywhere}
.support-qr{display:flex;flex-direction:column;align-items:center;padding:6px 0 12px}
.support-qr-image{width:min(100%,244px);height:auto;aspect-ratio:1;background:#fff;border:12px solid #fff;border-radius:4px;-webkit-touch-callout:default}
.support-qr-note{font-size:12px;color:var(--muted);line-height:1.8;text-align:center;margin:15px 0 0}

/* A single-screen home: image carousel, campaign message and the BMW M strip. */
body[data-page="home"] #app{padding-bottom:var(--nav-height)}
body[data-page="home"] .home-hero{height:calc(100svh - var(--nav-height) - 54px);height:calc(100dvh - var(--nav-height) - 54px);min-height:0;max-height:none}
body[data-page="home"] .experience-strip{height:54px;padding-block:0}
body[data-page="home"] .home-header{top:calc(24px + env(safe-area-inset-top,0px))}
body[data-page="home"] .hero-edition{top:calc(93px + env(safe-area-inset-top,0px))}
body[data-page="home"] .hero-content{bottom:65px;z-index:2}
.home-carousel,.home-slides,.home-slide{position:absolute;inset:0}
.home-carousel{pointer-events:none}
.home-slides{background:#101215}
.home-slide{opacity:0;transition:opacity .8s ease;overflow:hidden}
.home-slide.is-active{opacity:1}
.home-slide-image{width:100%;height:100%;object-fit:cover;display:block}
.home-slide-image[hidden]{display:none}
.home-slide.is-image-missing{background:linear-gradient(145deg,#242c36,#101215 65%)}
.hero-carousel-controls{position:absolute;bottom:12px;left:var(--gutter);right:var(--gutter);z-index:4;display:flex;align-items:center;justify-content:center;gap:14px;pointer-events:auto}
.hero-carousel-dots{display:flex;align-items:center;gap:2px}
.hero-carousel-dot{width:26px;height:34px;padding:0;display:grid;place-items:center}
.hero-carousel-dot>span{width:6px;height:6px;border:1px solid #f3f4f7a0;border-radius:50%;background:transparent;transition:background .2s,transform .2s}
.hero-carousel-dot[aria-pressed="true"]>span{background:#f3f4f7;border-color:#f3f4f7;transform:scale(1.18)}
.station-card.is-ended{opacity:.52;filter:grayscale(1);cursor:default}
.station-card.is-ended:before{display:none}
.station-card.is-ended:hover .track-outline{transform:none;color:inherit}
.station-card.is-ended .availability{color:#afb4bd}
.support-phone-group{padding:21px 0;border-bottom:1px solid var(--line)}
.support-phone-heading{display:flex;align-items:center;gap:17px;margin-bottom:17px}
.support-phone-heading>.icon{width:24px;height:24px;color:#8faed2;stroke-width:1.2}
.support-phone-cards{display:grid;gap:10px}
.support-phone-card{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:15px 17px;background:#171c23;border:1px solid #343d49}
.contact-options .support-phone-card b{font-size:12px;line-height:1.7}
.contact-options .support-phone-card small{font:500 19px/1.5 "Barlow Condensed",sans-serif;letter-spacing:1px;color:#d4dde8;margin-top:5px}
.support-phone-card>.icon{width:20px;height:20px;color:#a9bfd4}
.support-faq-list{font-size:11px;color:var(--muted);line-height:1.9;margin:0;padding:0 14px 18px 19px}
.support-faq-list>li+li{margin-top:9px}
.support-qr-crop{position:relative;width:min(100%,280px);aspect-ratio:1;overflow:hidden;background:#fff;border-radius:3px}
.support-qr-crop-image{position:absolute;width:119.3548387%;height:auto;max-width:none;left:-9.67741935%;top:-32.2580645%;display:block;-webkit-touch-callout:default}
.support-wechat-copy{display:inline-flex;align-items:center;justify-content:center;gap:9px;padding:9px 12px;margin-top:9px;border:1px solid #566477;color:#d4e0ee;font-size:12px}
.support-wechat-copy>.icon{width:15px;height:15px}
@media(max-height:620px){body[data-page="home"] .hero-content h1{font-size:38px;line-height:1.08}body[data-page="home"] .hero-content>p{font-size:10px;margin:12px 0 14px;line-height:1.6}body[data-page="home"] .hero-content>p>span{font-size:9px}body[data-page="home"] .hero-content>.eyebrow{font-size:8px;margin-bottom:10px}body[data-page="home"] .hero-content>.primary-button{min-height:44px;padding-block:10px}body[data-page="home"] .hero-content{bottom:54px}body[data-page="home"] .hero-edition{display:none}}
@media(max-height:500px){body[data-page="home"] .home-hero{min-height:250px}body[data-page="home"] .home-header{top:calc(12px + env(safe-area-inset-top,0px))}body[data-page="home"] .hero-content{bottom:48px}body[data-page="home"] .hero-content>.eyebrow,body[data-page="home"] .hero-side-label{display:none}body[data-page="home"] .hero-content h1{font-size:30px;line-height:1.02}body[data-page="home"] .hero-content>p{margin:8px 0 10px}body[data-page="home"] .hero-content>.primary-button{min-height:40px;padding-block:8px}.hero-carousel-controls{bottom:5px}}
@media(prefers-reduced-motion:reduce){.home-slide,.hero-carousel-dot>span{transition:none}}

body.has-page-message:is([data-page="station"],[data-page="course"]) #app{padding-top:var(--page-header-height)}
body[data-page="home"] .phone-shell{min-height:100dvh}
