/* ==========================================================
   Dalgadan Sayıya: görsel sistem
   "Skala camı": derin petrol cihaz paneli, fildişi skala baskısı,
   kırmızı ayar ibresi. Renk bir sözlüktür:
   I = gök mavisi, Q = kehribar, genlik = fildişi, faz = nane,
   gürültü = kırçıl gri, ibre = kırmızı.
   ========================================================== */

:root {
  --bg: #0e1a1f;          /* cihaz paneli */
  --bg-deep: #0a1418;
  --stage: #13242a;       /* skala camı */
  --panel: #1a2f36;       /* düğme yüzeyi */
  --line: #26404a;        /* panel çizgisi */
  --line-2: #345661;
  --ink: #efe9dc;         /* kadran fildişisi */
  --ink-2: #a7b3b0;
  --muted: #6f8384;

  --i: #4dbbff;           /* I: gerçek bileşen */
  --q: #ffb23f;           /* Q: sanal bileşen */
  --amp: #efe9dc;         /* genlik */
  --phase: #8ce0b0;       /* faz */
  --noise: #7f8c96;       /* gürültü */
  --needle: #ff4a3d;      /* ayar ibresi */
  --brass: #d9b46a;       /* pirinç: rehber halkası, "Dene" kutusu */

  --f-display: "Big Shoulders Display", "Arial Narrow", sans-serif;
  --f-body: "Atkinson Hyperlegible Next", "Atkinson Hyperlegible", system-ui, sans-serif;

  --r-sm: 5px;
  --r-md: 10px;
  --gutter: clamp(16px, 3.2vw, 48px);
  --bar-h: 68px;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: clamp(15px, 0.7vw + 6.5px, 18px);
  line-height: 1.58;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}
/* panelin hafif dokusu: çok ince yatay fırçalama çizgileri */
body::before {
  content: "";
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background:
    radial-gradient(90% 70% at 70% 40%, rgba(77, 187, 255, 0.045), transparent 70%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.012) 0 1px, transparent 1px 3px);
}

button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; border-radius: 3px; }
.tnum, output, .val { font-variant-numeric: tabular-nums; }

