/* Fonts are self-hosted (SIL Open Font License, see assets/fonts/LICENSE-*.txt) */
@font-face {
  font-family: Inter; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url(assets/fonts/inter-latin-wght-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: Inter; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url(assets/fonts/inter-greek-wght-normal.woff2) format('woff2');
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
@font-face {
  font-family: Michroma; font-style: normal; font-weight: 400; font-display: swap;
  src: url(assets/fonts/michroma-latin-400-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #000;
  --fg: #f4f4f5;
  --mut: #8d8d95;
  --line: rgba(255, 255, 255, 0.55);
  --o1: #ffb000;
  --o2: #ff6a00;
  --display: Michroma, "Segoe UI", system-ui, sans-serif;
  --intro-font: var(--display); /* the font of the intro text: change this one line to try another */
}

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

/* readable by screen readers and search engines, invisible on screen */
.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--fg);
  font-family: Inter, system-ui, sans-serif;
  overflow: hidden;
}

/* ---------- brand + hint ---------- */
.brand {
  position: fixed;
  top: max(22px, env(safe-area-inset-top));
  left: 28px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 2;
}
.brand__name {
  font-family: var(--display);
  font-size: clamp(1rem, 2vw, 1.4rem);
  letter-spacing: 0.3em;
}
.brand__sub {
  font-size: 0.62rem;
  letter-spacing: 0.44em;
  color: var(--mut);
}
.hint {
  position: fixed;
  left: 0;
  right: 0;
  bottom: max(22px, env(safe-area-inset-bottom));
  text-align: center;
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--mut);
  pointer-events: none;
  transition: opacity 0.5s;
}
.hint.gone { opacity: 0; }

/* ---------- stage ---------- */
.stage {
  --n: clamp(54px, 10.5vmin, 76px);
  position: fixed;
  left: 50%;
  top: 50%;
  width: min(88vmin, 740px);
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  transition: transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
}
/* --tx / --ty / --ts are set from main.js so the atom fits the space the panel leaves free */
body.panel-open .stage {
  transform: translate(calc(-50% + var(--tx, 0px)), calc(-50% + var(--ty, 0px))) scale(var(--ts, 1));
}

.atom { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }

.ring {
  fill: none;
  stroke: var(--line);
  stroke-width: 0.28;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: draw 1.8s cubic-bezier(0.3, 0.6, 0.2, 1) forwards;
}
.ring:nth-child(2) { animation-delay: 0.12s; }
.ring:nth-child(3) { animation-delay: 0.24s; }
.ring:nth-child(4) { animation-delay: 0.36s; }
@keyframes draw { to { stroke-dashoffset: 0; } }

.bolt {
  opacity: 0;
  animation: fadein 0.9s 1s forwards;
}
/* the glow lives on the wrapper so it never fights the intro fade-in */
.bolt-wrap { filter: drop-shadow(0 0 0 rgba(255, 106, 0, 0)); }
/* Two layers on the bolt. .bolt-scale does the size change as a CSS transition, so it can reverse smoothly from
   wherever it is if the mouse leaves half way. .bolt-beat inside it does the heartbeat as an animation. */
.bolt-scale {
  transform-box: view-box; transform-origin: 50px 50px; transform: scale(0.78);
  transition: transform 0.45s ease-out; /* shrinking back */
}
.atom.is-active .bolt-scale {
  transform: scale(1.7);
  transition: transform 0.54s cubic-bezier(.4, 0, .2, 1); /* growing: slow start, smooth finish */
}

/* Idle: a light heartbeat at 30 bpm (2 s per beat). */
.bolt-beat { transform-box: view-box; transform-origin: 50px 50px; animation: idlebeat 2s cubic-bezier(.25, .8, .3, 1) infinite; }
.bolt-wrap { animation: idleglow 2s cubic-bezier(.25, .8, .3, 1) infinite; }
@keyframes idlebeat {
  0% { transform: scale(1); }
  10% { transform: scale(1.05); }
  22% { transform: scale(1.01); }
  34% { transform: scale(1.075); }
  54%, 100% { transform: scale(1); }
}
@keyframes idleglow {
  0%, 54%, 100% { filter: drop-shadow(0 0 0 rgba(255, 106, 0, 0)) brightness(1); }
  10% { filter: drop-shadow(0 0 2px rgba(255, 140, 0, 0.5)) brightness(1.1); }
  34% { filter: drop-shadow(0 0 3px rgba(255, 150, 0, 0.6)) brightness(1.18); }
}

