/* No scrolling: every screen fits the window. The page is locked to the viewport,
   media takes a fixed share, and the panel lays out to fill what is left. fit.js then fine tunes. */
html,body{height:100%;overflow:hidden!important}
.app{height:100vh;height:100dvh;overflow:hidden}
.shell,.main{min-height:0;overflow:hidden}
.view{overflow:hidden!important;height:100%;min-height:0}
.split{height:100%;min-height:0;max-height:100%;overflow:hidden;align-content:stretch!important;align-items:stretch!important;box-sizing:border-box}
.split-panel{min-height:0;overflow:hidden;justify-content:flex-start}
.split-media{min-height:0;overflow:hidden;display:flex;flex-direction:column;align-items:center;justify-content:center;position:relative!important;top:auto!important}
.split-media>*{max-width:100%}
.split-panel>.cta:last-child,.split-panel>.navrow,.split-panel>.nexthelp{flex-shrink:0}
.split-panel>.navrow,.split-panel>.cta:last-child{margin-top:auto;position:relative!important;bottom:auto!important}
.split-panel>.navrow+.nexthelp{margin-top:0}
.nav{overflow:hidden!important}

/* Desktop and landscape tablet: two columns, both centred in the height */
@media (min-width:900px){
  .split{grid-template-rows:minmax(0,1fr)!important;padding:clamp(14px,2.2vw,32px)!important;gap:clamp(16px,2.4vw,36px)!important}
  .split-panel{justify-content:center}
  .split-panel>.navrow,.split-panel>.cta:last-child{margin-top:8px}
  .split-media .pstage,.split-media .phero,.split-media .demo-main,.split-media .scene-wrap,.split-media .cstage{max-height:100%}
  .split-media .pstage{display:flex;flex-direction:column;width:auto!important;max-width:100%!important}
  .split-media .pstage img{height:auto;max-height:calc(100dvh - 240px);width:auto;max-width:100%;aspect-ratio:auto!important;object-fit:contain}
  .split-media .phero img,.split-media .demo-main img{max-height:calc(100dvh - 220px)}
  .split-media .mstack{max-height:100%;display:grid;gap:10px}
  .split-media .mstack .phero img{max-height:calc(100dvh - 380px)}
  .split-media .mstack .pstage img{max-height:calc(100dvh - 400px)}
  .split-media .scene-wrap{width:min(100%,calc((100dvh - 200px)*1.6))!important}
}

/* Phone and portrait tablet: media on top at a fixed share, panel fills the rest */
@media (max-width:899px){
  .split{grid-template-columns:1fr!important;grid-template-rows:auto minmax(0,1fr)!important;padding:12px 14px 12px!important;gap:10px!important}
  .split.intro-split{grid-template-rows:auto minmax(0,1fr)!important}
  .split-panel{gap:9px}
  .split-media{max-height:30dvh}
  .split-media .pstage{display:flex;flex-direction:row;align-items:stretch;width:100%;max-width:100%!important;margin:0}
  .split-media .pstage img{height:24dvh;width:auto;max-width:58%;aspect-ratio:auto!important;object-fit:cover;flex:0 0 auto}
  .split-media .pstage figcaption{flex-direction:column;align-items:flex-start;justify-content:center;padding:10px 12px}
  .split-media .phero,.split-media .demo-main{width:100%;aspect-ratio:auto!important}
  .split-media .phero img,.split-media .demo-main img{height:22dvh;width:100%;aspect-ratio:auto!important;object-fit:cover}
  .split-media .phero.big img{height:24dvh}
  .split-media .mstack{display:flex;gap:8px;width:100%;align-items:stretch}
  .split-media .mstack>*{flex:1 1 0;min-width:0}
  .split-media .mstack .phero img{height:20dvh}
  .split-media .mstack .pstage{flex-direction:column}
  .split-media .mstack .pstage img{height:17dvh;max-width:100%;width:100%}
  .split-media .mstack .pstage figcaption{padding:6px 10px}
  .split-media .mstack .meters{padding:10px 12px;gap:6px;align-content:center}
  .split-media .mstack .study{flex-direction:column;align-items:flex-start;gap:4px;padding:10px 12px}
  .split-media .mstack .study .big{font-size:32px}
  .split-media .ingrow{width:100%}
  .split-media .ingrow img{aspect-ratio:auto;height:15dvh}
  .split-media .scene-wrap{width:min(100%,calc(28dvh*1.6))!important;margin:0 auto}
  .split-media .scene-wrap.photo img{aspect-ratio:1.6;height:auto}
  .split-media .scene-wrap.photo.alertpic img{aspect-ratio:2.2}
  .title{font-size:clamp(34px,10vw,48px)!important}
  .qtext{font-size:19px!important}
  .choice{padding:10px 12px!important;font-size:14px!important}
  .said{padding:10px 12px;font-size:14px!important}
  .bubble{padding:9px 12px;font-size:14px!important}
  .guide .ava{flex-basis:44px;height:44px}
  .verdict{padding:10px 12px;font-size:14px}
  .hint{font-size:12.5px}
  .cta{padding:13px 18px}
}

