/* =========================================================================
   ZOE'S ALIEN ENCOUNTER — atmosphere.css
   Mood: night, forest, fog, flashlight, lo-fi goth, synthwave
   Palette: black / deep blue / violet / turquoise / neon green
   ========================================================================= */

:root {
  --black:      #04050a;
  --ink:        #07090f;
  --night:      #0a0f1f;
  --blue-deep:  #0b1733;
  --blue:       #14274e;
  --violet-dk:  #1c1238;
  --violet:     #3a2168;
  --violet-lt:  #9b6bff;
  --teal:       #16e0cf;
  --teal-dim:   #0e8f86;
  --neon:       #5dff9b;
  --pink:       #ff6ad5;
  --amber:      #ffb15c;

  --text:       #c3cbe0;
  --text-dim:   #6f7a96;
  --text-faint: #3c455e;
  --glow-teal:  0 0 18px rgba(22,224,207,.55), 0 0 42px rgba(22,224,207,.28);
  --glow-violet:0 0 18px rgba(155,107,255,.5), 0 0 46px rgba(155,107,255,.25);

  --font-narr:  "Spectral", Georgia, serif;
  --font-ui:    "Space Grotesk", system-ui, sans-serif;
  --font-mono:  "JetBrains Mono", ui-monospace, monospace;

  --ease: cubic-bezier(.4, 0, .15, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  background: var(--black);
  color: var(--text);
  font-family: var(--font-ui);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ---- Stage (full-viewport responsive) ------------------------------------ */
#stage {
  position: fixed;
  inset: 0;
  overflow: hidden;
  cursor: none;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
}
#stage.show-cursor { cursor: default; }

.scene {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 1.1s var(--ease);
}
.scene.active {
  opacity: 1;
  pointer-events: auto;
}

/* world layer sits behind UI/flashlight */
.world { position: absolute; inset: 0; }

/* =========================================================================
   STARFIELD
   ========================================================================= */
.starfield { position: absolute; inset: -10%; }
.star {
  position: absolute;
  width: 2px; height: 2px;
  border-radius: 50%;
  background: #cfe6ff;
  opacity: .0;
  animation: twinkle 5s ease-in-out infinite;
}
@keyframes twinkle {
  0%,100% { opacity: .15; }
  50%     { opacity: .9; }
}

/* =========================================================================
   FOG
   ========================================================================= */
.fog {
  position: absolute;
  inset: -20% -40%;
  background:
    radial-gradient(60% 40% at 20% 70%, rgba(58,33,104,.30), transparent 70%),
    radial-gradient(50% 40% at 80% 60%, rgba(20,39,78,.35), transparent 70%),
    radial-gradient(70% 50% at 50% 90%, rgba(22,224,207,.06), transparent 70%);
  filter: blur(8px);
  animation: drift 38s ease-in-out infinite alternate;
}
@keyframes drift {
  from { transform: translate3d(-3%, 0, 0) scale(1.05); }
  to   { transform: translate3d(4%, -2%, 0) scale(1.12); }
}

/* =========================================================================
   FLASHLIGHT
   The dark overlay; a soft hole follows the pointer.
   ========================================================================= */
.darkness {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    circle var(--beam, 190px) at var(--mx, 50%) var(--my, 60%),
    rgba(0,0,0,0) 0%,
    rgba(2,3,8,.05) 30%,
    rgba(2,3,8,.55) 58%,
    rgba(2,3,8,.92) 78%,
    rgba(2,3,8,.99) 100%
  );
  transition: background .08s linear;
}
/* warm tint of the beam itself */
.beam-glow {
  position: absolute;
  width: 460px; height: 460px;
  left: 0; top: 0;
  margin: -230px 0 0 -230px;
  transform: translate(var(--mxpx,0), var(--mypx,0));
  pointer-events: none;
  background: radial-gradient(circle, rgba(180,210,255,.10), rgba(120,170,255,.04) 40%, transparent 68%);
  mix-blend-mode: screen;
  transition: transform .05s linear;
}

/* =========================================================================
   TREES (stylised pine silhouettes)
   ========================================================================= */