/* Active (hover / focus / selected): once it has grown (0.54 s, the same moment the transition ends), the bolt beats at 80 bpm (0.75 s per beat):
   lub, dub, rest. --pk is how hard it beats, as a factor on top of the 1.7x size; a selected department beats
   a little harder than a hovered one. */
.atom.is-active { --pk: 1.07; }
.atom.is-active.is-selected { --pk: 1.145; }
.atom.is-active .bolt-beat { animation: heartbeat 0.75s cubic-bezier(.25, .8, .3, 1) 0.54s infinite; }
@keyframes heartbeat {
  0% { transform: scale(1); }
  10% { transform: scale(var(--pk)); }
  22% { transform: scale(1.02); }
  34% { transform: scale(calc(var(--pk) + 0.06)); }
  54%, 100% { transform: scale(1); }
}
/* the glow beats with it */
.atom.is-active .bolt-wrap { animation: beatglow 0.75s cubic-bezier(.25, .8, .3, 1) 0.54s infinite; }
@keyframes beatglow {
  0% { filter: drop-shadow(0 0 1.5px rgba(255, 106, 0, 0.7)) brightness(1); }
  10% { filter: drop-shadow(0 0 5px rgba(255, 160, 0, 0.95)) brightness(1.4); }
  22% { filter: drop-shadow(0 0 2.5px rgba(255, 120, 0, 0.8)) brightness(1.12); }
  34% { filter: drop-shadow(0 0 6px rgba(255, 180, 40, 1)) brightness(1.55); }
  54%, 100% { filter: drop-shadow(0 0 1.5px rgba(255, 106, 0, 0.7)) brightness(1); }
}
@keyframes fadein { to { opacity: 1; } }

