/* ================================================================ colour schemes
   All colours come from the Abbott colour palette (no logo, no brand name).
   Warm = default · Fresh = [data-theme="fresh"] · Dark = [data-theme="dark"]
   Text on a coloured area always uses the dark shade of the same colour family. */
:root {
  --bg: #fcf7f2; --surface: #ffffff; --surface-2: #f2ebde; --ink: #4f4843; --muted: #776d64;
  --line: #f2ebde; --line-strong: #ddd1c3; --track: #ddd1c3;
  --accent: #2e4aed; --accent-ink: #2e4aed; --accent-soft: #d6dbfc; --accent-deep: #000075; --on-accent: #ffffff; --accent-shadow: rgba(46, 74, 237, .28);
  --indigo: #003d54; --indigo-soft: #ccf2fa; --on-indigo: #ffffff; --on-indigo-muted: #ccf2fa;
  --good: #73d26b; --on-good: #124f00; --good-ink: #124f00; --good-soft: #e3fae0; --good-fill: #e3fae0; --good-line: #73d26b; --fb-ok-line: #baf2b5;
  --bad: #3b0012; --bad-line: #ff2652; --bad-soft: #ffd9de; --fb-bad-line: #ff9ead;
  --gold: #ffbf21; --gold-ink: #5c4500; --gold-soft: #fff2d4; --gold-line: #ffde8f;
  --overlay: rgba(52, 64, 66, .45); --float: rgba(255, 255, 255, .96);
  --r: 22px;
  color-scheme: light;
}
:root[data-theme="fresh"] {
  --bg: #e4eeef; --surface: #ffffff; --surface-2: #e4eeef; --ink: #344042; --muted: #566567;
  --line: #d0dddd; --line-strong: #a8baba; --track: #d0dddd;
  --accent: #003d54; --accent-ink: #003d54; --accent-soft: #ccf2fa; --accent-deep: #003d54; --on-accent: #ffffff; --accent-shadow: rgba(0, 61, 84, .25);
  --indigo: #2e4aed; --indigo-soft: #d6dbfc; --on-indigo: #ffffff; --on-indigo-muted: #d6dbfc;
}
:root[data-theme="dark"] {
  --bg: #283234; --surface: #344042; --surface-2: #3e4b4d; --ink: #e4eeef; --muted: #a8baba;
  --line: #45535a; --line-strong: #6d7f80; --track: #4a585a;
  --accent: #7dceff; --accent-ink: #7dceff; --accent-soft: #002c60; --accent-deep: #c0e6ff; --on-accent: #002c60; --accent-shadow: rgba(0, 0, 0, .35);
  --indigo: #80def0; --indigo-soft: #003d54; --on-indigo: #003d54; --on-indigo-muted: #003d54;
  --good: #73d26b; --on-good: #124f00; --good-ink: #baf2b5; --good-soft: #124f00; --good-fill: #124f00; --good-line: #73d26b; --fb-ok-line: #124f00;
  --bad: #ff9ead; --bad-line: #ff2652; --bad-soft: #3b0012; --fb-bad-line: #3b0012;
  --gold: #ffbf21; --gold-ink: #ffde8f; --gold-soft: #5c4500; --gold-line: #5c4500;
  --overlay: rgba(0, 0, 0, .6); --float: rgba(52, 64, 66, .97);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); }
/* the page itself never scrolls, only #app (iOS 26 moves fixed bars when the page scrolls) */
html.app-shell, html.app-shell body { height: 100%; overflow: hidden; overscroll-behavior: none; }
html.app-shell #app { height: 100%; overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; overscroll-behavior-y: contain; }
body { font-family: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif; font-size: 16px; line-height: 1.45; -webkit-font-smoothing: antialiased; }
a { color: var(--accent-ink); font-weight: 700; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--indigo); outline-offset: 2px; }

.screen { max-width: 560px; margin: 0 auto; padding: 24px 20px 32px; display: flex; flex-direction: column; gap: 16px; min-height: 100vh; }
.screen.with-nav { padding-bottom: 104px; min-height: 0; }
.screen.admin { max-width: 960px; }
.center { display: flex; justify-content: center; padding: 64px 0; }
.center-col { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; padding-top: 48px; }

.brand { font-weight: 800; color: var(--accent-ink); letter-spacing: .02em; }
.title { margin: 0; font-size: 27px; font-weight: 800; line-height: 1.2; }
.h2 { margin: 0; font-size: 18px; font-weight: 800; }
.muted { color: var(--muted); }
.strong { font-weight: 800; }
.tiny { font-size: 13px; }
.small { font-size: 14px; }
.big { font-size: 22px; font-weight: 800; line-height: 1; }
.big-num { font-size: 40px; font-weight: 800; margin: 0; }
.msg { margin: 0; padding: 12px 14px; border-radius: 14px; background: var(--indigo-soft); color: var(--indigo); font-weight: 600; }

.card { background: var(--surface); border-radius: var(--r); padding: 18px; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.stack-s { display: flex; flex-direction: column; gap: 4px; }
.stack-0 { display: flex; flex-direction: column; }
.row { display: flex; align-items: center; gap: 12px; }
.row.wrap { flex-wrap: wrap; gap: 8px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grow { flex: 1 1 auto; min-width: 0; }

label { font-weight: 700; font-size: 14px; }
input, select, textarea { width: 100%; min-height: 48px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--surface); }
textarea { min-height: 88px; resize: vertical; }
input.code { font-size: 26px; letter-spacing: .35em; text-align: center; font-weight: 800; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; }
.check input { width: 22px; min-height: 22px; height: 22px; margin-top: 1px; accent-color: var(--accent); flex-shrink: 0; }
fieldset { border: 0; padding: 0; margin: 0; }
legend { font-weight: 700; font-size: 14px; margin-bottom: 6px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: 999px; border: 0; font-weight: 800; cursor: pointer; text-decoration: none; }
.btn.primary { background: var(--accent); color: var(--on-accent); }
.btn.indigo { background: var(--indigo); color: var(--on-indigo); }
.btn.ghost { background: transparent; border: 1.5px solid var(--line-strong); color: var(--ink); }
.btn.small { min-height: 40px; padding: 0 14px; font-size: 14px; }
.btn:disabled { opacity: .5; cursor: default; }
.big-btn { min-height: 60px; font-size: 19px; width: 100%; }
.link { background: none; border: 0; color: var(--accent-ink); font-weight: 800; cursor: pointer; padding: 8px 0; min-height: 44px; display: inline-flex; align-items: center; gap: 6px; }
.icon-btn { width: 44px; height: 44px; border-radius: 22px; border: 0; background: var(--surface); color: var(--ink); display: flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; }

.notice { background: var(--bg); border-radius: 16px; padding: 14px; font-size: 14px; }
.notice ul { margin: 8px 0 12px; padding-left: 18px; color: var(--ink); }
.notice li { margin-bottom: 4px; }

.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.seg-opt { position: relative; }
.seg-opt input { position: absolute; opacity: 0; }
.seg-opt span { display: flex; align-items: center; justify-content: center; min-height: 48px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface); font-weight: 700; cursor: pointer; }
.seg-opt input:checked + span { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-ink); }
.seg-opt input:focus-visible + span { outline: 3px solid var(--indigo); }

