/* T3 Lab — stile dell'interfaccia */
@font-face { font-family: 'Barlow'; font-weight: 400; font-display: swap; src: url(../fonts/barlow-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'Barlow'; font-weight: 500; font-display: swap; src: url(../fonts/barlow-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: 'Barlow'; font-weight: 600; font-display: swap; src: url(../fonts/barlow-latin-600-normal.woff2) format('woff2'); }
@font-face { font-family: 'Barlow'; font-weight: 700; font-display: swap; src: url(../fonts/barlow-latin-700-normal.woff2) format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-style: italic; font-weight: 600; font-display: swap; src: url(../fonts/barlow-condensed-latin-600-italic.woff2) format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-style: italic; font-weight: 700; font-display: swap; src: url(../fonts/barlow-condensed-latin-700-italic.woff2) format('woff2'); }
@font-face { font-family: 'Barlow Condensed'; font-style: italic; font-weight: 800; font-display: swap; src: url(../fonts/barlow-condensed-latin-800-italic.woff2) format('woff2'); }

:root {
  --night: #0B1F3A; --electric: #1E5BFF; --bike: #5B8DF5; --swim: #19C2E6; --run: #FF7A45; --lime: #C6F432; --ice: #F4F7FB; --slate: #44546E;
  --strength: #8A97AD;
  --green: #1FA463; --yellow: #E8A317; --red: #E5484D;

  --bg: #F4F7FB; --surface: #FFFFFF; --surface-2: #EDF1F7; --border: #DCE3EE; --text: #0B1F3A; --muted: #5A6A84;
  --primary: #1E5BFF; --primary-ink: #FFFFFF; --primary-soft: #E3EBFF; --accent: #C6F432; --accent-ink: #0B1F3A;
  --topbar: #0B1F3A; --topbar-text: #F4F7FB;
  --shadow: 0 1px 2px rgba(11,31,58,.06), 0 4px 16px rgba(11,31,58,.06);
  --radius: 14px; --radius-s: 9px;
  --font: 'Barlow', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-title: 'Barlow Condensed', 'Barlow', 'Arial Narrow', sans-serif;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #071428; --surface: #0E2342; --surface-2: #132C51; --border: #1E3A63; --text: #EAF0F8; --muted: #9AABC4;
  --primary: #5B8DF5; --primary-ink: #071428; --primary-soft: #18325C; --accent: #C6F432; --accent-ink: #0B1F3A;
  --topbar: #0A1A33; --topbar-text: #F4F7FB;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 6px 20px rgba(0,0,0,.25);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { background: var(--bg); color: var(--text); font-family: var(--font); font-size: 15px; line-height: 1.45; -webkit-font-smoothing: antialiased; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { font-family: var(--font-title); font-style: italic; font-weight: 700; letter-spacing: .01em; margin: 0 0 .4em; line-height: 1.1; }
h1 { font-size: 30px; } h2 { font-size: 22px; } h3 { font-size: 18px; }
.num, .mono { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.hidden { display: none !important; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.grow { flex: 1; }
.stack > * + * { margin-top: 12px; }
.grid { display: grid; gap: 16px; }
.grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 900px) { .grid.cols-3, .grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .grid.cols-2, .grid.cols-3 { grid-template-columns: minmax(0, 1fr); } }

/* ---------- shell ---------- */
.topbar { position: sticky; top: 0; z-index: 20; background: var(--topbar); color: var(--topbar-text); display: flex; align-items: center; gap: 14px; padding: 0 18px; height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none !important; }
.brand svg { width: 38px; height: 38px; flex: none; }
.brand .word { font-family: var(--font-title); font-style: italic; font-weight: 800; font-size: 24px; letter-spacing: .02em; }
.brand .word b { color: var(--lime); font-weight: 800; }
.nav { display: flex; gap: 2px; margin-left: 10px; }
.nav a { color: #C9D5E8; padding: 8px 12px; border-radius: 9px; font-weight: 600; font-size: 14px; text-decoration: none; }
.nav a:hover { background: rgba(255,255,255,.07); color: #fff; }
.nav a.active { background: rgba(255,255,255,.12); color: #fff; box-shadow: inset 0 -2px 0 var(--lime); }
.topbar .spacer { flex: 1; }
.hat { display: inline-flex; background: rgba(255,255,255,.08); border-radius: 999px; padding: 3px; }
.hat button { border: 0; background: transparent; color: #C9D5E8; font: 600 13px var(--font); padding: 5px 12px; border-radius: 999px; cursor: pointer; }
.hat button.on { background: var(--lime); color: var(--night); }
.athlete-pick { background: rgba(255,255,255,.08); color: #fff; border: 1px solid rgba(255,255,255,.15); border-radius: 9px; padding: 6px 8px; font: 600 14px var(--font); max-width: 180px; }
.athlete-pick option { color: #0B1F3A; }
.me-btn { border: 0; background: transparent; padding: 0; cursor: pointer; border-radius: 50%; }
.menu { position: absolute; right: 12px; top: 56px; background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: 12px; box-shadow: var(--shadow); min-width: 220px; padding: 6px; z-index: 40; }
.menu a, .menu button { display: block; width: 100%; text-align: left; padding: 9px 12px; border-radius: 8px; color: var(--text); background: none; border: 0; font: 500 14px var(--font); cursor: pointer; text-decoration: none; }
.menu a:hover, .menu button:hover { background: var(--surface-2); }
.menu .who { padding: 8px 12px 10px; border-bottom: 1px solid var(--border); margin-bottom: 4px; }

.banner { background: var(--lime); color: var(--night); padding: 8px 18px; font-weight: 600; display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.banner button { margin-left: auto; }
main { max-width: 1240px; margin: 0 auto; padding: 22px 18px 90px; }
.page-head { display: flex; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.page-head h1 { margin: 0; }
.page-head .sub { color: var(--muted); font-weight: 500; }
.page-head .actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
footer.app-foot { text-align: center; color: var(--muted); font-size: 12px; padding: 16px 0 24px; }

.bottomnav { display: none; }
@media (max-width: 760px) {
  .nav { display: none; }
  .topbar { padding: 0 12px; gap: 8px; height: 56px; }
  .brand .word { display: none; }
  .athlete-pick { max-width: 120px; }
  main { padding: 16px 12px 96px; }
  h1 { font-size: 26px; }
  .bottomnav { display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 30; background: var(--surface); border-top: 1px solid var(--border); padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); justify-content: space-around; }
  .bottomnav a, .bottomnav button { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; color: var(--muted); font: 600 11px var(--font); background: none; border: 0; padding: 4px 0; text-decoration: none; cursor: pointer; }
  .bottomnav a.active { color: var(--primary); }
  .bottomnav svg { width: 22px; height: 22px; }
  .bottomnav .fab span.fab-c { width: 46px; height: 46px; margin-top: -20px; border-radius: 50%; background: var(--lime); color: var(--night); display: grid; place-items: center; box-shadow: var(--shadow); }
  .menu { top: 52px; }
}

/* ---------- componenti ---------- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; min-width: 0; }
.card > h2:first-child, .card > h3:first-child { margin-top: 0; }
.card.flat { box-shadow: none; }
.stat { display: flex; flex-direction: column; gap: 2px; }
.stat .v { font-family: var(--font-title); font-style: italic; font-weight: 800; font-size: 30px; line-height: 1; font-variant-numeric: tabular-nums; }
.stat .l { color: var(--muted); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font: 600 14px var(--font); padding: 8px 14px; border-radius: 10px; cursor: pointer; text-decoration: none !important; white-space: nowrap; min-height: 38px; }
.btn:hover { border-color: var(--primary); }
.btn.primary { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); }
.btn.primary:hover { filter: brightness(1.07); }
.btn.accent { background: var(--lime); border-color: var(--lime); color: var(--night); }
.btn.danger { color: var(--red); }
.btn.danger:hover { border-color: var(--red); }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.ghost:hover { background: var(--surface-2); }
.btn.sm { padding: 4px 10px; min-height: 30px; font-size: 13px; }
.btn.icon { padding: 6px; min-width: 36px; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn svg { width: 18px; height: 18px; }

label.f { display: flex; flex-direction: column; gap: 5px; font-weight: 600; font-size: 13px; color: var(--muted); min-width: 0; }
input, select, textarea { font: 500 15px var(--font); color: var(--text); background: var(--surface); border: 1px solid var(--border); border-radius: 9px; padding: 8px 10px; min-height: 38px; width: 100%; }
textarea { min-height: 80px; resize: vertical; line-height: 1.4; }
input:focus, select:focus, textarea:focus, .btn:focus-visible { outline: 2px solid var(--primary); outline-offset: 1px; border-color: var(--primary); }
input[type="checkbox"], input[type="radio"] { width: 18px; height: 18px; min-height: 0; accent-color: var(--primary); }
label.check { display: flex; align-items: center; gap: 8px; font-weight: 500; cursor: pointer; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }

.chip { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; background: var(--surface-2); color: var(--text); white-space: nowrap; }
.chip svg { width: 14px; height: 14px; }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.dot.green { background: var(--green); } .dot.yellow { background: var(--yellow); } .dot.red { background: var(--red); } .dot.missed { background: transparent; border: 2px solid var(--red); } .dot.todo { background: transparent; border: 2px solid var(--muted); } .dot.done { background: var(--primary); } .dot.extra { background: var(--slate); }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-weight: 700; font-size: 12px; }
.badge.green { background: color-mix(in srgb, var(--green) 18%, transparent); color: var(--green); }
.badge.yellow { background: color-mix(in srgb, var(--yellow) 20%, transparent); color: #B57D00; }
:root[data-theme="dark"] .badge.yellow { color: var(--yellow); }
.badge.red, .badge.missed { background: color-mix(in srgb, var(--red) 16%, transparent); color: var(--red); }
.badge.neutral { background: var(--surface-2); color: var(--muted); }
.badge.lime { background: var(--lime); color: var(--night); }

.avatar { border-radius: 50%; display: inline-grid; place-items: center; overflow: hidden; flex: none; background: var(--bike); color: #fff; font-weight: 700; font-family: var(--font); }
.avatar img { width: 100%; height: 100%; object-fit: cover; }

table.t { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
table.t th, table.t td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--border); font-size: 14px; }
table.t th { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; font-weight: 700; }
table.t tr.click { cursor: pointer; }
table.t tr.click:hover td { background: var(--surface-2); }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.empty { text-align: center; color: var(--muted); padding: 28px 12px; }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 16px; overflow-x: auto; }
.tabs button { border: 0; background: none; color: var(--muted); font: 600 14px var(--font); padding: 10px 14px; cursor: pointer; border-bottom: 3px solid transparent; white-space: nowrap; }
.tabs button.on { color: var(--text); border-bottom-color: var(--primary); }
.seg { display: inline-flex; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.seg button { border: 0; background: var(--surface); color: var(--muted); font: 600 13px var(--font); padding: 7px 12px; cursor: pointer; }
.seg button.on { background: var(--primary); color: var(--primary-ink); }

/* ---------- modale e toast ---------- */
.modal-bg { position: fixed; inset: 0; background: rgba(5,14,30,.55); z-index: 50; display: flex; align-items: flex-start; justify-content: center; padding: 40px 16px; overflow-y: auto; }
.modal { background: var(--surface); border-radius: 16px; box-shadow: 0 20px 60px rgba(0,0,0,.35); width: 100%; max-width: 640px; border: 1px solid var(--border); }
.modal.wide { max-width: 920px; }
.modal-h { display: flex; align-items: center; gap: 10px; padding: 16px 18px 6px; }
.modal-h h2 { margin: 0; flex: 1; }
.modal-b { padding: 10px 18px 16px; }
.modal-f { display: flex; gap: 8px; justify-content: flex-end; padding: 12px 18px 16px; border-top: 1px solid var(--border); flex-wrap: wrap; }
.modal-f .left { margin-right: auto; }
@media (max-width: 640px) { .modal-bg { padding: 0; align-items: stretch; } .modal { border-radius: 0; min-height: 100%; } }
#toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 60; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { background: var(--night); color: #fff; padding: 10px 16px; border-radius: 10px; box-shadow: var(--shadow); font-weight: 600; pointer-events: auto; border-left: 4px solid var(--lime); max-width: 90vw; }
.toast.err { border-left-color: var(--red); }
@media (max-width: 760px) { #toasts { bottom: 86px; } }

/* ---------- login ---------- */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; background:
  radial-gradient(1200px 500px at 85% -10%, rgba(30,91,255,.35), transparent 60%),
  radial-gradient(800px 400px at -10% 110%, rgba(25,194,230,.25), transparent 60%), var(--night); }
.login-card { width: 100%; max-width: 400px; background: var(--surface); border-radius: 20px; padding: 28px 26px; box-shadow: 0 30px 80px rgba(0,0,0,.4); }
.login-card .logo-big { display: flex; justify-content: center; margin-bottom: 8px; }
.login-card .logo-big svg { width: 96px; height: 96px; }
.login-card h1 { text-align: center; font-size: 34px; margin-bottom: 4px; }
.login-card .tag { text-align: center; color: var(--muted); margin-bottom: 20px; }
.login-card .ver { text-align: center; color: var(--muted); font-size: 12px; margin-top: 18px; }
.err-msg { background: color-mix(in srgb, var(--red) 12%, transparent); color: var(--red); padding: 8px 12px; border-radius: 9px; font-weight: 600; font-size: 14px; }
.ok-msg { background: color-mix(in srgb, var(--green) 14%, transparent); color: var(--green); padding: 8px 12px; border-radius: 9px; font-weight: 600; font-size: 14px; }
.otp-input { text-align: center; font-size: 26px; letter-spacing: .4em; font-variant-numeric: tabular-nums; }

/* ---------- calendario ---------- */
.cal-toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.cal-toolbar .title { font-family: var(--font-title); font-style: italic; font-weight: 700; font-size: 22px; min-width: 200px; }
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.cal .dow { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; padding: 0 4px; }
.day { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; min-height: 150px; padding: 8px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.day.today { border-color: var(--primary); box-shadow: inset 0 3px 0 var(--primary); }
.day.other { opacity: .5; }
.day.drop { outline: 2px dashed var(--primary); }
.day .dh { display: flex; align-items: center; gap: 6px; font-weight: 700; font-size: 13px; color: var(--muted); }
.day .dh .n { font-family: var(--font-title); font-style: italic; font-size: 20px; color: var(--text); }
.day .dh .add { margin-left: auto; opacity: .0; transition: opacity .15s; }
.day:hover .dh .add, .day .dh .add:focus { opacity: 1; }
@media (hover: none) { .day .dh .add { opacity: 1; } }
.cal.month .day { min-height: 104px; }
.sess { border-radius: 9px; padding: 6px 8px; background: var(--surface-2); border-left: 4px solid var(--c, var(--slate)); cursor: pointer; font-size: 13px; min-width: 0; }
.sess:hover { filter: brightness(.97); }
:root[data-theme="dark"] .sess:hover { filter: brightness(1.15); }
.sess .st { display: flex; align-items: center; gap: 5px; font-weight: 700; }
.sess .st .tt { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; min-width: 0; }
.sess .meta { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.sess svg { width: 14px; height: 14px; flex: none; color: var(--c); }
.sess.act { background: transparent; border: 1px dashed var(--border); border-left: 4px solid var(--c, var(--slate)); }
.sess.draft { opacity: .7; border-style: dashed; }
.sess.rest { --c: var(--slate); background: transparent; }
.cal.month .sess .meta { display: none; }
.cal.month .sess { padding: 3px 6px; font-size: 12px; }
@media (max-width: 760px) {
  .cal.week { grid-template-columns: minmax(0, 1fr); }
  .cal.week .dow { display: none; }
  .cal.week .day { min-height: 0; }
  .cal.week .day .dh .wd { display: inline; }
  .cal.month { gap: 3px; }
  .cal.month .day { min-height: 64px; padding: 4px; border-radius: 8px; }
  .cal.month .sess .st .tt { display: none; }
  .cal.month .sess { padding: 2px 4px; border-left-width: 3px; }
  .cal.month .day .dh .add { display: none; }
}
.day .dh .wd { display: none; }
.week-sum { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 12px; }

/* ---------- builder sessione ---------- */
.steps { display: flex; flex-direction: column; gap: 8px; }
.step { border: 1px solid var(--border); border-left: 4px solid var(--sc, var(--slate)); border-radius: 10px; padding: 8px; background: var(--surface); }
.step.repeat { border-left-color: var(--lime); background: var(--surface-2); }
.step .sr { display: grid; grid-template-columns: 130px 110px 110px 1fr auto; gap: 6px; align-items: center; }
.step .sr.tg { grid-template-columns: 130px 1fr 1fr 1fr; margin-top: 6px; }
.step .inner { margin: 8px 0 0 10px; display: flex; flex-direction: column; gap: 6px; }
.step input, .step select { min-height: 34px; padding: 5px 8px; font-size: 14px; }
@media (max-width: 640px) { .step .sr, .step .sr.tg { grid-template-columns: 1fr 1fr; } }
.step[data-t="warmup"], .step[data-t="cooldown"] { --sc: var(--swim); }
.step[data-t="work"] { --sc: var(--run); }
.step[data-t="recovery"] { --sc: var(--bike); }
.step[data-t="steady"] { --sc: var(--electric); }
.estimate { display: flex; gap: 18px; align-items: center; padding: 10px 12px; background: var(--primary-soft); border-radius: 10px; font-weight: 600; flex-wrap: wrap; }
.struct-view { display: flex; flex-direction: column; gap: 4px; }
.struct-view .sv { display: flex; gap: 8px; align-items: center; padding: 6px 10px; border-radius: 8px; background: var(--surface-2); border-left: 4px solid var(--sc, var(--slate)); font-size: 14px; }
.struct-view .sv.rep { background: transparent; border-left-color: var(--lime); font-weight: 700; }
.struct-view .sv .k { font-weight: 700; min-width: 100px; }
.struct-view .indent { margin-left: 18px; display: flex; flex-direction: column; gap: 4px; }

/* ---------- attività ---------- */
.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 12px; }
.compare td.dev { font-weight: 700; }
.chart-box { position: relative; height: 280px; }
.chart-box.tall { height: 340px; }
.chart-box.short { height: 200px; }
.thread { display: flex; flex-direction: column; gap: 12px; }
.msg { display: flex; gap: 10px; align-items: flex-start; }
.msg .bubble { background: var(--surface-2); border-radius: 4px 14px 14px 14px; padding: 8px 12px; max-width: 100%; white-space: pre-wrap; word-wrap: break-word; }
.msg.mine { flex-direction: row-reverse; }
.msg.mine .bubble { background: var(--primary-soft); border-radius: 14px 4px 14px 14px; }
.msg .who { font-size: 12px; color: var(--muted); font-weight: 600; margin-bottom: 2px; }
.msg.mine .who { text-align: right; }
.msg .kind { font-weight: 700; color: var(--run); }
.rpe-scale { display: grid; grid-template-columns: repeat(10, 1fr); gap: 4px; }
.rpe-scale button { border: 1px solid var(--border); background: var(--surface); border-radius: 8px; padding: 8px 0; font: 700 15px var(--font); cursor: pointer; color: var(--text); }
.rpe-scale button.on { background: var(--primary); color: var(--primary-ink); border-color: var(--primary); }
.ai-box { border: 1px solid var(--border); border-radius: 12px; padding: 14px; background: linear-gradient(180deg, color-mix(in srgb, var(--lime) 10%, transparent), transparent 60%); }
.ai-text { white-space: pre-wrap; line-height: 1.55; }
.dropzone { border: 2px dashed var(--border); border-radius: 14px; padding: 26px; text-align: center; color: var(--muted); cursor: pointer; transition: border-color .15s, background .15s; }
.dropzone.over { border-color: var(--primary); background: var(--primary-soft); }
.dropzone svg { width: 34px; height: 34px; color: var(--primary); }

/* heatmap aderenza */
.heat { display: grid; grid-auto-flow: column; grid-template-rows: repeat(7, 16px); gap: 4px; overflow-x: auto; padding-bottom: 4px; }
.legend .c { width: 12px; height: 12px; border-radius: 3px; display: inline-block; background: var(--surface-2); }
.heat .c { width: 16px; height: 16px; border-radius: 4px; background: var(--surface-2); }
.heat .c.green, .legend .c.green { background: var(--green); } .heat .c.yellow, .legend .c.yellow { background: var(--yellow); } .heat .c.red, .legend .c.red { background: var(--red); }
.heat .c.missed, .legend .c.missed { background: transparent; border: 2px solid var(--red); } .heat .c.extra, .legend .c.extra { background: var(--slate); } .heat .c.todo { background: transparent; border: 2px solid var(--border); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--muted); margin-top: 8px; align-items: center; }
.legend span { display: inline-flex; gap: 6px; align-items: center; }

/* lista atleti */
.athlete-card { display: flex; gap: 12px; align-items: center; cursor: pointer; }
.athlete-card:hover { border-color: var(--primary); }

.qr { background: #fff; padding: 8px; border-radius: 10px; display: inline-block; }
.secret { font-family: ui-monospace, Menlo, monospace; background: var(--surface-2); padding: 4px 8px; border-radius: 6px; word-break: break-all; }
.spinner { width: 18px; height: 18px; border: 3px solid var(--border); border-top-color: var(--primary); border-radius: 50%; animation: spin 0.8s linear infinite; display: inline-block; vertical-align: middle; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading { padding: 40px; text-align: center; }
h1 svg, h2 svg, h3 svg { width: 24px; height: 24px; flex: none; }
table.t td svg, .row > span > svg, a.row > svg { width: 18px; height: 18px; vertical-align: middle; flex: none; }
.banner svg { width: 18px; height: 18px; }
