:root {
  --bg: #f4f2ee;
  --ink: #12141a;
  --ink-2: #3a3e48;
  --mute: #6b7180;
  --faint: #a2a6ae;
  --line: #e3e0d9;
  --card: #ffffff;
  --card-2: #ecebe6;
  --accent: #ff5a2c;
  --accent-ink: #c43e14;
  --ok: #1f9d55;
  --warn: #d48806;
  --shadow: 0 1px 2px rgba(18,20,26,.05), 0 8px 24px rgba(18,20,26,.06);
  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --ease: cubic-bezier(.23, 1, .32, 1);
  --gutter: max(16px, env(safe-area-inset-left), env(safe-area-inset-right));
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1014; --ink: #eceae4; --ink-2: #c5c7cd; --mute: #9aa0aa; --faint: #5d626c;
    --line: #23262d; --card: #16191f; --card-2: #1d2027;
    --accent: #ff6a3d; --accent-ink: #ff8a5c; --ok: #3ccf7a; --warn: #f0b03c;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 12px 32px rgba(0,0,0,.35);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e1014; --ink: #eceae4; --ink-2: #c5c7cd; --mute: #9aa0aa; --faint: #5d626c;
  --line: #23262d; --card: #16191f; --card-2: #1d2027;
  --accent: #ff6a3d; --accent-ink: #ff8a5c; --ok: #3ccf7a; --warn: #f0b03c;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 12px 32px rgba(0,0,0,.35);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg);
  color: var(--ink);
  font: 400 15px/1.45 var(--sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent;
}
button { font: inherit; color: inherit; }
button, a { touch-action: manipulation; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 8px; }
.sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
[hidden] { display: none !important; }

/* Layout */
.app {
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100vh;
  min-height: 100dvh;
  padding: max(10px, env(safe-area-inset-top)) var(--gutter) max(16px, env(safe-area-inset-bottom));
}

/* Top bar */
.bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; min-height: 48px; }
.bar-actions { justify-self: end; }
.modes { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--card-2); }
.modes button { height: 34px; padding: 0 15px; border: 0; border-radius: 999px; background: none; color: var(--mute); font-size: 14px; font-weight: 500; white-space: nowrap; cursor: pointer; transition: background-color .15s ease, color .15s ease; }
.modes button[aria-pressed="true"] { background: var(--card); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.12); }
@media (hover: hover) { .modes button:not([aria-pressed="true"]):hover { color: var(--ink-2); } }
@media (max-width: 760px) {
  .bar { grid-template-columns: auto 1fr; grid-template-areas: "brand actions" "modes modes"; row-gap: 8px; }
  .brand { grid-area: brand; } .bar-actions { grid-area: actions; } .modes { grid-area: modes; display: grid; grid-auto-columns: minmax(0, 1fr); grid-auto-flow: column; }
  .modes button { padding: 0 8px; }
}
.brand { color: var(--ink); font-size: 21px; font-weight: 650; letter-spacing: -.045em; text-decoration: none; }
.brand span { color: var(--accent); }
.bar-actions { display: flex; align-items: center; gap: 6px; min-width: 0; }
.pill {
  display: inline-flex; align-items: center; gap: 7px; min-width: 0; max-width: 52vw; height: 40px; padding: 0 14px 0 11px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--card); color: var(--ink-2);
  font-size: 14px; font-weight: 500; cursor: pointer;
  transition: border-color .15s ease, color .15s ease, transform .16s var(--ease);
}
.pill svg { flex: none; color: var(--accent-ink); }
.pill span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.icon-btn {
  display: inline-grid; place-items: center; flex: none; width: 40px; height: 40px; padding: 0;
  border: 0; border-radius: 999px; background: none; color: var(--mute); cursor: pointer;
  transition: background-color .15s ease, color .15s ease, transform .16s var(--ease);
}
@media (hover: hover) {
  .pill:hover { border-color: var(--faint); color: var(--ink); }
  .icon-btn:hover { background: var(--card-2); color: var(--ink); }
}
.pill:active, .icon-btn:active { transform: scale(.96); }
.icon-btn .i-shrink { display: none; }
.big .icon-btn .i-grow { display: none; }
.big .icon-btn .i-shrink { display: block; }

