:root {
  color-scheme: light;
  --ink: #142a34;
  --muted: #52646e;
  --paper: #f2f5f3;
  --line: #d9e2de;
  --accent: #0a6c57;
  --accent-soft: #e4f3ec;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}
* { box-sizing: border-box; }
body { margin: 0; }
button, input, textarea { font: inherit; }
button { cursor: pointer; touch-action: manipulation; }
button:disabled { cursor: default; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #176ac0; outline-offset: 4px; }
.skip-link { position: fixed; top: -80px; left: 16px; padding: 16px; background: white; color: var(--ink); z-index: 2; }
.skip-link:focus { top: 12px; }
.page { max-width: 660px; margin: 0 auto; padding: 28px 24px 32px; }
.masthead, .card-heading, .progress-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 750; letter-spacing: -.04em; }
.brand-mark { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; background: var(--ink); color: white; font-size: 12px; letter-spacing: -.03em; }
.tag, .phase { font-size: 11px; letter-spacing: .07em; border: 1px solid var(--line); border-radius: 100px; padding: 7px 10px; white-space: nowrap; }
.intro { padding: 36px 0 24px; }
.eyebrow { color: var(--accent); font-size: 10px; letter-spacing: .14em; font-weight: 800; margin: 0 0 14px; }
h1 { font-size: clamp(36px, 9vw, 54px); line-height: 1.04; font-weight: 760; letter-spacing: -.055em; margin: 0 0 18px; }
.lead { font-size: 16px; line-height: 1.55; color: var(--muted); max-width: 480px; margin: 0 0 16px; }
.privacy-note { font-size: 12px; font-weight: 650; margin: 0; color: var(--accent); }
h2 { font-size: 17px; line-height: 1.4; letter-spacing: -.02em; margin: 0; }
p { line-height: 1.5; }
.test-card, .share-card, .diagnostics { border: 1px solid var(--line); border-radius: 20px; background: white; }
.test-card { padding: 22px; box-shadow: 0 6px 24px #142a3405; }
.phase { background: var(--accent-soft); color: var(--accent); border-color: transparent; letter-spacing: 0; font-weight: 650; }
.game-status { min-height: 42px; font-size: 13px; color: var(--muted); margin: 12px 0 0; }
.tap-area { display: flex; justify-content: center; padding: 10px 0 23px; }
.tap-button { width: 174px; height: 174px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; border-radius: 50%; color: white; background: var(--accent); border: 9px solid #e4f3ec; box-shadow: 0 0 0 1px #cae4d8; -webkit-tap-highlight-color: transparent; transition: transform .12s ease, background .12s ease; }
.tap-button:enabled:active { transform: scale(.96); }
.tap-button:disabled { background: #e8eeeb; color: #53675d; border-color: #f3f6f4; box-shadow: 0 0 0 1px #e0e8e3; }
.tap-count { font-size: 57px; line-height: 1; font-weight: 780; letter-spacing: -.06em; font-variant-numeric: tabular-nums; }
.tap-caption { font-size: 10px; font-weight: 750; letter-spacing: .12em; }
.progress-heading { font-size: 11px; color: var(--muted); margin-bottom: 8px; }
#progress-count { font-variant-numeric: tabular-nums; font-weight: 650; }
progress { width: 100%; height: 7px; display: block; border: 0; border-radius: 10px; overflow: hidden; appearance: none; background: #e8eeeb; color: var(--accent); }
progress::-webkit-progress-bar { background: #e8eeeb; }
progress::-webkit-progress-value { background: var(--accent); }
progress::-moz-progress-bar { background: var(--accent); }
.game-actions, .share-actions, .report-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.button { min-height: 44px; border-radius: 10px; padding: 11px 15px; border: 1px solid var(--line); font-size: 13px; font-weight: 650; color: var(--ink); background: white; }
.game-actions .button { flex: 1; }
.primary { background: var(--ink); color: white; border-color: var(--ink); }
.secondary:enabled:hover { background: #f2f6f4; }
.primary:enabled:hover { background: #254452; }
.button:disabled { color: #758078; background: #f3f5f3; border-color: #e2e8e4; }
.result { padding: 16px; border-radius: 12px; margin-top: 16px; background: var(--accent-soft); }
.result p { margin: 0; }
.result-title { font-weight: 750; color: var(--accent); }
#result-duration { font-size: 24px; font-weight: 750; letter-spacing: -.03em; margin-top: 5px; }
.small { font-size: 12px; line-height: 1.55; color: var(--muted); }
.test-footnote { text-align: center; margin: 15px 0 0; }
.share-card { margin-top: 16px; padding: 22px; }
.share-card > p { font-size: 13px; color: var(--muted); margin: 8px 0 0; }
.share-actions .button { flex: 1; }
#share-status { min-height: 36px; margin-top: 12px; }
.notice { padding: 12px 14px; border: 1px solid #ead5a6; background: #fff8e8; color: #6d4d19 !important; border-radius: 10px; font-size: 12px !important; }
.manual-copy { padding-top: 12px; }
label { display: block; font-size: 12px; font-weight: 650; margin: 0 0 8px; }
input, textarea { display: block; width: 100%; min-width: 0; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: #f7f9f7; color: var(--ink); font-size: 13px; }
input { min-height: 44px; }
textarea { resize: vertical; font-family: ui-monospace, Consolas, monospace; font-size: 11px; line-height: 1.6; }
.text-button { margin-top: 8px; border-color: transparent; color: var(--accent); }
.diagnostics { margin-top: 16px; }
summary { cursor: pointer; min-height: 52px; padding: 17px 22px; font-size: 13px; font-weight: 700; }
summary .small { margin-left: 8px; font-weight: 400; }
.diagnostics-body { padding: 0 22px 22px; border-top: 1px solid var(--line); }
.diagnostic-grid { margin: 20px 0; }
.diagnostic-grid > div { display: grid; grid-template-columns: 1fr 1.3fr; gap: 16px; padding: 10px 0; border-bottom: 1px solid #edf1ee; font-size: 12px; line-height: 1.5; }
dt { color: var(--muted); }
dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.footer { padding: 22px 8px 0; text-align: center; color: var(--muted); font-size: 11px; line-height: 1.7; }
@media (max-width: 360px) {
  .page { padding: 20px 16px 24px; }
  .test-card, .share-card { padding: 18px; }
  .diagnostics-body { padding: 0 18px 18px; }
  .brand { font-size: 15px; }
  .card-heading { align-items: flex-start; }
  .button { padding: 11px 12px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