/* ---------- Slayt kabı ---------- */
#deck { position: fixed; inset: 0 0 var(--bar-h) 0; z-index: 1; }
.slide {
  position: absolute; inset: 0;
  display: grid;
  grid-template-columns: minmax(300px, 0.74fr) 1.26fr;
  gap: clamp(20px, 3vw, 52px);
  padding: clamp(22px, 4.2vh, 52px) var(--gutter) clamp(14px, 2.6vh, 28px);
  opacity: 0; visibility: hidden;
  transition: opacity 0.4s ease, transform 0.5s cubic-bezier(.2,.7,.2,1), visibility 0s linear 0.5s;
  transform: translateX(24px);
}
.slide.before { transform: translateX(-24px); }
.slide.active {
  opacity: 1; visibility: visible; transform: none;
  transition: opacity 0.4s ease, transform 0.5s cubic-bezier(.2,.7,.2,1), visibility 0s;
}
.slide.wide { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
.slide.center { grid-template-columns: 1fr; place-items: center; text-align: center; }

body.text-hidden .slide:not(.center) { grid-template-columns: 0 1fr; gap: 0; }
body.text-hidden .slide:not(.center) .text { display: none; }

/* ---------- Metin sütunu ---------- */
.text {
  overflow-y: auto;
  padding-right: 10px;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
  max-width: 60ch;
  align-self: start;
  max-height: 100%;
}
/* bölüm etiketi: radyodaki bant seçme tuşu gibi */
.chapter-tag {
  font-family: var(--f-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  color: var(--ink-2);
  margin: 0 0 0.7rem;
  display: flex; align-items: center; gap: 0.6em;
}
.chapter-tag b {
  display: inline-grid; place-items: center;
  min-width: 1.9em; height: 1.5em; padding: 0 0.3em;
  border-radius: 3px;
  background: var(--ink); color: var(--bg);
  font-weight: 800; font-size: 0.9em;
}
h1, h2, h3 { font-family: var(--f-display); font-weight: 800; line-height: 0.98; margin: 0 0 0.9rem; letter-spacing: 0.005em; }
h1 { font-size: clamp(3.4rem, 8vw, 8.4rem); font-weight: 900; line-height: 0.88; }
h2 { font-size: clamp(2.3rem, 3.7vw, 3.9rem); }
h3 { font-size: 1.3rem; font-weight: 700; margin: 1.4rem 0 0.4rem; }
.text p { margin: 0 0 0.9em; color: var(--ink-2); }
.text p.lead { color: var(--ink); font-size: 1.1em; line-height: 1.5; }
.text strong { color: var(--ink); font-weight: 700; }
.text em { color: var(--ink); }
.text ul, .text ol { padding-left: 1.15em; margin: 0 0 1em; color: var(--ink-2); }
.text li { margin-bottom: 0.35em; }
.text li::marker { color: var(--muted); }
.text a { color: var(--ink); text-decoration-color: var(--muted); text-underline-offset: 3px; }
.text a:hover { text-decoration-color: var(--ink); }
.text code, .text .mono { font-variant-numeric: tabular-nums; background: rgba(255,255,255,.05); padding: 0 .3em; border-radius: 3px; }

/* renk dili: metin içinde de aynı */
.ci { color: var(--i); font-weight: 700; }
.cq { color: var(--q); font-weight: 700; }
.camp { color: var(--amp); font-weight: 700; }
.cph { color: var(--phase); font-weight: 700; }
.cn { color: var(--noise); font-weight: 700; }
.cr { color: var(--needle); font-weight: 700; }

/* "Daha fazla": formüller ve ayrıntı */
details.more {
  margin: 1.1rem 0 0.6rem;
  border-left: 2px solid var(--line-2);
  padding: 0.15rem 0 0.15rem 1rem;
}
details.more summary {
  cursor: pointer;
  font-family: var(--f-display); font-weight: 700; font-size: 1.05rem;
  color: var(--ink);
  list-style: none;
}
details.more summary::-webkit-details-marker { display: none; }
details.more summary::before { content: "+"; display: inline-block; width: 1em; color: var(--muted); }
details.more[open] summary::before { content: "−"; }
details.more p, details.more ul { margin-top: 0.6rem; font-size: 0.95em; }
.formula {
  display: block; margin: 0.5rem 0 0.8rem; padding: 0.5rem 0.8rem;
  background: rgba(0,0,0,.18); border-radius: var(--r-sm);
  font-variant-numeric: tabular-nums; color: var(--ink); white-space: nowrap; overflow-x: auto;
}

/* "Dene" kutusu */
.try {
  margin-top: 1.1rem;
  padding: 0.7rem 1rem;
  border-radius: var(--r-sm);
  background: rgba(217, 180, 106, 0.07);
  border: 1px solid rgba(217, 180, 106, 0.3);
  color: var(--ink);
  font-size: 0.95em;
}
.try::before { content: "Dene: "; font-family: var(--f-display); font-weight: 800; font-size: 1.08em; color: var(--brass); }

aside.notes { display: none; }

/* ---------- Sahne: skala camı ---------- */
.stage {
  position: relative;
  min-height: 0; min-width: 0;
  border-radius: var(--r-md);
  background:
    linear-gradient(180deg, rgba(255,255,255,0.035), transparent 22%),
    var(--stage);
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), inset 0 0 40px rgba(0,0,0,0.25), 0 18px 50px rgba(0,0,0,0.25);
  overflow: hidden;
  display: flex; flex-direction: column;
}
.stage.bare { background: transparent; border: 0; box-shadow: none; }
.stage canvas { display: block; }
.stage .fill { flex: 1; min-height: 0; position: relative; }
.stage .fill > canvas, .stage .fill > svg { position: absolute; inset: 0; width: 100%; height: 100%; }

.controls {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: 10px 18px;
  padding: 11px 16px;
  border-top: 1px solid var(--line);
  background: rgba(10, 20, 24, 0.55);
  font-size: 0.9rem;
}
.controls.top { border-top: 0; border-bottom: 1px solid var(--line); }
.controls .spacer { flex: 1; }
.controls label, .controls .lab { color: var(--ink-2); }
label.sl { display: inline-flex; align-items: center; gap: 9px; }

.btn {
  font-family: var(--f-body); font-weight: 700; font-size: 0.88rem;
  padding: 0.45em 1em;
  border-radius: var(--r-sm);
  border: 1px solid var(--line-2);
  background: var(--panel);
  color: var(--ink);
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
  white-space: nowrap;
}
.btn:hover { border-color: var(--ink-2); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.btn.primary:hover { background: #fff; }
.btn.on { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.btn:disabled { opacity: 0.4; cursor: default; }
.btn.ghost { background: rgba(14, 26, 31, 0.6); }
.btn.big { font-size: 1.02rem; padding: 0.75em 1.35em; display: inline-flex; align-items: center; gap: 0.55em; }
.btn.big svg { width: 1.2em; height: 1.2em; }

/* bant seçici: eski radyolardaki yan yana basmalı tuşlar */
.seg { display: inline-flex; border: 1px solid var(--line-2); border-radius: var(--r-sm); background: var(--bg-deep); padding: 2px; gap: 2px; }
.seg button {
  border: 0; background: transparent; padding: 0.32em 0.8em; border-radius: 3px; cursor: pointer;
  font-weight: 700; font-size: 0.84rem; color: var(--ink-2);
}
.seg button:hover { color: var(--ink); }
.seg button.on { background: var(--ink); color: var(--bg); }

/* aç/kapa düğmesi */
.tog {
  display: inline-flex; align-items: center; gap: 0.5em;
  border: 1px solid var(--line-2); background: var(--bg-deep); color: var(--ink-2);
  border-radius: var(--r-sm); padding: 0.32em 0.8em 0.32em 0.6em; cursor: pointer; font-weight: 700; font-size: 0.84rem;
}
.tog::before { content: ""; width: 0.6em; height: 0.6em; border-radius: 50%; background: var(--line-2); transition: background .15s, box-shadow .15s; }
.tog[aria-pressed="true"] { color: var(--ink); border-color: var(--ink-2); }
.tog[aria-pressed="true"]::before { background: var(--needle); box-shadow: 0 0 8px var(--needle); }
.tog.ci[aria-pressed="true"]::before { background: var(--i); box-shadow: 0 0 8px var(--i); }
.tog.cq[aria-pressed="true"]::before { background: var(--q); box-shadow: 0 0 8px var(--q); }

/* kaydırıcı: fildişi ayar düğmesi */
input[type="range"] {
  -webkit-appearance: none; appearance: none;
  width: 140px; height: 24px; background: transparent; cursor: pointer;
}
input[type="range"]::-webkit-slider-runnable-track { height: 3px; border-radius: 2px; background: var(--line-2); }
input[type="range"]::-moz-range-track { height: 3px; border-radius: 2px; background: var(--line-2); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%;
  background: var(--ink); margin-top: -6.5px; border: 3px solid var(--bg-deep);
  box-shadow: 0 0 0 1px var(--ink-2);
}
input[type="range"]::-moz-range-thumb { width: 12px; height: 12px; border-radius: 50%; background: var(--ink); border: 3px solid var(--bg-deep); box-shadow: 0 0 0 1px var(--ink-2); }
/* renkli kaydırıcılar: seçici özgüllüğü genel kuralı yenmeli */
input[type="range"].ci::-webkit-slider-thumb { background: var(--i); box-shadow: 0 0 0 1px var(--i); }
input[type="range"].cq::-webkit-slider-thumb { background: var(--q); box-shadow: 0 0 0 1px var(--q); }
input[type="range"].cn::-webkit-slider-thumb { background: var(--noise); box-shadow: 0 0 0 1px var(--noise); }
input[type="range"].cph::-webkit-slider-thumb { background: var(--phase); box-shadow: 0 0 0 1px var(--phase); }
input[type="range"].cr::-webkit-slider-thumb { background: var(--needle); box-shadow: 0 0 0 1px var(--needle); }
input[type="range"].ci::-moz-range-thumb { background: var(--i); }
input[type="range"].cq::-moz-range-thumb { background: var(--q); }
input[type="range"].cn::-moz-range-thumb { background: var(--noise); }
input[type="range"].cph::-moz-range-thumb { background: var(--phase); }
input[type="range"].cr::-moz-range-thumb { background: var(--needle); }
.val { font-size: 0.86rem; color: var(--ink); min-width: 4.2em; display: inline-block; font-weight: 700; }

/* ---------- Alt çubuk: radyo kadranı ---------- */
#bar {
  position: fixed; left: 0; right: 0; bottom: 0; height: var(--bar-h);
  display: flex; align-items: center; gap: 14px;
  padding: 0 var(--gutter);
  z-index: 5;
  font-size: 0.86rem;
  color: var(--ink-2);
  background: linear-gradient(180deg, transparent, rgba(10, 20, 24, 0.7) 35%);
}
#bar .chapter-name { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 0 1 210px; font-family: var(--f-display); font-weight: 600; font-size: 1rem; }
#bar .chapter-name b { color: var(--ink); font-weight: 800; }
#progress {
  position: relative;
  flex: 1; min-width: 0;
  display: flex; gap: 0; align-items: stretch;
  height: 44px;
  padding: 0 10px;
  border-radius: 6px;
  background: linear-gradient(180deg, #16292f, #0f1e23);
  border: 1px solid var(--line);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05), inset 0 -8px 16px rgba(0,0,0,0.25);
  overflow-x: auto; overflow-y: hidden;
  scrollbar-width: none;
}
#progress::-webkit-scrollbar { display: none; }
#progress .ch {
  display: flex; flex-direction: column; justify-content: flex-start;
  flex: var(--n) 1 0; min-width: max(calc(var(--n) * 12px), 3.4em);
  border-left: 1px solid rgba(239, 233, 220, 0.12);
  padding: 0 4px;
}
#progress .ch:first-of-type { border-left: 0; }
#progress .ticks { display: flex; height: 22px; align-items: flex-start; }
#progress .dot {
  flex: 1; height: 100%; min-width: 8px; border: 0; padding: 0; cursor: pointer; background: transparent; position: relative;
}
#progress .dot::after {
  content: ""; position: absolute; left: 50%; top: 0; width: 1px; height: 9px; background: rgba(239, 233, 220, 0.35);
  transition: background .2s, height .2s;
}
#progress .dot:first-child::after { height: 14px; background: rgba(239, 233, 220, 0.55); }
#progress .dot.seen::after { background: var(--ink); }
#progress .dot:hover::after { height: 16px; background: var(--ink); }
#progress .band {
  font-family: var(--f-display); font-weight: 700; font-size: 0.82rem; letter-spacing: 0.03em;
  color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; line-height: 1; padding-top: 1px;
}
#dial-needle {
  position: absolute; left: 0; top: 0; bottom: 0; width: 0; pointer-events: none;
  transition: transform 0.55s cubic-bezier(.3,.8,.25,1);
}
#dial-needle::before {
  content: ""; position: absolute; left: -1px; top: 2px; bottom: 2px; width: 2px; border-radius: 1px;
  background: var(--needle); box-shadow: 0 0 10px rgba(255, 74, 61, 0.65);
}
#bar .counter { font-variant-numeric: tabular-nums; font-size: 0.85rem; min-width: 4.4em; text-align: right; color: var(--ink); font-weight: 700; }
.iconbtn {
  width: 38px; height: 38px; flex: none; display: inline-grid; place-items: center;
  border-radius: 50%; border: 1px solid var(--line-2); background: var(--panel); cursor: pointer; color: var(--ink);
}
.iconbtn:hover { border-color: var(--ink-2); }
.iconbtn svg { width: 18px; height: 18px; }
.iconbtn.on { border-color: var(--ink); background: var(--ink); color: var(--bg); }
#sound-slot { display: inline-flex; align-items: center; gap: 6px; }
#vol { width: 70px; }

