/* tour-film.css · the full-screen neural-net tour film (tour-film.js). Identical on every site; ONE source: release-qa/tour-film/.
   Self-contained: every rule is scoped to .tf-* (plus html.tf-on to stop page scroll); no shared desktop rule is touched.
   Neon Ink: no grey or pale text; every card its own colour + glow; captions = tinted light card + dark ink. */
html.tf-on, html.tf-on body { overflow: hidden !important; }
.tf-root { position: fixed; inset: 0; z-index: 2147483000; background: var(--tf-bg, #070a1a); color: #fff8e6;
  font: 500 16px/1.45 Inter, system-ui, -apple-system, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; isolation: isolate; }
.tf-root[hidden] { display: none !important; }
.tf-root *, .tf-root *::before, .tf-root *::after { box-sizing: border-box; }
/* shield the film from page rules (uppercase headings, gradient text, shadows) */
.tf-root :where(h2, p, a, button, span, small, b, nav) { text-transform: none; text-shadow: none; letter-spacing: normal; font-style: normal; -webkit-text-fill-color: currentColor; text-decoration: none; filter: none; }
.tf-root :where(h2, p) { background: none; border: 0; }
.tf-cv { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.tf-poster { position: absolute; inset: 0; display: grid; place-items: center; }
.tf-poster[hidden] { display: none; }
.tf-poster img { width: min(52vmin, 460px); height: auto; filter: drop-shadow(0 0 60px rgba(255, 194, 61, .45)); }
.tf-vig { position: absolute; inset: 0; pointer-events: none; background: radial-gradient(120% 90% at 50% 45%, transparent 55%, rgba(0, 0, 0, .55) 100%); }

/* neuron labels: own colour as the background, dark ink, own glow */
.tf-labels { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.tf-lab { position: absolute; left: 0; top: 0; display: inline-flex; align-items: center; gap: 7px; padding: 6px 12px 6px 8px; border-radius: 999px;
  background: var(--c); color: #0b1020; font: 700 13.5px/1.1 Inter, system-ui, sans-serif; white-space: nowrap; opacity: 0;
  box-shadow: 0 0 0 2px rgba(11, 16, 32, .55), 0 0 22px color-mix(in srgb, var(--c) 75%, transparent); will-change: transform, opacity; }
.tf-lab::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: #0b1020; box-shadow: 0 0 0 3px rgba(255, 255, 255, .55); flex: none; }
.tf-lab img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; margin: -3px 0 -3px -3px; border: 2px solid #0b1020; }
.tf-lab:has(img)::before { display: none; }
.tf-state:empty { display: none; }
.tf-state { display: block; padding-left: 9px; margin-left: 2px; border-left: 2px solid rgba(11, 16, 32, .45); font-weight: 800; }
.tf-lab.tf-hot { background: #ff6b45; box-shadow: 0 0 0 2px #3d1206, 0 0 34px #ff5a36; animation: tf-beat .9s ease-in-out infinite; }
.tf-lab.tf-ok { background: #4ade80; box-shadow: 0 0 0 2px #06301a, 0 0 30px #4ade80; }
@keyframes tf-beat { 50% { box-shadow: 0 0 0 2px #3d1206, 0 0 54px #ff5a36; } }

/* top: film name, sound off, pause, close */
.tf-top { z-index: 3; position: absolute; left: 0; right: 0; top: 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 18px 22px 0; }
.tf-name { margin: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 4px 12px; padding: 9px 16px; border-radius: 14px;
  background: #fff1c9; color: #3a2700; box-shadow: 0 0 26px rgba(255, 194, 61, .55); max-width: 62vw; }
.tf-name b { font: 800 17px/1.15 Inter, system-ui, sans-serif; letter-spacing: -.01em; }
.tf-name small { font: 700 11.5px/1.2 ui-monospace, "JetBrains Mono", Menlo, monospace; letter-spacing: .04em; text-transform: uppercase; color: #6b4300; }
.tf-dot { width: 10px; height: 10px; border-radius: 50%; box-shadow: 0 0 0 3px #3a2700; }
.tf-ctl { display: flex; align-items: center; gap: 8px; flex: none; }
.tf-sound { padding: 8px 12px; border-radius: 999px; background: #dff3ff; color: #062a44; font: 700 13px/1 Inter, system-ui, sans-serif; box-shadow: 0 0 18px rgba(56, 189, 248, .5); }
.tf-btn { appearance: none; border: 0; cursor: pointer; padding: 10px 15px; border-radius: 999px; font: 800 14px/1 Inter, system-ui, sans-serif; min-height: 40px; min-width: 44px;
  background: #ebe5ff; color: #1d1147; box-shadow: 0 0 18px rgba(167, 139, 250, .55); transition: transform .15s ease, box-shadow .15s ease; }
.tf-btn:hover { transform: translateY(-1px); box-shadow: 0 0 28px rgba(167, 139, 250, .85); }
.tf-btn:disabled { opacity: .45; cursor: default; transform: none; }
.tf-x { background: #ffc23d; color: #241500; box-shadow: 0 0 22px rgba(255, 194, 61, .7); }
.tf-root :focus-visible { outline: 3px solid #fff8e6; outline-offset: 3px; }

/* chapter bar: 5 segments, each its own colour */
.tf-bar { position: absolute; left: 22px; right: 22px; top: 76px; display: flex; gap: 6px; }
.tf-seg { appearance: none; border: 0; padding: 8px 0; flex: 1; background: none; cursor: pointer; }
.tf-seg i { display: block; height: 5px; border-radius: 3px; background: color-mix(in srgb, var(--c) 30%, #0b1020); overflow: hidden; position: relative; box-shadow: 0 0 10px color-mix(in srgb, var(--c) 40%, transparent); }
.tf-seg i::after { content: ""; position: absolute; inset: 0; background: var(--c); transform-origin: left; transform: scaleX(0); }
.tf-seg.tf-done i::after { transform: scaleX(1); }
.tf-seg.tf-now i::after { animation: tf-fill 7.2s linear forwards; }
.tf-paused .tf-seg.tf-now i::after, .tf-ended .tf-seg.tf-now i::after { animation-play-state: paused; }
.tf-still .tf-seg.tf-now i::after { animation: none; transform: scaleX(1); }
.tf-ended .tf-seg i::after { transform: scaleX(1); animation: none; }
@keyframes tf-fill { to { transform: scaleX(1); } }

/* caption card: tinted light background per chapter, dark ink, own glow */
.tf-cap { position: absolute; left: 22px; bottom: 22px; width: min(560px, calc(100% - 44px)); padding: 18px 22px 16px; border-radius: 20px;
  background: var(--cbg, #dff3ff); color: var(--cink, #062a44); box-shadow: 0 0 0 2px color-mix(in srgb, var(--cglow) 60%, transparent), 0 0 46px color-mix(in srgb, var(--cglow) 65%, transparent); }
.tf-cap.tf-in { animation: tf-up .55s cubic-bezier(.2, .8, .2, 1); }
@keyframes tf-up { from { opacity: 0; transform: translateY(14px); } }
.tf-k { margin: 0 0 6px; font: 800 12px/1.2 ui-monospace, "JetBrains Mono", Menlo, monospace; letter-spacing: .08em; text-transform: uppercase; color: var(--ck, #0b5d8a); }
.tf-t { margin: 0 0 6px; font: 800 clamp(22px, 2.5vw, 32px)/1.1 Inter, system-ui, sans-serif; letter-spacing: -.02em; color: inherit; min-height: 1.1em; }
.tf-l { margin: 0; font: 600 16px/1.45 Inter, system-ui, sans-serif; color: inherit; }
.tf-step { display: flex; gap: 8px; margin-top: 12px; }
.tf-step .tf-btn { min-height: 34px; padding: 8px 14px; font-size: 13px; background: #fff; color: var(--cink, #062a44); box-shadow: 0 0 0 2px color-mix(in srgb, var(--cglow) 70%, transparent); }
.tf-ended .tf-cap, .tf-ended .tf-labels { opacity: 0; pointer-events: none; transition: opacity .4s; }

/* end card */
.tf-end { z-index: 2; position: absolute; inset: 0; display: grid; place-items: center; padding: 110px 16px 24px; background: radial-gradient(circle at 50% 50%, rgba(0, 0, 0, .15), rgba(0, 0, 0, .55)); }
.tf-end[hidden] { display: none; }
.tf-end-in { width: min(640px, 100%); padding: 30px 30px 26px; border-radius: 26px; text-align: center; background: #ebe5ff; color: #1d1147;
  box-shadow: 0 0 0 2px #a78bfa, 0 0 70px rgba(167, 139, 250, .8); animation: tf-up .6s cubic-bezier(.2, .8, .2, 1); }
.tf-end-in .tf-k { color: #5b3bd1; }
.tf-end-t { margin: 4px 0 10px; font: 800 clamp(26px, 3.4vw, 40px)/1.08 Inter, system-ui, sans-serif; letter-spacing: -.02em; color: #1d1147; }
.tf-end-l { margin: 0 auto 20px; max-width: 46ch; font: 600 16.5px/1.5 Inter, system-ui, sans-serif; color: #1d1147; }
.tf-end-a { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.tf-go { appearance: none; border: 0; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; min-height: 46px; padding: 12px 20px; border-radius: 999px;
  font: 800 15.5px/1.1 Inter, system-ui, sans-serif; transition: transform .15s ease, box-shadow .15s ease; }
.tf-go:hover { transform: translateY(-2px); }
.tf-go[hidden] { display: none; }
.tf-pitch { background: #ffc23d; color: #241500; box-shadow: 0 0 0 2px #241500, 0 0 30px rgba(255, 194, 61, .85); font-size: 17px; }
.tf-again { background: #dcfce7; color: #06301a; box-shadow: 0 0 0 2px #137a3d, 0 0 22px rgba(74, 222, 128, .6); }
.tf-demo { background: #dff3ff; color: #062a44; box-shadow: 0 0 0 2px #0b5d8a, 0 0 22px rgba(56, 189, 248, .6); }
.tf-explore { background: #ffe4d9; color: #3d1206; box-shadow: 0 0 0 2px #b3360f, 0 0 22px rgba(255, 122, 69, .6); }

/* phones: compact chrome, caption full width, smaller labels */
@media (max-width: 700px) {
  .tf-top { padding: 12px 12px 0; gap: 8px; }
  .tf-name { padding: 7px 11px; max-width: calc(100vw - 150px); }
  .tf-name b { font-size: 14.5px; }
  .tf-name small, .tf-sound { display: none; }
  .tf-x span { display: none; }
  .tf-bar { left: 12px; right: 12px; top: 64px; }
  .tf-cap { left: 12px; right: 12px; bottom: 12px; width: auto; padding: 14px 16px 12px; }
  .tf-l { font-size: 14.5px; }
  .tf-lab { font-size: 11.5px; padding: 4px 9px 4px 6px; }
  .tf-end-in { padding: 22px 18px 18px; }
}
@media (max-height: 520px) { .tf-cap { padding: 10px 14px; } .tf-l { display: none; } }
@media (prefers-reduced-motion: reduce) { .tf-root *, .tf-root *::after { animation: none !important; transition: none !important; } }
/* headings: some pages style h2 with stronger selectors (v9/v8 .nx-page); the film keeps its own type */
.tf-root h2.tf-t, .tf-root h2.tf-end-t { font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif !important; font-weight: 800 !important; line-height: 1.1 !important; letter-spacing: -.02em !important; text-transform: none !important; max-width: none !important; }
.tf-root h2.tf-t { font-size: clamp(22px, 2.5vw, 32px) !important; margin: 0 0 6px !important; }
.tf-root h2.tf-end-t { font-size: clamp(26px, 3.4vw, 40px) !important; margin: 4px 0 10px !important; }
.tf-root p.tf-l, .tf-root p.tf-end-l { font-family: Inter, system-ui, sans-serif !important; max-width: none; }
@media (max-width: 700px) { .tf-root h2.tf-t { font-size: 21px !important; } .tf-root h2.tf-end-t { font-size: 25px !important; } }
