/* SAECULA — round 2 additions (saecula lane, 2026-10-09), both pages. The page's own sheet stays inline;
 * everything new for the flight rail, the explore key and the landscape layout lives here, after it. */

/* Every HUD control is a real 44 px box (round 2 sweep: Back 17x34, Today 38x34, Find 73x31, Explore 78x35,
 * Sound 38x34, Menu 38x34). The bar keeps its 58 px height: 7 + 44 + 7. */
.hud{padding-top:calc(env(safe-area-inset-top,0px) + 7px);padding-bottom:7px}
.hud .pill{min-height:44px;min-width:44px;display:inline-flex;align-items:center;justify-content:center}
.hud .pill.ico{width:44px;height:44px}
.hud .pill.tdy{height:44px;min-width:44px}
.hud .pill .lg{margin-right:.4em}
@media (max-width:560px){.hud .out-t{display:none}}   /* the chevron is the way out on a phone; the words collided with Today and Find */
/* FN28: on a phone the way out was a bare chevron — a shape, not a word. The control now
   says where it goes. The second pill beside it still drops out at 560 px. */
.hud .pill.ico.out{width:auto;min-width:44px;padding:0 12px 0 10px;gap:5px}
.hud .out-w{font-family:var(--f-mono);font-size:10.5px;letter-spacing:.16em;text-transform:uppercase}
@media (max-width:340px){.hud .out-w{display:none}.hud .pill.ico.out{width:44px;padding:0}}
/* At 360 the five 44 px pills reached under the back control: Find keeps its name for screen readers, shows the lens. */
@media (max-width:400px){.hud-r{gap:4px}.hud .pill.fnd{width:44px;padding:0;gap:0}.hud .fnd-t{display:none}}
.hud .seg{padding:0;border:0;box-shadow:inset 0 0 0 1px var(--rule)}
.hud .seg button{height:44px}

/* The wordmark leaves narrow screens, where the HUD carries four pills or more (public page at 360: they collided). */
@media (max-width:400px){.hud .brand{display:none}}

/* Snap: every chapter is a stop the flight cannot pass (scroll-snap-stop: always). Off in explore and while the page
 * moves itself (html.tween). The stops are 1 px marks placed by flight.js from the frame loop's own numbers. */
html{scroll-snap-type:y mandatory}
html.snapoff,html.tween{scroll-snap-type:none}
.snap{position:absolute;left:0;width:1px;height:1px;scroll-snap-align:start;scroll-snap-stop:always;pointer-events:none}

/* The chapter rail: where he is in the 24 chapters, what he has watched, and a way to anywhere. */
.rch{position:fixed;right:6px;z-index:8;width:32px;top:180px;bottom:280px;cursor:pointer;touch-action:none;outline:none;pointer-events:auto}
body.explore .rch{display:none}
.rch:focus-visible .rch-tr{background:var(--gold)}
.rch-tr{position:absolute;right:15px;top:0;bottom:0;width:2px;background:var(--rule);border-radius:1px}
.rch-t{position:absolute;right:13px;width:6px;height:1px;background:var(--ink-3);transform:translateY(-.5px)}
.rch-t.seen{background:var(--ink-2)}
.rch-t.age{width:10px;right:11px}
.rch-t.age::before{content:attr(data-r);position:absolute;right:14px;top:-6px;font-family:var(--f-mono);font-size:9px;line-height:1;letter-spacing:.06em;color:var(--ink-3)}
.rch-dot{position:absolute;right:11px;width:10px;height:10px;margin-top:-5px;border-radius:50%;background:var(--gold);box-shadow:0 0 0 3px rgba(5,7,13,.8)}
.rch-pill{position:absolute;right:30px;transform:translateY(-50%);padding:5px 9px;border:1px solid var(--rule);border-radius:999px;background:rgba(5,7,13,.85);font-size:10px;letter-spacing:.12em;white-space:nowrap;color:var(--ink);opacity:0;transition:opacity .4s;pointer-events:none}
.rch-pill.on{opacity:1}
.rch-lab{position:absolute;right:30px;transform:translateY(-50%);max-width:min(260px,70vw);padding:7px 11px;border:1px solid var(--gold);border-radius:10px;background:rgba(5,7,13,.94);font-size:10.5px;letter-spacing:.08em;line-height:1.35;color:var(--ink);white-space:normal;pointer-events:none}
.chp-age{margin:18px 0 6px;color:var(--gold)}

/* Next, on the caption: tap instead of scrolling. */
.cap-next{position:absolute;right:4px;bottom:0;min-height:44px;min-width:44px;padding:0 10px;border:0;background:none;cursor:pointer;font-size:10.5px;letter-spacing:.16em;text-transform:uppercase;color:var(--gold);pointer-events:auto}
.cap-next[hidden],.cap.min .cap-next{display:none}

