:root {
  --navy: #001F48;
  --navy-2: #0a2c5c;
  --cyan: #0D9ED9;
  --cyan-2: #1FAAE1;
  --blue: #01559e;
  --bg: #f4f7fb;
  --card: #ffffff;
  --ink: #0f1c2e;
  --ink-2: #4a5a70;
  --ink-3: #8593a6;
  --line: #e3e9f1;
  --danger: #ce0058;
  --danger-bg: #fde8f1;
  --amber: #b7791f;
  --amber-bg: #fdf3e1;
  --ok: #0f9d6b;
  --ok-bg: #e4f7ef;
  --loglig: #F26522;
  --loglig-ink: #1a1a1a;
  --meet-tint: #EEF2FA;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(0, 31, 72, .06), 0 6px 20px rgba(0, 31, 72, .06);
  --mono: ui-monospace, "SF Mono", "Roboto Mono", Menlo, Consolas, monospace;
  --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: "Assistant", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  min-height: 100dvh;
}
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.dot { color: var(--ink-3); margin: 0 .35em; }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: calc(10px + env(safe-area-inset-top, 0px)) 14px 10px;
  background: linear-gradient(180deg, var(--navy), var(--navy-2));
  color: #fff;
  box-shadow: 0 2px 12px rgba(0, 31, 72, .25);
}
.brand { min-width: 0; }
.brand-title { font-weight: 800; font-size: 17px; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-sub { font-size: 12px; color: #9fc7e8; letter-spacing: .02em; }
.top-btn {
  min-height: 40px; padding: 0 12px; border-radius: 10px;
  border: 1px solid rgba(255,255,255,.18); background: rgba(255,255,255,.08); color: #fff;
  font-weight: 600; font-size: 14px; transition: background .15s;
}
.top-btn:hover, .top-btn:focus-visible { background: rgba(255,255,255,.18); }
.top-btn.is-active { background: var(--cyan); border-color: var(--cyan); }
/* ---------- Layout ---------- */
main { max-width: 560px; margin: 0 auto; padding: 14px 14px calc(28px + var(--safe-b)); }
.view { animation: none; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.loading { position: absolute; inset: auto 0 0; height: 3px; overflow: hidden; pointer-events: none; }
.loading::after { content: ""; display: block; width: 35%; height: 100%; background: var(--cyan); animation: route-progress 1.2s ease-in-out infinite; }
@keyframes route-progress { from { transform: translateX(300%); } to { transform: translateX(-100%); } }
.view-title { font-size: 24px; font-weight: 800; margin: 12px 0 4px; color: var(--navy); }
.view-hint { margin: 0 0 18px; color: var(--ink-2); }
.source-note { margin-top: 22px; font-size: 13px; color: var(--ink-3); line-height: 1.5; }
.source-note a { color: var(--blue); }
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); }

/* ---------- Lane grid ---------- */
.lane-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.lane-btn {
  position: relative; aspect-ratio: 1 / 1.05; border: 2px solid transparent; border-radius: 20px;
  background: var(--card); box-shadow: var(--shadow);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  transition: transform .12s, border-color .15s, box-shadow .15s;
  overflow: hidden;
}
.lane-btn::before {
  content: ""; position: absolute; inset: auto 0 0 0; height: 6px;
  background: repeating-linear-gradient(90deg, var(--cyan) 0 12px, #fff 12px 18px, var(--danger) 18px 30px, #fff 30px 36px);
  opacity: .55;
}
.lane-btn:active { transform: scale(.97); }
.lane-btn:hover { border-color: var(--cyan-2); }
.lane-btn.is-current { border-color: var(--cyan); box-shadow: 0 0 0 4px rgba(13,158,217,.18), var(--shadow); }
.lane-num { font-size: 46px; font-weight: 800; color: var(--navy); font-family: var(--mono); line-height: 1; }
.lane-count { font-size: 13px; color: var(--ink-2); }
.lane-done { font-size: 12px; color: var(--ok); font-weight: 700; }

/* ---------- Queue bar ---------- */
.queue-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.queue-meta { font-size: 14px; color: var(--ink-2); white-space: nowrap; }
.queue-meta b { color: var(--navy); }
.jump select {
  min-height: 40px; max-width: 210px; padding: 0 10px; border-radius: 10px;
  border: 1px solid var(--line); background: #fff; font-size: 14px; color: var(--navy); font-weight: 600;
}
.progress { height: 4px; background: #e2e9f2; border-radius: 4px; overflow: hidden; margin-bottom: 12px; }
.progress-fill { height: 100%; width: 0; background: linear-gradient(90deg, var(--cyan-2), var(--cyan)); transition: width .3s; }

/* ---------- Heat card ---------- */
.heat-card { padding: 16px 16px 14px; margin-bottom: 12px; border-top: 4px solid var(--blue); }
.heat-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.event-label { font-size: 20px; font-weight: 800; color: var(--navy); line-height: 1.2; }
.event-sub { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.chip {
  display: inline-flex; align-items: center; min-height: 26px; padding: 0 10px; border-radius: 999px;
  background: #eaf4fb; color: var(--blue); font-size: 13px; font-weight: 700;
}
.chip-heat { background: var(--blue); color: #fff; }
.chip-muted { background: #eef1f5; color: var(--ink-2); font-weight: 600; }
.saved-badge {
  display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 999px;
  background: var(--ok-bg); color: var(--ok); font-weight: 700; font-size: 13px; white-space: nowrap;
  animation: pop .25s ease-out;
}
.saved-badge svg { width: 16px; height: 16px; stroke-width: 3; }
.saved-badge.is-dirty { background: var(--amber-bg); color: var(--amber); }
.saved-badge.is-dsq { background: var(--danger-bg); color: var(--danger); }
.saved-badge.is-dns { background: #eef1f5; color: var(--ink-2); }
@keyframes pop { 0% { transform: scale(.85); opacity: 0; } 100% { transform: none; opacity: 1; } }
.swimmer {
  display: flex; align-items: center; gap: 12px; margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line);
}
.swimmer-lane {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; flex: none;
  background: var(--navy); color: #fff; font-weight: 800; font-size: 22px; font-family: var(--mono);
}
.swimmer-info { flex: 1; min-width: 0; }
.swimmer-name { font-size: 22px; font-weight: 800; line-height: 1.15; }
.swimmer-meta { color: var(--ink-2); font-size: 15px; margin-top: 2px; }
.seed { font-family: var(--mono); font-size: 15px; color: var(--blue); font-weight: 700; direction: ltr; flex: none; }

/* ---------- Entry ---------- */
.entry-card { padding: 16px; margin-bottom: 12px; transition: opacity .2s; }
.time-wrap { margin-bottom: 14px; }
.time-display {
  display: flex; justify-content: center; align-items: baseline; gap: 2px;
  padding: 14px 8px 10px; border-radius: 14px; background: #f3f7fc; border: 2px solid transparent;
  font-family: var(--mono); font-size: clamp(36px, 11vw, 52px); font-weight: 700; color: var(--navy);
  transition: border-color .15s, background .15s;
}
.time-display.is-focused { border-color: var(--cyan); background: #fff; }
.time-display.is-invalid { border-color: var(--danger); }
.time-display.is-disabled { color: #b8c3d1; background: #f1f3f6; }
.seg {
  display: inline-flex; border: 0; background: none; padding: 2px 3px; border-radius: 8px; line-height: 1.1;
  font: inherit; color: inherit; min-height: 44px; align-items: center;
}
.seg:hover:not(:disabled) { background: #e7f3fb; }
.seg:disabled { cursor: default; }
.sep { color: var(--ink-3); padding: 0 1px; }
.digit { position: relative; display: inline-block; width: .62em; text-align: center; }
.digit.is-empty { color: #c2ccd8; }
.time-display.is-disabled .digit { color: inherit; }
.digit.is-cursor::after {
  content: ""; position: absolute; left: 8%; right: 8%; bottom: -2px; height: 4px; border-radius: 2px;
  background: var(--cyan); animation: blink 1s steps(2, start) infinite;
}
@keyframes blink { to { visibility: hidden; } }
.time-legend {
  display: grid; grid-template-columns: 2fr 2fr 2fr 1.2fr; gap: 4px; text-align: center;
  font-size: 11px; color: var(--ink-3); margin-top: 6px; padding: 0 10%;
}
.status-row { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 12px; }
.status-row > .field { min-width: 0; max-width: 100%; }
.field { display: flex; flex-direction: column; gap: 4px; flex: 1 1 150px; }
.field-label { font-size: 13px; color: var(--ink-2); font-weight: 600; }
.field-label em { font-style: normal; color: var(--ink-3); font-weight: 400; }
.status-select, .reason-field input, .reason-field select {
  width: 100%; min-width: 0; max-width: 100%;
  min-height: 48px; padding: 0 12px; border-radius: 12px; border: 1.5px solid var(--line); background: #fff; font-size: 16px;
}
.status-select { font-weight: 700; color: var(--navy); }
.status-select:focus, .reason-field input:focus, .reason-field select:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(13,158,217,.15); }
.status-select.is-DSQ { border-color: var(--danger); color: var(--danger); background: var(--danger-bg); }
.status-select.is-DNS { border-color: #c9a35f; color: var(--amber); background: var(--amber-bg); }
.reason-field { flex: 2 1 220px; animation: fade .2s ease-out; }
.reason-field input, .reason-field select { border-color: #f2b9d0; background: #fff; }
.loglig-status { display: inline-block; margin-inline-start: 8px; padding: 2px 8px; border-radius: 999px; background: #fff; color: var(--loglig-ink); border: 1.5px solid var(--loglig); font-size: 13px; font-weight: 700; }
.loglig-status.is-verified, .loglig-status.is-skipped_unchanged { background: #fff; color: var(--loglig-ink); }
.loglig-status.is-failed, .loglig-status.is-conflict, .loglig-status.is-verify_failed, .loglig-status.is-suspended { background: #fff; color: var(--danger); border-color: var(--loglig); }
.loglig-status.is-relay_skipped, .loglig-status.is-dry_run { background: #fff; color: var(--loglig-ink); }
.status-note {
  margin: -2px 0 12px; padding: 10px 12px; border-radius: 10px; font-size: 14px; font-weight: 600;
}
.status-note.is-DSQ { background: var(--danger-bg); color: var(--danger); }
.status-note.is-DNS { background: var(--amber-bg); color: var(--amber); }

.keypad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.keypad button {
  min-height: 58px; border-radius: 14px; border: 1px solid #c5cedf; background: #eef3f9; color: var(--navy);
  font-size: 26px; font-weight: 700; font-family: var(--mono);
  display: grid; place-items: center; transition: background .1s, transform .08s;
  touch-action: manipulation; user-select: none;
}
.keypad button:active:not(:disabled) { background: #d4e8f6; transform: scale(.97); }
.keypad button.k-aux { font-family: inherit; font-size: 16px; color: var(--ink-2); background: #f4f6f9; }
.keypad button svg { width: 26px; height: 26px; }
.keypad button:disabled { opacity: .35; cursor: not-allowed; }

/* ---------- Actions ---------- */
.actions { display: grid; grid-template-columns: 1fr 1.4fr 1fr; gap: 10px; }
.actions-sheet { grid-template-columns: 1fr; margin-top: 12px; }
.btn {
  min-height: 54px; border-radius: 14px; border: 0; font-weight: 800; font-size: 17px;
  display: inline-flex; align-items: center; justify-content: center; gap: 4px; transition: filter .15s, transform .08s;
}
.btn:active:not(:disabled) { transform: scale(.98); }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.btn-primary { background: var(--cyan); color: #fff; box-shadow: 0 4px 14px rgba(13,158,217,.35); }
.btn-primary:hover { filter: brightness(1.05); }
.btn-primary.is-saved { background: var(--ok); box-shadow: 0 4px 14px rgba(15,157,107,.3); }
.btn-ghost { background: #fff; color: var(--navy); box-shadow: var(--shadow); }
.sub-actions { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; flex-wrap: wrap; }
.toggle { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--ink-2); min-height: 44px; cursor: pointer; }
.toggle input { position: absolute; opacity: 0; pointer-events: none; }
.toggle-ui { width: 40px; height: 24px; border-radius: 12px; background: #cfd8e3; position: relative; transition: background .15s; flex: none; }
.toggle-ui::after { content: ""; position: absolute; top: 3px; right: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .15s; box-shadow: 0 1px 3px rgba(0,0,0,.2); }
.toggle input:checked + .toggle-ui { background: var(--cyan); }
.toggle input:checked + .toggle-ui::after { transform: translateX(-16px); }
.toggle input:focus-visible + .toggle-ui { outline: 2px solid var(--cyan); outline-offset: 2px; }
.link-btn { border: 0; background: none; color: var(--danger); font-size: 14px; font-weight: 600; min-height: 44px; padding: 0 4px; }

/* ---------- Heat sheet ---------- */
.sheet-nav { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.sheet-title { flex: 1; text-align: center; }
.sheet-title .event-sub { justify-content: center; }
.icon-btn {
  width: 48px; height: 48px; flex: none; border-radius: 14px; border: 0; background: #fff; color: var(--navy);
  box-shadow: var(--shadow); display: grid; place-items: center;
}
.icon-btn:disabled { opacity: .35; }
.sheet-card { overflow: hidden; }
.sheet { width: 100%; border-collapse: collapse; font-size: 15px; }
.sheet th { background: var(--blue); color: #fff; font-weight: 700; font-size: 13px; padding: 10px 8px; text-align: right; }
.sheet td { padding: 12px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.sheet tr:last-child td { border-bottom: 0; }
.sheet td.c-lane { width: 52px; text-align: center; }
.sheet .lane-pill {
  display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 9px;
  background: #eef3f9; color: var(--navy); font-weight: 800; font-family: var(--mono);
}
.sheet td.c-name { font-weight: 700; }
.sheet td.c-times { min-width: 88px; max-width: 120px; }
.sheet td.c-year { color: var(--ink-2); }
.sheet td.c-club { color: var(--ink-2); font-size: 14px; }
.sheet td.c-empty { color: var(--ink-3); font-style: italic; }
.sheet tr.is-mine td { background: #e6f5fc; }
.sheet tr.is-mine .lane-pill { background: var(--cyan); color: #fff; }
.sheet .time-stack { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.sheet .t-seed {
  font-family: var(--mono); color: var(--ink-3); direction: ltr; font-size: 12px; font-weight: 600;
}
.sheet .t-pill {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 8px; border-radius: 999px;
  font-family: var(--mono); font-size: 13px; font-weight: 800; direction: ltr; line-height: 1.2;
  max-width: 100%;
}
.sheet .t-pill .t-cap {
  font-family: var(--sans, 'Assistant', system-ui, sans-serif); font-size: 10px; font-weight: 800;
  letter-spacing: .02em; direction: rtl;
}
.sheet .t-official { background: #dcfce7; color: #166534; border: 1px solid #86efac; }
.sheet .t-official.is-dq, .sheet .t-official.is-dns, .sheet .t-official.is-dnf {
  background: #fee2e2; color: #991b1b; border-color: #fca5a5;
}
.sheet .t-official.is-dns { background: #ffedd5; color: #9a3412; border-color: #fdba74; }
.sheet .t-judge {
  background: #e0f2fe; color: #075985; border: 1px dashed #7dd3fc;
}
.sheet .t-judge.is-saved { background: #f1f5f9; color: #334155; border-style: solid; border-color: #cbd5e1; }
.sheet .t-judge.is-dq { color: var(--danger); }
.sheet .t-judge.is-dns { color: var(--amber); }
.sheet .t-place {
  font-family: var(--sans, 'Assistant', system-ui, sans-serif); font-size: 11px; font-weight: 800;
  color: #166534; direction: rtl;
}
@media (max-width: 420px) {
  .sheet td.c-club { display: none; }
  .sheet td.c-name .club-inline { display: block; font-weight: 400; color: var(--ink-2); font-size: 13px; }
  .top-btn { padding: 0 8px; font-size: 12.5px; }
  .brand-title { font-size: 15px; }
  .sheet td.c-times { min-width: 78px; }
}
@media (min-width: 421px) { .club-inline { display: none; } }

/* ---------- Results page ---------- */
.results-head { margin-bottom: 8px; }
.results-title { margin-bottom: 2px; }
.results-pick {
  display: block; margin: 10px 0 12px;
}
.results-pick select {
  width: 100%; min-height: 44px; appearance: none; -webkit-appearance: none;
  padding: 14px 16px; padding-inline-end: 40px; border-radius: 14px; border: 1.5px solid var(--line);
  background: #fff url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23001F48' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'><path d='m6 9 6 6 6-6'/></svg>") no-repeat left 14px center / 18px;
  font: inherit; font-weight: 700; font-size: 16px; color: var(--navy);
  box-shadow: 0 1px 0 rgba(0,31,72,.04);
}
.results-event-pick { position: relative; }
.results-pick select.has-event-counts { color: transparent; }
.results-pick select option { color: var(--navy); }
.results-event-display {
  position: absolute; inset-block: 0; inset-inline: 17px 40px; pointer-events: none;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  color: var(--navy); font-weight: 700; white-space: nowrap;
}
#resultsEventLabel { overflow: hidden; text-overflow: ellipsis; }
.results-other-count { flex: none; font-size: 13px; color: var(--ink-2); }
.age-chips {
  display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px;
}
.age-chip {
  min-width: 44px; min-height: 44px;
  border: 1.5px solid var(--line); background: #fff; color: var(--ink-2);
  border-radius: 999px; padding: 8px 14px; font: inherit; font-weight: 700; font-size: 14px;
  cursor: pointer; -webkit-tap-highlight-color: transparent; touch-action: manipulation;
}
.age-chip.is-active {
  background: var(--navy); color: #fff; border-color: var(--navy);
}
.results-attention {
  display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0 0 10px;
}
.results-attention-chip {
  display: inline-flex; flex: none; align-items: center; gap: 8px; min-height: 44px; padding: 4px 12px;
  border: 1.5px solid var(--ink-3); border-radius: 999px; background: var(--card); color: var(--navy);
  font-weight: 800; white-space: nowrap;
}
.results-attention-chip svg { width: 18px; height: 18px; }
.results-attention-chip[aria-pressed="true"] { border-color: var(--navy); background: var(--navy); color: var(--card); }
.results-attention-count {
  display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding-inline: 6px;
  border-radius: 999px; background: var(--meet-tint); color: var(--navy); font-variant-numeric: tabular-nums;
}
.results-attention-chip[aria-pressed="true"] .results-attention-count { background: var(--card); }
.results-attention-summary { font-weight: 600; font-size: 14px; color: var(--ink-2); margin: 0; }
#resultsDeliveryStatus { margin-bottom: 10px; }
.results-delivery-notice { margin-bottom: 10px; }
.results-delivery-notice p { margin: 0; }
.results-delivery-notice a {
  display: inline-flex; align-items: center; min-height: 44px; color: var(--blue); font-weight: 700;
}
.results-attention-empty { padding: 24px 16px; text-align: center; }
.results-attention-empty-icon {
  display: inline-grid; place-items: center; width: 44px; height: 44px;
  border-radius: 50%; background: var(--meet-tint); color: var(--blue);
}
.results-attention-empty h2 { margin: 10px 0 4px; font-size: 20px; color: var(--navy); }
.results-attention-empty p { margin: 0; color: var(--ink-2); }
#resultsAttentionEmptyActions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 16px; }
#resultsAttentionEmptyActions .btn { min-height: 44px; padding: 8px 14px; }
.results-attention-empty .btn-primary { background: var(--navy); box-shadow: none; }
.results-card { overflow: hidden; padding: 0; }
.results-table {
  --result-red: #ad333b;
  --result-amber: #8a6122;
  width: 100%; table-layout: fixed; border-collapse: collapse; font-size: 15px;
}
.results-table th {
  background: #254f88; color: #fff; font-weight: 800; font-size: 13px; text-align: center;
}
.results-table th:nth-child(2) { text-align: start; }
.results-table th, .results-table td { padding: 9px 8px; white-space: nowrap; }
.results-table td { border-bottom: 1px solid var(--line); vertical-align: middle; }
.results-table tr:last-child td { border-bottom: 0; }
.results-table .c-place, .results-table .c-lane { width: 54px; text-align: center; }
.results-table td.c-place, .results-table td.c-lane { font-weight: 800; color: var(--navy); }
.results-table .c-time { width: 130px; }
.results-table td.c-time {
  font-family: var(--mono); direction: ltr; text-align: center; font-weight: 800; color: var(--ink-2);
  overflow: hidden; text-overflow: ellipsis;
}
.results-table .c-year { width: 60px; text-align: center; }
.results-table td.c-year { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.results-table .c-status { width: 56px; padding-inline: 2px; }
.results-table td.c-status { padding-block: 3px; text-align: center; }
.results-table .name-cell { padding-block: 4px; }
.results-table .result-name { display: flex; flex-direction: column; justify-content: center; min-height: 44px; }
.results-table .result-person, .results-table .result-club {
  display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.results-table .result-person { font-weight: 800; line-height: 1.3; }
.results-table a.result-name { color: #254f88; text-decoration: none; }
.results-table a.result-name .result-person { text-decoration: underline; }
.results-table .result-club { font-size: 12px; line-height: 1.3; color: var(--ink-2); margin-top: 2px; }
.results-table .is-official .c-time { color: var(--navy); }
.results-table .is-failed td { background: #fdf1f3; }
.results-table .is-failed .c-time { color: var(--result-red); }
.results-table td.c-time.is-no-finish { color: var(--result-amber); }
.results-table .is-official .c-status { color: #337254; }
.results-table .is-waiting .c-status, .results-table .is-suspended .c-status { color: var(--result-amber); }
.results-table .is-unmapped .c-status { color: var(--danger); }
.results-table .is-failed .c-status { color: var(--result-red); }
.result-icon { width: 22px; height: 22px; vertical-align: middle; }
.result-status-button {
  display: inline-grid; place-items: center; vertical-align: middle;
  width: 44px; height: 44px; padding: 0;
  border: 1.5px solid var(--line); border-radius: 10px; background: #f8fafc;
}
.result-status-button:hover, .result-status-button[aria-expanded="true"] { border-color: currentColor; background: #edf3fa; }
.result-status-button:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.result-details {
  position: fixed; z-index: 40; top: var(--result-details-top, 12px); left: var(--result-details-left, 12px);
  width: min(340px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); overflow: auto;
  padding: 14px 16px 16px; border: 1.5px solid var(--line); border-radius: var(--radius);
  background: var(--card); color: var(--ink); box-shadow: 0 12px 36px rgba(0, 31, 72, .22);
  overflow-wrap: anywhere;
}
.result-details-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.result-details-head h2 { margin: 0; color: var(--navy); font-size: 19px; line-height: 1.3; }
.result-details-head .icon-btn { flex: none; }
.result-details p { margin: 0 0 8px; }
.result-details-club, .result-details-source { color: var(--ink-2); }
.result-details .result-details-value {
  margin-top: 8px; color: var(--navy); text-align: right; font: 800 18px var(--mono);
}
.result-details-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; margin-top: 8px; }
.result-details-actions .heat-send-resolve { min-height: 44px; padding: 8px 20px; }
.result-details-actions a { display: inline-flex; align-items: center; min-height: 44px; color: var(--blue); }
@media (max-width: 560px) {
  .result-details {
    inset: auto 0 0; width: 100%; max-height: min(85dvh, 540px);
    border-radius: var(--radius) var(--radius) 0 0; padding-bottom: calc(16px + var(--safe-b));
  }
}
.results-empty {
  padding: 28px 16px; text-align: center; color: var(--ink-3); font-weight: 600;
}
.heat-progress {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 0 0 12px; padding: 10px 12px; border-radius: 12px;
  background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow);
  color: var(--navy); font-weight: 800; font-size: 14px;
}
.heat-progress-text { white-space: nowrap; }
.heat-progress-bar {
  flex: 1; height: 6px; min-width: 72px; border-radius: 6px; background: #e2e9f2; overflow: hidden;
}
.heat-progress-fill { display: block; height: 100%; width: 0; background: var(--ok); }
.heat-sheets { display: flex; flex-direction: column; gap: 12px; margin-bottom: 12px; }
.heat-block {
  background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow);
  overflow: hidden; border: 1.5px solid var(--line);
}
.heat-block.is-unswum { border-style: dashed; border-color: #b7c3d3; background: #f8fafc; }
.heat-block.is-partial { border-color: #fdba74; }
.heat-block.is-complete { border-color: #86efac; }
.heat-block-head {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 12px 12px 4px;
}
.heat-block-title-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.heat-block-title { margin: 0; font-size: 18px; font-weight: 800; color: var(--navy); }
.heat-refresh {
  width: auto; min-height: 36px; border: 0; border-radius: 10px; padding: 4px 8px;
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--loglig); color: var(--loglig-ink);
}
.heat-refresh svg { width: 16px; height: 16px; }
.heat-refresh .loglig-mark { color: inherit; font-size: 13px; }
.heat-refresh .loglig-mark svg { width: 16px; height: 16px; fill: currentColor; stroke: none; }
.heat-refresh.is-loading .loglig-refresh-icon { animation: heat-spin .8s linear infinite; }
.heat-refresh:disabled { cursor: default; }
@keyframes heat-spin { to { transform: rotate(-360deg); } }
.heat-block-note.is-error { color: var(--danger); }
.heat-status {
  display: inline-flex; align-items: center; min-height: 26px; padding: 0 10px;
  border-radius: 999px; font-size: 13px; font-weight: 800; white-space: nowrap;
}
.heat-block.is-unswum .heat-status { background: #eef1f5; color: var(--ink-2); }
.heat-block.is-partial .heat-status { background: var(--amber-bg); color: #9a3412; }
.heat-block.is-complete .heat-status { background: var(--ok-bg); color: #166534; }
.heat-block-meta, .heat-block-note {
  margin: 0; padding: 0 12px 8px; color: var(--ink-2); font-size: 13px; font-weight: 700;
}
.heat-last-sync { display: block; }
.heat-block.is-unswum .heat-block-note { color: #3d4d63; }
.heat-block.is-partial .heat-block-note { color: #9a3412; }
.loglig-resolve {
  width: min(560px, calc(100vw - 24px)); max-height: min(88vh, 760px);
  margin: auto; border: 0; border-radius: 16px; padding: 0; color: var(--loglig-ink);
  box-shadow: 0 16px 48px rgba(0, 31, 72, .28);
}
.loglig-resolve::backdrop { background: rgba(0, 31, 72, .45); }
.loglig-resolve-body { padding: 16px; overflow: auto; max-height: min(88vh, 760px); }
.loglig-resolve h2 { margin: 0 0 8px; color: var(--navy); font-size: 20px; }
.loglig-resolve-seed {
  margin: 0 0 10px; padding: 10px 12px; border-radius: 12px; background: #f3f7fc; color: var(--navy); line-height: 1.45;
}
.loglig-resolve-option {
  display: block; width: 100%; text-align: start; margin-top: 8px; padding: 10px 12px;
  border: 1.5px solid var(--line); border-radius: 12px; background: #fff; color: inherit;
  font: inherit; line-height: 1.45; cursor: pointer;
}
.loglig-resolve-option.is-selected { border-color: var(--loglig); background: #fff7f3; }
.loglig-resolve-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.loglig-resolve-actions .btn { width: 100%; }
@media (max-width: 640px) {
  .loglig-resolve { width: 100vw; max-width: 100vw; max-height: 92vh; margin: auto 0 0; border-radius: 16px 16px 0 0; }
}
@media (max-width: 420px) {
  .heat-progress { font-size: 13px; padding: 8px 10px; }
  .heat-block-title { font-size: 17px; }
  .results-table td, .results-table th { padding-inline: 4px; }
  .results-table .c-place, .results-table .c-lane { width: 44px; }
  .results-table .c-year { width: 42px; }
  .results-table .c-time { width: 100px; }
  .results-table td.c-time { font-size: 13px; }
  .results-table .c-status { width: 50px; }
}

/* ---------- Toast ---------- */
.toast-wrap { position: fixed; inset: auto 0 calc(18px + var(--safe-b)) 0; display: flex; justify-content: center; pointer-events: none; z-index: 50; }
.toast {
  padding: 12px 18px; border-radius: 12px; background: var(--navy); color: #fff; font-weight: 600; font-size: 15px;
  box-shadow: 0 10px 30px rgba(0,31,72,.3); opacity: 0; transform: translateY(12px); transition: opacity .2s, transform .2s; max-width: 90vw;
}
.toast.is-show { opacity: 1; transform: none; }
.toast.is-error { background: var(--danger); }
.toast.is-ok { background: var(--ok); }

:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* sticky bottom action bar on judge view (keeps שמור / הבא in thumb reach) */
#view-judge .actions {
  position: sticky; bottom: 0; z-index: 5;
  margin: 0 -14px; padding: 10px 14px calc(10px + var(--safe-b));
  background: linear-gradient(180deg, rgba(244,247,251,0), var(--bg) 22%);
  pointer-events: none;
}
#view-judge .sub-actions { margin-top: 4px; }
.toast-wrap { bottom: calc(92px + var(--safe-b)); }
@media (max-height: 760px) {
  .keypad button { min-height: 50px; }
  .time-display { padding: 10px 8px 6px; }
  .heat-card { padding: 12px 14px; }
  .swimmer { margin-top: 10px; padding-top: 10px; }
}
.seg { flex-direction: column; align-items: center; gap: 2px; padding: 2px 4px 4px; }
.seg-digits { display: inline-flex; }
.seg-cap { font-family: "Assistant", sans-serif; font-size: 11px; font-weight: 600; color: var(--ink-3); line-height: 1; }
.time-display { align-items: flex-start; }
.sep { line-height: 1.1; padding-top: 2px; }

/* ---------- v2: manual mode + submit ---------- */
.queue-tools { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pill-btn {
  display: inline-flex; align-items: center; gap: 4px; min-height: 40px; padding: 0 12px; border-radius: 10px;
  border: 1px solid var(--line); background: #fff; color: var(--blue); font-weight: 700; font-size: 14px; white-space: nowrap;
}
.pill-btn svg { width: 16px; height: 16px; }
.pill-btn[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }
.jump select { max-width: 170px; }
.manual-card { padding: 16px; margin-bottom: 12px; border-top: 4px solid var(--cyan); animation: fade .2s ease-out; }
.manual-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-bottom: 12px; }
.manual-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.manual-grid .field-wide { grid-column: 1 / -1; }
.manual-grid input, .manual-grid select {
  min-height: 48px; padding: 0 12px; border-radius: 12px; border: 1.5px solid var(--line); background: #fff; font-size: 16px; width: 100%; min-width: 0;
}
.manual-grid input:focus, .manual-grid select:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(13,158,217,.15); }
.manual-grid input.is-invalid { border-color: var(--danger); background: var(--danger-bg); }
.manual-list { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 6px; }
.manual-list:empty { display: none; }
.manual-list li { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; padding: 8px 10px; border-radius: 10px; background: #f3f7fc; }
.manual-list li b { font-weight: 700; }
.manual-list li span { color: var(--ink-2); white-space: nowrap; font-family: var(--mono); direction: ltr; }
.saved-badge.is-sent { background: #e3f1fb; color: var(--blue); }
.actions-judge { grid-template-columns: 72px 1fr 1.5fr 72px; gap: 8px; }
.btn-nav { flex-direction: column; gap: 0; font-size: 12px; font-weight: 700; padding: 0; }
.btn-nav svg { width: 22px; height: 22px; }
.btn-secondary { background: #fff; color: var(--blue); border: 2px solid #cfe3f3; font-size: 16px; }
.btn-secondary.is-saved { border-color: var(--ok); color: var(--ok); }
.btn-primary { gap: 8px; }
.btn-primary.is-sent { background: var(--blue); box-shadow: 0 4px 14px rgba(1,85,158,.3); }
.btn-primary.is-error { background: var(--danger); box-shadow: 0 4px 14px rgba(206,0,88,.3); }
#btnSubmit.is-sending:disabled { opacity: 1; cursor: progress; }
.send-spinner {
  width: 16px; height: 16px; border-radius: 50%; box-sizing: border-box; flex: none;
  border: 2px solid rgba(255,255,255,.35); border-top-color: #fff;
  animation: heat-spin .8s linear infinite;
}
.send-status {
  margin: 0 0 8px; min-height: 24px; font-weight: 800; font-size: 15px; color: var(--navy);
}
.send-status.is-sending, .send-status.is-sent, .send-status.is-error { animation: none; }
.send-status.is-sent { color: var(--ok); }
.send-status.is-error { color: var(--danger); }
.banner {
  position: fixed; top: calc(70px + env(safe-area-inset-top, 0px)); inset-inline: 0; margin: 0 auto; width: max-content; max-width: 92vw;
  display: flex; align-items: center; gap: 8px; padding: 12px 18px; border-radius: 14px; z-index: 40;
  background: var(--ok); color: #fff; font-weight: 700; box-shadow: 0 10px 30px rgba(15,157,107,.35);
  animation: drop .3s ease-out;
}
.banner svg { width: 22px; height: 22px; stroke-width: 3; }
@keyframes drop { from { opacity: 0; transform: translateY(-12px); } to { opacity: 1; transform: none; } }
.queue-meta { white-space: normal; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; font-size: 13px; }
.queue-meta .dot { display: none; }
.queue-tools { flex: none; }
main { overflow-x: clip; }

/* ---------- v2: live timer (default) ↔ keypad ---------- */
.entry-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.entry-mode-label { font-weight: 700; font-size: 14px; color: var(--ink-2); }
.mode-btn { display: inline-flex; align-items: center; gap: 2px; min-height: 44px; padding: 3px; border-radius: 12px; border: 1px solid var(--line); background: #f3f7fc; }
.mode-opt { display: grid; place-items: center; width: 40px; height: 34px; border-radius: 9px; color: var(--ink-3); transition: background .15s, color .15s; }
.mode-opt svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.mode-btn[data-mode="timer"] .mode-opt[data-opt="timer"], .mode-btn[data-mode="keypad"] .mode-opt[data-opt="keypad"] { background: var(--navy); color: #fff; }
.timer-panel[hidden], .keypad[hidden], .time-wrap[hidden] { display: none !important; }
.timer-display {
  font-family: var(--mono); font-variant-numeric: tabular-nums; font-weight: 800; text-align: center;
  font-size: clamp(44px, 14vw, 64px); letter-spacing: 1px; line-height: 1.1; padding: 14px 6px; border-radius: 14px;
  background: #f3f7fc; color: var(--navy); border: 2px solid var(--line);
}
.timer-display.is-running { border-color: var(--cyan); color: var(--blue); background: #eaf6fc; }
.timer-display.is-disabled { color: var(--ink-3); opacity: .55; }
.timer-display.is-invalid { border-color: var(--danger); background: var(--danger-bg); }
.timer-controls { display: grid; grid-template-columns: 2fr 1fr; gap: 10px; margin-top: 12px; }
.btn-timer { min-height: 72px; font-size: 22px; font-weight: 800; color: #fff; background: var(--ok); border: 0; border-radius: 16px; gap: 10px; box-shadow: 0 4px 14px rgba(15,157,107,.3); }
.btn-timer svg { width: 26px; height: 26px; fill: currentColor; }
.btn-timer .ic-stop { display: none; }
.btn-timer[data-state="running"] { background: var(--danger); box-shadow: 0 4px 14px rgba(206,0,88,.3); }
.btn-timer[data-state="running"] .ic-stop { display: inline; }
.btn-timer[data-state="running"] .ic-play { display: none; }
.btn-timer:disabled, .btn-timer-reset:disabled { opacity: .45; box-shadow: none; }
.btn-timer-reset { min-height: 72px; font-size: 18px; font-weight: 700; }
.banner { pointer-events: none; }  /* never block taps on the queue bar under it */

/* v3: reliable single tap, no double-tap zoom */
html, body { touch-action: manipulation; }
body { overscroll-behavior-y: contain; -webkit-tap-highlight-color: transparent; }
button, .btn, .icon-btn, .top-btn, .pill-btn, .lane-btn, .meet-lane-chip, .mode-btn, .link-btn, .toggle, a, label {
  touch-action: manipulation; user-select: none; -webkit-user-select: none;
}
#view-judge .actions > * { pointer-events: auto; }
#btnPrev, #btnNext { min-height: 56px; }

/* v3: hundredths — 11-char time (00:00:32.25) must fit, never clip */
.time-display { font-size: clamp(26px, 8.6vw, 48px); gap: 0; padding-left: 4px; padding-right: 4px; overflow: hidden; }
.seg { padding: 2px 2px 4px; }
.digit { width: .6em; }
.timer-display { font-size: clamp(30px, 10.5vw, 56px); letter-spacing: 0; white-space: nowrap; overflow: hidden; padding: 14px 4px; }

/* ===================== v4 ===================== */
/* ---------- day tabs ---------- */
.day-tabs {
  display: flex; gap: 8px; margin: 0 0 10px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
  padding: 2px; scroll-snap-type: x proximity;
}
.day-tabs::-webkit-scrollbar { display: none; }
.day-tab {
  flex: 1 0 auto; min-width: 92px; min-height: 52px; scroll-snap-align: start;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0; padding: 4px 10px;
  border-radius: 12px; border: 1.5px solid var(--line); background: #fff; color: var(--navy); line-height: 1.15;
  transition: background .15s, border-color .15s, color .15s;
}
.day-tab-main { font-weight: 800; font-size: 15px; }
.day-tab-sub { font-size: 12px; color: var(--ink-2); font-weight: 600; white-space: nowrap; }
.day-tab-note { font-size: 11px; color: var(--ink-3); font-family: var(--mono); }
.day-tab.is-active { background: var(--navy); border-color: var(--navy); color: #fff; box-shadow: 0 4px 12px rgba(0,31,72,.2); }
.day-tab.is-active .day-tab-sub, .day-tab.is-active .day-tab-note { color: #9fd8f3; }
.day-tab.is-empty { opacity: .55; border-style: dashed; cursor: not-allowed; }
.day-tab-all { flex: 0 0 auto; min-width: 72px; }
#view-lane .day-tabs { margin-bottom: 16px; }

/* ---------- jump button ---------- */
.jump-btn {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; max-width: 210px; padding: 0 10px 0 8px;
  border-radius: 12px; border: 1.5px solid #cfe3f3; background: #fff; color: var(--navy); font-weight: 700; font-size: 14px;
}
.jump-btn svg { width: 18px; height: 18px; color: var(--cyan); }
.jump-btn .caret { width: 16px; height: 16px; color: var(--ink-3); }
.jump-btn-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.jump-btn:active { background: #eaf6fc; }

/* ---------- jump sheet ---------- */
.jsheet-overlay {
  position: fixed; inset: 0; z-index: 60; background: rgba(0, 20, 48, .45); backdrop-filter: blur(2px);
  display: flex; align-items: flex-end; justify-content: center; animation: fadeIn .15s ease-out;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.jsheet {
  width: 100%; max-width: 560px; max-height: calc(100dvh - 48px - env(safe-area-inset-top, 0px));
  background: var(--bg); border-radius: 22px 22px 0 0; box-shadow: 0 -10px 40px rgba(0,31,72,.3);
  display: flex; flex-direction: column; padding: 6px 14px calc(12px + var(--safe-b)); animation: sheetUp .22s ease-out;
}
@keyframes sheetUp { from { transform: translateY(40px); opacity: .6; } to { transform: none; opacity: 1; } }
.jsheet-grip { width: 44px; height: 5px; border-radius: 3px; background: #cdd7e3; margin: 4px auto 6px; }
.jsheet-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.jsheet-head h2 { margin: 0; font-size: 19px; font-weight: 800; color: var(--navy); }
.jsheet-close { width: 44px; height: 44px; }
.jsearch {
  position: relative; display: flex; align-items: center; gap: 8px; margin: 10px 0; padding: 0 12px;
  min-height: 52px; border-radius: 14px; background: #fff; border: 2px solid var(--line);
}
.jsearch:focus-within { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(13,158,217,.15); }
.jsearch > svg { color: var(--cyan); }
.jsearch input { flex: 1; min-width: 0; border: 0; outline: none; background: none; font-size: 17px; min-height: 48px; -webkit-appearance: none; appearance: none; }
.jsearch input::-webkit-search-cancel-button { display: none; }
.jsearch-clear { border: 0; background: #eef1f5; color: var(--ink-2); width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; }
.jsearch-clear svg { width: 16px; height: 16px; }
.jlist { overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; display: grid; gap: 8px; padding-bottom: 6px; }
.jsec {
  position: sticky; top: 0; z-index: 1; padding: 8px 4px 4px; font-size: 13px; font-weight: 800; color: var(--blue);
  background: var(--bg); letter-spacing: .02em;
}
.jrow {
  display: grid; grid-template-columns: 1fr auto; grid-template-areas: "main badge" "sub badge"; align-items: center; column-gap: 10px;
  width: 100%; min-height: 64px; padding: 10px 14px; text-align: start; border-radius: 14px;
  border: 1.5px solid transparent; background: #fff; box-shadow: var(--shadow); color: var(--ink);
}
.jrow:active { transform: scale(.99); background: #f3f9fd; }
.jrow-main { grid-area: main; display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; }
.jrow-stroke { font-size: 18px; font-weight: 800; color: var(--navy); }
.jrow-cat { font-size: 15px; font-weight: 700; color: var(--blue); }
.jrow-sub { grid-area: sub; font-size: 13px; color: var(--ink-2); margin-top: 2px; }
.jrow-badge {
  grid-area: badge; min-width: 34px; height: 30px; padding: 0 8px; border-radius: 999px; display: grid; place-items: center;
  background: #eef3f9; color: var(--ink-2); font-size: 13px; font-weight: 800; font-family: var(--mono);
}
.jrow.is-done .jrow-badge { background: var(--ok-bg); color: var(--ok); }
.jrow.is-current { border-color: var(--cyan); background: #eaf6fc; }
.jrow.is-current .jrow-badge { background: var(--cyan); color: #fff; font-family: inherit; }
.jempty { text-align: center; color: var(--ink-3); padding: 24px 0; font-weight: 600; }

/* ---------- heat card v4: name-first hierarchy ---------- */
.heat-card { padding: 14px 14px 12px; border-top: 0; position: relative; overflow: hidden; }
.heat-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 5px; background: linear-gradient(90deg, var(--cyan), var(--blue)); }
.hc-swimmer { display: flex; align-items: center; gap: 12px; }
.hc-lane {
  flex: none; width: 60px; height: 64px; border-radius: 14px; background: var(--navy); color: #fff;
  display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1;
  box-shadow: inset 0 -3px 0 rgba(13,158,217,.8);
}
.hc-lane-cap { font-size: 11px; font-weight: 700; color: #9fd8f3; margin-bottom: 3px; }
.hc-lane-num { font-size: 32px; font-weight: 800; font-family: var(--mono); }
.hc-who { flex: 1; min-width: 0; }
.heat-card .swimmer-name {
  font-size: clamp(24px, 7.4vw, 30px); font-weight: 800; line-height: 1.1; color: var(--ink); overflow-wrap: anywhere;
}
.hc-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 12px; margin-top: 4px; }
.hc-club { font-size: 17px; font-weight: 700; color: var(--blue); }
.hc-year { font-size: 16px; color: var(--ink-2); white-space: nowrap; }
.hc-year b { font-family: var(--mono); color: var(--ink); font-size: 17px; }
.hc-cap { font-size: 13px; color: var(--ink-3); font-weight: 600; }
.hc-team { margin-top: 4px; font-size: 14px; color: var(--ink-2); line-height: 1.35; }
.hc-event {
  display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 12px; padding: 10px 12px;
  border-radius: 12px; background: #eaf4fb;
}
.hc-event-text { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; min-width: 0; }
.hc-stroke { font-size: 20px; font-weight: 800; color: var(--navy); }
.hc-cat { font-size: 17px; font-weight: 700; color: var(--blue); }
.hc-facts { display: grid; grid-template-columns: 1fr 1fr 1.2fr; gap: 8px; margin: 10px 0 0; }
.hc-fact { margin: 0; padding: 8px 10px; border-radius: 12px; background: #f4f7fb; border: 1px solid var(--line); min-width: 0; }
.hc-fact dt { font-size: 12px; font-weight: 700; color: var(--ink-3); }
.hc-fact dd { margin: 2px 0 0; font-size: 20px; font-weight: 800; color: var(--navy); font-family: var(--mono); text-align: right; white-space: nowrap; }
.hc-fact-heat { background: var(--blue); border-color: var(--blue); }
.hc-fact-heat dt { color: #bfe2f7; }
.hc-fact-heat dd { color: #fff; }
.hc-fact .seed { font-size: 17px; color: var(--ink-2); font-weight: 700; }
.hc-fact .seed:not(.is-nt) { color: var(--blue); }
.hc-foot { margin-top: 8px; font-size: 13px; color: var(--ink-3); font-weight: 600; }
.hc-foot [hidden] + .dot { display: none; }
.heat-card .saved-badge { flex: none; }
@media (max-width: 360px) {
  .hc-facts { grid-template-columns: 1fr 1fr; }
  .hc-facts .hc-fact:last-child { grid-column: 1 / -1; }
  .hc-lane { width: 52px; height: 58px; }
}
@media (max-height: 760px) {
  .heat-card { padding: 12px 12px 10px; }
  .hc-event { margin-top: 10px; padding: 8px 10px; }
  .hc-fact { padding: 6px 10px; }
}

/* ---------- entry head tools + focus button ---------- */
.entry-head-tools { display: inline-flex; align-items: center; gap: 8px; }
.focus-btn {
  width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line); background: #f3f7fc; color: var(--navy);
  display: grid; place-items: center;
}
.focus-btn svg { width: 22px; height: 22px; }
.focus-btn .ic-compress { display: none; }
.focus-btn[aria-pressed="true"] .ic-compress { display: block; }
.focus-btn[aria-pressed="true"] .ic-expand { display: none; }
.fs-lane, .fs-text, .fs-chip, .focus-queue, .focus-comment, .jump-manual, .sent-icon { display: none; }

/* ---------- scroll lock ---------- */
html.is-locked, body.is-locked { overflow: hidden; overscroll-behavior: none; }
body.is-locked { position: fixed; inset-inline: 0; width: 100%; }

/* ---------- focus (fullscreen) mode ---------- */
body.is-focus .topbar,
body.is-focus #dayTabs,
body.is-focus .queue-bar,
body.is-focus #view-judge > .progress,
body.is-focus #heatCard,
body.is-focus #manualCard,
body.is-focus .sub-actions { display: none !important; }
body.is-focus main { max-width: none; padding: 0; overflow: hidden; }
body.is-focus #view-judge {
  position: fixed; inset: 0; z-index: 30; animation: none;
  display: flex; flex-direction: column; gap: 6px; height: 100dvh;
  padding: calc(8px + env(safe-area-inset-top, 0px)) max(12px, env(safe-area-inset-right, 0px)) 0 max(12px, env(safe-area-inset-left, 0px));
  max-width: 600px; margin: 0 auto; overflow-y: auto; overscroll-behavior: contain;
}
body.is-focus .focus-queue {
  flex: none; display: flex; align-items: center; gap: 7px; min-height: 44px;
  border: 0; padding: 0 2px; background: none; color: var(--navy); font-size: 14px; white-space: nowrap;
}
.focus-queue bdi { font-family: var(--mono); font-weight: 800; }
.focus-queue svg { width: 16px; height: 16px; }
.focus-queue-label { color: var(--ink-2); font-weight: 600; }
.focus-queue-track { flex: 1; height: 4px; margin-inline-start: 3px; border-radius: 4px; overflow: hidden; background: var(--line); }
.focus-queue-track span { display: block; height: 100%; background: linear-gradient(90deg, var(--cyan-2), var(--cyan)); }
body.is-focus .jump-manual { display: inline-flex; flex: none; align-self: flex-start; min-height: 44px; padding: 0 12px; margin-bottom: 8px; }

body.is-focus .entry-card {
  flex: 1 0 auto; margin: 0; display: flex; flex-direction: column; gap: 6px;
  padding: 0; background: none; box-shadow: none;
}
body.is-focus .entry-head {
  display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 10px; align-items: center;
  margin: 0; padding: 8px 10px 6px; border-radius: 16px;
  background: var(--meet-tint, #EEF2FA); border-inline-start: 4px solid var(--navy);
}
body.is-focus .entry-mode-label { display: none; }
body.is-focus .entry-head-tools { margin-inline-start: auto; flex: none; }
body.is-focus .focus-btn { background: #fff; border: 1.5px solid #c9d3e0; }
.fs-lane {
  width: 62px; height: 72px; border-radius: 14px; background: var(--navy); color: #fff; line-height: 1;
  flex-direction: column; align-items: center; justify-content: center; gap: 3px;
}
.fs-lane span { color: #9fd8f3; font-size: 11px; font-weight: 700; }
.fs-lane bdi { font-family: var(--mono); font-size: 42px; font-weight: 800; }
.fs-text { min-width: 0; }
.fs-name, .fs-club, .fs-event { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fs-name { margin: 0; color: var(--navy); font-size: 32px; font-weight: 800; line-height: 1.12; }
.fs-club { margin: 2px 0 0; color: var(--ink-2); font-size: 14px; font-weight: 650; line-height: 1.2; }
#fsClub:not(:empty) + #fsYearWrap::before { content: ' · '; }
#fsYear { color: var(--ink); font-family: var(--mono); font-weight: 800; }
.fs-facts { display: flex; flex-wrap: wrap; grid-column: 1 / -1; grid-row: 2; align-items: center; gap: 6px; min-width: 0; }
.fs-event { margin: 2px 0 0; color: var(--blue); font-size: 15px; font-weight: 800; line-height: 1.2; }
.fs-chip {
  flex: none; align-items: center; gap: 5px; height: 34px; padding: 0 10px;
  border-radius: 10px; border: 1px solid #d5deec; background: #fff; color: var(--ink-2);
  font-size: 13px; font-weight: 700; white-space: nowrap;
}
.fs-chip bdi { font-family: var(--mono); font-size: 17px; color: var(--navy); }
.fs-chip-heat { background: var(--blue); border-color: var(--blue); color: #cfe8f8; }
.fs-chip-heat bdi { color: #fff; }
body.is-focus .fs-lane { display: flex; }
body.is-focus .fs-text { display: block; }
body.is-focus .fs-chip { display: inline-flex; }

body.is-focus .time-wrap, body.is-focus .status-row, body.is-focus .status-note, body.is-focus #relayLogligNote { margin: 0; }
body.is-focus .time-display {
  justify-content: space-between; border-radius: 14px; padding: 8px 4px 4px;
  font-size: clamp(30px, 12.5vw, 54px);
}
body.is-focus .status-row { flex-wrap: nowrap; align-items: stretch; gap: 8px; }
body.is-focus .status-row .field { flex: 1 1 0; }
body.is-focus .status-row .reason-field { flex-grow: 1.6; }
body.is-focus .status-row .field-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
body.is-focus .status-row select { min-height: 48px; padding: 0 8px; text-overflow: ellipsis; }
body.is-focus .focus-comment {
  flex: none; display: grid; place-items: center; width: 44px; min-height: 44px; padding: 0;
  border: 1.5px solid #c9d3e0; border-radius: 12px; background: #fff; color: var(--navy);
}
body.is-focus .focus-comment[aria-expanded="true"] { border-color: var(--cyan); background: #eaf6fc; }
body.is-focus .note-details, body.is-focus .note-details input { margin: 0; }
body.is-focus .note-details summary, body.is-focus .note-details:not([open]) { display: none; }
body.is-focus .note-details .reason-field { margin-top: 6px; }
body.is-focus .status-note, body.is-focus #relayLogligNote { padding: 6px 10px; font-size: 13px; line-height: 1.3; }

body.is-focus .timer-panel { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; gap: 10px; }
body.is-focus .timer-display { flex: 1 1 auto; display: grid; place-items: center; font-size: clamp(40px, 13vw, 76px); min-height: 90px; }
body.is-focus .timer-controls { flex: 1 1 auto; margin-top: 0; max-height: 220px; }
body.is-focus .btn-timer, body.is-focus .btn-timer-reset { min-height: 44px; height: 100%; font-size: 26px; }
body.is-focus .keypad { flex: 1 0 auto; grid-auto-rows: minmax(44px, 1fr); gap: 6px; }
body.is-focus .keypad button { min-height: 44px; font-size: 28px; }
body.is-focus .keypad button.k-aux { font-size: 15px; }
body.is-focus #view-judge .actions {
  position: static; flex: none; margin: 0; padding: 4px 0 calc(8px + var(--safe-b)); background: none;
  --nav-width: clamp(44px, 14.4vw, 56px);
  grid-template-columns: var(--nav-width) minmax(0, 1fr) minmax(0, 1.7fr) var(--nav-width);
}
body.is-focus #view-judge .actions .btn { min-height: 52px; }
body.is-focus .btn-nav span { display: none; }
body.is-focus #btnSubmit { background: var(--navy); box-shadow: 0 4px 14px rgba(0,31,72,.28); }
body.is-focus #btnSubmit.is-sent { background: #0f7d58; }
body.is-focus #btnSubmit.is-error { background: var(--danger); }
body.is-focus #btnSubmit.is-sent .send-icon { display: none; }
body.is-focus #btnSubmit.is-sent .sent-icon { display: block; }
body.is-focus .send-status { margin: 0; }
body.is-focus .send-status.is-sending, body.is-focus .send-status.is-sent {
  position: absolute; width: 1px; height: 1px; min-height: 0; overflow: hidden; clip-path: inset(50%);
}
body.is-focus .toast-wrap { bottom: calc(86px + var(--safe-b)); }
body.is-focus .banner { top: calc(12px + env(safe-area-inset-top, 0px)); }
@media (max-height: 640px) {
  body.is-focus #view-judge, body.is-focus .entry-card { gap: 4px; }
  body.is-focus #view-judge { padding-top: calc(4px + env(safe-area-inset-top, 0px)); }
  body.is-focus .entry-head { padding-block: 4px; row-gap: 0; }
  .fs-lane { width: 56px; height: 62px; }
  .fs-lane bdi { font-size: 38px; }
  .fs-name { font-size: 30px; }
  .fs-event { font-size: 14px; }
  .fs-chip { height: 30px; }
  body.is-focus .time-display { padding-top: 4px; }
  body.is-focus .status-row select { min-height: 44px; }
  body.is-focus .keypad { row-gap: 4px; }
  body.is-focus #view-judge .actions .btn { min-height: 46px; }
  body.is-focus .status-note, body.is-focus #relayLogligNote { padding: 3px 10px; line-height: 1.25; }
}

/* Meet operations share the deck client's light theme and touch targets. */
body.is-meet-management main { max-width: 1160px; }
.meet-hero { padding: 20px 0 24px; }
.meet-hero h1 { font-size: clamp(26px, 4vw, 36px); line-height: 1.25; margin: 8px 0; color: var(--navy); }
.meet-eyebrow { color: var(--blue); font-size: 13px; font-weight: 700; margin: 0; }
.meet-subtitle { color: var(--ink-2); margin: 0; line-height: 1.6; }
.meet-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 28px; align-items: start; }
.meet-menu { display: grid; gap: 8px; padding: 8px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; }
.meet-menu-link { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 12px; border-radius: 10px; text-decoration: none; color: var(--ink-2); }
.meet-menu-link:hover { background: var(--bg); color: var(--navy); }
.meet-menu-link[aria-current="page"] { color: var(--card); background: var(--navy); font-weight: 700; }
.meet-menu-link:focus-visible, .meet-shortcuts a:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.meet-content { min-width: 0; }
.meet-section-title { margin: 0 0 4px; font-size: 24px; color: var(--navy); }
.meet-download { display: inline-flex; padding: 12px 16px; margin-bottom: 20px; text-decoration: none; }
.meet-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0 0 24px; }
.meet-stats > div { display: flex; flex-direction: column-reverse; gap: 4px; padding: 16px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; }
.meet-stats dt { color: var(--ink-2); font-size: 14px; }
.meet-stats dd { margin: 0; font-size: 30px; font-weight: 700; color: var(--navy); font-variant-numeric: tabular-nums; }
.meet-shortcuts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-bottom: 24px; }
.meet-shortcuts .resource-link { padding: 20px; color: var(--navy); font-weight: 700; transition: border-color .15s, background .15s; }
.meet-shortcuts .resource-link:hover { background: var(--bg); border-color: var(--blue); }
.meet-shortcuts .resource-link svg { display: block; width: 24px; height: 24px; margin-bottom: 16px; color: var(--blue); }
.meet-shortcuts .resource-link small { font-weight: 400; line-height: 1.6; }
.meet-content summary { cursor: pointer; min-height: 44px; padding-block: 10px; font-weight: 600; }
.meet-content details[open] > summary { margin-bottom: 12px; }
.meet-danger { border: 1px solid var(--danger); }
.meet-danger > summary { color: var(--danger); }
.meet-danger .portal-card { padding: 0; box-shadow: none; margin: 0; }
.meet-write-row { padding-block: 16px; border-bottom: 1px solid var(--line); line-height: 1.6; }
.meet-write-link { display: block; color: var(--blue); margin-bottom: 6px; }
.meet-write-row button { display: block; margin-top: 8px; }
.meet-status-filter { min-height: 44px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); width: 100%; }
@media (max-width: 760px) {
  .meet-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .meet-menu { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; }
  .meet-menu-link { flex-direction: column; justify-content: center; text-align: center; gap: 6px; padding: 10px 4px; font-size: 13px; }
  .meet-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .meet-stats > div { padding: 12px; }
  .meet-hero { padding-top: 8px; }
  .meet-shortcuts { gap: 8px; }
  .meet-shortcuts .resource-link { padding: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .view { animation: none; }
  .meet-shortcuts .resource-link { transition: none; }
}
.topbar { flex-wrap: wrap; }
.global-nav { display: flex; gap: 6px; flex-wrap: wrap; }
.global-nav .top-btn { display: inline-flex; align-items: center; text-decoration: none; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; font-size: 13px; overflow-wrap: anywhere; }
.breadcrumbs a, .resource-link, .sheet a, .results-table a, .entry-facts a { color: var(--blue); text-underline-offset: 3px; }
.breadcrumbs span::before { content: "/"; margin-inline-end: 6px; color: var(--ink-3); }
.portal-card { padding: 18px; margin: 12px 0; min-width: 0; }
.portal-card h2 { margin: 0 0 12px; font-size: 20px; color: var(--navy); }
.portal-card p { margin: 8px 0; line-height: 1.5; overflow-wrap: anywhere; }
.portal-form { display: grid; gap: 12px; }
.portal-form input, .portal-form select, .portal-form textarea, .note-details input {
  width: 100%; min-width: 0; min-height: 48px; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff;
}
.portal-form textarea { min-height: 130px; font-family: var(--mono); font-size: 13px; }
.portal-form .field { flex: auto; }
.portal-form .check-field { display: flex; align-items: flex-start; gap: 8px; line-height: 1.4; }
.portal-form .check-field input { width: 20px; min-height: 20px; margin-top: 3px; flex: none; }
.portal-form .btn { padding: 10px 16px; }
.form-error { color: var(--danger); font-weight: 600; white-space: pre-wrap; overflow-wrap: anywhere; }
form[data-delete-meet] button[type="submit"], #resetTestDataForm button[type="submit"] {
  background: var(--danger); box-shadow: none;
}
.notice { background: #eaf4fb; padding: 12px; border-radius: 12px; color: var(--navy); line-height: 1.5; overflow-wrap: anywhere; }
.notice.warning { background: var(--amber-bg); color: #825416; }
.resource-list { display: grid; gap: 10px; padding: 0; list-style: none; margin: 12px 0; }
.resource-link { display: block; padding: 14px; background: #fff; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; line-height: 1.4; }
.resource-link:hover { border-color: var(--cyan); }
.resource-link small { display: block; color: var(--ink-2); margin-top: 5px; }
.resource-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.resource-actions .btn { padding: 8px 14px; font-size: 15px; }
.metadata { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; line-height: 1.5; }
.metadata dt { color: var(--ink-2); }
.metadata dd { margin: 0; overflow-wrap: anywhere; }
.qr-panel { text-align: center; }
.qr-panel img { width: min(100%, 320px); height: auto; display: block; margin: 10px auto; }
.qr-panel a { display: block; direction: ltr; overflow-wrap: anywhere; color: var(--blue); }
.qr-panel .notice { text-align: start; }
.qr-invite-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 16px; align-items: center; }
.qr-invite-details { min-width: 0; text-align: start; }
.qr-invite-details .qr-invite-label { color: var(--navy); font-size: 14px; font-weight: 700; }
.qr-panel .qr-invite-link { padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: #fff; text-align: left; word-break: break-all; user-select: text; -webkit-user-select: text; }
.qr-invite-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.qr-invite-actions .btn { flex: 1 1 140px; min-height: 44px; padding: 8px 12px; font-size: 15px; }
.qr-invite-status { color: var(--ink-2); font-size: 14px; }
.qr-invite-status:empty { display: none; }
@media (max-width: 640px) { .qr-invite-layout { grid-template-columns: minmax(0, 1fr); } }
.lane-management { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.lane-management .btn { width: 100%; font-size: 15px; padding: 8px; }
.lane-management .lane-manage-card { padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.lane-management p { font-size: 13px; min-height: 20px; color: var(--ink-2); }
.entry-facts { margin-bottom: 12px; display: grid; gap: 8px; font-size: 14px; }
.entry-facts:empty { display: none; }
.entry-facts details { padding: 10px; background: #fff; border-radius: 10px; }
.entry-facts summary { cursor: pointer; min-height: 32px; }
.search-matches { display: grid; gap: 6px; max-height: 280px; overflow-y: auto; }
.search-match { border: 1px solid var(--line); border-radius: 10px; background: #fff; text-align: start; padding: 10px; min-height: 48px; }
.search-match small { display: block; color: var(--ink-2); }
#btnReserveSpecial { margin-top: 12px; width: 100%; font-size: 14px; min-height: 44px; }
.manual-grid input:read-only { background: #f3f7fc; color: var(--ink-2); }
.note-details { margin: 0 0 12px; font-size: 13px; color: var(--ink-2); }
.note-details summary { min-height: 32px; cursor: pointer; }
.note-details input { margin-top: 6px; }
.status-select.is-DNF, .status-note.is-DNF { color: var(--amber); background: var(--amber-bg); }
.status-select.is-EXH, .status-note.is-EXH { color: var(--blue); background: #eaf4fb; }
.outside-results { border-top: 2px solid var(--line); margin-top: 28px; padding-top: 12px; }
.outside-results h2 { font-size: 22px; color: var(--navy); }
.outside-results h3 { font-size: 17px; }
.audit-row { padding: 8px 0; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
body.is-focus .breadcrumbs, body.is-focus .entry-facts { display: none !important; }
@media (max-width: 420px) {
  .brand { width: 100%; }
  .global-nav { margin-top: 2px; }
  .metadata { gap: 6px 10px; font-size: 14px; }
  .portal-card { padding: 14px; }
}

html { scrollbar-gutter: stable; }
.topbar { flex-wrap: nowrap; gap: 12px; min-height: 64px; }
.topbar .brand { width: auto; flex: 1; min-width: 0; }
.topbar .brand-title { line-height: 1.4; }
.site-menu-toggle { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 12px; flex: none; border: 1px solid var(--ink-3); border-radius: 10px; background: var(--navy-2); color: var(--card); }
.site-menu-toggle:focus-visible { outline: 2px solid var(--card); outline-offset: 3px; }
.has-site-menu { overflow: hidden; }
.site-menu { position: fixed; inset-block: 0; inset-inline-start: 0; inset-inline-end: auto; margin: 0; width: min(380px, calc(100vw - 24px)); height: 100dvh; max-height: 100dvh; max-width: none; padding: calc(20px + env(safe-area-inset-top, 0px)) 20px calc(20px + var(--safe-b)); border: 0; border-inline-end: 1px solid var(--line); background: var(--card); color: var(--ink); overflow-y: auto; overscroll-behavior: contain; }
.site-menu::backdrop { background: var(--navy); opacity: .4; }
.site-menu-heading { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.site-menu-heading h2 { margin: 0; color: var(--navy); font-size: 24px; }
.menu-close { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); }
.menu-close svg { width: 22px; height: 22px; }
.menu-identity { display: flex; align-items: center; gap: 12px; margin: 16px 0 18px; min-width: 0; }
.menu-avatar { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--navy); color: var(--card); font-weight: 800; font-size: 16px; flex: none; }
.menu-identity-text { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; min-width: 0; }
.menu-identity-name { color: var(--ink); font-weight: 700; font-size: 15px; line-height: 1.3; overflow-wrap: anywhere; }
.menu-role { display: inline-flex; align-items: center; min-height: 22px; padding: 0 8px; border-radius: 999px; background: var(--bg); color: var(--navy); font-size: 12px; font-weight: 700; }
.meet-empty-hint { display: block; margin: 0 0 8px; padding: 10px 12px; border-radius: 10px; background: var(--bg); color: var(--blue); text-decoration: none; font-size: 14px; line-height: 1.45; }
.meet-empty-hint:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.meet-block { margin: 0 0 4px; }
.meet-card { background: var(--meet-tint); border-inline-start: 4px solid var(--navy); border-radius: 14px; padding: 12px 12px 6px; }
.meet-card-name { margin: 0; color: var(--navy); font-size: 16px; font-weight: 800; line-height: 1.35; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.meet-card-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 8px; color: var(--ink-2); font-size: 13px; line-height: 1.3; }
.meet-card-date { direction: ltr; unicode-bidi: isolate; }
.meet-status { display: inline-flex; align-items: center; min-height: 24px; padding: 0 8px; border-radius: 999px; background: #fff; color: var(--navy); font-size: 12px; font-weight: 700; }
.meet-status.is-today { background: var(--ok-bg); color: var(--ok); }
.meet-status.is-future { background: #fff; color: var(--blue); }
.meet-status.is-past { background: #fff; color: var(--ink-2); }
.meet-lane-chip { display: inline-flex; align-items: center; gap: 4px; min-height: 36px; padding: 0 10px; border: 0; border-radius: 999px; background: var(--navy); color: #fff; font-size: 13px; font-weight: 700; }
.meet-lane-num { font-family: var(--mono); }
.site-block-rule { height: 1px; margin: 16px -20px 0; background: var(--line); }
.site-block .menu-group-title { margin: 14px 4px 6px; color: var(--ink-3); font-size: 12px; font-weight: 700; }
.site-menu .global-nav, #siteMeetNav { display: grid; gap: 2px; width: 100%; }
#siteMeetNav { margin-top: 8px; }
.site-menu-link { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 48px; padding: 8px 12px; border: 0; border-radius: 10px; background: transparent; color: var(--ink); text-align: start; text-decoration: none; font-size: 16px; }
.site-menu-link > svg { width: 24px; height: 24px; stroke-width: 1.75; color: var(--ink-2); }
.menu-link-copy { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; min-width: 0; flex: 1; }
.menu-link-label { line-height: 1.3; color: inherit; }
.menu-link-sub { display: flex; align-items: center; gap: 6px; color: var(--ink-2); font-size: 12px; font-weight: 500; line-height: 1.3; }
.menu-status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ink-3); flex: none; }
.menu-status-dot.is-on { background: var(--ok); }
.menu-loglig-badge { display: inline-flex; align-items: center; margin-inline-start: auto; flex: none; }
.menu-loglig-badge .loglig-mark { font-size: 14px; }
.site-menu-link:hover { background: var(--bg); }
.meet-card .site-menu-link:hover { background: rgba(0, 31, 72, .06); }
.site-menu-link[aria-current="page"], .site-menu-link.is-active { color: var(--card); background: var(--navy); }
.site-menu-link[aria-current="page"] > svg, .site-menu-link.is-active > svg { color: var(--card); }
.site-menu-link[aria-current="page"] .menu-link-sub, .site-menu-link.is-active .menu-link-sub { color: rgba(255, 255, 255, .82); }
.site-menu-link[aria-current="page"] .menu-status-dot, .site-menu-link.is-active .menu-status-dot { background: rgba(255, 255, 255, .75); }
.site-menu-link[aria-current="page"] .menu-status-dot.is-on, .site-menu-link.is-active .menu-status-dot.is-on { background: #8ee4b6; }
.site-menu-link[aria-current="page"] .menu-loglig-badge, .site-menu-link.is-active .menu-loglig-badge { background: #fff; border-radius: 999px; padding: 3px 7px; }
.site-menu-link:focus-visible, .menu-close:focus-visible, .meet-lane-chip:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.site-menu-footer { padding-top: 8px; margin-top: 12px; }
.menu-icon { width: 24px; height: 24px; stroke-width: 1.75; }
[dir="rtl"] .menu-icon-exit { transform: scaleX(-1); }
.loglig-mark {
  display: inline-flex; align-items: center; gap: 5px; color: var(--loglig);
  font-weight: 800; line-height: 1; flex: none;
}
.loglig-mark svg { width: 1.15em; height: 1.15em; fill: currentColor; stroke: none; stroke-width: 0; }
.loglig-mark-word { font-weight: 800; letter-spacing: -0.03em; font-size: 1em; }
.loglig-page-title { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.portal-card.loglig-card {
  padding: 0; background: #fff; color: var(--loglig-ink);
  border: 1px solid #f3c2ae; overflow: hidden;
}
.loglig-card-bar { height: 8px; background: var(--loglig); }
.loglig-card-head {
  display: flex; align-items: center; gap: 8px; padding: 14px 16px 0; background: #fff;
}
.loglig-card-head h2 { margin: 0; color: var(--loglig-ink); font-size: 20px; }
.loglig-card-body { padding: 8px 16px 16px; color: var(--loglig-ink); }
.loglig-card-body p, .loglig-explain { color: var(--loglig-ink); }
.loglig-explain { margin: 8px 0 12px; padding-inline-start: 1.2em; }
.loglig-explain li { margin: 6px 0; line-height: 1.45; }
.loglig-connection {
  display: flex; align-items: center; gap: 8px; margin: 8px 0;
  padding: 8px 10px; border: 1.5px solid var(--loglig); border-radius: 12px;
  background: #fff; color: var(--loglig-ink); font-weight: 700;
}
.btn-loglig {
  background: var(--loglig); color: var(--loglig-ink); border: 0;
  box-shadow: 0 4px 14px rgba(242, 101, 34, .28);
}
.btn-loglig-ghost {
  background: #fff; color: var(--loglig-ink); border: 2px solid var(--loglig);
}
.loglig-review {
  margin: 12px 0; padding: 12px; border: 1.5px solid var(--loglig); border-radius: 14px;
  background: #fff; color: var(--loglig-ink);
}
.loglig-review h3 { margin: 0 0 6px; font-size: 18px; color: var(--navy); }
.loglig-review-note { margin: 0 0 10px; line-height: 1.45; }
.loglig-review-card { margin-top: 10px; padding-top: 10px; border-top: 1px solid #f3c2ae; }
.loglig-review-seed, .loglig-review-observed { margin: 0 0 8px; line-height: 1.45; }
.loglig-candidate { margin-top: 8px; padding: 8px 10px; border-radius: 12px; background: #fff7f3; }
.loglig-candidate p { margin: 0 0 8px; line-height: 1.45; }
.loglig-card .btn-loglig,
.loglig-card .btn-loglig-ghost { width: 100%; }
.loglig-card .btn-loglig-ghost { margin-top: 8px; }
.site-menu-link[aria-current="page"] .loglig-mark,
.site-menu-link.is-active .loglig-mark,
.meet-menu-link[aria-current="page"] .loglig-mark { color: var(--loglig); }
.site-menu-link[aria-current="page"] .loglig-mark svg,
.site-menu-link.is-active .loglig-mark svg,
.meet-menu-link[aria-current="page"] .loglig-mark svg { color: var(--loglig); fill: var(--loglig); }
a.loglig-link {
  display: flex; align-items: center; gap: 8px; width: fit-content; max-width: 100%;
  margin: 8px 0; padding: 10px 12px; background: #fff; color: var(--loglig-ink);
  border: 1.5px solid var(--loglig); border-radius: 12px; text-decoration: none; font-weight: 700;
}
.source-note a.loglig-link { display: inline-flex; }
.site-menu #btnLogout { color: var(--danger); font-weight: 600; }
.site-menu #btnLogout:hover { background: var(--danger-bg); }
.site-menu #btnLogout svg { color: inherit; }
@media (prefers-reduced-motion: reduce) {
  .loading::after { animation: none; width: 100%; }
}