/* Clock */
.view { display: flex; flex-direction: column; align-items: center; width: 100%; min-width: 0; }
.stage { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 0; padding: 3vh 0; text-align: center; }
.zone { margin: 0 0 1.2vh; color: var(--mute); font-size: clamp(13px, 1.6vw, 17px); font-weight: 500; }
.zone b { color: var(--ink-2); font-weight: 600; }
.clock-wrap { display: flex; justify-content: center; width: 100%; min-width: 0; }
.clock {
  display: inline-flex; align-items: baseline; white-space: nowrap;
  font-size: 120px; /* app.js fits it to the screen */
  font-weight: 600; line-height: .92; letter-spacing: -.045em;
  font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1, "ss01" 1;
  cursor: pointer; user-select: none; -webkit-user-select: none;
  visibility: hidden;
}
.clock.ready { visibility: visible; }
.ss { font-size: var(--ss, 1em); color: var(--faint); }
.colon { display: inline-block; margin: 0 -.01em; }
.hm, .ss { display: inline-block; }
[data-seconds="off"] .ss { display: none; }
[data-seconds="same"] .ss { --ss: 1em; color: inherit; }
[data-seconds="same"] .ss .colon { display: inline-block !important; }
[data-seconds="same"] .ss { margin-left: 0 !important; }
[data-hide-zone] #zone, [data-hide-date] #date, [data-hide-sync] #sync, [data-hide-week] .date small { display: none !important; }
[data-hide-date]:not([data-hide-week]) #date { display: block !important; }
[data-hide-date] .date .day, [data-hide-date] .date .sep { display: none; }
[data-hide-date] .date small { display: inline; margin: 0; font-size: 1em; }
.date { margin: 2.2vh 0 0; color: var(--ink-2); font-size: clamp(16px, 2.3vw, 26px); font-weight: 450; letter-spacing: -.01em; }
.date::first-letter { text-transform: uppercase; }
.date small { color: var(--mute); font-size: .78em; font-weight: 400; white-space: nowrap; }
.sync {
  display: inline-flex; align-items: center; gap: 8px; margin: 1.6vh 0 0; padding: 6px 12px;
  border-radius: 999px; background: var(--card-2); color: var(--mute); font-size: 13px; font-variant-numeric: tabular-nums;
}
.sync b { color: var(--ink); font-weight: 600; }
.dot { flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--faint); }
.sync.ok .dot { background: var(--ok); }
.sync.off .dot { background: var(--warn); }