/* home */
.hello { display: flex; justify-content: space-between; align-items: center; }
.avatar { width: 46px; height: 46px; border-radius: 23px; border: 0; background: var(--accent-soft); color: var(--accent-deep); font-weight: 800; cursor: pointer; }
.goal { display: flex; align-items: center; gap: 16px; }
.ring { width: 96px; height: 96px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.ring-in { width: 74px; height: 74px; border-radius: 50%; background: var(--surface); display: flex; flex-direction: column; align-items: center; justify-content: center; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.pill { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 700; padding: 4px 10px; border-radius: 12px; background: var(--bg); }
.install { display: flex; align-items: center; gap: 10px; font-size: 14px; background: var(--indigo-soft); color: var(--indigo); }
.medals { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.medal-card { background: var(--surface); border-radius: 18px; padding: 12px 4px; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.medal-name { font-size: 12px; font-weight: 800; line-height: 1.2; }
.medal { border-radius: 50%; border: 3px solid; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 800; flex-shrink: 0; }

/* topics */
.topic { display: flex; flex-direction: column; gap: 12px; }
.bar { height: 10px; border-radius: 6px; background: var(--track); overflow: hidden; }
.bar > div { height: 100%; border-radius: 6px; background: var(--accent); transition: width .3s; }
.seg3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.seg-btn { min-height: 44px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); font-weight: 700; cursor: pointer; font-size: 14px; }
.seg-btn.on { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-ink); }
.seg-btn:disabled { opacity: .45; cursor: not-allowed; }

/* ranking */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { min-height: 40px; padding: 0 16px; border-radius: 20px; border: 0; background: var(--surface); font-weight: 700; cursor: pointer; }
.chip.on { background: var(--ink); color: var(--surface); }
.chip.alt.on { background: var(--indigo); color: var(--on-indigo); }
.podium { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 6px; }
.pod { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; min-width: 0; }
.pod-name { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.pod-av { width: 52px; height: 52px; border-radius: 50%; border: 3px solid #ddd1c3; background: var(--bg); display: flex; align-items: center; justify-content: center; font-weight: 800; }
.pod-av.gold { width: 62px; height: 62px; background: #fff2d4; border-color: #ffbf21; color: #5c4500; }
.pod-av.silver { background: #e4eeef; border-color: #a8baba; color: #344042; }
.pod-av.bronze { background: #fcded4; border-color: #ff5729; color: #520000; }
.pod-step { width: 86%; border-radius: 12px 12px 4px 4px; padding-top: 6px; font-weight: 800; font-size: 14px; }
.pod-step.s1 { height: 76px; background: #fff2d4; color: #5c4500; }
.pod-step.s2 { height: 56px; background: #e4eeef; color: #344042; }
.pod-step.s3 { height: 42px; background: #fcded4; color: #520000; }
.lb { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.lb-row { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-radius: 20px; background: var(--surface); }
.lb-row .tiny { color: var(--muted); }
.lb-row.me { background: var(--surface); color: inherit; box-shadow: inset 0 0 0 2.5px var(--accent-deep); }
.lb-row.me .tiny { color: var(--muted); }
.rk { width: 24px; font-weight: 800; }
.staff { color: var(--indigo); vertical-align: -2px; }
.lb-row.me .staff { color: var(--indigo); }

/* round */
.round-top { display: flex; align-items: center; gap: 12px; }
.qcard { display: flex; flex-direction: column; gap: 12px; }
.question { margin: 0; font-size: 23px; line-height: 1.3; font-weight: 800; }
.tag { font-size: 13px; font-weight: 800; padding: 5px 12px; border-radius: 14px; background: var(--indigo-soft); color: var(--indigo); }
.tag.soft { background: var(--bg); color: var(--muted); }
.answers { display: flex; flex-direction: column; gap: 10px; }
.answer { min-height: 58px; padding: 14px 20px; border-radius: 28px; border: 2px solid transparent; background: var(--surface); text-align: left; font-weight: 700; display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; }
@media (hover: hover) and (pointer: fine) { .answer:not(:disabled):hover { border-color: var(--line-strong); } }
.answer.right { background: var(--good-fill); border-color: var(--good-line); color: var(--good-ink); }
.answer.wrong { background: var(--bad-soft); border-color: var(--bad-line); color: var(--bad); }
.answer.dim { color: var(--muted); font-weight: 600; }
.answer:disabled { cursor: default; }
.feedback { border-radius: var(--r); padding: 16px 18px; display: flex; flex-direction: column; gap: 8px; }
.feedback p { margin: 0; font-size: 15px; }
.feedback.ok { background: var(--surface); border: 1.5px solid var(--fb-ok-line); color: var(--ink); }
.feedback.ok .h2 { color: var(--good-ink); }
.feedback.bad { background: var(--surface); border: 1.5px solid var(--fb-bad-line); color: var(--ink); }
.feedback.bad .h2 { color: var(--bad); }
.pts { font-weight: 800; padding: 4px 12px; border-radius: 14px; background: var(--surface); color: var(--good-ink); }
.result-badge { width: 96px; height: 96px; border-radius: 50%; background: var(--gold-soft); border: 4px solid var(--gold); color: var(--gold-ink); display: flex; align-items: center; justify-content: center; }

/* nav */
.nav { position: fixed; left: 0; right: 0; bottom: 0; height: calc(72px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: var(--surface); border-radius: 24px 24px 0 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); box-shadow: 0 -1px 0 var(--line); }
.nav-item { border: 0; background: none; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; color: var(--muted); font-size: 12px; font-weight: 700; cursor: pointer; }
.nav-item.on { color: var(--accent-ink); font-weight: 800; }
@media (min-width: 600px) { .nav { max-width: 560px; margin: 0 auto; } }

/* overlay */
.overlay { position: fixed; inset: 0; background: var(--overlay); display: flex; align-items: flex-end; justify-content: center; z-index: 10; }
.sheet { background: var(--surface); width: 100%; max-width: 560px; border-radius: 24px 24px 0 0; padding: 22px 20px calc(22px + env(safe-area-inset-bottom)); }

/* admin */
.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; }
.kpi { display: flex; flex-direction: column; gap: 6px; }
.aqcard { padding: 12px 14px; }
.qrow { display: flex; gap: 12px; align-items: flex-start; font-weight: 400; font-size: 15px; }
.qopen { background: none; border: 0; padding: 0; text-align: left; font: inherit; color: inherit; cursor: pointer; }
.qmore { color: var(--indigo); font-weight: 700; margin-top: 4px; }
.qdetail { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--bg); font-size: 15px; overflow-wrap: anywhere; }
.qans { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.qans li { display: flex; gap: 10px; align-items: flex-start; padding: 8px 10px; border-radius: 12px; }
.qans li.ok { background: var(--good-soft); }
.qans li.no { background: var(--bg); }
.qmark { font-weight: 800; width: 14px; flex-shrink: 0; }
.qans li.ok .qmark { color: var(--good-ink); }
.qans li.no .qmark { color: var(--bad); }
.block { display: block; }
.nowrap { white-space: nowrap; }
.qrow input { width: 22px; height: 22px; min-height: 22px; margin-top: 2px; accent-color: var(--accent); flex-shrink: 0; }
.sticky-actions { position: sticky; top: 0; background: var(--bg); padding: 8px 0; z-index: 2; }
.admin select { width: auto; min-width: 160px; }

.spinner { width: 36px; height: 36px; border-radius: 50%; border: 4px solid var(--track); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 3s; } .bar > div { transition: none; } }
@media (max-width: 380px) { .medals { grid-template-columns: repeat(3, minmax(0, 1fr)); } .row2 { grid-template-columns: 1fr; } }

/* My questions */
.seg2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.star-badge { width: 42px; height: 42px; background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.saved-card { border: 1.5px solid var(--accent-soft); }
.star-tag { display: inline-flex; align-items: center; gap: 4px; background: var(--accent-soft); color: var(--accent-deep); }
.save-btn { align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 14px; border-radius: 22px;
  border: 1.5px solid var(--line); background: var(--surface); font: inherit; font-weight: 700; font-size: 14px; color: var(--ink); cursor: pointer; }
.save-btn.on { background: var(--accent-soft); border-color: var(--accent); color: var(--accent-deep); }
.save-btn svg { color: var(--accent); }
.saved-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.saved-item { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; }
.icon-btn.star { color: var(--accent); }
.fb-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding-top: 12px; border-top: 1px solid var(--line); }
.fb-actions .save-btn { min-height: 40px; padding: 6px 14px; }

/* keep content from scrolling under the iPhone status bar */
body::before { content: ''; position: fixed; top: 0; left: 0; right: 0; height: env(safe-area-inset-top); background: var(--bg); z-index: 50; }
body { padding-top: env(safe-area-inset-top); }

/* ---------------------------------------------------------------- levels */
.lv-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.lv-chip { min-height: 52px; border-radius: 14px; border: 1.5px dashed var(--line-strong); background: var(--surface); cursor: pointer; font: inherit;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; padding: 6px 4px; color: var(--muted); }
.lv-chip.on { border-style: solid; border-color: var(--indigo); background: var(--indigo-soft); color: var(--indigo); }
.lv-chip.soon { opacity: .55; cursor: not-allowed; }
.lv-top { display: inline-flex; align-items: center; gap: 5px; font-weight: 800; font-size: 14px; }
.lv-sub { font-size: 12px; font-weight: 700; }
.lv-dot { width: 11px; height: 11px; border-radius: 50%; border: 2px solid; display: inline-block; }
.ready-chip { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border-radius: 22px; border: 0; cursor: pointer;
  font: inherit; font-weight: 800; font-size: 14px; background: var(--gold-soft); color: var(--gold-ink); animation: breathe 2.4s ease-in-out infinite; }

/* ---------------------------------------------------------------- celebration */
.celebrate { align-items: center; padding: 16px; }
.celebrate .sheet { border-radius: 24px; text-align: center; animation: rise .45s cubic-bezier(.2, .9, .3, 1.3) both; position: relative; z-index: 2; }
.lvl-badge { width: 92px; height: 92px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff2d4, #ffbf21); border: 4px solid #ffbf21;
  color: #5c4500; display: flex; flex-direction: column; align-items: center; justify-content: center; font-weight: 900; font-size: 20px;
  animation: bounce-in .8s cubic-bezier(.2, .9, .3, 1.4) .15s both; box-shadow: 0 0 0 0 rgba(217, 165, 32, .5); }
.confetti { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 1; }
.confetti i { position: absolute; top: -20px; border-radius: 2px; animation-name: confetti-fall; animation-timing-function: cubic-bezier(.3, .6, .5, 1); animation-fill-mode: both; }
.toast { position: fixed; left: 50%; bottom: calc(92px + env(safe-area-inset-bottom)); transform: translateX(-50%); background: var(--ink); color: var(--surface);
  padding: 12px 18px; border-radius: 16px; font-weight: 700; font-size: 14px; z-index: 20; max-width: calc(100% - 32px); text-align: center;
  animation: toast-in .35s ease-out both; }

/* ---------------------------------------------------------------- one-shot animations (class .animate only the first time a tab is shown in a session)
   Standard: tiles and rows only fade in, no movement; Fun mode keeps its bounce */
@property --p { syntax: '<percentage>'; inherits: false; initial-value: 0%; }
.animate .ring { animation: ring-fill 1.1s cubic-bezier(.3, .7, .3, 1) both; }
.animate .bar > div { transform-origin: left center; animation: grow-x .9s cubic-bezier(.3, .7, .3, 1) both; }
.animate .medal-card, .animate .topic { animation: fade-in .4s ease-out both; animation-delay: calc(var(--i, 0) * 40ms); }
.animate .medal-card .medal { animation: fade-in .4s ease-out both; animation-delay: calc(100ms + var(--i, 0) * 40ms); }
.animate .pod-step { transform-origin: bottom center; animation: grow-y .8s cubic-bezier(.2, .9, .3, 1.2) both; animation-delay: calc(var(--i, 0) * 120ms); }
.animate .pod-av { animation: pop .5s cubic-bezier(.2, .9, .3, 1.5) both; animation-delay: calc(450ms + var(--i, 0) * 120ms); }
.animate .lb-row { animation: fade-in .4s ease-out both; animation-delay: calc(100ms + var(--i, 0) * 30ms); }
.feedback.enter { animation: rise .35s ease-out both; }
.pts { position: relative; }
.pts.pop { animation: pop .5s cubic-bezier(.2, .9, .3, 1.6) both; }
.float-pts { position: absolute; right: 8px; top: -6px; color: var(--good-ink); font-weight: 900; pointer-events: none; animation: float-up 1.1s ease-out both; }
.answer.right { animation: glow .9s ease-out; }
.result-badge { animation: bounce-in .8s cubic-bezier(.2, .9, .3, 1.4) both; }
.new-medals { display: flex; flex-direction: column; gap: 10px; width: 100%; }
.new-medal { display: flex; align-items: center; gap: 12px; background: var(--surface); border-radius: 18px; padding: 12px 14px; text-align: left;
  animation: rise .45s ease-out both; animation-delay: calc(300ms + var(--i, 0) * 150ms); }
.medal.pop { animation: pop .6s cubic-bezier(.2, .9, .3, 1.6) both; animation-delay: calc(450ms + var(--i, 0) * 150ms); }

@keyframes ring-fill { from { --p: 0%; } }
@keyframes grow-x { from { transform: scaleX(0); } }
@keyframes grow-y { from { transform: scaleY(0); } }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } }
@keyframes fade-in { from { opacity: 0; } }
@keyframes slide-in { from { opacity: 0; transform: translateX(-18px); } }
@keyframes pop { 0% { transform: scale(.3); opacity: 0; } 70% { transform: scale(1.12); opacity: 1; } 100% { transform: scale(1); } }
@keyframes bounce-in { 0% { transform: scale(.2) rotate(-12deg); opacity: 0; } 60% { transform: scale(1.15) rotate(4deg); opacity: 1; } 100% { transform: scale(1) rotate(0); } }
@keyframes float-up { 0% { opacity: 0; transform: translateY(0) scale(.8); } 20% { opacity: 1; } 100% { opacity: 0; transform: translateY(-38px) scale(1.15); } }
@keyframes glow { 0% { box-shadow: 0 0 0 0 rgba(46, 125, 79, .55); } 100% { box-shadow: 0 0 0 14px rgba(46, 125, 79, 0); } }
@keyframes breathe { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.03); } }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 12px); } }
@keyframes confetti-fall {
  0% { transform: translate(0, 0) rotate(var(--r)); opacity: 1; }
  100% { transform: translate(var(--dx), 105vh) rotate(calc(var(--r) + 540deg)); opacity: .9; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .confetti { display: none; }
}
.seg-btn.locked { color: var(--muted); background: var(--surface-2); border-style: dashed; display: inline-flex; align-items: center; justify-content: center; gap: 5px; }
.focus-hint { margin: -4px 0 0; }
.seg3 .seg-btn { font-size: 13px; padding: 4px 6px; line-height: 1.2; }
.seg-btn.locked svg { flex-shrink: 0; }

/* ---------------------------------------------------------------- answer streaks */
.flame { display: inline-flex; line-height: 0; position: relative; }
.flame.t1 { color: #F0A43A; }
.flame.t2 { color: #EA6A1F; filter: drop-shadow(0 0 3px rgba(234, 106, 31, .45)); }
.flame.t3 { color: #D62F1F; filter: drop-shadow(0 0 5px rgba(214, 47, 31, .6)); animation: flicker 1.2s ease-in-out infinite; }
.flame.t4 { color: #6A3DE8; filter: drop-shadow(0 0 7px rgba(106, 61, 232, .7)); animation: flicker .8s ease-in-out infinite; }
.flame.t4 path + path { fill: #BFE3FF; }
.streak-pill.t2 { background: #FDEBDD; color: #8A3A0B; }
.streak-pill.t3 { background: #FCE1DC; color: #8E1E12; }
.streak-pill.t4 { background: #ECE5FD; color: #3E1F99; }
.streak-chip { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px 5px 8px; border-radius: 16px;
  background: #FFF3E3; color: #8A3A0B; font-weight: 800; font-size: 14px; }
.streak-chip.t3 { background: #FCE1DC; color: #8E1E12; }
.streak-chip.t4 { background: #ECE5FD; color: #3E1F99; }
.streak-chip.pop { animation: pop .5s cubic-bezier(.2, .9, .3, 1.6) both; }
.streak-burst { position: fixed; left: 50%; top: 38%; transform: translate(-50%, -50%); z-index: 30; pointer-events: none;
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 22px 28px; border-radius: 28px;
  background: var(--float); box-shadow: 0 18px 50px rgba(35, 32, 28, .25); text-align: center;
  animation: burst 1.9s ease-out forwards; }
.streak-burst strong { font-size: 26px; font-weight: 900; }
.streak-burst span { font-weight: 800; color: var(--accent-ink); }
.stats { display: flex; flex-direction: column; gap: 14px; }
.best-streak { display: flex; align-items: center; gap: 14px; }
.big-num-s { font-size: 24px; font-weight: 900; }
.stat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.stat-grid > div { background: var(--bg); border-radius: 14px; padding: 10px; display: flex; flex-direction: column; gap: 2px; }
.stat-grid strong { font-size: 18px; }
@keyframes flicker { 0%, 100% { transform: scale(1) rotate(0); } 30% { transform: scale(1.06, .96) rotate(-2deg); } 60% { transform: scale(.97, 1.05) rotate(2deg); } }
@keyframes burst { 0% { opacity: 0; transform: translate(-50%, -50%) scale(.4); } 15% { opacity: 1; transform: translate(-50%, -50%) scale(1.08); }
  25% { transform: translate(-50%, -50%) scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -60%) scale(.95); } }
.streak-burst { width: max-content; max-width: 86vw; }
.streak-burst strong, .streak-burst span { white-space: nowrap; }

/* medal = progress ring around the percentage */
.medal.ring-m { border: 0; padding: 4px; background: conic-gradient(var(--c) 0 var(--p), var(--track) var(--p) 100%); }
.medal.ring-m > span { width: 100%; height: 100%; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.animate .medal.ring-m { animation: fade-in .4s ease-out both, ring-fill 1.2s cubic-bezier(.3, .7, .3, 1) both; animation-delay: calc(100ms + var(--i, 0) * 40ms); }

/* leaderboard filters: what (big tabs) + period (small tabs) */
.scope-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; background: var(--surface); padding: 4px; border-radius: 18px; }
.scope-btn { min-height: 52px; border: 0; border-radius: 14px; background: transparent; font: inherit; font-weight: 800; font-size: 14px; color: var(--muted);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; cursor: pointer; }
.scope-btn.on { background: var(--indigo); color: var(--on-indigo); }
.period-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.period-tabs { display: inline-flex; background: var(--surface-2); border-radius: 14px; padding: 3px; }
.period-btn { min-height: 36px; border: 0; background: transparent; border-radius: 11px; padding: 0 12px; font: inherit; font-weight: 700; font-size: 13px; color: var(--muted); cursor: pointer; }
.period-btn.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.gear { color: var(--muted); }
.ver-badge { font-size: 12px; font-weight: 800; padding: 4px 10px; border-radius: 12px; background: var(--indigo-soft); color: var(--indigo); }
.changes { margin: 8px 0 0; padding-left: 18px; font-size: 14px; display: flex; flex-direction: column; gap: 4px; }
details summary { cursor: pointer; min-height: 32px; display: flex; align-items: center; }
.notice ul { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.card.notice { background: var(--surface); padding: 18px 20px; border: 0; }

/* weekly ring: keeps filling in a new colour after the goal is reached */
.ring { position: relative; background: conic-gradient(var(--c1, var(--accent)) 0 var(--p), var(--c0, var(--track)) var(--p) 100%); }
.lap-badge { position: absolute; top: -4px; right: -6px; background: var(--ink); color: var(--surface); font-size: 12px; font-weight: 900; padding: 3px 7px; border-radius: 10px;
  border: 2px solid var(--surface); animation: pop .5s cubic-bezier(.2, .9, .3, 1.6) .9s both; }

/* ---------------------------------------------------------------- duels (indigo) */
.nav-ic { position: relative; display: inline-flex; }
.nav-badge { position: absolute; top: -6px; right: -10px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--accent);
  color: var(--on-accent); font-size: 11px; font-weight: 900; display: flex; align-items: center; justify-content: center; border: 2px solid var(--surface); animation: pop .5s both; }
.nav-item.duels.on { color: var(--indigo); }
.nav-item { font-size: 11px; }
.duel-home { display: flex; align-items: center; gap: 12px; border: 0; background: var(--indigo); color: var(--on-indigo); text-align: left; cursor: pointer; font: inherit;
  animation: breathe 2.4s ease-in-out infinite; }
.duel-home .tiny { color: var(--on-indigo-muted); }
.record { display: inline-flex; gap: 6px; align-items: center; font-weight: 800; font-size: 13px; background: var(--surface); padding: 6px 12px; border-radius: 14px; color: var(--muted); }
.record .w { color: var(--good-ink); } .record .l { color: var(--bad); }
.duel-card { display: flex; flex-direction: column; gap: 12px; }
.duel-card.turn { border: 2px solid var(--indigo); }
.duel-card.plain { border: 0; text-align: left; font: inherit; color: inherit; cursor: pointer; width: 100%; }
.duel-card.plain .row > svg { transform: rotate(180deg); color: var(--muted); }
.duel-av { width: 42px; height: 42px; border-radius: 21px; background: var(--bg); color: var(--ink); display: flex; align-items: center; justify-content: center; font-weight: 900; flex-shrink: 0; }
.duel-av.indigo { background: var(--indigo-soft); color: var(--indigo); }
.score { font-weight: 900; font-size: 18px; margin-right: 8px; }
.res { font-size: 12px; font-weight: 800; padding: 4px 10px; border-radius: 10px; background: var(--bg); color: var(--muted); }
.res.won { background: var(--good-soft); color: var(--good-ink); } .res.lost { background: var(--bad-soft); color: var(--bad); }
.res.draw { background: var(--indigo-soft); color: var(--indigo); }
.animate .duel-card { animation: fade-in .4s ease-out both; animation-delay: calc(var(--i, 0) * 40ms); }
.pick-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.pick { width: 100%; display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 18px; border: 0; background: var(--surface); font: inherit; color: inherit; text-align: left; cursor: pointer; min-height: 60px; }
.pick:disabled { opacity: .55; cursor: not-allowed; }
.pick svg { color: var(--indigo); }
.duel-play .timer { min-width: 54px; height: 44px; border-radius: 22px; background: var(--indigo); color: var(--on-indigo); font-weight: 900; display: flex; align-items: center; justify-content: center; }
.duel-play .timer.stopped { background: var(--indigo-soft); color: var(--indigo); }
.timebar { height: 8px; border-radius: 4px; background: var(--indigo-soft); overflow: hidden; }
.timebar > div { height: 100%; background: var(--indigo); border-radius: 4px; transition: width .2s linear, background .3s; }
.timebar > div.hurry { background: var(--accent); }
.duel-result { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.duel-result.won { background: linear-gradient(180deg, var(--gold-soft), var(--surface)); }
.big-emoji { font-size: 44px; line-height: 1; animation: bounce-in .7s both; }
.scoreline { display: flex; align-items: center; gap: 18px; }
.scoreline b { font-size: 40px; font-weight: 900; }
.scoreline .colon { font-size: 30px; font-weight: 900; color: var(--muted); }
.duel-marks { display: flex; gap: 18px; font-size: 14px; font-weight: 700; }
.duel-marks > div { display: inline-flex; align-items: center; gap: 6px; }
.mk { width: 22px; height: 22px; border-radius: 11px; display: inline-flex; align-items: center; justify-content: center; color: #fff; }
.mk.ok { background: var(--good); color: var(--on-good); } .mk.bad { background: var(--bad-soft); color: var(--bad); box-shadow: inset 0 0 0 1.5px var(--bad-line); }
.duel-record { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14px; color: var(--indigo); font-weight: 700; }
.duel-record b { font-weight: 800; color: var(--muted); } .duel-record b.w { color: var(--good-ink); } .duel-record b.l { color: var(--bad); }

/* Stardust: shimmering top medal */
.medal.ring-m.stardust { background: conic-gradient(#8054f2, #ff6eb8, #ffbf21, #00bfde, #8054f2); animation: spin-glow 6s linear infinite; box-shadow: 0 0 12px rgba(128, 84, 242, .45); }
.medal.ring-m.stardust > span { background: radial-gradient(circle at 30% 30%, #fff, #e5defc) !important; }
@keyframes spin-glow { to { filter: hue-rotate(360deg); } }
.duel-btn { width: 36px; height: 36px; background: var(--indigo-soft); color: var(--indigo); margin-left: 6px; }
.lb-row.me .duel-btn { display: none; }
.pod-duel { border: 0; background: var(--indigo-soft); color: var(--indigo); font: inherit; font-size: 12px; font-weight: 800; border-radius: 12px; padding: 4px 10px; display: inline-flex; align-items: center; gap: 4px; cursor: pointer; margin: 2px 0 4px; }
.medal-trophy { display: inline-flex; margin-top: auto; }
.trophy.stardust { filter: drop-shadow(0 0 3px rgba(142, 91, 232, .5)); }
.topic-sub { display: inline-flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.animate .medal-trophy { animation: fade-in .4s ease-out both; animation-delay: calc(200ms + var(--i, 0) * 40ms); }

/* ---------------------------------------------------------------- glossary */
.gl { display: inline; border: 0; padding: 0; margin: 0; background: none; font: inherit; color: inherit; cursor: pointer;
  text-decoration: underline dotted; text-decoration-color: var(--indigo); text-decoration-thickness: 2px; text-underline-offset: 4px; }
@media (hover: hover) and (pointer: fine) { .gl:hover { color: var(--indigo); } }
.gl:focus-visible { color: var(--indigo); }
.answer .gl { pointer-events: none; text-decoration: none; }
.term-sheet .term-def { font-size: 16px; line-height: 1.5; margin: 0; }
.term-sheet .row svg { color: var(--indigo); }
.gl-card { display: flex; align-items: center; gap: 12px; border: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; width: 100%; }
.gl-card > svg:first-child { color: var(--indigo); }
.gl-card > svg:last-child { transform: rotate(180deg); color: var(--muted); }
.gl-letter { font-size: 14px; font-weight: 900; color: var(--indigo); margin: 8px 0 0; }
.gl-item { display: flex; align-items: center; gap: 10px; border: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; width: 100%; padding: 12px 16px; }

/* ---------------------------------------------------------------- new medals on the result screen: one after another */
.new-medal { position: relative; overflow: hidden; gap: 16px; padding: 14px 16px; border: 2px solid transparent;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, linear-gradient(120deg, var(--fill), var(--rim)) border-box;
  animation: nm-in .6s cubic-bezier(.2, .9, .3, 1.25) both; animation-delay: calc(400ms + var(--i, 0) * 900ms); }
.new-medal::after { content: ''; position: absolute; inset: 0; background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, .8) 50%, transparent 70%);
  transform: translateX(-120%); animation: nm-shine 1.1s ease-out both; animation-delay: calc(1200ms + var(--i, 0) * 900ms); pointer-events: none; }
.nm-badge { position: relative; width: 58px; height: 58px; border-radius: 50%; flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 35% 30%, #fff, var(--fill)); border: 3px solid var(--rim);
  animation: nm-drop .7s cubic-bezier(.2, .9, .3, 1.5) both; animation-delay: calc(650ms + var(--i, 0) * 900ms); }
.nm-glow { position: absolute; inset: -3px; border-radius: 50%; box-shadow: 0 0 0 0 var(--rim); opacity: .6;
  animation: nm-glow 1.2s ease-out both; animation-delay: calc(1100ms + var(--i, 0) * 900ms); }
.spark { position: absolute; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px; border-radius: 50%; background: var(--rim); opacity: 0;
  animation: nm-spark .8s ease-out both; animation-delay: calc(1050ms + var(--i, 0) * 900ms); }
.spark:nth-of-type(even) { background: #ffbf21; width: 5px; height: 5px; }
.nm-kicker { text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-size: 11px; }
.nm-title { font-size: 20px; font-weight: 900; line-height: 1.15; }
.nm-next { color: var(--indigo); font-weight: 700; margin-top: 2px; }
.new-medals.shown .new-medal, .new-medals.shown .new-medal::after, .new-medals.shown .nm-badge, .new-medals.shown .nm-glow, .new-medals.shown .spark { animation: none; }
.confetti.mini i { animation-duration: 2.2s !important; }
@keyframes nm-in { 0% { opacity: 0; transform: translateX(60px) scale(.9); } 100% { opacity: 1; transform: none; } }
@keyframes nm-drop { 0% { opacity: 0; transform: translateY(-40px) scale(.3) rotate(-25deg); } 70% { opacity: 1; transform: translateY(4px) scale(1.12) rotate(6deg); } 100% { transform: none; } }
@keyframes nm-glow { 0% { box-shadow: 0 0 0 0 var(--rim); opacity: .7; } 100% { box-shadow: 0 0 0 18px var(--rim); opacity: 0; } }
@keyframes nm-shine { to { transform: translateX(120%); } }
@keyframes nm-spark { 0% { opacity: 1; transform: rotate(var(--a)) translateX(10px) scale(1); } 100% { opacity: 0; transform: rotate(var(--a)) translateX(46px) scale(.4); } }

/* ---------------------------------------------------------------- big "+points" burst after a correct answer */
.pts-burst { position: fixed; left: 50%; top: 42%; z-index: 40; pointer-events: none; width: 0; height: 0; }
.pts-burst b { position: absolute; left: 0; top: 0; transform: translate(-50%, -50%); font-size: 54px; font-weight: 900; white-space: nowrap;
  color: var(--good-ink); text-shadow: 0 4px 0 var(--surface), 0 8px 24px rgba(31, 122, 77, .35); animation: pts-pop 1.4s cubic-bezier(.2, .9, .3, 1.2) forwards; }
.pts-burst i { position: absolute; left: -5px; top: -5px; width: 10px; height: 10px; border-radius: 50%; background: #ffbf21; opacity: 0;
  animation: pts-spark .9s ease-out .1s forwards; }
.pts-burst i:nth-child(odd) { background: var(--good); width: 7px; height: 7px; }
@keyframes pts-pop {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.3); }
  25% { opacity: 1; transform: translate(-50%, -50%) scale(1.25); }
  45% { transform: translate(-50%, -50%) scale(1); }
  75% { opacity: 1; transform: translate(-50%, -80%) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -160%) scale(.7); }
}
@keyframes pts-spark { 0% { opacity: 1; transform: rotate(var(--a)) translateX(20px); } 100% { opacity: 0; transform: rotate(var(--a)) translateX(95px) scale(.4); } }
.pts.pop { animation: pts-pill 1.1s cubic-bezier(.2, .9, .3, 1.6) .35s both; }
@keyframes pts-pill { 0% { transform: scale(.4); opacity: 0; } 50% { transform: scale(1.25); opacity: 1; background: var(--gold-soft); } 100% { transform: scale(1); } }

/* ---------------------------------------------------------------- favorite star */
.save-star { position: relative; display: inline-flex; }
.save-btn.just-saved { animation: fav-btn .6s cubic-bezier(.2, .9, .3, 1.5); }
.save-btn.just-saved .save-star svg { animation: fav-star .8s cubic-bezier(.2, .9, .3, 1.4); }
.save-star i { position: absolute; left: 50%; top: 50%; width: 5px; height: 5px; margin: -2.5px; border-radius: 50%; background: var(--accent); opacity: 0;
  animation: fav-spark .7s ease-out .15s forwards; }
.save-btn.just-unsaved .save-star svg { animation: fav-off .35s ease-in; }
@keyframes fav-btn { 0% { transform: scale(1); } 35% { transform: scale(1.12); background: var(--accent-soft); } 100% { transform: scale(1); } }
@keyframes fav-star { 0% { transform: scale(.4) rotate(-90deg); } 60% { transform: scale(1.6) rotate(20deg); } 100% { transform: scale(1) rotate(0); } }
@keyframes fav-spark { 0% { opacity: 1; transform: rotate(var(--a)) translateX(6px); } 100% { opacity: 0; transform: rotate(var(--a)) translateX(24px) scale(.5); } }
@keyframes fav-off { 50% { transform: scale(.6); } 100% { transform: scale(1); } }

/* status bar: a cream band behind the iPhone status bar. It starts above the visible page, because iOS draws
   scrolled content under the status bar even where the page itself reports no safe area. */
body::before { top: -120px; height: calc(120px + env(safe-area-inset-top)); }
html { background: var(--bg); }
@media (prefers-reduced-motion: reduce) { .pts-burst { display: none; } }

/* ---------------------------------------------------------------- feedback sequence (about 2 s in total)
   0.0 s answer glows · 0.05 s big +points · 0.55 s points pill counts up · 1.0 s streak chip · 1.25 s streak milestone */
.pts-burst b { animation-duration: .95s; }
.pts-burst i { animation-duration: .7s; animation-delay: .1s; }
.pts.pop { animation: pts-pill .6s cubic-bezier(.2, .9, .3, 1.6) .55s both; }
.streak-chip.pop { animation: pop .5s cubic-bezier(.2, .9, .3, 1.6) 1s both; }
.streak-burst { animation: burst 1.6s ease-out 1.25s both; }

/* ---------------------------------------------------------------- calmer timing (about 3 s) and a badge behind +points
   0.1 s +points badge (1.5 s) · 1.0 s pill counts up · 1.7 s streak chip · 2.1 s streak milestone */
.pts-burst b { padding: 10px 26px; border-radius: 26px; background: var(--surface); border: 3px solid var(--good);
  box-shadow: 0 12px 34px rgba(35, 32, 28, .22); text-shadow: none; font-size: 46px;
  animation: pts-pop 1.5s cubic-bezier(.2, .9, .3, 1.2) .1s both; }
.pts-burst i { animation: pts-spark .8s ease-out .25s forwards; }
.pts.pop { animation: pts-pill .7s cubic-bezier(.2, .9, .3, 1.6) 1s both; }
.streak-chip.pop { animation: pop .55s cubic-bezier(.2, .9, .3, 1.6) 1.7s both; }
.streak-burst { animation: burst 1.8s ease-out 2.1s both; }
@keyframes pts-pop {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.3); }
  22% { opacity: 1; transform: translate(-50%, -50%) scale(1.15); }
  38% { transform: translate(-50%, -50%) scale(1); }
  75% { opacity: 1; transform: translate(-50%, -60%) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -130%) scale(.75); }
}
@keyframes pts-spark { 0% { opacity: 1; transform: rotate(var(--a)) translateX(78px); } 100% { opacity: 0; transform: rotate(var(--a)) translateX(140px) scale(.4); } }

/* ---------------------------------------------------------------- smoother feedback motion
   Only transform and opacity are animated (runs on the graphics chip, no jank), with soft "ease-out" curves. */
.answer { position: relative; }
.answer.right { animation: right-in .45s cubic-bezier(.22, 1, .36, 1); }
.answer.right::after { content: ''; position: absolute; inset: -2px; border-radius: inherit; border: 3px solid var(--good); opacity: 0;
  pointer-events: none; animation: right-ring .9s cubic-bezier(.22, 1, .36, 1) both; }
@keyframes right-in { 0% { transform: scale(.97); } 60% { transform: scale(1.02); } 100% { transform: scale(1); } }
@keyframes right-ring { 0% { opacity: .55; transform: scale(1); } 100% { opacity: 0; transform: scale(1.06, 1.25); } }

.pts-burst b, .pts-burst i, .pts.pop, .streak-chip.pop, .feedback.enter { will-change: transform, opacity; backface-visibility: hidden; }
.pts-burst b { animation: pts-pop2 1.6s linear .1s both; }
@keyframes pts-pop2 {
  0%   { opacity: 0; transform: translate3d(-50%, -50%, 0) scale(.5); animation-timing-function: cubic-bezier(.34, 1.56, .64, 1); }
  20%  { opacity: 1; transform: translate3d(-50%, -50%, 0) scale(1); animation-timing-function: linear; }
  62%  { opacity: 1; transform: translate3d(-50%, -54%, 0) scale(1); animation-timing-function: cubic-bezier(.55, 0, .45, 1); }
  100% { opacity: 0; transform: translate3d(-50%, -125%, 0) scale(.85); }
}
.pts-burst i { animation: pts-spark2 .9s cubic-bezier(.22, 1, .36, 1) .3s both; }
@keyframes pts-spark2 { 0% { opacity: 0; transform: rotate(var(--a)) translate3d(70px, 0, 0) scale(1); } 15% { opacity: 1; }
  100% { opacity: 0; transform: rotate(var(--a)) translate3d(135px, 0, 0) scale(.3); } }

.pts.pop { animation: pts-pill2 .75s cubic-bezier(.34, 1.56, .64, 1) 1s both; }
@keyframes pts-pill2 { 0% { opacity: 0; transform: scale(.6); } 100% { opacity: 1; transform: scale(1); } }
.streak-chip.pop { animation: chip-in .6s cubic-bezier(.34, 1.56, .64, 1) 1.7s both; }
@keyframes chip-in { 0% { opacity: 0; transform: translate3d(-12px, 0, 0) scale(.85); } 100% { opacity: 1; transform: none; } }
.feedback.enter { animation: fb-in .5s cubic-bezier(.22, 1, .36, 1) both; }
@keyframes fb-in { 0% { opacity: 0; transform: translate3d(0, 16px, 0); } 100% { opacity: 1; transform: none; } }

/* admin: company list */
.co-list { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; }
.co-list li { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.co-req { padding-top: 10px; border-top: 1px solid var(--line); }
.co-req select { width: 100%; }

/* invites */
.invite-box { background: var(--indigo-soft); border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.invite-box.boost { background: var(--gold-soft); }
.invite-boost { align-self: flex-start; background: var(--gold); color: #5c4500; font-weight: 900; font-size: 13px; padding: 4px 10px; border-radius: 999px; }
.invite-code { font-weight: 900; font-size: 20px; letter-spacing: .12em; font-variant-numeric: tabular-nums; }
.mt { margin-top: 10px; }

/* ================================================================ learn (courses, chapter player, interactive ECG cards) */
:root { --lk-grid-minor: rgba(255, 38, 82, .16); --lk-grid-major: rgba(255, 38, 82, .38); --lk-paper: #FFFBF6; --lk-trace: #23201C; --lk-ext: #ECE6DC; --lk-surface-2: #EFE8DC; }
.nav.n6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.nav.n6 .nav-item { font-size: 11px; }
.screen.learn { padding-bottom: 32px; }
.lk-player, .lk-course, .lk-result { display: flex; flex-direction: column; gap: 14px; }
.lk-player [hidden], .lk-course [hidden] { display: none !important; }
.lk-single.lk-qrs { max-width: 170px; }
.lk-player { min-height: 100%; }
.lk-icon { width: 44px; height: 44px; border-radius: 22px; border: 0; background: var(--surface); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; color: var(--ink); }
.lk-kicker { font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); }
.lk-muted { color: var(--muted); margin: 0; }
.lk-h1 { margin: 0; font-size: 26px; font-weight: 900; line-height: 1.15; text-wrap: balance; }
.lk-h2 { margin: 0; font-size: clamp(23px, 6.2vw, 28px); font-weight: 900; line-height: 1.15; text-wrap: balance; letter-spacing: -.01em; }
.lk-eyebrow { font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.lk-body { max-width: 62ch; }
.lk-body p { margin: 0 0 10px; }
.lk-body p:last-child { margin-bottom: 0; }
.lk-list { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
.lk-note { font-size: 14px; background: var(--surface); border-radius: 14px; padding: 12px 14px; border-left: 0; }
.lk-note b { color: var(--accent-ink); }
.lk-scale { font-size: 12px; color: var(--muted); margin: 0; font-variant-numeric: tabular-nums; }
.lk-scale.block { display: block; margin-top: 6px; }
.lk-big { font-size: 24px; font-weight: 900; font-variant-numeric: tabular-nums; line-height: 1.1; }
.lk-panel { background: var(--surface); border-radius: 22px; padding: 14px; display: flex; flex-direction: column; gap: 12px; }
.lk-col { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.lk-figure, .lk-widget { display: flex; flex-direction: column; gap: 10px; }
.lk-fig { display: flex; justify-content: center; }
.lk-fig svg { width: min(100%, 340px); height: auto; }
.lk-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: 999px; border: 0; font-weight: 900; font-size: 16px; cursor: pointer; text-decoration: none; }
.lk-btn.primary { background: var(--accent); color: var(--on-accent); }
.lk-btn.ghost { background: transparent; border: 1.5px solid var(--line-strong); color: var(--ink); }
.lk-btn.wide { width: 100%; }
.lk-btn:disabled { opacity: .4; cursor: not-allowed; }
.lk-btn-inline { align-self: flex-start; background: var(--indigo); color: var(--on-indigo); min-height: 44px; }

/* player */
.lk-top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--bg); display: flex; align-items: center; gap: 10px; padding: 6px 0 4px; }
.lk-top-mid { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.lk-top-title { font-weight: 800; font-size: 15px; line-height: 1.25; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow-wrap: anywhere; }
.lk-count { font-size: 13px; font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; }
.lk-prog { display: flex; gap: 4px; }
.lk-prog span { flex: 1; height: 6px; border-radius: 99px; background: var(--lk-surface-2); transition: background .3s; }
.lk-prog span.on { background: var(--accent); }
.lk-stage { flex: 1; }
.lk-card { display: flex; flex-direction: column; gap: 14px; padding-bottom: 8px; }
.lk-card.enter { animation: lk-enter .35s ease both; }
@keyframes lk-enter { from { opacity: .0001; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.lk-foot { position: sticky; bottom: 0; z-index: 5; background: var(--bg); display: flex; gap: 10px; padding: 12px 0 calc(12px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--line); }
.lk-foot .primary { flex: 1; }
.lk-foot .ghost { background: var(--lk-surface-2); border: 0; }

/* strips */
.lk-leads { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.lk-leads.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.lk-leads.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.lk-leads.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.lk-tile { position: relative; display: block; background: var(--lk-paper); border: 2px solid transparent; border-radius: 10px; padding: 0; overflow: hidden; text-align: left; font: inherit; color: inherit; }
button.lk-tile { cursor: pointer; }
@media (hover: hover) and (pointer: fine) { button.lk-tile:hover { border-color: var(--line); } }
.lk-tile.hit { border-color: var(--good); } .lk-tile.miss { border-color: var(--bad-line); } .lk-tile.hl { border-color: var(--indigo); }
.lk-tile-name { position: absolute; top: 4px; left: 6px; font-size: 13px; font-weight: 900; background: var(--lk-paper); padding: 0 3px; border-radius: 4px; z-index: 1; }
.lk-strip { display: block; width: 100%; height: auto; }
.lk-trace { fill: none; stroke: var(--lk-trace); stroke-width: 1.7px; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.lk-single { max-width: 220px; }
.lk-single.big { max-width: 100%; }
.lk-band { fill: var(--accent); fill-opacity: .14; }
.lk-band.strong { fill-opacity: .35; stroke: var(--accent); stroke-width: .12; }
.lk-bracket { fill: none; stroke: var(--accent-ink); stroke-width: .25; }

/* dial */
.lk-dial-wrap { display: flex; justify-content: center; }
.lk-dial { width: min(100%, 290px); height: auto; display: block; overflow: visible; user-select: none; -webkit-user-select: none; }
.lk-dial:focus-visible { outline: 3px solid var(--indigo); outline-offset: 4px; border-radius: 50%; }
.lk-dial .ring { fill: var(--surface); stroke: var(--line); stroke-width: 2; }
.lk-dial .zones + .ring { fill: none; }
.lk-dial .z-normal { fill: var(--good-soft); } .lk-dial .z-lad { fill: var(--indigo-soft); } .lk-dial .z-rad { fill: var(--accent-soft); } .lk-dial .z-ext { fill: var(--lk-ext); }
.lk-dial .lead-axis line { stroke: var(--muted); stroke-width: 1.4; opacity: .55; }
.lk-dial .lead-axis line.neg { stroke: var(--lk-va); stroke-width: .9; opacity: .55; }
.lk-dial .lead-axis text { font: 800 13px 'Nunito', system-ui, sans-serif; fill: var(--ink); text-anchor: middle; dominant-baseline: central; }
.lk-dial .lead-axis .hit { fill: transparent; }
.lk-dial .lead-axis.on line.pos { stroke: var(--indigo); stroke-width: 3; opacity: 1; }
.lk-dial .lead-axis.on line.neg { stroke: var(--indigo); opacity: .6; }
.lk-dial .lead-axis.on .hit { fill: var(--indigo-soft); }
.lk-dial .lead-axis.on text { fill: var(--indigo); }
.lk-dial.tap .lead-axis { cursor: pointer; }
.lk-dial .deg { font: 700 9px 'Nunito', system-ui, sans-serif; fill: var(--muted); text-anchor: middle; dominant-baseline: central; }
.lk-dial .vec line { stroke: var(--accent); stroke-width: 5; stroke-linecap: round; }
.lk-dial .vec path { fill: var(--accent); }
.lk-dial .vec .handle { fill: var(--accent); opacity: .18; }
.lk-dial.drag { cursor: grab; touch-action: none; }
.lk-dial .ghost line { stroke: var(--indigo); stroke-width: 4; stroke-dasharray: 6 5; stroke-linecap: round; }
.lk-dial .ghost path { fill: var(--indigo); }
.lk-dial .hub { fill: var(--ink); }
.lk-dial-row { display: flex; flex-direction: column; gap: 12px; }
@media (min-width: 700px) { .lk-dial-row { display: grid; grid-template-columns: 1fr 1fr; align-items: center; } }
.lk-readout2 { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: nowrap; min-width: 0; }
.lk-readout2 .lk-angle { flex: none; min-width: 4.2ch; font-variant-numeric: tabular-nums; }
.lk-readout2 .lk-zone { flex: 0 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
.lk-readout-note { min-height: 20px; font-size: 13px; font-weight: 800; color: var(--muted); text-align: right; }
.lk-angle { font-size: 30px; font-weight: 900; font-variant-numeric: tabular-nums; letter-spacing: -.02em; line-height: 1; }
.lk-zone { display: inline-flex; font-size: 13px; font-weight: 800; padding: 5px 12px; border-radius: 99px; }
.lk-zone.normal { background: var(--good-soft); color: var(--good-ink); } .lk-zone.lad { background: var(--indigo-soft); color: var(--indigo); }
.lk-zone.rad { background: var(--accent-soft); color: var(--accent-ink); } .lk-zone.ext { background: var(--lk-ext); color: var(--muted); }
.lk-slider-label { font-size: 12px; color: var(--muted); font-weight: 700; }
.lk-col input[type=range] { min-height: 0; padding: 0; border: 0; accent-color: var(--accent); }
.lk-status { font-weight: 700; font-size: 15px; min-height: 3.2em; }
.lk-info { display: grid; grid-template-columns: minmax(0, 1fr) 92px; gap: 12px; align-items: center; }
.lk-info h3 { margin: 0; font-size: 19px; font-weight: 900; }
.lk-info p { margin: 4px 0 0; font-size: 15px; }
.lk-deg { color: var(--indigo); font-variant-numeric: tabular-nums; }

/* chips, info, feedback */
.lk-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.lk-chip { min-height: 38px; padding: 0 14px; border-radius: 99px; border: 1.5px solid var(--line); background: var(--surface); font-weight: 800; font-size: 14px; cursor: pointer; color: var(--ink); }
.lk-chip.on { background: var(--indigo); border-color: var(--indigo); color: var(--on-indigo); }
.lk-chip-n { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; margin: 0 6px 0 -6px; border-radius: 50%; background: var(--indigo-soft); color: var(--indigo); font-size: 12px; font-weight: 900; vertical-align: middle; }
.lk-chip.on .lk-chip-n { background: var(--on-indigo); color: var(--indigo); }
.lk-infobox { font-size: 15px; min-height: 2.6em; }
.lk-infobox b { color: var(--indigo); }
/* fixed height: longer or shorter phase texts never move the button or the page */
.lk-phase { font-size: 15px; font-weight: 700; line-height: 1.45; height: 5.8em; overflow: hidden; }
.lk-feedback { border-radius: 14px; padding: 12px 14px; font-size: 15px; background: var(--surface); border: 1.5px solid var(--line-strong); }
.lk-feedback.good { border-color: var(--fb-ok-line); } .lk-feedback.good strong { color: var(--good-ink); }
.lk-feedback.bad { border-color: var(--fb-bad-line); } .lk-feedback.bad strong { color: var(--bad); }
.lk-feedback strong { display: block; font-weight: 900; margin-bottom: 2px; }
.lk-round { font-size: 13px; font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; }
.lk-readout { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
/* segmented choices look like the chips: every option is a visible, outlined button; the chosen one is filled */
.lk-seg { display: inline-flex; flex-wrap: wrap; gap: 6px; align-self: flex-start; }
.lk-seg button { min-height: 38px; border: 1.5px solid var(--line-strong); background: var(--surface); padding: 0 14px; border-radius: 99px; font-weight: 800; cursor: pointer; color: var(--ink); font-size: 14px; }
.lk-seg button[aria-pressed="true"] { background: var(--indigo); border-color: var(--indigo); color: var(--on-indigo); }
@media (hover: hover) and (pointer: fine) { .lk-seg button:hover:not([aria-pressed="true"]) { border-color: var(--indigo); } }
/* all options in one row, sharing the width (e.g. the phases of the action potential) */
.lk-seg.one-row { display: flex; flex-wrap: nowrap; align-self: stretch; gap: 4px; }
.lk-seg.one-row button { flex: 1 1 auto; padding: 0 6px; min-width: 0; font-size: 13px; white-space: nowrap; }

/* quiz */
.lk-prompt { margin: 0; font-size: 17px; font-weight: 700; }
.lk-opts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.lk-opts.one { grid-template-columns: 1fr; }
.lk-opt { background: var(--surface); border: 2px solid var(--line); border-radius: 14px; padding: 13px 12px; font-weight: 800; cursor: pointer; text-align: center; font-size: 15px; color: var(--ink); min-height: 52px; }
.lk-opts.one .lk-opt { text-align: left; }
@media (hover: hover) and (pointer: fine) { .lk-opt:hover:not(:disabled) { border-color: var(--accent); } }
.lk-opt.right { border-color: var(--good); background: var(--good-soft); color: var(--good-ink); }
.lk-opt.wrong { border-color: var(--bad-line); background: var(--bad-soft); color: var(--bad); }
.lk-opt:disabled { cursor: default; }

/* rules, quadrant, shapes, table */
.lk-rules { display: flex; flex-direction: column; gap: 8px; }
.lk-rule { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 12px; align-items: center; background: var(--surface); border-radius: 14px; padding: 8px 12px 8px 8px; }
.lk-rule b { display: block; font-weight: 800; }
.lk-rule span { font-size: 14px; color: var(--muted); }
.lk-quad { display: grid; grid-template-columns: 60px 1fr 1fr; gap: 6px; }
.lk-quad div { border-radius: 10px; padding: 12px 8px; font-weight: 800; font-size: 14px; line-height: 1.25; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.lk-quad .h { color: var(--muted); font-size: 13px; padding: 4px; }
.lk-quad .ok { background: var(--good-soft); color: var(--good-ink); } .lk-quad .lad { background: var(--indigo-soft); color: var(--indigo); }
.lk-quad .rad { background: var(--accent-soft); color: var(--accent-ink); } .lk-quad .ext { background: var(--lk-ext); color: var(--muted); }
.lk-quad small { font-weight: 600; font-size: 12px; }
.lk-shapes { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.lk-shape { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.lk-shape b { font-size: 16px; }
.lk-table-wrap { overflow-x: auto; background: var(--surface); border-radius: 16px; }
.lk-table { border-collapse: collapse; width: 100%; font-size: 15px; }
.lk-table th, .lk-table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.lk-table thead th { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.lk-table tr:last-child th, .lk-table tr:last-child td { border-bottom: 0; }

/* heart, torso, chest, einthoven */
.lk-heart-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; align-items: center; }
.lk-heart-box svg { width: 100%; height: auto; display: block; }
.lk-heart-side { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.lk-heart .lk-region { fill: var(--accent); fill-opacity: .08; stroke: #D9C8B4; stroke-width: 1.5; cursor: pointer; transition: fill-opacity .2s; }
.lk-heart .lk-region.sel { fill-opacity: .3; }
.lk-heart .lk-septum { fill: none; stroke: #D9C8B4; stroke-width: 1.5; }
.lk-heart .lk-path { fill: none; stroke: #E2B66D; stroke-width: 3.2; stroke-linecap: round; cursor: pointer; }
.lk-heart .lk-path.thin { stroke-width: 1.6; }
.lk-heart .lk-path.sel { stroke: var(--indigo); stroke-width: 4.5; }
.lk-heart .lk-path.thin.sel { stroke-width: 2.6; }
.lk-heart .lk-flow { fill: none; stroke: var(--accent); stroke-width: 4.5; stroke-linecap: round; opacity: 0; pointer-events: none; }
.lk-heart .lk-node { fill: #E2B66D; stroke: #fff; stroke-width: 2; cursor: pointer; }
.lk-heart .lk-node.sel { fill: var(--indigo); }
.lk-heart .lk-node.fire { fill: var(--accent); }
.lk-heart .lk-hlabels text { font: 800 10px 'Nunito', system-ui, sans-serif; fill: var(--muted); pointer-events: none; }
.lk-heart .lk-block path { stroke: var(--bad-line); stroke-width: 4; stroke-linecap: round; }
.lk-heart .lk-lead { fill: none; stroke: var(--ink); stroke-width: 3; stroke-linecap: round; }
.lk-heart .lk-lead-tip { fill: var(--indigo); stroke: #fff; stroke-width: 1.5; }
.lk-heart-fig svg { width: min(100%, 240px); }
.lk-torso .body, .lk-chest .body { fill: var(--lk-surface-2); stroke: #D9C8B4; stroke-width: 1.5; }
.lk-torso .bone { fill: none; stroke: #CDBBA5; stroke-width: 3; stroke-linecap: round; }
.lk-torso .rib { fill: none; stroke: #DCCDBA; stroke-width: 1.4; }
.lk-torso .guide { fill: none; stroke: #CDBBA5; stroke-width: 1; stroke-dasharray: 3 3; }
.lk-el { cursor: pointer; }
.lk-el circle { fill: var(--surface); stroke: var(--accent); stroke-width: 2; }
.lk-el text { font: 900 8px 'Nunito', system-ui, sans-serif; fill: var(--accent-ink); text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.lk-torso .lk-el text { font-size: 7.5px; }
.lk-el.on circle { fill: var(--indigo); stroke: var(--indigo); }
.lk-el.on text { fill: var(--on-indigo); }
.lk-el:focus-visible { outline: none; }
.lk-el:focus-visible circle { stroke: var(--indigo); stroke-width: 3; }
.lk-chest .rv { fill: var(--indigo-soft); stroke: var(--indigo); stroke-width: 1; }
.lk-chest .lv { fill: var(--accent-soft); stroke: var(--accent); stroke-width: 1; }
.lk-chest .cap { font: 700 9px 'Nunito', system-ui, sans-serif; fill: var(--muted); text-anchor: middle; }
.lk-chest .cap2 { font: 800 9px 'Nunito', system-ui, sans-serif; fill: var(--ink); text-anchor: middle; dominant-baseline: central; }
.lk-chest .vec path { stroke: var(--accent); stroke-width: 3; fill: var(--accent); stroke-linecap: round; }
.lk-chest .lk-el text { font-size: 7px; }
.lk-ein .tri { fill: var(--lk-surface-2); stroke: #D9C8B4; stroke-width: 1.5; }
.lk-ein .ax path { stroke: var(--indigo); stroke-width: 2; fill: var(--indigo); }
.lk-ein .ax text, .lk-ein .aug text { font: 900 12px 'Nunito', system-ui, sans-serif; fill: var(--indigo); text-anchor: middle; dominant-baseline: central; }
.lk-ein .aug path { stroke: var(--accent); stroke-width: 1.5; stroke-dasharray: 4 3; fill: none; }
.lk-ein .aug circle { fill: var(--accent); }
.lk-ein .aug text { fill: var(--accent-ink); font-size: 10px; }
.lk-ein .el circle { fill: var(--surface); stroke: var(--ink); stroke-width: 1.5; }
.lk-ein .el text { font: 900 10px 'Nunito', system-ui, sans-serif; fill: var(--ink); text-anchor: middle; dominant-baseline: central; }

/* caliper */
.lk-caliper { max-width: 100%; }
.lk-caliper svg { cursor: ew-resize; }
.lk-caliper svg:focus-visible { outline: 3px solid var(--indigo); outline-offset: 2px; }
.lk-cal line { stroke: var(--indigo); stroke-width: .22; }
.lk-cal circle { fill: var(--indigo); }
.lk-cal .hit { fill: transparent; }

/* timeline, checks */
.lk-timeline { display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.lk-tl-head { font-weight: 800; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.lk-tl-row { display: grid; grid-template-columns: 26px 1fr; gap: 6px; align-items: center; font-weight: 800; }
.lk-tl { position: relative; height: 12px; background: var(--lk-surface-2); border-radius: 6px; }
.lk-tl i { position: absolute; top: 0; bottom: 0; background: var(--accent); border-radius: 6px; }
.lk-tl-scale { display: flex; justify-content: space-between; padding-left: 32px; color: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.lk-checks { display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.lk-check { display: grid; grid-template-columns: 22px 1fr; gap: 6px; align-items: start; }
.lk-check > span:first-child { width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; }
.lk-check.ok > span:first-child { background: var(--good-soft); color: var(--good-ink); }
.lk-check.no > span:first-child { background: var(--bad-soft); color: var(--bad); }

/* summary, practice */
.lk-done-hero { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding-top: 6px; }
.lk-done-badge { width: 78px; height: 78px; border-radius: 50%; background: var(--good-soft); color: var(--good-ink); display: flex; align-items: center; justify-content: center; animation: lk-pop .5s cubic-bezier(.34, 1.56, .64, 1) both; }
.lk-done-badge svg { width: 36px; height: 36px; }
.lk-done-badge.gold { background: var(--gold-soft); color: var(--gold-ink); border: 4px solid var(--gold); }
.lk-done-badge.retry { background: var(--bad-soft); color: var(--bad); }
@keyframes lk-pop { from { transform: scale(.6); opacity: .0001; } to { transform: none; opacity: 1; } }
.lk-takeaways { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.lk-takeaways li { background: var(--surface); border-radius: 14px; padding: 12px 14px 12px 40px; position: relative; font-size: 15px; }
.lk-takeaways li::before { content: ""; position: absolute; left: 14px; top: 16px; width: 14px; height: 14px; border-radius: 50%; background: var(--good-soft); box-shadow: inset 0 0 0 4px var(--good); }
.lk-practice { display: flex; flex-direction: column; gap: 12px; background: var(--indigo-soft); border-radius: 18px; padding: 14px; }
.lk-practice b { display: block; color: var(--indigo); font-weight: 900; }
.lk-practice span { font-size: 14px; }

/* course list & course page */
.lk-subject { display: flex; flex-direction: column; gap: 10px; }
.lk-subject-title { margin: 6px 0 0; font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.lk-course-card { display: flex; gap: 14px; align-items: center; background: var(--surface); border: 0; border-radius: 22px; padding: 16px; text-align: left; cursor: pointer; font: inherit; color: inherit; width: 100%; }
.lk-course-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.lk-course-main strong { font-size: 17px; font-weight: 900; }
.lk-course-main > span, .lk-course-main p { color: var(--muted); font-size: 14px; margin: 0; }
.lk-course-meta { display: inline-flex; align-items: center; gap: 4px; flex-wrap: wrap; font-size: 13px; font-weight: 700; color: var(--muted); }
.lk-course-ring { --p: 0%; width: 56px; height: 56px; border-radius: 50%; flex-shrink: 0; background: conic-gradient(var(--accent) var(--p), var(--lk-surface-2) 0); display: flex; align-items: center; justify-content: center; }
.lk-course-ring span { width: 44px; height: 44px; border-radius: 50%; background: var(--surface); display: flex; align-items: center; justify-content: center; font-weight: 900; font-size: 13px; color: var(--ink); }
.lk-course-ring.big { width: 72px; height: 72px; }
.lk-course-ring.big span { width: 58px; height: 58px; font-size: 16px; }
.lk-course-head { display: flex; align-items: center; gap: 10px; }
.lk-course-hero { display: flex; gap: 14px; align-items: center; }
.lk-chapters { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.lk-chapter { display: flex; gap: 12px; align-items: flex-start; width: 100%; background: var(--surface); border: 0; border-radius: 18px; padding: 14px; text-align: left; cursor: pointer; font: inherit; color: inherit; }
.lk-chapter.locked { cursor: not-allowed; opacity: .6; }
.lk-num { width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-weight: 900; background: var(--accent-soft); color: var(--accent-ink); }
.lk-chapter.done .lk-num { background: var(--good-soft); color: var(--good-ink); }
.lk-chapter.locked .lk-num { background: var(--lk-surface-2); color: var(--muted); }
.lk-ch-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.lk-ch-main strong { font-weight: 900; }
.lk-ch-main > span { color: var(--muted); font-size: 14px; }
.lk-exam { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; background: var(--gold-soft); border-radius: 22px; padding: 16px; }
.lk-exam.locked { background: var(--surface); opacity: .75; }
.lk-exam.passed { background: var(--gold-soft); }
.lk-exam-badge { width: 44px; height: 44px; border-radius: 50%; background: var(--surface); color: var(--gold-ink); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.lk-exam .lk-btn { margin-left: auto; }
.lk-empty { background: var(--surface); border-radius: 22px; padding: 18px; color: var(--muted); }
.lk-result { align-items: center; text-align: center; padding-top: 40px; }
.lk-big-score { font-size: 44px; font-weight: 900; margin: 0; font-variant-numeric: tabular-nums; }
.learn-intro { margin: 0; color: var(--muted); }

@media (max-width: 380px) { .lk-heart-row { grid-template-columns: 1fr; } .lk-shapes { grid-template-columns: repeat(2, minmax(0, 1fr)); } .lk-leads.four { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (prefers-reduced-motion: reduce) { .lk-card.enter, .lk-done-badge { animation: none; } }
.lh-learn-table { width: 100%; border-collapse: collapse; font-size: 14px; margin-top: 6px; }
.lh-learn-table th, .lh-learn-table td { text-align: left; padding: 6px 4px; border-top: 1px solid var(--line); }
.lh-learn-table th { font-size: 12px; color: var(--muted); }
.lh-learn-table td + td, .lh-learn-table th + th { text-align: right; width: 70px; font-variant-numeric: tabular-nums; }

/* leaderboard: rank colours for 1–3, trophies and duels per player, player card */
.rk { width: 30px; height: 30px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; font-variant-numeric: tabular-nums; }
.rk.gold { background: #fff2d4; color: #5c4500; box-shadow: inset 0 0 0 2px #ffbf21; }
.rk.silver { background: #e4eeef; color: #344042; box-shadow: inset 0 0 0 2px #a8baba; }
.rk.bronze { background: #fcded4; color: #520000; box-shadow: inset 0 0 0 2px #ff5729; }
.lb-open { background: none; border: 0; padding: 0; text-align: left; font: inherit; color: inherit; cursor: pointer; min-width: 0; }
.achs { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 4px; }
.ach { display: inline-flex; align-items: center; gap: 3px; font-size: 13px; }
.ach b { font-weight: 800; font-variant-numeric: tabular-nums; }
.ach.duel { color: var(--indigo); }

.player-card { gap: 14px; }
.pc-av { width: 54px; height: 54px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-deep); font-weight: 900; font-size: 19px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.pc-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pc-stats > div { background: var(--bg); border-radius: 14px; padding: 10px; display: flex; flex-direction: column; }
.pc-stats strong { font-size: 20px; font-variant-numeric: tabular-nums; }
.pc-medals { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pc-medal { background: var(--bg); border-radius: 14px; padding: 10px 6px; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.pc-medal strong { font-size: 18px; font-variant-numeric: tabular-nums; }
.pc-medal.zero { opacity: .45; }
/* hints next to the avatar */
.hello-right { display: flex; align-items: center; gap: 8px; }
.hint-btn { position: relative; height: 40px; min-width: 40px; padding: 0 10px; border-radius: 20px; border: 0; display: inline-flex; align-items: center; justify-content: center; gap: 4px; cursor: pointer; font: inherit; font-weight: 900; }
.hint-btn.bell { background: var(--gold-soft); color: var(--gold-ink); }
.hint-btn.bell i { position: absolute; top: 7px; right: 8px; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px var(--gold-soft); }
.hint-btn.duel { background: var(--indigo-soft); color: var(--indigo); }
@media (prefers-reduced-motion: no-preference) { .hint-btn.bell svg { animation: bell-ring 1.4s ease-in-out 1s 2; transform-origin: 50% 10%; } }
@keyframes bell-ring { 0%, 100% { transform: rotate(0); } 15% { transform: rotate(14deg); } 30% { transform: rotate(-12deg); } 45% { transform: rotate(8deg); } 60% { transform: rotate(-5deg); } 75% { transform: rotate(0); } }
/* update box in Settings & info */
.update-box { background: var(--gold-soft); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.update-box .changes { margin: 6px 0 0; }
.update-ok { gap: 10px; }
.mail-log { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.mail-log li { padding: 8px 0; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 2px; }

/* asking for notifications */
.push-ask { display: flex; flex-direction: column; gap: 12px; background: var(--gold-soft); }
.push-ask svg { color: var(--gold-ink); flex-shrink: 0; }
.push-ask-sheet .lvl-badge { background: var(--gold-soft); color: var(--gold-ink); }

/* step-by-step controls for animations */
.lk-stepper { display: flex; flex-direction: column; gap: 10px; }
.lk-steps { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.lk-step-btn { width: 44px; height: 44px; border-radius: 22px; border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--ink); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; }
.lk-step-btn:disabled { opacity: .35; cursor: default; }
.lk-steps .lk-play { align-self: auto; min-width: 128px; }
.lk-step-count { font-size: 13px; font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; margin-left: auto; }

/* question statistics: ring = learning progress, shown · right · wrong */
.qstat { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; }
.qstat b { color: var(--ink); }
.qstat .qs-ok { color: var(--good-ink); font-weight: 700; }
.qstat .qs-no { color: var(--bad); font-weight: 700; }
.qstat.new span:last-child { font-weight: 800; color: var(--indigo); }
.qring { --p: 0%; width: 22px; height: 22px; border-radius: 50%; flex-shrink: 0; background: conic-gradient(var(--good) var(--p), var(--track) 0); display: inline-flex; align-items: center; justify-content: center; }
.qring::after { content: ""; width: 14px; height: 14px; border-radius: 50%; background: var(--surface); }
.qstat.done .qring { background: var(--good); }
.qring.big { width: 58px; height: 58px; position: relative; }
.qring.big::after { width: 46px; height: 46px; }
.qring.big b { position: absolute; font-size: 13px; font-weight: 900; color: var(--ink); }
/* focus list */
.focus-card { display: flex; align-items: center; gap: 12px; border: 1.5px solid var(--accent-soft); font: inherit; color: inherit; text-align: left; cursor: pointer; width: 100%; }
.focus-card > svg:last-child { transform: rotate(180deg); color: var(--muted); flex-shrink: 0; }
.focus-card .bar { margin-top: 4px; }
.focus-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.focus-item { display: flex; gap: 10px; align-items: flex-start; padding: 14px 14px 14px 16px; font-size: 15px; }
/* glossary: choose questions */
.term-sheet { max-height: 86vh; overflow-y: auto; }
.pick-list { list-style: none; margin: 4px 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.pick-row { display: flex; gap: 10px; align-items: flex-start; width: 100%; text-align: left; font: inherit; font-size: 15px; color: inherit; background: var(--bg); border: 0; border-radius: 14px; padding: 12px; cursor: pointer; }
.pick-row.in { background: var(--surface-2); color: var(--muted); cursor: default; }
.pick-in { display: inline-flex; align-items: center; gap: 4px; font-weight: 700; color: var(--muted); }
.pick-box { width: 24px; height: 24px; border-radius: 7px; border: 2px solid var(--line-strong); background: var(--surface); flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; margin-top: 1px; }
.pick-box.on { background: var(--good); border-color: var(--good); color: var(--on-good); }
.pick-row.in .pick-box.on { background: var(--line-strong); border-color: var(--line-strong); color: var(--ink); }

/* admin: app version per member */
.client-list { display: flex; flex-wrap: wrap; gap: 6px; }
.client { font-size: 12.5px; background: var(--bg); border-radius: 999px; padding: 4px 10px; color: var(--muted); }
.client.app b { color: var(--indigo); }
.client-ok { color: var(--good-ink); font-weight: 700; }
.client-old { color: var(--bad); font-weight: 700; }

/* admins: registrations waiting */
.hint-btn.admin { background: var(--indigo-soft); color: var(--indigo); }

/* admin: tabs in one row with counters */
.atabs { display: flex; gap: 6px; overflow-x: auto; margin: 0 -16px; padding: 2px 16px 6px; scrollbar-width: none; }
.atabs::-webkit-scrollbar { display: none; }
.atab { flex-shrink: 0; min-height: 40px; padding: 0 14px; border-radius: 20px; border: 0; background: var(--surface); font: inherit; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; color: var(--ink); }
.atab.on { background: var(--ink); color: var(--surface); }
.atab b { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--accent); color: var(--on-accent); font-size: 12px; display: inline-flex; align-items: center; justify-content: center; }
/* admin: to-do cards */
.todo { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; font: inherit; color: inherit; border: 0; cursor: pointer; }
.todo > svg:last-child { transform: rotate(180deg); color: var(--muted); flex-shrink: 0; }
.todo-n { min-width: 44px; height: 44px; padding: 0 8px; border-radius: 14px; background: var(--accent-soft); color: var(--accent-deep); font-size: 20px; font-weight: 900; display: inline-flex; align-items: center; justify-content: center; }
.todo.done { cursor: default; color: var(--good-ink); font-weight: 700; }
button.kpi { font: inherit; color: inherit; border: 0; text-align: left; cursor: pointer; }
/* admin: compact player list */
.msearch { width: 100%; }
.mrow { padding: 0; overflow: hidden; }
.mrow-head { display: flex; gap: 10px; align-items: center; width: 100%; padding: 14px 16px; background: none; border: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.mrow-tags { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex-shrink: 0; }
.mrow-quick { padding: 0 16px 14px; gap: 8px; }
.mdetail { padding: 0 16px 16px; border-top: 1px solid var(--line); padding-top: 12px; }
.mrow.open { box-shadow: 0 0 0 2px var(--indigo-soft); }
.role-tag { font-size: 12px; font-weight: 800; padding: 3px 9px; border-radius: 999px; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.role-tag.author { background: var(--good-soft); color: var(--good-ink); }
.role-tag.editor { background: var(--indigo-soft); color: var(--indigo); }
.role-tag.gadmin { background: var(--accent-soft); color: var(--accent-deep); }

.chips.one-row { flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 0 16px 4px; scrollbar-width: none; }
.chips.one-row::-webkit-scrollbar { display: none; }
.chips.one-row .chip { flex-shrink: 0; }
.admin .kpis { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }

/* admin: learn progress per player */
.ch-dots { display: inline-flex; gap: 3px; flex-wrap: wrap; }
.ch-dots i { width: 11px; height: 11px; border-radius: 50%; background: var(--track); }
.ch-dots i.started { background: linear-gradient(90deg, var(--good) 50%, var(--track) 50%); }
.ch-dots i.done { background: var(--good); }
.learners { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.learners li { background: var(--bg); border-radius: 14px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; font-size: 15px; }
.learner-sub { align-items: center; gap: 10px; }
.ex-ok { color: var(--good-ink); font-weight: 700; display: inline-flex; align-items: center; gap: 4px; }
.ex-no { color: var(--muted); font-weight: 700; }
.learn-mini { display: inline-flex; align-items: center; gap: 3px; color: var(--indigo); font-weight: 700; }
.learn-mini.passed { color: var(--good-ink); }
.learn-line { display: flex; flex-direction: column; gap: 4px; }
.qs-line { gap: 8px; align-items: center; }
.imports summary { cursor: pointer; }
.imports-2 { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 6px; }
.imports summary { list-style: none; display: flex; justify-content: space-between; align-items: center; }
.imports summary::-webkit-details-marker { display: none; }
.imports summary::after { content: "+"; font-size: 22px; font-weight: 700; color: var(--muted); }
.imports[open] summary::after { content: "–"; }

/* graduation cap: course final test passed */
.ach.cap { color: var(--indigo); }
.pc-caps { display: flex; flex-wrap: wrap; gap: 6px; }
.pc-cap { display: inline-flex; align-items: center; gap: 6px; background: var(--indigo-soft); color: var(--indigo); font-weight: 700; font-size: 14px; border-radius: 999px; padding: 6px 12px; }

/* profile: Admin next to the settings gear */
.prof-top { gap: 8px; }
.admin-top { position: relative; height: 40px; padding: 0 14px; border-radius: 20px; border: 0; background: var(--indigo-soft); color: var(--indigo); font: inherit; font-weight: 800; font-size: 14px; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.admin-top b { min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: var(--accent); color: var(--on-accent); font-size: 12px; display: inline-flex; align-items: center; justify-content: center; }

/* calmer weekly goal card: ring + text, then one row of three figures */
.card.goal { flex-wrap: wrap; row-gap: 14px; }
.goal-stats { flex-basis: 100%; display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); padding-top: 12px; }
.goal-stats > div { display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; }
.goal-stats > div + div { border-left: 1px solid var(--line); }
.goal-stats strong { display: inline-flex; align-items: center; gap: 5px; font-size: 19px; font-weight: 900; font-variant-numeric: tabular-nums; }
.goal-stats strong svg { color: var(--muted); }
.goal-stats span { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.card.goal > .stack-s { flex: 1 1 0; min-width: 0; }

/* start button: play circle, title and what to expect */
.start-btn { width: 100%; display: flex; align-items: center; gap: 14px; padding: 14px 18px 14px 14px; border: 0; border-radius: 22px; background: var(--accent); color: var(--on-accent); font: inherit; text-align: left; cursor: pointer; box-shadow: 0 6px 18px var(--accent-shadow); }
.start-btn:active { transform: scale(.985); }
.start-btn[disabled] { opacity: .6; }
.start-play { width: 52px; height: 52px; border-radius: 50%; background: var(--surface); color: var(--accent); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.start-play svg { margin-left: 3px; }
.start-btn strong { font-size: 19px; font-weight: 900; }
.start-btn .stack-0 > span { font-size: 14px; opacity: .9; }
.start-btn > svg:last-child { transform: rotate(180deg); opacity: .8; flex-shrink: 0; }

/* topics page: sections, labels inside the cards, help sheet */
.sec-h { margin-top: 8px; display: flex; align-items: baseline; gap: 8px; }
.sec-h .muted { font-size: 15px; font-weight: 700; }
.topic-label { font-size: 12.5px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin-bottom: -6px; }
.help-btn { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 14px; border-radius: 19px; border: 0; background: var(--indigo-soft); color: var(--indigo); font: inherit; font-weight: 800; font-size: 14px; cursor: pointer; }
.help-sheet { max-height: 88vh; overflow-y: auto; gap: 0 !important; padding-top: 10px; }
.help-sheet::before { content: ''; display: block; width: 40px; height: 5px; border-radius: 3px; background: var(--line-strong); margin: 0 auto 12px; }
.help-head { padding-bottom: 6px; }
.help-head .h2 { font-size: 21px; }
.help-items { display: flex; flex-direction: column; }
.help-item { display: flex; gap: 14px; align-items: flex-start; font-size: 15px; line-height: 1.45; padding: 12px 0; border-top: 1px solid var(--line); }
.help-item:first-child { border-top: 0; }
.help-item strong { font-size: 16px; }
.help-item .stack-0 span { color: var(--muted); }
.help-ic { width: 40px; height: 40px; border-radius: 12px; background: var(--indigo-soft); color: var(--indigo); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.help-sheet .help-notify { margin-top: 8px; }
.help-sheet > .btn { position: sticky; bottom: 0; margin-top: 14px; box-shadow: 0 -12px 0 var(--surface); }
.help-ic .qring { width: 20px; height: 20px; }
.help-ic .qring::after { width: 12px; height: 12px; }

/* "?" help button: quiet, on every main page */
.help-q { width: 36px; height: 36px; border-radius: 50%; border: 1.5px solid var(--line); background: transparent; color: var(--muted); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0; padding: 0; }
.help-q:active { background: var(--indigo-soft); color: var(--indigo); }
.duel-top { gap: 10px; }

/* "?" sits right after the page title: small, no frame */
.title-row { display: flex; align-items: center; gap: 4px; min-width: 0; }
.help-q { width: 30px; height: 30px; border: 0; color: var(--muted); }
.help-q svg { width: 20px; height: 20px; }
.hello-line { display: flex; align-items: center; gap: 2px; }
.hello-line .help-q { width: 26px; height: 26px; }
.hello-line .help-q svg { width: 18px; height: 18px; }

.help-notify { background: var(--gold-soft); border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; font-size: 15px; line-height: 1.4; }
.help-notify strong { display: inline-flex; align-items: center; gap: 6px; }
.help-notify .btn { align-self: flex-start; }
.help-notify.ok { flex-direction: row; align-items: center; background: var(--good-soft); color: var(--good-ink); font-weight: 700; }

/* ---------------------------------------------------------------- colour scheme picker (Profile) */
.theme-pick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.theme-opt { position: relative; font-weight: 400; }
.theme-opt input { position: absolute; opacity: 0; }
.theme-tile { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 10px 6px; border-radius: 16px; border: 2px solid var(--line); background: var(--surface); cursor: pointer; min-height: 88px; justify-content: center; }
.theme-tile b { font-size: 14px; font-weight: 800; }
.theme-opt input:checked + .theme-tile { border-color: var(--accent); background: var(--accent-soft); }
.theme-opt input:checked + .theme-tile b { color: var(--accent-deep); }
.theme-opt input:focus-visible + .theme-tile { outline: 3px solid var(--indigo); outline-offset: 2px; }
.theme-swatch { width: 56px; height: 36px; border-radius: 10px; border: 1px solid var(--line-strong); display: inline-flex; align-items: center; justify-content: center; gap: 4px; }
.theme-swatch i { width: 14px; height: 14px; border-radius: 50%; }
.lk-judge-q { margin-top: 6px; }

/* chapter in progress: small ring with % on the course page */
.lk-num.ring { width: 40px; height: 40px; background: conic-gradient(var(--accent) var(--p), var(--track) 0); }
.lk-num.ring > span { width: 32px; height: 32px; border-radius: 50%; background: var(--surface); display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 900; color: var(--accent-deep); }
.course-set { margin-top: 8px; grid-template-columns: repeat(2, minmax(0, 1fr)); } .course-set label { font-weight: 400; min-width: 0; } .course-set select { min-width: 0; padding-right: 8px; }

/* glossary: picture of a limb lead – triangle and hexaxial side by side, typical curve below */
.lk-lead-fig { display: flex; flex-direction: column; gap: 8px; background: var(--surface-2); border-radius: 14px; padding: 10px; }
.lk-lead-pics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; align-items: center; }
.lk-lead-pics .lk-ein, .lk-lead-pics .lk-dial-wrap, .lk-lead-pics .lk-dial { width: 100%; max-width: 100%; height: auto; }
.lk-lead-fig .lk-deg { font-weight: 800; font-size: 14px; color: var(--ink); }
.lk-lead-fig .lk-tile { max-height: 120px; align-self: center; }
.lk-lead-fig .lk-tile svg { max-height: 110px; width: 100%; }
.lk-ein.hl .off { opacity: .22; }
.lk-ein.hl .ax.on path:first-child { stroke-width: 3.5; }
.lk-ein.hl .aug.on path { stroke-width: 3; stroke-dasharray: none; }
.flag { font-size: 1.15em; line-height: 1; margin-right: 5px; vertical-align: -0.1em; font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif; }

/* ================================================================ learn: anatomy drawings (Medical Anatomy & Terminology) */
:root {
  --an-skin: var(--surface-2); --an-line: var(--line-strong); --an-bone: #cdbba5; --an-bone-fill: #fffaf4;
  --an-heart: #ffd9de; --an-heart-line: #ff9ead; --an-blood: var(--accent-soft); --an-hl: var(--indigo); --an-hl-soft: var(--indigo-soft);
  --an-mark: var(--accent); --an-faint: var(--line-strong); --an-warn: #ff2652;
}
:root[data-theme="fresh"] { --an-bone: #a8baba; --an-bone-fill: #ffffff; }
:root[data-theme="dark"] { --an-bone: #a8baba; --an-bone-fill: #4a585a; --an-heart: #3b0012; --an-heart-line: #ff9ead; --an-faint: #6d7f80; }
.an-wrap svg { width: min(100%, 360px); height: auto; display: block; overflow: visible; }
.an-svg text { font-family: 'Nunito', system-ui, sans-serif; }
.an-svg { -webkit-tap-highlight-color: transparent; }
.an-fig-out > * { fill: var(--an-line); stroke: var(--an-line); stroke-width: 3px; stroke-linejoin: round; stroke-linecap: round; }
.an-fig > * { fill: var(--an-skin); stroke: none; }
.an-fig .limb, .an-fig-out path[style] { fill: none; stroke-linecap: round; }
.an-fig .limb { stroke: var(--an-skin); }
.an-skin { fill: var(--an-skin); stroke: var(--an-line); stroke-width: 1.5px; }
.an-rib path { fill: none; stroke: var(--an-bone); stroke-width: 2.4px; stroke-linecap: round; }
.an-rib.faint path { opacity: .55; }
.an-bone path { fill: var(--an-bone-fill); stroke: var(--an-bone); stroke-width: 1.6px; stroke-linejoin: round; }
.an-bonefill { fill: var(--an-bone-fill); stroke: var(--an-bone); stroke-width: 1.6px; }
.an-clav path { fill: none; stroke: var(--an-bone); stroke-width: 6px; stroke-linecap: round; }
.an-costal { fill: none; stroke: var(--an-bone); stroke-width: 2.4px; stroke-linecap: round; }
.an-costal.base { stroke-dasharray: 4 3; }
.an-fold { fill: none; stroke: var(--an-line); stroke-width: 1.5px; }
.an-rl text, .an-cap text, text.an-cap { font-size: 11px; font-weight: 800; fill: var(--muted); }
.an-rl text { font-size: 13px; font-weight: 900; text-anchor: middle; }
.an-hname text { font-size: 10px; font-weight: 800; fill: var(--muted); pointer-events: none; }
.an-heartsvg .an-hname text { font-size: 11px; }
/* selectable parts */
.an-opt { cursor: pointer; transition: opacity .2s; }
.an-opt .hit { fill: none; stroke: transparent; stroke-width: 18px; pointer-events: stroke; }
.an-lab { font-size: 12px; font-weight: 900; fill: var(--an-hl); opacity: 0; pointer-events: none; transition: opacity .2s; paint-order: stroke; stroke: var(--surface); stroke-width: 3.5px; stroke-linejoin: round; }
.an-lab.small { font-size: 10.5px; }
.an-lab.always { opacity: 1; fill: var(--ink); font-size: 11px; }
.an-opt.on .an-lab { opacity: 1; }
.an-shaft { fill: none; stroke: var(--an-faint); stroke-width: 2.6px; stroke-linecap: round; }
.an-head { fill: var(--an-faint); }
.an-opt.on .an-shaft { stroke: var(--an-hl); stroke-width: 3.4px; }
.an-opt.on .an-head { fill: var(--an-hl); }
.an-dot { fill: var(--an-faint); stroke: var(--surface); stroke-width: 1.5px; }
.an-opt.on .an-dot { fill: var(--an-hl); }
.an-dash { fill: none; stroke: var(--an-faint); stroke-width: 1.4px; stroke-dasharray: 4 4; }
.an-dash.strong { stroke-width: 2px; }
.an-opt.on .an-dash { stroke: var(--an-hl); stroke-width: 2.2px; }
.an-mark { fill: none; stroke: transparent; stroke-width: 3px; stroke-linecap: round; }
.an-opt.on .an-mark { stroke: var(--an-hl); }
.an-limb .vis { fill: none; stroke: transparent; stroke-width: 6px; stroke-linecap: round; }
.an-limb .hit { stroke-width: 22px; }
.an-limb.on .vis { stroke: var(--an-hl); }
.an-rl { pointer-events: none; }
/* planes */
.an-plane { fill: var(--an-hl); fill-opacity: 0; stroke: none; transition: fill-opacity .25s; }
.an-planeg { pointer-events: none; }
.an-planeg.on .an-plane { fill-opacity: .22; stroke: var(--an-hl); stroke-width: 1.6px; }
/* chest */
.an-area path { fill: var(--an-hl); fill-opacity: 0; transition: fill-opacity .2s; }
.an-area.on path { fill-opacity: .32; }
@media (hover: hover) and (pointer: fine) { .an-task .an-area:hover path { fill-opacity: .12; } }
.an-rib-hl path { fill: none; stroke: transparent; stroke-width: 3.4px; stroke-linecap: round; }
.an-opt.on .an-rib-hl path { stroke: var(--an-hl); }
.an-opt.on .an-costal { stroke: var(--an-hl); stroke-width: 3.2px; }
.an-bone .an-opt.on path { fill: var(--an-hl-soft); stroke: var(--an-hl); stroke-width: 2px; }
.an-clav .an-opt.on path { stroke: var(--an-hl); }
.an-line .vis { fill: none; stroke: var(--an-faint); stroke-width: 1.3px; stroke-dasharray: 3 4; }
.an-line.on .vis { stroke: var(--an-hl); stroke-width: 2.6px; stroke-dasharray: none; }
.an-lab.boxed { stroke-width: 4px; }
.an-elec circle { fill: var(--surface); stroke: var(--an-mark); stroke-width: 2px; }
.an-elec text { font-size: 8.5px; font-weight: 900; fill: var(--accent-ink); text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.an-elec.on circle { fill: var(--an-hl); stroke: var(--an-hl); }
.an-elec.on text { fill: var(--on-indigo); }
.has-sel .an-elec:not(.on) { opacity: .45; }
/* tap tasks */
.an-task .an-opt.miss .vis, .an-task .an-limb.miss .vis { stroke: var(--an-warn); }
.an-task .an-area.miss path { fill: var(--an-warn); fill-opacity: .3; }
.an-task .an-bone .an-opt.miss path, .an-task .an-clav .an-opt.miss path { stroke: var(--an-warn); }
.an-task .an-elec.miss circle { stroke: var(--an-warn); }
.an-task .an-off { pointer-events: none; }
.an-task .an-lab { opacity: 0 !important; }
.an-task.an-wrap .solved .an-opt.on .an-lab { opacity: 1 !important; }
/* heart */
.an-h { stroke: var(--an-heart-line); stroke-width: 1.5px; }
.an-h.ra, .an-h.la { fill: var(--an-heart); fill-opacity: .7; }
.an-h.rv, .an-h.lv { fill: var(--an-heart); }
.an-septum { fill: none; stroke: var(--an-heart-line); stroke-width: 2px; }
.an-septum.strong { stroke-width: 3px; }
.an-fillhl { fill: var(--an-hl); fill-opacity: 0; transition: fill-opacity .2s; }
.an-opt.on .an-fillhl { fill-opacity: .22; }
.an-wall { fill: none; stroke: transparent; stroke-width: 6px; stroke-linecap: round; }
.an-opt.on .an-wall { stroke: var(--an-hl); }
.an-septseg { fill: none; stroke: transparent; stroke-width: 7px; stroke-linecap: round; }
.an-opt.on .an-septseg { stroke: var(--an-hl); }
/* wall layers and septum slice */
.an-band rect { stroke: var(--surface); stroke-width: 1px; }
.an-peri { fill: var(--an-bone-fill); }
.an-fluid { fill: var(--an-blood); fill-opacity: .55; }
.an-epi { fill: var(--gold-soft); }
.an-myo { fill: var(--an-heart); }
.an-endo { fill: var(--an-heart-line); fill-opacity: .55; }
.an-blood { fill: var(--an-blood); }
.an-band.on rect { stroke: var(--an-hl); stroke-width: 3px; }
.an-band.on .an-lab { fill: var(--an-hl); }
.an-zone { fill: var(--an-hl); fill-opacity: 0; transition: fill-opacity .25s; }
.an-opt.on .an-zone { fill-opacity: .18; }
.an-endoline { fill: none; stroke: var(--an-heart-line); stroke-width: 4px; }
.an-opt.on .an-endoline { stroke: var(--an-hl); }
.an-lbb { fill: none; stroke: transparent; stroke-width: 4px; stroke-linecap: round; }
.an-lbb.base { stroke: #e2b66d; stroke-width: 3px; }
.an-opt.on .an-lbb { stroke: var(--an-hl); }
.an-leadbody, .an-leadline { fill: none; stroke: var(--ink); stroke-width: 4px; stroke-linecap: round; }
.an-helix { fill: none; stroke: var(--ink); stroke-width: 1.6px; }
.an-leadtip { fill: var(--an-hl); stroke: var(--surface); stroke-width: 1.5px; }
.an-perf .an-leadtip { fill: var(--an-warn); }
.an-cs { fill: none; stroke: #e2b66d; stroke-width: 4px; stroke-linecap: round; }
.an-node { fill: #e2b66d; stroke: var(--surface); stroke-width: 2px; }
.an-prefix .an-zone, .an-opt .an-zone { stroke: none; }
/* access */
.an-vein { fill: none; stroke: var(--accent); stroke-width: 5px; stroke-linecap: round; opacity: .55; }
.an-vein-faint path { fill: none; stroke: var(--accent); stroke-width: 4px; stroke-linecap: round; opacity: .25; }
.an-vg.on .an-vein { opacity: 1; stroke: var(--an-hl); stroke-width: 6.5px; }
.an-vg .hit { stroke-width: 16px; }
.an-leadline.vis { stroke-width: 2.6px; }
.an-vg.on .an-leadline { stroke: var(--an-hl); stroke-width: 3.6px; }
.an-pocket { fill: var(--an-hl); fill-opacity: 0; stroke: var(--an-faint); stroke-width: 1.4px; stroke-dasharray: 4 3; }
.an-opt.on .an-pocket { fill-opacity: .18; stroke: var(--an-hl); stroke-dasharray: none; }
.an-device { fill: var(--muted); stroke: var(--ink); stroke-width: 1px; }
.an-opt.on .an-device { fill: var(--an-hl); }
.an-header { fill: var(--surface); stroke: var(--ink); stroke-width: 1.2px; }
.an-opt.on .an-header { fill: var(--an-hl); }
.an-small-heart .an-h { stroke-width: 2.5px; }
/* fluoroscopy */
.an-fluoro-row { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 10px; align-items: center; }
.an-carm { transition: transform .6s cubic-bezier(.3, .8, .3, 1); }
@media (prefers-reduced-motion: reduce) { .an-carm { transition: none; } }
.an-arc { fill: none; stroke: var(--an-faint); stroke-width: 1.2px; stroke-dasharray: 2 5; }
.an-beam { fill: var(--gold); fill-opacity: .18; }
.an-detector { fill: var(--an-hl); }
.an-detlabel { font-size: 10px; font-weight: 900; fill: var(--on-indigo); }
.an-tube { fill: var(--muted); }
.an-table { fill: var(--an-faint); }
.an-angle { font-size: 0; }
.an-inset { width: 100%; height: auto; display: block; }
.an-inset-box { background: var(--surface-2); border-radius: 14px; padding: 6px; }
.an-septface { fill: var(--an-hl); fill-opacity: .25; stroke: var(--an-hl); stroke-width: 1.2px; }
.an-septband { fill: var(--an-hl); fill-opacity: .35; }
@media (max-width: 380px) { .an-fluoro-row { grid-template-columns: 1fr; } }
.an-box { fill: none; stroke: var(--an-faint); stroke-width: 1px; stroke-dasharray: 3 4; opacity: .8; }
.an-box.back { opacity: .5; }
.an-dot.hid { opacity: 0; }
.an-opt.on .an-dot.hid { opacity: 1; }
.an-skin.noline { stroke: none; }
.an-wrap svg.an-svg { overflow: hidden; }
.an-heartsvg .lk-lead { fill: none; stroke: var(--ink); stroke-width: 3px; stroke-linecap: round; }
.an-heartsvg .lk-lead-tip { fill: var(--an-hl); stroke: var(--surface); stroke-width: 1.5px; }
.an-fillhl { stroke: transparent; stroke-width: 2.5px; }
.an-opt.on .an-fillhl { fill-opacity: .14; stroke: var(--an-hl); }
.an-opt.on .an-zone { fill: var(--an-hl-soft); fill-opacity: .9; }
.an-septsvg .an-opt.on .an-zone { fill: var(--an-hl); fill-opacity: .2; }
.an-cs.thin { stroke-width: 3px; }
:root[data-theme="dark"] { --lk-surface-2: #3e4b4d; }
.lk-chips.an-pairs { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 8px 6px; align-items: center; }
.lk-chips.an-pairs .lk-chip { width: 100%; }
.an-vs { color: var(--muted); font-weight: 900; font-size: 15px; text-align: center; }

/* admin players: edit button next to the row, edit form */
.mrow-top { display: flex; align-items: center; }
.mrow-top .mrow-head { flex: 1 1 auto; min-width: 0; }
.medit-btn { margin-right: 10px; width: 40px; height: 40px; background: var(--surface-2); color: var(--accent-deep); }
.medit-btn.on { background: var(--accent-soft); }
.medit label { font-weight: 700; font-size: 13px; }
/* admin questions: list in its own box */
.qlist > .chips, .qlist > select, .qlist > .sticky-actions { margin-top: 6px; }
.qlist .aqcard { background: var(--bg); }

/* bottom bar without Profile (5 tabs, 4 without Courses); Profile opens from the initials */
.nav { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.nav.n4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.avatar-btn { display: flex; flex-direction: column; align-items: center; gap: 2px; background: none; border: 0; padding: 0; cursor: pointer; font: inherit; color: inherit; }
.avatar-btn .avatar { display: flex; align-items: center; justify-content: center; }
.avatar-label { font-size: 11px; font-weight: 700; color: var(--muted); line-height: 1; }

/* pen dot at the tip of a trace while it is being drawn */
.lk-pen { fill: var(--accent); stroke: #fff; stroke-width: .25; }

/* bundle branch memory aid: one row per block with M / W tags */
.lk-bbb-head { display: flex; align-items: baseline; gap: 8px; margin: 10px 0 6px; font-size: 15px; }
.lk-bbb-head span { color: var(--accent); font-weight: 900; letter-spacing: .02em; }
.lk-bbb-head small { margin-left: auto; color: var(--muted); font-size: 12.5px; }
.lk-tag-mw { position: absolute; top: 4px; right: 6px; background: var(--accent); color: #fff; font-weight: 900; font-size: 13px; padding: 1px 9px; border-radius: 6px; }
/* chest electrodes over the heart */
.lk-chestheart .heart .lv { fill: #F3C9C4; stroke: #C98880; stroke-width: 1.2; opacity: .85; }
.lk-chestheart .heart .rv { fill: #F7DCD8; stroke: #C98880; stroke-width: 1.2; opacity: .9; }
.lk-chestheart .heart .sept, .lk-chestheart .heart .lat { fill: none; stroke: transparent; stroke-width: 5; stroke-linecap: round; }
.lk-chestheart .heart .rv.hl { fill: var(--indigo-soft); stroke: var(--indigo); stroke-width: 2; }
.lk-chestheart .heart .sept.hl, .lk-chestheart .heart .lat.hl { stroke: var(--indigo); opacity: .75; }
.lk-chestheart .cap2 { font-size: 9px; font-weight: 800; fill: #8C5A54; text-anchor: middle; }
.lk-chestheart .cap { font-size: 6.5px; font-weight: 700; fill: var(--muted); text-anchor: middle; }
.lk-chestheart .rib, .lk-chestheart .bone { opacity: .55; }
.lk-chestheart .look path { stroke: var(--indigo); stroke-width: 1.4; stroke-dasharray: 3 2.5; fill: none; }

/* chapter check box on the summary card */
.lk-practice.lk-check { background: #FFF3D6; }

/* LBBAP ECG course: V1/V6 pairs, RWPT marks, output manoeuvre */
.lk-lbpair { display: grid; gap: 6px; }
.lk-mark { stroke: var(--indigo); stroke-width: .22; fill: none; }
.lk-mark.dash { stroke-dasharray: .8 .6; }
.lk-band.alt { fill: var(--indigo); fill-opacity: .14; }
.lk-caliper { position: relative; background: var(--lk-paper); border-radius: 10px; overflow: hidden; }
.lk-delta { font-weight: 900; font-variant-numeric: tabular-nums; padding: 4px 10px; border-radius: 99px; background: var(--lk-surface-2); }
.lk-delta.warn { background: var(--accent); color: #fff; }

/* Admin export */
form[data-form=admin-export] .row2 > label { min-width: 0; }
form[data-form=admin-export] select { width: 100%; min-width: 0; }
.course-export { gap: 8px; }

/* sliders in courses: big knob that pulses until it is moved the first time */
.lk-range-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.lk-range-hint { font-size: 13px; font-weight: 900; color: var(--accent); letter-spacing: 2px; animation: lk-nudge 1.4s ease-in-out infinite; }
.lk-rangebox.used .lk-range-hint { display: none; }
@keyframes lk-nudge { 0%, 100% { transform: translateX(-3px); } 50% { transform: translateX(3px); } }
.lk-col input.lk-range { -webkit-appearance: none; appearance: none; width: 100%; height: 34px; background: transparent; cursor: pointer; }
.lk-range::-webkit-slider-runnable-track { height: 8px; border-radius: 99px; background: linear-gradient(to right, var(--accent) var(--pct, 0%), var(--lk-surface-2) var(--pct, 0%)); }
.lk-range::-moz-range-track { height: 8px; border-radius: 99px; background: var(--lk-surface-2); }
.lk-range::-moz-range-progress { height: 8px; border-radius: 99px; background: var(--accent); }
.lk-range::-webkit-slider-thumb { -webkit-appearance: none; width: 30px; height: 30px; margin-top: -11px; border-radius: 50%; background: var(--accent); border: 4px solid #fff; box-shadow: 0 1px 5px rgba(0, 0, 0, .35); }
.lk-range::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: var(--accent); border: 4px solid #fff; box-shadow: 0 1px 5px rgba(0, 0, 0, .35); }
.lk-range.attn::-webkit-slider-thumb { animation: lk-pulse 1.6s ease-out infinite; }
.lk-range.attn::-moz-range-thumb { animation: lk-pulse 1.6s ease-out infinite; }
@keyframes lk-pulse { 0% { box-shadow: 0 1px 5px rgba(0, 0, 0, .35), 0 0 0 0 color-mix(in srgb, var(--accent) 55%, transparent); } 100% { box-shadow: 0 1px 5px rgba(0, 0, 0, .35), 0 0 0 16px transparent; } }
@media (prefers-reduced-motion: reduce) { .lk-range.attn::-webkit-slider-thumb, .lk-range.attn::-moz-range-thumb, .lk-range-hint { animation: none; } }

/* output test: − / + like on the analyser, running monitor */
.lk-outctl { display: grid; grid-template-columns: 56px 1fr 56px; align-items: center; gap: 10px; }
.lk-outbtn { height: 56px; border-radius: 16px; border: 0; background: var(--accent); color: #fff; font-size: 30px; font-weight: 900; line-height: 1; cursor: pointer; }
.lk-outbtn:disabled { opacity: .3; cursor: default; }
.lk-outval { display: flex; flex-direction: column; align-items: center; background: var(--lk-surface-2); border-radius: 16px; padding: 6px 8px; }
.lk-outval b { font-size: 24px; font-weight: 900; font-variant-numeric: tabular-nums; }
.lk-outval span { font-size: 12px; color: var(--muted); font-weight: 700; }
.lk-old { opacity: .35; }

/* ECG Fundamentals: action potential, rhythm strips, ectopic focus */
.lk-ap svg { width: 100%; height: auto; display: block; background: var(--lk-paper); border-radius: 12px; }
.lk-ap-axis { stroke: var(--muted); stroke-width: 1; fill: none; opacity: .6; }
.lk-ap-line { stroke: var(--indigo); stroke-width: 2.6; fill: none; stroke-linejoin: round; }
.lk-ap-ecg { stroke: var(--lk-trace); stroke-width: 1.6; fill: none; }
.lk-ap-lab { font-size: 9px; fill: var(--muted); font-weight: 700; }
.lk-ap-num { font-size: 12px; font-weight: 900; fill: var(--accent); }
.lk-rhythm { display: grid; gap: 6px; }
.lk-focus circle { fill: var(--accent); }
.lk-focus .ring { fill: none; stroke: var(--accent); stroke-width: 2; opacity: .5; animation: lk-focus 1.6s ease-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes lk-focus { 0% { transform: scale(.6); opacity: .8; } 100% { transform: scale(1.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .lk-focus .ring { animation: none; } }

/* chest leads in 3D (turnable) */
.lk-ch3d .heart .h3 { stroke: #C98880; stroke-width: 1; opacity: .95; }
.lk-ch3d .heart .h3.sept { stroke: #B8706A; stroke-width: .8; opacity: 0; }
.lk-ch3d .heart .h3.sept.hl { opacity: .95; }
.lk-ch3d .heart .h3.hl { stroke: var(--indigo); stroke-width: 2.4; }
.lk-ch3d .lk-el.back { opacity: .3; pointer-events: none; }
.lk-ch3d .ch-view { font-size: 7px; text-anchor: end; }

/* start page: course card above the practice button */
.home-course { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 1.5px solid var(--accent-soft); font: inherit; color: inherit; cursor: pointer; }
.home-course > svg:last-child { transform: rotate(180deg); color: var(--muted); flex-shrink: 0; }
.home-course-ic { width: 44px; height: 44px; border-radius: 14px; background: var(--accent-soft); color: var(--accent-deep); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.home-course-new { color: var(--accent-ink); font-weight: 800; margin-top: 2px; }
/* courses: enrol button under a course card */
.lk-enroll-wrap { display: flex; flex-direction: column; gap: 8px; background: var(--surface); border-radius: 22px; padding-bottom: 12px; margin-bottom: 10px; }
.lk-enroll-wrap .lk-course-card { margin-bottom: 0; }
.lk-enroll { align-self: flex-start; margin-left: 16px; min-height: 40px; }
.lk-course-main .lk-kicker { font-size: 11px; }
/* LBBAP implant technique widgets */
.lk-aim-tv { fill: none; stroke: var(--muted); stroke-width: 2px; stroke-dasharray: 2 4; stroke-linecap: round; }
.lk-aim-zone { fill: none; stroke: var(--good); stroke-width: 12px; stroke-linecap: round; opacity: .35; }
.lk-aim.ok .lk-aim-zone { opacity: .7; }
.lk-aim-zlab { fill: var(--good); }
.lk-aim.ok .an-leadtip { fill: var(--good); }
.lk-aim-arc { fill: none; stroke: var(--accent); stroke-width: 2px; }
.lk-aim .an-septband { fill-opacity: .55; }
.lk-axis { fill: none; stroke: var(--line-strong); stroke-width: 1.2px; }
.lk-feel-line { fill: none; stroke: var(--accent); stroke-width: 3px; stroke-linecap: round; stroke-linejoin: round; }
.lk-torque { display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: center; font-size: 13px; font-weight: 800; color: var(--muted); }
.lk-torque-bar { height: 12px; border-radius: 6px; background: var(--lk-surface-2); overflow: hidden; }
.lk-torque-bar i { display: block; height: 100%; width: 0; background: var(--accent); border-radius: 6px; transition: width .15s; }
.lk-torque.warn .lk-torque-bar i { background: var(--an-warn); }
.lk-mon { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.lk-mon-box { background: var(--lk-surface-2); border-radius: 14px; padding: 8px 10px; display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: 2px 8px; }
.lk-mon-box span { font-size: 12px; font-weight: 800; color: var(--muted); grid-column: 1 / -1; }
.lk-mon-box b { font-size: 22px; font-weight: 900; font-variant-numeric: tabular-nums; }
.lk-mon-box b.warn { color: var(--an-warn); }
.lk-spark { width: 70px; height: 22px; }
.lk-spark path { fill: none; stroke: var(--accent); stroke-width: 2px; stroke-linejoin: round; }
.lk-monrow { gap: 6px; }
.lk-infobox.warn b { color: var(--an-warn); }
.lk-montext { min-height: 6.6em; }
.home-practice[disabled] { opacity: .6; }

/* Courses overview: continue card, figures, my courses, discover */
.lk-cont { display: flex; flex-direction: column; gap: 12px; width: 100%; text-align: left; border: 1.5px solid var(--accent); border-radius: 24px; padding: 18px; background: var(--accent-soft); color: var(--ink); font: inherit; cursor: pointer; }
.lk-cont-kicker { font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-deep); }
.lk-cont-body { display: flex; align-items: center; gap: 14px; }
.lk-cont .lk-course-main strong { font-size: 19px; font-weight: 900; }
.lk-cont .lk-course-main span { color: var(--ink); opacity: .75; font-size: 14px; }
.lk-cont-go { align-self: flex-start; display: inline-flex; align-items: center; gap: 8px; background: var(--accent); color: var(--on-accent); border-radius: 999px; padding: 9px 16px; font-weight: 900; }
.lk-cont.empty { cursor: default; }
.lk-cont-title { font-size: 19px; font-weight: 900; }
.lk-mine { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 0; border-radius: 20px; padding: 12px 14px; background: var(--surface); font: inherit; color: inherit; cursor: pointer; }
.lk-mine .lk-course-ring { width: 48px; height: 48px; } .lk-mine .lk-course-ring span { width: 38px; height: 38px; font-size: 12px; }
.lk-mine > svg:last-child { color: var(--muted); flex-shrink: 0; }
.lk-disc-group { display: flex; flex-direction: column; gap: 10px; }
.lk-disc-subject { align-self: flex-start; font-size: 12px; font-weight: 800; color: var(--accent-deep); background: var(--accent-soft); border-radius: 999px; padding: 4px 12px; }
.lk-disc { background: var(--surface); border-radius: 22px; border: 1.5px dashed var(--line-strong); overflow: hidden; }
.lk-disc-main { display: flex; flex-direction: column; gap: 4px; width: 100%; text-align: left; border: 0; background: none; padding: 16px 16px 8px; font: inherit; color: inherit; cursor: pointer; }
.lk-disc-main strong { font-size: 17px; font-weight: 900; }
.lk-disc-main > span:not(.lk-course-meta) { color: var(--muted); font-size: 14px; }
.lk-disc-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 0 12px 12px; }
.lk-disc-foot .lk-enroll { margin: 0; align-self: auto; }
.lk-btn.small { min-height: 40px; padding: 0 16px; font-size: 14px; }
.lk-facts { margin: -4px 4px 0; font-size: 13px; font-weight: 700; color: var(--muted); }
.lk-preview { display: flex; flex-direction: column; gap: 6px; background: var(--accent-soft); border: 1.5px dashed var(--accent); border-radius: 20px; padding: 14px 16px; }
.lk-preview span { font-size: 14px; color: var(--ink); opacity: .8; }
.lk-preview .lk-enroll { margin: 6px 0 0; align-self: stretch; }

/* certificates */
.cert-card .h2 { display: inline-flex; align-items: center; gap: 8px; }
.cert-row { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 0; border-radius: 16px; padding: 10px 12px; background: var(--gold-soft); font: inherit; color: inherit; cursor: pointer; }
.cert-row > svg:last-child { transform: rotate(180deg); color: var(--muted); flex-shrink: 0; }
.cert-ic { width: 40px; height: 40px; border-radius: 12px; background: var(--surface); color: var(--gold-ink, #8a6a12); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.cert-sheet { max-width: 760px; }
.cert-frame { border-radius: 10px; overflow: hidden; box-shadow: 0 2px 14px rgba(0, 0, 0, .12); background: #fffdf8; }
.cert-frame svg { display: block; width: 100%; height: auto; }
.cert-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.cert-actions .btn { flex: 1 1 auto; display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; }
.cert-signer { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.cert-sig { width: 110px; height: 40px; display: inline-flex; align-items: center; justify-content: center; background: #fff; border-radius: 8px; flex-shrink: 0; }
.cert-sig img { max-width: 100%; max-height: 100%; }
.cert-form { border: 1.5px dashed var(--line-strong); border-radius: 16px; padding: 12px; }
.cert-sel { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: 6px; align-items: center; }
.cert-sel select { min-width: 0; width: 100%; }
@media (max-width: 420px) { .cert-sel { grid-template-columns: 1fr 1fr; } }
.lk-certbar { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 1.5px solid var(--gold); border-radius: 20px; padding: 12px 14px; background: var(--gold-soft); color: var(--ink); font: inherit; cursor: pointer; }
.lk-certbar-ic { width: 42px; height: 42px; border-radius: 50%; background: var(--surface); color: var(--gold-ink); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.lk-certbar .lk-course-main strong { font-size: 16px; }
.lk-certbar > svg:last-child { color: var(--muted); flex-shrink: 0; }
.lk-facts-link { display: inline-flex; align-items: center; gap: 3px; border: 0; background: none; padding: 0; font: inherit; color: var(--accent-ink); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.lk-facts-link svg { width: 14px; height: 14px; }
.tagline { margin-top: -10px; font-size: 13px; font-weight: 800; letter-spacing: .08em; color: var(--muted); }

/* decide, sort, flip, order, compare */
.lk-decide-qs { display: flex; flex-direction: column; gap: 10px; }
.lk-decide-q { display: flex; flex-direction: column; gap: 6px; }
.lk-decide-l { font-size: 13px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.lk-decide-out { display: flex; flex-direction: column; gap: 4px; border-radius: 18px; padding: 14px 16px; background: var(--accent-soft); border: 1.5px solid var(--accent); }
.lk-decide-out strong { font-size: 17px; }
.lk-decide-out.warn { background: var(--gold-soft); border-color: var(--gold); }
.lk-decide-out.good { background: var(--good-soft); border-color: var(--good); }
.lk-decide-tag { align-self: flex-start; margin-top: 4px; font-size: 12px; font-weight: 800; padding: 3px 10px; border-radius: 999px; background: var(--surface); color: var(--ink); }
.lk-sort-list { display: flex; flex-direction: column; gap: 8px; }
.lk-sort-item { background: var(--lk-surface-2); border-radius: 16px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; border: 1.5px solid transparent; }
.lk-sort-item.ok { border-color: var(--good); } .lk-sort-item.bad { border-color: var(--an-warn); }
.lk-sort-t { font-size: 15px; font-weight: 600; }
.lk-sort-btns { display: flex; flex-wrap: wrap; gap: 6px; }
.lk-sort-btns button { flex: 1 1 0; min-height: 40px; border-radius: 999px; border: 1.5px solid var(--line-strong); background: var(--surface); font: inherit; font-weight: 800; font-size: 14px; color: var(--ink); cursor: pointer; padding: 0 10px; }
.lk-sort-btns button.right { border-color: var(--good); background: var(--good-soft); }
.lk-sort-btns button.picked:not(.right) { border-color: var(--an-warn); }
.lk-sort-btns button:disabled { cursor: default; }
.lk-sort-why { font-size: 14px; color: var(--muted); } .lk-sort-why:empty { display: none; }
.lk-sort-score { font-size: 14px; color: var(--muted); text-align: center; }
.lk-flip-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 360px) { .lk-flip-grid { grid-template-columns: 1fr; } }
.lk-flip { border: 0; border-radius: 18px; padding: 14px; min-height: 150px; text-align: left; font: inherit; color: var(--ink); background: var(--surface); box-shadow: 0 1px 4px rgba(0, 0, 0, .08); cursor: pointer; display: flex; }
.lk-flip-front, .lk-flip-back { display: flex; flex-direction: column; gap: 6px; width: 100%; }
.lk-flip-front strong { font-size: 16px; } .lk-flip-front > span:not(.lk-kicker):not(.lk-flip-hint) { font-size: 13px; color: var(--muted); }
.lk-flip-hint { margin-top: auto; font-size: 12px; font-weight: 800; color: var(--accent-ink); }
.lk-flip-back { display: none; font-size: 14px; }
.lk-flip[aria-pressed="true"] { background: var(--accent-soft); }
.lk-flip[aria-pressed="true"] .lk-flip-front { display: none; } .lk-flip[aria-pressed="true"] .lk-flip-back { display: flex; }
.lk-order-done { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 6px; }
.lk-order-done:empty { display: none; }
.lk-order-done li { padding: 6px 8px; border-radius: 10px; } .lk-order-done li.ok { background: var(--good-soft); } .lk-order-done li.bad { background: var(--gold-soft); }
.lk-order-ask { font-size: 13px; font-weight: 800; color: var(--muted); }
.lk-order-pool { display: flex; flex-direction: column; gap: 6px; }
.lk-order-pool button { text-align: left; border: 1.5px solid var(--line-strong); background: var(--surface); border-radius: 14px; padding: 10px 12px; font: inherit; font-size: 15px; color: var(--ink); cursor: pointer; }
.lk-order-res { display: flex; flex-direction: column; gap: 6px; border-radius: 16px; padding: 12px 14px; }
.lk-order-res.ok { background: var(--good-soft); } .lk-order-res.bad { background: var(--gold-soft); }
.lk-order-res ol { margin: 0; padding-left: 20px; }
.lk-changed { font-weight: 900; color: var(--accent-ink); }
.lk-flip-q { font-size: 13px; color: var(--accent-deep); }

/* file picker */
.file-pick { position: relative; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 6px; border: 1.5px dashed var(--line-strong); border-radius: 16px; cursor: pointer; }
.file-pick .file-in { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font-size: 0; }
.file-btn { display: inline-flex; align-items: center; gap: 6px; padding: 9px 14px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-deep); font-weight: 800; font-size: 14px; pointer-events: none; }
.file-name { font-size: 13px; color: var(--muted); min-width: 0; overflow-wrap: anywhere; pointer-events: none; }

/* admin: course tiles */
.lc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.lc-tile { display: flex; flex-direction: column; gap: 8px; text-align: left; border: 0; border-radius: 20px; padding: 14px; background: var(--surface); font: inherit; color: inherit; cursor: pointer; box-shadow: 0 1px 4px rgba(0, 0, 0, .06); }
.lc-tile.off { opacity: .7; }
.lc-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.lc-pill { font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: 999px; background: var(--lk-surface-2, #eee); color: var(--muted); }
.lc-pill.on { background: var(--good-soft); color: var(--good-ink); }
.lc-title { font-size: 17px; font-weight: 900; }
.lc-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.lc-stats > span { display: flex; flex-direction: column; font-size: 11px; color: var(--muted); font-weight: 700; line-height: 1.2; }
.lc-stats b { font-size: 17px; color: var(--ink); font-variant-numeric: tabular-nums; }
.lc-stats .warn b { color: var(--accent-ink); }
.lc-more { font-size: 13px; font-weight: 800; color: var(--accent-ink); }
.lc-back { align-self: flex-start; }

/* flip cards turn over like a real card */
.lk-flip-grid { perspective: 900px; }
.lk-flip.turn-out { animation: lk-turn-out .17s ease-in forwards; }
.lk-flip.turn-in { animation: lk-turn-in .22s ease-out; }
@keyframes lk-turn-out { from { transform: rotateY(0); } to { transform: rotateY(90deg); } }
@keyframes lk-turn-in { from { transform: rotateY(-90deg); } to { transform: rotateY(0); } }

/* language choice on the sign-in page */
.lang-pick { display: flex; justify-content: center; gap: 18px; margin-top: 4px; }
.lang-pick .link { color: var(--muted); font-weight: 700; }
.lang-pick .link.on { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }

/* language: button next to the profile picture, sheet and profile card */
.lang-av { flex-direction: column; gap: 0; line-height: 1; }
.lang-av b { font-size: 11px; font-weight: 800; letter-spacing: .02em; margin-top: 1px; }
.lang-av svg { opacity: .8; }
.lang-list { display: grid; gap: 8px; }
.lang-opt { font: inherit; font-size: 17px; font-weight: 700; text-align: start; padding: 14px 16px; border-radius: 14px; border: 1.5px solid var(--line, var(--surface-2)); background: var(--surface); color: var(--ink); cursor: pointer; }
.lang-opt.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-deep); }
.lang-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.lang-card .h2 { display: inline-flex; align-items: center; gap: 8px; }

/* right to left (Arabic, Persian): drawings, ECG strips and figures keep their left-to-right layout */
[dir="rtl"] svg, [dir="rtl"] canvas, [dir="rtl"] .lk-fig, [dir="rtl"] .cert-frame { direction: ltr; }
/* arrows point the other way ("scale" adds to the existing transform, so rotated chevrons flip too) */
[dir="rtl"] svg.ic-dir { scale: -1 1; }
[dir="rtl"] input[type="email"], [dir="rtl"] input.code { direction: ltr; text-align: right; }
.lang-chip { font: inherit; font-size: 15px; font-weight: 700; padding: 9px 16px; border-radius: 999px; border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--ink); cursor: pointer; }
.lang-chip.on { border-color: var(--accent); background: var(--accent); color: var(--surface); }

/* focus list: sorting, group headings, remove button */
.focus-sort { display: flex; flex-direction: column; gap: 6px; }
.focus-group { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; font-size: 16px; margin: 6px 4px -2px; }
.focus-item { flex-direction: column; gap: 10px; }
.focus-remove { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; font: inherit; font-size: 13px; font-weight: 700; color: var(--accent); background: var(--accent-soft); border: 0; border-radius: 999px; padding: 6px 12px; cursor: pointer; }
.focus-remove:active { opacity: .7; }
/* right to left with content that is still English: each paragraph takes the direction of its own text */
[dir="rtl"] :is(.question, .answer > span, .feedback p, .fq, .term-def, .lk-body p, .lk-body li, .lk-body h2, .lk-body h3, .lk-prompt, .lk-takeaways li, .lk-list li, .lk-infobox p, .pick-row strong, .medal-name) { unicode-bidi: plaintext; text-align: start; }
.fq { align-self: stretch; }
.focus-item > .stack-s { align-self: stretch; }
.focus-filter { display: flex; flex-direction: column; gap: 10px; padding: 14px; }
.focus-selects { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.focus-selects label:first-child { grid-column: 1 / -1; }
.focus-selects select { width: 100%; min-width: 0; text-overflow: ellipsis; font-size: 15px; padding-inline: 10px 28px; }

/* tiles: same look on Home (My progress), Courses (My courses) and Practice (Your topics) */
.tile-btn { border: 0; font: inherit; color: var(--ink); cursor: pointer; position: relative; }
.tile-sub { font-size: 11px; line-height: 1.25; color: var(--muted); font-weight: 700; }
.tile-focus.more { color: var(--accent-ink); } .tile-focus.mastered { color: var(--good-ink); }
.tile-gear { position: absolute; top: 8px; right: 8px; color: var(--muted); display: inline-flex; }
.tile-own { background: var(--gold-soft); border: 1.5px dashed var(--gold); }
.medals.tiles-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tiles-3 .lk-course-ring { width: 52px; height: 52px; } .tiles-3 .lk-course-ring span { width: 42px; height: 42px; font-size: 12px; }
.topic-overlay .sheet { max-height: 90vh; overflow-y: auto; }

/* three tile families: courses (teal), practice topics (white, blue ring), own lists (warm, dashed) */
.tile-course { background: var(--indigo-soft); }
.tile-course .medal-name { color: var(--indigo); }
.tile-course .tile-sub { color: var(--indigo); opacity: .8; }
.tile-course .lk-course-ring { background: conic-gradient(var(--indigo) var(--p), var(--surface) 0); }
.tile-course .lk-course-ring span { color: var(--indigo); }
.tile-corner { position: absolute; top: 8px; right: 8px; color: var(--indigo); display: inline-flex; opacity: .75; }
.tile-corner svg { width: 14px; height: 14px; }

/* start page header: every round button has the same size and a label below, all on one line */
.hello-right { align-items: flex-start; gap: 6px; }
.hint-av { position: relative; }
.hint-av.bell { background: var(--gold-soft); color: var(--gold-ink); }
.hint-av.bell i { position: absolute; top: 8px; right: 10px; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px var(--gold-soft); }
.hint-av.admin { background: var(--indigo-soft); color: var(--indigo); } /* same as the Admin button in Profile */
.hint-av.duel { background: var(--indigo-soft); color: var(--indigo); }
.hint-av b { position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: var(--accent); color: var(--on-accent); font-size: 11px; font-weight: 900; display: flex; align-items: center; justify-content: center; border: 2px solid var(--bg); }
@media (max-width: 380px) { .hello-right .avatar { width: 40px; height: 40px; } .hello-right { gap: 4px; } }
/* start page header: greeting and buttons on one line, the big title below over the full width */
.hello { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 8px; }
.hello > div:first-child { display: contents; }
.hello .hello-line { grid-row: 1; grid-column: 1; }
.hello > div:first-child > .title { grid-row: 2; grid-column: 1 / -1; margin-top: 2px; }
.hello .hello-right { grid-row: 1; grid-column: 2; }

/* Device Programming course: AV delay chart */
.lk-avchart svg { width: 100%; max-width: 420px; display: block; margin: 0 auto; }
.lk-avdot { fill: var(--accent); stroke: var(--surface); stroke-width: 2; }

/* Courses: all courses as tiles – enrolled with a green outline, not enrolled white with a dashed outline */
.tile-course.tile-in { box-shadow: inset 0 0 0 2px var(--accent-deep); }
.tile-badge { position: absolute; top: 7px; right: 7px; width: 20px; height: 20px; border-radius: 50%; background: var(--accent-deep); color: var(--surface); display: inline-flex; align-items: center; justify-content: center; }
.tile-badge svg { width: 12px; height: 12px; }
.tile-new { background: var(--surface); border: 2px solid var(--line-strong); padding: 10px 2px; }
.tile-new .medal-name { color: var(--ink); }
.tile-new .tile-sub { color: var(--muted); }
.tile-ring-new { background: none; border: 2px dashed var(--line-strong); }
.tile-ring-new span { color: var(--muted); background: none; }
.tile-ring-new svg { display: block; }
.lk-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; font-size: 13px; color: var(--muted); margin: -4px 0 10px; }
.lk-leg { display: inline-block; width: 16px; height: 12px; border-radius: 4px; }
.lk-leg + * { margin-right: 6px; }
.lk-leg.in { background: var(--indigo-soft); box-shadow: inset 0 0 0 2px var(--accent-deep); }
.lk-leg.new { background: var(--surface); border: 2px solid var(--line-strong); margin-left: 8px; }
.lk-sheet-overlay { z-index: 12; }
.lk-sheet-back { position: absolute; inset: 0; background: none; border: 0; padding: 0; cursor: default; }
.lk-sheet { position: relative; gap: 10px; }
.lk-sheet .h2 { font-size: 22px; font-weight: 900; }
.lk-sheet-desc { color: var(--muted); margin: 0; }
.lk-sheet-btns { display: flex; gap: 10px; justify-content: flex-end; margin-top: 8px; }
.lk-sheet-btns .lk-btn { flex: 1; margin: 0; }

/* screwFeel scene: the lead turning into the septum */
.lk-scene { margin-bottom: 4px; }
.lk-sc-sept { fill: var(--an-heart); stroke: var(--an-heart-line); stroke-width: 1.5; }
.lk-sc-trab { fill: none; stroke: var(--an-heart-line); stroke-width: 2; stroke-linecap: round; }
.lk-sc-tunnel { fill: var(--surface); stroke: var(--an-heart-line); stroke-width: 1.2; stroke-dasharray: 3 3; }
.lk-sc-lead { fill: none; stroke: var(--indigo); stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; }
.lk-sc-helix { fill: none; stroke: var(--ink); stroke-width: 2.4; stroke-linecap: round; }
.lk-sc-spin { fill: none; stroke: var(--accent); stroke-width: 2; }
.lk-sc-spin-h { fill: var(--accent); }
.lk-sc-spin.warn { stroke: var(--an-warn); } .lk-sc-spin-h.warn { fill: var(--an-warn); }
.lk-scene text.lk-sc-tag { fill: var(--ink); } .lk-scene text.lk-sc-tag.warn { fill: var(--an-warn); }

/* implant monitor, compact: scene, depth slider, values, three strips and the text on one screen */
.lk-monpanel { gap: 10px; }
.an-septsvg.compact .an-lab { font-size: 11px; }
.lk-depthctl { display: grid; grid-template-columns: 40px 1fr 40px; align-items: center; gap: 10px; }
.lk-stepbtn { width: 40px; height: 40px; border-radius: 12px; border: 0; background: var(--accent); color: var(--on-accent); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.lk-stepbtn.fwd svg { transform: scaleX(-1); }
.lk-stepbtn:disabled { opacity: .3; cursor: default; }
.lk-depthctl input.lk-range { -webkit-appearance: none; appearance: none; width: 100%; height: 34px; margin: 0; padding: 0; border: 0; background: transparent; cursor: pointer; }
.lk-monchips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.lk-monchips span { background: var(--lk-surface-2); border-radius: 10px; padding: 4px 8px; font-size: 11px; font-weight: 800; color: var(--muted); display: flex; flex-direction: column; min-width: 0; }
.lk-monchips b { color: var(--ink); font-size: 16px; font-weight: 900; font-variant-numeric: tabular-nums; white-space: nowrap; }
.lk-monchips b.warn { color: var(--an-warn); }
.lk-monpanel .lk-montext { min-height: 0; }

/* output test: V6 RWPT next to the blue marker, thresholds found and where to program */
.lk-mark-t { font-size: 1.35px; font-weight: 900; fill: var(--indigo); paint-order: stroke; stroke: var(--surface); stroke-width: .5px; stroke-linejoin: round; font-variant-numeric: tabular-nums; }
.lk-mark-t tspan.warn { fill: var(--an-warn); }
.lk-thr { display: grid; gap: 8px; }
.lk-thr-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.lk-thr-row span { background: var(--lk-surface-2); border-radius: 12px; padding: 6px 10px; font-size: 12px; font-weight: 800; color: var(--muted); display: flex; flex-direction: column; }
.lk-thr-row b { font-size: 18px; font-weight: 900; color: var(--muted); font-variant-numeric: tabular-nums; }
.lk-thr-row span.on b { color: var(--ink); }
.lk-thr-ans { border: 2px solid var(--accent); border-radius: 14px; padding: 10px 12px; display: grid; gap: 4px; }
.lk-monrow .lk-mark-t { font-size: 2px; }

/* fluoro widget: a real X-ray below the schematic */
.an-xray { margin: 0; display: grid; grid-template-columns: 132px 1fr; gap: 12px; align-items: center; }
.an-xray img { width: 132px; height: auto; border-radius: 10px; display: block; background: #000; }
.an-xray figcaption { display: grid; gap: 4px; font-size: 13px; color: var(--ink); }
.an-xray figcaption span { font-size: 11px; color: var(--muted); }
.an-xray img { cursor: zoom-in; }
.an-xray.big { grid-template-columns: 1fr; }
.an-xray.big img { width: 100%; cursor: zoom-out; }

/* courses: hero as compact as the practice button, tiles in the same grid as practice */
.lk-cont { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 4px 12px; padding: 12px 14px; border-radius: 22px; }
.lk-cont > .lk-cont-kicker { grid-column: 1 / -1; }
.lk-cont .lk-course-main { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.lk-cont .lk-cont-kicker { font-size: 11px; }
.lk-cont .lk-course-main strong { font-size: 17px; line-height: 1.2; }
.lk-cont .lk-course-main > span:last-child { font-size: 13px; }
.lk-cont .lk-course-ring { width: 50px; height: 50px; } .lk-cont .lk-course-ring span { width: 40px; height: 40px; font-size: 12px; }
.lk-cont-go { align-self: center; flex-shrink: 0; padding: 8px 13px; font-size: 14px; gap: 6px; }
.lk-cont-go svg { width: 14px; height: 14px; }
.lk-cont.empty { display: flex; flex-direction: column; align-items: flex-start; }
.lk-tiles .lk-course-ring { width: 44px; height: 44px; } .lk-tiles .lk-course-ring span { width: 35px; height: 35px; font-size: 11px; }
.lk-tiles .lk-course-ring span svg { width: 16px; height: 16px; }
.lk-tiles .medal-card { padding: 12px 3px; }
.lk-tiles .medal-name { font-size: 11.5px; letter-spacing: -.1px; hyphens: auto; }
.lk-tiles .tile-sub { font-size: 11px; }
.lk-tiles .tile-badge { top: 5px; right: 5px; width: 17px; height: 17px; } .lk-tiles .tile-badge svg { width: 10px; height: 10px; }
.lk-tiles .tile-new { padding: 10px 2px; }
.lk-ref-h { margin-top: 18px; }

/* ---------------------------------------------------------------- display mode: standard (no attribute), focus, fun */
.mode-pick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.mode-opt { position: relative; }
.mode-opt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.mode-opt span { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 4px; border-radius: 14px; border: 2px solid var(--line); background: var(--surface); color: var(--muted); font-size: 13px; }
.mode-opt b { color: var(--ink); font-weight: 800; }
.mode-opt input:checked + span { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-ink); }
.mode-opt input:focus-visible + span { outline: 3px solid var(--indigo); outline-offset: 2px; }
/* focus: calm – no motion, no confetti, fewer explanatory extras */
[data-mode="focus"] *, [data-mode="focus"] *::before, [data-mode="focus"] *::after { animation-duration: 0s !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition: none !important; }
[data-mode="focus"] .confetti, [data-mode="focus"] .mode-extra, [data-mode="focus"] .lk-legend { display: none !important; }
/* fun: livelier entrances */
[data-mode="fun"] .animate .medal-card, [data-mode="fun"] .animate .topic { animation: bounce-in .6s cubic-bezier(.2, .9, .3, 1.4) both; animation-delay: calc(var(--i, 0) * 70ms); }
/* Fun mode keeps the lively entrance of the earlier versions */
[data-mode="fun"] .animate .medal.ring-m { animation: pop .5s cubic-bezier(.2, .9, .3, 1.5) both, ring-fill 1.2s cubic-bezier(.3, .7, .3, 1) both; animation-delay: calc(150ms + var(--i, 0) * 60ms); }
[data-mode="fun"] .animate .medal-trophy { animation: pop .5s cubic-bezier(.2, .9, .3, 1.6) both; animation-delay: calc(500ms + var(--i, 0) * 60ms); }
[data-mode="fun"] .animate .lb-row { animation: slide-in .45s ease-out both; animation-delay: calc(250ms + var(--i, 0) * 45ms); }
[data-mode="fun"] .animate .duel-card { animation: rise .4s ease-out both; animation-delay: calc(var(--i, 0) * 60ms); }
[data-mode="fun"] .tile-btn:active, [data-mode="fun"] .card:active { transform: scale(.96) rotate(-1deg); }

/* profile: language as flags in one row, statistics as one calm row */
.lang-row { display: flex; flex-direction: column; align-items: stretch; gap: 10px; padding: 12px 14px; }
.lang-cur { font-weight: 700; }
.lang-flags { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.lang-flag { font-size: 22px; line-height: 1; width: 100%; height: 40px; border-radius: 10px; border: 2px solid transparent; background: var(--bg); cursor: pointer; padding: 0; }
.lang-flag.on { border-color: var(--accent); background: var(--accent-soft); }
.stats-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; padding: 12px 10px; text-align: center; }
.stats-row > div { display: flex; flex-direction: column; gap: 2px; }
.stats-row strong { font-size: 17px; font-weight: 900; font-variant-numeric: tabular-nums; }
.stats-row span { font-size: 11px; color: var(--muted); font-weight: 700; line-height: 1.2; }
.stats-duels { grid-column: 1 / -1; margin: 6px 0 0; font-size: 13px; color: var(--muted); font-weight: 700; }
.stats-duels b.w { color: var(--good-ink); } .stats-duels b.l { color: var(--bad); }

/* focus mode: show the essentials only – fewer panels, symbols and rings */
[data-mode="focus"] .mode-busy { display: none !important; }
[data-mode="focus"] .lk-tiles .lk-course-ring, [data-mode="focus"] .lk-tiles .tile-badge, [data-mode="focus"] .lk-cont .lk-course-ring { display: none; }
[data-mode="focus"] .lk-tiles .tile-in { background: var(--surface); }
[data-mode="focus"] .lk-tiles .medal-card { justify-content: center; min-height: 92px; }
[data-mode="focus"] .medals .medal-card .medal, [data-mode="focus"] .medals .medal-card .ring-m, [data-mode="focus"] .tile-gear, [data-mode="focus"] .medal-trophy { display: none; }
[data-mode="focus"] .medals .medal-card { justify-content: center; min-height: 92px; }
[data-mode="focus"] .achs, [data-mode="focus"] .lb-row .flag, [data-mode="focus"] .scope-btn svg, [data-mode="focus"] .staff { display: none; }
[data-mode="focus"] .home-course-ic, [data-mode="focus"] .start-play, [data-mode="focus"] .gl-card > svg:first-child { display: none; }
[data-mode="focus"] .hello .title { font-size: 26px; }

/* practice: a topic can be switched off – grey tile */
.seg4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.seg4 .seg-btn { font-size: 13px; padding: 4px 4px; line-height: 1.2; }
.tile-off { background: var(--surface-2); opacity: .75; }
.tile-off .medal-name, .tile-off .tile-sub { color: var(--muted); }
.tile-off .tile-focus.off { font-weight: 800; }

/* courses: passed = gold, left = grey with the progress kept */
.lk-tiles .tile-passed { background: var(--gold-soft); box-shadow: inset 0 0 0 2px var(--gold); }
.lk-tiles .tile-passed .medal-name { color: var(--gold-ink); }
.lk-tiles .tile-passed .tile-sub { color: var(--gold-ink); font-weight: 800; }
.tile-medal { width: 44px; height: 44px; border-radius: 50%; background: var(--gold); color: var(--gold-ink); display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 0 0 3px var(--surface), 0 2px 8px rgba(0, 0, 0, .15); }
.tile-medal svg { width: 24px; height: 24px; }
.lk-tiles .tile-paused { background: var(--surface-2); box-shadow: inset 0 0 0 2px var(--line-strong); }
.lk-tiles .tile-paused .lk-course-ring { filter: grayscale(1); opacity: .7; }
.lk-tiles .tile-paused .tile-medal { filter: grayscale(.6); opacity: .8; }
.lk-tiles .tile-paused .medal-name, .lk-tiles .tile-paused .tile-sub { color: var(--muted); }
.lk-leg.passed { background: var(--gold-soft); box-shadow: inset 0 0 0 2px var(--gold); }
.lk-leg.paused { background: var(--surface-2); box-shadow: inset 0 0 0 2px var(--line-strong); margin-left: 8px; }
.lk-leg.passed { margin-left: 8px; }
.lk-leave { display: block; margin: 18px auto 4px; background: none; border: 0; color: var(--muted); font: inherit; font-size: 14px; font-weight: 700; text-decoration: underline; cursor: pointer; }
.lk-btn.danger { background: var(--bad-line); color: #fff; border: 0; }
[data-mode="focus"] .lk-tiles .tile-medal { display: none; }
.lk-paused-note { margin: 0; padding: 8px 12px; border-radius: 12px; background: var(--surface-2); font-size: 14px; color: var(--ink); }
.lk-legend { gap: 6px 14px; }
.lk-leg-i { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.lk-leg-i .lk-leg { margin: 0 !important; }
.tile-off { box-shadow: inset 0 0 0 1.5px var(--line-strong); }

/* mandatory: lock on tiles, disabled leave link, admin switches */
.tile-lock { position: absolute; top: 6px; left: 6px; width: 18px; height: 18px; border-radius: 50%; background: var(--surface-2); color: var(--muted); display: inline-flex; align-items: center; justify-content: center; }
.tile-lock svg { width: 11px; height: 11px; }
.lk-leave.locked { color: var(--muted); opacity: .55; text-decoration: none; display: flex; justify-content: center; align-items: center; gap: 6px; width: 100%; }
.lk-leave.locked svg { width: 14px; height: 14px; }
.lk-mand-note { text-align: center; margin: 0; font-size: 12px; color: var(--muted); font-weight: 700; }
.mand-h { margin: 6px 0 0; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.mand-list { list-style: none; margin: 0; padding: 0; }
.mand-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.mand-sw { width: 46px; height: 28px; border-radius: 99px; border: 0; background: var(--line-strong); position: relative; cursor: pointer; flex-shrink: 0; }
.mand-sw i { position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: left .15s; }
.mand-sw.on { background: var(--accent); }
.mand-sw.on i { left: 21px; }

/* admin: topics as tiles, settings rows */
.at-tiles .at-tile { min-height: 112px; justify-content: center; }
.at-num { font-size: 22px; font-weight: 900; color: var(--indigo); line-height: 1; }
.lc-pill.mand { display: inline-flex; align-items: center; gap: 4px; background: var(--surface-2); color: var(--ink); margin-right: 6px; }
.mand-sw:disabled { opacity: .5; cursor: default; }
.at-warn { color: var(--bad-line); }
.inv-label { font-size: 14px; font-weight: 700; color: var(--muted); }
.inv-input { max-width: 200px; }
.inv-hint { margin-top: -6px; }

/* areas (Rubriken): filter chips on Courses and Practice, one heading per area */
.area-chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 4px -16px 2px; padding: 2px 16px 4px; }
.area-chips::-webkit-scrollbar { display: none; }
.area-chip { flex: none; font: inherit; font-size: 13.5px; font-weight: 700; padding: 7px 14px; border-radius: 999px; border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--ink); cursor: pointer; white-space: nowrap; }
.area-chip.on { border-color: var(--accent); background: var(--accent); color: var(--surface); }
.area-h { margin: 12px 0 6px; font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.lk-subject .lk-subject-title + .medals { margin-top: 6px; }
.lk-subject .medals + .lk-subject-title { margin-top: 14px; }
/* admin: area list and the area picker of a course or topic */
.area-row { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-top: 1px solid var(--line, var(--surface-2)); }
.area-row:first-of-type { border-top: 0; }
.area-row .grow { min-width: 0; }
.area-pick { display: flex; flex-wrap: wrap; gap: 6px; }
.area-pick .area-chip { font-size: 13px; padding: 6px 12px; }
.area-pick .area-chip.main { opacity: .45; cursor: default; }
.at-group { margin: 10px 0 6px; }
.area-row .icon-btn { width: 32px; height: 32px; flex: none; }

/* ================================================================ Courses and Practice: areas as columns (Standard, Fun)
   One grid: row 1 = all area headings, row 2 = their tiles, so every list starts at the same height.
   Thin lines between the columns; about three fit on a phone, the row scrolls sideways for more. */
.lk-cols { display: grid; grid-template-rows: auto 1fr; grid-auto-flow: column; grid-auto-columns: max(104px, min(160px, calc((100% - 2px) / 3)));
  overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none; margin: 6px -16px 0; padding: 2px 16px 8px; scroll-padding: 0 16px; }
.lk-cols::-webkit-scrollbar { display: none; }
.lk-col-h, .lk-col-list { padding-inline: 6px; border-inline-start: 1px solid var(--line-strong); }
.lk-col-h:first-child, .lk-col-h:first-child + .lk-col-list { border-inline-start: 0; padding-inline-start: 0; }
.lk-col-h { scroll-snap-align: start; margin: 0; padding-bottom: 8px; align-self: stretch; display: flex; align-items: flex-end; font-size: 12px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--accent-ink); line-height: 1.2; hyphens: auto; -webkit-hyphens: auto; overflow-wrap: break-word; }
.lk-col-list { display: flex; flex-direction: column; gap: 6px; padding-top: 8px; box-shadow: inset 0 2px 0 var(--accent-soft); background-clip: padding-box; }
.lk-col-list .medal-card { width: 100%; }
.lk-col-list .medal-name { hyphens: auto; -webkit-hyphens: auto; overflow-wrap: break-word; }
/* Fun: the area names as coloured pills */
[data-mode="fun"] .lk-col-h span { display: inline-block; padding: 4px 10px; border-radius: 999px; background: var(--accent); color: var(--on-accent); text-transform: none; letter-spacing: 0; font-size: 12.5px; }
[data-mode="fun"] .lk-col-list { box-shadow: none; }
[data-mode="fun"] .lk-col-list .medal-card { border-radius: 16px; }
/* the area as a bar along the top edge of each tile, edge to edge, always at the very top.
   The tile outline (an inset shadow) is drawn again on top, so it runs over the bar as well. */
.has-area { overflow: hidden; padding-top: 26px !important; }
.has-area::after { content: ''; position: absolute; inset: 0; border-radius: inherit; box-shadow: inherit; pointer-events: none; }
.has-area.tile-own::after { display: none; }
.has-area .tile-area { position: absolute; top: 0; left: 0; right: 0; display: block; padding: 3px 8px; font-size: 10px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: center; }
/* area colours (Standard, Fun): neighbouring blues and greens from the palette, light fill + dark text of the same family */
.tile-area, .tile-area.ac-0 { background: #c0e6ff; color: #002c60; }
.tile-area.ac-1 { background: #ccf2fa; color: #003d54; }
.tile-area.ac-2 { background: #d6dbfc; color: #000075; }
.tile-area.ac-3 { background: #e3fae0; color: #124f00; }
.tile-area.ac-4 { background: #edf0cc; color: #3d3d00; }
.tile-area.ac-5 { background: #e4eeef; color: #344042; }
:root[data-theme="dark"] .tile-area.ac-0 { background: #002c60; color: #c0e6ff; }
:root[data-theme="dark"] .tile-area.ac-1 { background: #003d54; color: #ccf2fa; }
:root[data-theme="dark"] .tile-area.ac-2 { background: #000075; color: #d6dbfc; }
:root[data-theme="dark"] .tile-area.ac-3 { background: #124f00; color: #e3fae0; }
:root[data-theme="dark"] .tile-area.ac-4 { background: #3d3d00; color: #edf0cc; }
:root[data-theme="dark"] .tile-area.ac-5 { background: #344042; color: #e4eeef; }
/* Focus: one colour for all areas, nothing colourful */
[data-mode="focus"] .tile-area[class*="ac-"] { background: var(--accent-soft); color: var(--accent-ink); }
.has-area .tile-badge, .has-area .tile-gear, .has-area .tile-corner { top: 24px; }
.has-area .tile-lock { top: 22px; }
[data-mode="focus"] .has-area { justify-content: flex-start; }
[data-mode="focus"] .has-area .medal-name { margin-top: auto; } [data-mode="focus"] .has-area .tile-sub:last-child { margin-bottom: auto; }
/* filter row: area dropdown + "My courses" / "Available" switches */
.lk-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 4px 0 12px; }
.area-sel { position: relative; display: inline-flex; }
.area-sel select { appearance: none; -webkit-appearance: none; font: inherit; font-size: 14px; font-weight: 800; color: var(--ink); background: var(--surface); border: 1.5px solid var(--line-strong); border-radius: 999px; padding: 7px 32px 7px 14px; cursor: pointer; max-width: 60vw; }
.area-sel::after { content: ''; position: absolute; right: 14px; top: 50%; width: 7px; height: 7px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: translateY(-70%) rotate(45deg); pointer-events: none; }
[dir="rtl"] .area-sel select { padding: 7px 14px 7px 32px; } [dir="rtl"] .area-sel::after { right: auto; left: 14px; }
.lk-sw { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; font-weight: 700; color: var(--ink); cursor: pointer; white-space: nowrap; }
.lk-sw input { position: absolute; opacity: 0; width: 1px; height: 1px; }
/* the switch looks like the Active / Mandatory switches in the admin area */
.lk-sw-box { position: relative; width: 40px; height: 24px; border-radius: 99px; background: var(--line-strong); flex: none; transition: background .15s; }
.lk-sw-box::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, .2); transition: left .15s; }
.lk-sw input:checked + .lk-sw-box { background: var(--accent); }
.lk-sw input:checked + .lk-sw-box::after { left: 19px; }
[dir="rtl"] .lk-sw-box::after { left: auto; right: 3px; transition: right .15s; } [dir="rtl"] .lk-sw input:checked + .lk-sw-box::after { left: auto; right: 19px; }
.lk-sw input:focus-visible + .lk-sw-box { outline: 2px solid var(--accent); outline-offset: 2px; }
.lk-none { margin: 10px 0; color: var(--muted); font-size: 14px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:root:not([data-mode="fun"]) .lk-tiles .tile-course .lk-course-ring { background: conic-gradient(var(--indigo) var(--p), var(--track) 0); }
/* long course names and states break between syllables instead of running out of the tile */
.lk-tiles .medal-name, .lk-tiles .tile-sub, .medals .medal-name { hyphens: auto; -webkit-hyphens: auto; overflow-wrap: break-word; max-width: 100%; }

/* ================================================================ calm tiles (Courses and Practice, every mode)
   One thin, soft dark-grey outline for every tile (it also runs over the area bar).
   White = yours / switched on, light grey = not enrolled, left or switched off. No check badges. */
:root { --tile-line: color-mix(in srgb, var(--muted) 38%, var(--line-strong)); }
.medals .tile-btn.medal-card:not(.tile-own) { border: 0; box-shadow: inset 0 0 0 1.5px var(--tile-line); }
.medals .tile-off { background: var(--surface-2); opacity: 1; }
.lk-tiles .tile-in, .lk-tiles .tile-passed, .lk-tiles .tile-fresh { background: var(--surface); }
.lk-tiles .tile-new, .lk-tiles .tile-paused { background: var(--surface-2); padding: 12px 3px; }
.lk-tiles .tile-in .medal-name, .lk-tiles .tile-passed .medal-name { color: var(--ink); }
.lk-tiles .tile-in .tile-sub { color: var(--muted); opacity: 1; }
.lk-tiles .tile-passed .tile-sub { color: var(--good-ink); font-weight: 800; }
/* enrolled but not started: the 0 % ring stays grey */
.lk-tiles .tile-fresh .lk-course-ring span { color: var(--muted); }
/* left: grey like "not enrolled", but the kept progress ring (grey) instead of the plus */
.lk-tiles .tile-paused .lk-course-ring { filter: grayscale(1); opacity: .65; }
.lk-legend { display: none !important; }
/* Fun: dark blue outline for active and passed courses, light grey for the others */
[data-mode="fun"] .lk-tiles .tile-in, [data-mode="fun"] .lk-tiles .tile-passed { box-shadow: inset 0 0 0 2px var(--accent-deep) !important; }
[data-mode="fun"] .lk-tiles .tile-new, [data-mode="fun"] .lk-tiles .tile-paused { box-shadow: inset 0 0 0 1.5px var(--line-strong) !important; }
/* filter row on one line on a phone */
.lk-filter { gap: 8px 12px; }
.area-sel select { font-size: 13.5px; padding: 6px 28px 6px 12px; max-width: 42vw; text-overflow: ellipsis; }
.area-sel::after { right: 12px; }
.lk-sw { font-size: 13.5px; gap: 6px; }
.lk-sw-box { width: 36px; height: 22px; } .lk-sw-box::after { width: 16px; height: 16px; }
.lk-sw input:checked + .lk-sw-box::after { left: 17px; } [dir="rtl"] .lk-sw input:checked + .lk-sw-box::after { left: auto; right: 17px; }
@media (max-width: 380px) { .lk-sw { font-size: 12.5px; } .area-sel select { font-size: 12.5px; } }
.area-sel select { width: auto; min-width: 0; min-height: 34px; }
.lk-filter { flex-wrap: nowrap; } .lk-filter > * { min-width: 0; } .lk-sw > span:last-child { overflow: hidden; text-overflow: ellipsis; }
.lk-tiles .tile-course .lk-course-ring { background: conic-gradient(var(--indigo) var(--p), var(--track) 0); }
/* switch labels may take two lines, so they are always readable */
.lk-sw { white-space: normal; } .lk-sw > span:last-child { overflow: visible; text-overflow: clip; line-height: 1.15; }
.lk-filter { align-items: center; }
/* ================================================================ Courses and Practice start the same way:
   title · intro (always two lines high) · one big card of the same height · filter row · tiles */
.tab-intro { margin: 0; color: var(--muted); line-height: 1.45; min-height: 2.9em; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tab-hero { margin-top: 2px; }
.tab-hero > .start-btn, .tab-hero > .lk-cont { height: 92px; min-height: 92px; box-sizing: border-box; overflow: hidden; }
.tab-hero > .start-btn { padding-block: 0; }
.tab-hero > .lk-cont { align-content: center; }
.tab-hero > .lk-cont .lk-course-main strong { display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.tab-hero > .lk-cont.empty { justify-content: center; gap: 2px; }
.tab-hero > .lk-cont.empty > span:last-child { display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; font-size: 13px; }
.lk-filter { margin: 12px 0 12px; min-height: 40px; }
.lk-subject > .lk-filter:first-child { margin-top: 12px; }
/* switches always at the right end of the row */
.lk-sws { display: inline-flex; align-items: center; gap: 12px; margin-inline-start: auto; }
.lk-subject + .lk-facts { margin-top: 12px; }
.lk-subject > .lk-filter ~ .medals, .lk-subject > .lk-filter ~ .lk-none { margin-top: 6px; }
/* status line(s) always at the bottom of the tile, whatever the length of the name */
.medals .medal-card { justify-content: flex-start !important; }
.medals .medal-card .medal-name + .tile-sub { margin-top: auto; }
[data-mode="focus"] .has-area .medal-name { margin-top: auto; }
[data-mode="focus"] .has-area .tile-sub:last-child { margin-bottom: 0; }
.lk-tiles .tile-sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; hyphens: none; }
/* the area dropdown keeps one width, so the switches never move */
.area-sel select { width: 104px; }
/* ================================================================ start page: compact weekly goal card
   small ring · title and status · one line of small figures (icon + number + word) */
.card.goal { flex-wrap: nowrap; gap: 14px; padding: 14px 16px; }
.card.goal .ring { width: 66px; height: 66px; }
.card.goal .ring-in { width: 52px; height: 52px; }
.card.goal .ring-in .big { font-size: 16px; line-height: 1.1; }
.card.goal .ring-in .tiny { font-size: 10.5px; line-height: 1.1; }
.card.goal .lap-badge { font-size: 10.5px; padding: 2px 5px; top: -6px; right: -10px; }
.goal-main { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.goal-t { font-size: 17px; font-weight: 900; line-height: 1.2; }
.goal-s { font-size: 13.5px; color: var(--muted); line-height: 1.3; }
.goal-mini { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 6px; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.goal-mini > span { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.goal-mini b { color: var(--ink); font-weight: 900; font-variant-numeric: tabular-nums; }
.goal-mini svg { color: var(--muted); flex: none; }
.goal-mini .flame { display: inline-flex; }
/* Profile: "My certificates" entry card and the certificate tiles */
.cert-entry { display: flex; align-items: center; gap: 12px; width: 100%; text-align: start; border: 0; font: inherit; color: inherit; cursor: pointer; }
.cert-tiles .tile-cert { background: var(--surface); }
.cert-tiles .tile-cert .tile-medal { width: 40px; height: 40px; }
.cert-tiles .tile-cert .tile-sub { color: var(--muted); }
.cert-sheet .lk-filter { margin: 4px 0 8px; }
.cert-entry > svg:last-child { transform: rotate(180deg); color: var(--muted); flex: none; }
[dir="rtl"] .cert-entry > svg:last-child { transform: none; }
/* start page: "Learn something new" and "Practice round" as two cards side by side */
.home-duo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.home-duo > .home-course { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 14px; margin: 0; min-height: 0; text-align: start; position: relative; }
.home-duo > .home-course:only-child { grid-column: 1 / -1; }
.home-duo .home-course-ic { width: 40px; height: 40px; }
.home-duo .home-course > .grow { width: 100%; }
.home-duo .home-course strong { font-size: 15px; line-height: 1.2; }
.home-duo .home-course .tiny { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.3; }
.home-duo .home-course > svg:last-child { position: absolute; top: 16px; right: 14px; }
[dir="rtl"] .home-duo .home-course > svg:last-child { right: auto; left: 14px; }
/* player card: small medal row, then courses passed and certificates side by side */
.pc-medals-s { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; }
.pc-medals-s .pc-medal { padding: 8px 2px; border-radius: 12px; }
.pc-medals-s .pc-medal strong { font-size: 15px; }
.pc-learn { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.pc-box { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 12px 8px; border-radius: 14px; background: var(--bg); border: 0; font: inherit; color: var(--ink); text-align: center; }
.pc-box svg { color: var(--indigo); }
.pc-box strong { font-size: 20px; font-variant-numeric: tabular-nums; }
.pc-box-btn { cursor: pointer; box-shadow: inset 0 0 0 1.5px var(--tile-line); }
.pc-box-btn:disabled { cursor: default; opacity: .55; box-shadow: none; }
.pc-box-go { position: absolute; top: 10px; right: 10px; display: inline-flex; } .pc-box-go svg { transform: rotate(180deg); color: var(--muted); }
[dir="rtl"] .pc-box-go { right: auto; left: 10px; } [dir="rtl"] .pc-box-go svg { transform: none; }
.ach.cert svg { color: var(--indigo); }
/* compact goal card v2: ring · title and status · figures stacked on the right */
.card.goal { align-items: center; gap: 12px; padding: 12px 14px; }
.card.goal .ring { width: 60px; height: 60px; } .card.goal .ring-in { width: 47px; height: 47px; }
.card.goal .ring-in .big { font-size: 14.5px; }
.goal-main { gap: 1px; }
.goal-t { font-size: 16px; }
.goal-s { font-size: 13px; }
.goal-x { color: var(--accent-ink); font-weight: 800; }
.card.goal > .goal-mini { flex: none; flex-direction: column; flex-wrap: nowrap; align-items: flex-start; gap: 3px; margin: 0; padding-inline-start: 12px; border-inline-start: 1px solid var(--line); font-size: 12px; }
/* start page duo: icon and title on one line, one short line below */
.home-duo > .home-course { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 4px 10px; padding: 12px; }
.home-duo .home-course-ic { width: 34px; height: 34px; border-radius: 11px; grid-row: 1; }
.home-duo .home-course-ic svg { width: 18px; height: 18px; }
.home-duo .home-course > .grow { display: contents; }
.home-duo .home-course strong { grid-row: 1; grid-column: 2; font-size: 15.5px; }
.home-duo .home-course .tiny { grid-row: 2; grid-column: 1 / -1; -webkit-line-clamp: 1; }
.home-duo .home-course > svg:last-child { position: static; grid-row: 1; grid-column: 3; }
.goal-t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-duo .home-course .tiny { -webkit-line-clamp: 2; }

/* ---------------------------------------------------------------- VDI UHF-ECG map */
.uhf-fig svg { width: min(100%, 420px); }
.uhf-map .uhf-frame, .uhf-env .uhf-frame { fill: none; stroke: var(--muted); stroke-width: .6; }
.uhf-lab { font-size: 9px; font-weight: 800; fill: var(--ink); }
.uhf-lab.on { fill: var(--indigo); }
.uhf-tlab, .uhf-qh { font-size: 8px; font-weight: 700; fill: var(--muted); }
.uhf-q { font-size: 7.5px; font-weight: 800; fill: var(--muted); font-variant-numeric: tabular-nums; }
.uhf-q.warn { fill: var(--an-warn); }
.uhf-tick { stroke: var(--muted); stroke-width: .6; }
.uhf-at { fill: none; stroke: #111; stroke-width: 1.3; stroke-linejoin: round; }
.uhf-atdot { fill: #111; stroke: #fff; stroke-width: .6; }
.uhf-ved { fill: #fff; }
.uhf-nd { fill: none; stroke: #fff; stroke-width: 1.3; stroke-dasharray: 3 2; stroke-linejoin: round; }
.uhf-pace { fill: rgba(200, 200, 200, .82); }
.uhf-pace.second { fill: rgba(190, 190, 190, .9); }
.uhf-pacepk { stroke: #6b6b6b; stroke-width: 1.6; }
.uhf-greyline { stroke: rgba(205, 205, 205, .9); stroke-width: 1.2; }
.uhf-sel { fill: none; stroke: #fff; stroke-width: 1.2; stroke-dasharray: 2 1.5; }
.uhf-cur { stroke: var(--ink); stroke-width: 1; }
.uhf-curtri { fill: var(--ink); }
.uhf-curlab { font-size: 7px; font-weight: 900; fill: var(--ink); text-anchor: middle; }
.uhf-hit { fill: transparent; cursor: pointer; }
.uhf-legend { display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: 11px; font-weight: 700; color: var(--muted); }
.uhf-legend span { display: inline-flex; align-items: center; gap: 5px; }
.uhf-legend i { width: 14px; height: 10px; border-radius: 3px; display: inline-block; }
.uhf-legend i.grad { background: linear-gradient(to right, rgb(16, 38, 92), rgb(150, 205, 245)); }
.uhf-legend i.dot { width: 8px; height: 8px; border-radius: 50%; background: #111; box-shadow: 0 0 0 1.5px #fff, 0 0 0 2.5px var(--muted); }
.uhf-toggles { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.uhf-chk { border: 1.5px solid var(--lk-surface-2); background: var(--surface); color: var(--muted); border-radius: 99px; padding: 6px 12px 6px 28px; font-size: 13px; font-weight: 800; cursor: pointer; position: relative; }
.uhf-chk::before { content: ''; position: absolute; left: 9px; top: 50%; width: 12px; height: 12px; margin-top: -6px; border-radius: 4px; border: 2px solid var(--muted); box-sizing: border-box; }
.uhf-chk[aria-pressed="true"] { color: var(--ink); border-color: var(--indigo); }
.uhf-chk[aria-pressed="true"]::before { background: var(--indigo); border-color: var(--indigo); }
.uhf-env .uhf-envline { fill: none; stroke: var(--indigo); stroke-width: 1.8; stroke-linejoin: round; }
.uhf-env .uhf-lvl { stroke: var(--muted); stroke-width: .6; stroke-dasharray: 3 2; }
.uhf-env .uhf-vdband { fill: rgba(255, 140, 32, .14); }
.uhf-env .uhf-vd { stroke: var(--an-warn); stroke-width: 2; }
.uhf-env .uhf-vdlab { font-size: 9px; font-weight: 900; fill: var(--an-warn); }
.uhf-env .uhf-atmark { stroke: #111; stroke-width: .8; stroke-dasharray: 2 2; }
.uhf-septfig svg { width: min(100%, 420px); }
.uhf-sept { fill: #F3C9C9; stroke: #D98488; stroke-width: 1; }
.uhf-lbb { stroke: var(--gold, #E0A100); stroke-width: 3; stroke-linecap: round; }
.uhf-leadbody { stroke: var(--ink); stroke-width: 4; stroke-linecap: round; }
.uhf-leadtip { fill: var(--indigo); stroke: var(--surface); stroke-width: 1.5; }
.uhf-tag { display: block; font-style: normal; font-size: 10px; font-weight: 800; margin-top: 2px; color: var(--muted); }
.uhf-tag.good { color: var(--good); } .uhf-tag.warn { color: var(--an-warn); }
.uhf-nboxes { display: grid; grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 3px; }
.uhf-nbox { font-size: 10px; font-weight: 900; text-align: center; padding: 5px 0; border-radius: 6px; color: #10301a; background: #6CC24A; }
.uhf-nbox.l1 { background: #B5D334; } .uhf-nbox.l2 { background: #F2C230; } .uhf-nbox.l3 { background: #F08A24; color: #fff; } .uhf-nbox.l4 { background: #D7263D; color: #fff; }
.uhf-fb { display: flex; flex-direction: column; gap: 8px; }
.uhf-fb:empty { display: none; }
.uhf-next { align-self: flex-start; margin-top: 4px; }
.uhf-torso .lk-el.limb circle { fill: var(--gold-soft, #FFF1C9); }
.uhf-torso .lk-el.limb.on circle { fill: var(--indigo); }
.uhf-torso .lk-el text.uhf-ct { font-size: 5.6px; }

/* "Report a problem" flag: a small tab on the screen edge on every page (in the chapter player: in the top bar) */
.bug-tab { position: fixed; right: 0; top: 58%; z-index: 40; width: 30px; height: 40px; border: 1px solid var(--line); border-right: 0;
  border-radius: 12px 0 0 12px; background: var(--surface); color: var(--muted); display: inline-flex; align-items: center; justify-content: center;
  padding: 0 0 0 2px; cursor: pointer; opacity: .85; box-shadow: -2px 2px 8px rgba(0, 0, 0, .06); }
.bug-tab.rtl { right: auto; left: 0; border-right: 1px solid var(--line); border-left: 0; border-radius: 0 12px 12px 0; padding: 0 2px 0 0; }
.bug-tab:hover, .bug-tab:focus-visible { opacity: 1; color: var(--accent); }
.lk-report { width: auto; height: 36px; padding: 0 8px; gap: 4px; display: inline-flex; align-items: center; color: var(--muted); }
.lk-report-t { font-size: 13px; font-weight: 800; }
.lk-report:hover, .lk-report:focus-visible { color: var(--accent); }
.bug-overlay h2 svg { vertical-align: -3px; }
@media print { .bug-tab { display: none; } }

/* Learn: schematic 12-lead ECG, wave front, rate drill */
.lk-ecg12 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.lk-ecg12-col { display: grid; gap: 4px; }
.lk-ecg12 .lk-tile { border-radius: 8px; }
.lk-ecg12 .lk-tile-name { font-size: 11px; top: 2px; left: 4px; }
.lk-ecg12 + .lk-rhythm { margin-top: 6px; }
.lk-wave-fig svg { width: min(100%, 360px); }
.lk-wave-fig .lk-cell { fill: var(--lk-surface-2); stroke: var(--line); stroke-width: 1; transition: fill .15s; }
.lk-wave-fig .lk-cell.on { fill: var(--indigo-soft); stroke: var(--indigo); }
.lk-wave-fig .lk-wave-front { stroke: var(--indigo); stroke-width: 3; stroke-linecap: round; }
.lk-wave-fig .lk-wave-dir { fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.lk-wave-fig .lk-el { fill: var(--surface); stroke: var(--ink); stroke-width: 2; }
.lk-wave-fig .lk-el-t { font-size: 13px; font-weight: 900; text-anchor: middle; fill: var(--ink); }

/* Practice Lab */
.lab-card { border: 1.5px solid var(--indigo-soft); }
.lab-card > svg:first-child, .title .lab-ic, .lab-ic { color: var(--indigo); }
.lab-intro { background: var(--indigo-soft); }
.lab-filter { margin: 12px 0 8px; }
.lab-tile { align-items: center; }
.lab-tile .lab-ic { display: inline-flex; align-items: center; justify-content: center; width: 52px; height: 52px; border-radius: 16px; background: var(--indigo-soft); flex-shrink: 0; }
.lab-badge { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; font-weight: 900; color: var(--indigo); background: var(--indigo-soft); border-radius: 99px; padding: 1px 7px; vertical-align: middle; }
.title svg { vertical-align: -3px; color: var(--indigo); }
.lk-labcard { border-left: 4px solid var(--accent); border-radius: 4px 18px 18px 4px; padding: 6px 4px 6px 14px; }
.lk-lab-go { display: flex; margin-top: 4px; }
.lk-lab-link { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 10px 12px; border-radius: 14px; border: 1.5px solid var(--accent-soft); background: var(--surface); color: var(--ink); cursor: pointer; font: inherit; }
.lk-lab-link .ic { flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-ink); display: flex; align-items: center; justify-content: center; }
.lk-lab-link .ic svg { width: 20px; height: 20px; }
.lk-lab-link .tx { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.lk-lab-link .tx b { font-weight: 800; font-size: 15px; color: var(--accent-ink); }
.lk-lab-link .tx small { font-size: 12px; color: var(--muted); }
.lk-lab-link .chev { flex: none; color: var(--accent-ink); display: flex; }
@media (hover: hover) and (pointer: fine) { .lk-lab-link:hover { border-color: var(--accent); } }

/* ---------- Training Lab widgets: two vectors (A red, B blue), 3D shadows, naming the QRS ---------- */
:root { --lk-va: #E0183D; --lk-vb: #2E4AED; }
:root[data-theme="dark"] { --lk-va: #FF5C77; --lk-vb: #7DA2FF; }
.lk-dial .vlab { font: 900 13px 'Nunito', system-ui, sans-serif; text-anchor: middle; dominant-baseline: central; stroke: none; }
.lk-dial-pair .lk-dial .vec line { stroke: var(--lk-vb); } .lk-dial-pair .lk-dial .vec path, .lk-dial-pair .lk-dial .vec .handle, .lk-dial-pair .lk-dial .vec .vlab { fill: var(--lk-vb); }
.lk-dial .vec2 line { stroke: var(--lk-va); stroke-width: 5; stroke-linecap: round; }
.lk-dial .vec2 path, .lk-dial .vec2 .vlab { fill: var(--lk-va); }
.lk-dial-pair.mv-a .lk-dial .vec line { stroke: var(--lk-va); } .lk-dial-pair.mv-a .lk-dial .vec path, .lk-dial-pair.mv-a .lk-dial .vec .handle, .lk-dial-pair.mv-a .lk-dial .vec .vlab { fill: var(--lk-va); }
.lk-dial-pair.mv-a .lk-dial .vec2 line { stroke: var(--lk-vb); } .lk-dial-pair.mv-a .lk-dial .vec2 path, .lk-dial-pair.mv-a .lk-dial .vec2 .vlab { fill: var(--lk-vb); }
.lk-trace-pair .lk-trace:not(.lk-trace-b) { stroke: #D0102F; }
.lk-trace-b { fill: none; stroke: #1F3BE0; stroke-width: 1.7px; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.lk-vc-read { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; text-align: center; font-weight: 800; font-size: 15px; font-variant-numeric: tabular-nums; }
.lk-vc-read > span { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.lk-vc-read b { white-space: nowrap; } .lk-vc-read small { font-size: 13px; font-weight: 700; white-space: nowrap; }
.lk-vc-read i { display: inline-block; width: 14px; height: 4px; border-radius: 2px; margin-right: 6px; vertical-align: middle; }
.lk-vc-read .vc-a { color: var(--lk-va); } .lk-vc-read .vc-a i { background: var(--lk-va); }
.lk-vc-read .vc-b { color: var(--lk-vb); } .lk-vc-read .vc-b i { background: var(--lk-vb); }
.lk-dial-cycle .lead-axis line.pos { stroke: var(--ink); opacity: .45; stroke-width: 1.6; }
.lk-dial-cycle .lead-axis text { fill: var(--ink); }
.lk-dial-cycle .vec line { stroke-width: 6; }
.lk-dial-cycle .ghost line { stroke-width: 3; opacity: .55; } .lk-dial-cycle .ghost path { opacity: .55; }
.lk-3d svg { width: min(100%, 360px); height: auto; display: block; margin: 0 auto; }
.lk-3d .w3-wall { fill: var(--indigo-soft); stroke: var(--indigo); stroke-width: 1; opacity: .7; }
.lk-3d .w3-floor { fill: var(--gold-soft); stroke: var(--gold); stroke-width: 1; opacity: .7; }
.lk-3d .w3-lab { font: 800 10px 'Nunito', system-ui, sans-serif; fill: var(--muted); }
.lk-3d .w3-lab.strong { fill: var(--ink); font-size: 11px; }
.lk-3d .w3-sh { stroke-width: 4; stroke-linecap: round; opacity: .85; }
.lk-3d .w3-sh.f { stroke: var(--indigo); } .lk-3d .w3-sh.h { stroke: var(--gold-ink); }
.lk-3d .w3-proj { stroke: var(--muted); stroke-width: 1; stroke-dasharray: 3 3; }
.lk-3d .w3-ray { stroke-width: 1.2; stroke-dasharray: 2 3; opacity: .8; } .lk-3d .w3-ray.f { stroke: var(--indigo); } .lk-3d .w3-ray.h { stroke: var(--gold-ink); }
.lk-3d .w3-lamp circle { fill: #FFE38A; stroke: #C99A00; stroke-width: 1.5; } .lk-3d .w3-lamp path { stroke: #C99A00; stroke-width: 1.6; stroke-linecap: round; }
.lk-3d .w3-vec { stroke: var(--accent); stroke-width: 5; stroke-linecap: round; }
.lk-3d .w3-tip { fill: var(--accent); } .lk-3d .w3-hub { fill: var(--ink); }
.lk-3d .w3-o.f { fill: var(--indigo); } .lk-3d .w3-o.h { fill: var(--gold-ink); }
.lk-bodycircle, .lk-planecut { width: min(100%, 280px); height: auto; display: block; margin: 0 auto; }
.lk-bodycircle .heart { fill: #F3C9C4; stroke: #C98880; stroke-width: 1.4; }
.lk-bodycircle .ring { fill: none; stroke: var(--indigo); stroke-width: 2; stroke-dasharray: 5 4; }
.lk-bodycircle .tick { stroke: var(--indigo); stroke-width: 2; }
.lk-bodycircle .deg { font: 900 11px 'Nunito', system-ui, sans-serif; fill: var(--ink); text-anchor: middle; dominant-baseline: central; }
.lk-bodycircle .deg2 { font: 700 9px 'Nunito', system-ui, sans-serif; fill: var(--muted); text-anchor: middle; dominant-baseline: central; }
.lk-bodycircle .arrow line { stroke: var(--accent); stroke-width: 5; stroke-linecap: round; } .lk-bodycircle .arrow circle, .lk-bodycircle .arrow-head { fill: var(--accent); }
.lk-planecut .cut { fill: var(--indigo); fill-opacity: .25; stroke: var(--indigo); stroke-width: 2; }
.lk-planecut .cut-lab { font: 800 11px 'Nunito', system-ui, sans-serif; fill: var(--indigo); text-anchor: middle; }
.lk-planecut .look { stroke: var(--indigo); stroke-width: 2; stroke-dasharray: 3 3; } .lk-planecut .look-h { fill: none; stroke: var(--indigo); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.lk-planecut .eye path { fill: var(--surface); stroke: var(--ink); stroke-width: 1.6; } .lk-planecut .eye circle { fill: var(--ink); }
.lk-chest .bonefill { fill: #CDBBA5; }
.lk-fig-pair { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 8px; align-items: center; }
.lk-fig-pair svg { width: 100%; height: auto; display: block; }
.lk-vsum svg { width: min(100%, 340px); height: auto; display: block; margin: 0 auto; overflow: visible; }
.lk-vsum .vs-heart .lk-region { opacity: .55; } .lk-vsum .vs-heart .lk-cs, .lk-vsum .vs-heart .lk-septum { opacity: .25; }
.lk-vsum .va { transition: transform .9s ease-in-out, opacity .4s; }
.lk-vsum .va line { stroke: var(--indigo); stroke-width: 3; stroke-linecap: round; } .lk-vsum .va path { fill: var(--indigo); }
.lk-vsum .vs-sum { opacity: 0; transition: opacity .5s; }
.lk-vsum .vs-sum line { stroke: var(--accent); stroke-width: 7; stroke-linecap: round; } .lk-vsum .vs-sum path { fill: var(--accent); }
.lk-vsum .summed .vs-sum { opacity: 1; } .lk-vsum .summed .va { opacity: .45; }
.lk-vsum .vs-o { fill: var(--ink); }
.lk-row-c { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: space-between; }
.lk-name-fig { display: flex; justify-content: center; }
.lk-name-out { min-height: 48px; display: flex; align-items: center; justify-content: center; font: 900 30px 'Nunito', system-ui, sans-serif; letter-spacing: 1px; border: 2px dashed var(--line-strong); border-radius: 14px; color: var(--ink); }
.lk-name-out.empty { color: var(--muted); }
.lk-name-keys { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 6px; }
.lk-name-key { min-height: 44px; border-radius: 12px; border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--ink); font: 900 19px 'Nunito', system-ui, sans-serif; cursor: pointer; }
.lk-name-key:active { background: var(--indigo-soft); }
.lk-name-row { display: flex; gap: 8px; justify-content: center; }
.lk-pick .lk-tile { position: relative; cursor: pointer; }
.lk-pick-n { position: absolute; left: 50%; transform: translateX(-50%); bottom: 4px; white-space: nowrap; font-weight: 900; font-size: 14px; color: var(--ink); background: var(--surface); padding: 0 5px; border-radius: 6px; }
.lk-pick .lk-tile.hit { border-width: 2.5px; }
.lk-3d .w3-o.f { fill: var(--indigo); } .lk-3d .w3-o.h { fill: var(--gold-ink); }
/* one camera: the shadow of the arrow on the chosen lead */
.lk-dial .proj .drop { stroke: var(--muted); stroke-width: 1.4; stroke-dasharray: 3 3; }
.lk-dial .proj .len { stroke: #1E9E55; stroke-width: 7; stroke-linecap: round; opacity: .85; }
.lk-dial .proj .len.neg { stroke: var(--lk-va); }
.lk-dial-cam .lead-axis.on line.pos { stroke-width: 3; }
.lk-bodycircle .limb-axis line { stroke: var(--indigo); stroke-width: 1.6; }
.lk-bodycircle .limb-axis line.neg { stroke: var(--lk-va); stroke-width: .9; opacity: .55; }
.lk-bodycircle .limb-axis circle { fill: var(--surface); stroke: var(--indigo); stroke-width: 1.4; }
.lk-bodycircle .limb-axis text { font: 900 9.5px 'Nunito', system-ui, sans-serif; fill: var(--indigo); text-anchor: middle; dominant-baseline: central; }
.lk-cam-row { display: grid; grid-template-columns: 1.15fr 1fr; gap: 8px; align-items: center; }
.lk-cam-row .lk-dial { width: 100%; }
.lk-cam-strip { width: 100%; }
.lk-bodycircle .trail { fill: none; stroke: var(--accent); stroke-width: 1.6; stroke-dasharray: 2 3; opacity: .7; }
.lk-bodycircle .live line { stroke: var(--accent); stroke-width: 5; stroke-linecap: round; } .lk-bodycircle .live path { fill: var(--accent); }
.lk-bodycircle .hub { fill: var(--ink); }

.lk-timeline svg { width: 100%; height: auto; display: block; }
.lk-timeline .axis { stroke: var(--line-strong); stroke-width: 1.5; }
.lk-timeline .bg { fill: var(--line); }
.lk-timeline .fill { fill: var(--accent); opacity: .55; }
.lk-timeline .seg.now .fill { opacity: 1; }
.lk-timeline text { font: 900 10px 'Nunito', system-ui, sans-serif; fill: var(--muted); text-anchor: middle; }
.lk-timeline .seg.now text { fill: var(--accent-ink); }
.lk-timeline .cur { stroke: var(--ink); stroke-width: 2; }
.lk-timeline .time { font-size: 8px; font-weight: 700; text-anchor: end; }
.lk-beat-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.lk-beat-list li { display: flex; gap: 8px; align-items: baseline; padding: 4px 8px; border-radius: 8px; font-size: 14px; visibility: hidden; transition: background .3s; }
.lk-beat-list li b { min-width: 34px; color: var(--accent-ink); }
.lk-beat-list li.shown { visibility: visible; }
.lk-beat-list li.now { background: var(--accent-soft); }
.lk-bodycircle .loop { fill: var(--accent); fill-opacity: .12; stroke: var(--accent); stroke-width: 1.8; stroke-dasharray: 3 3; }
.lk-bodycircle .axis-arrow { opacity: .8; } .lk-bodycircle .axis-arrow line { stroke: #1E9E55; stroke-width: 5; stroke-linecap: round; } .lk-bodycircle .axis-arrow path { fill: #1E9E55; }
.lk-bodycircle .axis-lab { font: 900 11px 'Nunito', system-ui, sans-serif; fill: #1E7A45; text-anchor: middle; dominant-baseline: central; }
/* ball around the heart with the frontal and the horizontal disc */
.lk-sphere { width: min(100%, 330px); height: auto; display: block; margin: 0 auto; overflow: visible; }
.lk-sphere .ball { fill: var(--indigo-soft); fill-opacity: .35; stroke: var(--line-strong); stroke-width: 1.5; }
.lk-sphere .guide { fill: none; stroke: var(--line-strong); stroke-width: 1; stroke-dasharray: 3 4; }
.lk-sphere .plane .disc { stroke-width: 2; }
.lk-sphere .plane.frontal .disc { fill: var(--indigo); fill-opacity: .16; stroke: var(--indigo); }
.lk-sphere .plane.horizontal .disc { fill: var(--gold); fill-opacity: .22; stroke: var(--gold-ink); }
.lk-sphere .plane.off { opacity: .35; }
.lk-sphere .plane line.pos { stroke: var(--ink); stroke-width: 1.6; }
.lk-sphere .plane line.neg { stroke: var(--ink); stroke-width: 1; stroke-dasharray: 3 3; opacity: .4; }
.lk-sphere .lab circle { fill: var(--surface); stroke: var(--indigo); stroke-width: 1.5; }
.lk-sphere .horizontal .lab circle { stroke: var(--gold-ink); }
.lk-sphere .lab text { font: 900 10px 'Nunito', system-ui, sans-serif; fill: var(--ink); text-anchor: middle; dominant-baseline: central; }
.lk-sphere .heart { fill: #F3C9C4; stroke: #C98880; stroke-width: 2; }
.lk-sphere .dir { font: 800 10px 'Nunito', system-ui, sans-serif; fill: var(--muted); text-anchor: middle; dominant-baseline: central; }
.lk-compact .lk-dial { width: min(100%, 236px); }
.lk-compact .lk-leads { gap: 6px; }
.lk-compact .lk-vc-read { font-size: 14px; }
.lk-zone-hint { min-height: 40px; font-size: 14px; text-align: center; color: var(--ink); }
.lk-axis-anim .loop, .lk-axis-anim .axis-arrow, .lk-axis-anim .axis-lab { opacity: 0; transition: opacity .6s; }
.lk-axis-anim .show-axis .loop { opacity: 1; } .lk-axis-anim .show-axis .axis-arrow { opacity: .85; } .lk-axis-anim .show-axis .axis-lab { opacity: 1; }
.lk-axis-anim .show-axis .trail { opacity: 0; }
.lk-bodycircle .live.dim line { stroke: var(--muted); } .lk-bodycircle .live.dim path { fill: var(--muted); }
.lk-planecut .heartside { fill: #F3C9C4; stroke: #C98880; stroke-width: 1.4; }
.lk-frontdisc .disc { fill: var(--indigo); fill-opacity: .14; stroke: var(--indigo); stroke-width: 2; }
.lk-frontdisc .wire { stroke: var(--indigo); stroke-width: 1.2; stroke-dasharray: 3 3; }
.lk-frontdisc .heartf { fill: #F3C9C4; stroke: #C98880; stroke-width: 1.4; }
.lk-planecut .cut.thin { fill-opacity: .18; stroke-width: 1.6; }
.lk-bodycircle .wave-vec { stroke: #6E6E6E; stroke-width: 1; opacity: .55; }
.lk-bodycircle .wave-tip { fill: none; stroke: #8A8A8A; stroke-width: 1.2; stroke-dasharray: 2 2; opacity: .7; }
.lk-bodycircle .wave-lab { font: 900 10px 'Nunito', system-ui, sans-serif; fill: #6E6E6E; text-anchor: middle; dominant-baseline: central; }
.lk-bodycircle .heart.faint { opacity: .3; }
.lk-bodycircle .wave-vec.w-P, .lk-bodycircle .wave-vec.w-T { stroke-width: 1.6; opacity: .7; }
.lk-dial .trail { fill: none; stroke: var(--accent); stroke-width: 1.4; stroke-dasharray: 2 3; opacity: .75; }
.lk-rule.with-vec { grid-template-columns: 58px 70px minmax(0, 1fr); gap: 10px; }
.lk-rule-vec svg { width: 58px; height: 58px; display: block; overflow: visible; }
.lk-rule-vec .ring { fill: none; stroke: var(--line-strong); stroke-width: 1.2; }
.lk-rule-vec .pos { stroke: var(--muted); stroke-width: 1.6; } .lk-rule-vec .neg { stroke: var(--muted); stroke-width: 1.2; stroke-dasharray: 2 3; opacity: .5; }
.lk-rule-vec .cam circle { fill: var(--surface); stroke: var(--indigo); stroke-width: 1.5; } .lk-rule-vec .cam text { font: 900 8px 'Nunito', system-ui, sans-serif; fill: var(--indigo); text-anchor: middle; dominant-baseline: central; }
.lk-rule-vec .arr { stroke: var(--accent); stroke-width: 3.5; stroke-linecap: round; } .lk-rule-vec .arr-h, .lk-rule-vec .hub { fill: var(--accent); }
.lk-rule-vec .hub { fill: var(--ink); }
.lk-rule-vec .cam.plus text { font-size: 12px; }
.lk-rule-vec .mean { stroke: var(--muted); stroke-width: 1.6; stroke-dasharray: 2.5 2.5; opacity: .6; }
.lk-rule-vec .drop { stroke: var(--muted); stroke-width: .8; stroke-dasharray: 1.5 1.5; }
.lk-rule-vec .len { stroke: #1E9E55; stroke-width: 4.5; stroke-linecap: round; opacity: .85; } .lk-rule-vec .len.neg { stroke: var(--lk-va); }
.lk-figure > .lk-seg { margin-bottom: 8px; }
.lk-bodycircle.zoom { width: min(100%, 380px); }
.lk-bodycircle.zoom .deg { font-size: 9px; } .lk-bodycircle.zoom .deg2 { font-size: 7.5px; }
.lk-bodycircle.zoom .wave-lab, .lk-bodycircle.zoom .axis-lab { font-size: 9px; }
.lk-bodycircle.zoom .wave-vec { stroke-width: 1.2; opacity: .7; } .lk-bodycircle.zoom .heart.faint { opacity: .3; } .lk-bodycircle.zoom .axis-arrow line { stroke-width: 4; }
.lk-trans { display: flex; flex-direction: column; gap: 10px; }
.lk-trans-row { background: var(--surface); border-radius: 14px; padding: 8px; display: flex; flex-direction: column; gap: 6px; }
.lk-trans-lab { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 0 4px; }
.lk-trans-lab b { font-weight: 800; } .lk-trans-lab span { font-size: 13px; font-weight: 800; color: var(--accent-ink); }
.lk-trans-strips { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
.lk-trans-strips .lk-tile .lk-tile-name { font-size: 10px; }
.lk-trans-strips .lk-tile.hl { border-color: var(--accent); }
/* 3D: grey shadows with heads, coloured arrow, torches, lead groups */
.lk-3d .w3-sh line { stroke: #6E6E6E; stroke-width: 4; stroke-linecap: round; opacity: .75; } .lk-3d .w3-sh path { fill: #6E6E6E; opacity: .75; }
.lk-3d .w3-vec line { stroke: var(--accent); stroke-width: 5; stroke-linecap: round; } .lk-3d .w3-vec path { fill: var(--accent); }
.lk-3d .w3-torch .body { fill: #4A4A4A; } .lk-3d .w3-torch .head { fill: #2E2E2E; } .lk-3d .w3-torch .btn { fill: #F2C200; }
.lk-3d .w3-torch .beam { fill: #FFE38A; opacity: .7; }
.lk-3d-groups { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.lk-3d-group { border: 2px solid transparent; border-radius: 12px; padding: 6px; transition: border-color .3s, background .3s; }
.lk-3d-group.f { background: var(--indigo-soft); } .lk-3d-group.h { background: var(--gold-soft); }
.lk-3d-group.changed { border-color: var(--accent); }
.lk-3d-gh { font-size: 12px; font-weight: 800; margin-bottom: 4px; display: flex; justify-content: space-between; gap: 4px; } .lk-3d-gh b { font-variant-numeric: tabular-nums; white-space: nowrap; }

/* start page: a topic switched off in Practice – plain grey tile, no ring or trophy */
.home-off .home-off-ring { width: 44px; height: 44px; border-radius: 50%; border: 3px dashed var(--line-strong); }
.lk-return { margin-top: 16px; } .lk-return svg { vertical-align: -4px; }

/* Admin → Players: never signed in, status change, overview of courses and practice */
.tag.never { background: var(--gold-soft, #fff3d6); color: var(--gold-ink, #7a5a00); }
.never-box { background: var(--gold-soft, #fff3d6); border-radius: 14px; padding: 10px 12px; }
.never-box .btn { align-self: flex-start; }
.status-pick { gap: 8px; align-items: center; }
.status-pick select { flex: 1; min-width: 0; }
.btn.danger { background: var(--bad-line); color: #fff; border-color: var(--bad-line); }
.pinfo { max-height: 88vh; overflow-y: auto; }
.pi-sec { border-top: 1px solid var(--line, var(--surface-2)); padding-top: 8px; }
.pi-sec > summary { display: flex; align-items: center; gap: 8px; cursor: pointer; padding: 6px 0; list-style: none; }
.pi-sec > summary::-webkit-details-marker { display: none; }
.pi-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line, var(--surface-2)); }
.pi-row:last-child { border-bottom: 0; }
.pi-row.off b { color: var(--muted); }
.pi-row b { font-size: 14.5px; }
.pi-sel { max-width: 46%; font-size: 13px; padding: 6px 8px; flex: none; }
.pi-lock { display: inline-flex; align-items: center; gap: 3px; color: var(--muted); flex: none; }
.pi-ring { --p: 0%; flex: none; width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--accent) var(--p), var(--track) 0); }
.pi-ring > span { width: 30px; height: 30px; border-radius: 50%; background: var(--surface); display: grid; place-items: center; font-size: 10.5px; font-weight: 800; }
.pi-ring.gold { background: var(--gold, #e0a800); }
.pi-ring.gold > span { color: var(--gold-ink, #7a5a00); }
.pi-ring.empty { background: none; border: 2.5px dashed var(--line-strong); }
.pi-sel { min-height: 38px; padding: 6px 26px 6px 10px; max-width: 44%; }

/* country field: type to filter, list below */
.cpick { position: relative; }
.cpick-in { width: 100%; }
.cpick-list { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 20; max-height: 260px; overflow-y: auto; background: var(--surface); border: 1.5px solid var(--line-strong); border-radius: 14px; box-shadow: 0 8px 24px rgba(0, 0, 0, .12); padding: 4px; }
.cpick-opt { display: flex; align-items: center; width: 100%; text-align: start; font: inherit; font-size: 15px; padding: 10px 12px; border: 0; background: none; color: var(--ink); border-radius: 10px; cursor: pointer; }
.cpick-opt:hover, .cpick-opt:focus { background: var(--surface-2); }
.cpick-opt[hidden], .cpick-none[hidden] { display: none; }
.cpick-none { padding: 10px 12px; margin: 0; }
.cpick-list { display: flex; flex-direction: column; }
.cpick-list[hidden] { display: none; }
.cpick-none { order: 2; }
/* read aloud in a chapter: small speaker in the top bar, a stop square while it reads */
.lk-speak { color: var(--ink); }
.lk-speak.on { color: var(--accent); background: var(--accent-soft); }
/* settings: read-aloud voice */
.voice-row { gap: 8px; align-items: center; }
.voice-row select { flex: 1; min-width: 0; }
.voice-warn { color: var(--gold-ink); }
.voice-tip summary { cursor: pointer; }

/* Profile: slim folding cards, compact colours + mode, footer */
.fold { padding: 0; }
.fold > summary { display: flex; align-items: center; gap: 12px; padding: 14px 16px; cursor: pointer; list-style: none; }
.fold > summary::-webkit-details-marker { display: none; }
.fold-ic { width: 38px; height: 38px; border-radius: 12px; background: var(--accent-soft); color: var(--accent-deep); display: grid; place-items: center; flex: none; }
.fold-chev { color: var(--muted); transform: rotate(180deg); transition: transform .2s; display: inline-flex; }
[dir="rtl"] .fold-chev { transform: none; }
.fold[open] .fold-chev { transform: rotate(270deg); }
.fold-body { padding: 0 16px 16px; }
.look-card { padding: 12px 14px; }
.look-row { display: flex; align-items: center; gap: 10px; }
.look-l { font-weight: 800; font-size: 14px; width: 62px; flex: none; }
.look-seg { flex: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.look-opt { position: relative; }
.look-opt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.look-opt span { display: flex; align-items: center; justify-content: center; gap: 5px; padding: 8px 4px; border-radius: 12px; border: 1.5px solid var(--line-strong); background: var(--surface); font-size: 13px; font-weight: 800; white-space: nowrap; }
.look-opt input:checked + span { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-deep); }
.look-opt input:focus-visible + span { outline: 3px solid var(--indigo); outline-offset: 2px; }
.look-sw { display: inline-flex; gap: 2px; padding: 3px; border-radius: 8px; border: 1px solid var(--line-strong); }
.look-sw em { width: 7px; height: 7px; border-radius: 50%; display: block; }
.look-sub { margin: 0; }
.prof-foot { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 4px 0 12px; text-align: center; }
/* start page: My courses / My practice topics, one row each with "All" */
.home-sec { gap: 8px; }
/* start page: My courses and My practice topics each sit on their own light panel, so the two areas read apart */
.home-sec { padding: 12px 12px 14px; border-radius: 22px; background: var(--accent-soft); background: color-mix(in srgb, var(--accent-soft) 28%, var(--bg)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent-soft) 70%, var(--line)); }
.home-sec + .home-sec { margin-top: 6px; }
.home-sec-h { padding: 0 2px 0 4px; }
.home-sec-h { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.home-sec-h .link { min-height: 32px; padding: 4px 0; font-size: 14px; }
.home-sec-h .link svg { transform: rotate(180deg); }
[dir="rtl"] .home-sec-h .link svg { transform: none; }
.home-pick { display: flex; align-items: center; gap: 12px; padding: 14px 16px; font: inherit; font-weight: 800; color: var(--ink); text-align: start; }
.home-pick > svg:last-child { transform: rotate(180deg); color: var(--muted); }

/* start page footer: small and quiet */
.home-foot { display: flex; flex-direction: column; align-items: center; gap: 3px; margin: 36px 0 8px; padding-top: 18px; border-top: 1px solid var(--line); text-align: center; font-size: 12px; color: var(--muted); }
.home-foot > :not(.home-foot-logo) { opacity: .75; }
.home-foot a { color: inherit; text-decoration: none; font-weight: 700; }
/* footer logo: bold brand · infinity in a theme gradient · light claim, one line */
.home-foot-logo { display: inline-flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 4px 7px; margin-bottom: 4px; color: var(--accent-deep); opacity: .85; font-family: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif; line-height: 1.1; }
.home-foot-brand { font-weight: 600; font-size: 15px; letter-spacing: 0; }
.home-foot-claim { font-weight: 300; font-size: 14.5px; letter-spacing: -.005em; }
.home-foot-inf { flex: none; display: block; width: 30px; height: 15px; }
.home-foot-inf .hf-s1 { stop-color: var(--accent-deep); }
.home-foot-inf .hf-s2 { stop-color: var(--accent); }
.home-foot-inf .hf-s3 { stop-color: #7dceff; stop-color: color-mix(in srgb, var(--accent) 45%, #7dceff); }
/* "All" next to the headings on the start page: a quiet pill in the theme colours, not a blue link */
.home-sec-h .link { min-height: 30px; padding: 4px 8px 4px 12px; border-radius: 999px; background: var(--surface); color: var(--muted); font-size: 13px; font-weight: 800; gap: 2px; box-shadow: inset 0 0 0 1px var(--line); }
.home-sec-h .link:hover, .home-sec-h .link:focus-visible { color: var(--ink); }

/* admin player detail: chapter dots, then the final test as one symbol */
.learn-dots { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.exam-mark { width: 18px; height: 18px; border-radius: 50%; display: inline-grid; place-items: center; flex: none; }
.exam-mark.none { border: 1.5px dashed var(--line-strong); color: var(--muted); }
.exam-mark.tried { background: var(--bad-soft, #ffe3e3); color: var(--bad-line, #d33); }
.exam-mark.passed { background: var(--gold); color: var(--gold-ink); }
/* feedback: scope switch in a round, done form in admin */
.bug-scope { margin-top: -4px; }
.fb-done { color: var(--good-ink, var(--muted)); display: inline-flex; gap: 4px; align-items: flex-start; }
.fb-done-form { background: var(--surface-2); border-radius: 14px; padding: 10px 12px; }

/* elastic edges: where the page or row scrolls, the phone's own bounce (contain = it stays inside, no chaining);
   where nothing scrolls, assets/elastic.js lets it follow the finger and spring back */
html.app-shell #app { overscroll-behavior-y: contain; }
.medals, .lk-tiles, .area-chips, .lk-cols, .atabs { overscroll-behavior-x: contain; }
.elastic-back, [data-mode="focus"] .elastic-back { transition: transform .45s cubic-bezier(.22, 1.25, .36, 1) !important; }
.set-sw { white-space: normal; }
/* one beat with names */
.lk-beatlabels { width: 100%; height: auto; display: block; }
.lk-beatlabels .bl-band { fill: var(--accent); opacity: .07; }
.lk-beatlabels .bl-wave { font: 800 1.15px 'Nunito', system-ui, sans-serif; fill: color-mix(in srgb, var(--accent) 45%, var(--ink)); text-anchor: middle; }
.lk-beatlabels .bl-qrs { font: 800 .95px 'Nunito', system-ui, sans-serif; fill: color-mix(in srgb, var(--accent) 45%, var(--ink)); text-anchor: middle; }
.lk-beatlabels .bl-seg { stroke: #1E9E55; stroke-width: .16; stroke-linecap: round; }
.lk-beatlabels .bl-seg-t { font: 800 .62px 'Nunito', system-ui, sans-serif; fill: #1E7A45; text-anchor: middle; }
.lk-beatlabels .bl-iv { fill: none; stroke: var(--muted); stroke-width: .18; }
.lk-beatlabels .bl-iv-t { font: 800 .85px 'Nunito', system-ui, sans-serif; fill: var(--muted); text-anchor: middle; }

/* ecgAnatomy: segments differ from waves (green line), intervals get a grey bracket */
.lk-band.seg { fill: #1E9E55; fill-opacity: .08; }
.lk-segline { stroke: #1E9E55; stroke-width: .3; stroke-linecap: round; }
.lk-band.iv { fill-opacity: .07; }
.lk-bracket.iv { stroke: var(--muted); stroke-width: .2; }

/* Workout area: tinted page, workout colour instead of the course blue, dumbbell next to the kicker */
:root.lab-mode { --bg: color-mix(in srgb, var(--indigo-soft) 55%, var(--surface)); --lab-line: color-mix(in srgb, var(--indigo) 28%, var(--indigo-soft)); }
:root.lab-mode .lab-tile, .lk-lab-mode .lk-chapter { border: 1.5px solid var(--lab-line, var(--indigo-soft)); }
.lk-lab-mode .lk-kicker { color: var(--indigo); display: inline-flex; align-items: center; gap: 6px; }
.lk-lab-mode .lk-kicker svg { width: 16px; height: 16px; flex: none; }
.lk-lab-mode .lk-prog span.on { background: var(--indigo); }
.lk-lab-mode .lk-course-hero { background: var(--indigo-soft); border-radius: 20px; padding: 14px; }
.lk-lab-mode .lk-course-ring { background: conic-gradient(var(--indigo) var(--p), var(--lk-surface-2) 0); }
.lk-lab-mode .lk-num { background: var(--indigo-soft); color: var(--indigo); }
.lk-lab-mode .lk-num.ring { background: conic-gradient(var(--indigo) var(--p), var(--track) 0); }
:root.lab-mode .lab-intro { background: var(--surface); border: 1.5px solid var(--lab-line); }

/* player top bar: the kicker stays on one line (… when too long), the card count sits at the end of the progress bar */
.lk-top-kicker { display: flex; align-items: center; gap: 6px; min-width: 0; letter-spacing: .05em; }
.lk-top-kicker svg { flex: none; }
.lk-top-kicker .kt { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lk-progrow { display: flex; align-items: center; gap: 10px; }
.lk-progrow .lk-prog { flex: 1; }
.lk-progrow .lk-count { flex: none; font-size: 12px; }
.lk-progrow .lk-count:empty { display: none; }

/* workout start page: small "Workout" label with dumbbell above the title */
.lk-lab-tag { display: inline-flex; align-items: center; gap: 6px; align-self: flex-start; margin-bottom: 4px; padding: 3px 10px 3px 8px; border-radius: 99px; background: var(--surface); color: var(--indigo); font-size: 12px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
.lk-lab-tag svg { width: 16px; height: 16px; flex: none; }

/* paperSpeed: one strip window, three speeds */
.lk-speed .lk-tile { width: 100%; }
.lk-speed-read { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; text-align: center; }
.lk-speed-read span { display: flex; flex-direction: column; background: var(--lk-surface-2); border-radius: 12px; padding: 6px 4px; }
.lk-speed-read small { font-size: 11.5px; color: var(--muted); font-weight: 700; }
.lk-speed-read b { font-size: 16px; font-weight: 900; font-variant-numeric: tabular-nums; }

/* beatPhases: heart + circle, two rows of leads, the strip, the parts, speed and paper */
.lk-bp .lk-heart-row { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); }
.lk-bp-dial .lk-dial { width: 100%; }
.lk-bp-dial [hidden] { display: none; }
.lk-bp-strip { position: relative; }
.lk-bp-strip .lk-tile-name { position: absolute; left: 8px; top: 4px; }
.lk-bp-ghost { opacity: .45; stroke-width: 2px; }
.lk-bp-hi { stroke-width: 3px; stroke: var(--ink); }
.lk-bp-strip .lk-band { fill-opacity: .09; }
.lk-bp-ctl { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.lk-bp-c { display: flex; flex-direction: column; gap: 4px; }
.lk-bp-c small { font-size: 11.5px; font-weight: 800; color: var(--muted); }
.lk-bp-c .lk-seg button { min-height: 34px; padding: 0 11px; font-size: 13px; }
.lk-bp-play { margin-left: auto; }

/* beatPhases heart: the part that plays is bright, earlier parts are grey */
.lk-bp .lk-heart .lk-flow { stroke-width: 5.5; }
.lk-bp .lk-heart .lk-flow.past { stroke: var(--muted); stroke-width: 3.2; opacity: .35 !important; }

.lk-bp-chip .lk-chip-n svg { width: 10px; height: 10px; margin-left: 1px; }

/* Admin → Notes (super admin): the two pages and the notes added in the app */
.nd-card > svg:first-child { color: var(--indigo); flex: none; }
.nd-doc { font-size: 14.5px; line-height: 1.5; overflow-wrap: anywhere; }
.nd-doc > :first-child { margin-top: 0; }
.nd .nd-h { margin: 16px 0 6px; line-height: 1.25; }
.nd h2.nd-h { font-size: 20px; } .nd h3.nd-h { font-size: 17px; } .nd h4.nd-h, .nd h5.nd-h { font-size: 15px; }
.nd-doc p { margin: 6px 0; }
.nd-doc ul, .nd-doc ol { margin: 6px 0; padding-left: 20px; }
.nd-doc li { margin: 3px 0; }
.nd-doc li.sub { margin-left: 18px; }
.nd-doc li.nd-check { list-style: none; margin-left: -20px; display: flex; gap: 8px; align-items: flex-start; }
.nd-doc li.nd-check.sub { margin-left: -2px; }
.nd-doc li.nd-check .box { flex: none; width: 18px; height: 18px; margin-top: 2px; border: 1.5px solid var(--line-strong); border-radius: 5px; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 900; color: var(--good-ink); }
.nd-doc li.nd-check.done .box { background: var(--good-soft); border-color: var(--good); }
.nd-doc code { font-size: 13px; background: var(--surface-2); border-radius: 5px; padding: 1px 5px; }
.nd-doc hr { border: 0; border-top: 1px solid var(--line); margin: 14px 0; }
.nd-back { align-self: flex-start; }
.nd-notes h2.nd-h { margin-top: 0; font-size: 18px; }
.nd-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.nd-list li { display: flex; gap: 10px; align-items: flex-start; padding: 10px; border-radius: 14px; background: var(--indigo-soft); }
.nd-list li.done { opacity: .55; }
.nd-list li.done .nd-text { text-decoration: line-through; }
.nd-tick { flex: none; width: 24px; height: 24px; border-radius: 7px; border: 1.5px solid var(--indigo); background: var(--surface); color: var(--indigo); font-weight: 900; cursor: pointer; padding: 0; }
.nd-list .grow { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.nd-tag { font-size: 11px; font-weight: 900; letter-spacing: .05em; text-transform: uppercase; color: var(--indigo); }
.nd-text { font-size: 14.5px; overflow-wrap: anywhere; }
.nd-notes textarea { width: 100%; box-sizing: border-box; font: inherit; font-size: 15px; padding: 10px 12px; border-radius: 12px; border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--ink); resize: vertical; }
.nd-doc li.nd-check .tx { flex: 1; min-width: 0; }

/* the sphere: frontal circle upright, horizontal circle as a tilted ellipse, all twelve leads */
.lk-sphere3 { width: 100%; max-width: 420px; height: auto; display: block; margin: 0 auto; }
.lk-sphere3 .sp-ball { fill: var(--indigo-soft); fill-opacity: .35; stroke: none; }
.lk-sphere3 .sp-front { fill: none; stroke: var(--indigo); stroke-width: 1.6; }
.lk-sphere3 .sp-floor { fill: var(--gold-soft); fill-opacity: .55; stroke: none; }
.lk-sphere3 .sp-hfront { fill: none; stroke: var(--gold-ink); stroke-width: 1.6; }
.lk-sphere3 .sp-hback { fill: none; stroke: var(--gold-ink); stroke-width: 1; stroke-dasharray: 4 3; opacity: .6; }
.lk-sphere3 .sp-lead line.pos { stroke: var(--muted); stroke-width: 1.4; opacity: .8; }
.lk-sphere3 .sp-lead line.neg { stroke: var(--lk-va); stroke-width: .9; opacity: .5; }
.lk-sphere3 .sp-lead .lead-line { stroke: var(--muted); stroke-width: .8; opacity: .55; }
.lk-sphere3 .sp-lead .dot { fill: var(--gold-ink); }
.lk-sphere3 .sp-lead .tag { fill: var(--surface); stroke: var(--line-strong); stroke-width: 1.2; }
.lk-sphere3 .sp-lead.f .tag { stroke: var(--indigo); }
.lk-sphere3 .sp-lead.h .tag { stroke: var(--gold-ink); }
.lk-sphere3 .sp-lead text { font: 800 11.5px 'Nunito', system-ui, sans-serif; fill: var(--ink); text-anchor: middle; dominant-baseline: central; }
.lk-sphere3 .sp-lead.on line.pos { stroke: var(--accent); stroke-width: 3; opacity: 1; }
.lk-sphere3 .sp-lead.on .tag { fill: var(--accent); stroke: var(--accent); }
.lk-sphere3 .sp-lead.on text { fill: var(--on-accent); }
.lk-sphere3 .sp-sh { stroke: #6E6E6E; stroke-width: 3; stroke-linecap: round; opacity: .45; }
.lk-sphere3 .sp-drop { stroke: var(--muted); stroke-width: .8; stroke-dasharray: 2 3; }
.lk-sphere3 .sp-trail { fill: none; stroke: var(--accent); stroke-width: 1.4; stroke-dasharray: 2 3; opacity: .75; }
.lk-sphere3 .sp-vec line { stroke: var(--accent); stroke-width: 5; stroke-linecap: round; }
.lk-sphere3 .sp-vec path { fill: var(--accent); }
.lk-sphere3 .sp-hub { fill: var(--ink); }

/* beatCamera12 */
.lk-cam-where { font-size: 13.5px; color: var(--muted); min-height: 1.2em; }
.lk-cam-where b { color: var(--ink); margin-right: 4px; }
/* the turnable sphere */
.lk-sphere-box { display: flex; flex-direction: column; gap: 4px; }
.lk-sphere-stage { touch-action: none; cursor: grab; user-select: none; -webkit-user-select: none; }
.lk-sphere-stage:active { cursor: grabbing; }
.lk-sphere-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 32px; }
.lk-sphere-hint { font-size: 12px; color: var(--muted); }
.lk-sphere-reset { font: inherit; font-size: 13px; font-weight: 800; color: var(--accent-ink); background: var(--surface); border: 1.5px solid var(--accent-soft); border-radius: 99px; padding: 5px 12px; cursor: pointer; }
.lk-sphere-reset[hidden] { display: none; }
.lk-sphere3 .sp-f-fill { fill: var(--indigo-soft); fill-opacity: .25; }
.lk-sphere3 .sp-f-line { fill: none; stroke: var(--indigo); stroke-width: 1.6; }
.lk-sphere3 .sp-f-back { fill: none; stroke: var(--indigo); stroke-width: 1; stroke-dasharray: 4 3; opacity: .55; }
.lk-sphere3 .sp-h-fill { fill: var(--gold-soft); fill-opacity: .55; }
.lk-sphere3 .sp-h-line { fill: none; stroke: var(--gold-ink); stroke-width: 1.6; }
.lk-sphere3 .sp-h-back { fill: none; stroke: var(--gold-ink); stroke-width: 1; stroke-dasharray: 4 3; opacity: .6; }
.lk-sphere3 .sp-ball { fill: none; stroke: var(--line-strong); stroke-width: 1; }
.lk-sphere3 .sp-lead.behind { opacity: .45; }
.lk-sphere3 .sp-lead { cursor: pointer; }
/* twelve small strips; the chosen lead spans the full row */
.lk-bp-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.lk-bp-mini { position: relative; padding: 0; border: 1.5px solid transparent; cursor: pointer; font: inherit; color: inherit; background: var(--surface); }
.lk-bp-mini.big { border-color: var(--line); cursor: default; }
.lk-bp-mini.on { border-color: var(--accent); }
.lk-bp-mini .lk-tile-name { position: absolute; left: 6px; top: 3px; font-size: 11px; }
.lk-bp-mini svg { display: block; width: 100%; height: auto; }
.lk-bp-grid .lk-bp-hi { stroke-width: 2px; }
.lk-bp-grid .lk-bp-ghost { stroke-width: 1.4px; }

/* 3D scene with circles instead of wall and floor */
.lk-3dc .c3-f { fill: var(--indigo-soft); fill-opacity: .55; stroke: var(--indigo); stroke-width: 1.4; }
.lk-3dc .c3-h { fill: var(--gold-soft); fill-opacity: .7; stroke: var(--gold-ink); stroke-width: 1.4; }
.lk-3dc .c3-pos { stroke: var(--muted); stroke-width: 1.1; opacity: .75; }
.lk-3dc .c3-pos.on { stroke: var(--ink); stroke-width: 2; opacity: 1; }
.lk-3dc .c3-neg { stroke: var(--lk-va); stroke-width: .8; opacity: .45; }
.lk-3dc .c3-lab { font: 800 9.5px 'Nunito', system-ui, sans-serif; fill: var(--muted); text-anchor: middle; dominant-baseline: central; }
.lk-3dc .c3-lab.on { fill: var(--ink); font-size: 11px; }
.lk-3dc-flat { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.lk-3dc-flat .lk-dial { width: 100%; }
.lk-sphere3 .sp-lead .ring { fill: var(--surface); stroke: var(--indigo); stroke-width: 1.6; }
.lk-sphere3 .sp-lead.on .ring { stroke: var(--accent); }

/* topic sheet: compact pop-up – Practise this at the top, the settings below in one card */
html.app-shell #app:has(> .overlay) { overflow: hidden; }
.topic-overlay { overscroll-behavior: contain; touch-action: none; }
.topic-overlay .sheet { touch-action: pan-y; }
.topic-overlay { background: rgba(20, 24, 26, .55); }
.topic-overlay.ts-in { animation: ts-fade .2s ease-out backwards; }
.topic-overlay .sheet.ts { max-height: 82vh; overflow-y: auto; overscroll-behavior: contain; }
.sheet.ts { position: relative; padding: 8px 16px calc(16px + env(safe-area-inset-bottom)); gap: 10px; box-shadow: 0 -8px 30px rgba(0, 0, 0, .18); will-change: transform; }
.ts-in .sheet.ts { animation: ts-up .25s cubic-bezier(.2, .8, .2, 1) backwards; }
@keyframes ts-up { from { transform: translateY(40px); opacity: .4; } to { transform: none; opacity: 1; } }
@keyframes ts-fade { from { opacity: 0; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .ts-in .sheet.ts, .topic-overlay.ts-in { animation: none; } }
.ts-grab { display: block; width: 36px; height: 4px; border-radius: 2px; background: var(--line-strong); margin: 0 auto 2px; }
.ts-head { display: flex; align-items: center; gap: 10px; }
.ts-title { font-size: 16px; font-weight: 800; line-height: 1.2; }
.ts-go { width: 100%; min-height: 46px; }
.ts-card { display: flex; flex-direction: column; gap: 10px; padding: 10px 12px; border-radius: 16px; background: var(--surface-2); }
.ts-onoff { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 16px; border: 2px solid var(--accent); background: var(--accent-soft); color: var(--accent-ink); }
.ts-onoff strong { font-size: 15px; }
.ts-onoff .tiny { opacity: .85; }
.ts-onoff.off { border-style: dashed; background: var(--surface); }
.ts-onoff.off .ts-sw { box-shadow: 0 0 0 3px var(--accent-soft); }
.ts-onoff.locked { border: 1.5px solid var(--line-strong); background: var(--surface-2); color: var(--ink); }
.ts-onoff.locked .tiny { color: var(--muted); opacity: 1; }
.ts-sec { display: flex; flex-direction: column; gap: 5px; transition: opacity .2s; }
.ts-sec .topic-label { margin-bottom: 0; font-size: 11.5px; }
.ts-off .ts-sec { opacity: .4; pointer-events: none; }
.ts-seg { gap: 0; padding: 3px; border-radius: 11px; background: var(--surface); }
.ts-seg .seg-btn { min-height: 32px; border: 0; background: transparent; color: var(--ink); border-radius: 8px; font-size: 13px; }
.ts-seg .seg-btn.on { background: var(--accent-soft); color: var(--accent-ink); font-weight: 800; }
.ts-seg .seg-btn:disabled { opacity: 1; cursor: default; }
.ts-levels { border-radius: 12px; overflow: hidden; background: var(--surface); }
.ts-lv { display: flex; align-items: center; gap: 10px; min-height: 40px; padding: 2px 10px; }
.ts-lv + .ts-lv { border-top: 1px solid var(--line); }
.ts-lv.soon { color: var(--muted); }
.ts-lv-name { width: 64px; flex: none; font-weight: 800; font-size: 13.5px; }
.ts-lv-bar { flex: 1; height: 5px; border-radius: 3px; background: var(--track); overflow: hidden; }
.ts-lv-bar > span { display: block; height: 100%; background: var(--accent); }
.ts-off .ts-lv-bar > span { background: var(--muted); }
.ts-lv-pct { width: 32px; text-align: end; font-weight: 700; color: var(--muted); }
.ts-lv-soon { flex: 1; }
.ts-lv-ready { flex: 1; white-space: nowrap; display: inline-flex; align-items: center; gap: 4px; font-weight: 800; color: var(--gold-ink); }
.ts-lv.ready { background: var(--gold-soft); animation: breathe 2.4s ease-in-out infinite; }
.ts-sw { position: relative; flex: none; width: 44px; height: 26px; padding: 0; border: 0; border-radius: 99px; background: var(--line-strong); cursor: pointer; transition: background .15s; }
.ts-sw > span { position: absolute; top: 3px; inset-inline-start: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: inset-inline-start .15s; }
.ts-sw[aria-checked="true"] { background: var(--accent); }
.ts-sw[aria-checked="true"] > span { inset-inline-start: 21px; }
.ts-off .ts-sw.s[aria-checked="true"] { background: var(--muted); }
.ts-sw.s { width: 38px; height: 22px; }
.ts-sw.s > span { width: 16px; height: 16px; top: 3px; }
.ts-sw.s[aria-checked="true"] > span { inset-inline-start: 19px; }
.ts-sw:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ts-lock { flex: none; width: 36px; height: 36px; border-radius: 50%; border: 0; background: var(--surface); color: var(--muted); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.ts-lock:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------------------------------------------------------------- AVEIR patient selection */
.lp-say { background: var(--accent-soft); border-radius: 18px; padding: 14px 16px; display: flex; flex-direction: column; gap: 6px; position: relative; }
.lp-say p { margin: 0; font-size: 16px; font-weight: 600; color: var(--ink); line-height: 1.35; }
.lp-say p b { color: var(--accent-ink); font-weight: 900; }
.lp-say p:first-of-type::before { content: '“'; color: var(--accent-ink); font-weight: 900; margin-right: 2px; }
.lp-say p:last-of-type::after { content: '”'; color: var(--accent-ink); font-weight: 900; margin-left: 1px; }
.lp-say-ask { display: inline-flex; gap: 7px; align-items: center; align-self: flex-start; margin-top: 6px; padding: 6px 12px 6px 10px; border-radius: 99px; background: var(--gold); color: #3d2e00; font-size: 13.5px; font-weight: 900; box-shadow: 0 3px 10px -4px rgba(92, 69, 0, .55); animation: lp-pop .45s cubic-bezier(.2, 1.6, .4, 1) .25s both; }
.lp-say-ask svg { flex-shrink: 0; width: 16px; height: 16px; }
@keyframes lp-pop { from { opacity: 0; transform: scale(.6); } }
@media (prefers-reduced-motion: reduce) { .lp-say-ask { animation: none; } }
:root[data-mode="focus"] .lp-say-ask { animation: none; }
.lp-fig svg { width: min(100%, 360px); }
.lp-body { fill: var(--lk-surface-2); stroke: var(--line-strong); stroke-width: 1.5; }
.lp-bone { fill: none; stroke: var(--line-strong); stroke-width: 4; stroke-linecap: round; }
.lp-vein { fill: none; stroke: var(--indigo-soft); stroke-width: 9; stroke-linecap: round; }
.lp-heart { fill: #f7c9cf; stroke: #e0183d; stroke-width: 1.5; }
:root[data-theme="dark"] .lp-heart { fill: #5c2a33; stroke: #ff5c77; }
.lp-ra, .lp-rv { fill: rgba(224, 24, 61, .14); stroke: rgba(224, 24, 61, .5); stroke-width: 1; }
.lp-tv-valve { stroke: rgba(224, 24, 61, .6); stroke-width: 2; stroke-dasharray: 2 2; }
.lp-pocket { fill: var(--gold-soft); stroke: var(--gold); stroke-width: 1.5; stroke-dasharray: 4 3; }
.lp-can { fill: var(--muted); stroke: var(--ink); stroke-width: 1; }
.lp-lead { fill: none; stroke: var(--ink); stroke-width: 2.4; stroke-linecap: round; }
.lp-cap { fill: var(--accent); stroke: var(--accent-deep); stroke-width: 1; }
.lp-i2i { fill: none; stroke: var(--accent); stroke-width: 2; stroke-dasharray: 3 4; animation: lp-flow 1.2s linear infinite; }
.lp-i2i-t { font-size: 12px; font-weight: 900; fill: var(--accent-ink); }
.lp-scar-free { fill: none; stroke: var(--good); stroke-width: 1.5; stroke-dasharray: 3 4; }
@keyframes lp-flow { to { stroke-dashoffset: -14; } }
.lp-spot { cursor: pointer; outline: none; }
.lp-spot circle { fill: var(--surface); stroke: var(--accent); stroke-width: 2.5; transition: fill .15s; }
.lp-spot text { font-size: 12px; font-weight: 900; fill: var(--accent-ink); text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.lp-spot.on circle, .lp-spot:focus-visible circle { fill: var(--accent); }
.lp-spot.on text, .lp-spot:focus-visible text { fill: var(--on-accent); }
.lk-infobox.lp-gone b { color: var(--good-ink); }
@media (prefers-reduced-motion: reduce) { .lp-i2i { animation: none; } }
:root[data-mode="focus"] .lp-i2i { animation: none; }

.ev-head { display: flex; flex-direction: column; gap: 4px; }
.ev-head strong { font-size: 16px; }
.ev-n { font-size: 13px; color: var(--muted); font-weight: 700; }
.ev-legend { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13px; font-weight: 800; color: var(--muted); }
.ev-key { width: 14px; height: 10px; border-radius: 3px; display: inline-block; margin-left: 4px; }
.ev-key.a, .ev-bar.a i { background: var(--accent); }
.ev-key.b, .ev-bar.b i { background: var(--line-strong); }
.ev-rows { display: flex; flex-direction: column; gap: 12px; }
.ev-row { display: flex; flex-direction: column; gap: 4px; }
.ev-cmp { display: grid; grid-template-columns: minmax(0, 1fr) 84px; gap: 12px; align-items: center; }
.ev-bars { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.ev-cmp .ev-rr { justify-self: stretch; text-align: center; padding: 8px 4px; border-radius: 14px; font-size: 17px; }
.ev-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.ev-l { font-weight: 800; font-size: 14px; }
.ev-rr { font-size: 13px; font-weight: 900; padding: 2px 10px; border-radius: 99px; background: var(--lk-surface-2); color: var(--muted); white-space: nowrap; }
.ev-rr.good { background: var(--good-soft); color: var(--good-ink); }
.ev-bar { display: flex; align-items: center; gap: 6px; height: 16px; }
.ev-bar i { max-width: calc(100% - 48px); }
.ev-bar i { display: block; height: 12px; width: 0; border-radius: 6px; transition: width .6s cubic-bezier(.2, .8, .2, 1); min-width: 3px; }
.ev-bar b { font-size: 12px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ev-hr { font-size: 12px; color: var(--muted); font-weight: 700; }

.sg-out { display: flex; flex-direction: column; gap: 10px; }
.sg-out:empty { display: none; }
.sg-bars { display: flex; flex-direction: column; gap: 6px; }
.sg-row { display: grid; grid-template-columns: minmax(84px, 34%) 1fr auto; gap: 8px; align-items: center; font-size: 13px; }
.sg-l { font-weight: 700; }
.sg-track { height: 12px; background: var(--lk-surface-2); border-radius: 6px; overflow: hidden; }
.sg-track i { display: block; height: 100%; width: 0; background: var(--line-strong); border-radius: 6px; transition: width .7s cubic-bezier(.2, .8, .2, 1); }
.sg-row.hi .sg-track i { background: var(--accent); }
.sg-row.hi .sg-l, .sg-row.hi b { color: var(--accent-ink); font-weight: 900; }
.sg-row b { font-variant-numeric: tabular-nums; }

.rb-rows { display: flex; flex-direction: column; gap: 14px; }
.rb-row { display: flex; flex-direction: column; gap: 5px; }
.rb-yr { font-size: 12px; font-weight: 800; color: var(--muted); white-space: nowrap; }
.rb-track { position: relative; height: 16px; background: var(--lk-surface-2); border-radius: 8px; overflow: hidden; }
.rb-track i { position: absolute; top: 0; bottom: 0; transition: width .25s, left .25s; }
.rb-lo { left: 0; border-radius: 8px 0 0 8px; }
.rb-a .rb-lo { background: var(--gold); } .rb-a .rb-hi { background: var(--gold-line); }
.rb-b .rb-lo { background: var(--bad-line); } .rb-b .rb-hi { background: var(--fb-bad-line); }
.rb-val { font-size: 15px; font-weight: 900; font-variant-numeric: tabular-nums; }
.rb-scale { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); font-weight: 700; }

.avs-out { display: flex; flex-direction: column; gap: 12px; }
.avs-sys { display: flex; flex-direction: column; gap: 6px; background: var(--lk-surface-2); border-radius: 16px; padding: 10px 12px; }
.avs-sys.a .lk-big { color: var(--accent-ink); }
.avs-beats { display: grid; grid-template-columns: repeat(10, 1fr); gap: 3px; }
.avs-beats i { display: block; border-radius: 6px; padding: 2px 0; animation: avs-in .35s both; animation-delay: calc(var(--i) * 45ms); }
.avs-beats svg { width: 100%; height: 22px; display: block; }
.avs-beats path { fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.avs-beats .on { background: var(--surface); }
.avs-beats .on .p { stroke: var(--indigo); } .avs-beats .on .q { stroke: var(--accent); }
.avs-beats .off .p { stroke: var(--line-strong); } .avs-beats .off .q { stroke: var(--line-strong); stroke-dasharray: 2 2; }
@keyframes avs-in { from { opacity: 0; transform: scale(.6); } }
@media (prefers-reduced-motion: reduce) { .avs-beats i { animation: none; } }

.gm-board { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.gm-g { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 58px; padding: 6px 4px; border-radius: 14px; background: var(--lk-surface-2); color: var(--muted); font-size: 12px; font-weight: 800; text-align: center; border: 2px solid transparent; transition: background .2s, color .2s, transform .2s; line-height: 1.2; }
.gm-g b { font-size: 18px; font-weight: 900; line-height: 1; }
.gm-g.on { background: var(--accent); color: var(--on-accent); transform: scale(1.03); }
button.gm-g { cursor: pointer; font-family: inherit; }
.gm-g.pick { background: var(--surface); border-color: var(--line-strong); color: var(--ink); }
.gm-g.pick.on { background: var(--accent); border-color: var(--accent); color: var(--on-accent); transform: none; }
.gm-g.right { background: var(--good-soft); border-color: var(--good); color: var(--good-ink); }
.gm-g.miss { background: var(--gold-soft); border-color: var(--gold); color: var(--gold-ink); }
.gm-g.wrong { background: var(--bad-soft); border-color: var(--bad-line); color: var(--bad); }
.gm-g.off { opacity: .55; }
.gm-meter { display: flex; flex-direction: column; gap: 6px; }
.gm-meter strong { font-size: 14px; }
.gm-meter-bar { height: 10px; background: var(--lk-surface-2); border-radius: 5px; overflow: hidden; }
.gm-meter-bar i { display: block; height: 100%; background: var(--accent); border-radius: 5px; transition: width .35s; }
.gm-groups { display: flex; flex-direction: column; gap: 10px; }
.gm-grp .lk-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.gm-grp .lk-chip { min-height: 34px; font-size: 13px; padding: 0 12px; }
.gm-gamehead { display: flex; justify-content: space-between; align-items: center; }
.gm-score { font-weight: 900; font-size: 14px; padding: 3px 10px; border-radius: 99px; background: var(--gold-soft); color: var(--gold-ink); }
.gm-factor { background: var(--accent-soft); border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.gm-factor strong { font-size: 18px; }
.gm-stars { font-size: 28px; color: var(--gold); letter-spacing: 4px; }
.gm-top { display: flex; flex-direction: column; gap: 4px; }
.gm-trow { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 12px; border: 1.5px solid transparent; background: var(--lk-surface-2); color: var(--ink); font: inherit; font-size: 13px; text-align: left; cursor: pointer; }
.gm-trow.on { border-color: var(--accent); }
.gm-tl { font-weight: 700; }
.gm-dots { display: flex; gap: 3px; }
.gm-dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--surface); border: 1px solid var(--line-strong); }
.gm-dots i.on { background: var(--accent); border-color: var(--accent); }
.gm-trow b { font-variant-numeric: tabular-nums; min-width: 26px; text-align: right; }

.lt-line svg { width: 100%; max-width: 420px; }
.lt-track { fill: var(--lk-surface-2); }
.lt-fill { fill: var(--accent); opacity: .55; }
.lt-batt { fill: none; stroke: var(--good); stroke-width: 2; stroke-dasharray: 3 2; }
.lt-mark { stroke: var(--gold); stroke-width: 2.5; }
.lt-dot { fill: var(--accent); stroke: var(--surface); stroke-width: 3; }
.lt-lab { font-size: 11px; font-weight: 800; fill: var(--muted); }
.lt-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.lt-tile { background: var(--lk-surface-2); border-radius: 14px; padding: 8px; display: flex; flex-direction: column; gap: 2px; font-size: 12px; min-width: 0; }
.lt-tile .lk-kicker { font-size: 10px; }
.lt-tile .lk-big { font-size: 18px; }
.lt-tile.good { background: var(--good-soft); }
@media (max-width: 420px) { .lt-tiles { grid-template-columns: 1fr; } }

.pw-rows { display: flex; flex-direction: column; gap: 14px; }
.pw-track { display: flex; flex-direction: column; gap: 5px; }
.pw-end { font-size: 12px; font-weight: 800; color: var(--muted); white-space: nowrap; }
.pw-bar { position: relative; height: 14px; background: var(--lk-surface-2); border-radius: 7px; }
.pw-bar > i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 7px; background: var(--line-strong); transition: width .2s; }
.pw-track.a .pw-bar > i { background: var(--accent); }
.pw-track.b .pw-bar > i { background: var(--gold); }
.pw-mark { position: absolute; top: -3px; width: 4px; height: 20px; margin-left: -2px; border-radius: 2px; background: var(--line-strong); }
.pw-mark.on { background: var(--ink); }
.pw-endmark { position: absolute; top: -5px; width: 2px; height: 24px; margin-left: -1px; background: var(--good); }
.pw-now { font-size: 14px; min-height: 2.6em; }
.pw-track.home .pw-now { color: var(--good-ink); font-weight: 800; }

.cq-card { background: var(--lk-surface-2); border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.cq-card strong { font-size: 17px; }
.cq-facts { display: flex; flex-wrap: wrap; gap: 6px; }
.cq-facts span { background: var(--surface); border-radius: 99px; padding: 4px 10px; font-size: 13px; font-weight: 700; }
.cq-focus { display: block; margin-top: 6px; font-size: 13px; font-weight: 800; color: var(--accent-ink); }
.gm-sticky { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 54px); z-index: 3; background: var(--surface); margin: -4px -14px 0; padding: 4px 14px 10px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 8px 10px -10px rgba(0, 0, 0, .25); }
.gm-sticky .gm-g { min-height: 46px; }

/* course description: short intro line + points */
.lk-desc { display: flex; flex-direction: column; gap: 6px; color: var(--muted); font-size: 14px; }
.lk-desc p { margin: 0; }
.lk-desc-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 4px; }
.lk-desc-list li { position: relative; padding-left: 16px; }
.lk-desc-list li::before { content: ''; position: absolute; left: 3px; top: .55em; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.lk-desc-list b { color: var(--ink); }
.lk-flip-back.big { font-size: 15.5px; justify-content: center; line-height: 1.35; font-weight: 500; }
.lk-flip-back.big b { font-weight: 900; color: var(--accent-deep); }

/* conversation box: key words first, then the sentence */
.lp-say .lp-key { color: var(--accent-ink); font-weight: 900; }
.lp-say.anim .lp-key { display: inline-block; animation: lp-key .5s cubic-bezier(.2, 1.5, .4, 1) both; animation-delay: calc(.2s + var(--k) * .35s); }
.lp-say.anim .lp-rest { animation: lp-rest .6s ease-out both; animation-delay: calc(.35s + var(--n) * .35s); }
.lp-say.anim .lp-say-ask { animation-delay: calc(.8s + var(--n) * .35s); }
.lp-say.anim p::before, .lp-say.anim p::after { animation: lp-rest .6s ease-out both; animation-delay: calc(.35s + var(--n) * .35s); }
@keyframes lp-key { 0% { opacity: 0; transform: scale(1.6) translateY(-6px); } 60% { opacity: 1; background: var(--gold-soft); border-radius: 6px; } 100% { background: transparent; } }
@keyframes lp-rest { from { opacity: 0; } }
/* list with a sign per line */
.lp-checks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.lp-checks li { display: flex; gap: 10px; align-items: flex-start; background: var(--surface); border-radius: 14px; padding: 10px 12px; font-size: 15px; line-height: 1.35; }
.lp-ck { flex: none; width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 900; margin-top: 1px; }
.lp-checks .ok .lp-ck { background: var(--good-soft); color: var(--good-ink); border: 1.5px solid var(--good); }
.lp-checks .warn .lp-ck { background: var(--gold-soft); color: var(--gold-ink); border: 1.5px solid var(--gold); }
.lp-checks .info .lp-ck { background: var(--accent-soft); color: var(--accent-ink); }
.ev-cmp .ev-rr:not(.good) { font-size: 12.5px; white-space: normal; line-height: 1.2; }
/* course files (private PDFs) */
.lk-files { display: flex; flex-direction: column; gap: 8px; }
.lk-files.in-card { margin-top: 2px; }
.lk-file { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 18px; background: var(--surface); color: var(--ink); text-decoration: none; font-weight: 400; border: 1.5px solid var(--line); }
.lk-file:active { transform: scale(.99); }
@media (hover: hover) and (pointer: fine) { .lk-file:hover { border-color: var(--accent); } }
.lk-file-ic { flex: none; width: 42px; height: 42px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--bad-soft); color: var(--bad-line); }
.lk-file-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.lk-file-main strong { font-size: 15px; }
.lk-file-main small { font-size: 12px; color: var(--muted); font-weight: 700; }
.lk-file > svg:last-child { color: var(--muted); flex: none; }
.cf-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.cf-list li { gap: 10px; padding: 8px 10px; border-radius: 12px; background: var(--surface-2); }
/* round 3: light lines between evidence rows, values per quiz answer, calm vertical risk chart, 100 people */
.ev-row + .ev-row { border-top: 1px solid var(--line); padding-top: 10px; }
.lk-opt-v { display: block; margin-top: 4px; font-size: 13px; font-weight: 900; color: var(--muted); }
.lk-opt.right .lk-opt-v { color: var(--good-ink); }
.lk-practice.done { background: var(--indigo-soft); }
.rb-chart { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: end; }
.rb-scale-v { height: 150px; display: flex; flex-direction: column; justify-content: space-between; font-size: 11px; font-weight: 700; color: var(--muted); align-self: end; margin-bottom: 66px; text-align: right; }
.rb-col { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; min-width: 0; }
.rb-col .rb-val { font-size: 15px; font-weight: 900; font-variant-numeric: tabular-nums; white-space: nowrap; }
.rb-vtrack { position: relative; width: 56px; height: 150px; background: var(--lk-surface-2); border-radius: 12px; overflow: hidden; }
.rb-vtrack i { position: absolute; left: 0; right: 0; bottom: 0; border-radius: 0; transition: height .25s; }
.rb-a .rb-hi { background: var(--accent-soft); } .rb-a .rb-lo { background: var(--accent); }
.rb-b .rb-hi { background: var(--line-strong); opacity: .55; } .rb-b .rb-lo { background: var(--muted); }
.rb-a .rb-val { color: var(--accent-ink); }
.rb-name { font-size: 13px; font-weight: 800; line-height: 1.25; min-height: 2.5em; }
.rb-col .rb-yr { font-size: 11px; font-weight: 700; color: var(--muted); white-space: nowrap; }
.rb-years .lk-big { font-size: 20px; }
.sg-people svg { width: 100%; height: auto; display: block; }
.sg-people .pp { fill: var(--line-strong); transition: fill .15s; }
.sg-people .pp.g { fill: var(--bad-line); }
.sg-people .pp.a { fill: var(--accent); }
.sg-people .pp.miss { fill: var(--bad-line); } .sg-people .pp.over { fill: var(--bad-line); }
.sg-key { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 6px; font-size: 12px; font-weight: 800; color: var(--muted); }
.sg-key i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; margin-left: 6px; }
.sg-key i.a { background: var(--accent); } .sg-key i.miss { background: var(--bad-line); } .sg-key i.over { background: var(--bad-line); }

.gm-g small { font-size: 10px; font-weight: 800; opacity: .85; margin-top: -2px; text-transform: uppercase; letter-spacing: .04em; }
.gm-cap { font-size: 12px; font-weight: 700; color: var(--muted); margin-top: -4px; }
/* chapter list: the number always stays in the circle; done / progress / locked sit small below it */
.lk-num-col { display: flex; flex-direction: column; align-items: center; gap: 3px; flex-shrink: 0; width: 40px; }
.lk-num-col .lk-num.ring > span { font-size: 15px; }
.lk-num-sub { min-height: 14px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 900; color: var(--accent-ink); font-variant-numeric: tabular-nums; }
.lk-num-sub svg { width: 14px; height: 14px; }
.lk-chapter.done .lk-num-sub { color: var(--good-ink); }
.lk-chapter.locked .lk-num-sub { color: var(--muted); }
.lk-lab-mode .lk-num-sub { color: var(--indigo); }
.sg-diff { display: block; margin-top: 4px; font-weight: 800; }
/* simple value bars (e.g. savings in a cost model) */
.lp-bars { display: flex; flex-direction: column; gap: 12px; background: var(--surface); border-radius: 18px; padding: 14px; }
.lp-bar-row { display: flex; flex-direction: column; gap: 4px; }
.lp-bar-top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.lp-bar-top b { font-size: 14px; }
.lp-bar-top strong { font-size: 18px; font-weight: 900; font-variant-numeric: tabular-nums; white-space: nowrap; color: var(--good-ink); }
.lp-bar-track { height: 14px; background: var(--lk-surface-2); border-radius: 7px; overflow: hidden; }
.lp-bar-track i { display: block; height: 100%; width: 0; border-radius: 7px; background: var(--good); transition: width .7s cubic-bezier(.2, .8, .2, 1); }
.lp-bar-row small { font-size: 12.5px; color: var(--muted); font-weight: 700; }
/* lifetime slider with marks on it, schematic cost bars */
.lt-slider { position: relative; }
.lt-marks { position: relative; height: 0; }
.lt-marks .lt-batt { position: absolute; top: 4px; height: 26px; border: 2px dashed var(--good); border-radius: 8px; background: color-mix(in srgb, var(--good) 12%, transparent); pointer-events: none; }
.lt-marks .lt-be { position: absolute; top: 2px; height: 30px; width: 0; border-left: 3px solid var(--gold); pointer-events: none; }
.lt-marks .lt-be b { position: absolute; top: -16px; left: 0; transform: translateX(-50%); font-size: 11px; font-weight: 900; color: var(--gold-ink); white-space: nowrap; }
.lt-slider .lk-range-head { margin-bottom: 14px; }
.lt-scale { position: relative; height: 16px; font-size: 11px; font-weight: 800; color: var(--muted); }
.lt-scale span { position: absolute; top: 0; transform: translateX(-50%); white-space: nowrap; }
.lt-scale span.b { color: var(--good-ink); }
.lt-cost { display: flex; flex-direction: column; gap: 6px; background: var(--lk-surface-2); border-radius: 16px; padding: 12px; }
.lt-crow { display: grid; grid-template-columns: 104px 1fr; white-space: nowrap; gap: 8px; align-items: center; font-size: 13px; font-weight: 800; }
.lt-ctrack { position: relative; height: 16px; background: var(--surface); border-radius: 8px; overflow: hidden; }
.lt-ctrack i { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 8px; transition: width .2s; }
.lt-crow.t i { background: var(--line-strong); }
.lt-crow.a i { background: var(--accent); }
.lt-ctrack em { position: absolute; top: 0; bottom: 0; background: repeating-linear-gradient(45deg, rgba(255,255,255,.55) 0 3px, transparent 3px 6px); }
.lt-vrow { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 2px; }
.lt-verdict { font-size: 14px; white-space: nowrap; padding: 5px 12px; border-radius: 99px; }
.lt-verdict.more { background: var(--gold-soft); color: var(--gold-ink); }
.lt-verdict.even { background: var(--surface); color: var(--muted); border: 1.5px solid var(--line-strong); }
.lt-verdict.less { background: var(--good-soft); color: var(--good-ink); }
.lt-stepnote { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 800; color: var(--muted); white-space: nowrap; }
.lt-stepnote i { width: 14px; height: 10px; border-radius: 3px; background: var(--accent) repeating-linear-gradient(45deg, rgba(255,255,255,.55) 0 3px, transparent 3px 6px); }
.lt-tiles.two { grid-template-columns: 1fr 1fr; }
@media (max-width: 420px) { .lt-tiles.two { grid-template-columns: 1fr 1fr; } }
/* cards with several rounds: header with dots and a Next button at the top */
.rq-head { display: flex; align-items: center; gap: 10px; }
.rq-dots { flex: 1; display: flex; gap: 5px; align-items: center; min-width: 0; }
.rq-dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--line-strong); }
.rq-dots i.done { background: var(--accent); }
.rq-dots i.now { background: var(--surface); box-shadow: 0 0 0 2px var(--accent); }
.rq-next { display: inline-flex; align-items: center; gap: 2px; min-height: 36px; padding: 0 8px 0 14px; border-radius: 99px; border: 0; font: inherit; font-size: 14px; font-weight: 900; background: var(--lk-surface-2); color: var(--muted); cursor: pointer; }
.rq-next svg { width: 18px; height: 18px; }
.rq-next:disabled { opacity: .55; cursor: default; }
.rq-next.ready { background: var(--accent); color: var(--on-accent); animation: rq-pulse 1.4s ease-in-out 2; }
@keyframes rq-pulse { 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent) 25%, transparent); } }
@media (prefers-reduced-motion: reduce) { .rq-next.ready { animation: none; } }
:root[data-mode="focus"] .rq-next.ready { animation: none; }
.gm-panel .gm-score { align-self: flex-start; }
.lt-marks .lt-tv { position: absolute; top: 9px; height: 16px; width: 0; border-left: 2px dotted var(--muted); pointer-events: none; }
.lt-crow.t .lt-ctrack em { background: repeating-linear-gradient(45deg, rgba(0,0,0,.18) 0 3px, transparent 3px 6px); }
/* admin notes: voice test – compare AI voices with the device voice */
.vl .nd-h { display: flex; align-items: center; gap: 8px; }
.vl-seg { margin-top: 2px; }
.vl textarea { font-size: 14px; line-height: 1.45; }
.vl-row { display: flex; align-items: center; gap: 12px; padding: 12px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--surface); }
.vl-row.on { border-color: var(--accent); background: var(--accent-soft); }
.vl-ctl { gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.vl-ctl select { flex: 1 1 130px; min-width: 0; }
.vl-play { flex: none; width: 48px; height: 48px; border-radius: 50%; border: 0; background: var(--accent); color: #fff; display: grid; place-items: center; cursor: pointer; }
.vl-play:disabled { opacity: .35; cursor: not-allowed; }
.vl-play .spinner, .vl .spinner.small { width: 20px; height: 20px; border-width: 3px; }
.vl-row.on .vl-play .spinner { border-color: rgba(255,255,255,.35); border-top-color: #fff; }
.vl-miss { color: var(--gold-ink); }
.vl-err { color: var(--danger, #c0392b); }
/* course audio (admin): chapters × voices, clone settings, progress */
.au-langs { display: flex; gap: 8px; flex-wrap: wrap; }
.au-langs .seg-btn { padding: 0 14px; }
.au-clone { gap: 10px; padding: 10px 12px; border-radius: 14px; background: var(--surface-2); }
.au-clone select { width: 100%; }
.au-warn, .au-err { color: var(--gold-ink); }
.au-msg { margin: 0; padding: 8px 12px; border-radius: 12px; background: var(--good-soft); color: var(--good-ink); }
.au-run { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; background: var(--accent-soft); }
.au-run .spinner { width: 22px; height: 22px; border-width: 3px; flex: none; }
.au-head { display: flex; align-items: center; gap: 4px; padding: 0 10px; font-size: 12px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.au-col { flex: none; width: 54px; text-align: center; }
.au-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.au-list > li { border: 1.5px solid var(--line); border-radius: 14px; background: var(--surface); }
.au-list > li.open { border-color: var(--accent); }
.au-ch { display: flex; align-items: center; gap: 4px; width: 100%; min-height: 48px; padding: 6px 10px; border: 0; background: none; color: inherit; font: inherit; text-align: start; cursor: pointer; }
.au-title { font-weight: 700; font-size: 14px; line-height: 1.3; min-width: 0; }
.au-chip { display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 26px; padding: 0 8px; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: 13px; font-weight: 800; }
.au-chip.ok { background: var(--good-soft); color: var(--good-ink); }
.au-chip.warn { background: var(--gold-soft); color: var(--gold-ink); }
.au-detail { padding: 4px 10px 12px; }
.au-vrow { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.au-text { margin: 0; padding-inline-start: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; max-height: 360px; overflow: auto; }
.au-text li { display: flex; flex-direction: column; gap: 2px; padding: 8px 10px; border-radius: 10px; background: var(--surface-2); }
.au-costs ul { list-style: none; margin: 8px 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.au-badge { display: block; margin-top: 4px; font-weight: 700; }
.au-badge.ok { color: var(--good-ink); }
.au-badge.warn { color: var(--gold-ink); }
/* settings: read-aloud voice choice and speed */
.vc-opt { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 52px; padding: 6px 12px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface); color: inherit; font: inherit; text-align: start; cursor: pointer; }
.vc-opt.on { border-color: var(--accent); background: var(--accent-soft); }
.vc-dot { flex: none; width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--line-strong); box-sizing: border-box; }
.vc-opt.on .vc-dot { border: 6px solid var(--accent); }
.vc-speed { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.vc-device { margin-top: 8px; }
/* chapter player: small "AI voice · Clone ▾" button next to the speaker (opens the voice and speed menu), and a waiting state */
.lk-ai { align-self: center; flex-shrink: 1; min-width: 0; max-width: 24vw; overflow: hidden; text-overflow: ellipsis; font: inherit; font-size: 11px; font-weight: 800; color: var(--muted); padding: 6px 8px; min-height: 32px; border: 0; border-radius: 9px; background: var(--surface-2); white-space: nowrap; cursor: pointer; }
.lk-ai.on { color: var(--accent-ink); background: var(--accent-soft); }
.lk-vm { position: fixed; inset: 0; z-index: 60; display: flex; flex-direction: column; justify-content: flex-end; }
.lk-vm-back { position: absolute; inset: 0; background: var(--overlay); }
.lk-vm-sheet { position: relative; background: var(--surface); color: var(--ink); border-radius: 26px 26px 0 0; padding: 8px 18px calc(20px + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 10px; max-width: 560px; width: 100%; margin: 0 auto; box-sizing: border-box; box-shadow: 0 -10px 30px rgba(0, 0, 0, .15); animation: lkVmUp .22s ease-out; }
@keyframes lkVmUp { from { transform: translateY(30px); opacity: .4; } to { transform: none; opacity: 1; } }
.lk-vm-grab { align-self: center; width: 38px; height: 5px; border-radius: 3px; background: var(--line); margin-bottom: 2px; }
.lk-vm-head { display: flex; align-items: center; gap: 12px; }
.lk-vm-hicon { flex: none; width: 42px; height: 42px; border-radius: 14px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-ink); }
.lk-vm-htx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.lk-vm-htx b { font-size: 17px; }
.lk-vm-htx small { color: var(--muted); font-size: 13px; font-weight: 700; display: flex; align-items: center; gap: 6px; }
.lk-vm-flag { font-size: 16px; line-height: 1; }
.lk-vm-info { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; background: var(--surface-2); font-size: 13px; line-height: 1.4; }
.lk-vm-flags { flex: none; display: inline-flex; align-items: center; gap: 4px; font-size: 20px; line-height: 1; }
.lk-vm-flags i { font-style: normal; font-size: 13px; color: var(--muted); }
[dir="rtl"] .lk-vm-flags i { transform: scaleX(-1); }
.lk-vm-lbl { color: var(--muted); font-size: 11.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; margin-top: 2px; }
.lk-vm-list { display: flex; flex-direction: column; gap: 8px; }
.lk-vm-opt { display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 8px 12px; border-radius: 16px; border: 1.5px solid var(--line); background: var(--surface); color: inherit; font: inherit; text-align: start; cursor: pointer; transition: border-color .15s, background .15s; }
.lk-vm-opt.on { border-color: var(--accent); background: var(--accent-soft); }
.lk-vm-av { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 17px; color: #fff; background: linear-gradient(135deg, var(--accent), var(--accent-deep, var(--accent))); }
.lk-vm-av.marin { background: linear-gradient(135deg, #e0679a, #a03f86); }
.lk-vm-av.cedar { background: linear-gradient(135deg, #3f8fd6, #2c4f9e); }
.lk-vm-av.dev { background: var(--surface-2); color: var(--muted); }
.lk-vm-tx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.lk-vm-tx small, .lk-vm-note { color: var(--muted); font-size: 12.5px; }
.lk-vm-check { flex: none; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--line); color: transparent; box-sizing: border-box; }
.lk-vm-opt.on .lk-vm-check { background: var(--accent); border-color: var(--accent); color: #fff; }
.lk-vm-speedrow { display: flex; align-items: center; gap: 8px; }
.lk-vm-pace { flex: none; display: grid; place-items: center; color: var(--muted); }
.lk-vm-speed { flex: 1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 2px; padding: 3px; border-radius: 14px; background: var(--surface-2); }
.lk-vm-sp { min-height: 40px; border-radius: 11px; border: 0; background: transparent; color: var(--muted); font: inherit; font-weight: 800; cursor: pointer; direction: ltr; }
.lk-vm-sp.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 4px rgba(0, 0, 0, .12); }
.lk-vm-note { text-align: center; }
.au-course { padding: 14px; border-radius: 16px; background: var(--surface-2); }
.au-course .au-vrow { border-top-color: var(--line-strong); }
.au-sec { display: block; font-size: 16px; margin-top: 6px; }
.au-course .au-vrow:first-of-type { border-top: 0; }
.au-allv { align-self: stretch; }
.lk-speak.loading { animation: lk-pulse 1s ease-in-out infinite; }
@keyframes lk-pulse { 50% { opacity: .45; } }
.au-vrow .btn { white-space: nowrap; flex: none; }
.au-ov { display: flex; flex-direction: column; gap: 4px; }
.au-ov-head { display: flex; align-items: center; gap: 4px; padding: 0 10px; font-size: 12px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.au-ov-row { display: flex; align-items: center; gap: 4px; width: 100%; min-height: 44px; padding: 4px 10px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--surface); color: inherit; font: inherit; text-align: start; cursor: pointer; }
.au-ov-row.on { border-color: var(--accent); background: var(--accent-soft); }
.au-ov-row.off { opacity: .55; cursor: default; }
.au-ov-name { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14px; min-width: 0; }
.au-ov-flag { font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif; font-size: 18px; }
.au-ov-tr { flex: none; width: 84px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: center; font-size: 12px; font-weight: 800; color: var(--good-ink); }
.au-ov-row.off .au-ov-tr { color: var(--muted); font-weight: 700; }
.au-ov-tr.part { color: var(--gold-ink); }
.au-ov-head .au-ov-tr { color: var(--muted); letter-spacing: 0; font-size: 10px; }
.au-ov-head { gap: 8px; }
@media (max-width: 400px) { .au-ov .au-col { width: 46px; } }
.au-ov-miss { flex: none; font-size: 12px; font-weight: 700; color: var(--muted); }
.au-lang { font-weight: 700; color: var(--accent-ink); white-space: nowrap; }
/* a long confirm button goes onto its own line instead of squeezing the text next to it */
.au-vrow { flex-wrap: wrap; }
.au-vrow > .grow { min-width: 150px; }
.au-vrow .btn.primary { flex: 1 1 100%; white-space: normal; }

/* globe sheet: languages as a compact grid of flags with the name underneath */
.lang-sheet { max-width: 460px; }
.lang-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); gap: 8px; }
.lang-tile { font: inherit; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 4px 8px; border-radius: 14px; border: 1.5px solid var(--line, var(--surface-2)); background: var(--surface); color: var(--ink); cursor: pointer; min-width: 0; }
.lang-tile-flag { font-size: 28px; line-height: 1; }
.lang-tile-name { font-size: 12.5px; font-weight: 700; line-height: 1.2; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lang-tile.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-deep); }

/* chapter player: the speaker and voice tag sit close together, so the title keeps the room */

/* admin course detail: title above the folded sections */
.cd-head { padding: 2px 4px 4px; }

/* admin course download: one row per language with .json / Offline / Excel */
.cx-langs { display: flex; flex-direction: column; gap: 6px; }
.cx-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; padding: 6px 0; border-top: 1px solid var(--line); }
.cx-row:first-child { border-top: 0; }
.cx-name { font-weight: 800; display: inline-flex; align-items: center; gap: 6px; }
.cx-btns { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.cx-btns .btn { padding-inline: 10px; }
.cx-st { height: 22px; font-size: 11.5px; margin-inline-start: 4px; }

/* course language: flag in the chapter top bar, flags under the progress ring on the course page */
.lk-setbtn { color: var(--ink); }
.lk-setbtn.flag { font-size: 20px; line-height: 1; }
.lk-top .lk-setbtn + .lk-speak { margin-inline-start: -4px; }
.lk-vm-langs { display: flex; flex-wrap: wrap; gap: 6px; }
.lk-vm-lang { font: inherit; font-size: 13px; font-weight: 800; display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px 6px 8px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; }
.lk-vm-lang span { font-size: 18px; line-height: 1; }
.lk-vm-lang.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-ink); }
.lk-vm-note.lk-vm-note-l { text-align: start; margin-top: -2px; }
.lk-vm-hflag { font-size: 24px; background: var(--surface-2); }
.lk-vm-av.lk-vm-fl { background: var(--surface-2); font-size: 22px; }
.lk-course-side { display: flex; flex-direction: column; align-items: center; gap: 10px; flex-shrink: 0; }
.cl-langs { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 4px; max-width: 80px; color: var(--muted); }
.cl-ic { width: 100%; display: flex; justify-content: center; }
.cl-flag { font-size: 18px; line-height: 1; width: 32px; height: 28px; padding: 0; border-radius: 8px; border: 1.5px solid transparent; background: var(--surface); cursor: pointer; opacity: .75; }
.cl-flag.on { border-color: var(--accent); background: var(--accent-soft); opacity: 1; }

/* continuous reading: the speaker stays highlighted between cards */
.lk-speak.auto { color: var(--accent-ink); background: var(--accent-soft); box-shadow: 0 0 0 2px var(--accent) inset; }

/* course tile: flag when the course is read in another language than the app */
.tile-lang { position: absolute; top: 6px; right: 6px; width: 18px; height: 18px; border-radius: 50%; background: var(--surface-2); display: inline-flex; align-items: center; justify-content: center; font-size: 10px; line-height: 1; overflow: hidden; z-index: 1; }
.has-area .tile-lang { top: 22px; }
.lab-tile { position: relative; }
.cl-reset-row { display: block; margin-top: 2px; }
/* sign-in: language tiles */
.lang-grid-signin { margin-top: 6px; }
/* admin / player view toggle next to the help button */
.pv-btn { width: 30px; height: 30px; border-radius: 50%; border: 0; background: transparent; color: var(--muted); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; padding: 0; margin-inline-start: 2px; }
.pv-btn.on { color: var(--accent-ink); background: var(--accent-soft); }
.lang-hint { margin: 2px 2px 0; line-height: 1.4; }

/* speaker: always the speaker icon – white when idle or paused; while reading a very light grey circle, a slow soft ring from its edge and a gently breathing icon */
.lk-speak { position: relative; overflow: visible; z-index: 0; }
.lk-speak.on, .lk-speak.auto { color: var(--ink); background: var(--surface); box-shadow: none; }
.lk-speak.paused { color: var(--ink); background: var(--surface); }
.lk-speak.talking::after { content: ''; position: absolute; inset: 0; border-radius: 50%; border: 1.5px solid var(--line-strong, var(--line)); opacity: 0; pointer-events: none; animation: lkRing 4.8s ease-in-out infinite; }
.lk-speak.talking svg { animation: lkCore 4.8s ease-in-out infinite; transform-origin: center; }

@keyframes lkRing { 0% { transform: scale(1); opacity: 0; } 30% { transform: scale(1.05); opacity: .6; } 100% { transform: scale(1.24); opacity: 0; } }
@keyframes lkCore { 0%, 100% { opacity: 1; transform: scale(1.04); } 30% { opacity: .45; transform: scale(.96); } 65% { opacity: .85; transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .lk-speak.talking::after, .lk-speak.talking svg { animation: none; } }
.lk-sbar { position: absolute; left: 18%; right: 18%; bottom: -7px; height: 3px; border-radius: 2px; background: var(--line); overflow: hidden; pointer-events: none; }
.lk-sbar i { display: block; height: 100%; width: 0; background: var(--accent-ink); border-radius: 2px; transition: width .2s linear; }

/* workout teaser: how many workouts and their names; workout cards: flags of the languages under the icon */
.lab-count { flex-shrink: 0; font-size: 12px; font-weight: 800; color: var(--muted); background: var(--surface-2); border-radius: 999px; padding: 4px 10px; white-space: nowrap; }
.lab-side { display: flex; flex-direction: column; align-items: center; gap: 8px; flex-shrink: 0; }
.lab-flags { display: flex; flex-wrap: wrap; justify-content: center; gap: 3px; max-width: 64px; font-size: 13px; line-height: 1; }

/* Read-aloud audio (admin): three steps – voices, what is to do, chapters × languages */
.au-step { display: flex; align-items: center; gap: 8px; margin-top: 10px; font-size: 12px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.au-step i { font-style: normal; display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--indigo); color: var(--on-indigo); font-size: 12px; letter-spacing: 0; }
.au-box { padding: 12px; border-radius: 16px; background: var(--surface-2); }
.au-box > .btn { align-self: stretch; white-space: normal; }
.au-box .au-clone { background: var(--surface); }
.au .btn.link { background: none; border: 0; color: var(--accent-ink); padding: 4px 0; min-height: 0; align-self: flex-start; font-size: 13px; }
.au-hr { border: 0; border-top: 1px solid var(--line-strong); margin: 2px 0; width: 100%; }
.au-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.au-tab { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 6px; border: 1.5px solid var(--line-strong); border-radius: 14px; background: var(--surface); color: var(--ink); font: inherit; cursor: pointer; min-width: 0; }
.au-tab b { font-size: 15px; }
.au-tab span { font-size: 11.5px; font-weight: 700; color: var(--muted); text-align: center; overflow-wrap: anywhere; }
.au-tab[aria-pressed="true"] { background: var(--indigo); border-color: var(--indigo); color: var(--on-indigo); }
.au-tab[aria-pressed="true"] span { color: var(--on-indigo); opacity: .85; }
.au-gridwrap { overflow-x: auto; margin: 0 -12px; padding: 0 12px; }
.au-grid { border-collapse: separate; border-spacing: 3px; font-variant-numeric: tabular-nums; }
.au-grid th, .au-grid td { padding: 0; }
.au-gch { position: sticky; inset-inline-start: 0; z-index: 1; background: var(--surface-2); text-align: start; font-size: 13px; font-weight: 800; padding-inline-end: 6px !important; min-width: 96px; max-width: 120px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.au-gch small { color: var(--muted); font-weight: 800; }
.au-flag { border: 0; background: none; padding: 2px 3px; border-radius: 8px; font-size: 18px; line-height: 1; cursor: pointer; font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif; }
.au-flag[aria-pressed="true"] { background: var(--accent-soft); }
.au-cell { display: inline-grid; place-items: center; width: 32px; height: 30px; border: 0; border-radius: 9px; font: inherit; font-weight: 900; font-size: 13px; background: var(--surface); color: var(--muted); cursor: pointer; }
.au-cell.ok { background: var(--good-soft); color: var(--good-ink); }
.au-cell.warn { background: var(--gold-soft); color: var(--gold-ink); }
.au-cell.none { background: var(--surface); color: var(--muted); }
.au-cell.miss { background: none; color: var(--line-strong); cursor: default; }
.au-cell.foot { background: none; font-size: 12px; cursor: default; }
.au-cell.foot.warn { background: none; }
.au-cell.sel { outline: 2.5px solid var(--accent); outline-offset: 1px; }
.au-legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12px; color: var(--muted); }
.au-legend span { display: inline-flex; align-items: center; gap: 5px; }
.au-legend .au-cell { width: 22px; height: 20px; font-size: 11px; border-radius: 6px; cursor: default; }
.au-detail2 { padding: 12px; border: 1.5px solid var(--accent); border-radius: 14px; background: var(--surface); }
.au-detail2 > .btn { align-self: stretch; white-space: normal; }
.au-text li.chg { background: var(--gold-soft); }
.au-warnbox { padding: 12px; border-radius: 14px; background: var(--gold-soft); color: var(--gold-ink); }
.au-choice { display: flex; flex-direction: column; gap: 2px; text-align: start; padding: 10px 12px; border: 1.5px solid var(--line-strong); border-radius: 12px; background: var(--surface); color: var(--ink); font: inherit; cursor: pointer; }
.au-choice span { font-size: 12.5px; color: var(--muted); }

/* Admin overview: details under a to-do card (missing translations, courses, audio) */
.todo-more { gap: 8px; margin-top: -4px; }
.todo-lang { display: flex; flex-direction: column; gap: 2px; padding-bottom: 6px; border-bottom: 1px solid var(--line); }
.todo-row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 0; border: 0; border-bottom: 1px solid var(--line); background: none; color: inherit; font: inherit; font-weight: 700; text-align: start; cursor: pointer; }
.todo-row > svg { transform: rotate(180deg); color: var(--muted); flex: none; }
.todo-flags { font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif; font-size: 15px; letter-spacing: 1px; }
/* course page: languages and read-aloud state at a glance */
.cd-status { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px; border-radius: 14px; background: var(--surface-2); font-size: 13px; line-height: 1.5; }
.cd-status .au-badge { display: inline; margin: 0; }
.cd-miss { color: var(--gold-ink); }
.cd-ok { color: var(--good-ink); }

/* a switch whose group is empty (e.g. no further course): greyed out and not tappable */
.lk-sw.off { cursor: default; color: var(--muted); opacity: .5; }