.tree {
  position: absolute;
  bottom: 0;
  background: linear-gradient(180deg, #060912, #02030700);
  clip-path: polygon(50% 0, 64% 28%, 57% 28%, 70% 52%, 60% 52%, 76% 78%, 50% 78%, 24% 78%, 40% 52%, 30% 52%, 43% 28%, 36% 28%);
  opacity: .96;
}
.tree::after {
  content: "";
  position: absolute;
  left: 47%; bottom: 0;
  width: 6%; height: 24%;
  background: #04060d;
}

/* =========================================================================
   NARRATIVE TEXT
   ========================================================================= */
.narr {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  text-align: center;
  padding: 8vw;
  pointer-events: none;
}
.narr p {
  font-family: var(--font-narr);
  font-weight: 300;
  font-size: clamp(20px, 3.1vw, 40px);
  line-height: 1.5;
  color: var(--text);
  letter-spacing: .01em;
  max-width: 22ch;
  opacity: 0;
  filter: blur(6px);
  transform: translateY(8px);
  text-wrap: balance;
}
.narr p.in {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0);
  transition: opacity 2.4s var(--ease), filter 2.4s var(--ease), transform 2.4s var(--ease);
}
.narr p.dim { color: var(--text-dim); }
.narr p.teal { color: var(--teal); text-shadow: var(--glow-teal); }
.narr p.violet { color: var(--violet-lt); text-shadow: var(--glow-violet); }

/* =========================================================================
   CHAPTER LABEL
   ========================================================================= */
