/* Mission 1249: shared look of the narrated walk-throughs (Eros, Stages, ...). Scene pictures live in each page. */
:root{
  --gold:#c9962e; --gold-light:#e6c878; --cream:#f3ecdd;
  --dark:#0d0c0a; --dark2:#161410; --text:#e8e0d0; --muted:#9a8d76;
  --serif:'Cinzel', Georgia, serif; --sans:'Lato', sans-serif;
}
*{box-sizing:border-box;margin:0;padding:0;}
html,body{height:100%;}
body{background:var(--dark);color:var(--text);font-family:var(--sans);overflow:hidden;-webkit-tap-highlight-color:transparent;}

.stage{position:fixed;inset:0;overflow:hidden;background:radial-gradient(ellipse 80% 60% at 50% 40%, #1a150e 0%, var(--dark) 70%);}
.scene{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;
  padding:calc(env(safe-area-inset-top,0px) + 70px) 24px calc(env(safe-area-inset-bottom,0px) + 210px);
  text-align:center;opacity:0;visibility:hidden;transition:opacity 1.1s ease, visibility 0s linear 1.1s;}
.scene.on{opacity:1;visibility:visible;transition:opacity 1.1s ease, visibility 0s;}
[data-at]{opacity:0;transform:translateY(10px);transition:opacity .9s ease, transform .9s ease, color .6s, text-shadow .6s;}
[data-at].on{opacity:1;transform:none;}

.big{font-family:var(--serif);font-weight:700;color:var(--cream);line-height:1.05;letter-spacing:.03em;}
.line{font-family:var(--serif);font-size:clamp(19px,5.4vw,30px);color:var(--cream);line-height:1.3;margin:.35em 0;}
.line.gold{color:var(--gold-light);}
.line.dim{color:#b89a7a;}
.small{font-size:clamp(14px,3.8vw,17px);color:var(--muted);font-family:var(--sans);font-weight:300;line-height:1.6;}
.over{font-family:var(--serif);font-size:11px;letter-spacing:.28em;text-transform:uppercase;color:var(--gold);margin-bottom:1rem;}
.quote{font-family:var(--serif);font-size:clamp(20px,5.8vw,32px);color:var(--gold-light);line-height:1.3;font-style:normal;}
.quote::before{content:'“';}.quote::after{content:'”';}
svg{overflow:visible;}
.flame{width:86px;height:120px;margin-bottom:1.4rem;filter:drop-shadow(0 0 22px rgba(232,181,74,.55));animation:breathe 4s ease-in-out infinite;}
@keyframes breathe{50%{filter:drop-shadow(0 0 38px rgba(232,181,74,.85));transform:scale(1.04);}}
.title{font-size:clamp(54px,16vw,96px);}
.sub{font-family:var(--serif);font-size:clamp(16px,4.6vw,24px);color:var(--gold-light);letter-spacing:.14em;margin-top:.6rem;}
.end a{display:inline-block;margin:.5rem .3rem;padding:13px 22px;border:1px solid rgba(230,200,120,.5);border-radius:8px;color:var(--gold-light);
  text-decoration:none;font-family:var(--serif);font-size:13px;letter-spacing:.12em;text-transform:uppercase;background:rgba(201,150,46,.12);}

/* top: Library and Chapters */
.top{position:fixed;left:0;right:0;top:0;padding:calc(env(safe-area-inset-top,0px) + 12px) 12px 8px;display:flex;justify-content:space-between;align-items:center;z-index:11;}
.top a{color:var(--gold);text-decoration:none;font-family:var(--serif);font-size:16px;font-weight:600;letter-spacing:.04em;padding:10px 12px 10px 4px;}
.chbtn{max-width:58vw;display:flex;align-items:center;gap:8px;min-height:40px;padding:8px 14px;border-radius:999px;border:1px solid rgba(230,200,120,.4);
  background:rgba(13,12,10,.7);color:var(--gold-light);font-family:var(--serif);font-size:12px;letter-spacing:.08em;cursor:pointer;}
.chbtn span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.chbtn i{flex:none;width:12px;height:2px;background:currentColor;box-shadow:0 -4px 0 currentColor,0 4px 0 currentColor;}
.chlist{position:fixed;right:12px;top:calc(env(safe-area-inset-top,0px) + 62px);z-index:12;width:min(86vw,340px);max-height:62vh;overflow:auto;
  background:#14110c;border:1px solid #3a2f1e;border-radius:14px;padding:6px;box-shadow:0 20px 50px rgba(0,0,0,.6);}
.chlist[hidden]{display:none;}
.ch{display:flex;align-items:center;gap:10px;width:100%;min-height:48px;padding:8px 10px;border:0;border-radius:10px;background:none;color:var(--text);
  text-align:left;cursor:pointer;font-family:var(--sans);font-size:15px;}
.ch small{flex:none;width:1.4em;color:var(--muted);font-size:11px;text-align:right;}
.ch span{flex:1;}
.ch em{flex:none;font-style:normal;font-size:12px;color:var(--muted);font-variant-numeric:tabular-nums;}
.ch.on{background:rgba(201,150,46,.16);color:var(--gold-light);}

/* caption and controls */
.cap{position:fixed;left:0;right:0;bottom:calc(env(safe-area-inset-bottom,0px) + 118px);padding:0 22px;text-align:center;
  font-size:clamp(14px,3.9vw,17px);line-height:1.55;color:var(--text);font-weight:300;min-height:3.2em;text-shadow:0 1px 8px #000;}
.bar{position:fixed;left:0;right:0;bottom:0;padding:10px 16px calc(env(safe-area-inset-bottom,0px) + 12px);z-index:5;
  background:linear-gradient(to top,rgba(13,12,10,.97) 60%,rgba(13,12,10,0));}
.row{display:flex;align-items:center;gap:12px;}
.row + .row{justify-content:center;gap:18px;margin-top:8px;}
.seek{flex:1;-webkit-appearance:none;appearance:none;height:4px;border-radius:2px;background:#3a2f1e;outline:none;}
.seek::-webkit-slider-thumb{-webkit-appearance:none;width:18px;height:18px;border-radius:50%;background:var(--gold-light);}
.seek::-moz-range-thumb{width:18px;height:18px;border-radius:50%;background:var(--gold-light);border:0;}
.tm{flex:none;font-size:12px;color:var(--muted);font-variant-numeric:tabular-nums;min-width:74px;text-align:right;}
.pp{flex:none;width:56px;height:56px;border-radius:50%;border:0;cursor:pointer;background:linear-gradient(135deg,#f3d58a,#c9962e 55%,#a87a22);
  display:flex;align-items:center;justify-content:center;}
.pp i{width:0;height:0;border-style:solid;border-width:9px 0 9px 15px;border-color:transparent transparent transparent #1a1308;margin-left:4px;}
.pp.on i{width:14px;height:17px;border:none;margin:0;background:linear-gradient(to right,#1a1308 0 5px,transparent 5px 9px,#1a1308 9px 14px);}
.spd{min-width:86px;min-height:40px;padding:8px 12px;border-radius:999px;border:1px solid rgba(230,200,120,.35);background:none;color:var(--gold-light);
  font-family:var(--serif);font-size:12px;letter-spacing:.08em;cursor:pointer;}
.spd:disabled{opacity:.35;cursor:default;}
.rate{min-width:44px;border:0;background:none;color:var(--muted);font-size:13px;font-variant-numeric:tabular-nums;cursor:pointer;}

.start{position:fixed;inset:0;z-index:10;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1.4rem;
  background:radial-gradient(ellipse 70% 60% at 50% 45%, #21190e 0%, var(--dark) 75%);text-align:center;padding:24px;}
.start[hidden]{display:none;}
.start button{width:96px;height:96px;border-radius:50%;border:0;cursor:pointer;background:linear-gradient(135deg,#f3d58a,#c9962e 55%,#a87a22);
  display:flex;align-items:center;justify-content:center;box-shadow:0 0 40px rgba(232,181,74,.45);}
.start button i{width:0;height:0;border-style:solid;border-width:16px 0 16px 26px;border-color:transparent transparent transparent #1a1308;margin-left:6px;}
.start a{color:var(--muted);font-size:14px;}
/* Next (Nov 29): the card between one teaching and the next, the same look as the start card */
.nextcard{position:fixed;inset:0;z-index:12;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:.9rem;
  background:radial-gradient(ellipse 70% 60% at 50% 45%, #21190e 0%, var(--dark) 75%);text-align:center;padding:24px;}
.nextcard[hidden]{display:none;}
.nextcard .nc-t{font-size:clamp(40px,11vw,64px);}
.nextcard .nc-s{margin-top:-.3rem;}
.nextcard .nc-in{margin-top:.6rem;font-variant-numeric:tabular-nums;}
.nextcard .nc-b{display:flex;gap:12px;margin-top:.4rem;}
@media (prefers-reduced-motion: reduce){ *{animation:none!important;transition:none!important;} }

/* Each scene's contents sit in one box (added by walk.js) that is scaled to fit the space between the top bar and
   the caption, so nothing runs under the controls on a short screen. */
.sc-in{display:flex;flex-direction:column;align-items:center;width:100%;transform-origin:50% 50%;}

/* A phone turned sideways (Nov 22): the controls fold into one slim row, the caption sits just above it, and the
   scene gets the rest of the height. walk.js then sizes each scene to fill that space. */
@media (orientation:landscape) and (max-height:540px){
  .top{padding:calc(env(safe-area-inset-top,0px) + 6px) max(12px,env(safe-area-inset-right)) 4px max(12px,env(safe-area-inset-left));}
  .top a{font-size:14px;padding:6px 10px 6px 2px;}
  .chbtn{min-height:34px;padding:6px 12px;font-size:11px;}
  .chlist{top:calc(env(safe-area-inset-top,0px) + 46px);max-height:72vh;}
  .scene{padding:calc(env(safe-area-inset-top,0px) + 48px) max(28px,env(safe-area-inset-right)) calc(env(safe-area-inset-bottom,0px) + 104px) max(28px,env(safe-area-inset-left));}
  .bar{display:flex;align-items:center;gap:14px;padding:4px max(16px,env(safe-area-inset-right)) calc(env(safe-area-inset-bottom,0px) + 6px) max(16px,env(safe-area-inset-left));
    background:linear-gradient(to top,rgba(13,12,10,.97) 70%,rgba(13,12,10,0));}
  .bar .row{margin:0;}
  .bar .row:first-child{flex:1;order:2;}
  .bar .row + .row{gap:10px;order:1;}
  .bar .row:last-child{order:3;}
  .pp{width:42px;height:42px;}
  .pp i{border-width:7px 0 7px 12px;margin-left:3px;}
  .pp.on i{width:12px;height:14px;background:linear-gradient(to right,#1a1308 0 4px,transparent 4px 8px,#1a1308 8px 12px);}
  .spd{min-width:70px;min-height:34px;padding:6px 10px;font-size:11px;}
  .cap{bottom:calc(env(safe-area-inset-bottom,0px) + 54px);font-size:14px;line-height:1.4;min-height:0;padding:0 max(40px,env(safe-area-inset-left));}
}