/* Weather (the campus pattern) */
.weather {
  display: flex; align-items: center; justify-content: center; gap: 28px;
  width: min(100%, 980px); margin: 0 auto; padding: 14px 18px;
  border: 1px solid var(--line); border-radius: 20px; background: var(--card); box-shadow: var(--shadow);
}
.wx-now {
  display: flex; align-items: center; gap: 11px; flex: none; padding: 4px 6px; margin: -4px -6px;
  border: 0; border-radius: 12px; background: none; text-align: left; cursor: pointer;
}
.wx-icon { display: grid; color: var(--accent-ink); }
.wx-temp { font-size: 40px; font-weight: 500; letter-spacing: -.04em; line-height: .9; font-variant-numeric: tabular-nums; }
.wx-meta { display: grid; gap: 3px; color: var(--mute); font-size: 13px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.wx-label { color: var(--ink-2); font-weight: 600; }
.wx-rain { color: var(--accent-ink); font-weight: 600; }
.wx-hours { display: flex; gap: 16px; margin: 0; padding: 0 0 0 26px; border-left: 1px solid var(--line); list-style: none; color: var(--mute); font-size: 12px; }
.wx-hours li { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 30px; font-variant-numeric: tabular-nums; }
.wx-hours svg { color: var(--accent-ink); }
.wx-hours b { color: var(--ink); font-size: 13px; font-weight: 600; }
.wx-sun { display: grid; gap: 4px; margin: 0; padding-left: 26px; border-left: 1px solid var(--line); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.wx-sun div { display: flex; align-items: center; gap: 7px; }
.wx-sun dt { display: grid; color: var(--accent-ink); }
.wx-sun dd { margin: 0; color: var(--ink-2); font-weight: 500; }
.wx-sun dd small { color: var(--mute); font-weight: 400; }
@media (hover: hover) { .wx-now:hover { background: var(--card-2); } }

@media (max-width: 860px) { .wx-sun { display: none; } }
@media (max-width: 600px) {
  .weather { flex-direction: column; align-items: stretch; gap: 12px; padding: 14px 16px; border-radius: 18px; }
  .wx-now { justify-content: flex-start; }
  .wx-temp { font-size: 36px; }
  .wx-hours { justify-content: space-between; gap: 4px; padding: 12px 0 0; border-left: 0; border-top: 1px solid var(--line); }
  .wx-hours li { min-width: 0; flex: 1; }
  .pill { max-width: 46vw; }
}
@media (max-width: 600px) { .date small { display: block; margin-top: 3px; } .date .sep, .sync .more { display: none; } }
@media (max-width: 380px) { .wx-hours li:nth-child(n+6) { display: none; } }

/* Phone held upright: seconds sit smaller, next to the minutes */
@media (max-aspect-ratio: 1/1) { :root { --ss: .44em; } .ss .colon { display: none; } .ss { margin-left: .08em; } }

/* Phone on its side: little height, so the weather becomes one line */
@media (max-height: 520px) and (orientation: landscape) {
  .app { grid-template-rows: auto 1fr auto; padding-top: max(6px, env(safe-area-inset-top)); padding-bottom: max(8px, env(safe-area-inset-bottom)); }
  .bar { min-height: 40px; }
  .stage { padding: 0; }
  .date { margin-top: 1vh; font-size: 15px; }
  .sync { display: none; }
  .weather { flex-direction: row; gap: 16px; padding: 8px 14px; border-radius: 14px; }
  .wx-temp { font-size: 28px; }
  .wx-hours { padding: 0 0 0 16px; border-top: 0; border-left: 1px solid var(--line); gap: 12px; }
  .wx-hours li { flex: none; }
  .wx-sun { display: none; }
}

/* En gran: only the time, the date and a quiet line of weather */
.big { grid-template-rows: 1fr auto; }
.big .bar { position: fixed; top: 0; right: 0; left: 0; z-index: 5; padding: max(10px, env(safe-area-inset-top)) var(--gutter) 0; opacity: 0; pointer-events: none; transition: opacity .3s ease; }
.big.awake .bar { opacity: 1; pointer-events: auto; }
.big .brand, .big .modes, .big #placeBtn, .big #settingsBtn { visibility: hidden; }
.big .stage { padding: 0; }
.big .sync { display: none; }
.big .zone { font-size: clamp(14px, 2vw, 24px); }
.big .date { margin-top: 3vh; color: var(--mute); font-size: clamp(16px, 3vw, 40px); }
.big .weather { gap: 3vw; width: auto; padding: 0; border: 0; background: none; box-shadow: none; }
.big .wx-hours, .big .wx-sun { display: none; }
.big .wx-temp { font-size: clamp(26px, 3.4vw, 52px); }
.big .wx-meta { font-size: clamp(12px, 1.3vw, 18px); }
.big.sleepy, .big.sleepy * { cursor: none !important; }
.big .clock { cursor: default; }
@media (max-aspect-ratio: 3/4) {
  .big .clock { flex-direction: column; align-items: center; line-height: .84; letter-spacing: -.05em; }
  .big .hm { display: flex; flex-direction: column; align-items: center; }
  .big .hm .c1 { display: none; }
  .big .ss { margin: .12em 0 0; font-size: .3em; line-height: 1; }
  [data-seconds="same"] .big .ss { margin: 0; font-size: 1em; line-height: inherit; }
  [data-seconds="same"] .big .ss .colon { display: none !important; }
}
@media (max-aspect-ratio: 1/1) { .big .weather { flex-direction: row; justify-content: center; } }

/* Timer and pomodoro */
.c-label { display: flex; align-items: center; gap: 10px; margin: 0 0 1.4vh; color: var(--mute); font-size: clamp(13px, 1.4vw, 15px); font-weight: 500; }
.c-label b { color: var(--ink-2); font-weight: 600; }
.c-label .tag { display: inline-flex; align-items: center; height: 24px; padding: 0 10px; border-radius: 99px; background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent-ink); font-size: 13px; font-weight: 600; }
.rest .c-label .tag { background: color-mix(in srgb, var(--ok) 16%, transparent); color: var(--ok); }
.count { cursor: default; }
.count.over { color: var(--accent); }
.count.idle { color: var(--ink-2); }
.c-progress { width: min(100%, var(--cw, 640px)); height: 6px; margin-top: 2.6vh; border-radius: 99px; background: var(--card-2); overflow: hidden; }
.c-progress i { display: block; height: 100%; border-radius: inherit; background: var(--accent); transform: scaleX(0); transform-origin: left center; }
.rest .c-progress i { background: var(--ok); }
.c-ctl { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 3vh; }
.c-play, .c-btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; height: 56px; border-radius: 999px; font-size: 16px; font-weight: 600; cursor: pointer; transition: transform .16s var(--ease), background-color .15s ease, border-color .15s ease; }
.c-play { min-width: 168px; padding: 0 28px; border: 0; background: var(--ink); color: var(--bg); }
.c-btn { min-width: 56px; padding: 0 18px; border: 1px solid var(--line); background: var(--card); color: var(--ink-2); font-weight: 550; font-variant-numeric: tabular-nums; }
.c-play:active, .c-btn:active, .chip:active { transform: scale(.96); }
@media (hover: hover) { .c-btn:hover { border-color: var(--faint); color: var(--ink); } .chip:hover { border-color: var(--faint); color: var(--ink); } }
.c-play .i-play, .c-play.running .i-pause { display: grid; }
.c-play .i-pause, .c-play.running .i-play, .c-play.stop .i-play, .c-play.stop .i-pause { display: none; }
.c-play.stop { background: var(--accent); color: #fff; }
.presets { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; max-width: 820px; margin-top: 2.6vh; }
.chip { display: inline-flex; align-items: center; gap: 4px; height: 38px; padding: 0 15px; border: 1px solid var(--line); border-radius: 999px; background: none; color: var(--ink-2); font-size: 14px; font-weight: 500; font-variant-numeric: tabular-nums; cursor: pointer; transition: transform .16s var(--ease), border-color .15s ease, color .15s ease; }
.chip[aria-pressed="true"] { border-color: var(--ink); background: var(--ink); color: var(--bg); }
.chip.custom { padding: 0 12px 0 6px; cursor: text; }
.chip.custom input { width: 58px; height: 30px; padding: 0 6px; border: 0; border-radius: 99px; background: none; color: var(--ink); font: 500 14px var(--sans); text-align: right; outline: none; -moz-appearance: textfield; }
.chip.custom input::-webkit-outer-spin-button, .chip.custom input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.chip.custom input::placeholder { color: var(--mute); }
.chip.custom:focus-within { border-color: var(--accent); }
.chip.custom span { color: var(--mute); }
.chip.custom input:placeholder-shown { width: 64px; text-align: center; }
.chip.custom input:placeholder-shown + span { display: none; }
.chip.custom:has(input:placeholder-shown) { padding: 0 6px; }
.pomo-plan { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 2.6vh; }
.dots { display: flex; gap: 7px; }
.dots span { width: 9px; height: 9px; border-radius: 50%; background: var(--line); }
.dots span.on { background: var(--accent); }
.seg.small button { height: 32px; font-variant-numeric: tabular-nums; }
@media (max-width: 600px) {
  .c-play { min-width: 0; flex: 1; max-width: 200px; }
  .c-ctl { width: 100%; gap: 10px; }
  .presets { gap: 7px; }
  .chip { height: 36px; padding: 0 13px; }
}
@media (max-height: 520px) and (orientation: landscape) {
  .c-progress, .c-ctl, .presets, .pomo-plan { margin-top: 1.4vh; }
  .c-play, .c-btn { height: 44px; }
  .presets { display: none; }
}
.big .presets, .big .pomo-plan { display: none; }
.big .c-ctl { opacity: 0; pointer-events: none; transition: opacity .3s ease; }
.big.awake .c-ctl { opacity: 1; pointer-events: auto; }
.big .c-progress { width: min(100%, 900px); }

/* The PiP video lives off to the side; Safari wants it in the page */
.pip-video { position: fixed; right: 0; bottom: 0; width: 2px; height: 2px; opacity: .01; pointer-events: none; }

/* Sheets */
dialog.sheet {
  width: min(440px, calc(100vw - 32px)); max-height: min(640px, calc(100dvh - 48px)); margin: auto; padding: 8px 20px 20px;
  border: 1px solid var(--line); border-radius: 22px; background: var(--card); color: var(--ink); box-shadow: 0 24px 64px rgba(0,0,0,.25);
  overflow: auto; overscroll-behavior: contain;
}
dialog.sheet::backdrop { background: rgba(10,11,14,.42); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
dialog.sheet[open] { animation: sheet-in .28s var(--ease); }
dialog.sheet[open]::backdrop { animation: fade-in .2s ease; }
@keyframes sheet-in { from { opacity: 0; transform: translateY(10px) scale(.985); } }
@keyframes fade-in { from { opacity: 0; } }
.sheet-grab { display: none; justify-content: center; padding: 4px 0 2px; }
.sheet-grab span { width: 38px; height: 5px; border-radius: 99px; background: var(--line); }
.sheet-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin: 6px -10px 14px 0; }
.sheet-head h2 { margin: 6px 0 0; font-size: 18px; font-weight: 650; letter-spacing: -.02em; }
.sheet-sub { margin: 2px 0 0; color: var(--mute); font-size: 13px; }
@media (max-width: 600px) {
  dialog.sheet { width: 100vw; max-width: 100vw; max-height: 88dvh; margin: auto 0 0; padding: 4px 18px max(20px, env(safe-area-inset-bottom)); border: 0; border-radius: 22px 22px 0 0; }
  dialog.sheet[open] { animation: sheet-up .32s var(--ease); }
  .sheet-grab { display: flex; }
  @keyframes sheet-up { from { transform: translateY(100%); } }
}
@media (prefers-reduced-motion: reduce) { dialog.sheet[open], dialog.sheet[open]::backdrop { animation: none; } }

.search { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg); color: var(--mute); }
.search:focus-within { border-color: var(--accent); }
.search input { flex: 1; min-width: 0; height: 100%; border: 0; background: none; color: var(--ink); font: 400 16px var(--sans); outline: none; }
.search input::-webkit-search-cancel-button { display: none; }
.results, .quick { margin: 0; padding: 0; list-style: none; }
.results:not(:empty) { margin-top: 8px; }
.row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 52px; padding: 8px 10px;
  border: 0; border-radius: 12px; background: none; text-align: left; cursor: pointer;
}
.row strong { display: block; font-weight: 550; }
.row small { display: block; color: var(--mute); font-size: 12.5px; }
.row time { flex: none; color: var(--ink-2); font-size: 14px; font-weight: 500; font-variant-numeric: tabular-nums; }
.row.on strong { color: var(--accent-ink); }
@media (hover: hover) { .row:hover { background: var(--card-2); } .here:hover { border-color: var(--faint); } }
.empty { padding: 14px 10px; color: var(--mute); font-size: 14px; }
.here {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 48px; margin-top: 12px; padding: 0 14px;
  border: 1px dashed var(--line); border-radius: 14px; background: none; color: var(--ink-2); font-weight: 500; cursor: pointer;
}
.here svg { color: var(--accent-ink); }
.sheet-label { margin: 20px 0 4px 10px; color: var(--mute); font: 600 11px var(--mono); letter-spacing: .1em; text-transform: uppercase; }