.chapter-tag {
  position: absolute;
  top: 7vh; left: 50%;
  transform: translateX(-50%);
  text-align: center;
  pointer-events: none;
  opacity: 0;
  animation: tagIn 2s var(--ease) .3s forwards;
}
.chapter-tag .k {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .42em;
  text-transform: uppercase;
  color: var(--teal);
  opacity: .8;
}
.chapter-tag .t {
  margin-top: 10px;
  font-family: var(--font-narr);
  font-weight: 300;
  font-size: clamp(26px, 3.4vw, 44px);
  color: var(--text);
}
@keyframes tagIn {
  from { opacity: 0; transform: translate(-50%, -10px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}
.chapter-tag.fade-out { animation: tagOut 1.4s var(--ease) forwards; }
@keyframes tagOut { to { opacity: 0; } }

/* =========================================================================
   FINDS (discoverable items in the dark)
   ========================================================================= */
.find {
  position: absolute;
  width: 60px; height: 60px;
  display: grid;
  place-items: center;
  font-size: 34px;
  transform: translate(-50%, -50%) scale(.9);
  filter: grayscale(.3) brightness(.5);
  transition: filter .4s var(--ease), transform .4s var(--ease);
  cursor: pointer;
  pointer-events: auto;
  user-select: none;
}
.find.near {
  filter: grayscale(0) brightness(1.15) drop-shadow(0 0 14px rgba(150,200,255,.5));
  transform: translate(-50%, -50%) scale(1.05);
}
.find.found {
  filter: grayscale(0) brightness(1.2) drop-shadow(0 0 16px rgba(22,224,207,.6));
}
.find .ring {
  position: absolute; inset: -10px;
  border: 1px solid rgba(22,224,207,.0);
  border-radius: 50%;
  transition: border-color .4s;
}
.find.near .ring { border-color: rgba(22,224,207,.35); }

/* caption that appears when a find is read */
.caption {
  position: absolute;
  left: 50%; bottom: 11vh;
  transform: translateX(-50%) translateY(14px);
  width: min(560px, 84vw);
  text-align: center;
  font-family: var(--font-narr);
  font-weight: 300;
  font-size: clamp(18px, 2.2vw, 27px);
  line-height: 1.55;
  color: var(--text);
  opacity: 0;
  pointer-events: none;
  transition: opacity .7s var(--ease), transform .7s var(--ease);
  text-wrap: balance;
}
.caption.in { opacity: 1; transform: translateX(-50%) translateY(0); }
.caption .em { color: var(--teal); }

/* small counter of finds */
.find-counter {
  position: absolute;
  bottom: 9vh; left: 50%;
  transform: translateX(-50%);
  display: flex; gap: 10px;
  pointer-events: none;
}
.find-counter .pip {
  width: 8px; height: 8px; border-radius: 50%;
  border: 1px solid var(--text-faint);
  transition: background .5s, border-color .5s, box-shadow .5s;
}
.find-counter .pip.on {
  background: var(--teal); border-color: var(--teal);
  box-shadow: var(--glow-teal);
}

/* =========================================================================
   SOCIAL BATTERY (Kapitel 2)
   ========================================================================= */
.social-battery {
  position: absolute;
  top: 5vh; left: 4vw;
  width: 220px;
  font-family: var(--font-mono);
  pointer-events: none;
  z-index: 5;
}
.social-battery .label {
  font-size: 11px; letter-spacing: .28em; text-transform: uppercase;
  color: var(--text-dim); margin-bottom: 8px;
}
.social-battery .cell {
  position: relative;
  height: 16px;
  border: 1px solid rgba(155,107,255,.5);
  border-radius: 3px;
  overflow: hidden;
  background: rgba(10,15,31,.6);
}
.social-battery .fill {
  position: absolute; inset: 0; right: 0;
  width: 100%;
  background: linear-gradient(90deg, var(--teal), var(--neon));
  transition: width .9s var(--ease), background .9s var(--ease);
  transform-origin: left;
}
.social-battery.low .fill { background: linear-gradient(90deg, var(--amber), var(--pink)); }
.social-battery.crit .fill { background: linear-gradient(90deg, #ff4d6d, var(--pink)); }
.social-battery .pct {
  margin-top: 7px; font-size: 12px; color: var(--text-dim); letter-spacing: .1em;
}
.battery-shake { animation: shake .4s; }
@keyframes shake {
  0%,100% { transform: translateX(0); }
  25% { transform: translateX(-4px); } 75% { transform: translateX(4px); }
}

/* floating energy-loss number */
.energy-pop {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 700;
  color: var(--pink);
  text-shadow: 0 0 12px rgba(255,106,213,.7);
  pointer-events: none;
  animation: popUp 1.3s var(--ease) forwards;
}
@keyframes popUp {
  from { opacity: 0; transform: translateY(6px) scale(.9); }
  20%  { opacity: 1; }
  to   { opacity: 0; transform: translateY(-40px) scale(1.05); }
}

/* =========================================================================
   SILHOUETTES (people)
   ========================================================================= */
.silhouette {
  position: absolute;
  bottom: -2%;
  width: 110px; height: 320px;
  background: linear-gradient(180deg, #0d1326, #060912);
  clip-path: polygon(38% 0, 62% 0, 66% 14%, 60% 22%, 70% 40%, 66% 100%, 34% 100%, 30% 40%, 40% 22%, 34% 14%);
  filter: blur(1px);
  opacity: .85;
  transition: transform .8s var(--ease), opacity .8s;
}
.silhouette::before { /* head */
  content: "";
  position: absolute;
  top: -6%; left: 50%;
  width: 38%; aspect-ratio: 1;
  transform: translateX(-50%);
  background: #0d1326;
  border-radius: 50%;
}

/* speech bubble for people / NPCs */
.speech {
  position: absolute;
  padding: 14px 18px;
  max-width: 280px;
  background: rgba(10,15,31,.86);
  border: 1px solid rgba(155,107,255,.4);
  border-radius: 14px;
  font-family: var(--font-ui);
  font-size: clamp(15px, 1.6vw, 19px);
  line-height: 1.4;
  color: var(--text);
  backdrop-filter: blur(6px);
  box-shadow: 0 10px 40px rgba(0,0,0,.6);
  opacity: 0; transform: translateY(8px) scale(.98);
  transition: opacity .5s var(--ease), transform .5s var(--ease);
}
.speech.in { opacity: 1; transform: translateY(0) scale(1); }

/* =========================================================================
   FESTIVAL
   ========================================================================= */
.string-lights {
  position: absolute; top: 0; left: -5%; right: -5%; height: 30%;
  pointer-events: none;
}
.bulb {
  position: absolute;
  width: 9px; height: 9px; border-radius: 50%;
  animation: bulbPulse 3s ease-in-out infinite;
}
@keyframes bulbPulse { 0%,100% { opacity: .55; } 50% { opacity: 1; } }

.campfire {
  position: absolute;
  width: 90px; height: 90px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,177,92,.9), rgba(255,106,80,.5) 40%, transparent 70%);
  filter: blur(2px);
  animation: flicker 1.4s ease-in-out infinite;
}
@keyframes flicker { 0%,100% { transform: scale(1); opacity: .9; } 50% { transform: scale(1.08); opacity: 1; } }

/* =========================================================================
   UFO
   ========================================================================= */
.ufo-wrap {
  position: absolute;
  left: 50%; top: 38%;
  transform: translate(-50%, -50%);
  animation: hover 6s ease-in-out infinite;
}
@keyframes hover { 0%,100% { transform: translate(-50%, -50%); } 50% { transform: translate(-50%, calc(-50% - 14px)); } }
.ufo {
  position: relative;
  width: 300px; height: 110px;
}
.ufo .dome {
  position: absolute; left: 50%; top: -32px;
  width: 130px; height: 90px;
  transform: translateX(-50%);
  border-radius: 50% 50% 45% 45%;
  background: radial-gradient(120% 120% at 40% 25%, rgba(93,255,155,.55), rgba(22,224,207,.35) 45%, rgba(11,23,51,.7));
  border: 1px solid rgba(93,255,155,.5);
  box-shadow: inset 0 0 30px rgba(93,255,155,.35);
}
.ufo .body {
  position: absolute; left: 50%; top: 30px;
  width: 300px; height: 64px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(80% 120% at 50% 18%, #1b3a52, #0b1733 60%, #07101f);
  border: 1px solid rgba(22,224,207,.45);
  box-shadow: var(--glow-teal), inset 0 -8px 24px rgba(0,0,0,.6);
}
.ufo .lights { position: absolute; left: 50%; top: 52px; transform: translateX(-50%); display: flex; gap: 18px; }
.ufo .lights i {
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--teal);
  box-shadow: var(--glow-teal);
  animation: ufoLight 2s ease-in-out infinite;
}
.ufo .lights i:nth-child(2){ animation-delay: .25s; background: var(--neon); box-shadow: 0 0 14px var(--neon); }
.ufo .lights i:nth-child(3){ animation-delay: .5s; }
.ufo .lights i:nth-child(4){ animation-delay: .75s; background: var(--neon); box-shadow: 0 0 14px var(--neon); }
.ufo .lights i:nth-child(5){ animation-delay: 1s; }
@keyframes ufoLight { 0%,100% { opacity: .4; transform: scale(.85); } 50% { opacity: 1; transform: scale(1.1); } }

.ufo-beam {
  position: absolute; left: 50%; top: 86px;
  width: 220px; height: 460px;
  transform: translateX(-50%);
  background: linear-gradient(180deg, rgba(93,255,155,.28), rgba(22,224,207,.10) 40%, transparent 80%);
  clip-path: polygon(38% 0, 62% 0, 100% 100%, 0 100%);
  filter: blur(3px);
  animation: beamPulse 4s ease-in-out infinite;
  pointer-events: none;
}
@keyframes beamPulse { 0%,100% { opacity: .5; } 50% { opacity: .85; } }

/* =========================================================================
   EARTH (observatory)
   ========================================================================= */
.earth {
  position: absolute;
  width: 120px; height: 120px;
  border-radius: 50%;
  background:
    radial-gradient(80% 80% at 30% 30%, #2a6fb0, #123a66 55%, #07142b),
    #0a1d3a;
  box-shadow: 0 0 40px rgba(42,111,176,.5), inset -10px -8px 30px rgba(0,0,0,.7);
  overflow: hidden;
}
.earth::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(12px 8px at 30% 40%, rgba(45,160,120,.7), transparent 70%),
    radial-gradient(16px 10px at 60% 55%, rgba(45,160,120,.6), transparent 70%),
    radial-gradient(10px 7px at 48% 25%, rgba(45,160,120,.55), transparent 70%);
}
.earth::after { /* atmosphere rim */
  content: "";
  position: absolute; inset: -3px;
  border-radius: 50%;
  box-shadow: inset 0 0 18px rgba(120,200,255,.5);
}

/* =========================================================================
   DIALOGUE / CHOICES (shared panel)
   ========================================================================= */
.dialog {
  position: absolute;
  left: 50%; bottom: 8vh;
  transform: translateX(-50%);
  width: min(680px, 88vw);
  display: flex; flex-direction: column; align-items: center;
  gap: 18px;
  z-index: 8;
}
.dialog .line {
  font-family: var(--font-narr);
  font-weight: 300;
  font-size: clamp(19px, 2.3vw, 28px);
  line-height: 1.5;
  text-align: center;
  color: var(--text);
  text-wrap: balance;
  opacity: 0; transform: translateY(8px);
  transition: opacity 1s var(--ease), transform 1s var(--ease);
}
.dialog .line.in { opacity: 1; transform: translateY(0); }
.dialog .line.mono { font-family: var(--font-mono); font-size: clamp(15px,1.7vw,20px); color: var(--teal); }

.choices { display: flex; flex-direction: column; gap: 10px; width: 100%; align-items: center; }
.choice {
  font-family: var(--font-ui);
  font-size: clamp(15px, 1.7vw, 20px);
  color: var(--text);
  background: rgba(10,15,31,.5);
  border: 1px solid rgba(155,107,255,.35);
  border-radius: 999px;
  padding: 12px 26px;
  cursor: pointer;
  pointer-events: auto;
  opacity: 0; transform: translateY(10px);
  transition: opacity .6s var(--ease), transform .6s var(--ease), background .25s, border-color .25s, color .25s;
  backdrop-filter: blur(6px);
}
.choice.in { opacity: 1; transform: translateY(0); }
.choice:hover {
  background: rgba(22,224,207,.12);
  border-color: var(--teal);
  color: #eafffb;
  box-shadow: var(--glow-teal);
}
.choice.chosen {
  background: rgba(22,224,207,.18);
  border-color: var(--teal);
  color: #eafffb;
}
.choice.muted { opacity: .25; pointer-events: none; }

/* =========================================================================
   PROMPTS / HINTS
   ========================================================================= */
.hint {
  position: absolute;
  left: 50%; bottom: 4vh;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 12px; letter-spacing: .22em; text-transform: uppercase;
  color: var(--text-dim);
  pointer-events: none;
  opacity: 0;
  animation: hintIn 1.2s var(--ease) forwards, hintPulse 3s ease-in-out 1.2s infinite;
}
@keyframes hintIn { to { opacity: .8; } }
@keyframes hintPulse { 0%,100% { opacity: .35; } 50% { opacity: .85; } }

.next-btn {
  position: absolute;
  left: 50%; bottom: 5vh;
  transform: translateX(-50%);
  font-family: var(--font-ui);
  font-size: 16px;
  letter-spacing: .08em;
  color: var(--teal);
  background: rgba(10,15,31,.5);
  border: 1px solid var(--teal);
  border-radius: 999px;
  padding: 13px 34px;
  cursor: pointer;
  pointer-events: auto;
  opacity: 0;
  transition: opacity .8s var(--ease), background .25s, box-shadow .25s, transform .25s;
  backdrop-filter: blur(6px);
  z-index: 9;
}
.next-btn.in { opacity: 1; }
.next-btn:hover { background: rgba(22,224,207,.14); box-shadow: var(--glow-teal); transform: translateX(-50%) translateY(-2px); }

/* =========================================================================
   START + UI CHROME
   ========================================================================= */
#title-screen {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  background: radial-gradient(120% 90% at 50% 30%, #0a1124, #04050a 70%);
  z-index: 30;
  transition: opacity 1.4s var(--ease);
  gap: 22px;
  padding: 8vw;
}
#title-screen.gone { opacity: 0; pointer-events: none; }
#title-screen .eyebrow {
  font-family: var(--font-mono);
  font-size: 12px; letter-spacing: .5em; text-transform: uppercase;
  color: var(--teal); opacity: .85;
}
#title-screen h1 {
  font-family: var(--font-narr);
  font-weight: 300;
  font-size: clamp(40px, 7.5vw, 96px);
  line-height: 1.02;
  letter-spacing: -.01em;
  color: #eef2ff;
  text-shadow: 0 0 30px rgba(22,224,207,.25);
}
#title-screen h1 span { display: block; }
#title-screen h1 .alien {
  color: var(--teal);
  text-shadow: var(--glow-teal);
}
#title-screen .sub {
  font-family: var(--font-ui);
  font-size: clamp(14px, 1.8vw, 19px);
  color: var(--text-dim);
  max-width: 30ch;
  line-height: 1.6;
}
#title-screen .meta {
  display: flex; gap: 22px; flex-wrap: wrap; justify-content: center;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .2em;
  text-transform: uppercase; color: var(--text-faint);
}
.start-btn {
  margin-top: 6px;
  font-family: var(--font-ui);
  font-size: 17px; letter-spacing: .06em;
  color: #04050a;
  background: var(--teal);
  border: none;
  border-radius: 999px;
  padding: 15px 44px;
  cursor: pointer;
  box-shadow: var(--glow-teal);
  transition: transform .25s, box-shadow .25s, background .25s;
}
.start-btn:hover { transform: translateY(-2px); box-shadow: 0 0 30px rgba(22,224,207,.8); }
.from-line {
  font-family: var(--font-narr); font-style: italic;
  font-size: clamp(13px,1.5vw,16px); color: var(--text-faint);
}

