/* Nerve Blocks — shared styles
   Lab equipment / ultrasound screen aesthetic. */

:root {
  --ink: #08090B;
  --ink-2: #0E1014;
  --grid: #1A1D22;
  --line: #262A31;
  --green: #39FF88;
  --green-dim: rgba(57, 255, 136, .14);
  --red: #FF3B3B;
  --paper: #F2F2F0;
  --text: #F2F2F0;
  --muted: #9AA0A8;
  --orange: #FF8A3D;
  --font-display: "Bricolage Grotesque", "Arial Narrow", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --font-body: "Bricolage Grotesque", system-ui, -apple-system, "Segoe UI", sans-serif;
  --gutter: clamp(16px, 4vw, 48px);
  --max: 1320px;
  --radius: 2px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 122px; }
body {
  margin: 0;
  background: var(--ink);
  color: var(--text);
  font-family: var(--font-body);
  font-variation-settings: "wdth" 100;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--green); text-underline-offset: 3px; }
a:hover { color: var(--paper); }
::selection { background: var(--green); color: var(--ink); }
:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }

.mono { font-family: var(--font-mono); }
.label {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
}
.skip {
  position: absolute; left: 8px; top: 8px; z-index: 100; transform: translateY(-200%);
  background: var(--green); color: var(--ink); padding: 8px 12px; font-family: var(--font-mono);
}
.skip:focus { transform: none; }
[dir=rtl] .skip { left: auto; right: 8px; }

/* Scope grid background */
.scope-grid {
  background-color: var(--ink);
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 48px 48px;
  background-position: -1px -1px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(8, 9, 11, .86);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .inner {
  max-width: var(--max); margin: 0 auto;
  padding: 0 var(--gutter);
  height: 64px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  color: var(--paper); text-decoration: none;
  font-family: var(--font-display);
  font-weight: 800;
  font-variation-settings: "wdth" 75;
  font-size: 22px; letter-spacing: -.01em; text-transform: uppercase;
}
.brand-mark { width: 28px; height: 18px; flex: none; }
.brand-mark path { stroke: var(--green); }
.nav { display: flex; gap: 4px; }
.nav a {
  font-family: var(--font-mono); font-size: 13px; letter-spacing: .04em;
  color: var(--muted); text-decoration: none; padding: 8px 12px; border-radius: var(--radius);
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--paper); }
.nav a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--green); }
.nav-toggle {
  display: none; background: none; border: 1px solid var(--line); color: var(--paper);
  font-family: var(--font-mono); font-size: 12px; padding: 8px 12px; border-radius: var(--radius); cursor: pointer;
}
@media (max-width: 1100px) {
  .nav-toggle { display: inline-block; }
  .nav {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; gap: 0;
    background: var(--ink); border-bottom: 1px solid var(--line);
    padding: 8px var(--gutter) 16px;
    display: none;
  }
  .nav.open { display: flex; }
  .nav a { padding: 14px 0; border-bottom: 1px solid var(--grid); font-size: 15px; }
  .nav a[aria-current="page"] { box-shadow: none; color: var(--green); }
}