/* ---------- Notlar paneli ---------- */
#notes {
  position: fixed; right: var(--gutter); bottom: calc(var(--bar-h) + 10px);
  width: min(460px, calc(100vw - 32px)); max-height: 45vh; overflow: auto;
  background: var(--ink); color: #1b2326;
  border-radius: var(--r-md);
  padding: 16px 20px;
  font-size: 1rem; line-height: 1.5;
  z-index: 6;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
  display: none;
}
#notes.open { display: block; }
#notes h4 { margin: 0 0 6px; font-family: var(--f-display); font-weight: 800; font-size: 1rem; color: #8a2a20; }
#notes ul { margin: 0; padding-left: 1.1em; }

/* ---------- Genel bakış ---------- */
#overview {
  position: fixed; inset: 0; z-index: 8;
  background: rgba(10, 20, 24, 0.97);
  overflow: auto;
  padding: 40px var(--gutter) 60px;
  display: none;
}
#overview.open { display: block; }
#overview h2 { font-size: 2.4rem; margin-bottom: 1.4rem; }
#overview .ov-ch { margin-bottom: 26px; }
#overview .ov-ch h3 { margin: 0 0 10px; color: var(--ink-2); font-size: 1.2rem; }
#overview .ov-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 6px; }
#overview .ov-item {
  text-align: left; padding: 9px 14px; border-radius: var(--r-sm);
  border: 1px solid var(--line); background: var(--stage); cursor: pointer;
  font-size: 0.92rem; color: var(--ink);
  display: flex; gap: 10px;
}
#overview .ov-item:hover { border-color: var(--ink-2); }
#overview .ov-item span { color: var(--muted); font-variant-numeric: tabular-nums; font-size: 0.82rem; padding-top: 1px; min-width: 1.4em; }
#overview .ov-item.cur { border-color: var(--needle); }
#overview .keys { color: var(--ink-2); font-size: 0.92rem; margin-top: 24px; }
kbd {
  font-family: var(--f-body); font-size: 0.8em; font-weight: 700; border: 1px solid var(--line-2); border-bottom-width: 2px;
  border-radius: 4px; padding: 0 6px; background: var(--panel); color: var(--ink);
}