.arc {
  fill: none;
  stroke: #ff8a00;
  stroke-width: 0.38;
  stroke-linejoin: miter;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  opacity: 0;
  filter: drop-shadow(0 0 1px rgba(255, 106, 0, 0.9));
}
.arc.on { opacity: 1; animation: strike 0.32s ease-out forwards; }
.arc--thin { stroke: #ffd27a; stroke-width: 0.2; stroke-dashoffset: 0; }
.arc--thin.on { animation: none; }
.arc--fork { stroke-width: 0.22; }
/* the point where the electricity lands on the node */
.spark { fill: #fff1cf; opacity: 0; pointer-events: none; filter: drop-shadow(0 0 1.2px #ff8a00) drop-shadow(0 0 3px rgba(255, 106, 0, 0.8)); }
.arc.fade { stroke-dashoffset: 0; opacity: 0; transition: opacity 0.35s; }
@keyframes strike { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }

/* ---------- nodes ---------- */
.node {
  position: absolute;
  width: var(--n);
  height: var(--n);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: #000;
  color: var(--fg);
  cursor: pointer;
  opacity: 0;
  animation: fadein 0.8s 1.2s forwards;
  transition: border-color 0.25s, color 0.25s, box-shadow 0.25s;
}
.node:hover, .node:focus-visible, .node.is-on {
  color: var(--o1);
  border-color: var(--o2);
  box-shadow: 0 0 0 5px rgba(255, 106, 0, 0.08);
  outline: none;
}
.node::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 50%;
  pointer-events: none;
}
.node:hover::after, .node:focus-visible::after, .node.is-on::after { animation: halo 1s ease-out infinite; }
@keyframes halo {
  0% { box-shadow: 0 0 0 0 rgba(255, 106, 0, 0.4); }
  100% { box-shadow: 0 0 0 14px rgba(255, 106, 0, 0); }
}
.node svg {
  width: 68%;
  height: 68%;
  margin: auto;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  overflow: visible;
}
.node__label {
  position: absolute;
  top: calc(100% + 12px);
  left: 50%;
  transform: translateX(-50%);
  width: 180px;
  text-align: center;
  pointer-events: none;
}
.node__label b {
  display: block;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}
.node__label i {
  display: block;
  margin-top: 5px;
  font-style: normal;
  font-size: 0.66rem;
  color: var(--mut);
  opacity: 0;
  transform: translateY(-3px);
  transition: opacity 0.3s, transform 0.3s;
}
.node:hover .node__label i,
.node:focus-visible .node__label i,
.node.is-on .node__label i { opacity: 1; transform: none; }

/* one-shot icon animations, played on hover / focus / selection */
.a { transform-box: view-box; }
.node:hover .a-lift, .node:focus-visible .a-lift, .node.is-on .a-lift { animation: lift 1.5s ease-in-out 1; }
.node:hover .a-kb, .node:focus-visible .a-kb, .node.is-on .a-kb { animation: swing 1.7s ease-in-out 1; }
.node:hover .a-hand, .node:focus-visible .a-hand, .node.is-on .a-hand { animation: sweep 1.5s cubic-bezier(.5,0,.2,1) 1; }
.node:hover .a-bag, .node:focus-visible .a-bag, .node.is-on .a-bag { animation: punch 1.7s ease-out 1; }
.a-kb { transform-origin: 24px 6px; }
.a-hand { transform-origin: 24px 28px; }
.a-bag { transform-origin: 24px 4px; }

@keyframes lift {
  0% { transform: translateY(0); }
  22% { transform: translateY(3px); }
  45% { transform: translateY(-10px); }
  75% { transform: translateY(-10px); }
  100% { transform: translateY(0); }
}
@keyframes swing {
  0% { transform: rotate(0); }
  20% { transform: rotate(-32deg); }
  45% { transform: rotate(24deg); }
  68% { transform: rotate(-11deg); }
  85% { transform: rotate(4deg); }
  100% { transform: rotate(0); }
}
@keyframes sweep {
  0% { transform: rotate(0); }
  100% { transform: rotate(360deg); }
}
@keyframes punch {
  0% { transform: rotate(0); }
  10% { transform: rotate(15deg); }
  30% { transform: rotate(-10deg); }
  52% { transform: rotate(6deg); }
  74% { transform: rotate(-2.5deg); }
  100% { transform: rotate(0); }
}

/* ---------- panel ---------- */
.panel {
  position: fixed;
  right: 28px;
  top: 50%;
  width: min(380px, calc(100vw - 56px));
  transform: translate(24px, -50%);
  opacity: 0;
  pointer-events: none;
  background: rgba(8, 8, 10, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  padding: 30px 28px 28px;
  visibility: hidden; /* closed panel must not be reachable by keyboard or screen reader */
  transition: opacity 0.35s, transform 0.35s, visibility 0s 0.35s;
  z-index: 3;
}
.panel.open { opacity: 1; transform: translate(0, -50%); pointer-events: auto; visibility: visible; transition-delay: 0s; }
.panel__close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: transparent;
  color: var(--fg);
  font-size: 1.05rem;
  cursor: pointer;
}
.panel__close:hover, .panel__close:focus-visible { color: var(--o1); border-color: var(--o2); outline: none; }
.cta:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.panel__kicker { font-size: 0.66rem; letter-spacing: 0.26em; text-transform: uppercase; color: var(--o1); }
.panel h2 { font-family: var(--display); font-weight: 400; font-size: 1.4rem; letter-spacing: 0.08em; margin: 12px 0 14px; }
.panel p { line-height: 1.65; color: #cfcfd4; font-size: 0.93rem; }
.panel__tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 18px 0 16px; }
.panel__tags li {
  list-style: none;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #d4d4d8;
}
.cta {
  display: inline-block;
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #000;
  text-decoration: none;
  background: linear-gradient(90deg, var(--o1), var(--o2));
  padding: 12px 20px;
  border-radius: 999px;
}

/* ---------- intro ---------- */
.intro {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  align-items: center;
  justify-content: center;
  background: #000;
  cursor: pointer;
  padding: 24px;
  transition: opacity 0.9s ease;
}
.intro-on .intro { display: flex; }
.intro.out { opacity: 0; pointer-events: none; }
/* the atom's own intro waits until the text is done */
.intro-on .ring, .intro-on .bolt, .intro-on .node { animation-play-state: paused; }

.intro__text { width: min(92vw, 760px); text-align: center; }
.intro__line {
  font-family: var(--intro-font);
  font-size: clamp(0.8rem, 2.2vw, 1.15rem);
  line-height: 1.5;
  font-weight: 400;
  letter-spacing: 0.03em;
  color: var(--fg);
  margin: 0 0 0.55em;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.9s ease, transform 0.9s ease, color 0.9s ease;
}
.intro__line.in { opacity: 1; transform: none; }
.intro__line.past { opacity: 0.58; } /* dimmed, but still above the 4.5:1 contrast minimum */
.intro__line--head { letter-spacing: 0.06em; font-size: clamp(1.1rem, 3.3vw, 1.9rem); }
.intro__line--gap { margin-top: 1.7em; }
.intro__line--cta.in { color: var(--o1); opacity: 1; }
.intro__skip {
  position: absolute;
  bottom: max(26px, env(safe-area-inset-bottom));
  left: 0;
  right: 0;
  text-align: center;
  font-size: 0.68rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--mut);
}
.intro.static .intro__line { transition: none; }