/* Settings drawer: grouped cards, as a native settings screen */
.settings .sheet-head { margin-bottom: 6px; }
.group { margin-top: 16px; }
.group h3 { margin: 0 0 7px 4px; color: var(--mute); font-size: 12px; font-weight: 600; letter-spacing: .01em; }
.card { border: 1px solid var(--line); border-radius: 16px; background: var(--bg); overflow: hidden; }
.row-opt { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 58px; padding: 10px 14px; }
.row-opt + .row-opt { border-top: 1px solid var(--line); }
.row-opt.stack { flex-direction: column; align-items: stretch; gap: 10px; padding: 13px 14px 14px; }
.opt-text { display: grid; gap: 2px; min-width: 0; }
.opt-text > span { font-size: 15px; font-weight: 550; }
.opt-text small { color: var(--mute); font-size: 12.5px; line-height: 1.35; }
.seg { display: inline-flex; padding: 3px; border-radius: 11px; background: var(--card-2); }
.seg.wide { display: grid; grid-auto-columns: minmax(0, 1fr); grid-auto-flow: column; }
.seg button { min-width: 0; height: 34px; padding: 0 12px; border: 0; border-radius: 8px; background: none; color: var(--mute); font-size: 14px; font-weight: 500; white-space: nowrap; cursor: pointer; transition: background-color .15s ease, color .15s ease; }
.seg.wide button { padding: 0 6px; }
.seg button[aria-pressed="true"] { background: var(--card); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.12), 0 0 0 .5px rgba(0,0,0,.04); }
@media (hover: hover) { .seg button:not([aria-pressed="true"]):hover { color: var(--ink-2); } }
.switch { position: relative; flex: none; width: 46px; height: 28px; padding: 0; border: 0; border-radius: 99px; background: var(--line); cursor: pointer; transition: background-color .2s ease; }
.switch span { position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.22); transition: transform .22s var(--ease); }
.switch[aria-checked="true"] { background: var(--ink); }
.switch[aria-checked="true"] span { background: var(--card); }
.switch[aria-checked="true"] span { transform: translateX(18px); }
@media (prefers-reduced-motion: reduce) { .switch, .switch span { transition: none; } }
.keys { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 5px; margin: 18px 4px 0; color: var(--mute); font-size: 12.5px; }
.keys kbd + kbd { margin-left: -2px; }
.keys kbd:not(:first-child) { margin-left: 8px; }
.keys kbd + kbd:not(:first-child) { margin-left: 0; }
kbd { display: inline-block; min-width: 22px; padding: 1px 6px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 6px; background: var(--bg); color: var(--ink-2); font: 500 11.5px var(--mono); text-align: center; }
@media (hover: none) { .keys { display: none; } }
.credit { margin: 12px 4px 0; color: var(--faint); font-size: 12px; }
.credit a { color: var(--mute); }