/* ---------- Kapak ---------- */
.cover { padding: 0; }
.cover .stage canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.cover .stage { position: absolute; inset: 0; border-radius: 0; }
.cover .cover-text {
  position: relative; z-index: 2; pointer-events: none;
  text-align: left; align-self: end; justify-self: start;
  padding: 0 var(--gutter) 6vh;
  max-width: 1100px;
}
.cover .cover-text > * { pointer-events: auto; }
.cover h1 { margin-bottom: 1.1rem; text-shadow: 0 6px 50px rgba(10, 20, 24, 0.95); }
.cover .sub { font-size: 1.25rem; color: var(--ink); max-width: 44ch; margin: 0 0 0.6rem; text-shadow: 0 2px 20px rgba(10,20,24,.9); }
.cover p { font-size: 1.05rem; color: var(--ink-2); max-width: 50ch; margin: 0 0 1.4rem; text-shadow: 0 2px 20px rgba(10,20,24,.9); }
.cover .byline { font-family: var(--f-display); font-weight: 700; font-size: 1.3rem; color: var(--ink); margin-bottom: 1.4rem; letter-spacing: 0.02em; }
.cover-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 1.2rem; }
.cover .hint { font-size: 0.9rem; color: var(--muted); }

/* ---------- Duyarlı ---------- */
@media (max-width: 860px) {
  :root { --bar-h: 62px; }
  body { overflow: auto; }
  #deck { position: relative; inset: auto; }
  .slide {
    position: relative; inset: auto; display: none;
    grid-template-columns: 1fr !important; grid-auto-rows: auto;
    padding: 22px 16px 100px; transform: none !important;
  }
  .slide.active { display: grid; }
  .text { max-height: none; overflow: visible; padding-right: 0; }
  .stage { min-height: 72vh; }
  .cover { min-height: calc(100svh - var(--bar-h)); }
  .cover .cover-text { padding-bottom: 4vh; }
  #bar { gap: 8px; background: var(--bg); border-top: 1px solid var(--line); padding: 0 10px; }
  #bar .chapter-name, #vol, #bar .counter { display: none; }
  #bar #btn-text, #bar #btn-notes { display: none; }
  .iconbtn { width: 34px; height: 34px; }
  #progress { height: 40px; }
  body.text-hidden .slide .text { display: block; }
}

