/* ═══════════════════════════════════════════════════════════════════════
   ANCESTRAL WATCH — THE LAMPLIGHT READING ROOM  (/lamplight/, 11/11/2026)
   The first of the book worlds. A dark, warm room at night; one oil lamp
   gives the only light. The page is the lit circle of the lamp's glow, and
   the opening of The Amber and the Stone sits in that warm pool like a page
   on a table, its edges falling off into shadow.

   Firelight #dfb171 / #f4d998 from the home page's own palette; the rest is
   the dark of the room. The glow breathes with opacity and transform only:
   no blend modes, no filters, no backdrop blur (iPhone Safari is fragile).
   The read-along highlight here is lamplight: the sentence being read warms
   to full ink with a soft firelight halo; no box, no yellow.
   ═══════════════════════════════════════════════════════════════════════ */

@font-face{font-family:'Newsreader';font-style:normal;font-weight:400;font-display:swap;
  src:url('/assets/fonts/newsreader-latin.woff2?v=1') format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'Newsreader';font-style:normal;font-weight:400;font-display:swap;
  src:url('/assets/fonts/newsreader-latin-ext.woff2?v=1') format('woff2');unicode-range:U+0100-02AF,U+0304,U+0308,U+0329,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20CF,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:'Newsreader';font-style:italic;font-weight:400 500;font-display:swap;
  src:url('/assets/fonts/newsreader-italic-latin.woff2?v=1') format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'Newsreader';font-style:italic;font-weight:400 500;font-display:swap;
  src:url('/assets/fonts/newsreader-italic-latin-ext.woff2?v=1') format('woff2');unicode-range:U+0100-02AF,U+0304,U+0308,U+0329,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20CF,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:'Archivo';font-style:normal;font-weight:400 600;font-display:swap;
  src:url('/assets/fonts/archivo-text-latin.woff2?v=1') format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:'Archivo';font-style:normal;font-weight:400 600;font-display:swap;
  src:url('/assets/fonts/archivo-text-latin-ext.woff2?v=1') format('woff2');unicode-range:U+0100-02AF,U+0304,U+0308,U+0329,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20CF,U+2113,U+2C60-2C7F,U+A720-A7FF}

:root{
  --room:#0b0806;            /* the dark of the room */
  --room-2:#140e08;
  --fire:#dfb171;            /* firelight, from the home page */
  --fire-pale:#f4d998;
  --fire-deep:#b98340;
  --paper:#efe0c2;           /* the page on the table */
  --paper-edge:#c8b08a;
  --ink:#2a1a0e;             /* ink read in lamplight */
  --ink-shadow:#6e5a44;      /* ink still in shadow */
  --prose:'Newsreader',Georgia,'Times New Roman',serif;
  --ui:'Archivo',system-ui,-apple-system,'Segoe UI',sans-serif;
  --font-body:var(--ui);
  --font-display:var(--prose);
  --ease:cubic-bezier(.2,.7,.2,1);
}

*,*::before,*::after{box-sizing:border-box}
html.lamp-html{background:var(--room);color-scheme:dark;-webkit-text-size-adjust:100%;scroll-behavior:smooth}
body.lamp-body{margin:0;min-height:100vh;background:var(--room);color:#d8c7a5;font-family:var(--ui);line-height:1.5;
  overflow-x:hidden;-webkit-font-smoothing:antialiased}
body.lamp-body a{color:inherit}
.skip-link{position:absolute;left:-999px;top:8px;z-index:50;padding:.5rem .8rem;background:var(--fire-pale);color:var(--ink);border-radius:8px}
.skip-link:focus{left:8px}

/* ---------- the glow: three layers of lamplight, moved by the script with transform and opacity only ---------- */
.glow{position:fixed;inset:0;z-index:0;pointer-events:none;overflow:hidden}
.glow__l{position:absolute;left:0;top:0;border-radius:50%;will-change:transform,opacity;transform:translate(-50%,-50%)}
.glow__l--wide{width:230vmax;height:230vmax;margin:-115vmax 0 0 -115vmax;opacity:.5;
  background:radial-gradient(circle at 50% 50%,rgba(223,177,113,.30) 0%,rgba(190,140,80,.18) 16%,rgba(110,70,30,.10) 34%,rgba(40,24,10,.04) 50%,rgba(11,8,6,0) 64%)}
