/* =========================================================
   LJUDSKO TIJELO — stilovi
   ========================================================= */
:root {
  --ink: #eaf6ff;
  --muted: rgba(226, 240, 255, .7);
  --faint: rgba(226, 240, 255, .44);
  --line: rgba(255, 255, 255, .13);
  --glass: rgba(6, 18, 36, .5);
  --glass-strong: rgba(4, 12, 26, .88);
  --acc: #6fe3ff;
  --zc: #b69cff;
  --padL: 132px;
  --colW: 390px;
  --fd: 'Fraunces', Georgia, 'Times New Roman', serif;
  --fu: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --fm: 'JetBrains Mono', ui-monospace, Consolas, monospace;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: auto; }
html, body { margin: 0; padding: 0; }
body {
  background: #030b18; color: var(--ink); font-family: var(--fu);
  overflow-x: hidden; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent;
}
button { font: inherit; color: inherit; }
a { color: var(--acc); }
kbd { font: 600 11px var(--fm); padding: 2px 6px; border-radius: 6px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .22); }

/* ---------- slojevi ---------- */
#gl { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; display: block; touch-action: pan-y; cursor: grab; }
#gl.drag { cursor: grabbing; }
#gl.hov { cursor: pointer; }
#vignette { position: fixed; inset: 0; z-index: 1; pointer-events: none; background: radial-gradient(ellipse at 50% 50%, transparent 55%, rgba(0, 3, 10, .45)); }
#leads { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 4; pointer-events: none; overflow: visible; }
#leads path { fill: none; stroke: rgba(210, 238, 255, .42); stroke-width: 1; }
#leads path.f { stroke: var(--lc, #fff); stroke-width: 1.4; }
#pins { position: fixed; inset: 0; z-index: 5; pointer-events: none; }
#flash { position: fixed; inset: 0; z-index: 40; pointer-events: none; opacity: 0; background: radial-gradient(circle at 50% 50%, rgba(120, 220, 255, .2), rgba(0, 4, 12, .96) 70%); }
#flash.go { animation: flash .7s ease-out; }
@keyframes flash { 0% { opacity: .95; } 100% { opacity: 0; } }
.no-gl #gl { display: none; }
.no-gl body, body.no-gl { background: radial-gradient(ellipse at 60% 40%, #0b2a4a, #030b18 70%) fixed; }

#loader {
  position: fixed; inset: 0; z-index: 90; display: grid; place-content: center; justify-items: center; gap: 16px;
  background: radial-gradient(ellipse at 50% 42%, #0c2d4d, #030b18 70%); color: #cfeaff;
  font: 600 12.5px var(--fm); letter-spacing: .2em; text-transform: uppercase;
  transition: opacity 1s ease, visibility 1s;
}
#loader.done { opacity: 0; visibility: hidden; }
#loader p { margin: 0; min-height: 1.2em; }
.ld-ecg svg { width: 220px; height: 60px; overflow: visible; }
.ld-ecg path { fill: none; stroke: #ff5a6e; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 60 300; animation: ecgRun 1.6s linear infinite; filter: drop-shadow(0 0 6px #ff5a6e); }
@keyframes ecgRun { from { stroke-dashoffset: 360; } to { stroke-dashoffset: 0; } }
.ld-bar { width: 220px; height: 3px; border-radius: 2px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.ld-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #6fe3ff, #ff5a6e); transition: width .3s; }

/* ---------- uvod ---------- */
#hero {
  position: relative; z-index: 12; height: 100vh; height: 100svh; min-height: 560px;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
  text-align: center; padding: 10vh 20px 0; pointer-events: none;
}
.hero-inner { max-width: 900px; pointer-events: auto; }
.kicker { font: 700 12px/1 var(--fm); letter-spacing: .24em; text-transform: uppercase; margin: 0 0 14px; color: rgba(160, 225, 255, .8); }
.title {
  font-family: var(--fd); font-weight: 900; letter-spacing: -.035em;
  font-size: clamp(58px, 12vw, 172px); line-height: .86; margin: 0; font-variation-settings: 'opsz' 144;
  color: #f4fbff; text-shadow: 0 4px 40px rgba(0, 20, 40, .6), 0 0 60px rgba(111, 227, 255, .18);
}
.title .t1 { display: inline-block; animation: tfloat 6s ease-in-out infinite; }
.title .t2 { display: inline-block; font-style: italic; font-weight: 700; color: #ff8fa0; animation: tfloat 6s ease-in-out -3s infinite; text-shadow: 0 4px 40px rgba(40, 0, 10, .5), 0 0 50px rgba(255, 90, 110, .25); }
@keyframes tfloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
.lead { font-size: clamp(16px, 1.8vw, 19.5px); line-height: 1.6; max-width: 640px; margin: 22px auto 0; color: rgba(225, 240, 255, .86); font-weight: 500; text-shadow: 0 2px 16px rgba(0, 8, 20, .9); }
.hero-btns { display: flex; gap: 12px; justify-content: center; margin-top: 30px; flex-wrap: wrap; }
.btn {
  display: inline-flex; align-items: center; gap: 10px; cursor: pointer; border: 0;
  padding: 14px 26px; border-radius: 999px; font-weight: 800; font-size: 16px; letter-spacing: .01em;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
}
.btn svg { width: 20px; height: 20px; }
.btn.primary { background: linear-gradient(135deg, #ff5a6e, #ff8a5c); color: #fff; box-shadow: 0 10px 34px rgba(255, 70, 100, .35); }
.btn.primary:hover { transform: translateY(-2px); box-shadow: 0 14px 40px rgba(255, 70, 100, .5); }
.btn.primary svg { animation: nudge 1.6s ease-in-out infinite; }
@keyframes nudge { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(4px); } }
.btn.ghost { background: rgba(255, 255, 255, .1); color: #fff; border: 1px solid rgba(255, 255, 255, .18); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.btn.ghost:hover { background: rgba(255, 255, 255, .18); transform: translateY(-2px); }
.btn.small { padding: 9px 16px; font-size: 14px; }
.btn:focus-visible, .cb:focus-visible, .lab:focus-visible, .wtag:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }
.hero-live { position: absolute; left: 50%; bottom: 96px; transform: translateX(-50%); display: flex; gap: 14px; pointer-events: none; }
.hero-live div { padding: 10px 16px; border-radius: 16px; background: rgba(4, 14, 30, .55); border: 1px solid var(--line); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); text-align: left; min-width: 170px; }
.hero-live b { display: block; font: 700 22px var(--fm); color: #fff; font-variant-numeric: tabular-nums; }
.hero-live span { font-size: 12px; color: var(--muted); }
.scroll-hint { position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 10px; font: 600 12px var(--fm); letter-spacing: .12em; text-transform: uppercase; color: rgba(255, 255, 255, .85); }
.scroll-hint i { width: 22px; height: 34px; border: 2px solid rgba(255, 255, 255, .8); border-radius: 12px; position: relative; }
.scroll-hint i::after { content: ''; position: absolute; left: 50%; top: 6px; width: 4px; height: 7px; margin-left: -2px; border-radius: 2px; background: #fff; animation: wheel 1.8s ease-in-out infinite; }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 80% { transform: translateY(12px); opacity: 0; } 100% { opacity: 0; } }

/* ---------- svijet (tekst uz tijelo) ---------- */
#world { position: relative; width: 100%; z-index: 10; pointer-events: none; }
#world > * { pointer-events: auto; }
#ruler { position: absolute; top: 0; right: 0; width: 18px; bottom: 0; pointer-events: none !important; }
body.at-top #ruler { opacity: 0; }
#ruler { transition: opacity .6s; }
.rt { position: absolute; right: 0; height: 1px; background: rgba(255, 255, 255, .22); width: 6px; }
.rt.m { width: 11px; background: rgba(255, 255, 255, .35); }
.rt.k { width: 18px; background: rgba(255, 255, 255, .6); }
.rl { position: absolute; right: 24px; transform: translateY(-50%); font: 500 11px var(--fm); color: rgba(255, 255, 255, .5); white-space: nowrap; pointer-events: none !important; }
.rl.k { color: rgba(255, 255, 255, .85); font-weight: 700; font-size: 12px; }

.blk { position: absolute; left: var(--padL); width: var(--colW); }
.zone-card .zs { font: 700 11px var(--fm); letter-spacing: .2em; text-transform: uppercase; color: var(--zc); }
.zone-card h2 { font: 700 clamp(38px, 4.4vw, 62px)/1 var(--fd); margin: 8px 0 12px; color: #fff; letter-spacing: -.02em; text-shadow: 0 2px 30px rgba(0, 0, 0, .5); }
.zone-card p { margin: 0; color: var(--muted); font-size: 15.5px; line-height: 1.6; text-shadow: 0 1px 10px rgba(0, 0, 0, .7); }
.zone-card .zl { width: 64px; height: 3px; border-radius: 2px; background: var(--zc); margin-bottom: 16px; box-shadow: 0 0 18px var(--zc); }
.zone-card .zsys { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.zone-card .zsys span { font: 600 11px var(--fu); padding: 4px 9px; border-radius: 999px; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1); color: var(--muted); }
.zone-card .zsys span::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--c); margin-right: 6px; vertical-align: 1px; }

.mk { display: flex; align-items: center; gap: 10px; padding: 8px 14px 8px 8px; border-radius: 14px; width: auto !important; max-width: var(--colW); background: rgba(3, 14, 30, .72); border: 1px solid rgba(255, 255, 255, .12); }
.mk .mi { flex: 0 0 32px; height: 32px; border-radius: 10px; background: rgba(255, 255, 255, .08); display: grid; place-items: center; }
.mk .mi svg { width: 19px; height: 19px; fill: none; stroke: #bfe9ff; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.mk .mt { font: 700 13.5px/1.25 var(--fu); color: #fff; }
.mk .mt b { font: 700 12px var(--fm); color: var(--acc); margin-right: 6px; }
.mk .md { font-size: 12.5px; color: var(--muted); margin-top: 2px; line-height: 1.35; }

.fact { padding: 16px 18px; border-radius: 18px; background: linear-gradient(160deg, rgba(14, 40, 72, .8), rgba(4, 12, 28, .82)); border: 1px solid rgba(255, 255, 255, .13); font-size: 15px; line-height: 1.55; color: var(--ink); opacity: 0; translate: 0 26px; transition: opacity .8s ease, translate .8s cubic-bezier(.2, .8, .2, 1); }
.fact::before { content: 'Znaš li?'; display: block; font: 700 10.5px var(--fm); letter-spacing: .2em; text-transform: uppercase; color: var(--acc); margin-bottom: 6px; }
.fact.big { background: none; border: 0; padding: 0; font: italic 700 clamp(28px, 3.2vw, 44px)/1.12 var(--fd); color: #fff; text-shadow: 0 2px 26px rgba(0, 10, 30, .8), 0 0 40px rgba(111, 227, 255, .2); }
.fact.big::before { display: none; }
.fact.in, .wg.in, .quiz.in { opacity: 1; translate: 0 0; }

/* kviz */
.quiz { padding: 18px 18px 16px; border-radius: 20px; background: linear-gradient(160deg, rgba(40, 24, 80, .78), rgba(8, 8, 26, .84)); border: 1px solid rgba(182, 156, 255, .28); opacity: 0; translate: 0 26px; transition: opacity .8s ease, translate .8s cubic-bezier(.2, .8, .2, 1); }
.quiz .qk { font: 700 10.5px var(--fm); letter-spacing: .2em; text-transform: uppercase; color: #cbb8ff; }
.quiz h3 { font: 700 20px/1.25 var(--fd); margin: 8px 0 14px; }
.quiz .qo { display: grid; gap: 8px; }
.quiz .qo button { text-align: left; padding: 11px 14px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .06); cursor: pointer; font-weight: 700; font-size: 14.5px; transition: background .2s, border-color .2s, transform .2s; }
.quiz .qo button:hover:not(:disabled) { background: rgba(255, 255, 255, .12); transform: translateX(3px); }
.quiz .qo button.ok { background: rgba(55, 217, 149, .22); border-color: #37d995; }
.quiz .qo button.no { background: rgba(255, 90, 110, .2); border-color: #ff5a6e; }
.quiz .qo button:disabled { cursor: default; }
.quiz .qw { margin: 12px 0 0; font-size: 14px; line-height: 1.5; color: var(--muted); min-height: 0; }

/* pokusi */
.wg { padding: 18px 18px 14px; border-radius: 22px; background: linear-gradient(165deg, rgba(10, 34, 62, .86), rgba(3, 10, 24, .9)); border: 1px solid rgba(255, 255, 255, .14); box-shadow: 0 20px 60px rgba(0, 0, 0, .35); opacity: 0; translate: 0 26px; transition: opacity .8s ease, translate .8s cubic-bezier(.2, .8, .2, 1); }
.wg-k { font: 700 10.5px var(--fm); letter-spacing: .2em; text-transform: uppercase; color: var(--acc); }
.wg h3 { font: 700 23px/1.15 var(--fd); margin: 8px 0 6px; letter-spacing: -.01em; }
.wg-p { margin: 0 0 12px; font-size: 14.5px; line-height: 1.55; color: var(--muted); }
.wg-p b { color: #fff; }
.wg-note { margin: 10px 0 0; font-size: 13px; line-height: 1.5; color: var(--faint); }
.wg-note b { color: #fff; }
.wg-cv { display: block; width: 100%; border-radius: 14px; background: rgba(0, 0, 0, .25); touch-action: pan-y; }
.wg-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.wg-stat { font-size: 13px; color: var(--muted); }
.wg-stat b { font-family: var(--fm); color: #fff; }
.wbtn { cursor: pointer; border: 1px solid rgba(255, 255, 255, .18); background: rgba(255, 255, 255, .08); border-radius: 999px; padding: 8px 14px; font-weight: 700; font-size: 13px; }
.wbtn:hover { background: rgba(255, 255, 255, .16); }
.wtag { display: inline-flex; align-items: center; gap: 8px; padding: 7px 13px 7px 8px; border-radius: 999px; cursor: pointer; background: rgba(111, 227, 255, .12); border: 1px solid rgba(111, 227, 255, .35); font: 700 13px var(--fu); white-space: nowrap; }
.wtag:hover { background: rgba(111, 227, 255, .22); }
.wtag i { width: 20px; height: 20px; border-radius: 50%; background: #fff; color: #06223b; font: 800 12px/20px var(--fd); font-style: italic; text-align: center; }
.wtag.found::after { content: '✓'; color: #37d995; }
/* slijepa pjega */
.bs-box { position: relative; height: 150px; border-radius: 14px; background: #f4f7fa; display: flex; align-items: center; justify-content: space-between; padding: 0 12%; }
.bs-x { font: 700 44px/1 var(--fu); color: #0b1a2b; }
.bs-dot { width: 34px; height: 34px; border-radius: 50%; background: #e0243b; }
.bs-box.flip { flex-direction: row-reverse; }
/* sluh */
.hz-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; }
.hz { cursor: pointer; padding: 11px 4px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .06); transition: background .2s, transform .15s; }
.hz b { font: 700 12.5px var(--fm); }
.hz:hover { background: rgba(255, 255, 255, .13); }
.hz.on { background: rgba(111, 227, 255, .22); border-color: var(--acc); animation: hzp 1.3s ease; }
@keyframes hzp { 0%, 100% { box-shadow: 0 0 0 0 rgba(111, 227, 255, .5); } 50% { box-shadow: 0 0 0 8px rgba(111, 227, 255, 0); } }
/* reakcija */
.rt-pad { display: grid; place-content: center; gap: 4px; width: 100%; height: 150px; border-radius: 16px; border: 0; cursor: pointer; background: #1b3350; color: #fff; text-align: center; transition: background .15s; touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.rt-pad b { font: 800 26px var(--fu); }
.rt-pad small { font-size: 13px; color: rgba(255, 255, 255, .75); }
.rt-pad.wait { background: #a3243a; }
.rt-pad.go { background: #1fb872; }
.rt-pad.early { background: #6b4a12; }
.rt-pad.done { background: #173e63; }
.rt-res { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 10px; }
.rt-res div { padding: 8px 10px; border-radius: 12px; background: rgba(255, 255, 255, .06); }
.rt-res span { display: block; font-size: 11px; color: var(--faint); }
.rt-res b { font: 700 15px var(--fm); }
/* puls */
.pl-wrap { display: flex; align-items: center; gap: 18px; }
.pl-btn { flex: 0 0 auto; width: 118px; height: 118px; border-radius: 50%; border: 0; cursor: pointer; display: grid; place-items: center; align-content: center; gap: 2px; background: radial-gradient(circle at 40% 35%, #ff7d8d, #c81d36); box-shadow: 0 10px 40px rgba(255, 60, 90, .45), inset 0 -6px 20px rgba(0, 0, 0, .25); touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.pl-btn svg { width: 40px; height: 38px; fill: #fff; }
.pl-btn span { font: 800 13px var(--fu); letter-spacing: .1em; text-transform: uppercase; }
.pl-btn.beat { animation: plb .35s ease; }
@keyframes plb { 30% { transform: scale(1.1); } }
.pl-read b { display: block; font: 700 48px/1 var(--fm); }
.pl-read small { font-size: 13px; color: var(--muted); }
.pl-cmp { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 6px; margin-top: 14px; }
.pl-a { display: grid; grid-template-columns: auto 1fr; column-gap: 7px; align-items: center; padding: 7px 9px; border-radius: 12px; background: rgba(255, 255, 255, .05); border: 1px solid transparent; transition: border-color .3s, background .3s; }
.pl-a i { grid-row: span 2; font-style: normal; font-size: 20px; }
.pl-a span { font-size: 11.5px; color: var(--muted); }
.pl-a b { font: 700 13px var(--fm); }
.pl-a.near { border-color: #ff7d8d; background: rgba(255, 90, 110, .14); }
/* otisak */
.fp-row { display: flex; gap: 14px; align-items: center; }
.fp-row .wg-cv { flex: 1 1 0; min-width: 0; width: 100%; background: none; }
.fp-side { display: grid; gap: 12px; justify-items: start; flex: 0 0 auto; }
.fp-type span { display: block; font-size: 11px; color: var(--faint); text-transform: uppercase; letter-spacing: .14em; }
.fp-type b { font: 700 24px var(--fd); text-transform: capitalize; }

/* kraj */
.end { width: min(640px, calc(100vw - 32px)) !important; padding: 32px 28px 34px; border-radius: 30px; background: radial-gradient(ellipse at 50% 0%, rgba(30, 70, 110, .78), rgba(2, 6, 16, .92)); border: 1px solid rgba(255, 255, 255, .14); box-shadow: 0 30px 90px rgba(0, 0, 0, .5); }
.end .ek { font: 700 12px var(--fm); letter-spacing: .22em; text-transform: uppercase; color: #ffd27a; }
.end h2 { font: 900 clamp(40px, 6.6vw, 80px)/1 var(--fd); margin: 12px 0 14px; letter-spacing: -.03em; }
.end p { color: var(--muted); font-size: 16px; line-height: 1.6; margin: 0 0 20px; }
.end-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 6px 0 24px; }
.end-stats div { padding: 14px 12px; border-radius: 16px; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1); }
.end-stats b { display: block; font: 700 clamp(20px, 2.8vw, 27px) var(--fm); color: #fff; font-variant-numeric: tabular-nums; }
.end-stats span { font-size: 12.5px; color: var(--muted); }
.end .btns { display: flex; gap: 12px; flex-wrap: wrap; }
.series { margin-top: 28px; padding-top: 22px; border-top: 1px solid rgba(255, 255, 255, .1); }
.series h3 { font: 700 12px var(--fm); letter-spacing: .2em; text-transform: uppercase; color: var(--faint); margin: 0 0 12px; }
.series-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.series-grid a, .series-grid div { display: flex; align-items: center; gap: 10px; padding: 11px 12px; border-radius: 14px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .08); color: var(--ink); text-decoration: none; font-weight: 700; font-size: 13.5px; }
.series-grid a:hover { background: rgba(255, 255, 255, .12); }
.series-grid i { font-style: normal; font-size: 20px; }
.series-grid small { display: block; font: 500 11px var(--fm); color: var(--faint); }
.series-grid .here { border-color: rgba(255, 90, 110, .5); background: rgba(255, 90, 110, .12); }
.series-grid .soon { opacity: .55; }
.credits { margin-top: 22px !important; font-size: 12.5px !important; color: var(--faint) !important; line-height: 1.55 !important; }

/* ---------- oznake organa ---------- */
.pin { position: absolute; left: 0; top: 0; width: 22px; height: 22px; margin: -11px 0 0 -11px; border: 0; padding: 0; background: none; cursor: pointer; pointer-events: auto; opacity: 0; transition: opacity .35s; will-change: transform; }
.pin i { position: absolute; inset: 6px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 2px var(--lc, #6fe3ff), 0 0 14px var(--lc, #6fe3ff); }
.pin::after { content: ''; position: absolute; inset: 0; border-radius: 50%; border: 1.5px solid var(--lc, #6fe3ff); animation: pinr 2.4s ease-out infinite; }
@keyframes pinr { 0% { transform: scale(.4); opacity: 1; } 100% { transform: scale(1.6); opacity: 0; } }
.pin.back i { background: rgba(255, 255, 255, .5); }
.lab {
  position: absolute; left: 0; top: 0; pointer-events: auto; cursor: pointer; opacity: 0; transition: opacity .35s, background .2s, border-color .2s;
  display: flex; align-items: center; gap: 9px; padding: 7px 12px 7px 9px; border-radius: 14px; white-space: nowrap; will-change: transform;
  background: rgba(4, 14, 30, .72); border: 1px solid rgba(255, 255, 255, .14); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  text-align: left;
}
.lab .ld { width: 9px; height: 9px; border-radius: 50%; background: var(--lc); box-shadow: 0 0 10px var(--lc); flex: 0 0 auto; }
.lab b { display: block; font: 700 13.5px/1.2 var(--fu); color: #fff; }
.lab small { display: block; font: 500 10.5px var(--fm); color: var(--faint); margin-top: 2px; }
.lab:hover, .lab.f { background: rgba(8, 26, 50, .9); border-color: var(--lc); }
.lab.f b { color: #fff; }
.lab.found b::after { content: '✓'; display: inline-block; margin-left: 6px; width: 15px; height: 15px; border-radius: 50%; background: #37d995; color: #04241a; font-size: 9.5px; line-height: 15px; text-align: center; vertical-align: 1px; }
.lab .snd { width: 14px; height: 14px; fill: none; stroke: #9fe3ff; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; margin-left: 2px; }
#tip { position: fixed; left: 0; top: 0; z-index: 35; pointer-events: none; padding: 6px 11px; border-radius: 10px; background: rgba(4, 14, 30, .9); border: 1px solid rgba(255, 255, 255, .16); font: 700 13px var(--fu); white-space: nowrap; opacity: 0; transition: opacity .15s; }
#tip.on { opacity: 1; }

/* ---------- HUD ---------- */
#hud {
  position: fixed; top: 16px; right: 16px; z-index: 30; width: 244px; padding: 14px 16px 12px; border-radius: 20px;
  background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 10px 40px rgba(0, 0, 0, .3); transition: opacity .6s ease, transform .6s ease;
}
body.at-top #hud { opacity: 0; transform: translateY(-12px); pointer-events: none; }
.hud-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.hud-lbl { font: 700 10.5px var(--fm); letter-spacing: .2em; text-transform: uppercase; color: var(--faint); }
.hud-zone { font: 700 11px var(--fm); letter-spacing: .06em; color: var(--zc); text-align: right; white-space: nowrap; }
.hud-depth { font: 700 40px/1.05 var(--fm); letter-spacing: -.02em; margin: 6px 0 10px; font-variant-numeric: tabular-nums; }
.hud-depth small { font-size: 16px; margin-left: 6px; color: var(--muted); }
.hud-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; }
.hud-grid div { padding: 7px 8px; border-radius: 10px; background: rgba(255, 255, 255, .06); }
.hud-grid span { display: block; font-size: 10.5px; color: var(--faint); }
.hud-grid b { display: block; font: 700 12.5px var(--fm); white-space: nowrap; font-variant-numeric: tabular-nums; }
.hud-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; gap: 10px; }
.ecg-wrap { position: relative; flex: 1; height: 54px; border-radius: 10px; background: rgba(0, 30, 20, .35); overflow: hidden; }
.ecg-wrap canvas { width: 100%; height: 54px; display: block; }
.ecg-wrap span { position: absolute; left: 7px; top: 5px; font: 700 9px var(--fm); letter-spacing: .2em; color: rgba(110, 255, 190, .6); }
.lungs { display: grid; justify-items: center; gap: 2px; font-size: 10px; color: var(--faint); }
.lungs svg { width: 44px; height: 40px; overflow: visible; }
#lungL, #lungR { fill: #ff8a9a; opacity: .85; transform-box: fill-box; transition: transform .1s linear; }
#lungL { transform-origin: 100% 20%; }
#lungR { transform-origin: 0% 20%; }

/* ---------- traka za skok (silueta tijela) ---------- */
#track { position: fixed; left: 22px; top: 30vh; height: 240px; width: 82px; z-index: 30; cursor: pointer; transition: opacity .6s; }
body.at-top #track { opacity: 0; pointer-events: none; }
.tr-body { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.tr-body .sil { fill: rgba(255, 255, 255, .07); stroke: rgba(255, 255, 255, .28); stroke-width: .6; vector-effect: non-scaling-stroke; }
.tr-body .band { opacity: .5; }
.tr-line { position: absolute; left: -4px; right: -4px; height: 2px; margin-top: -1px; background: #fff; box-shadow: 0 0 10px #6fe3ff, 0 0 2px #fff; pointer-events: none; }
.tr-line span { position: absolute; left: 100%; top: 50%; transform: translate(8px, -50%); font: 700 11px var(--fm); white-space: nowrap; color: #fff; text-shadow: 0 1px 8px #000; opacity: 0; transition: opacity .2s; }
#track:hover .tr-line span { opacity: 1; }
.tr-lbl { position: absolute; left: calc(100% + 10px); transform: translateY(-50%); font: 600 10px var(--fm); white-space: nowrap; color: var(--faint); opacity: 0; transition: opacity .25s; pointer-events: none; }
#track:hover .tr-lbl { opacity: 1; }
.tr-hover { position: absolute; left: -4px; right: -4px; height: 1px; background: rgba(255, 255, 255, .6); opacity: 0; pointer-events: none; }
#track:hover .tr-hover { opacity: 1; }

/* ---------- kontrole ---------- */
#controls {
  position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 30; display: flex; gap: 4px; padding: 6px; border-radius: 999px;
  background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 10px 40px rgba(0, 0, 0, .35); transition: opacity .6s, transform .6s;
}
body.at-top #controls { opacity: 0; transform: translate(-50%, 20px); pointer-events: none; }
.cb { display: inline-flex; align-items: center; gap: 7px; border: 0; cursor: pointer; background: transparent; padding: 10px 14px; border-radius: 999px; font: 700 13.5px var(--fu); color: var(--ink); white-space: nowrap; transition: background .2s, color .2s; }
.cb svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cb:hover { background: rgba(255, 255, 255, .1); }
.cb.on { background: #eaf6ff; color: #06223b; }
.cb.sm { padding: 10px 10px; font-family: var(--fm); min-width: 44px; justify-content: center; }
.cb em { font: 700 11px var(--fm); font-style: normal; padding: 2px 7px; border-radius: 999px; background: rgba(255, 255, 255, .14); }
.cb.on em { background: rgba(6, 34, 59, .12); }
.cb .snd-off { display: none; }
#bSound:not(.on) .snd-on { display: none; }
#bSound:not(.on) .snd-off { display: inline; }
.cb.pulse { animation: cbp .6s ease; }
@keyframes cbp { 50% { transform: scale(1.12); } }
.pop { position: fixed; z-index: 45; bottom: 76px; left: 50%; transform: translateX(-50%); min-width: 220px; padding: 12px; border-radius: 18px; background: var(--glass-strong); border: 1px solid var(--line); box-shadow: 0 20px 60px rgba(0, 0, 0, .5); animation: pop .3s cubic-bezier(.2, .9, .25, 1.15); }
.pop-h { font: 700 10.5px var(--fm); letter-spacing: .2em; text-transform: uppercase; color: var(--faint); margin: 2px 4px 8px; }
.pop label { display: flex; align-items: center; gap: 10px; padding: 8px 8px; border-radius: 10px; cursor: pointer; font-weight: 700; font-size: 14px; }
.pop label:hover { background: rgba(255, 255, 255, .07); }
.pop input { width: 17px; height: 17px; accent-color: #6fe3ff; margin: 0; }
.pop label i { width: 10px; height: 10px; border-radius: 50%; background: var(--c); box-shadow: 0 0 8px var(--c); }

/* ---------- prozori ---------- */
.overlay { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 20px; }
.ov-back { position: absolute; inset: 0; background: rgba(0, 5, 14, .66); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); animation: fadeIn .3s ease; }
@keyframes fadeIn { from { opacity: 0; } }
.x { position: absolute; top: 14px; right: 14px; width: 40px; height: 40px; border-radius: 50%; border: 0; cursor: pointer; z-index: 3; background: rgba(255, 255, 255, .1); color: #fff; font-size: 24px; line-height: 40px; }
.x:hover { background: rgba(255, 255, 255, .2); }
.m-box {
  position: relative; overscroll-behavior: contain; width: min(1020px, 100%); max-height: calc(100vh - 40px); overflow: auto;
  display: grid; grid-template-columns: 1.1fr 1fr; border-radius: 28px;
  background: linear-gradient(160deg, rgba(12, 32, 60, .97), rgba(3, 8, 20, .98)); border: 1px solid rgba(255, 255, 255, .14); box-shadow: 0 30px 90px rgba(0, 0, 0, .6);
  animation: pop .45s cubic-bezier(.2, .9, .25, 1.15);
}
@keyframes pop { from { opacity: 0; transform: translateY(24px) scale(.96); } }
.m-card { padding: 22px; display: grid; }
.m-stage { position: relative; border-radius: 22px; min-height: 400px; overflow: hidden; background: radial-gradient(ellipse at 50% 40%, var(--mc1, #173e63), var(--mc2, #030b18) 78%); border: 1px solid rgba(255, 255, 255, .14); box-shadow: inset 0 0 60px rgba(0, 0, 0, .4); }
.m-stage::before { content: ''; position: absolute; inset: 0; opacity: .5; pointer-events: none; background-image: linear-gradient(rgba(111, 227, 255, .06) 1px, transparent 1px), linear-gradient(90deg, rgba(111, 227, 255, .06) 1px, transparent 1px); background-size: 28px 28px; }
#mCanvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; cursor: grab; touch-action: none; }
#mCanvas:active { cursor: grabbing; }
.m-h { position: absolute; left: 16px; bottom: 14px; font: 700 12px var(--fm); color: rgba(255, 255, 255, .75); letter-spacing: .06em; pointer-events: none; }
.m-hint { position: absolute; right: 16px; bottom: 14px; font: 500 11px var(--fu); color: var(--faint); pointer-events: none; }
.m-badge { position: absolute; left: 14px; top: 14px; display: flex; gap: 6px; pointer-events: none; }
.m-badge span { font: 700 11px var(--fu); padding: 6px 10px; border-radius: 999px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .18); }
.m-badge span i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--c); margin-right: 6px; box-shadow: 0 0 8px var(--c); }
.m-info { padding: 34px 32px 28px 8px; display: flex; flex-direction: column; }
.m-kicker { font: 700 11px var(--fm); letter-spacing: .18em; text-transform: uppercase; color: var(--zc); }
.m-info h2 { font: 700 clamp(28px, 3.4vw, 42px)/1.05 var(--fd); margin: 10px 0 6px; letter-spacing: -.02em; }
.m-latin { font: italic 500 16px var(--fd); color: var(--muted); }
.m-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 16px; }
.m-chips span { font-size: 12.5px; padding: 7px 11px; border-radius: 10px; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .1); }
.m-chips span b { font-family: var(--fm); font-weight: 700; margin-left: 5px; }
.m-facts { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 12px; }
.m-facts li { position: relative; padding-left: 26px; font-size: 15.5px; line-height: 1.55; color: #dcecf8; }
.m-facts li::before { content: ''; position: absolute; left: 2px; top: 9px; width: 10px; height: 10px; border-radius: 50%; background: var(--zc); box-shadow: 0 0 12px var(--zc); }
.m-actions { margin-top: auto; display: flex; gap: 8px; flex-wrap: wrap; }

.log-box, .help-box {
  position: relative; overscroll-behavior: contain; width: min(1120px, 100%); max-height: calc(100vh - 40px); overflow: auto;
  border-radius: 28px; padding: 30px 30px 34px;
  background: linear-gradient(160deg, rgba(12, 32, 60, .97), rgba(3, 8, 20, .98)); border: 1px solid rgba(255, 255, 255, .14); box-shadow: 0 30px 90px rgba(0, 0, 0, .6);
  animation: pop .45s cubic-bezier(.2, .9, .25, 1.15);
}
.log-head h2, .help-box h2 { font: 700 38px/1 var(--fd); margin: 0 0 8px; }
.log-head p { color: var(--muted); margin: 0 0 16px; max-width: 640px; line-height: 1.5; }
.log-prog { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.log-bar { flex: 1; max-width: 420px; height: 8px; border-radius: 4px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.log-bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #37d995, #6fe3ff); border-radius: 4px; transition: width .6s; }
#atlasProg { font: 700 13px var(--fm); }
.log-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.log-zone { grid-column: 1 / -1; font: 700 11px var(--fm); letter-spacing: .2em; text-transform: uppercase; color: var(--zc); margin-top: 10px; padding-bottom: 6px; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.tile { position: relative; border: 1px solid rgba(255, 255, 255, .1); border-radius: 16px; padding: 8px 8px 11px; cursor: pointer; text-align: left; background: radial-gradient(ellipse at 50% 30%, rgba(40, 90, 150, .3), rgba(255, 255, 255, .03)); transition: transform .2s, border-color .2s; }
.tile:hover { transform: translateY(-3px); border-color: rgba(255, 255, 255, .3); }
.tile .th { height: 96px; border-radius: 10px; display: grid; place-items: center; overflow: hidden; }
.tile .th img { width: 100%; height: 100%; object-fit: contain; }
.tile .th .ph { width: 40px; height: 40px; border-radius: 50%; border: 2px dashed rgba(255, 255, 255, .2); }
.tile.no .th img { filter: brightness(0) opacity(.5) drop-shadow(0 0 1px rgba(160, 220, 255, .6)); }
.tile b { display: block; font-size: 13px; margin-top: 6px; line-height: 1.2; }
.tile small { font: 500 11px var(--fm); color: var(--faint); }
.tile.no b { color: var(--faint); }
.tile .sy { position: absolute; top: 10px; right: 10px; width: 8px; height: 8px; border-radius: 50%; background: var(--c); box-shadow: 0 0 8px var(--c); }
.help-box { width: min(660px, 100%); }
.help-list { list-style: none; padding: 0; margin: 18px 0 24px; display: grid; gap: 10px; }
.help-list li { padding: 12px 14px; border-radius: 14px; background: rgba(255, 255, 255, .05); line-height: 1.5; font-size: 15px; color: #dcecf8; }
.help-list b { color: #fff; }

/* ---------- obavijesti ---------- */
#toasts { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); z-index: 60; display: grid; gap: 8px; justify-items: center; pointer-events: none; }
.toast { display: flex; align-items: center; gap: 10px; padding: 10px 16px 10px 12px; border-radius: 999px; background: var(--glass-strong); border: 1px solid rgba(255, 255, 255, .16); box-shadow: 0 10px 30px rgba(0, 0, 0, .4); font-weight: 700; font-size: 14px; animation: toastIn .5s cubic-bezier(.2, .9, .25, 1.2), toastOut .5s ease 3.4s forwards; }
.toast i { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-style: normal; background: var(--tc, #37d995); color: #04241a; font-size: 14px; flex: 0 0 auto; }
.toast small { display: block; font: 500 11px var(--fm); color: var(--muted); }
@keyframes toastIn { from { opacity: 0; transform: translateY(-16px) scale(.95); } }
@keyframes toastOut { to { opacity: 0; transform: translateY(-10px); } }

/* ---------- tablet ---------- */
@media (max-width: 1280px) {
  :root { --padL: 120px; --colW: 350px; }
}
@media (max-width: 1099px) {
  :root { --padL: 26px; --colW: 340px; }
  #track { display: none; }
}
/* ---------- mobitel ---------- */
@media (max-width: 760px) {
  :root { --padL: 14px; --colW: calc(100vw - 50px); }
  #hero { padding-top: 11vh; }
  .kicker { letter-spacing: .14em; font-size: 10.5px; }
  .btn { padding: 13px 20px; font-size: 15px; }
  .hero-live { bottom: 74px; gap: 8px; width: calc(100% - 28px); justify-content: center; }
  .scroll-hint span { display: none; }
  .scroll-hint { bottom: 20px; }
  .hero-live div { min-width: 0; flex: 1; padding: 8px 12px; }
  .hero-live b { font-size: 17px; }
  .hero-live span { font-size: 10.5px; }
  #hud { top: 10px; right: 10px; left: 10px; width: auto; padding: 9px 12px; border-radius: 16px; display: grid; grid-template-columns: auto 1fr; column-gap: 12px; align-items: center; }
  .hud-head { grid-column: 1; flex-direction: column; align-items: flex-start; gap: 2px; }
  .hud-zone { text-align: left; }
  .hud-depth { grid-column: 1; margin: 2px 0 0; font-size: 28px; }
  .hud-grid { grid-column: 2; grid-row: 1 / span 2; }
  .hud-foot { display: none; }
  #track { display: none; }
  #controls { left: 8px; right: 8px; transform: none; bottom: 8px; justify-content: space-between; border-radius: 20px; }
  body.at-top #controls { transform: translateY(20px); }
  .cb { padding: 8px 8px; flex-direction: column; gap: 3px; font-size: 10.5px; }
  .cb em { display: none; }
  .cb.sm { flex-direction: row; min-width: 38px; }
  .pop { bottom: 84px; }
  .zone-card { padding: 16px; border-radius: 18px; background: rgba(3, 12, 28, .74); border: 1px solid rgba(255, 255, 255, .1); }
  .zone-card h2 { font-size: 34px; margin: 6px 0 8px; }
  .zone-card p { font-size: 14px; }
  .fact { font-size: 14px; padding: 14px; }
  .fact.big { font-size: 27px; }
  .wg { padding: 16px 14px 12px; }
  .hz-row { grid-template-columns: repeat(4, 1fr); }
  .pl-btn { width: 96px; height: 96px; }
  .lab { padding: 5px 9px 5px 7px; gap: 6px; border-radius: 11px; }
  .lab b { font-size: 12px; }
  .lab small { display: none; }
  .rl { display: none; }
  #toasts { top: 96px; width: calc(100% - 24px); }
  .toast { font-size: 13px; }
  .m-box { grid-template-columns: 1fr; }
  .m-card { padding: 12px 12px 0; }
  .m-stage { min-height: 280px; }
  .m-info { padding: 18px 20px 22px; }
  .m-hint { display: none; }
  .end { left: 50% !important; transform: translateX(-50%); padding: 26px 18px 28px; }
  .log-box, .help-box { padding: 22px 16px 24px; }
  .log-grid { grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); }
  .fp-row { flex-direction: column; align-items: stretch; }
}
@media (prefers-reduced-motion: reduce) {
  .title .t1, .title .t2, .pin::after { animation: none !important; }
  .fact, .wg, .quiz { transition: none; }
}
/* niža kvaliteta */
.lowfx #hud, .lowfx #controls, .lowfx .lab, .lowfx .hero-live div { backdrop-filter: none; -webkit-backdrop-filter: none; background: rgba(4, 14, 30, .9); }
.lowfx .ov-back, .lowfx .btn.ghost { backdrop-filter: none; -webkit-backdrop-filter: none; }
.lowfx .ov-back { background: rgba(0, 5, 14, .82); }