@media (prefers-reduced-motion: reduce) {
  .slide, .slide.active { transition: opacity 0.2s; transform: none; }
  #dial-needle { transition: none; }
}

/* ---------- Sözlük balonları ---------- */
.term {
  color: inherit;
  text-decoration: underline dotted rgba(239, 233, 220, 0.55);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
  cursor: help;
  border-radius: 2px;
}
.term:hover, .term:focus-visible { background: rgba(239, 233, 220, 0.09); text-decoration-color: var(--ink); outline: none; }
#gloss {
  position: fixed; z-index: 20;
  width: min(330px, calc(100vw - 24px));
  padding: 12px 14px;
  background: #1c343c;
  border: 1px solid var(--line-2);
  border-top: 2px solid var(--ink);
  border-radius: var(--r-sm);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
  font-size: 0.9rem; line-height: 1.45; color: var(--ink-2);
  opacity: 0; transform: translateY(4px); pointer-events: none;
  transition: opacity .15s, transform .15s;
}
#gloss.open { opacity: 1; transform: none; pointer-events: auto; }
#gloss h4 { margin: 0 0 4px; font-family: var(--f-display); font-weight: 800; font-size: 1.15rem; color: var(--ink); }
#gloss p { margin: 0 0 8px; }
#gloss a { font-weight: 700; font-size: 0.82rem; color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--muted); }
#gloss a:hover { border-bottom-color: var(--ink); }