/* Weather detail */
.wx-detail-now { display: flex; align-items: center; gap: 14px; padding: 4px 0 18px; }
.wx-detail-now > span:first-child { display: grid; color: var(--accent-ink); }
.wx-detail-now strong { font-size: 56px; font-weight: 500; letter-spacing: -.055em; line-height: 1; font-variant-numeric: tabular-nums; }
.wx-detail-now p { margin: 0; color: var(--mute); font-size: 14px; }
.wx-detail-now p b { display: block; color: var(--ink); font-size: 16px; font-weight: 600; }
.wx-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 0; }
.wx-stats div { display: grid; align-content: space-between; gap: 8px; min-height: 76px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg); }
.wx-stats dt { color: var(--mute); font-size: 11.5px; line-height: 1.25; }
.wx-stats dd { margin: 0; color: var(--ink); font-size: 19px; font-weight: 600; font-variant-numeric: tabular-nums; }
.wx-stats dd.sun { font-size: 15px; white-space: nowrap; }
.wx-detail h3 { margin: 22px 0 6px; font-size: 14px; font-weight: 600; }
.wx-list { margin: 0; padding: 0; list-style: none; }
.wx-list li { display: grid; grid-template-columns: 44px 24px minmax(0, 1fr) auto; align-items: center; gap: 10px; min-height: 46px; border-bottom: 1px solid var(--line); color: var(--ink-2); font-size: 13px; }
.wx-list li:last-child { border-bottom: 0; }
.wx-list time, .wx-list strong { font-variant-numeric: tabular-nums; }
.wx-list svg { color: var(--accent-ink); }
.wx-list strong { color: var(--ink); font-size: 15px; font-weight: 600; text-align: right; }
.wx-list .rain { color: var(--accent-ink); font-weight: 600; }
.wx-list .days { grid-template-columns: 74px 24px minmax(0, 1fr) auto; }