.replay {
  position: fixed;
  top: max(20px, env(safe-area-inset-top));
  right: 24px;
  z-index: 2;
  background: none;
  border: 0;
  padding: 12px 6px;
  font: inherit;
  font-size: clamp(0.78rem, 1.05vw, 0.92rem);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #d4d4d8;
  cursor: pointer;
  animation: breathe 4.6s ease-in-out infinite; /* slow glow: it says "you can press me" */
  transition: color 0.25s;
}
@keyframes breathe {
  0%, 100% { opacity: 0.62; text-shadow: 0 0 0 rgba(255, 106, 0, 0); }
  50% { opacity: 1; text-shadow: 0 0 16px rgba(255, 140, 0, 0.6); }
}
.replay:hover, .replay:focus-visible { color: var(--o1); outline: none; animation: none; opacity: 1; text-shadow: 0 0 14px rgba(255, 140, 0, 0.55); }

/* ---------- weight plate behind the bolt (on by default, ?nodisc turns it off) ----------
   A translucent barbell plate: thick rim, grooves, lettering around it and a hole with a collar in the centre,
   where the bolt sits. It glows a little while a department is active and the bolt grows to fill it. */
.plate { display: none; opacity: 0; filter: drop-shadow(0 0 0 rgba(255, 140, 0, 0)); transition: filter 0.5s; }
.disc .plate { display: block; animation: fadein 0.8s 0.2s forwards; }
.atom.is-active .plate { filter: drop-shadow(0 0 3px rgba(255, 140, 0, 0.5)); }
.plate__edge { fill: #08080a; stroke: rgba(255, 255, 255, 0.3); stroke-width: 0.3; } /* the thickness of the plate, seen from a slight angle */
.plate__face { fill: url(#plateFace); }
.plate__glow { fill: rgba(255, 140, 0, 0.13); opacity: 0; transition: opacity 0.5s; }
.atom.is-active .plate__glow { opacity: 1; }
.plate__shine { fill: url(#plateShine); }
.plate__aodir { fill: url(#plateAoDir); }
.plate__ao { fill: url(#plateAo); }
.plate__rim { fill: none; stroke: url(#plateRim); stroke-width: 1.3; }
.plate__groove { fill: none; stroke: url(#plateBevel); stroke-width: 0.34; }
.plate__tx { font-family: var(--display); font-size: 2.7px; letter-spacing: 0.35px; }
.plate__tx--s3 { fill: #000; opacity: 0.16; transform: translate(0.5px, 0.66px); }
.plate__tx--s2 { fill: #000; opacity: 0.28; transform: translate(0.3px, 0.4px); }
.plate__tx--s1 { fill: #000; opacity: 0.5; transform: translate(0.14px, 0.2px); }
.plate__tx--hi { fill: #fff; opacity: 0.32; transform: translate(-0.07px, -0.09px); }
.plate__tx--main { fill: rgba(255, 176, 0, 0.96); }
.plate__hole { fill: url(#plateHole); }
.plate__collar { fill: none; stroke: url(#plateSteel); stroke-width: 1.15; } /* steel insert, as on the real plates */
.plate__insert { fill: none; stroke: rgba(255, 255, 255, 0.3); stroke-width: 0.2; }

.snd { font: inherit; font-size: 0.68rem; letter-spacing: 0.22em; text-transform: uppercase; border: 1px solid rgba(255, 255, 255, 0.28); background: rgba(0, 0, 0, 0.55); }
.snd .snd__on { display: none; }
.snd[aria-pressed='true'] .snd__on { display: inline; }
.snd[aria-pressed='true'] .snd__off { display: none; }
.snd[aria-pressed='true'] { color: var(--o1); border-color: rgba(255, 106, 0, 0.55); }

/* ---------- photo gallery ---------- */
.panel__thumbs { display: flex; gap: 8px; margin: 0 0 22px; }
.thumb {
  position: relative; flex: 0 0 auto; width: 68px; height: 68px; padding: 0; overflow: hidden;
  border-radius: 10px; border: 1px solid rgba(255, 255, 255, 0.18); background: #111; cursor: pointer;
  transition: border-color 0.25s;
}
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: 0.88; transition: opacity 0.25s; }
.thumb:hover, .thumb:focus-visible { border-color: var(--o2); outline: none; }
.thumb:hover img, .thumb:focus-visible img { opacity: 1; }
.thumb--more::after {
  content: attr(data-more); position: absolute; inset: 0; display: grid; place-items: center;
  background: rgba(0, 0, 0, 0.58); color: #fff; font-size: 0.85rem; font-weight: 600; letter-spacing: 0.04em;
}

.lightbox {
  position: fixed; inset: 0; z-index: 30; display: flex; align-items: center; justify-content: center;
  background: rgba(0, 0, 0, 0.97); padding: 64px 72px 72px;
  visibility: hidden; opacity: 0; transition: opacity 0.25s, visibility 0s 0.25s;
}
.lightbox.open { visibility: visible; opacity: 1; transition-delay: 0s; }
.lb__fig { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 14px; max-width: 100%; max-height: 100%; }
.lb__img { max-width: min(100%, 1400px); max-height: calc(100vh - 170px); object-fit: contain; border-radius: 6px; transition: opacity 0.25s; }
.lb__img.loading { opacity: 0; }
.lb__cap { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 16px; font-size: 0.8rem; color: #cfcfd4; text-align: center; }
.lb__sport { color: var(--o1); font-size: 0.66rem; letter-spacing: 0.22em; text-transform: uppercase; align-self: center; }
.lb__count { color: var(--mut); }
.lb__btn {
  position: absolute; width: 46px; height: 46px; display: grid; place-items: center; padding: 0 0 3px;
  border-radius: 50%; border: 1px solid rgba(255, 255, 255, 0.25); background: rgba(0, 0, 0, 0.55);
  color: #fff; font-size: 1.5rem; line-height: 1; cursor: pointer; transition: color 0.25s, border-color 0.25s;
}
.lb__btn:hover, .lb__btn:focus-visible { color: var(--o1); border-color: var(--o2); outline: none; }
.lb__close { top: max(16px, env(safe-area-inset-top)); right: 16px; }
.lb__prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lb__next { right: 16px; top: 50%; transform: translateY(-50%); }

/* ---------- instagram ---------- */
.social {
  position: fixed; right: 24px; bottom: max(22px, env(safe-area-inset-bottom)); z-index: 2;
  display: flex; gap: 8px; transition: opacity 0.35s;
}
.ig, .fb, .snd {
  display: flex; align-items: center; gap: 10px; padding: 10px 16px 10px 12px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.28); background: rgba(0, 0, 0, 0.55); color: #d4d4d8; cursor: pointer;
  font: inherit; font-size: 0.68rem; letter-spacing: 0.22em; text-transform: uppercase; text-decoration: none;
  transition: color 0.25s, border-color 0.25s;
}
.ig svg, .fb svg, .snd svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linejoin: round; }
.ig svg circle:last-child { fill: currentColor; stroke: none; }
.ig:hover, .ig:focus-visible, .fb:hover, .fb:focus-visible, .snd:hover, .snd:focus-visible { color: var(--o1); border-color: var(--o2); outline: none; }

.igview {
  position: fixed; inset: 0; z-index: 30; display: flex; align-items: center; justify-content: center;
  background: rgba(0, 0, 0, 0.97); padding: 64px 16px 24px;
  visibility: hidden; opacity: 0; transition: opacity 0.25s, visibility 0s 0.25s;
}
.igview.open { visibility: visible; opacity: 1; transition-delay: 0s; }
.igview .lb__close { top: max(16px, env(safe-area-inset-top)); right: 16px; }
.igview__box { width: min(560px, 100%); height: 100%; max-height: 800px; display: flex; flex-direction: column; gap: 12px; }
.igview__note { font-size: 0.74rem; line-height: 1.5; color: var(--mut); text-align: center; }
.igview__note a { color: var(--o1); text-decoration: none; white-space: nowrap; }
.igview__note a:hover, .igview__note a:focus-visible { text-decoration: underline; outline: none; }
.igview__frame { flex: 1; min-height: 0; border-radius: 14px; overflow: hidden; background: #fff; }
.igview__frame iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ---------- mobile ---------- */
@media (max-width: 819px) {
  .brand { left: 18px; }
  .social { right: 14px; }
  .ig, .fb, .snd { padding: 11px; }
  .ig__label { display: none; }
  body.panel-open .social { opacity: 0; pointer-events: none; }
  .thumb { width: 52px; height: 52px; border-radius: 8px; }
  .panel__thumbs { gap: 6px; margin-bottom: 16px; }
  .lightbox { padding: 60px 10px 84px; }
  .lb__img { max-height: calc(100vh - 190px); }
  .lb__prev, .lb__next { top: auto; bottom: 18px; transform: none; }
  .lb__prev { left: calc(50% - 56px); }
  .lb__next { right: calc(50% - 56px); }
  .replay { top: 74px; left: 12px; right: auto; padding: 10px 6px; font-size: 0.7rem; letter-spacing: 0.16em; } /* under the brand, so it can be bigger */
  .stage { width: min(94vw, 560px); }
  .node__label { width: 120px; }
  .node__label b { font-size: 0.64rem; letter-spacing: 0.14em; }
  .node__label i { display: none; }
  .panel {
    right: 12px;
    left: 12px;
    top: auto;
    bottom: max(12px, env(safe-area-inset-bottom));
    width: auto;
    transform: translateY(24px);
  }
  .panel.open { transform: none; }
  .panel { padding: 22px 20px 20px; }
  .panel h2 { font-size: 1.15rem; margin: 8px 0 10px; }
  .panel p { font-size: 0.88rem; line-height: 1.55; }
  .panel__tags { margin: 12px 0 16px; }
  .cta { padding: 10px 18px; }
  body.panel-open .hint { opacity: 0; }
}

/* short landscape screens (phones turned sideways, small tablets): the replay link stays at the top right,
   because under the brand it would sit on top of the first department */
@media (max-width: 819px) and (min-aspect-ratio: 1/1) {
  .replay { top: max(20px, env(safe-area-inset-top)); left: auto; right: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  .ring { animation: none; stroke-dashoffset: 0; }
  .bolt, .node { animation: none; opacity: 1; }
  .disc .plate { animation: none; opacity: 1; }
  .bolt-scale { transition: none; }
  .bolt-beat, .atom.is-active .bolt-beat { animation: none; }
  .a, .node::after, .bolt-wrap { animation: none !important; }
  .arc.on { animation: none; stroke-dashoffset: 0; }
  .stage, .panel { transition: none; }
  .intro, .intro__line { transition: none; }
  .lightbox, .lb__img, .igview { transition: none; }
  .replay { animation: none; opacity: 1; }
}