/* top-right controls */
#chrome {
  position: fixed; top: 18px; right: 18px;
  display: flex; gap: 10px; z-index: 40;
}
.ctrl {
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(155,107,255,.3);
  background: rgba(7,9,15,.6);
  color: var(--text-dim);
  cursor: pointer;
  backdrop-filter: blur(6px);
  transition: color .25s, border-color .25s, background .25s;
  font-family: var(--font-mono); font-size: 15px;
}
.ctrl:hover { color: var(--teal); border-color: var(--teal); }
.ctrl.on { color: var(--teal); border-color: var(--teal); }

/* progress dots bottom-right */
#progress {
  position: fixed; bottom: 18px; right: 18px;
  display: flex; gap: 7px; z-index: 40;
}
#progress .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--text-faint);
  transition: background .4s, box-shadow .4s, transform .4s;
}
#progress .dot.active { background: var(--teal); box-shadow: var(--glow-teal); transform: scale(1.3); }
#progress .dot.done { background: var(--violet-lt); }

/* vignette overlay always on top of world */
.vignette {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(120% 100% at 50% 50%, transparent 55%, rgba(2,3,8,.75) 100%);
  z-index: 6;
}

/* grain */
.grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 50;
  opacity: .04; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .001ms !important; animation-iteration-count: 1 !important; }
}