.glow__l--mid{width:120vmax;height:120vmax;margin:-60vmax 0 0 -60vmax;opacity:.7;
  background:radial-gradient(circle at 50% 50%,rgba(244,217,152,.42) 0%,rgba(223,177,113,.24) 16%,rgba(160,110,50,.10) 36%,rgba(11,8,6,0) 60%)}
.glow__l--core{width:52vmin;height:52vmin;margin:-26vmin 0 0 -26vmin;opacity:.9;
  background:radial-gradient(circle at 50% 50%,rgba(255,244,214,.55) 0%,rgba(244,217,152,.30) 22%,rgba(223,177,113,.10) 48%,rgba(11,8,6,0) 70%)}

/* a few motes drifting in the light */
.motes{position:absolute;inset:0}
.motes i{position:absolute;display:block;width:3px;height:3px;border-radius:50%;background:var(--fire-pale);opacity:0;
  left:var(--mx,50%);top:var(--my,40%);animation:lamp-mote var(--md,18s) linear infinite;animation-delay:var(--mdl,0s);will-change:transform,opacity}
.motes i:nth-child(1){--mx:44%;--my:52%;--md:19s;--mdl:-3s}
.motes i:nth-child(2){--mx:55%;--my:46%;--md:23s;--mdl:-11s;width:2px;height:2px}
.motes i:nth-child(3){--mx:38%;--my:40%;--md:27s;--mdl:-7s}
.motes i:nth-child(4){--mx:62%;--my:58%;--md:21s;--mdl:-15s;width:2px;height:2px}
.motes i:nth-child(5){--mx:50%;--my:62%;--md:25s;--mdl:-1s}
.motes i:nth-child(6){--mx:33%;--my:56%;--md:29s;--mdl:-19s;width:2px;height:2px}
.motes i:nth-child(7){--mx:67%;--my:44%;--md:24s;--mdl:-9s}
.motes i:nth-child(8){--mx:47%;--my:36%;--md:31s;--mdl:-23s;width:2px;height:2px}
.motes i:nth-child(9){--mx:58%;--my:66%;--md:22s;--mdl:-5s}
@keyframes lamp-mote{
  0%{transform:translate(0,0);opacity:0}
  12%{opacity:.55}
  50%{transform:translate(18px,-70px);opacity:.35}
  82%{opacity:.5}
  100%{transform:translate(-14px,-150px);opacity:0}
}
html.lamp-hidden .motes i{animation-play-state:paused}

/* ---------- the room ---------- */
.room__top{position:relative;z-index:3;display:flex;justify-content:space-between;align-items:baseline;gap:1rem;
  padding:max(14px,env(safe-area-inset-top)) clamp(16px,2.5vw,36px) 0;font-size:.78rem;letter-spacing:.14em;text-transform:uppercase}
.room__top a{text-decoration:none;color:rgba(216,199,165,.42);transition:color .3s ease}
.room__top a:hover,.room__top a:focus-visible{color:var(--fire-pale)}
.room__brand{font-weight:600;letter-spacing:.08em;text-transform:none;font-size:.95rem}
.room__brand span{color:rgba(223,177,113,.55)}
.room__back{letter-spacing:.1em;font-size:.72rem}
.room__top a:focus-visible,.room__out a:focus-visible,.room__toneBtn:focus-visible{outline:2px solid var(--fire);outline-offset:4px;border-radius:4px}

.room{position:relative;z-index:1;padding:0 16px max(32px,env(safe-area-inset-bottom))}
.room__table{display:grid;grid-template-columns:minmax(0,1fr);justify-items:center;gap:0;max-width:46rem;margin:0 auto}
.room__player,.room__out{width:100%}

/* the lamp */
.lamp-col{position:relative;z-index:1;width:100%;display:flex;justify-content:center}
.lamp-hold{position:relative;padding:clamp(1.2rem,4vh,3rem) 0 0}
.lamp{position:relative;display:block;margin:0;padding:0 .6rem;border:0;background:none;cursor:pointer;color:inherit;
  -webkit-tap-highlight-color:transparent;touch-action:manipulation;border-radius:999px}
.lamp:focus{outline:0}
.lamp:focus-visible .lamp__svg{outline:2px solid rgba(244,217,152,.7);outline-offset:14px;border-radius:50% 50% 40% 40%}
.lamp__svg{display:block;width:clamp(96px,22vw,128px);height:auto;overflow:visible}
.lamp__flame{transform-origin:80px 154px;will-change:transform}
.lamp__flameOuter{opacity:.9}
.lamp__hint{display:block;margin:.1rem auto 0;font-family:var(--prose);font-style:italic;font-size:1rem;letter-spacing:.02em;
  color:rgba(244,217,152,.62);transition:opacity 1.2s ease,transform 1.2s ease}