/* ---------- Sesli anlatım çubuğu ---------- */
#narrator {
  position: fixed; left: 50%; bottom: calc(var(--bar-h) + 8px); z-index: 7;
  transform: translate(-50%, 12px);
  width: min(640px, calc(100vw - 32px));
  display: flex; align-items: center; gap: 12px;
  padding: 7px 10px 7px 7px;
  background: rgba(26, 47, 54, 0.95);
  border: 1px solid var(--line-2);
  border-radius: 999px;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(8px);
  font-size: 0.82rem; color: var(--ink-2);
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
#narrator.open { opacity: 1; pointer-events: auto; transform: translate(-50%, 0); }
.np-play {
  width: 36px; height: 36px; flex: none; border-radius: 50%; border: 0; cursor: pointer;
  background: var(--ink); color: var(--bg); display: grid; place-items: center;
}
.np-play svg { width: 18px; height: 18px; }
.np-track { flex: 1; min-width: 60px; height: 6px; border-radius: 3px; background: var(--line); cursor: pointer; position: relative; }
.np-track i { position: absolute; left: 0; top: 0; bottom: 0; width: 0; border-radius: 3px; background: var(--ink); }
.np-time { font-variant-numeric: tabular-nums; font-size: 0.78rem; color: var(--ink); white-space: nowrap; }
.np-auto { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; cursor: pointer; }
.np-auto input { accent-color: var(--ink); }
.np-status:empty { display: none; }
.np-status { color: var(--ink); white-space: nowrap; }
.np-close { border: 0; background: transparent; color: var(--muted); font-size: 1.3rem; line-height: 1; cursor: pointer; padding: 0 6px; }
.np-close:hover { color: var(--ink); }
@media (max-width: 860px) {
  #narrator { border-radius: var(--r-md); flex-wrap: wrap; }
  .np-auto { order: 5; }
}
body.narrating #deck { bottom: calc(var(--bar-h) + 58px); transition: bottom .2s; }
@media (max-width: 860px) { body.narrating #deck { bottom: auto; padding-bottom: 90px; } }

/* ---------- "Sesi açmak için dokunun" ---------- */
#sound-hint {
  position: fixed; left: 50%; top: 18px; z-index: 35;
  transform: translate(-50%, -12px);
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px 8px 12px; border-radius: 999px;
  background: var(--ink); color: var(--bg); border: 0; cursor: pointer;
  font-weight: 700; font-size: 0.92rem;
  box-shadow: 0 10px 30px rgba(0,0,0,.45);
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
#sound-hint svg { width: 18px; height: 18px; display: block; }
#sound-hint.on { opacity: 1; pointer-events: auto; transform: translate(-50%, 0); }

/* ---------- Deney rehberi ---------- */
#ghost-hand {
  position: fixed; left: 0; top: 0; z-index: 30; width: 34px; height: 34px;
  pointer-events: none; opacity: 0; transition: opacity .25s;
  filter: drop-shadow(0 4px 10px rgba(0,0,0,.5));
}
#ghost-hand svg { width: 100%; height: 100%; transition: transform .12s; transform-origin: 34% 12%; }
#ghost-hand.on { opacity: .95; }
#ghost-hand.down svg { transform: scale(.86); }
.ghost-ripple {
  position: fixed; z-index: 29; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%;
  border: 2px solid var(--brass); pointer-events: none; animation: ghostRipple .6s ease-out forwards;
}
@keyframes ghostRipple { to { transform: scale(3.6); opacity: 0; } }
#guide-ring { position: fixed; z-index: 6; pointer-events: none; border: 2px solid var(--brass); opacity: 0; }
#guide-ring.on { animation: guidePulse 1.3s ease-out 3; }
#guide-ring.on.still { animation: none; opacity: 1; box-shadow: 0 0 0 4px rgba(217,180,106,.18), 0 0 22px rgba(217,180,106,.35); }
@keyframes guidePulse {
  0% { opacity: 1; box-shadow: 0 0 0 0 rgba(217,180,106,.55); }
  70% { opacity: .9; box-shadow: 0 0 0 14px rgba(217,180,106,0); }
  100% { opacity: 0; box-shadow: 0 0 0 14px rgba(217,180,106,0); }
}
.try.try-live { cursor: pointer; position: relative; padding-right: 96px; transition: background .2s, border-color .2s; }
.try.try-live:hover, .try.try-live:focus-visible { background: rgba(217,180,106,.13); border-color: rgba(217,180,106,.65); outline: none; }
.try-cta {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  display: inline-flex; align-items: center; gap: 6px;
  font-weight: 700; font-size: 0.8rem; color: #1d1608;
  background: var(--brass); border-radius: 3px; padding: 4px 11px 4px 9px;
}
.try-cta::before { content: ""; width: 0; height: 0; border-left: 7px solid #1d1608; border-top: 5px solid transparent; border-bottom: 5px solid transparent; }
#guide-toast {
  position: fixed; left: 50%; top: 22px; transform: translate(-50%, -10px); z-index: 40;
  background: var(--panel); border: 1px solid var(--line-2); border-radius: 999px; padding: 8px 16px;
  font-size: .88rem; color: var(--ink);
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
#guide-toast.on { opacity: 1; transform: translate(-50%, 0); }
@media (prefers-reduced-motion: reduce) { #guide-ring.on { animation: none; opacity: 1; } }
