/* מצפן ההוקרות - design system
   palette: deep blue (trust/depth), warm gold (abundance), warm paper white */

/* one palette, both themes: light-dark(light, dark). The effective theme is
   color-scheme - auto by default, forced via data-theme (the header toggle). */
:root {
  color-scheme: light dark;
  --bg: light-dark(#F7F3EB, #0F1B29);
  --card: light-dark(#FFFFFF, #182A3D);
  --ink: light-dark(#1B2A3A, #E8E3D8);
  --muted: light-dark(#5C6878, #9AA7B6);
  --blue: light-dark(#16324F, #A8C5E0);
  --blue-deep: light-dark(#0F2438, #0A1622);
  --blue-soft: light-dark(#E9EEF4, #22354C);
  --gold: #C89B3C;
  --gold-ink: light-dark(#7A5A15, #E0C077);
  --gold-soft: light-dark(#F6EDD8, #3B3120);
  --line: light-dark(#E8E1D3, #2A3B4F);
  --danger: light-dark(#B4544B, #D98980);
  --ctx-life: light-dark(#356E4E, #7FBF9C);
  --ctx-life-bg: light-dark(#E9F2ED, #1E3328);
  --ctx-love: light-dark(#A24840, #E09A92);
  --ctx-love-bg: light-dark(#F8ECEA, #3A2523);
  --ctx-whole: light-dark(#6A5CA8, #A99BD8);
  --ctx-whole-bg: light-dark(#EFECF7, #2A2540);
  --radius: 18px;
  --shadow: 0 1px 2px light-dark(rgba(22, 50, 79, .05), rgba(0, 0, 0, .3)),
            0 10px 28px light-dark(rgba(22, 50, 79, .07), rgba(0, 0, 0, .35));
  --tabbar-h: 64px;
}

:root[data-theme="light"] { color-scheme: light; }

:root[data-theme="dark"] { color-scheme: dark; }

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Heebo', 'Segoe UI', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  min-height: 100dvh;
}

/* ---------- header ---------- */

.top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px 12px;
  padding-top: calc(14px + env(safe-area-inset-top));
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 19px;
  color: var(--blue);
}

.brand svg { display: block; }

.top-actions { display: flex; align-items: center; gap: 2px; }

.chip-streak {
  display: flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--gold-ink);
  font-weight: 600;
  font-size: 14px;
  padding: 7px 13px;
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  box-shadow: var(--shadow);
}

.chip-streak .n { font-weight: 800; font-size: 16px; color: var(--ink); font-variant-numeric: tabular-nums; }

.chip-streak.bump { animation: bump .5s ease; }

@keyframes bump {
  0% { transform: scale(1); }
  40% { transform: scale(1.18); }
  100% { transform: scale(1); }
}

/* ---------- layout ---------- */

main {
  max-width: 480px;
  margin: 0 auto;
  padding: 18px 18px calc(var(--tabbar-h) + 28px + env(safe-area-inset-bottom));
}

/* the entrance plays on a tab switch only; a save re-renders in place */
.screen.enter { animation: fadeup .2s ease-out; }

@keyframes fadeup {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.eyebrow {
  color: var(--muted);
  font-size: 14px;
  margin: 2px 0 2px;
}

h1.title {
  font-size: 24px;
  font-weight: 800;
  margin: 0 0 4px;
  color: var(--blue);
  scroll-margin-top: 84px; /* keeps a focus-scrolled title clear of the sticky header */
}

.subtitle { color: var(--muted); font-size: 15px; margin: 0 0 18px; }

h2.section {
  font-size: 16px;
  font-weight: 600;
  color: var(--blue);
  margin: 26px 0 10px;
}

/* ---------- cards ---------- */

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}

.card + .card { margin-top: 14px; }

/* ---------- forms ---------- */

.field { margin-bottom: 16px; }

.field label {
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: 15px;
  margin-bottom: 7px;
  color: var(--blue);
}

.num {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--gold-soft);
  color: var(--gold-ink);
  font-size: 13px;
  font-weight: 800;
  flex: none;
}

textarea, input[type="text"], input[type="search"] {
  width: 100%;
  border: 1.5px solid var(--line);
  border-radius: 14px;
  background: var(--card);
  color: var(--ink);
  font: inherit;
  padding: 12px 14px;
  resize: none;
  transition: border-color .16s ease, box-shadow .16s ease;
}

textarea:focus, input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(200, 155, 60, .18);
}

::placeholder { color: #A9B1BC; }

.hint { color: var(--muted); font-size: 13.5px; margin: 6px 2px 0; }

/* ---------- buttons ---------- */

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  border: 0;
  border-radius: 15px;
  min-height: 52px;
  font-family: inherit;
  font-size: 16.5px;
  font-weight: 600;
  cursor: pointer;
  transition: transform .12s ease, opacity .16s ease, background .16s ease;
}

.btn:active { transform: scale(.985); }

.btn:disabled { opacity: .45; cursor: default; transform: none; }

.btn-primary { background: light-dark(#16324F, #2C5983); color: #fff; }

.btn-primary:not(:disabled):hover { background: light-dark(#0F2438, #37699A); }

.btn-gold {
  background: linear-gradient(135deg, #D8B25C, var(--gold));
  color: #3B2D0D;
  box-shadow: 0 6px 18px rgba(200, 155, 60, .35);
}

.btn-ghost {
  background: transparent;
  color: var(--blue);
  border: 1.5px solid var(--line);
}

.btn-row { display: flex; gap: 10px; margin-top: 16px; }

.btn-row .btn { flex: 1; }

.linklike {
  background: none;
  border: 0;
  color: var(--muted);
  font: inherit;
  font-size: 14.5px;
  cursor: pointer;
  padding: 8px;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------- wizard chips and contexts ---------- */

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 44px; /* thumb-sized: these are the main controls of the daily flow */
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  border-radius: 999px;
  padding: 7px 16px;
  font: inherit;
  font-size: 14px;
  cursor: pointer;
  transition: background .15s ease, border-color .15s ease;
}

.chip:hover, .chip.on {
  background: var(--gold-soft);
  border-color: var(--gold);
  color: var(--gold-ink);
}

.ctx-grid { display: grid; gap: 10px; margin-top: 10px; }

.ctx {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  padding: 14px 16px;
  font: inherit;
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}

.ctx .ic {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  flex: none;
}

.ctx[data-ctx="life"] .ic { background: var(--ctx-life-bg); color: var(--ctx-life); }
.ctx[data-ctx="love"] .ic { background: var(--ctx-love-bg); color: var(--ctx-love); }
.ctx[data-ctx="whole"] .ic { background: var(--ctx-whole-bg); color: var(--ctx-whole); }

.ctx .sub { display: block; font-weight: 400; font-size: 13.5px; color: var(--muted); }

.ctx.on { border-color: var(--gold); background: var(--gold-soft); }

/* ---------- today: incremental entries ---------- */

.progress-row {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0 2px 16px;
}

.pdot {
  width: 26px;
  height: 5px;
  border-radius: 999px;
  background: var(--line);
}

.pdot.on { background: var(--gold); }

.pextra { font-size: 12.5px; font-weight: 600; color: var(--gold-ink); }

.ptxt { font-size: 13.5px; color: var(--muted); margin-inline-start: 4px; }

.entry {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px 16px;
  margin-bottom: 12px;
}

.entry.expanded { border-inline-start: 3px solid var(--gold); }

.entry-head { display: flex; align-items: flex-start; gap: 10px; }

.entry-main { flex: 1; min-width: 0; }

.entry-label, .item-label {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--gold-ink);
  margin-bottom: 3px;
}

.entry-text { margin: 0; font-size: 16px; line-height: 1.5; }

.arc-item { padding: 10px 2px; }

.arc-item + .arc-item { border-top: 1px solid var(--line); }

.arc-item p { margin: 0; font-size: 15px; line-height: 1.5; }

.exp-block .item-label { color: var(--gold-ink); }

.entry .tagrow { margin-top: 10px; }

.entry-actions { display: flex; gap: 8px; margin-top: 12px; }

.offer {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
  font-size: 14px;
  color: var(--muted);
}

.offer-btns { display: flex; gap: 8px; margin-top: 9px; }

.btn-mini {
  border: 1.5px solid var(--line);
  background: var(--card);
  color: var(--ink);
  border-radius: 12px;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  padding: 9px 16px;
  min-height: 42px;
  cursor: pointer;
}

.btn-mini.gold {
  border: 0;
  background: linear-gradient(135deg, #D8B25C, var(--gold));
  color: #3B2D0D;
}

.composer label {
  display: block;
  font-weight: 600;
  font-size: 15px;
  color: var(--blue);
  margin-bottom: 7px;
}

.composer .btn { margin-top: 12px; }

.nudge {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  background: var(--gold-soft);
  color: var(--gold-ink);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 14px;
}

.nudge strong { display: block; font-size: 15px; }

.nudge span { font-size: 13.5px; opacity: .9; }

.tag-partial { background: var(--blue-soft); color: var(--muted); font-weight: 400; }

/* ---------- success / archive cards ---------- */

.milestone-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  background: linear-gradient(135deg, #D8B25C, var(--gold));
  color: #3B2D0D;
  font-weight: 800;
  font-size: 16.5px;
  border-radius: 15px;
  padding: 14px 16px;
  margin-bottom: 16px;
  box-shadow: 0 6px 22px rgba(200, 155, 60, .4);
}

/* the ceremony plays once, when the milestone is reached; later renders of
   the same day show the banner at rest */
.milestone-banner.fresh { animation: msin .6s cubic-bezier(.2, 1.4, .4, 1); }

@keyframes msin {
  from { opacity: 0; transform: scale(.7); }
  to { opacity: 1; transform: none; }
}

.hero-streak .next-ms { font-size: 13.5px; opacity: .7; margin-top: 4px; }

.badge-saved {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: var(--gold-soft);
  color: var(--gold-ink);
  font-weight: 600;
  font-size: 14px;
  border-radius: 999px;
  padding: 6px 14px;
  margin-bottom: 12px;
}

.exp-block {
  border-inline-start: 3px solid var(--gold);
  background: linear-gradient(180deg, light-dark(#FDFBF5, #1E2F44), light-dark(#FBF6EA, #23344B));
  border-radius: 12px;
  padding: 13px 15px;
  margin: 10px 0;
}

.exp-block .action { font-size: 16.5px; font-weight: 600; color: var(--ink); margin: 0 0 9px; }

.tagrow { display: flex; flex-wrap: wrap; gap: 7px; }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 600;
  padding: 4px 12px;
}

.tag-value { background: var(--gold-soft); color: var(--gold-ink); }
.tag-ms { background: linear-gradient(135deg, #D8B25C, var(--gold)); color: #3B2D0D; margin-inline-start: 6px; }
.tag-life { background: var(--ctx-life-bg); color: var(--ctx-life); }
.tag-love { background: var(--ctx-love-bg); color: var(--ctx-love); }
.tag-whole { background: var(--ctx-whole-bg); color: var(--ctx-whole); }

.day-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}

.day-date { font-weight: 600; font-size: 15px; color: var(--blue); }

.iconbtn {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: background .15s ease, color .15s ease;
}

.iconbtn:hover { background: var(--blue-soft); color: var(--blue); }

.iconbtn.danger:hover { background: var(--ctx-love-bg); color: var(--danger); }

.day-actions { display: flex; gap: 8px; }

/* ---------- empty state ---------- */

.empty {
  text-align: center;
  color: var(--muted);
  padding: 44px 20px;
}

.empty svg { opacity: .5; margin-bottom: 14px; }

.empty p { margin: 0; font-size: 15px; }

/* ---------- journey / stats ---------- */

.hero-streak {
  text-align: center;
  background: linear-gradient(160deg, light-dark(#16324F, #1D3A57), light-dark(#0F2438, #12263B));
  color: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 26px 18px 22px;
}

.hero-streak .big { font-size: 46px; font-weight: 800; line-height: 1.15; color: #F0DDAE; font-variant-numeric: tabular-nums; }

.hero-streak .lbl { font-size: 15px; opacity: .85; }

.statgrid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}

.stat {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  text-align: center;
  padding: 12px 6px;
}

.stat .v {
  font-variant-numeric: tabular-nums; font-size: 22px; font-weight: 800; color: var(--blue); }

.stat .k { font-size: 12.5px; color: var(--muted); }

.bar-row { margin: 12px 0 0; }

.bar-row .bar-head {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 5px;
}

.bar-row .count { color: var(--muted); font-weight: 400; }

.bar {
  height: 9px;
  border-radius: 999px;
  background: var(--bg);
  overflow: hidden;
}

.bar > i {
  display: block;
  height: 100%;
  border-radius: 999px;
  width: 0; /* set on render; a transition on a freshly inserted node has no start value and never played */
}

.bar-life > i { background: var(--ctx-life); }
.bar-love > i { background: var(--ctx-love); }
.bar-whole > i { background: var(--ctx-whole); }

details.guide {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 4px 18px;
  margin-top: 14px;
}

details.guide summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--blue);
  padding: 13px 0;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

details.guide summary::-webkit-details-marker { display: none; }

details.guide summary::after {
  content: "";
  width: 9px;
  height: 9px;
  border-inline-start: 2px solid var(--muted);
  border-block-end: 2px solid var(--muted);
  transform: rotate(45deg);
  transition: transform .2s ease;
  flex: none;
}

details.guide[open] summary::after { transform: rotate(-135deg); }

details.guide .body { padding: 0 0 16px; color: var(--ink); font-size: 15px; }

.formula {
  background: var(--gold-soft);
  border-radius: 12px;
  padding: 12px 15px;
  font-weight: 600;
  color: var(--gold-ink);
  margin: 10px 0;
}

.guide ol { padding-inline-start: 20px; margin: 8px 0; }

.guide li { margin-bottom: 6px; }

.privacy-note {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  color: var(--muted);
  font-size: 13.5px;
  margin-top: 14px;
  padding: 0 4px;
}

.privacy-note svg { flex: none; margin-top: 2px; }

.credit {
  text-align: center;
  color: var(--muted);
  font-size: 12.5px;
  margin-top: 26px;
  padding: 0 10px;
}

/* ---------- tab bar ---------- */

.tabbar {
  position: fixed;
  bottom: 0;
  inset-inline: 0;
  z-index: 30;
  display: flex;
  justify-content: center;
  gap: 4px;
  background: color-mix(in srgb, light-dark(#FFFFFF, #14263A) 92%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
  padding: 6px 10px calc(6px + env(safe-area-inset-bottom));
}

.tabbar button {
  flex: 1;
  max-width: 160px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  border: 0;
  background: none;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  padding: 7px 4px 5px;
  border-radius: 12px;
  cursor: pointer;
  transition: color .15s ease;
}

.tabbar button.on { color: var(--blue); }

.tabbar button.on svg { color: var(--gold); }

/* ---------- dialog ---------- */

/* entry: fade and settle from 8 px below (@starting-style); older engines
   just open, as before. A modal keeps its centre origin. */
dialog:not([open]) {
  opacity: 0;
  transform: translateY(8px) scale(.98);
  transition: opacity .2s ease-out, transform .2s ease-out, overlay .2s allow-discrete, display .2s allow-discrete;
}

dialog[open] {
  opacity: 1;
  transform: none;
  transition: opacity .2s ease-out, transform .2s ease-out, overlay .2s allow-discrete, display .2s allow-discrete;
  @starting-style { opacity: 0; transform: translateY(8px) scale(.98); }
}

dialog {
  border: 0;
  border-radius: var(--radius);
  box-shadow: 0 24px 64px rgba(15, 36, 56, .3);
  padding: 20px;
  width: min(92vw, 440px);
  max-height: 86dvh;
  overflow-y: auto;
  background: var(--card);
  color: var(--ink);
  font-family: inherit;
}

dialog::backdrop { background: rgba(15, 36, 56, .45); backdrop-filter: blur(2px); }

dialog h3 { margin: 0 0 10px; font-size: 18px; font-weight: 800; color: var(--blue); }

.dlg-intro {
  margin: 0 0 16px;
  padding: 12px 14px;
  background: var(--blue-soft);
  border-radius: 12px;
  font-size: 14.5px;
  line-height: 1.5;
  color: var(--ink);
}

.dlg-intro b { font-weight: 600; color: var(--blue); }

.hint a { color: var(--gold-ink); }

.values { font-size: 16px; line-height: 2; margin: 0; }

/* keep the actions reachable on a short phone screen without hunting for them */
dialog .btn-row {
  position: sticky;
  bottom: -20px;
  background: var(--card);
  padding-block: 12px;
  margin-bottom: 0;
  box-shadow: 0 -10px 16px -12px rgba(0, 0, 0, .3);
}

/* ---------- toast ---------- */

#toast {
  position: fixed;
  bottom: calc(var(--tabbar-h) + 20px + env(safe-area-inset-bottom));
  inset-inline: 0;
  display: flex;
  justify-content: center;
  z-index: 50;
  pointer-events: none;
}

/* one element, class-toggled: a second message while the first shows just
   swaps the text (a transition retargets; a keyframe would restart) */
#toast .msg {
  background: light-dark(#0F2438, #2C5983);
  color: #fff;
  border-radius: 999px;
  padding: 10px 20px;
  font-size: 14.5px;
  box-shadow: var(--shadow);
  display: none;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .2s ease-out, transform .2s ease-out, display .2s allow-discrete;
}

#toast .msg.show {
  display: block;
  opacity: 1;
  transform: none;
  @starting-style { opacity: 0; transform: translateY(10px); }
}

/* ---------- confetti canvas ---------- */

#fx {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 60;
}

/* ---------- misc ---------- */

/* archive date filters */
.filter-row {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.filter-row .fld { flex: 1; min-width: 130px; }

.filter-row label {
  display: block;
  font-size: 12.5px;
  color: var(--muted);
  margin-bottom: 4px;
}

.filter-row input {
  width: 100%;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  color: var(--ink);
  font: inherit;
  font-size: 15px;
  padding: 9px 12px;
  min-height: 44px;
}

.filter-row .linklike { padding: 10px 4px; }

/* backfill: writing for a day other than today */
.daypick {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 18px;
  padding: 12px 16px;
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 14px;
}

.daypick input {
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--card);
  color: var(--ink);
  font: inherit;
  font-size: 15px;
  padding: 8px 12px;
  min-height: 44px;
}

.backfill-note {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: var(--gold-soft);
  color: var(--gold-ink);
  border-radius: 14px;
  padding: 9px 14px;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 14px;
}

.backfill-note .linklike { color: var(--gold-ink); padding: 10px 6px; min-height: 44px; }

.noscript-msg { text-align: center; padding: 24px; }

[hidden] { display: none !important; }

/* notice bars: install offer, update available */
.notice-bar {
  display: flex;
  align-items: center;
  gap: 11px;
  max-width: 480px;
  margin: 14px auto 0;
  padding: 12px 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.notice-bar .ib-icon { color: var(--gold); flex: none; }

.ib-txt { flex: 1; min-width: 0; line-height: 1.5; }

.ib-txt strong { display: block; font-size: 14.5px; font-weight: 600; color: var(--blue); }

.ib-txt span { font-size: 12.5px; color: var(--muted); }

.ib-btn {
  flex: none;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, #D8B25C, var(--gold));
  color: #3B2D0D;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 600;
  padding: 10px 16px;
  min-height: 42px;
  cursor: pointer;
}

.ib-btn:active { transform: scale(.98); }

:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

@media (prefers-reduced-motion: reduce) {
  /* gentler, not zero: colour and opacity still say "this changed"; movement goes */
  *, *::before, *::after { transition-property: opacity, color, background-color, border-color, box-shadow, filter !important; }
  .screen.enter, .chip-streak.bump, .milestone-banner.fresh { animation: none; }
  #toast .msg, dialog[open], dialog:not([open]) { transform: none; }
}