/* The coach mark (first explore only), above the bottom controls. */
.coach{position:fixed;z-index:12;left:var(--gut);right:var(--gut);top:calc(env(safe-area-inset-top,0px) + 112px);display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;padding:12px 48px 12px 14px;border:1px solid var(--gold);border-radius:14px;background:rgba(5,7,13,.94)}
.coach p{margin:0;flex:1 1 200px;font-size:15px;line-height:1.35;color:var(--ink)}
.coach .act{min-height:44px}
.coach-x{position:absolute;top:2px;right:2px;width:44px;height:44px;border:0;background:none;color:var(--ink-2);font-size:22px;cursor:pointer}
@media (min-width:900px){.coach{right:auto;width:420px}}

/* W3 (10/09): the key row, the century line, the century drawer, the long form, saint names */
.cenl{display:flex;align-items:center;justify-content:space-between;gap:10px;width:100%;min-height:44px;padding:0 16px;border:1px solid var(--rule);border-radius:999px;background:rgba(5,7,13,.62);color:var(--ink);font-family:var(--f-display);font-size:18px;line-height:1.1;cursor:pointer;text-align:left}
.cenl .mono{flex:none;font-size:10.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--ink-2)}
.cenl:disabled{cursor:default}
.keyrow{display:flex;gap:6px;overflow-x:auto;scrollbar-width:none;padding:1px;-webkit-mask-image:linear-gradient(to right,#000 calc(100% - 18px),transparent);mask-image:linear-gradient(to right,#000 calc(100% - 18px),transparent)}
.keyrow::-webkit-scrollbar{display:none}
.kc{flex:none;display:inline-flex;align-items:center;gap:7px;height:44px;padding:0 13px;border:1px solid var(--rule);border-radius:999px;background:rgba(5,7,13,.62);color:var(--ink);font-family:var(--f-mono);font-size:10.5px;letter-spacing:.1em;text-transform:uppercase;cursor:pointer;white-space:nowrap}
.kc small{font-size:11px;color:var(--ink-2);letter-spacing:0}
.kc[aria-pressed="false"]{opacity:.5}
.kc[aria-pressed="false"] span{text-decoration:line-through}
.gl{width:12px;height:12px;flex:none;display:inline-block;vertical-align:-1px}
.cen-l .who b .gl{margin-right:7px}
.cen-k{color:var(--gold);letter-spacing:.18em;text-transform:uppercase;font-size:10.5px}
.cen-tabs{display:flex;flex-wrap:wrap;gap:6px;margin:14px 0 10px}
.cen-tabs button{min-height:44px;padding:0 13px;border:1px solid var(--rule);border-radius:999px;background:transparent;color:var(--ink);font-family:var(--f-mono);font-size:10.5px;letter-spacing:.1em;text-transform:uppercase;cursor:pointer}
.cen-tabs button small{color:var(--ink-2);letter-spacing:0;margin-left:3px}
.cen-tabs button[aria-selected="true"]{border-color:var(--gold);color:var(--gold)}
.cen-tabs button:disabled{opacity:.35;cursor:default}
.how,.lf{margin-top:16px;border-top:1px solid var(--rule)}
.how summary,.lf summary{min-height:44px;display:flex;align-items:center;cursor:pointer;font-family:var(--f-mono);font-size:11px;letter-spacing:.14em;text-transform:uppercase;color:var(--ink-2);list-style:none}
.how summary::-webkit-details-marker,.lf summary::-webkit-details-marker{display:none}
.how summary::after,.lf summary::after{content:'▾';margin-left:8px}
.how[open] summary::after,.lf[open] summary::after{content:'▴'}
.how-l{margin:2px 0 6px;padding-left:18px;color:var(--ink-2);font-size:15px;line-height:1.5}
.how-l li{margin:3px 0}
.lf-p{margin:10px 0 0;line-height:1.55}
.lf-h{margin-top:14px;color:var(--ink-2)}
.lf-d{margin:6px 0 0;padding-left:18px;line-height:1.5}
.lb.sn span{font-size:12.5px}
.lb.fam{font-weight:600}
body.timeline .cenl,body.timeline .keyrow{display:none}
@media (max-width:699px){body.timeline.exon:not(.srch) .tb{opacity:0;visibility:hidden}body.timeline.explore #srchBtn{display:inline-flex}}   /* W4: on a phone the timeline gets the search row back; Find opens it */
@media (max-width:699px){.ex-hint,#tools,#rail{display:none!important}}
/* W4/§3.4: a phone held sideways. Explore: the globe on the left, the controls and every sheet in a right-hand column. */
@media (orientation:landscape) and (max-height:500px) and (max-width:1100px){
  body.timeline .ex-ui{display:none!important}   /* W4: the timeline has its own zoom and drag; the explore stack leaves */
  body.timeline.exon:not(.srch) .tb{opacity:0;visibility:hidden}
  body.timeline.explore #srchBtn{display:inline-flex}
  .hud{padding-top:calc(env(safe-area-inset-top,0px) + 4px);padding-bottom:4px}
  body.exon:not(.timeline) .ex-ui{left:auto;right:0;width:clamp(300px,44vw,380px);max-width:none;margin:0;top:calc(env(safe-area-inset-top,0px) + 106px);bottom:0;align-content:end;overflow-y:auto;padding:6px max(12px,env(safe-area-inset-right,0px)) calc(8px + env(safe-area-inset-bottom,0px)) 8px}
  body.exon:not(.timeline) .ex-hint,body.exon:not(.timeline) #tools,body.exon:not(.timeline) #rail{display:none!important}
  body.exon:not(.timeline) .ex-bar{display:grid;grid-template-columns:1fr auto;gap:4px 8px}
  body.exon:not(.timeline) .yr-wrap{grid-column:1 / -1;grid-row:2}
  body.exon:not(.timeline) .coach{right:auto;width:calc(100% - clamp(300px,44vw,380px) - 32px)}
  body.exon:not(.timeline) .year{left:0;right:clamp(300px,44vw,380px);top:calc(env(safe-area-inset-top,0px) + 52px)}
  body.exon:not(.timeline) .year b{font-size:38px}
  body.exon .sheet,body.exon .pnl{left:auto;right:0;width:clamp(300px,44vw,380px);top:52px;max-height:none;border-radius:18px 0 0 0}
  body.exon:not(.timeline) .tb{left:auto;right:max(12px,env(safe-area-inset-right,0px));width:calc(clamp(300px,44vw,380px) - 20px);top:calc(env(safe-area-inset-top,0px) + 56px)}
  body.exon .sheet,body.exon .pnl{top:calc(env(safe-area-inset-top,0px) + 106px)}
  /* Layers sideways: the panel sat above the scrolling column and the column clipped all of it (0 of 20 toggles).
   * Fixed (#exUi has no transform, so this escapes its clip), in the same right-hand column, opaque, scrolling. */
  body.exon:not(.timeline) .lyrp{position:fixed;z-index:2;top:calc(env(safe-area-inset-top,0px) + 106px);right:0;bottom:0;width:clamp(300px,44vw,380px);max-height:none;overflow-y:auto;background:#0a0e1c}
}
body.timeline .coach{display:none}
/* On a phone the Globe | Timeline control floats just above the explore bar, which is where the open Layers legend
 * ends: it sat over "Apparitions" and took the tap. It steps aside while Layers is open and returns when it closes. */
@media (max-width:699px){body.lyr-on #viewToggle{visibility:hidden}}
/* stage 2 walks */
/* Explore only. Scoped to .hud .pill so it outranks `.hud .pill{display:inline-flex}` above: the bare .wk-pill rule lost,
 * the landing HUD carried a sixth pill, and at 360 / 412 the row ran under the app's back control and off the right edge. */
.hud .pill.wk-pill{display:none}
body.explore .hud .pill.wk-pill{display:inline-flex}
.wk-pill svg{width:16px;height:16px}
@media (max-width:400px){.wk-pill span{display:none}.wk-pill{width:44px;padding:0;justify-content:center}}
.wk-card{margin-top:14px;padding:14px;border:1px solid var(--rule);border-radius:14px;background:rgba(236,228,214,.03)}
.wk-t{margin:0 0 4px;font-family:var(--f-display);font-size:20px;line-height:1.2;color:var(--ink)}
.wk-k{color:var(--gold);letter-spacing:.16em;text-transform:uppercase;font-size:10.5px}
.wk-p{margin:6px 0 10px;color:var(--ink-2)}
.wk-bar{height:3px;margin:8px 0 2px;border-radius:2px;background:rgba(236,228,214,.14);overflow:hidden}
.wk-bar i{display:block;height:100%;background:var(--gold)}
.wk-go,.wk-mark{display:flex;width:100%;min-height:48px;margin-top:12px;justify-content:center;text-align:center;white-space:normal}
.wk-mark{border-color:var(--gold);color:var(--gold)}
.wk-done{margin:14px 0 0;font-family:var(--f-mono);font-size:12px;letter-spacing:.12em;text-transform:uppercase;color:var(--gold)}
.wk-nav{margin-top:16px}
.wk-tiles{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:14px}
.wk-tile{padding:10px 12px;border:1px solid var(--rule);border-radius:12px}
.wk-tile b{display:block;font-family:var(--f-display);font-size:28px;font-weight:400;line-height:1;color:var(--ink)}
.wk-tile span{display:block;margin-top:4px;font-size:10px;letter-spacing:.12em;text-transform:uppercase;color:var(--ink-2)}
.wk-tile small{display:block;margin-top:2px;font-size:12px;color:var(--ink-3)}
.wk-strip{display:grid;grid-template-columns:repeat(13,1fr);grid-auto-flow:column;grid-template-rows:repeat(7,auto);gap:4px;margin-top:8px;max-width:200px}
.wk-strip i{aspect-ratio:1}
.wk-strip i{border-radius:50%;background:rgba(236,228,214,.12)}
.wk-strip i.on{background:var(--gold)}
.wk-today{margin-top:16px;padding-top:4px;border-top:1px solid var(--rule)}