.lamp.is-up .lamp__hint,.lamp.was-up .lamp__hint{opacity:0;transform:translateY(4px)}
.lamp:hover .lamp__hint{color:var(--fire-pale)}

/* the page on the table: a page-shaped pool of paper whose edges are lost in shadow */
.page{position:relative;z-index:2;width:100%;max-width:44rem;margin:clamp(.6rem,2vh,1.6rem) auto 0;
  padding:clamp(3.2rem,4vw,3.8rem) clamp(1.85rem,6vw,4.2rem) clamp(3rem,4vw,3.6rem);
  color:var(--ink);font-family:var(--prose);
  --px:50%;--py:38%;--fx:34px;--fy:60px;
  background:var(--paper-edge) radial-gradient(ellipse 78% 72% at var(--px) var(--py),var(--paper) 0%,#e8d6b4 40%,var(--paper-edge) 74%,#b39c76 100%);
  box-shadow:inset 0 0 28px 6px rgba(30,18,8,.28);
  /* the edges of the page are lost in the dark of the room: the page fades out at its four sides (a soft gradient mask;
     where masks are not supported the page is simply a lit rectangle) */
  -webkit-mask-image:linear-gradient(90deg,rgba(0,0,0,0) 0,rgba(0,0,0,.55) calc(var(--fx) * .35),rgba(0,0,0,.9) calc(var(--fx) * .68),#000 var(--fx),#000 calc(100% - var(--fx)),rgba(0,0,0,.9) calc(100% - var(--fx) * .68),rgba(0,0,0,.55) calc(100% - var(--fx) * .35),rgba(0,0,0,0) 100%),
    linear-gradient(180deg,rgba(0,0,0,0) 0,rgba(0,0,0,.55) calc(var(--fy) * .35),rgba(0,0,0,.9) calc(var(--fy) * .68),#000 var(--fy),#000 calc(100% - var(--fy)),rgba(0,0,0,.9) calc(100% - var(--fy) * .68),rgba(0,0,0,.55) calc(100% - var(--fy) * .35),rgba(0,0,0,0) 100%);
  mask-image:linear-gradient(90deg,rgba(0,0,0,0) 0,rgba(0,0,0,.55) calc(var(--fx) * .35),rgba(0,0,0,.9) calc(var(--fx) * .68),#000 var(--fx),#000 calc(100% - var(--fx)),rgba(0,0,0,.9) calc(100% - var(--fx) * .68),rgba(0,0,0,.55) calc(100% - var(--fx) * .35),rgba(0,0,0,0) 100%),
    linear-gradient(180deg,rgba(0,0,0,0) 0,rgba(0,0,0,.55) calc(var(--fy) * .35),rgba(0,0,0,.9) calc(var(--fy) * .68),#000 var(--fy),#000 calc(100% - var(--fy)),rgba(0,0,0,.9) calc(100% - var(--fy) * .68),rgba(0,0,0,.55) calc(100% - var(--fy) * .35),rgba(0,0,0,0) 100%);
  -webkit-mask-composite:source-in;mask-composite:intersect}
.page__shade{position:absolute;inset:0;z-index:1;pointer-events:none;opacity:.7;will-change:opacity;
  background:radial-gradient(ellipse 82% 78% at var(--px) var(--py),rgba(11,8,6,0) 40%,rgba(11,8,6,.08) 62%,rgba(11,8,6,.24) 84%,rgba(11,8,6,.42) 100%)}
.page > *:not(.page__shade){position:relative;z-index:2}
.page__k{margin:0 0 1.4rem;font-family:var(--ui);font-size:.68rem;font-weight:600;letter-spacing:.26em;text-transform:uppercase;text-align:center;color:rgba(110,90,68,.85)}
.page__title{margin:0 0 1.9rem;font-family:var(--prose);font-weight:400;font-style:italic;text-align:center;
  font-size:clamp(1.65rem,1.3rem + 1.6vw,2.35rem);line-height:1.18;letter-spacing:-.01em;color:var(--ink);text-wrap:balance}
.page__voices blockquote{margin:0;padding:0;font-size:clamp(1.12rem,1.02rem + .5vw,1.3rem);line-height:1.66;text-wrap:pretty;hanging-punctuation:first}
.page__voices blockquote + blockquote{margin-top:1.55em}
.page__voices blockquote::first-letter{font-size:1.08em}
.page__voices cite{display:block;margin-top:.5em;font-style:italic;font-size:.9em;color:#5c4631;letter-spacing:.01em}
.page__from{margin:2.2rem 0 0;text-align:center;font-style:italic;font-size:.95rem;color:#6b5540}

/* ---------- the read-along, lit by lamplight ---------- */
.page .aw-ra .aw-ra__s,.page .aw-ra .aw-ra__w{border-radius:0;background:none!important;box-shadow:none!important;
  transition:color .7s ease,text-shadow .7s ease,opacity .7s ease}
.page .aw-ra.aw-ra--on .aw-ra__s{opacity:1;color:var(--ink-shadow);cursor:pointer}
.page .aw-ra.aw-ra--on .aw-ra__s.is-read{color:var(--ink)}
.page .aw-ra.aw-ra--on .aw-ra__s.is-current{color:#1e1106;
  text-shadow:0 0 .35em rgba(255,240,200,.95),0 0 .9em rgba(244,217,152,.7),0 0 1.8em rgba(223,177,113,.4)}
.page .aw-ra.aw-ra--on .aw-ra__s.is-current .aw-ra__w.is-word{color:#0f0703;
  text-shadow:0 0 .25em rgba(255,250,230,1),0 0 .6em rgba(255,236,190,1),0 0 1.2em rgba(244,217,152,.85),0 0 2em rgba(223,177,113,.5)}
.page .aw-ra .aw-ra__s--live:hover{background:none;color:var(--ink)}
.page .aw-ra .aw-ra__s:focus-visible{outline:1px dotted rgba(90,60,30,.7);outline-offset:.15em}
@media (hover:none){.page .aw-ra .aw-ra__s--live:hover{color:inherit}}

/* ---------- the player, quiet, beneath the page ---------- */
.room__player{position:relative;z-index:2;max-width:34rem;margin:clamp(1.4rem,3vh,2.4rem) auto 0}
.room__player .aw-listen{--al-ink:#e7d7b6;--al-soft:rgba(216,199,165,.6);--al-gold:var(--fire);--al-deep:var(--fire-pale);--al-paper:transparent;
  margin-top:0;padding:.6rem .4rem;background:transparent;border:0;box-shadow:none;color:var(--al-ink)}
.room__player .aw-listen .aw-listen__btn{width:46px;height:46px;background:rgba(223,177,113,.14);color:var(--fire-pale);
  box-shadow:inset 0 0 0 1px rgba(223,177,113,.5)}
.room__player .aw-listen .aw-listen__btn:hover{background:rgba(223,177,113,.3);color:#fff6dd}
.room__player .aw-listen .aw-listen__btn svg{width:20px;height:20px}
.room__player .aw-listen .aw-listen__k{color:rgba(244,217,152,.75)}
.room__player .aw-listen .aw-listen__bar::before{background:rgba(244,217,152,.16)}
.room__player .aw-listen .aw-listen__fill{background:var(--fire)}
.room__player .aw-listen .aw-listen__knob{background:var(--fire-pale);box-shadow:0 0 6px rgba(244,217,152,.6)}
.room__player .aw-listen .aw-listen__bar:focus-visible::before{box-shadow:0 0 0 2px rgba(244,217,152,.4)}
.room__player .aw-listen .aw-listen__btn:focus-visible{outline-color:var(--fire-pale)}
.room__player .aw-ra__ui{padding:0 .4rem;margin-top:.4rem}
.room__player .aw-ra__toggle{color:rgba(216,199,165,.6)}
.room__player .aw-ra__toggle[aria-checked="true"]{color:rgba(244,217,152,.85)}
.room__player .aw-ra__sw{background:rgba(216,199,165,.22)}
.room__player .aw-ra__toggle[aria-checked="true"] .aw-ra__sw{background:var(--fire-deep)}
.room__player .aw-ra__dot{background:#fff3d6}
.room__player .aw-ra__hint{color:rgba(216,199,165,.55)}
.room__player .aw-ra__toggle:focus-visible{outline-color:var(--fire)}

.room__tone{display:flex;align-items:center;flex-wrap:wrap;gap:.35rem 1rem;margin:.9rem 0 0;padding:0 .4rem;font-size:.8rem;line-height:1.3}
.room__toneBtn{display:inline-flex;align-items:center;gap:.55rem;margin:0;padding:.25rem .1rem;border:0;background:none;cursor:pointer;
  color:rgba(216,199,165,.6);font:inherit;font-weight:600;letter-spacing:.12em;text-transform:uppercase;line-height:1.2;-webkit-tap-highlight-color:transparent}
.room__toneDot{width:9px;height:9px;border-radius:50%;background:rgba(216,199,165,.22);box-shadow:inset 0 0 0 1px rgba(216,199,165,.3);transition:background .3s ease,box-shadow .3s ease}
.room__toneBtn[aria-pressed="true"]{color:rgba(244,217,152,.85)}
.room__toneBtn[aria-pressed="true"] .room__toneDot{background:var(--fire);box-shadow:0 0 8px rgba(244,217,152,.7)}
.room__toneState{letter-spacing:.08em;opacity:.8}
.room__toneHint{color:rgba(216,199,165,.5);font-size:.78rem}

/* ---------- out of the room ---------- */
.room__out{position:relative;z-index:2;max-width:34rem;margin:clamp(2.6rem,6vh,4.5rem) auto 0;padding:0 .4rem;text-align:center;font-family:var(--prose);
  font-size:1.05rem;line-height:1.6}
.room__out p{margin:.4rem 0}
.room__out a{text-decoration:none;color:rgba(216,199,165,.62);border-bottom:1px solid rgba(223,177,113,.25);padding-bottom:.08em;transition:color .3s ease,border-color .3s ease}
.room__out a:hover,.room__out a:focus-visible{color:var(--fire-pale);border-bottom-color:var(--fire)}
.room__out em{font-style:italic}
.room__foot{position:relative;z-index:2;display:flex;justify-content:space-between;gap:1rem;flex-wrap:wrap;max-width:46rem;margin:clamp(3rem,8vh,6rem) auto 0;
  font-size:.72rem;letter-spacing:.08em;color:rgba(216,199,165,.3)}

/* ---------- the table at laptop width: the lamp stands to the left of the page, as on the cover ---------- */
@media (min-width:1000px){
  .room{padding-left:clamp(16px,3vw,48px);padding-right:clamp(16px,3vw,48px)}
  .room__table{grid-template-columns:19rem minmax(0,44rem);justify-content:center;align-items:start;column-gap:clamp(1rem,3vw,3.5rem);max-width:none}
  .lamp-col{justify-content:flex-end;align-self:stretch}
  .lamp-hold{position:sticky;top:calc(50vh - 190px);padding:0;margin-top:clamp(3rem,8vh,6rem)}
  .lamp__svg{width:168px}
  .lamp__hint{font-size:1.08rem;text-align:center}
  .page{--px:44%;--py:36%;--fx:96px;--fy:80px;margin-top:clamp(2rem,6vh,4rem);padding:4.4rem 5.4rem 4rem;box-shadow:inset 0 0 70px 16px rgba(30,18,8,.32)}
  .page__voices blockquote{font-size:1.28rem;line-height:1.68}
  .room__player,.room__out{grid-column:2;width:100%;max-width:34rem;justify-self:center}
}
@media (min-width:1000px) and (max-width:1180px){
  .room__table{grid-template-columns:15rem minmax(0,40rem)}
}

/* the page may be read without motion: the lamp holds still and the motes rest */
@media (prefers-reduced-motion:reduce){
  html.lamp-html{scroll-behavior:auto}
  .motes{display:none}
  .page .aw-ra .aw-ra__s,.page .aw-ra .aw-ra__w,.lamp__hint{transition:none}
}

/* 11/11: the room reads Stone Breath, Chapter One — book prose on the lit page */
.page__prose p{margin:0;font-size:clamp(1.12rem,1.02rem + .5vw,1.3rem);line-height:1.66;text-wrap:pretty;hanging-punctuation:first}
.page__prose p + p{margin-top:1.05em;text-indent:0}
.page__prose .page__epi{font-style:italic;text-align:center;margin:0 0 1.6em}
.page__prose .page__sub{margin:2.1em 0 .9em;font-family:var(--prose);font-weight:400;font-style:italic;font-size:1.08em;text-align:center;letter-spacing:.02em}
@media (min-width:900px){.page__prose p{font-size:1.28rem;line-height:1.68}}