/* =========================================================================
   MOBILE / TOUCH  (phones, narrow + short screens)
   ========================================================================= */
@media (max-width: 760px) {
  /* on touch the flashlight follows the finger; cursor irrelevant */
  #stage.flashlight { cursor: none; }

  .ufo { transform: scale(.6); }
  .ufo-wrap { top: 32%; }

  .social-battery { width: 150px; top: 2.5vh; left: 5vw; }
  .social-battery .label { font-size: 10px; letter-spacing: .2em; }

  .speech { max-width: 74vw; font-size: 16px; padding: 12px 14px; }

  .narr p { font-size: clamp(20px, 6vw, 30px); max-width: 18ch; }
  .narr { padding: 12vw 7vw; }

  .dialog { width: 92vw; gap: 14px; }
  .dialog .line { font-size: clamp(18px, 5vw, 24px); }
  .dialog .line.mono { font-size: clamp(14px, 4.2vw, 18px); }
  .choice { width: 100%; padding: 14px 20px; font-size: 17px; }

  .chapter-tag { top: 6vh; }
  .chapter-tag .t { font-size: clamp(24px, 7vw, 36px); }
  .chapter-tag .k { font-size: 10px; letter-spacing: .32em; }

  .caption { font-size: clamp(17px, 4.8vw, 22px); width: 88vw; }
  .find { width: 66px; height: 66px; font-size: 38px; }

  .next-btn, .start-btn { padding: 14px 30px; font-size: 16px; }
  #title-screen .sub { font-size: 15px; }
  #title-screen .meta { gap: 12px; font-size: 10px; }

  #chrome { top: 12px; right: 12px; }
  .ctrl { width: 44px; height: 44px; }
  #progress { bottom: 12px; right: 12px; }
}

/* very short landscape phones — keep the UFO from eating the dialog */
@media (max-height: 480px) {
  .ufo-wrap { top: 28%; }
  .ufo { transform: scale(.5); }
  .chapter-tag { top: 3vh; }
  .chapter-tag .t { font-size: 22px; }
  .narr p { font-size: clamp(18px, 4vw, 26px); }
  .dialog { bottom: 4vh !important; gap: 8px; }
  .dialog .line { font-size: 17px; }
}
