    :root {
      --bg: #fbf7f2;
      --card: rgba(255, 255, 255, 0.94);
      --card-solid: #ffffff;
      --border: #ecdccf;
      --text: #16120f;
      --muted: #7a685d;
      --muted-light: #b59d8b;
      --accent: #fc5200;
      --accent-strong: #c2410c;
      --accent-soft: #fff1e7;
      --danger-soft: #fff2f2;
      --danger-border: #f0b7b7;
      --danger-text: #b34b4b;
      --shadow: 0 18px 60px rgba(143, 63, 18, 0.09);
    }

    html[data-theme="dark"] {
      --bg: #07111f;
      --card: rgba(12, 23, 40, 0.9);
      --card-solid: #0f1b2d;
      --border: #233650;
      --text: #edf4ff;
      --muted: #9bb0cc;
      --muted-light: #6f88ab;
      --accent: #4da3ff;
      --accent-strong: #82c0ff;
      --accent-soft: rgba(77, 163, 255, 0.12);
      --accent-warm: #d97706;
      --accent-warm-strong: #f59e0b;
      --danger-soft: rgba(108, 31, 54, 0.32);
      --danger-border: #7a3652;
      --danger-text: #ffb8c8;
      --shadow: 0 24px 60px rgba(0, 5, 18, 0.38);
    }

    * {
      box-sizing: border-box;
    }

    html, body {
      margin: 0;
      padding: 0;
      background:
        radial-gradient(circle at top left, color-mix(in srgb, var(--accent) 14%, transparent), transparent 34%),
        radial-gradient(circle at top right, color-mix(in srgb, var(--accent) 10%, transparent), transparent 28%),
        linear-gradient(180deg, color-mix(in srgb, var(--bg) 65%, white) 0%, var(--bg) 100%);
      color: var(--text);
      font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    }

    button,
    input,
    summary {
      font: inherit;
    }

    .page {
      position: relative;
      min-height: 100vh;
      max-width: 64rem;
      margin: 0 auto;
      display: flex;
      flex-direction: column;
      padding: 40px 24px;
    }

    .hero {
      margin-bottom: 40px;
      opacity: 0;
      transform: translateY(10px);
      animation: fadeUp 0.35s ease forwards;
    }

    .hero-brand {
      position: absolute;
      top: 18px;
      right: -26px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 110px;
      height: 110px;
      margin-bottom: 0;
      background: radial-gradient(circle at 50% 50%, rgba(252, 82, 0, 0.08), rgba(252, 82, 0, 0) 68%);
      pointer-events: none;
      z-index: 0;
    }

    .stopwatch-logo {
      position: relative;
      width: 68px;
      height: 68px;
      color: var(--accent-strong);
      transform: translate(2px, 2px);
      opacity: 0.5;
    }

    .stopwatch-ring {
      position: absolute;
      inset: 10px;
      border-radius: 999px;
      border: 4px solid currentColor;
      box-shadow: inset 0 0 0 6px rgba(252, 82, 0, 0.05);
    }

    .stopwatch-crown,
    .stopwatch-button,
    .stopwatch-hand-long,
    .stopwatch-hand-short,
    .stopwatch-center,
    .stopwatch-base {
      position: absolute;
      border-radius: 999px;
      background: currentColor;
      transform-origin: center center;
    }

    .stopwatch-crown {
      top: 1px;
      left: 29px;
      width: 10px;
      height: 10px;
      border-radius: 4px;
    }

    .stopwatch-button {
      top: 7px;
      left: 43px;
      width: 8px;
      height: 14px;
      border-radius: 4px;
      transform: rotate(35deg);
      opacity: 0.86;
    }

    .stopwatch-hand-long {
      top: 29px;
      left: 33px;
      width: 3px;
      height: 20px;
      border-radius: 999px;
      transform: rotate(34deg);
      animation: stopwatchSweepLong 18s linear infinite;
    }

    .stopwatch-hand-short {
      top: 28px;
      left: 33px;
      width: 3px;
      height: 14px;
      border-radius: 999px;
      transform: rotate(-52deg);
      animation: stopwatchSweepShort 60s linear infinite;
    }

    .stopwatch-center {
      top: 31px;
      left: 31px;
      width: 8px;
      height: 8px;
      border-radius: 999px;
      box-shadow: 0 0 0 6px rgba(252, 82, 0, 0.035);
    }

    .stopwatch-base {
      left: 17px;
      right: 13px;
      bottom: 10px;
      height: 2px;
      background: linear-gradient(90deg, rgba(252, 82, 0, 0), rgba(252, 82, 0, 0.28), rgba(252, 82, 0, 0));
    }

    .stopwatch-tick {
      position: absolute;
      top: 15px;
      left: 33px;
      width: 2px;
      height: 5px;
      border-radius: 999px;
      background: currentColor;
      transform-origin: center 19px;
      opacity: 0.82;
    }

    .badge {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      margin-bottom: 16px;
      border: 1px solid rgba(252, 82, 0, 0.16);
      background: rgba(255, 247, 240, 0.92);
      color: var(--accent-strong);
      border-radius: 999px;
      padding: 6px 12px;
      font-size: 12px;
      letter-spacing: 0.04em;
      box-shadow: 0 10px 24px rgba(252, 82, 0, 0.08);
      backdrop-filter: blur(12px);
    }

    .badge-link {
      color: inherit;
      text-decoration: none;
    }

    .badge-link:hover {
      color: var(--accent);
    }

    .badge-separator {
      color: rgba(194, 65, 12, 0.38);
    }

    .badge-icon {
      width: 14px;
      height: 14px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      font-size: 12px;
    }

    h1 {
      max-width: 42rem;
      margin: 0;
      font-size: clamp(2.5rem, 7vw, 3.75rem);
      line-height: 1;
      letter-spacing: -0.04em;
      font-weight: 600;
      color: var(--text);
    }

    .hero p {
      margin: 16px 0 0;
      max-width: 36rem;
      font-size: clamp(1rem, 2.5vw, 1.125rem);
      line-height: 1.75;
      color: var(--muted);
    }

    .input-wrap {
      margin-bottom: 32px;
      opacity: 0;
      transform: translateY(14px);
      animation: fadeUp 0.35s ease 0.05s forwards;
    }

    .panel {
      position: relative;
      overflow: hidden;
      background: linear-gradient(180deg, color-mix(in srgb, var(--card-solid) 94%, white), color-mix(in srgb, var(--card-solid) 88%, var(--bg)));
      border: 1px solid rgba(236, 220, 207, 0.95);
      border-radius: 28px;
      padding: 16px;
      box-shadow: var(--shadow);
    }

    .panel::after {
      content: "";
      position: absolute;
      inset: -40% auto auto 68%;
      width: 180px;
      height: 180px;
      border-radius: 999px;
      background: radial-gradient(circle, rgba(252, 82, 0, 0.12), rgba(252, 82, 0, 0));
      pointer-events: none;
    }

    .panel-inner {
      position: relative;
      display: flex;
      flex-direction: column;
      gap: 16px;
      z-index: 1;
    }

    .utility-btn {
      border: 1px solid rgba(252, 82, 0, 0.14);
      background: rgba(255, 247, 240, 0.78);
      color: #7a4a2d;
      border-radius: 999px;
      padding: 7px 12px;
      font-size: 0.82rem;
      cursor: pointer;
      transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
      white-space: nowrap;
    }

    .utility-btn:hover {
      transform: translateY(-1px);
      background: rgba(255, 236, 224, 0.96);
    }

    .utility-btn.is-copied {
      background: linear-gradient(180deg, #ffffff, #fff1e7);
      border-color: rgba(252, 82, 0, 0.42);
      box-shadow: 0 14px 28px rgba(252, 82, 0, 0.14);
      color: var(--accent-strong);
    }

    .input-row {
      display: flex;
      align-items: center;
      gap: 12px;
      border: 1px solid var(--border);
      border-radius: 16px;
      padding: 12px 16px;
      background: rgba(255, 255, 255, 0.78);
      transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
    }

    .input-row:focus-within {
      border-color: rgba(252, 82, 0, 0.45);
      box-shadow: 0 0 0 4px rgba(252, 82, 0, 0.11);
      background: #ffffff;
    }

    html[data-theme="dark"] .input-row {
      border-color: rgba(130, 192, 255, 0.16);
      background: linear-gradient(180deg, rgba(11, 22, 38, 0.94), rgba(16, 31, 52, 0.9));
      box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.02);
    }

    html[data-theme="dark"] .input-row:focus-within {
      border-color: rgba(245, 158, 11, 0.34);
      box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.1);
      background: linear-gradient(180deg, rgba(13, 26, 45, 0.98), rgba(22, 39, 64, 0.94));
    }

    html[data-theme="dark"] .pace-input {
      color: #f3f8ff;
    }

    html[data-theme="dark"] .pace-input::placeholder {
      color: #7f97ba;
    }

    html[data-theme="dark"] .leading-icon,
    html[data-theme="dark"] .reset-icon {
      color: #7e96b8;
    }

    html[data-theme="dark"] .ghost-btn:hover {
      background: rgba(77, 163, 255, 0.12);
    }

    .leading-icon,
    .copy-icon,
    .reset-icon,
    .panel-chevron {
      color: var(--muted-light);
      flex-shrink: 0;
      display: inline-flex;
      align-items: center;
      justify-content: center;
    }

    .leading-icon {
      width: 20px;
      height: 20px;
      font-size: 18px;
    }

    .reset-icon {
      width: 16px;
      height: 16px;
      font-size: 14px;
    }

    .copy-icon {
      width: 16px;
      height: 16px;
      font-size: 13px;
    }

    .pace-input {
      width: 100%;
      min-width: 0;
      border: 0;
      outline: 0;
      background: transparent;
      font-size: 1.125rem;
      color: var(--text);
    }

    .pace-input::placeholder {
      color: var(--muted-light);
    }

    .ghost-btn {
      width: 36px;
      height: 36px;
      border: 0;
      border-radius: 999px;
      background: transparent;
      cursor: pointer;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      transition: background 0.15s ease;
    }

    .ghost-btn:hover {
      background: var(--accent-soft);
    }

    .unit-rail {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      align-items: center;
    }

    .unit-rail-label {
      font-size: 0.8rem;
      color: var(--muted-light);
      letter-spacing: 0.04em;
    }

    .unit-pill {
      border: 1px solid rgba(252, 82, 0, 0.14);
      background: rgba(255, 247, 240, 0.76);
      color: #7a4a2d;
      border-radius: 999px;
      padding: 7px 11px;
      font-size: 0.82rem;
      cursor: pointer;
      transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    }

    .unit-pill:hover {
      transform: translateY(-1px);
      background: rgba(255, 236, 224, 0.96);
    }

    .unit-pill.is-active {
      background: linear-gradient(180deg, rgba(252, 82, 0, 0.95), rgba(194, 65, 12, 0.96));
      color: #fff7f2;
      border-color: rgba(194, 65, 12, 0.72);
      box-shadow: 0 10px 20px rgba(194, 65, 12, 0.14);
    }

    .unit-rail-hint {
      display: none;
      margin-left: auto;
      font-size: 0.76rem;
      color: var(--muted-light);
      letter-spacing: 0.03em;
      white-space: nowrap;
    }

    .chips {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
    }

    .chip {
      border: 1px solid rgba(252, 82, 0, 0.14);
      background: rgba(255, 247, 240, 0.86);
      color: #7a4a2d;
      border-radius: 999px;
      padding: 6px 12px;
      font-size: 0.875rem;
      cursor: pointer;
      transition: background 0.15s ease, transform 0.15s ease;
    }

    .chip:hover {
      background: rgba(255, 236, 224, 0.96);
      transform: translateY(-1px);
    }

    .helper {
      font-size: 0.875rem;
      color: var(--muted);
    }

    .prefill-tip {
      display: none;
      align-items: center;
      justify-content: space-between;
      gap: 10px;
      padding: 8px 10px;
      border-radius: 14px;
      border: 1px solid rgba(252, 82, 0, 0.12);
      background: rgba(255, 250, 246, 0.92);
      color: var(--muted);
      box-shadow: 0 12px 22px rgba(143, 63, 18, 0.06);
      backdrop-filter: blur(10px);
      opacity: 0;
      transform: translateY(6px);
      transition: opacity 0.28s ease, transform 0.28s ease;
    }

    .prefill-tip[hidden] {
      display: none !important;
    }

    .prefill-tip.is-visible {
      opacity: 1;
      transform: translateY(0);
    }

    .prefill-tip.is-hiding {
      opacity: 0;
      transform: translateY(-4px);
    }

    .prefill-tip-copy {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      min-width: 0;
      flex-wrap: wrap;
    }

    .prefill-tip-eyebrow {
      font-size: 0.66rem;
      text-transform: uppercase;
      letter-spacing: 0.16em;
      color: var(--accent-strong);
      white-space: nowrap;
    }

    .prefill-tip-text {
      font-size: 0.79rem;
      line-height: 1.35;
      color: var(--muted);
    }

    .prefill-tip-text strong {
      color: var(--accent-strong);
      font-weight: 600;
    }

    .prefill-tip-close {
      width: 24px;
      height: 24px;
      border: 0;
      border-radius: 999px;
      background: transparent;
      color: var(--muted-light);
      cursor: pointer;
      font-size: 0.95rem;
      line-height: 1;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      flex-shrink: 0;
      transition: background 0.15s ease, color 0.15s ease;
    }

    .prefill-tip-close:hover {
      background: rgba(252, 82, 0, 0.08);
      color: var(--accent-strong);
    }

    .recent-wrap {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
      align-items: center;
    }

    .recent-wrap:empty {
      display: none;
    }

    .recent-label {
      font-size: 0.76rem;
      text-transform: uppercase;
      letter-spacing: 0.14em;
      color: var(--muted-light);
    }

    .recent-chip {
      border: 1px solid rgba(252, 82, 0, 0.12);
      background: rgba(255, 255, 255, 0.72);
      color: #7a4a2d;
      border-radius: 999px;
      padding: 6px 11px;
      font-size: 0.8rem;
      cursor: pointer;
      transition: background 0.15s ease, transform 0.15s ease, border-color 0.15s ease;
    }

    .recent-chip:hover {
      background: rgba(255, 241, 231, 0.96);
      transform: translateY(-1px);
      border-color: rgba(252, 82, 0, 0.18);
    }

    .recent-clear {
      margin-left: auto;
      border: 1px solid rgba(252, 82, 0, 0.12);
      background: transparent;
      color: var(--muted-light);
      border-radius: 999px;
      padding: 6px 10px;
      font-size: 0.76rem;
      cursor: pointer;
      transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
    }

    .recent-clear:hover {
      background: rgba(255, 241, 231, 0.96);
      color: var(--accent-strong);
      border-color: rgba(252, 82, 0, 0.22);
    }

    .results {
      display: grid;
      gap: 16px;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      margin-bottom: 0;
    }

    .section-divider {
      position: relative;
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 14px;
      padding: 30px 0 26px;
      color: rgba(188, 143, 115, 0.9);
      border: 0;
      width: 100%;
      background: transparent;
      cursor: pointer;
    }

    .section-divider::before,
    .section-divider::after {
      content: "";
      flex: 1;
      max-width: 180px;
      height: 1px;
      background: linear-gradient(90deg, rgba(252, 82, 0, 0), rgba(252, 82, 0, 0.28), rgba(252, 82, 0, 0));
    }

    .section-divider-dots {
      display: inline-flex;
      align-items: center;
      gap: 8px;
    }

    .section-divider-dots span {
      width: 6px;
      height: 6px;
      border-radius: 999px;
      background: rgba(252, 82, 0, 0.44);
      box-shadow: 0 0 0 6px rgba(252, 82, 0, 0.03);
      animation: dividerPulse 2.8s ease-in-out infinite;
    }

    .section-divider-dots span:nth-child(2) {
      animation-delay: 0.25s;
    }

    .section-divider-dots span:nth-child(3) {
      animation-delay: 0.5s;
    }

    .section-divider:hover .section-divider-dots span {
      background: rgba(194, 65, 12, 0.52);
    }

    .divider-label {
      display: none;
    }

    .section-divider:focus-visible {
      outline: none;
    }

    .section-divider.is-game::before,
    .section-divider.is-game::after,
    .section-divider.is-game .section-divider-dots,
    .section-divider.is-game .divider-label {
      opacity: 0;
      transition: opacity 0.18s ease;
    }

    .divider-game {
      position: absolute;
      inset: 0;
      display: none;
      align-items: center;
      justify-content: center;
      border-radius: 18px;
      overflow: hidden;
      background: linear-gradient(180deg, rgba(255, 249, 244, 0.96), rgba(255, 241, 231, 0.98));
      box-shadow: inset 0 0 0 1px rgba(252, 82, 0, 0.12);
    }

    .section-divider.is-game {
      min-height: 138px;
      padding: 46px 0 42px;
    }

    .section-divider.is-game .divider-game {
      display: flex;
    }

    .divider-game-track {
      position: absolute;
      inset: 16px 0 14px;
      overflow: hidden;
    }

    .divider-game-track::before,
    .divider-game-track::after {
      content: "";
      position: absolute;
      left: 0;
      right: 0;
      height: 1px;
      background: linear-gradient(90deg, rgba(252, 82, 0, 0), rgba(252, 82, 0, 0.24), rgba(252, 82, 0, 0));
    }

    .divider-game-track::before {
      top: 18px;
    }

    .divider-game-track::after {
      bottom: 16px;
    }

    .divider-game-ground {
      position: absolute;
      left: 0;
      right: 0;
      bottom: 24px;
      height: 2px;
      background: linear-gradient(90deg, rgba(252, 82, 0, 0), rgba(252, 82, 0, 0.4), rgba(252, 82, 0, 0));
    }

    .divider-game-runner {
      position: absolute;
      bottom: 26px;
      left: 56px;
      width: 28px;
      height: 28px;
      color: rgba(194, 65, 12, 0.96);
      will-change: transform;
      filter: drop-shadow(0 8px 12px rgba(194, 65, 12, 0.16));
    }

    .divider-game-runner .runner-head {
      position: absolute;
      top: 1px;
      left: 15px;
      width: 7px;
      height: 7px;
      border-radius: 999px;
      background: currentColor;
    }

    .divider-game-runner .runner-body,
    .divider-game-runner .runner-arm,
    .divider-game-runner .runner-leg-front,
    .divider-game-runner .runner-leg-back {
      position: absolute;
      border-radius: 999px;
      background: currentColor;
      transform-origin: left center;
    }

    .divider-game-runner .runner-body {
      top: 8px;
      left: 10px;
      width: 11px;
      height: 3px;
      transform: rotate(-28deg);
    }

    .divider-game-runner .runner-arm {
      top: 11px;
      left: 7px;
      width: 10px;
      height: 2px;
      transform: rotate(24deg);
      opacity: 0.9;
    }

    .divider-game-runner .runner-leg-front {
      top: 16px;
      left: 13px;
      width: 12px;
      height: 3px;
      transform: rotate(30deg);
    }

    .divider-game-runner .runner-leg-back {
      top: 17px;
      left: 7px;
      width: 10px;
      height: 3px;
      transform: rotate(-40deg);
      opacity: 0.84;
    }

    .divider-game-ball {
      position: absolute;
      width: 14px;
      height: 14px;
      border-radius: 999px;
      background: radial-gradient(circle at 35% 35%, rgba(255,255,255,0.86), rgba(255,255,255,0.22) 28%, rgba(252, 82, 0, 0.82) 29%, rgba(194, 65, 12, 0.95));
      box-shadow: 0 10px 20px rgba(194, 65, 12, 0.14);
      will-change: transform;
    }

    .divider-game-ui {
      position: absolute;
      inset: 0;
      pointer-events: none;
    }

    .divider-game-hint,
    .divider-game-score,
    .divider-game-live {
      position: absolute;
      left: 50%;
      transform: translateX(-50%);
      padding: 8px 12px;
      border-radius: 999px;
      background: rgba(255, 252, 248, 0.88);
      border: 1px solid rgba(252, 82, 0, 0.12);
      color: #7a4a2d;
      backdrop-filter: blur(8px);
      box-shadow: 0 12px 22px rgba(252, 82, 0, 0.06);
      white-space: nowrap;
    }

    .divider-game-hint {
      top: 10px;
      font-size: 0.76rem;
      letter-spacing: 0.04em;
    }

    .divider-game-live {
      top: 10px;
      right: 18px;
      left: auto;
      transform: none;
      font-size: 0.76rem;
    }

    .divider-game-score {
      top: 50%;
      opacity: 0;
      transform: translate(-50%, -50%) translateY(8px);
      transition: opacity 0.22s ease, transform 0.22s ease;
      font-size: 0.84rem;
    }

    .divider-game-score.is-visible {
      opacity: 1;
      transform: translate(-50%, -50%) translateY(0);
    }

    .result-card {
      width: 100%;
      text-align: left;
      border: 1px solid var(--border);
      background: var(--card);
      backdrop-filter: blur(10px);
      border-radius: 1rem;
      box-shadow: 0 3px 10px rgba(143, 63, 18, 0.05);
      padding: 20px;
      cursor: pointer;
      transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
    }

    .result-card:hover {
      transform: translateY(-2px);
      background: linear-gradient(180deg, #ffffff, #fff8f4);
      box-shadow: 0 18px 34px rgba(252, 82, 0, 0.08);
    }

    .result-card:active {
      transform: scale(0.99);
    }

    .result-card.is-copied {
      background: linear-gradient(180deg, #ffffff, #fff1e7);
      border-color: rgba(252, 82, 0, 0.42);
      box-shadow: 0 18px 34px rgba(252, 82, 0, 0.14);
    }

    .result-card.is-active-unit {
      border-color: rgba(252, 82, 0, 0.34);
      background: linear-gradient(180deg, #fffdfa, #fff3ea);
      box-shadow: 0 16px 32px rgba(252, 82, 0, 0.1);
    }

    .result-card.is-active-unit .result-label {
      color: var(--accent-strong);
    }

    .result-card.is-active-unit .result-suffix {
      color: #a95322;
    }

    html[data-theme="dark"] .unit-pill {
      border-color: rgba(245, 158, 11, 0.18);
      background: rgba(20, 34, 55, 0.88);
      color: #d9e8ff;
    }

    html[data-theme="dark"] .unit-pill:hover {
      background: rgba(28, 46, 74, 0.96);
      color: #f8fbff;
    }

    html[data-theme="dark"] .unit-pill.is-active {
      background: linear-gradient(180deg, rgba(245, 158, 11, 0.92), rgba(180, 83, 9, 0.95));
      color: #fff8ec;
      border-color: rgba(245, 158, 11, 0.52);
      box-shadow: 0 12px 24px rgba(180, 83, 9, 0.24);
    }

    html[data-theme="dark"] .result-card.is-active-unit {
      border-color: rgba(245, 158, 11, 0.34);
      background: linear-gradient(180deg, rgba(23, 37, 61, 0.98), rgba(53, 30, 9, 0.86));
      box-shadow: 0 18px 34px rgba(180, 83, 9, 0.16);
    }

    html[data-theme="dark"] .result-card.is-active-unit .result-label {
      color: #f6b34d;
    }

    html[data-theme="dark"] .result-card.is-active-unit .result-suffix {
      color: #f2c47a;
    }

    html[data-theme="dark"] .prefill-tip {
      border-color: rgba(130, 192, 255, 0.14);
      background: rgba(12, 23, 40, 0.92);
      box-shadow: 0 16px 30px rgba(0, 5, 18, 0.22);
    }

    html[data-theme="dark"] .prefill-tip-eyebrow,
    html[data-theme="dark"] .prefill-tip-text strong {
      color: #f6b34d;
    }

    html[data-theme="dark"] .prefill-tip-close:hover {
      background: rgba(245, 158, 11, 0.1);
      color: #f6b34d;
    }

    .result-label {
      margin-bottom: 8px;
      font-size: 0.75rem;
      text-transform: uppercase;
      letter-spacing: 0.18em;
      color: #9a755f;
    }

    .result-row {
      display: flex;
      align-items: flex-end;
      justify-content: space-between;
      gap: 16px;
    }

    .result-value {
      font-size: clamp(1.5rem, 4vw, 1.875rem);
      font-weight: 600;
      letter-spacing: -0.03em;
      color: var(--text);
      word-break: break-word;
    }

    .result-suffix {
      display: flex;
      align-items: center;
      gap: 8px;
      font-size: 0.875rem;
      color: var(--muted-light);
      white-space: nowrap;
    }

    .projection-panel {
      margin-top: 4px;
      border: 1px solid rgba(236, 220, 207, 0.95);
      border-radius: 24px;
      background: linear-gradient(180deg, color-mix(in srgb, var(--card-solid) 94%, white), color-mix(in srgb, var(--card-solid) 78%, var(--bg)));
      box-shadow: 0 18px 40px rgba(143, 63, 18, 0.07);
      overflow: hidden;
      opacity: 0;
      transform: translateY(14px);
      animation: fadeUp 0.35s ease 0.1s forwards;
    }

    .projection-panel.is-animating {
      overflow: clip;
    }

    .projection-summary {
      list-style: none;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      padding: 18px 20px;
      cursor: pointer;
    }

    .projection-summary:focus-visible {
      outline: none;
    }

    .projection-summary::-webkit-details-marker {
      display: none;
    }

    .projection-copy {
      display: flex;
      flex-direction: column;
      gap: 6px;
    }

    .projection-eyebrow-row,
    .slider-label-row {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      min-width: 0;
    }

    .projection-eyebrow {
      font-size: 0.72rem;
      text-transform: uppercase;
      letter-spacing: 0.18em;
      color: var(--muted-light);
    }

    .tooltip-wrap {
      position: relative;
      display: inline-flex;
      align-items: center;
      flex-shrink: 0;
    }

    .tooltip-trigger {
      width: 18px;
      height: 18px;
      border: 1px solid rgba(252, 82, 0, 0.18);
      border-radius: 999px;
      background: rgba(255, 247, 240, 0.92);
      color: var(--accent-strong);
      font-size: 0.7rem;
      font-weight: 700;
      line-height: 1;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
    }

    .tooltip-trigger:hover,
    .tooltip-wrap.is-open .tooltip-trigger,
    .tooltip-trigger:focus-visible {
      background: rgba(255, 236, 224, 0.98);
      border-color: rgba(252, 82, 0, 0.3);
      box-shadow: 0 10px 20px rgba(252, 82, 0, 0.08);
      outline: none;
      transform: translateY(-1px);
    }

    .tooltip-bubble {
      position: absolute;
      top: calc(100% + 10px);
      left: 50%;
      width: min(280px, calc(100vw - 40px));
      padding: 11px 12px;
      border-radius: 14px;
      border: 1px solid rgba(252, 82, 0, 0.14);
      background: rgba(255, 252, 248, 0.98);
      color: #7a685d;
      font-size: 0.79rem;
      line-height: 1.5;
      box-shadow: 0 18px 34px rgba(143, 63, 18, 0.1);
      backdrop-filter: blur(12px);
      opacity: 0;
      visibility: hidden;
      transform: translateX(-50%) translateY(-4px);
      transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s ease;
      z-index: 12;
      text-transform: none;
      letter-spacing: normal;
      pointer-events: none;
    }

    .tooltip-bubble::before {
      content: "";
      position: absolute;
      top: -6px;
      left: 50%;
      width: 12px;
      height: 12px;
      background: rgba(255, 252, 248, 0.98);
      border-left: 1px solid rgba(252, 82, 0, 0.14);
      border-top: 1px solid rgba(252, 82, 0, 0.14);
      transform: translateX(-50%) rotate(45deg);
    }

    .tooltip-wrap:hover .tooltip-bubble,
    .tooltip-wrap:focus-within .tooltip-bubble,
    .tooltip-wrap.is-open .tooltip-bubble {
      opacity: 1;
      visibility: visible;
      transform: translateX(-50%) translateY(0);
      pointer-events: auto;
    }

    .projection-panel.has-tooltip-open {
      overflow: visible;
      z-index: 6;
    }

    .projection-subtitle {
      font-size: 0.9rem;
      color: var(--muted);
    }

    .panel-chevron {
      width: 36px;
      height: 36px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      position: relative;
      border-radius: 999px;
      border: 1px solid rgba(252, 82, 0, 0.14);
      background: rgba(255, 248, 243, 0.92);
      transition: transform 0.2s ease, background 0.15s ease;
    }

    .panel-chevron::before {
      content: "";
      width: 8px;
      height: 8px;
      border-right: 2px solid currentColor;
      border-bottom: 2px solid currentColor;
      transform: translateY(-2px) rotate(45deg);
      transform-origin: center;
    }

    .projection-panel[open] .panel-chevron {
      transform: rotate(180deg);
      background: #fff4ec;
    }

    .projection-content {
      padding: 0 20px 20px;
      display: grid;
      gap: 12px;
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .projection-card {
      width: 100%;
      border: 1px solid rgba(236, 220, 207, 0.95);
      border-radius: 18px;
      padding: 16px;
      background: color-mix(in srgb, var(--card-solid) 90%, transparent);
      min-height: 100px;
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      gap: 12px;
      text-align: left;
      cursor: pointer;
      transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
    }

    .projection-card:hover {
      transform: translateY(-2px);
      box-shadow: 0 18px 34px rgba(252, 82, 0, 0.08);
      background: linear-gradient(180deg, #ffffff, #fff8f4);
    }

    .projection-card.is-copied {
      border-color: rgba(252, 82, 0, 0.42);
      background: linear-gradient(180deg, #ffffff, #fff1e7);
      box-shadow: 0 18px 34px rgba(252, 82, 0, 0.14);
    }

    .projection-card.is-record-fast {
      border-color: var(--danger-border);
      background: linear-gradient(180deg, #ffffff, var(--danger-soft));
      box-shadow: 0 14px 26px rgba(179, 75, 75, 0.09);
    }

    .vdot-panel {
      margin-top: 16px;
    }

    .vdot-card {
      width: 100%;
      border: 1px solid rgba(236, 220, 207, 0.95);
      border-radius: 18px;
      padding: 16px;
      background: color-mix(in srgb, var(--card-solid) 90%, transparent);
      min-height: 110px;
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      gap: 12px;
      text-align: left;
      cursor: pointer;
      transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease, background 0.15s ease;
    }

    .vdot-card:hover {
      transform: translateY(-2px);
      box-shadow: 0 18px 34px rgba(252, 82, 0, 0.08);
      background: linear-gradient(180deg, #ffffff, #fff8f4);
    }

    .vdot-card.is-selected {
      border-color: rgba(194, 65, 12, 0.72);
      background: linear-gradient(180deg, rgba(252, 82, 0, 0.95), rgba(194, 65, 12, 0.96));
      box-shadow: 0 22px 42px rgba(194, 65, 12, 0.22);
    }

    .vdot-card.is-selected .projection-distance,
    .vdot-card.is-selected .projection-time {
      color: #f8fafc;
    }

    .vdot-card.is-selected .projection-distance {
      color: rgba(248, 250, 252, 0.72);
    }

    .vdot-tag {
      font-size: 0.8rem;
      color: var(--muted);
    }

    .vdot-card.is-selected .vdot-tag {
      color: rgba(248, 250, 252, 0.78);
    }

    .vdot-card.is-selected .vdot-estimated,
    .vdot-card.is-selected .projection-copy-hint {
      color: rgba(248, 250, 252, 0.78);
    }

    .projection-distance {
      font-size: 0.8rem;
      text-transform: uppercase;
      letter-spacing: 0.16em;
      color: #bc8f73;
    }

    .projection-time {
      font-size: clamp(1.25rem, 3vw, 1.6rem);
      font-weight: 600;
      letter-spacing: -0.03em;
      color: var(--accent-strong);
    }

    .projection-meta {
      display: flex;
      align-items: baseline;
      justify-content: space-between;
      gap: 12px;
    }

    .projection-copy-hint {
      display: flex;
      align-items: center;
      gap: 8px;
      font-size: 0.82rem;
      color: var(--muted-light);
      white-space: nowrap;
    }

    .vdot-estimated {
      margin-bottom: 6px;
      font-size: 0.72rem;
      font-weight: 600;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      color: #d96b2d;
    }

    .vdot-estimated sup {
      font-size: 0.9em;
    }

    .record-notice {
      font-size: 0.78rem;
      color: var(--danger-text);
      letter-spacing: 0.01em;
    }

    .projection-empty {
      grid-column: 1 / -1;
      padding: 18px;
      border: 1px dashed rgba(252, 82, 0, 0.24);
      border-radius: 18px;
      color: var(--muted);
      background: rgba(255, 249, 245, 0.82);
    }

    .section-body {
      padding: 0 20px 20px;
      display: flex;
      flex-direction: column;
      gap: 16px;
    }

    .training-grid {
      display: grid;
      gap: 12px;
      grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .training-card {
      border: 1px solid rgba(236, 220, 207, 0.95);
      border-radius: 18px;
      padding: 16px;
      background: rgba(255, 255, 255, 0.9);
      display: flex;
      flex-direction: column;
      gap: 10px;
      min-height: 108px;
      transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
    }

    .training-card:hover {
      transform: translateY(-2px);
      box-shadow: 0 18px 34px rgba(252, 82, 0, 0.08);
      background: linear-gradient(180deg, #ffffff, #fff8f4);
    }

    .training-label {
      font-size: 0.74rem;
      text-transform: uppercase;
      letter-spacing: 0.16em;
      color: #bc8f73;
    }

    .training-pace {
      font-size: clamp(1.15rem, 2.8vw, 1.45rem);
      font-weight: 600;
      color: #8f3f12;
      letter-spacing: -0.03em;
    }

    .training-meta {
      font-size: 0.84rem;
      color: var(--muted);
      line-height: 1.55;
    }

    .table-toolbar {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      flex-wrap: wrap;
    }

    .mini-input {
      display: inline-flex;
      align-items: center;
      gap: 10px;
      padding: 10px 14px;
      border-radius: 999px;
      border: 1px solid rgba(252, 82, 0, 0.14);
      background: rgba(255, 247, 240, 0.86);
      color: var(--text);
      font-size: 0.88rem;
    }

    html[data-theme="dark"] .mini-input,
    html[data-theme="dark"] .mini-input input {
      color: #0f2744;
    }

    .mini-input input {
      width: 84px;
      border: 0;
      outline: 0;
      background: transparent;
      color: var(--text);
      text-align: right;
    }

    .slider-control {
      display: flex;
      flex-direction: column;
      gap: 8px;
      min-width: min(100%, 340px);
      padding: 12px 14px;
      border-radius: 18px;
      border: 1px solid rgba(252, 82, 0, 0.14);
      background: color-mix(in srgb, var(--card-solid) 86%, transparent);
    }

    .slider-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      font-size: 0.88rem;
      color: var(--text);
    }

    .slider-label {
      color: var(--muted);
      font-size: 0.82rem;
    }

    .slider-range {
      width: 100%;
      accent-color: var(--accent);
    }

    .slider-scale {
      display: flex;
      justify-content: space-between;
      gap: 12px;
      font-size: 0.76rem;
      color: var(--muted-light);
    }

    .toggle-row {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
    }

    .toggle-btn {
      border: 1px solid rgba(252, 82, 0, 0.14);
      background: rgba(255, 247, 240, 0.82);
      color: var(--text);
      border-radius: 999px;
      padding: 8px 14px;
      font-size: 0.88rem;
      cursor: pointer;
      transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
    }

    html[data-theme="dark"] .toggle-btn {
      color: #0f2744;
    }

    .toggle-btn:hover {
      transform: translateY(-1px);
      background: rgba(255, 236, 224, 0.96);
    }

    .toggle-btn.is-active {
      background: linear-gradient(180deg, rgba(252, 82, 0, 0.95), rgba(194, 65, 12, 0.96));
      color: #fff7f2;
      border-color: rgba(194, 65, 12, 0.72);
      box-shadow: 0 12px 28px rgba(194, 65, 12, 0.18);
    }

    html[data-theme="dark"] .toggle-btn.is-active {
      color: #0f2744;
    }

    html[data-theme="dark"] .toggle-btn.is-active,
    html[data-theme="dark"] .toggle-btn.is-active span {
      color: #0f2744;
    }

    html[data-theme="dark"] .tooltip-trigger {
      border-color: rgba(245, 158, 11, 0.22);
      background: rgba(20, 34, 55, 0.92);
      color: #f6b34d;
    }

    html[data-theme="dark"] .tooltip-trigger:hover,
    html[data-theme="dark"] .tooltip-wrap.is-open .tooltip-trigger,
    html[data-theme="dark"] .tooltip-trigger:focus-visible {
      background: rgba(28, 46, 74, 0.98);
      border-color: rgba(245, 158, 11, 0.36);
      box-shadow: 0 12px 24px rgba(0, 5, 18, 0.28);
    }

    html[data-theme="dark"] .tooltip-bubble {
      border-color: rgba(130, 192, 255, 0.14);
      background: rgba(13, 24, 41, 0.98);
      color: #b9cbe3;
      box-shadow: 0 18px 34px rgba(0, 5, 18, 0.34);
    }

    html[data-theme="dark"] .tooltip-bubble::before {
      background: rgba(13, 24, 41, 0.98);
      border-left-color: rgba(130, 192, 255, 0.14);
      border-top-color: rgba(130, 192, 255, 0.14);
    }

    .table-wrap {
      overflow-x: auto;
      border: 1px solid rgba(236, 220, 207, 0.95);
      border-radius: 20px;
      background: color-mix(in srgb, var(--card-solid) 92%, transparent);
      box-shadow: 0 16px 34px rgba(143, 63, 18, 0.05);
    }

    .data-table {
      width: 100%;
      border-collapse: collapse;
      min-width: 420px;
    }

    .data-table th,
    .data-table td {
      border-bottom: 1px solid rgba(236, 220, 207, 0.9);
      padding: 0;
      text-align: left;
    }

    .data-table tr:last-child th,
    .data-table tr:last-child td {
      border-bottom: 0;
    }

    .data-table th {
      padding: 14px 16px;
      font-size: 0.78rem;
      text-transform: uppercase;
      letter-spacing: 0.16em;
      color: var(--muted-light);
      background: color-mix(in srgb, var(--card-solid) 90%, transparent);
      font-weight: 600;
    }

    .table-copy {
      width: 100%;
      border: 0;
      background: transparent;
      text-align: left;
      padding: 14px 16px;
      color: var(--text);
      cursor: pointer;
      transition: background 0.15s ease, color 0.15s ease;
    }

    .table-copy:hover {
      background: rgba(252, 82, 0, 0.08);
      color: var(--accent-strong);
    }

    .table-copy.is-copied {
      background: rgba(252, 82, 0, 0.12);
      color: var(--accent-strong);
    }

    .table-static {
      padding: 14px 16px;
      color: var(--muted);
      font-size: 0.92rem;
    }

    .footer {
      margin-top: 32px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      font-size: 0.875rem;
      color: var(--muted-light);
    }

    .theme-toggle {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      border: 1px solid rgba(252, 82, 0, 0.14);
      background: rgba(255, 247, 240, 0.82);
      color: var(--text);
      border-radius: 999px;
      padding: 8px 12px;
      font-size: 0.82rem;
      cursor: pointer;
      transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
    }

    .theme-toggle:hover {
      transform: translateY(-1px);
      background: color-mix(in srgb, var(--accent-soft) 72%, var(--card-solid));
      border-color: color-mix(in srgb, var(--accent) 28%, var(--border));
    }

    .theme-toggle-dot {
      width: 10px;
      height: 10px;
      border-radius: 999px;
      background: linear-gradient(180deg, var(--accent), var(--accent-strong));
      box-shadow: 0 0 0 6px color-mix(in srgb, var(--accent) 10%, transparent);
    }

    .footer-right {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      flex-wrap: wrap;
    }

    .footer-link {
      display: inline-flex;
      align-items: center;
      gap: 8px;
      color: var(--accent-strong);
      text-decoration: none;
    }

    .footer-link:hover {
      color: var(--accent);
    }

    .footer-icon {
      width: 16px;
      height: 16px;
      display: inline-flex;
    }

    @keyframes fadeUp {
      from {
        opacity: 0;
        transform: translateY(10px);
      }
      to {
        opacity: 1;
        transform: translateY(0);
      }
    }

    @keyframes dividerPulse {
      0%, 100% {
        transform: scale(0.9);
        background: rgba(252, 82, 0, 0.32);
      }
      50% {
        transform: scale(1.15);
        background: rgba(194, 65, 12, 0.72);
      }
    }

    @keyframes stopwatchSweepLong {
      from {
        transform: rotate(34deg);
      }
      to {
        transform: rotate(394deg);
      }
    }

    @keyframes stopwatchSweepShort {
      from {
        transform: rotate(-52deg);
      }
      to {
        transform: rotate(308deg);
      }
    }

    @media (max-width: 640px) {
      .page {
        padding: 28px 16px 40px;
      }

      .hero-brand {
        top: 10px;
        right: -10px;
        width: 82px;
        height: 82px;
        border-radius: 24px;
      }

      .stopwatch-logo {
        width: 44px;
        height: 44px;
        transform: translate(2px, 1px);
      }

      .chips {
        display: none;
      }

      .results,
      .projection-content,
      .training-grid {
        grid-template-columns: 1fr;
      }

      .footer {
        flex-direction: column;
        align-items: flex-start;
      }

      .projection-summary {
        align-items: flex-start;
      }

      .tooltip-bubble {
        left: 0;
        transform: translateX(0) translateY(-4px);
      }

      .tooltip-bubble::before {
        left: 14px;
        top: -6px;
        transform: rotate(45deg);
      }

      .tooltip-wrap:hover .tooltip-bubble,
      .tooltip-wrap:focus-within .tooltip-bubble,
      .tooltip-wrap.is-open .tooltip-bubble {
        transform: translateX(0) translateY(0);
      }
    }

    @media (min-width: 901px) {
      .unit-rail-hint {
        display: inline-flex;
        align-items: center;
        gap: 6px;
      }

      .prefill-tip {
        display: flex;
      }

      .prefill-tip[hidden] {
        display: none !important;
      }
    }
  