/* Bottom sheet in Module B fits without scrolling too */
.sheet{overflow:hidden!important;max-height:94%!important}
@media (max-width:899px){.sheetpic img{aspect-ratio:3!important}}

/* Segmented controls and pagers used by the paged screens */
.tabs.three{grid-template-columns:repeat(3,1fr)}
.cswitch{display:flex;gap:6px;flex-wrap:wrap}
.cswitch button{border:1.5px solid var(--line);background:#fff;border-radius:999px;padding:7px 12px;font-weight:700;font-size:13px;color:var(--ink)}
.cswitch button.on{border-color:var(--plum);background:#F7EEF3}
.cswitch button.ok{color:var(--good)}
.rline{display:flex;flex-wrap:wrap;align-items:center;gap:6px;background:#fff;border:1px solid var(--line);border-radius:14px;padding:10px 12px}
.rline span{display:inline-flex;align-items:center;gap:6px;font-size:13px;font-weight:700;color:var(--ink)}
.rline span b{width:20px;height:20px;border-radius:50%;display:grid;place-items:center;font-size:11px;background:var(--soft)}
.rline span.hi{color:var(--warm)}.rline span.hi b{background:var(--grad-btn);color:#fff}
.rline i{font-style:normal;color:var(--muted)}
.split-panel>*{flex-shrink:0}
.split-panel>.ghost{flex:0 0 auto}
@media (max-width:899px){.split-panel .choice.fade{display:none}}
/* Module B specifics */
.intro-split .split-media{max-height:none!important;justify-content:flex-start}
@media (max-width:899px){.intro-split .tracks .trk svg{max-height:16dvh}}
@media (min-width:900px){.split-panel .alertpic{display:none!important}}
.split-panel .choice.fade{display:none}
.sheetpic img{aspect-ratio:3!important}
.jobdetails summary{cursor:pointer;list-style:none;display:flex;justify-content:space-between;align-items:center}
.jobdetails summary::-webkit-details-marker{display:none}
.jobdetails summary::after{content:"+";font-size:22px;font-weight:700;color:var(--plum)}
.jobdetails[open] summary::after{content:"−"}
.jobdetails summary h4{margin:0!important}
.jobdetails:not([open]){gap:0}
.sheet .tog,.sheet .chip{padding:9px 12px;font-size:14px}
.sheet .chips{gap:6px}
.sheet h3{font-size:26px!important;margin:2px 0 4px!important}
.sheet p{font-size:14px;margin-bottom:8px}
.sheet .why{margin-top:10px;padding:10px 12px}
.sheet .why p{font-size:14px;margin-top:4px}
.sheet .close{margin-top:10px;padding:12px}
.sheet .hold{height:72px}
@media (min-width:900px){.sheet{width:min(540px,46%)!important;padding:22px!important}}
@media (max-width:899px){.badge{width:96px!important;height:96px!important}.split-panel .stats .stat{padding:8px}.split-panel .stat span{font-size:18px}}
.intro-split .split-media{align-items:stretch!important}
.app{grid-template-rows:auto auto minmax(0,1fr)!important}.hud{grid-row:1}.pips{grid-row:2}.shell{grid-row:3;height:100%}
.sheetpic.tall img{aspect-ratio:2!important}
a.ghost.dl{display:flex;align-items:center;justify-content:center;gap:10px;text-decoration:none;font-weight:700;font-size:14px;padding:13px 14px}
a.ghost.dl .dli{width:26px;height:26px;border-radius:50%;display:grid;place-items:center;background:var(--grad-btn);color:#fff;font-size:15px}
a.ghost.dl small{font-size:11px;font-weight:800;color:var(--plum);background:#F7EEF3;border-radius:6px;padding:2px 6px}
