/* MVP v2 look: Material 3 inspired, clean white surfaces, soft corners, subtle shadows, 200 ms transitions.
   Light by default; dark when the system asks. No Google branding. Layout sizes the JS depends on:
   day header 44 px (DAY_HEADER_HEIGHT), moment row = var(--cover), tiles = var(--tile). */
:root {
  color-scheme: light dark;
  --primary: #0b57d0;
  --on-primary: #fff;
  --primary-container: #d3e3fd;
  --on-primary-container: #041e49;
  --surface: #fff;
  --surface-low: #f8fafd;
  --surface-high: #f0f4f9;
  --surface-highest: #e9eef6;
  --text: #1f1f1f;
  --muted: #444746;
  --outline: #747775;
  --line: #c4c7c5;
  --tile-bg: #e8eaed;          /* placeholder grey, only before a tile's first draw */
  --scrim: rgba(0, 0, 0, .32);
  --shadow-1: 0 1px 2px rgba(60, 64, 67, .3), 0 1px 3px 1px rgba(60, 64, 67, .15);
  --shadow-2: 0 1px 2px rgba(60, 64, 67, .3), 0 2px 6px 2px rgba(60, 64, 67, .15);
  --shadow-3: 0 4px 8px 3px rgba(60, 64, 67, .15), 0 1px 3px rgba(60, 64, 67, .3);
  --ease: cubic-bezier(.2, 0, 0, 1);   /* M3 standard easing */
  --t: 200ms;
  --font: Roboto, system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --primary: #a8c7fa;
    --on-primary: #062e6f;
    --primary-container: #0842a0;
    --on-primary-container: #d3e3fd;
    --surface: #131314;
    --surface-low: #1b1b1c;
    --surface-high: #1e1f20;
    --surface-highest: #282a2c;
    --text: #e3e3e3;
    --muted: #c4c7c5;
    --outline: #8e918f;
    --line: #444746;
    --tile-bg: #2a2b2d;
    --scrim: rgba(0, 0, 0, .6);
    --shadow-1: 0 1px 2px rgba(0, 0, 0, .6), 0 1px 3px 1px rgba(0, 0, 0, .3);
    --shadow-2: 0 1px 2px rgba(0, 0, 0, .6), 0 2px 6px 2px rgba(0, 0, 0, .3);
    --shadow-3: 0 4px 8px 3px rgba(0, 0, 0, .3), 0 1px 3px rgba(0, 0, 0, .6);
  }
}
@media (prefers-reduced-motion: reduce) { :root { --t: 0ms; } }
[hidden] { display: none !important; }
html, body {
  margin: 0;
  height: 100%;
  overscroll-behavior: none;
  background: var(--surface);
  color: var(--text);
  font: 16px/1.4 var(--font);
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
}
body { overflow: hidden; touch-action: pan-x pan-y; -webkit-tap-highlight-color: transparent; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
h1, h2, h3, p { margin: 0; }

/* ---- app column: full width on a phone, centred up to 1120 px on a laptop ---- */
.app { display: flex; flex-direction: column; height: 100dvh; max-width: 1120px; margin: 0 auto; background: var(--surface); }
@media (min-width: 1140px) { .app { box-shadow: 0 0 0 1px var(--line); } }

/* ---- top app bar ---- */
.app-header { flex: none; display: flex; align-items: center; gap: 4px; min-height: 64px; padding: 0 8px 0 16px; }
.brand { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; }
.brand h1 { font-size: 22px; font-weight: 400; }
.concept { padding: 2px 8px; border-radius: 8px; border: 1px solid var(--line); color: var(--muted); font-size: 14px; line-height: 18px; }
.task-btn {   /* M3 tonal button */
  min-height: 40px; padding: 0 16px 0 12px; display: inline-flex; align-items: center; gap: 8px;
  border: 0; border-radius: 20px; background: var(--primary-container); color: var(--on-primary-container);
  font-size: 14px; font-weight: 500; cursor: pointer; white-space: nowrap;
  transition: box-shadow var(--t) var(--ease);
}
.task-btn:hover { box-shadow: var(--shadow-1); }
.icon-btn {
  width: 48px; height: 48px; flex: none; display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 50%; background: none; color: var(--muted); cursor: pointer;
  transition: background var(--t) var(--ease);
}
.icon-btn:hover { background: color-mix(in srgb, var(--text) 8%, transparent); }
.avatar-btn { width: 48px; height: 48px; padding: 4px; border: 0; border-radius: 50%; background: none; cursor: pointer; flex: none; }
.avatar-btn img { width: 36px; height: 36px; border-radius: 50%; display: block; box-shadow: 0 0 0 1px var(--line); }
@media (max-width: 380px) { .concept { display: none; } }

/* ---- timeline ---- */
.timeline { position: relative; flex: 1; min-height: 0; }
.scroller { position: absolute; inset: 0; overflow-y: auto; overflow-x: hidden; overscroll-behavior: none; touch-action: pan-y; scrollbar-width: none; }
.scroller::-webkit-scrollbar { display: none; }
.content { position: relative; contain: layout style; }
.day-header {   /* 44 px tall: must match DAY_HEADER_HEIGHT */
  position: absolute; left: 0; right: 0; height: 44px; box-sizing: border-box; padding: 0 56px 10px 16px;
  display: flex; align-items: flex-end; font-size: 14px; font-weight: 500; letter-spacing: .1px;
  white-space: nowrap; overflow: hidden;
}
.row { position: absolute; left: 0; right: 0; display: grid; grid-template-columns: repeat(var(--cols), var(--tile)); gap: 2px; }
.tile { height: var(--tile); background: var(--tile-bg); border-radius: 4px; cursor: pointer; }
.tile img { width: 100%; height: 100%; display: block; border-radius: 4px; }
.tile.dim { background: var(--surface); }
.tile.dim img, .moment-row.dim { opacity: var(--dim, .35); }

/* ---- moment view ---- */
.moment-row { position: absolute; left: 0; right: 0; height: var(--cover); display: flex; align-items: center; gap: 16px; padding: 0 56px 0 12px; cursor: pointer; }
.moment-cover { flex: none; width: var(--cover); height: var(--cover); border-radius: 16px; background: var(--tile-bg); box-shadow: var(--shadow-1); }
.moment-cover img { width: 100%; height: 100%; display: block; border-radius: 16px; }
.moment-text { flex: 1; min-width: 0; }
.moment-date { font-size: 16px; font-weight: 500; }
.moment-count { font-size: 14px; color: var(--muted); margin-top: 2px; }
.moment-meta { display: flex; align-items: center; gap: 4px; margin-top: 4px; }
.moment-faces { display: flex; min-height: 24px; }
.moment-faces img { width: 24px; height: 24px; border-radius: 50%; box-shadow: 0 0 0 2px var(--surface); }
.moment-faces img + img { margin-left: -4px; }
.moment-info { width: 40px; height: 40px; }
.moments-pill {
  position: absolute; top: 8px; left: 8px; z-index: 3; min-height: 36px; padding: 0 16px 0 10px;
  display: flex; align-items: center; gap: 8px; border-radius: 18px;
  background: var(--primary-container); color: var(--on-primary-container); box-shadow: var(--shadow-2);
  font-size: 14px; font-weight: 500; pointer-events: none;
}
.moment-hint {
  position: absolute; top: 52px; left: 8px; right: 56px; z-index: 3; max-width: 420px;
  display: flex; align-items: center; gap: 4px; padding: 12px 4px 12px 16px; border-radius: 16px;
  background: var(--surface-highest); color: var(--text); box-shadow: var(--shadow-3); font-size: 14px;
  animation: rise var(--t) var(--ease);
}
.moment-hint span { flex: 1; }
.moment-hint .icon-btn { width: 40px; height: 40px; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }

/* ---- scrubber ---- */
.scrubber { position: absolute; top: 8px; bottom: 8px; right: 0; width: 0; pointer-events: none; }
.scrub-handle { position: absolute; top: 0; right: 0; width: 44px; height: 48px; display: flex; justify-content: flex-end; align-items: center; pointer-events: auto; touch-action: none; cursor: grab; }
.scrub-handle span {
  width: 28px; height: 44px; margin-right: 2px; border-radius: 14px 0 0 14px; background: var(--surface-highest);
  color: var(--muted); box-shadow: var(--shadow-1); display: flex; align-items: center; justify-content: center;
  transition: width var(--t) var(--ease);
}
.scrub-handle svg { display: block; }
.scrubber.dragging .scrub-handle span { width: 34px; background: var(--primary-container); color: var(--on-primary-container); }
.scrub-bubble {
  position: absolute; top: 4px; right: 56px; padding: 8px 16px; border-radius: 20px;
  background: var(--primary-container); color: var(--on-primary-container); box-shadow: var(--shadow-2);
  font-size: 16px; font-weight: 500; white-space: nowrap;
}
.scrub-years { position: absolute; top: 0; right: 22px; }
.scrub-year { position: absolute; right: 0; height: 40px; padding: 0 4px; border: 0; background: none; display: flex; align-items: center; pointer-events: auto; cursor: pointer; }
.scrub-year span { padding: 2px 10px; border-radius: 8px; background: color-mix(in srgb, var(--surface) 92%, transparent); color: var(--muted); box-shadow: var(--shadow-1); font-size: 14px; font-weight: 500; }
.scrub-ticks { position: absolute; top: 0; right: 0; }
.scrub-tick { position: absolute; right: 0; width: 36px; padding: 0; border: 0; background: none; pointer-events: auto; cursor: pointer; }
.scrub-tick span { position: absolute; right: 3px; top: 50%; width: 14px; height: 3px; margin-top: -1.5px; border-radius: 2px; background: var(--primary); box-shadow: 0 0 0 1px var(--surface); }

/* ---- Back pill ---- */
.back-pill {
  position: absolute; top: 12px; left: 50%; transform: translateX(-50%); z-index: 3; min-height: 40px; padding: 0 20px 0 12px;
  display: flex; align-items: center; gap: 8px; border: 0; border-radius: 20px;
  background: var(--primary-container); color: var(--on-primary-container); box-shadow: var(--shadow-2);
  font-size: 14px; font-weight: 500; cursor: pointer; animation: rise var(--t) var(--ease);
}

/* ---- faces ---- */
.face-row { flex: none; display: flex; align-items: flex-start; justify-content: space-between; gap: 2px; padding: 4px 8px 8px; border-bottom: 1px solid var(--line); }
.face { flex: 1 1 0; min-width: 0; min-height: 44px; padding: 2px 0; border: 0; background: none; display: flex; flex-direction: column; align-items: center; gap: 6px; cursor: pointer; }
.face-pic { position: relative; width: 48px; height: 48px; border-radius: 50%; transition: box-shadow var(--t) var(--ease); }
.face-pic canvas { width: 48px; height: 48px; border-radius: 50%; display: block; }
.face-check {
  display: none; position: absolute; right: -5px; bottom: -5px; width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid var(--surface); background: var(--primary); color: var(--on-primary); align-items: center; justify-content: center;
}
.face[aria-pressed="true"] .face-pic { box-shadow: 0 0 0 2px var(--surface), 0 0 0 5px var(--primary); }
.face[aria-pressed="true"] .face-check { display: flex; }
.face[aria-pressed="true"] .face-name { font-weight: 700; }
.face-name { font-size: 14px; line-height: 1.2; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.face-clear { flex: none; align-self: center; min-height: 40px; padding: 0 12px; border: 0; border-radius: 20px; background: none; color: var(--primary); font-size: 14px; font-weight: 500; cursor: pointer; }
.never-together {
  position: absolute; top: 12px; left: 50%; transform: translateX(-50%); z-index: 3; min-height: 40px; padding: 0 16px 0 12px;
  display: flex; align-items: center; gap: 8px; border-radius: 8px; background: #313033; color: #f4eff4;
  box-shadow: var(--shadow-2); font-size: 14px; font-weight: 500; white-space: nowrap; pointer-events: none;
}

/* ---- photo viewer (always dark, like a lightbox) ---- */
.viewer {
  position: fixed; inset: 0; z-index: 10; display: flex; flex-direction: column; align-items: center;
  overflow-y: auto; background: #000; color: #e3e3e3; overscroll-behavior: none; animation: fade var(--t) var(--ease);
}
@keyframes fade { from { opacity: 0; } }
.viewer-top { align-self: stretch; padding: 8px 4px; flex: none; }
.viewer .icon-btn { color: #fff; }
.viewer .icon-btn:hover { background: rgba(255, 255, 255, .1); }
.viewer-stage { position: relative; flex: none; display: flex; align-items: center; justify-content: center; align-self: stretch; }
.viewer-photo { display: block; touch-action: pan-y; border-radius: 4px; }
.viewer-prev, .viewer-next { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(32, 33, 36, .6) !important; }
.viewer-prev { left: 8px; }
.viewer-next { right: 8px; }
.icon-btn:disabled { opacity: .3; cursor: default; }
.viewer-info { width: 100%; max-width: 720px; box-sizing: border-box; padding: 0 16px; }
.viewer-date { margin: 12px 0 4px; font-size: 14px; letter-spacing: .25px; text-align: center; color: #c4c7c5; }
.viewer-note { margin: 8px 0; padding: 12px 16px; border-radius: 12px; background: #0842a0; color: #d3e3fd; font-size: 14px; font-weight: 500; text-align: center; }
.viewer-extra h3 { margin: 16px 0 8px; font-size: 14px; font-weight: 500; color: #c4c7c5; }
.v-people ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 4px 8px; }
.v-person { display: grid; grid-template-columns: 36px 1fr; grid-template-rows: auto auto; column-gap: 10px; align-items: center; }
.v-person img { grid-row: 1 / 3; }
.v-person img { width: 36px; height: 36px; border-radius: 50%; }
.v-person span { font-size: 14px; font-weight: 500; align-self: end; }
.not-btn {   /* text button; 40 px tall tap area that overlaps the gap */
  justify-self: start; align-self: start; min-height: 40px; margin: -10px 0 -10px -8px; padding: 0 8px; border: 0; border-radius: 20px;
  background: none; color: #a8c7fa; font-size: 14px; font-weight: 500; text-decoration: underline; text-underline-offset: 3px; cursor: pointer;
}
.v-similar { padding-bottom: 8px; border-radius: 16px; transition: box-shadow var(--t) var(--ease); }
.v-similar.nudge { animation: nudge 1.2s var(--ease) 2; }
@keyframes nudge { 50% { box-shadow: 0 0 0 3px #a8c7fa; } }
.strip-items { display: flex; gap: 12px; padding-top: 10px; overflow-x: auto; scrollbar-width: none; }
.strip-item { position: relative; flex: none; width: 76px; padding: 0; border: 0; background: none; display: flex; flex-direction: column; align-items: center; gap: 6px; cursor: pointer; color: inherit; }
.strip-item:disabled { cursor: default; }
.strip-thumb { width: 72px; height: 72px; border-radius: 12px; background: #2a2b2d; display: block; }
.strip-thumb img { width: 100%; height: 100%; display: block; border-radius: 12px; }
.strip-date { font-size: 14px; color: #c4c7c5; white-space: nowrap; }
.strip-item.here .strip-thumb { box-shadow: 0 0 0 2px #000, 0 0 0 5px #a8c7fa; }   /* outline plus the word "Here" */
.strip-item.here .strip-date { font-weight: 700; color: #fff; }
.strip-here { position: absolute; top: -9px; left: 50%; transform: translateX(-50%); padding: 0 8px; border-radius: 8px; background: #a8c7fa; color: #062e6f; font-size: 14px; font-weight: 500; line-height: 1.3; }
.viewer-actions { flex: none; padding: 16px 16px calc(20px + env(safe-area-inset-bottom)); align-self: stretch; display: flex; flex-direction: column; align-items: center; position: sticky; bottom: 0; background: linear-gradient(transparent, #000 30%); }
.viewer .primary { background: #a8c7fa; color: #062e6f; }
.viewer-msg { margin: 0 0 12px; padding: 12px 16px; border-radius: 8px; background: #e3e3e3; color: #1f1f1f; font-size: 14px; font-weight: 500; text-align: center; }
.viewer-info:last-child { padding-bottom: calc(24px + env(safe-area-inset-bottom)); }

/* ---- buttons ---- */
.primary {
  min-height: 48px; min-width: 200px; padding: 0 24px; border: 0; border-radius: 24px;
  background: var(--primary); color: var(--on-primary); font-size: 15px; font-weight: 500; letter-spacing: .1px; cursor: pointer;
  transition: box-shadow var(--t) var(--ease), transform var(--t) var(--ease);
}
.primary:hover { box-shadow: var(--shadow-1); }
.primary:active { transform: scale(.98); }
.text-btn { min-height: 48px; padding: 0 16px; border: 0; border-radius: 24px; background: none; color: var(--primary); font-size: 15px; font-weight: 500; cursor: pointer; }

/* ---- task bar ---- */
.task-bar { flex: none; display: flex; align-items: center; gap: 12px; margin: 0 8px 4px; padding: 8px 8px 8px 8px; border-radius: 16px; background: var(--surface-high); }
.task-thumb { flex: none; width: 48px; height: 48px; padding: 0; border: 0; border-radius: 12px; background: none; cursor: zoom-in; }
.task-thumb canvas { width: 48px; height: 48px; display: block; border-radius: 12px; }
.task-text { flex: 1; min-width: 0; }
.task-note { font-size: 14px; line-height: 1.35; }
.task-timer { font-size: 14px; font-weight: 500; color: var(--primary); font-variant-numeric: tabular-nums; margin-top: 2px; }
.giveup-btn { flex: none; min-height: 40px; padding: 0 16px; border: 1px solid var(--outline); border-radius: 20px; background: transparent; color: var(--primary); font-size: 14px; font-weight: 500; cursor: pointer; }
.peek { position: fixed; inset: 0; z-index: 25; display: flex; align-items: center; justify-content: center; background: rgba(0, 0, 0, .85); cursor: zoom-out; }
.peek canvas { border-radius: 12px; }

/* ---- bottom sheet (centred dialog on a laptop) ---- */
.scrim { position: fixed; inset: 0; z-index: 20; background: var(--scrim); animation: fade var(--t) var(--ease); }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 21; max-height: 85dvh; overflow-y: auto; box-sizing: border-box;
  padding: 8px 24px calc(24px + env(safe-area-inset-bottom)); border-radius: 28px 28px 0 0;
  background: var(--surface-low); box-shadow: var(--shadow-3); animation: slide var(--t) var(--ease);
}
@keyframes slide { from { transform: translateY(24px); opacity: 0; } }
@media (min-width: 640px) {
  .sheet { left: 50%; right: auto; bottom: auto; top: 50%; width: 480px; transform: translate(-50%, -50%); border-radius: 28px; padding-bottom: 24px; animation: fade var(--t) var(--ease); }
}
.sheet-head { display: flex; align-items: center; gap: 8px; margin-right: -12px; min-height: 56px; }
.sheet-head h2 { flex: 1; font-size: 22px; font-weight: 400; }
.sheet-sub { color: var(--muted); font-size: 14px; margin-bottom: 8px; }
.sheet-body h3 { margin: 16px 0 8px; font-size: 14px; font-weight: 500; color: var(--muted); }
.sheet-body .hint { margin-top: 16px; }
.sheet-action { width: 100%; margin-top: 16px; }
.text-btn.sheet-action { margin-top: 4px; }
.chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 8px; min-height: 32px; padding: 0 12px; border: 1px solid var(--line); border-radius: 8px; font-size: 14px; font-weight: 500; }
.chip img { width: 24px; height: 24px; border-radius: 50%; margin-left: -6px; }
.muted, .hint { color: var(--muted); font-size: 14px; }
.task-list { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.task-item {
  width: 100%; min-height: 64px; display: flex; align-items: center; gap: 12px; padding: 12px 8px 12px 16px; border: 0; border-radius: 16px;
  background: var(--surface-high); text-align: left; font-size: 16px; line-height: 1.4; cursor: pointer; transition: background var(--t) var(--ease);
}
.task-item:hover { background: var(--surface-highest); }
.task-item span { flex: 1; }
.task-item svg { flex: none; color: var(--muted); }
.result { display: flex; gap: 12px; margin: 8px 0 0; }
.result div { flex: 1; padding: 16px; border-radius: 16px; background: var(--surface-high); }
.result dt { font-size: 14px; color: var(--muted); }
.result dd { margin: 4px 0 0; font-size: 28px; font-variant-numeric: tabular-nums; }

/* ---- toast ---- */
.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 30;
  width: max-content; max-width: calc(100% - 32px); box-sizing: border-box; display: flex; align-items: center; gap: 8px;
  padding: 4px 4px 4px 16px; border-radius: 8px; background: #313033; color: #f4eff4; box-shadow: var(--shadow-3);
  font-size: 14px; animation: rise var(--t) var(--ease);
}
.toast-undo { min-height: 40px; padding: 0 12px; border: 0; border-radius: 20px; background: none; color: #a8c7fa; font-weight: 500; cursor: pointer; }

/* ---- full-screen screens ---- */
.screen { position: fixed; inset: 0; z-index: 40; overflow-y: auto; overscroll-behavior: none; background: var(--surface); animation: fade var(--t) var(--ease); }
.screen-inner { max-width: 520px; min-height: 100%; box-sizing: border-box; margin: 0 auto; padding: 32px 24px calc(32px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; }
.screen h1 { font-size: 28px; font-weight: 400; line-height: 1.25; margin-bottom: 8px; }
.screen h2 { font-size: 22px; font-weight: 400; margin-bottom: 8px; }
.screen .lead { font-size: 16px; line-height: 1.5; color: var(--muted); margin-bottom: 16px; }
.screen .primary { width: 100%; margin-top: 24px; }
.people { list-style: none; padding: 0; margin: 0; }
.people li { display: flex; align-items: center; gap: 16px; min-height: 64px; border-bottom: 1px solid var(--line); }
.people li:last-child { border-bottom: 0; }
.people img { width: 48px; height: 48px; border-radius: 50%; flex: none; }
.intro .screen-inner { justify-content: center; }
.intro-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; margin: 0 -24px; }
.intro-track::-webkit-scrollbar { display: none; }
.intro-card { flex: 0 0 100%; scroll-snap-align: center; box-sizing: border-box; padding: 24px; display: flex; flex-direction: column; align-items: center; gap: 24px; text-align: center; }
.intro-card svg { width: min(280px, 80%); height: auto; padding: 24px; box-sizing: border-box; border-radius: 28px; background: var(--surface-high); }
.intro-card h2 { font-size: 24px; line-height: 1.3; max-width: 320px; }
.intro-dots { display: flex; justify-content: center; gap: 8px; margin: 8px 0 24px; }
.intro-dots span { width: 8px; height: 8px; border-radius: 4px; background: var(--line); transition: width var(--t) var(--ease), background var(--t) var(--ease); }
.intro-dots span.on { width: 24px; background: var(--primary); }
.intro-actions { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.intro-actions .primary { width: auto; min-width: 140px; margin: 0; }
.il-muted { fill: var(--line); }
.il-accent { fill: var(--primary); }
.il-line { stroke: var(--outline); stroke-width: 2.5; fill: none; }
.il-ring { stroke: var(--primary); stroke-width: 4; }
.preview-screen .screen-inner { align-items: center; text-align: center; }
.preview { display: block; margin: 8px auto 0; border-radius: 16px; box-shadow: var(--shadow-2); }
.countdown { font-size: 36px; color: var(--primary); margin-top: 16px; font-variant-numeric: tabular-nums; }

/* ---- ?debug=1 overlay (speed.js) ---- */
.debug-overlay { position: absolute; left: 8px; bottom: 8px; z-index: 5; padding: 6px 8px; border-radius: 8px; background: rgba(0, 0, 0, .75); color: #fff; font: 14px/1.3 ui-monospace, monospace; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; max-width: calc(100% - 80px); }
.debug-overlay button { min-height: 32px; font-size: 14px; color: #1f1f1f; background: #fff; border: 0; border-radius: 8px; }

/* Laptop: faces grouped on the left instead of spread across the whole width */
@media (min-width: 768px) {
  .face-row { justify-content: flex-start; gap: 16px; padding-left: 16px; }
  .face { flex: none; width: 72px; }
  .face-clear { margin-left: auto; }
}