/* ---------- Block hero ---------- */
.block-hero {
  border-bottom: 1px solid var(--line);
  position: relative; overflow: hidden;
}
.block-hero .inner {
  max-width: var(--max); margin: 0 auto;
  padding: clamp(32px, 6vw, 72px) var(--gutter) clamp(28px, 4vw, 48px);
  display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: clamp(24px, 4vw, 56px); align-items: end;
}
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 20px; padding: 0; list-style: none; }
.crumbs li { font-family: var(--font-mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: var(--line); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--green); }
.block-code {
  display: inline-flex; gap: 10px; align-items: center;
  font-family: var(--font-mono); font-size: 12px; color: var(--green);
  border: 1px solid var(--green-dim); padding: 4px 10px; margin-bottom: 16px; letter-spacing: .1em;
}
.block-code .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); }
.block-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-variation-settings: "wdth" 75;
  font-size: clamp(40px, 7vw, 96px);
  line-height: .92; letter-spacing: -.02em;
  margin: 0 0 20px; text-transform: uppercase;
  text-wrap: balance;
}
.block-summary { font-size: clamp(17px, 1.6vw, 20px); color: #C9CDD2; max-width: 60ch; margin: 0; }
.block-thumb { margin: 0; width: 100%; border: 1px solid var(--line); background: #000; }
.block-thumb img { width: 100%; height: auto; }
.block-thumb figcaption { padding: 8px 12px; border-top: 1px solid var(--line); background: var(--ink-2); }
.block-thumb canvas { width: 100%; height: 100%; display: block; }
.block-thumb .hud {
  position: absolute; inset: 8px 10px auto; display: flex; justify-content: space-between;
  font-family: var(--font-mono); font-size: 11px; color: var(--green); opacity: .8; pointer-events: none;
}
.draft-flag {
  display: inline-block; margin-top: 20px;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em;
  color: var(--ink); background: var(--orange); padding: 6px 10px;
}

/* Quick facts strip */
.facts {
  max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter);
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
}
.fact { padding: 18px 16px 20px 0; border-right: 1px solid var(--line); }
.fact + .fact { padding-left: 16px; }
.fact:last-child { border-right: 0; }
.fact dt { font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.fact dd { margin: 0; font-family: var(--font-mono); font-size: 14px; line-height: 1.4; color: var(--paper); }
@media (max-width: 1000px) {
  .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .fact:nth-child(3n) { border-right: 0; }
  .fact:nth-child(3n+1) { padding-left: 0; }
  .fact:nth-child(n+4) { border-top: 1px solid var(--line); }
}
@media (max-width: 560px) {
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fact { border-right: 1px solid var(--line) !important; padding-left: 16px !important; }
  .fact:nth-child(2n) { border-right: 0 !important; }
  .fact:nth-child(2n+1) { padding-left: 0 !important; }
  .fact:nth-child(n+3) { border-top: 1px solid var(--line); }
}

@media (max-width: 860px) {
  .block-hero .inner { grid-template-columns: 1fr; }
  .block-thumb { max-width: 520px; }
}

/* ---------- Block body ---------- */
.block-body {
  max-width: var(--max); margin: 0 auto;
  padding: clamp(32px, 5vw, 64px) var(--gutter) 64px;
  display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: clamp(32px, 5vw, 72px);
}
.toc { position: sticky; top: 122px; align-self: start; max-height: calc(100vh - 144px); overflow: auto; }
.toc ol { list-style: none; margin: 12px 0 0; padding: 0; counter-reset: toc; }
.toc li { counter-increment: toc; }
.toc a {
  display: flex; gap: 10px; padding: 6px 0 6px 12px;
  font-family: var(--font-mono); font-size: 12.5px; line-height: 1.4;
  color: var(--muted); text-decoration: none;
  border-left: 1px solid var(--line);
}
.toc a::before { content: counter(toc, decimal-leading-zero); color: #5A606A; }
.toc a:hover { color: var(--paper); }
.toc a.active { color: var(--green); border-left-color: var(--green); }
.toc a.active::before { color: var(--green); }
@media (max-width: 960px) {
  .block-body { grid-template-columns: 1fr; }
  .toc { position: static; max-height: none; border: 1px solid var(--line); padding: 14px 16px; }
  .toc details summary { cursor: pointer; list-style: none; }
  .toc details summary::-webkit-details-marker { display: none; }
  .toc details summary::after { content: " +"; color: var(--green); }
  .toc details[open] summary::after { content: " −"; }
}

.content { min-width: 0; max-width: 820px; }
.content section { padding: 0 0 48px; margin: 0 0 48px; border-bottom: 1px solid var(--grid); }
.content section:last-of-type { border-bottom: 0; }
.sec-head { display: flex; align-items: baseline; gap: 14px; margin: 0 0 20px; }
.sec-num { font-family: var(--font-mono); font-size: 13px; color: var(--green); flex: none; }
.content h2 {
  font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 75;
  font-size: clamp(28px, 3.4vw, 40px); line-height: 1; letter-spacing: -.01em;
  margin: 0; text-transform: uppercase;
}
.content h3 {
  font-family: var(--font-mono); font-weight: 600; font-size: 13px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--green); margin: 32px 0 10px;
}
.content p { margin: 0 0 14px; color: #D9DCE0; }
.content strong { color: var(--paper); }
.content ul { margin: 0 0 16px; padding: 0; list-style: none; }
.content li { position: relative; padding: 0 0 0 22px; margin: 0 0 9px; color: #D9DCE0; }
.content li::before {
  content: ""; position: absolute; left: 2px; top: .72em; width: 10px; height: 1px; background: var(--green);
}

.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.cols > div { border: 1px solid var(--line); padding: 18px 20px 6px; }
.cols h3 { margin-top: 0; }
.cols .neg h3 { color: var(--red); }
.cols .neg li::before { background: var(--red); }
@media (max-width: 680px) { .cols { grid-template-columns: 1fr; } }

/* spec list */
.specs { margin: 0 0 20px; border-top: 1px solid var(--line); }
.specs div { display: grid; grid-template-columns: 200px 1fr; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.specs dt { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding-top: 3px; }
.specs dd { margin: 0; color: #D9DCE0; }
@media (max-width: 560px) { .specs div { grid-template-columns: 1fr; gap: 4px; } }

/* tables */
.table-wrap { overflow-x: auto; margin: 6px 0 18px; border: 1px solid var(--line); }
table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 520px; }
th, td { text-align: left; vertical-align: top; padding: 11px 14px; border-bottom: 1px solid var(--line); }
th { font-family: var(--font-mono); font-size: 11.5px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: var(--ink-2); }
tr:last-child td { border-bottom: 0; }
td:first-child { color: var(--paper); font-weight: 600; }
td { color: #D9DCE0; }

/* figures */
.scope {
  margin: 8px 0 28px; position: relative;
  border: 1px solid var(--line); background: #000;
}
.scope .frame { position: relative; overflow: hidden; }
.scope img { width: 100%; height: auto; }
.facts-wrap { border-top: 1px solid var(--line); }
.scope .tick { position: absolute; width: 14px; height: 14px; border-color: var(--green); border-style: solid; opacity: .9; pointer-events: none; }
.scope .tl { top: 8px; left: 8px; border-width: 1px 0 0 1px; }
.scope .tr { top: 8px; right: 8px; border-width: 1px 1px 0 0; }
.scope .bl { bottom: 8px; left: 8px; border-width: 0 0 1px 1px; }
.scope .br { bottom: 8px; right: 8px; border-width: 0 1px 1px 0; }
.scope .sweep {
  position: absolute; left: 0; right: 0; height: 2px; top: -4px;
  background: var(--green); box-shadow: 0 0 14px 3px rgba(57,255,136,.55);
  opacity: 0; pointer-events: none;
}
.scope.lock .sweep { animation: sweep 1.3s cubic-bezier(.4,0,.2,1) 1; }
.scope .frame img { filter: contrast(1.05); transition: filter .9s ease, opacity .9s ease; }
.scope:not(.lock) .frame img { filter: blur(6px) contrast(1.6) brightness(.6); opacity: .65; }
@keyframes sweep { 0% { top: -4px; opacity: 1; } 90% { opacity: 1; } 100% { top: 100%; opacity: 0; } }
figcaption { padding: 14px 16px; border-top: 1px solid var(--line); background: var(--ink-2); }
figcaption p { margin: 0 0 6px !important; font-size: 15px; color: #C9CDD2 !important; }
.credit { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .03em; color: var(--muted); }
.credit b { color: var(--green); font-weight: 500; }

.photos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 4px 0 28px; }
.photos figure { margin: 0; border: 1px solid var(--line); background: var(--ink-2); display: flex; flex-direction: column; }
.photos img { aspect-ratio: 3 / 2; object-fit: cover; width: 100%; height: auto; }
.photos figcaption { border-top: 1px solid var(--line); padding: 10px 12px; font-size: 14px; color: #C9CDD2; flex: 1; }
@media (max-width: 860px) { .photos { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .photos { grid-template-columns: 1fr; } }

/* references */
.refs { counter-reset: ref; padding: 0; list-style: none; }
.refs li { counter-increment: ref; padding-left: 40px !important; font-size: 14.5px; color: #B9BEC4 !important; }
.refs li::before { content: "[" counter(ref) "]" !important; background: none !important; width: auto !important; height: auto !important; top: 0 !important; left: 0 !important; font-family: var(--font-mono); font-size: 12px; color: var(--green); }

/* prev/next + disclaimer */
.disclaimer {
  border: 1px solid var(--line); border-left: 3px solid var(--orange);
  padding: 16px 18px; font-size: 14.5px; color: #B9BEC4; margin-top: 8px;
}
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 40px; }
.pager a {
  border: 1px solid var(--line); padding: 16px 18px; text-decoration: none; color: var(--paper);
  font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 75; font-size: 22px; text-transform: uppercase;
}
.pager a span { display: block; font-family: var(--font-mono); font-weight: 400; font-size: 11px; letter-spacing: .1em; color: var(--muted); margin-bottom: 4px; }
.pager a:hover { border-color: var(--green); }
.pager .next { text-align: right; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding: 48px var(--gutter) 24px; overflow: hidden; }
.site-footer .inner { max-width: var(--max); margin: 0 auto; }
.foot-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 32px; margin-bottom: 24px; }
.foot-row a { font-family: var(--font-mono); font-size: 13px; }
.foot-name {
  font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 75;
  font-size: clamp(56px, 15.5vw, 230px); line-height: .8; letter-spacing: -.03em; text-transform: uppercase;
  color: var(--paper); margin: 0; white-space: nowrap;
}
.foot-name em { font-style: normal; color: var(--green); }
.foot-small { font-family: var(--font-mono); font-size: 11.5px; color: #5A606A; margin-top: 18px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .scope:not(.lock) .frame img { filter: none; opacity: 1; }
}

/* illustration legend */
.legend { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 20px; margin: 10px 0 12px; }
.legend div { display: flex; gap: 10px; font-size: 14px; line-height: 1.4; }
.legend dt { font-family: var(--font-mono); font-size: 12.5px; color: var(--green); flex: none; min-width: 64px; }
.legend dd { margin: 0; color: #C9CDD2; }
@media (max-width: 560px) { .legend { grid-template-columns: 1fr; } }

/* ---------- Education library ---------- */
.lib-hero .inner { grid-template-columns: 1fr; }
.lib-jump { display: flex; flex-wrap: wrap; gap: 8px; max-width: var(--max, 1200px); margin: 24px auto 0; padding: 0 var(--gutter, 24px) 32px; }
.lib-jump a { font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--paper); text-decoration: none; border: 1px solid var(--line); padding: 8px 12px; }
.lib-jump a:hover, .lib-jump a:focus-visible { border-color: var(--green); color: var(--green); }
.lib-jump span { color: var(--muted); margin-left: 6px; }
.lib-group { padding: 48px 0 16px; border-top: 1px solid var(--line); scroll-margin-top: 106px; }
.lib-h { font-family: var(--font-display); font-weight: 800; font-size: clamp(28px, 4vw, 44px); margin: 0 0 24px; display: flex; gap: 14px; align-items: baseline; }
.lib-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.lib-card a { display: flex; flex-direction: column; height: 100%; border: 1px solid var(--line); background: var(--ink-2); color: var(--paper); text-decoration: none; transition: border-color .2s; }
.lib-card a:hover, .lib-card a:focus-visible { border-color: var(--green); }
.lib-card img { width: 100%; height: auto; aspect-ratio: 1000 / 620; object-fit: cover; background: #000; border-bottom: 1px solid var(--line); }
.lib-meta { display: flex; justify-content: space-between; padding: 12px 14px 0; font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; }
.lib-code { color: var(--green); }
.lib-draft { color: var(--orange, #FF8A00); }
.lib-title { padding: 6px 14px 16px; font-family: var(--font-display); font-weight: 700; font-size: 19px; line-height: 1.2; }
.lib-soon { color: var(--muted); font-family: var(--font-mono); font-size: 13px; }
@media (prefers-reduced-motion: reduce) { .lib-card a { transition: none; } }
.lib-group .inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.lib-jump { max-width: var(--max); padding: 0 var(--gutter) 32px; }
.lib-h .label { font-size: 12px; }

/* Home page */
.home-cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 0; }
.btn { display: inline-block; font-family: var(--font-mono); font-size: 13px; text-transform: uppercase; letter-spacing: .08em; text-decoration: none; padding: 12px 18px; background: var(--green); color: var(--ink); border: 1px solid var(--green); }
.btn:hover, .btn:focus-visible { background: transparent; color: var(--green); }
.btn-ghost { background: transparent; color: var(--paper); border-color: var(--line); }
.btn-ghost:hover, .btn-ghost:focus-visible { border-color: var(--green); }
.home-sec { border-top: 1px solid var(--line); padding: 56px 0; }
.home-sec .inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.home-sec p { max-width: 70ch; color: #C9CDD2; }
.home-sec a { color: var(--green); }
.home-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.home-cols p { margin: 0; }
.event { display: grid; grid-template-columns: 140px 1fr; gap: 32px; border: 1px solid var(--line); background: var(--ink-2); padding: 28px; }
.event-date { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; color: var(--muted); border-right: 1px solid var(--line); }
.event-date strong { font-family: var(--font-display); font-size: 64px; line-height: 1; color: var(--paper); }
.event h3 { font-family: var(--font-display); font-size: clamp(22px, 2.4vw, 30px); margin: 0 0 8px; }
.event-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 20px 0 0; }
.event-facts div { border-top: 1px solid var(--line); padding-top: 8px; }
.event-facts dt { font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.event-facts dd { margin: 4px 0 0; }
.event .btn { color: var(--ink); }
.event .btn:hover, .event .btn:focus-visible { color: var(--green); }
@media (max-width: 760px) {
  .home-cols { grid-template-columns: 1fr; }
  .event { grid-template-columns: 1fr; gap: 16px; padding: 20px; }
  .event-date { flex-direction: row; align-items: baseline; gap: 10px; border-right: 0; border-bottom: 1px solid var(--line); padding-bottom: 12px; }
  .event-date strong { font-size: 40px; }
  .event-facts { grid-template-columns: 1fr 1fr; }
}

/* Home v2: announcement, hero slider, stats, pillars, carousel, ticker, countdown, contact */
.announce { display: block; text-align: center; background: var(--green); color: var(--ink); font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; padding: 9px var(--gutter); text-decoration: none; }
.announce:hover, .announce:focus-visible { background: var(--paper); }
.announce-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--red); margin-right: 8px; vertical-align: 1px; animation: blink 1.4s infinite; }
@keyframes blink { 50% { opacity: .2; } }

.hero-slider { position: relative; height: min(86vh, 760px); min-height: 520px; overflow: hidden; background: var(--ink); border-bottom: 1px solid var(--line); }
.hs-slide { position: absolute; inset: 0; opacity: 0; visibility: hidden; transition: opacity 1s ease, visibility 0s linear 1s; }
.hs-slide.is-active { opacity: 1; visibility: visible; transition: opacity 1s ease; z-index: 1; }
.hs-media { position: absolute; inset: 0; }
.hs-media img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(.35) contrast(1.05) brightness(.8); transform: scale(1.12); }
.hs-slide.is-active .hs-media img { animation: kenburns 9s ease-out forwards; }
.hs-illus { background: #121212; display: flex; align-items: center; justify-content: flex-end; }
.hs-illus img { width: min(70%, 980px); height: auto; object-fit: contain; filter: none; margin-right: var(--gutter); }
@keyframes kenburns { from { transform: scale(1.12) translate(1%, 1%); } to { transform: scale(1.0) translate(0, 0); } }
.hs-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(8,9,11,.92) 0%, rgba(8,9,11,.7) 45%, rgba(8,9,11,.15) 100%), linear-gradient(0deg, rgba(8,9,11,.85), transparent 40%); }
.hs-text { position: absolute; left: 0; right: 0; bottom: 96px; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.hs-text > * { max-width: 640px; }
.hs-slide .hs-text > * { opacity: 0; transform: translateY(24px); }
.hs-slide.is-active .hs-text > * { opacity: 1; transform: none; transition: opacity .8s ease, transform .8s cubic-bezier(.2,.8,.2,1); }
.hs-slide.is-active .hs-text > *:nth-child(2) { transition-delay: .15s; }
.hs-slide.is-active .hs-text > *:nth-child(3) { transition-delay: .3s; }
.hs-slide.is-active .hs-text > *:nth-child(4) { transition-delay: .45s; }
.hs-title { font-family: var(--font-display); font-stretch: 75%; font-weight: 800; text-transform: uppercase; font-size: clamp(40px, 6.4vw, 92px); line-height: .92; letter-spacing: -.01em; margin: 14px 0 16px; }
.hs-sub { font-size: clamp(17px, 1.6vw, 21px); color: #D6D9DD; margin: 0; }
.hs-scan { position: absolute; left: 0; right: 0; top: 0; height: 2px; background: var(--green); box-shadow: 0 0 18px var(--green); opacity: 0; z-index: 2; pointer-events: none; }
.hero-slider.sweep .hs-scan { animation: scan 1.6s ease-in-out; }
@keyframes scan { 0% { top: 0; opacity: .9; } 100% { top: 100%; opacity: 0; } }
.hs-controls { position: absolute; left: 0; right: 0; bottom: 28px; z-index: 3; display: flex; align-items: center; gap: 12px; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.hs-controls button, .car-controls button { background: rgba(8,9,11,.6); color: var(--paper); border: 1px solid var(--line); font-family: var(--font-mono); font-size: 14px; min-width: 44px; height: 44px; cursor: pointer; }
.hs-controls button:hover, .car-controls button:hover, .hs-controls button:focus-visible, .car-controls button:focus-visible { border-color: var(--green); color: var(--green); }
.hs-dots { display: flex; gap: 8px; }
.hs-dots button { min-width: 0; width: 34px; height: 44px; padding: 0; background: none; border: 0; position: relative; }
.hs-dots button::after { content: ""; position: absolute; left: 0; right: 0; top: 21px; height: 3px; background: var(--line); }
.hs-dots button[aria-current="true"]::after { background: var(--green); box-shadow: 0 0 8px var(--green); }

.stats { border-bottom: 1px solid var(--line); padding: 40px 0 0; }
.stats-row { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stats-row div { border-left: 1px solid var(--line); padding-left: 16px; }
.stats-row strong { display: block; font-family: var(--font-display); font-size: clamp(40px, 5vw, 72px); line-height: 1; color: var(--green); }
.stats-row span { font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.stats .lib-jump { margin-top: 32px; }

.about-lead { font-size: clamp(20px, 2.2vw, 28px); line-height: 1.35; color: var(--paper) !important; max-width: 46ch !important; margin: 0 0 36px; }
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.pillar { border: 1px solid var(--line); background: var(--ink-2); padding: 24px; transition: border-color .3s, transform .3s; }
.pillar:hover { border-color: var(--green); transform: translateY(-4px); }
.pillar h3 { font-family: var(--font-display); font-size: 24px; margin: 10px 0 8px; }
.pillar p { margin: 0; }
.about-note { margin-top: 24px; font-size: 14px; }

.reveal { opacity: 0; transform: translateY(28px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.8,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.pillars .reveal:nth-child(2) { transition-delay: .12s; }
.pillars .reveal:nth-child(3) { transition-delay: .24s; }

.gallery { padding-bottom: 40px; }
.car-track { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px var(--gutter) 16px; scrollbar-width: none; }
.car-track::-webkit-scrollbar { display: none; }
.car-item { flex: 0 0 min(78vw, 520px); margin: 0; scroll-snap-align: start; position: relative; overflow: hidden; border: 1px solid var(--line); background: #000; }
.car-item img { width: 100%; height: 360px; object-fit: cover; display: block; transition: transform 1.2s ease; filter: saturate(.85); }
.car-item:hover img { transform: scale(1.06); }
.car-item figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 28px 16px 12px; background: linear-gradient(0deg, rgba(8,9,11,.9), transparent); font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.car-controls { display: flex; gap: 8px; max-width: var(--max); margin: 8px auto 0; padding: 0 var(--gutter); }

.event-sec { padding-top: 0; }
.ticker { overflow: hidden; border-bottom: 1px solid var(--line); background: var(--ink-2); margin-bottom: 56px; }
.ticker-track { display: flex; width: max-content; animation: ticker 40s linear infinite; }
.ticker-track span { font-family: var(--font-mono); font-size: 13px; text-transform: uppercase; letter-spacing: .1em; color: var(--paper); padding: 14px 28px; white-space: nowrap; }
.ticker-track span::before { content: "◆"; color: var(--green); margin-right: 28px; }
@keyframes ticker { to { transform: translateX(-50%); } }
.event h3 a { color: var(--paper); text-decoration: none; }
.event h3 a:hover { color: var(--green); }
.event-tag { display: inline-block; font-family: var(--font-mono); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; background: var(--red); color: #fff; padding: 4px 8px; margin-bottom: 10px; }
.countdown { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 20px 0 8px; max-width: 520px; }
.countdown div { border: 1px solid var(--line); background: var(--ink); text-align: center; padding: 12px 4px; }
.countdown strong { display: block; font-family: var(--font-mono); font-size: clamp(26px, 3.4vw, 40px); color: var(--green); font-variant-numeric: tabular-nums; }
.countdown span { font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.event-points { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 6px; }
.event-points li::before { content: "→ "; color: var(--green); }
.btn-pulse { animation: pulse 2.2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(57,255,136,.55); } 70% { box-shadow: 0 0 0 14px rgba(57,255,136,0); } 100% { box-shadow: 0 0 0 0 rgba(57,255,136,0); } }

.contact-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 48px; }
.contact-form { display: grid; gap: 16px; max-width: 640px; }
.contact-form label { display: grid; gap: 6px; font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.contact-form input, .contact-form select, .contact-form textarea { font: inherit; font-family: var(--font-body); font-size: 16px; text-transform: none; letter-spacing: 0; color: var(--paper); background: var(--ink-2); border: 1px solid var(--line); padding: 12px; border-radius: var(--radius); }
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus { outline: 2px solid var(--green); outline-offset: 1px; }
.contact-form .btn { border: 0; cursor: pointer; }
.hp { position: absolute; left: 0; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.contact-side .label { margin: 0 0 6px; font-size: 12px; }
.contact-side p { margin: 0 0 24px; }
.contact-side a, .contact-band a:not(.btn) { color: var(--green); }

@media (max-width: 860px) {
  .stats-row { grid-template-columns: 1fr 1fr; row-gap: 24px; }
  .pillars { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .hs-illus { justify-content: center; align-items: flex-start; padding-top: 24px; }
  .hs-illus img { width: 92%; margin: 0; }
  .car-item img { height: 260px; }
}
@media (max-width: 560px) {
  .hero-slider { height: 88vh; min-height: 560px; }
  .hs-text { bottom: 88px; }
  .hs-shade { background: linear-gradient(0deg, rgba(8,9,11,.96) 0%, rgba(8,9,11,.75) 55%, rgba(8,9,11,.3) 100%); }
  .countdown { gap: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  .hs-slide, .hs-slide .hs-text > *, .reveal { transition: none !important; }
  .hs-slide.is-active .hs-media img { animation: none; transform: none; }
  .hs-slide .hs-text > * { opacity: 1; transform: none; }
  .ticker-track, .btn-pulse, .announce-dot { animation: none; }
  .reveal { opacity: 1; transform: none; }
  .car-item img, .pillar { transition: none; }
}
.event .btn-ghost { color: var(--paper); }
.announce:hover, .announce:focus-visible { color: var(--ink); }
.home-sec .btn, .contact-band .btn, .hero-slider .btn { color: var(--ink); }
.home-sec .btn:hover, .home-sec .btn:focus-visible, .hero-slider .btn:hover, .hero-slider .btn:focus-visible { color: var(--green); }
.home-sec .btn-ghost, .hero-slider .btn-ghost { color: var(--paper); }
.btn:hover { text-decoration: none; }

/* ---------- Video demonstrations ---------- */
.videos { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); margin: 8px 0 12px; }
.video { margin: 0; border: 1px solid var(--line); background: var(--ink-2); }
.video-media { position: relative; aspect-ratio: 16 / 9; background: #000; }
.video-media img, .video-media iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; display: block; }
.video-play { position: absolute; inset: 0; display: block; }
.video-play:hover img { filter: brightness(1.12); }
.video-play:focus-visible { outline: 2px solid var(--green); outline-offset: -2px; }
.video figcaption { padding: 12px 14px 14px; font-family: var(--font-display); font-weight: 700; font-size: 17px; line-height: 1.25; color: var(--paper); }
.video figcaption .label { display: block; margin-bottom: 4px; font-family: var(--font-mono); font-weight: 500; font-size: 11px; letter-spacing: .08em; color: var(--green); }
.video-note { font-family: var(--font-mono); font-size: 11.5px; color: var(--muted); }

/* ---------- Spot the structure quiz ---------- */
.quiz { margin: 12px 0 4px; }
.quiz-start { border: 0; cursor: pointer; }
.quiz-bar { font-family: var(--font-mono); font-size: 14px; line-height: 1.5; color: var(--paper); }
.quiz-bar:not(:empty) { margin-top: 10px; padding: 12px 14px; border: 1px solid var(--line); background: var(--ink-2); }
.quiz-bar .qn { display: block; font-size: 11px; letter-spacing: .08em; color: var(--muted); text-transform: uppercase; margin-bottom: 4px; }
.quiz-bar strong { color: var(--green); }
.quiz-bar .bad { color: #FF8A8A; }
.quiz-bar .row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.quiz-bar button { font: 600 12px var(--font-mono); letter-spacing: .06em; text-transform: uppercase; padding: 8px 12px; border: 1px solid var(--line); background: transparent; color: var(--paper); cursor: pointer; border-radius: var(--radius); }
.quiz-bar button.primary { background: var(--green); color: var(--ink); border-color: var(--green); }
.quiz-bar button:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.scope.quizzing .frame { cursor: crosshair; outline: 2px solid var(--green); outline-offset: -2px; }
.scope.quizzing .sweep { display: none; }
.quiz-mark { position: absolute; width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%; pointer-events: none; }
.quiz-mark.tap { width: 14px; height: 14px; margin: -7px 0 0 -7px; background: #FF3B3B; box-shadow: 0 0 0 3px rgba(0,0,0,.6); }
.quiz-mark.tap.ok { background: var(--green); }
.quiz-mark.answer { border: 3px solid var(--green); box-shadow: 0 0 0 3px rgba(0,0,0,.6), 0 0 16px rgba(57,255,136,.7); }

/* Theatre card link on block pages */
.card-link { margin: 18px 0 0; }

/* Block finder by operation (Education page) */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.finder { padding: 48px 0 24px; border-top: 1px solid var(--line); scroll-margin-top: 106px; }
.finder .inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.finder-intro { color: var(--muted); max-width: 760px; margin: -8px 0 24px; }
.lib-jump a.lib-jump-finder { border-color: var(--green); color: var(--green); }
.finder-tools { display: flex; flex-direction: column; gap: 14px; margin-bottom: 28px; }
.finder-search input { width: 100%; max-width: 640px; font: inherit; font-size: 18px; color: var(--paper); background: var(--ink-2); border: 1px solid var(--line); padding: 14px 16px; border-radius: var(--radius); }
.finder-search input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px var(--green-dim); }
.finder-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.finder-chips .chip { font-family: var(--font-mono); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--paper); background: transparent; border: 1px solid var(--line); padding: 8px 12px; cursor: pointer; }
.finder-chips .chip:hover { border-color: var(--green); }
.finder-chips .chip[aria-pressed="true"] { background: var(--green); color: var(--ink); border-color: var(--green); }
.finder-none { color: var(--orange); }
.finder-area { margin-bottom: 28px; }
.finder-area-h { font-family: var(--font-mono); font-size: 13px; text-transform: uppercase; letter-spacing: .1em; color: var(--green); margin: 0 0 12px; font-weight: 600; }
.finder-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.op { border: 1px solid var(--line); background: var(--ink-2); padding: 18px 18px 14px; display: flex; flex-direction: column; gap: 10px; }
.op-name { margin: 0; font-family: var(--font-display); font-size: 20px; line-height: 1.2; font-weight: 700; }
.op-row { display: grid; grid-template-columns: 112px 1fr; gap: 10px; align-items: start; }
.op-tag { font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); padding-top: 5px; }
.op-tag.first { color: var(--green); }
.op-blocks { display: flex; flex-wrap: wrap; gap: 6px; }
.op-blocks a { font-size: 14px; line-height: 1.3; color: var(--paper); text-decoration: none; border: 1px solid var(--line); padding: 4px 8px; }
.op-row:has(.first) .op-blocks a { border-color: var(--green); color: var(--green); }
.op-blocks a:hover, .op-blocks a:focus-visible { background: var(--green); color: var(--ink); border-color: var(--green); }
.op-note { margin: 0; font-size: 15px; line-height: 1.5; }
.op-ev { margin: auto 0 0; padding-top: 8px; border-top: 1px dashed var(--line); font-size: 13px; color: var(--muted); display: flex; align-items: baseline; gap: 8px; }
.op-ev a { color: var(--green); }
.ev-dot { flex: 0 0 auto; width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid var(--muted); transform: translateY(-1px); }
.ev-dot.yes { background: var(--green); border-color: var(--green); }
@media (max-width: 520px) {
  .finder-grid { grid-template-columns: 1fr; }
  .op-row { grid-template-columns: 1fr; gap: 4px; }
  .op-tag { padding-top: 0; }
}
.finder [hidden] { display: none !important; }

/* Education drop-down menu */
.nav { align-items: center; }
.nav-item { position: relative; }
.nav-item > a { display: block; }
.nav-sub { display: none; position: absolute; top: 100%; left: 0; min-width: 220px; padding: 8px 0; background: var(--ink-2); border: 1px solid var(--line); box-shadow: 0 16px 32px rgba(0,0,0,.45); z-index: 50; }
.nav-sub a { display: block; padding: 10px 16px; white-space: nowrap; }
.nav-sub a:hover, .nav-sub a:focus-visible { color: var(--green); background: var(--grid); }
.has-sub > a::after { content: ""; display: inline-block; margin-left: 6px; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-3px) rotate(45deg); }
.has-sub:hover .nav-sub, .has-sub:focus-within .nav-sub { display: block; }
@media (max-width: 1100px) {
  .nav { align-items: stretch; }
  .has-sub > a::after { display: none; }
  .nav-sub { display: block; position: static; min-width: 0; padding: 0 0 6px 16px; background: none; border: 0; box-shadow: none; }
  .nav-sub a { padding: 10px 0; font-size: 14px; border-bottom: 1px solid var(--grid); }
}

/* Region tiles on the Education page */
.regions { padding: 40px 0 8px; }
.regions .inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.region-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.region-tile a { display: flex; flex-direction: column; height: 100%; border: 1px solid var(--line); background: var(--ink-2); color: var(--paper); text-decoration: none; transition: border-color .2s, transform .2s; }
.region-tile a:hover, .region-tile a:focus-visible { border-color: var(--green); transform: translateY(-2px); }
.region-tile img { width: 100%; height: auto; display: block; border-bottom: 1px solid var(--line); }
.region-body { display: flex; flex-direction: column; gap: 6px; padding: 16px; }
.region-count { font-family: var(--font-mono); font-size: 12px; letter-spacing: .1em; color: var(--green); }
.region-name { font-family: var(--font-display); font-size: 26px; font-weight: 800; line-height: 1.1; }
.region-list { font-size: 14px; color: var(--muted); line-height: 1.45; }
.lib-jump a[aria-current="page"] { border-color: var(--green); background: var(--green); color: var(--ink); }
.lib-jump a[aria-current="page"] span { color: var(--ink); }

/* Useful resources page */
.res-jump { padding-top: 24px; }
.res-sec { padding: 48px 0 24px; border-top: 1px solid var(--line); scroll-margin-top: 106px; }
.res-sec .inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.res-intro { color: var(--muted); max-width: 820px; margin: -8px 0 24px; }
.proto-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); align-items: start; }
.proto { --tone: var(--green); border: 1px solid var(--line); border-top: 4px solid var(--tone); background: var(--ink-2); padding: 20px; scroll-margin-top: 114px; }
.proto.tone-red { --tone: var(--red); }
.proto.tone-orange { --tone: var(--orange); }
.proto-k { font-family: var(--font-mono); font-size: 12px; letter-spacing: .1em; color: var(--tone); font-weight: 600; }
.proto h3 { font-family: var(--font-display); font-size: 24px; line-height: 1.15; margin: 6px 0 10px; }
.proto-when { font-size: 15px; color: var(--muted); margin: 0 0 12px; }
.proto-when b { color: var(--paper); }
.proto ol { margin: 0 0 12px; padding-left: 20px; }
.proto li { margin-bottom: 8px; font-size: 15px; line-height: 1.5; }
.proto li::marker { color: var(--tone); font-family: var(--font-mono); font-weight: 600; }
.proto-src { font-size: 13px; color: var(--muted); margin: 12px 0 0; padding-top: 10px; border-top: 1px dashed var(--line); }
.proto-src a { color: var(--green); }
.ac-rules { margin: 0 0 24px; padding-left: 20px; max-width: 900px; }
.ac-rules li { margin-bottom: 6px; }
.ac-group { font-family: var(--font-mono); font-size: 13px; text-transform: uppercase; letter-spacing: .1em; color: var(--green); margin: 28px 0 10px; }
.ac-table { width: 100%; }
.ac-table th[scope="row"] { text-align: left; font-weight: 650; width: 26%; }
.ac-table td, .ac-table th { vertical-align: top; }
.soc-grid, .pro-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.soc, .pro { display: flex; flex-direction: column; height: 100%; border: 1px solid var(--line); background: var(--ink-2); color: var(--paper); text-decoration: none; transition: transform .2s, border-color .2s; }
.soc:hover, .soc:focus-visible, .pro:hover, .pro:focus-visible { transform: translateY(-3px); border-color: var(--c1); }
.soc-thumb, .pro-thumb { position: relative; display: flex; aspect-ratio: 16 / 9; overflow: hidden;
  background: radial-gradient(circle at 85% 15%, rgba(255,255,255,.35) 0, transparent 40%), linear-gradient(125deg, var(--c1), var(--c2)); }
.soc-thumb::before, .pro-thumb::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.25) 1.5px, transparent 2px); background-size: 16px 16px; }
.soc-abbr { position: relative; margin: auto; font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 80; font-size: clamp(34px, 5vw, 48px); color: #fff; letter-spacing: -.01em; text-shadow: 0 3px 0 rgba(0,0,0,.18); }
.soc-body { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px 16px; }
.soc-name { font-weight: 700; line-height: 1.25; }
.soc-what { font-size: 14px; color: var(--muted); line-height: 1.45; }
.pro-thumb { flex-direction: column; justify-content: space-between; padding: 14px; color: #fff; }
.pro-area { position: relative; align-self: flex-start; font-family: var(--font-mono); font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; background: rgba(255,255,255,.92); color: #111; padding: 4px 8px; border-radius: 999px; }
.pro-op { position: relative; font-family: var(--font-display); font-weight: 800; font-size: 22px; line-height: 1.05; text-transform: uppercase; font-variation-settings: "wdth" 80; text-shadow: 0 2px 0 rgba(0,0,0,.18); }
.pro-tag { position: relative; font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em; opacity: .9; }
.pro-body { padding: 14px 16px 16px; font-size: 14px; line-height: 1.5; }
@media (max-width: 520px) {
  .proto-grid { grid-template-columns: 1fr; }
  .soc-grid, .pro-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .pro-op { font-size: 17px; }
  .soc-body, .pro-body { padding: 10px 12px 12px; }
}
.pro-thumb { aspect-ratio: 4 / 3; }
@media (min-width: 1100px) { .region-grid { grid-template-columns: repeat(5, 1fr); } }

/* Useful resources overview tiles */
.res-hub { border-top: 0; }
.hub-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.hub { display: flex; flex-direction: column; height: 100%; border: 1px solid var(--line); background: var(--ink-2); color: var(--paper); text-decoration: none; transition: transform .2s, border-color .2s; }
.hub:hover, .hub:focus-visible { transform: translateY(-3px); border-color: var(--c1); }
.hub-thumb { position: relative; display: flex; flex-direction: column; justify-content: space-between; aspect-ratio: 16 / 10; padding: 18px; color: #fff; overflow: hidden;
  background: radial-gradient(circle at 85% 15%, rgba(255,255,255,.35) 0, transparent 40%), linear-gradient(125deg, var(--c1), var(--c2)); }
.hub-thumb::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.25) 1.5px, transparent 2px); background-size: 16px 16px; }
.hub-k { position: relative; align-self: flex-start; font-family: var(--font-mono); font-size: 12px; font-weight: 600; letter-spacing: .08em; background: rgba(255,255,255,.92); color: #111; padding: 4px 10px; border-radius: 999px; }
.hub-name { position: relative; font-family: var(--font-display); font-weight: 800; font-size: 30px; line-height: 1; text-transform: uppercase; font-variation-settings: "wdth" 80; text-shadow: 0 3px 0 rgba(0,0,0,.18); }
.hub-body { padding: 16px; font-size: 15px; line-height: 1.5; }
.res-jump { max-width: var(--max); }

/* Sixth Education tile: block finder */
.region-finder .finder-art { display: flex; align-items: center; justify-content: center; aspect-ratio: 1000 / 620; border-bottom: 1px solid var(--line);
  background: radial-gradient(circle at 80% 20%, rgba(255,255,255,.3) 0, transparent 45%), linear-gradient(125deg, #39FF88, #00A3FF); }
.region-finder .finder-art span { font-family: var(--font-display); font-weight: 800; font-size: 96px; line-height: 1; color: #08090B; opacity: .85; }
.region-finder a { border-color: var(--green); }
@media (min-width: 1100px) { .region-grid { grid-template-columns: repeat(3, 1fr); } }
.finder { border-top: 0; }

/* Orange icons on the block finder boxes */
.op-head { display: flex; align-items: center; gap: 14px; }
.op-icon { flex: 0 0 auto; width: 44px; height: 44px; padding: 6px; color: var(--orange); background: rgba(255,138,61,.1); border: 1px solid rgba(255,138,61,.45); border-radius: 50%;
  fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* PROSPECT cards: plain dark card, simple icon in the card's colour (no bright gradient) */
.pro-thumb { aspect-ratio: auto; min-height: 0; display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto auto; column-gap: 14px; row-gap: 8px; align-items: center;
  padding: 16px 16px 12px; color: var(--paper); background: none; border-bottom: 1px dashed var(--line); }
.pro-thumb::before { display: none; }
.pro-icon { grid-row: 1 / span 2; width: 52px; height: 52px; padding: 7px; color: var(--c1); border: 1.5px solid var(--c1); border-radius: 50%;
  fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.pro-area { align-self: end; background: none; color: var(--c1); padding: 0; border-radius: 0; }
.pro-op { align-self: start; font-size: 19px; text-transform: none; font-variation-settings: normal; font-weight: 700; line-height: 1.2; text-shadow: none; }
.pro-tag { grid-column: 1 / -1; color: var(--muted); opacity: 1; }
@media (max-width: 520px) { .pro-icon { width: 42px; height: 42px; } .pro-op { font-size: 16px; } .pro-grid { grid-template-columns: 1fr; } }

/* Anticoagulation: each drug group in a box with an icon */
.ac-box { border: 1px solid var(--line); background: var(--ink-2); padding: 18px 18px 8px; margin: 0 0 18px; }
.ac-box .ac-group { display: flex; align-items: center; gap: 14px; margin: 0 0 12px; }
.ac-icon { flex: 0 0 auto; width: 44px; height: 44px; padding: 6px; color: var(--orange); background: rgba(255,138,61,.1); border: 1px solid rgba(255,138,61,.45); border-radius: 50%;
  fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.pro-thumb { grid-template-columns: auto minmax(0, 1fr); }
.pro-op { font-size: 17px; hyphens: auto; overflow-wrap: break-word; }

/* Social links in the footer, in each platform's own colours */
.foot-social { list-style: none; display: flex; gap: 12px; margin: 0 0 22px; padding: 0; }
.foot-social .soc { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; color: #fff; transition: transform .15s ease, box-shadow .15s ease; }
.foot-social .soc svg { width: 22px; height: 22px; }
.foot-social .soc:hover, .foot-social .soc:focus-visible { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,.45); }
.soc-x { background: #000; border: 1px solid #3a3f47; }
.soc-yt { background: #FF0033; }
.soc-ig { background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%); }

/* Ultrasound scan behind the illustration (switch: SCANS_ON in build.py, or "Show ultrasound scans" in WordPress) */
.scope.has-scan .frame > img:first-child { position: relative; z-index: 1; transition: clip-path 1.3s cubic-bezier(.4,0,.2,1), opacity .35s ease, filter .9s ease; }
.scope.has-scan.scan-wait:not(.ill-on) .frame > img:first-child { clip-path: inset(0 0 100% 0); }
.scope .frame img.scan { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #000; z-index: 0; }
.scope.has-scan .tick, .scope.has-scan .sweep { z-index: 2; }
.scope.has-scan.scan-wait.lock:not(.ill-on) .sweep { animation: none; }
.scope.has-scan.ill-on .sweep { animation: sweep 1.3s cubic-bezier(.4,0,.2,1) 1; }
.scope.has-scan.show-scan .frame > img:first-child { opacity: 0; }
@media (hover: hover) {
  .scope.has-scan:not(.quizzing):not(.no-hover) .frame:hover > img:first-child { opacity: 0; }
}
.scan-flip {
  position: absolute; right: 30px; top: 12px; z-index: 3;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .03em;
  color: var(--green); background: rgba(10,12,14,.78); border: 1px solid var(--green);
  border-radius: 999px; padding: 5px 12px; cursor: pointer;
}
.scan-flip:hover, .scan-flip:focus-visible { background: var(--green); color: #0A0C0E; }
.scope.quizzing .scan-flip { display: none; }
.credit-scan { margin-top: 4px; }
.nb-noscan .scope .scan, .nb-noscan .scan-flip, .nb-noscan .credit-scan { display: none !important; }
.nb-noscan .scope.has-scan .frame > img:first-child { clip-path: none !important; opacity: 1 !important; }

/* Scan explorer: named dots on the scan, shown only while the scan is visible */
.scan-spots { position: absolute; inset: 0; z-index: 2; opacity: 0; pointer-events: none; transition: opacity .3s ease; }
.scope.has-scan.ill-on.show-scan .scan-spots { opacity: 1; pointer-events: auto; }
@media (hover: hover) { .scope.has-scan.ill-on:not(.no-hover):not(.quizzing) .frame:hover .scan-spots { opacity: 1; pointer-events: auto; } }
.spot { position: absolute; width: 22px; height: 22px; margin: -11px 0 0 -11px; padding: 0; border: 0; background: none; cursor: pointer; }
.spot::before { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 2px rgba(10,12,14,.8), 0 0 10px rgba(57,255,136,.8); }
.spot-tag { position: absolute; left: 20px; top: 50%; transform: translateY(-50%); white-space: nowrap;
  font-family: var(--font-mono); font-size: 12px; color: var(--paper); background: rgba(10,12,14,.92);
  border: 1px solid var(--green); border-radius: 4px; padding: 3px 8px; opacity: 0; pointer-events: none; transition: opacity .15s; }
.spot-tag b { color: var(--green); font-weight: 500; margin-right: 4px; }
.spot.left .spot-tag { left: auto; right: 20px; }
.spot:hover .spot-tag, .spot:focus-visible .spot-tag, .spot.on .spot-tag { opacity: 1; }
.spot:hover, .spot.on { z-index: 3; }

/* Local anaesthetic dose calculator */
.dose-calc { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; margin: 8px 0 32px; }
.dose-form { display: grid; gap: 14px; }
.dose-form label, .dose-sex legend { display: grid; gap: 6px; font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .03em; color: var(--muted); }
.dose-form small { color: #6B717A; font-size: 11px; }
.dose-form input[type=number], .dose-form select {
  font: inherit; font-family: var(--font-body, inherit); font-size: 16px; color: var(--paper); background: var(--ink-2);
  border: 1px solid var(--line); border-radius: 6px; padding: 10px 12px; width: 100%; box-sizing: border-box; }
.dose-form input:focus, .dose-form select:focus { outline: 2px solid var(--green); outline-offset: 1px; }
.dose-sex { border: 0; padding: 0; margin: 0; display: flex; gap: 18px; flex-wrap: wrap; align-items: center; }
.dose-sex legend { margin-bottom: 6px; width: 100%; }
.dose-sex label, .dose-check { display: flex !important; align-items: center; gap: 8px; color: var(--paper) !important; font-size: 14px !important; }
.dose-check { align-items: flex-start !important; }
.dose-out { background: var(--ink-2); border: 1px solid var(--line); border-radius: 10px; padding: 20px; align-self: start; }
.dose-empty { color: var(--muted); margin: 0; }
.dose-big { display: grid; gap: 2px; margin-bottom: 16px; }
.dose-big span:last-child { font-family: var(--font-display, inherit); font-size: 34px; line-height: 1.1; color: var(--green); }
.dose-k { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.dose-plan { display: grid; gap: 6px; margin: 4px 0 14px; color: var(--paper); }
.dose-bar { display: block; height: 8px; border-radius: 4px; background: #23272D; overflow: hidden; }
.dose-bar i { display: block; height: 100%; background: var(--green); transition: width .3s ease; }
.dose-plan.near .dose-bar i { background: var(--orange); }
.dose-plan.over .dose-bar i { background: #FF4D4D; }
.dose-plan.over #dc-plan-txt { color: #FF8A8A; }
.dose-how { font-size: 14px; color: #C9CDD2; margin: 0; }
.dose-h { margin-top: 8px; }
@media (max-width: 760px) { .dose-calc { grid-template-columns: 1fr; } }
.dose-check small { display: block; margin-top: 2px; }
.dose-mix { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px 14px; margin: 0; display: grid; gap: 12px; }
.dose-mix[hidden] { display: none; }
.dose-mix legend { font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--green); padding: 0 6px; }
.dose-mixres { display: grid; gap: 8px; margin: 0 0 14px; color: var(--paper); }
.dose-mixres ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.dose-mixres li { font-size: 14.5px; line-height: 1.45; }
.dose-mixres li b { color: var(--green); font-weight: 600; }
.dose-mixres li.tot { border-top: 1px solid var(--line); padding-top: 8px; font-size: 16px; }
.dose-mixres p { margin: 0; font-size: 14.5px; }
.dose-mixres.near .dose-bar i { background: var(--orange); }
.dose-mixres.over .dose-bar i { background: #FF4D4D; }
.dose-mixres.over p, .dose-mixres.over li.tot b { color: #FF8A8A; }

/* Language bar (flags) */
.lang-bar { border-bottom: 1px solid var(--grid); }
.lang-bar .inner { height: 34px !important; justify-content: flex-end !important; gap: 10px !important; }
.lang-label { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: #6B717A; }
.lang-flags { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.lang-flag { display: flex; align-items: center; gap: 6px; padding: 4px 7px; border-radius: 4px; text-decoration: none;
  font-family: var(--font-mono); font-size: 11.5px; color: var(--muted); border: 1px solid transparent; }
.lang-flag svg { width: 21px; height: 14px; border-radius: 2px; box-shadow: 0 0 0 1px rgba(255,255,255,.18); display: block; }
.lang-flag:hover { color: var(--paper); border-color: var(--line); }
.lang-flag[aria-current="true"] { color: var(--paper); border-color: var(--green); }
@media (max-width: 1100px) { .nav { top: 98px; } }
@media (max-width: 480px) { .lang-label { display: none; } .lang-flag { padding: 4px 5px; gap: 4px; } .lang-flag span { font-size: 10.5px; } }
/* Automatic (Google) translation notice */
.mt-note { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 60; max-width: 760px; margin: 0 auto;
  display: flex; gap: 12px; align-items: center; flex-wrap: wrap; padding: 12px 16px; border-radius: 10px;
  background: rgba(10,12,14,.96); border: 1px solid var(--orange); color: var(--paper); font-size: 14px; box-shadow: 0 8px 30px rgba(0,0,0,.5); }
.mt-note p { margin: 0; flex: 1 1 260px; }
.mt-note button { font-family: var(--font-mono); font-size: 12px; background: none; color: var(--paper); border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; cursor: pointer; }
.mt-note button.mt-en { border-color: var(--green); color: var(--green); }
iframe.goog-te-banner-frame, .goog-te-banner-frame, #goog-gt-tt, .goog-te-balloon-frame, .skiptranslate > iframe { display: none !important; }
body { top: 0 !important; }
.goog-text-highlight { background: none !important; box-shadow: none !important; }
#gt-el { display: none; }

/* Arabic: right-to-left layout */
[dir=rtl] body { font-family: "Noto Sans Arabic", "Segoe UI", Tahoma, var(--font-body, sans-serif); }
[dir=rtl] .lang-bar, [dir=rtl] .lang-flags { direction: ltr; }
[dir=rtl] .mono, [dir=rtl] .eyebrow, [dir=rtl] code { letter-spacing: 0; }
[dir=rtl] ul, [dir=rtl] ol { padding-left: 0; padding-right: 1.25em; }
[dir=rtl] .nav ul, [dir=rtl] .lang-flags, [dir=rtl] .crumbs, [dir=rtl] ul.chips { padding-right: 0; }
[dir=rtl] th, [dir=rtl] td { text-align: right; }
[dir=rtl] .carousel, [dir=rtl] .car-track, [dir=rtl] .hero, [dir=rtl] .hero-track { direction: ltr; }
[dir=rtl] .carousel figcaption, [dir=rtl] .hero .slide-copy { direction: rtl; }
[dir=rtl] input[type=number] { direction: ltr; text-align: right; }
[dir=rtl] .ticker, [dir=rtl] .ticker-track { direction: ltr; }

/* Patient information leaflets */
.leaf-h { margin: 28px 0 14px; }
.leaf-h:first-of-type { margin-top: 8px; }
.leaf-grid { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.leaf { display: grid; grid-template-columns: 112px 1fr; gap: 16px; background: var(--ink-2); border: 1px solid var(--line); border-radius: 10px; padding: 14px; }
.leaf-thumb { display: block; align-self: start; border-radius: 4px; overflow: hidden; background: #fff; box-shadow: 0 4px 14px rgba(0,0,0,.35); transition: transform .2s ease; }
.leaf-thumb:hover, .leaf-thumb:focus-visible { transform: translateY(-2px) rotate(-1deg); }
.leaf-thumb img { display: block; width: 100%; height: auto; }
.leaf-body h3 { font-size: 17px; line-height: 1.3; margin: 0 0 6px; }
.leaf-body h3 a { color: var(--paper); text-decoration: none; }
.leaf-body h3 a:hover { color: var(--green); }
.leaf-body p { margin: 0 0 8px; font-size: 14px; color: #C9CDD2; }
.leaf-meta { font-family: var(--font-mono); font-size: 11.5px !important; letter-spacing: .03em; color: var(--muted) !important; }
.leaf-btns { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 0 !important; }
.leaf-btns .btn { padding: 8px 14px; font-size: 13px; }
@media (max-width: 420px) { .leaf { grid-template-columns: 88px 1fr; gap: 12px; } }
.dose-out [hidden] { display: none !important; }
