/* Gyst: punch-card chore tracker */
@font-face { font-family: 'Bricolage Grotesque'; src: url(fonts/bricolage-grotesque.woff2) format('woff2'); font-weight: 200 800; font-display: swap; }
@font-face { font-family: 'Atkinson Hyperlegible'; src: url(fonts/atkinson-400.woff2) format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Atkinson Hyperlegible'; src: url(fonts/atkinson-700.woff2) format('woff2'); font-weight: 700; font-display: swap; }
:root {
  --bg: #E8EFEC;
  --card: #FFFFFF;
  --ink: #1C2433;
  --ink-2: #566170;
  --line: #CAD5D0;
  --fern: #13895C;
  --fern-soft: #DCF1E6;
  --gold: #E9A60F;
  --gold-ink: #6B4A00;
  --gold-soft: #FCEFC7;
  --brick: #C8423A;
  --brick-soft: #F8E1DF;
  --kid: #3E63DD;
  --shadow: 0 1px 0 rgba(28, 36, 51, .06), 0 6px 18px -10px rgba(28, 36, 51, .25);
  --r-card: 18px;
  --r-ctl: 12px;
  --display: 'Bricolage Grotesque', 'Avenir Next', system-ui, sans-serif;
  --body: 'Atkinson Hyperlegible', system-ui, -apple-system, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #11171F; --card: #1A222E; --ink: #E8EDF3; --ink-2: #A0ABBA; --line: #2D3848;
    --fern: #34B37F; --fern-soft: #173A2C; --gold: #F2B935; --gold-ink: #F6D27A; --gold-soft: #3A2F12;
    --brick: #E0675F; --brick-soft: #3D2120;
    --shadow: 0 1px 0 rgba(0,0,0,.3), 0 8px 20px -12px rgba(0,0,0,.6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #11171F; --card: #1A222E; --ink: #E8EDF3; --ink-2: #A0ABBA; --line: #2D3848;
  --fern: #34B37F; --fern-soft: #173A2C; --gold: #F2B935; --gold-ink: #F6D27A; --gold-soft: #3A2F12;
  --brick: #E0675F; --brick-soft: #3D2120;
  --shadow: 0 1px 0 rgba(0,0,0,.3), 0 8px 20px -12px rgba(0,0,0,.6);
  color-scheme: dark;
}
/* Alerts and toasts: a quiet raised surface in both themes (no bright white pill in dark mode). */
:root { --raised: #1C2433; --raised-ink: #FFFFFF; --alert-bg: var(--gold-soft); --alert-ink: var(--gold-ink); --alert-edge: var(--gold); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --raised: #2A3546; --raised-ink: #E8EDF3; --alert-bg: #232C3A; --alert-ink: #E8EDF3; --alert-edge: #F2B935; --brick: #D9645C; }
}
:root[data-theme="dark"] { --raised: #2A3546; --raised-ink: #E8EDF3; --alert-bg: #232C3A; --alert-ink: #E8EDF3; --alert-edge: #F2B935; --brick: #D9645C; }

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg); color: var(--ink);
  font: 17px/1.5 var(--body);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  min-height: 100dvh;
}
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--kid); outline-offset: 2px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--display); line-height: 1.15; margin: 0; letter-spacing: -0.01em; }
h1 { font-size: 30px; font-weight: 800; }
h2 { font-size: 21px; font-weight: 700; }
h3 { font-size: 17px; font-weight: 700; }
p { margin: 0; }
.muted { color: var(--ink-2); }
.small { font-size: 14px; }
.hidden { display: none !important; }

/* ---------- Shell ---------- */
.shell { max-width: 560px; margin: 0 auto; padding: 0 16px calc(96px + env(safe-area-inset-bottom)); }
.topbar {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(10px + env(safe-area-inset-top)) 0 10px;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.wordmark { font-family: var(--display); font-weight: 800; font-size: 26px; letter-spacing: -0.04em; }
.wordmark .hole {
  display: inline-block; width: .2em; height: .2em; border-radius: 50%;
  background: var(--kid); margin-left: .07em; vertical-align: baseline;
}
.topbar-actions { display: flex; gap: 6px; align-items: center; }
.icon-btn {
  position: relative; width: 44px; height: 44px; border-radius: 50%;
  border: 0; background: transparent; display: grid; place-items: center;
}
.icon-btn:hover { background: var(--card); }
.icon-btn svg { width: 24px; height: 24px; }
.badge {
  position: absolute; top: 4px; right: 3px; min-width: 19px; height: 19px; padding: 0 5px;
  border-radius: 10px; background: var(--brick); color: #fff;
  font-size: 12px; font-weight: 700; line-height: 19px; text-align: center;
}

.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 6;
  display: flex; justify-content: center;
  background: var(--card); border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
}
.tabs-inner { display: flex; width: 100%; max-width: 560px; }
.tab {
  flex: 1; border: 0; background: none; padding: 9px 0 10px;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-size: 13px; color: var(--ink-2);
}
.tab svg { width: 24px; height: 24px; }
.tab[aria-current="page"] { color: var(--ink); font-weight: 700; }
.tab[aria-current="page"] svg { color: var(--kid); }
.tab .dot { position: relative; }
.tab .dot::after {
  content: attr(data-count); position: absolute; top: -6px; left: 16px;
  min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px;
  background: var(--brick); color: #fff; font-size: 11px; font-weight: 700; line-height: 17px;
}
.tab .dot[data-count="0"]::after, .tab .dot:not([data-count])::after { display: none; }

/* ---------- Building blocks ---------- */
.section { margin-top: 22px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.card { background: var(--card); border-radius: var(--r-card); box-shadow: var(--shadow); }
.pad { padding: 16px; }
.stack > * + * { margin-top: 12px; }
.row { display: flex; align-items: center; gap: 12px; }
.grow { flex: 1; min-width: 0; }
.list { list-style: none; margin: 0; padding: 0; }
.list > li { border-top: 1px solid var(--line); }
.list > li:first-child { border-top: 0; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 18px; border-radius: var(--r-ctl);
  border: 1.5px solid var(--line); background: var(--card); font-weight: 700;
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn:hover { border-color: var(--ink-2); }
.btn.primary { background: var(--ink); color: var(--card); border-color: var(--ink); }
.btn.go { background: var(--fern); color: #fff; border-color: var(--fern); }
.btn.money { background: var(--gold); color: #2B1E00; border-color: var(--gold); }
.btn.danger { color: var(--brick); }
.btn.quiet { border-color: transparent; background: transparent; color: var(--ink-2); }
.btn.small { min-height: 36px; padding: 0 12px; font-size: 15px; }
.btn.block { width: 100%; }
.btn:disabled { opacity: .5; cursor: default; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; }

.field { display: block; }
.field > span { display: block; font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.field small { display: block; color: var(--ink-2); margin-top: 4px; font-size: 14px; }
input[type=text], input[type=email], input[type=password], input[type=number], input[type=date], select, textarea {
  width: 100%; min-height: 46px; padding: 10px 12px;
  border: 1.5px solid var(--line); border-radius: var(--r-ctl); background: var(--card);
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--kid); }
.code-input { font-family: var(--display); font-size: 26px; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; text-align: center; }

.seg { display: flex; border: 1.5px solid var(--line); border-radius: var(--r-ctl); overflow: hidden; }
.seg label { flex: 1; position: relative; }
.seg input { position: absolute; opacity: 0; inset: 0; pointer-events: none; }
.seg span { display: block; text-align: center; padding: 10px 6px; font-weight: 700; font-size: 15px; color: var(--ink-2); }
.seg input:checked + span { background: var(--ink); color: var(--card); }
.seg input:focus-visible + span { outline: 3px solid var(--kid); outline-offset: -3px; }
.daypick { display: flex; gap: 6px; }
.daypick label { flex: 1; position: relative; }
.daypick input { position: absolute; opacity: 0; pointer-events: none; }
.daypick span { display: grid; place-items: center; height: 40px; border-radius: 10px; border: 1.5px solid var(--line); font-weight: 700; font-size: 14px; }
.daypick input:checked + span { background: var(--kid); border-color: var(--kid); color: #fff; }

.chip {
  display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 999px;
  font-size: 14px; font-weight: 700; background: var(--bg); color: var(--ink-2); white-space: nowrap;
}
.chip.money { background: var(--gold-soft); color: var(--gold-ink); }
.chip.ok { background: var(--fern-soft); color: var(--fern); }
.chip.wait { background: var(--gold-soft); color: var(--gold-ink); }
.chip.bad { background: var(--brick-soft); color: var(--brick); }
.filter-row { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; }
.filter-row button { border: 1.5px solid var(--line); background: var(--card); border-radius: 999px; padding: 6px 14px; font-weight: 700; white-space: nowrap; }
.filter-row button[aria-pressed="true"] { background: var(--ink); color: var(--card); border-color: var(--ink); }

.avatar {
  width: 44px; height: 44px; flex: none; border-radius: 50%;
  display: grid; place-items: center; font-size: 24px;
  background: color-mix(in srgb, var(--kid) 16%, var(--card));
  box-shadow: inset 0 0 0 2px var(--kid);
}
.avatar.lg { width: 64px; height: 64px; font-size: 36px; }

.empty { text-align: center; padding: 28px 16px; color: var(--ink-2); }
.empty h3 { color: var(--ink); margin-bottom: 4px; }

/* ---------- The punch (signature element) ---------- */
.punch {
  width: 46px; height: 46px; flex: none; border-radius: 50%;
  border: 2.5px dashed var(--line); background: transparent;
  display: grid; place-items: center; color: transparent;
}
.punch svg { width: 24px; height: 24px; }
.punch:hover { border-color: var(--kid); }
.punch[data-state="approved"] { border: 0; background: var(--kid); color: #fff; }
.punch[data-state="pending"] { border: 2.5px solid var(--gold); background: var(--gold-soft); color: var(--gold-ink); }
.punch[data-state="rejected"] { border: 2.5px solid var(--brick); color: var(--brick); }
.punch[data-state="locked"] { cursor: default; }
.punch.stamp { animation: stamp .26s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes stamp {
  0% { transform: scale(1.35) rotate(-14deg); }
  100% { transform: scale(1) rotate(0); }
}

.chore { display: flex; align-items: center; gap: 14px; padding: 12px 14px; }
.chore-title { font-weight: 700; display: flex; gap: 8px; align-items: center; }
.chore-meta { font-size: 14px; color: var(--ink-2); display: flex; gap: 10px; flex-wrap: wrap; margin-top: 2px; }
.chore[data-done="true"] .chore-title { color: var(--ink-2); }

/* Punch-card strip: last 14 days */
.strip { display: grid; grid-template-columns: repeat(14, 1fr); gap: 4px; max-width: 340px; }
.strip button, .strip span {
  aspect-ratio: 1; border-radius: 50%; border: 0; padding: 0; background: transparent;
  display: grid; place-items: center;
}
.strip i { display: block; width: 100%; height: 100%; border-radius: 50%; }
.strip [data-s="done"] i { background: var(--kid); }
.strip [data-s="missed"] i { box-shadow: inset 0 0 0 2px var(--brick); opacity: .8; }
.strip [data-s="open"] i { box-shadow: inset 0 0 0 2px var(--kid); border: 0; outline: 2px dashed transparent; background: color-mix(in srgb, var(--kid) 14%, transparent); }
.strip [data-s="none"] i { width: 28%; height: 28%; background: var(--line); }
.strip-labels { display: flex; justify-content: space-between; max-width: 340px; font-size: 12px; color: var(--ink-2); margin-top: 4px; }

/* Kid hero */
.hero { padding: 18px 16px; }
.hero-top { display: flex; align-items: center; gap: 14px; }
.streak-num { font-family: var(--display); font-weight: 800; font-size: 44px; line-height: 1; letter-spacing: -0.03em; }
.streak-label { font-size: 15px; color: var(--ink-2); }
.balance { font-family: var(--display); font-weight: 800; font-size: 22px; }
.bigmoney { font-family: var(--display); font-weight: 800; font-size: 52px; letter-spacing: -0.03em; line-height: 1; }

/* Kid picker / PIN pad */
.kid-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 12px; }
.kid-pick { border: 0; background: var(--card); box-shadow: var(--shadow); border-radius: var(--r-card); padding: 18px 10px; display: flex; flex-direction: column; align-items: center; gap: 8px; font-weight: 700; font-size: 18px; }
.pin-dots { display: flex; gap: 14px; justify-content: center; margin: 18px 0; }
.pin-dots i { width: 18px; height: 18px; border-radius: 50%; box-shadow: inset 0 0 0 2.5px var(--ink-2); }
.pin-dots i.on { background: var(--kid); box-shadow: none; }
.pinpad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; max-width: 300px; margin: 0 auto; }
.pinpad button { height: 62px; border-radius: 16px; border: 0; background: var(--card); box-shadow: var(--shadow); font-family: var(--display); font-size: 26px; font-weight: 700; }
.pinpad button.quiet { background: transparent; box-shadow: none; font-size: 16px; font-family: var(--body); color: var(--ink-2); }

/* Welcome */
.welcome { min-height: 100dvh; display: flex; flex-direction: column; justify-content: center; padding-top: 32px; padding-bottom: 32px; }
.welcome .wordmark { font-size: 72px; line-height: .9; }
.welcome-card-grid { display: grid; gap: 12px; margin-top: 32px; }
.role-btn { text-align: left; border: 0; background: var(--card); box-shadow: var(--shadow); border-radius: var(--r-card); padding: 18px; display: flex; align-items: center; gap: 14px; }
.role-btn strong { font-family: var(--display); font-size: 21px; display: block; }

/* Sheet */
.scrim { position: fixed; inset: 0; background: rgba(12, 17, 25, .45); z-index: 20; display: flex; align-items: flex-end; justify-content: center; }
.sheet {
  width: 100%; max-width: 560px; max-height: 92dvh; overflow: auto;
  background: var(--card); border-radius: 22px 22px 0 0; padding: 18px 16px calc(20px + env(safe-area-inset-bottom));
  animation: rise .22s ease-out;
}
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
@keyframes rise { from { transform: translateY(24px); opacity: .6; } to { transform: none; opacity: 1; } }

.toast {
  position: fixed; left: 50%; bottom: calc(86px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  z-index: 30; background: var(--raised); color: var(--raised-ink); padding: 12px 18px; border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--raised-ink) 12%, transparent);
  font-weight: 700; max-width: calc(100% - 32px); box-shadow: var(--shadow);
}
.toast.bad { background: var(--brick); color: #fff; }

.notice { border-left: 4px solid var(--alert-edge); background: var(--alert-bg); color: var(--alert-ink); padding: 10px 12px; border-radius: 8px; font-size: 15px; }
.codebox { font-family: var(--display); font-size: 30px; font-weight: 800; letter-spacing: .14em; }
.ledger-amt { font-family: var(--display); font-weight: 800; white-space: nowrap; }
.ledger-amt.plus { color: var(--fern); }
.ledger-amt.minus { color: var(--brick); }
.notif { padding: 12px 0; }
.notif.unread { background: color-mix(in srgb, var(--kid) 7%, transparent); margin: 0 -12px; padding: 12px; border-radius: 10px; }
.notif.unread strong::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--brick); margin-right: 8px; vertical-align: 2px; }
.progress { height: 8px; border-radius: 4px; background: var(--bg); overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--kid); border-radius: 4px; }
.loading { display: grid; place-items: center; min-height: 60dvh; color: var(--ink-2); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
.swatch { box-shadow: inset 0 0 0 2px rgba(0,0,0,.08); }
input:checked + .swatch { box-shadow: 0 0 0 3px var(--card), 0 0 0 5px var(--ink); }
input:focus-visible + .swatch { outline: 3px solid var(--ink); outline-offset: 3px; }

/* Drawn avatars */
.avatar svg { width: 100%; height: 100%; display: block; border-radius: 50%; }
.avatar:has(svg) { background: var(--card); overflow: hidden; }
.av-inline { display: inline-block; width: 1.35em; height: 1.35em; vertical-align: -0.3em; margin-right: 2px; }
.av-inline svg { width: 100%; height: 100%; }
.avatar-picker { display: grid; grid-template-columns: repeat(auto-fill, minmax(52px, 1fr)); gap: 8px; }
.avatar-picker label { position: relative; display: block; }
.avatar-picker input { position: absolute; opacity: 0; pointer-events: none; }
.avatar-picker span { display: block; aspect-ratio: 1; border-radius: 50%; overflow: hidden; box-shadow: inset 0 0 0 2px transparent; }
.avatar-picker span svg { width: 100%; height: 100%; display: block; }
.avatar-picker input:checked + span { box-shadow: 0 0 0 3px var(--card), 0 0 0 5px var(--ink); }
.avatar-picker input:focus-visible + span { outline: 3px solid var(--kid); outline-offset: 3px; }
.picker-group { font-size: 14px; font-weight: 700; color: var(--ink-2); margin: 10px 0 6px; }

/* Steps under a task */
.steps { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 4px; }
.step { display: flex; align-items: center; gap: 10px; border: 0; background: none; padding: 4px 0; text-align: left; width: 100%; font-size: 16px; }
.step i { width: 22px; height: 22px; flex: none; border-radius: 7px; border: 2px solid var(--line); display: grid; place-items: center; }
.step i svg { width: 14px; height: 14px; color: transparent; }
.step[aria-pressed="true"] i { background: var(--kid); border-color: var(--kid); }
.step[aria-pressed="true"] i svg { color: #fff; }
.step[aria-pressed="true"] span { color: var(--ink-2); text-decoration: line-through; text-decoration-thickness: 1.5px; }
.area-head { font-size: 14px; font-weight: 700; color: var(--ink-2); padding: 10px 14px 0; }
.chip.grad { background: color-mix(in srgb, var(--kid) 14%, var(--card)); color: var(--kid); }

/* Landing */
.landing-head { font-family: var(--display); font-weight: 800; font-size: clamp(34px, 9vw, 46px); line-height: 1.02; letter-spacing: -0.03em; margin-top: 22px; max-width: 13ch; }
.landing-sub { font-size: 19px; color: var(--ink-2); margin-top: 14px; max-width: 32ch; }
.demo-strip { display: flex; gap: 7px; margin-top: 26px; }
.demo-strip i { width: 26px; height: 26px; border-radius: 50%; background: var(--kid); }
.demo-strip i.wheel { background: transparent; box-shadow: inset 0 0 0 3px var(--kid); }
.demo-strip i { animation: punchIn .3s cubic-bezier(.3, 1.6, .5, 1) both; }
.demo-strip i:nth-child(1) { animation-delay: .05s } .demo-strip i:nth-child(2) { animation-delay: .12s }
.demo-strip i:nth-child(3) { animation-delay: .19s } .demo-strip i:nth-child(4) { animation-delay: .26s }
.demo-strip i:nth-child(5) { animation-delay: .33s } .demo-strip i:nth-child(6) { animation-delay: .40s }
.demo-strip i:nth-child(7) { animation-delay: .47s }
@keyframes punchIn { from { transform: scale(0) rotate(-20deg); } to { transform: none; } }
.uses { display: grid; gap: 10px; margin-top: 26px; }
.use { display: flex; gap: 12px; align-items: flex-start; }
.use b { font-family: var(--display); font-size: 17px; display: block; }
.use .avatar { width: 40px; height: 40px; }

/* The picture's background takes the person's color */
.avatar, .av-inline, .avatar-picker span { --av-bg: color-mix(in srgb, var(--kid) 30%, #FFFFFF); }

/* Task icons */
.ti { display: inline-flex; align-items: center; justify-content: center; flex: none; line-height: 1; }
.ti svg { width: 100%; height: 100%; display: block; }
.chore-title .ti { margin-right: 2px; }
.ticon-btn { width: 56px; height: 52px; border: 1.5px solid var(--line, #D8DEE6); border-radius: 12px; background: var(--card); display: flex; align-items: center; justify-content: center; padding: 0; cursor: pointer; }
.ticon-btn:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }
.icon-picker { padding: 12px; box-shadow: none; background: var(--bg); max-height: 340px; overflow-y: auto; }
.ti-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(48px, 1fr)); gap: 6px; }
.ti-opt { aspect-ratio: 1; border: 0; background: none; padding: 2px; border-radius: 14px; cursor: pointer; }
.ti-opt svg { width: 100%; height: 100%; display: block; }
.ti-opt.on { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--ink); }
.ti-opt:focus-visible { outline: 3px solid var(--ink); outline-offset: 1px; }
.style-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.style-opt { position: relative; display: block; cursor: pointer; }
.style-opt input { position: absolute; opacity: 0; pointer-events: none; }
.style-opt > span { display: flex; flex-direction: column; gap: 4px; padding: 10px; border-radius: 12px; border: 1.5px solid var(--line, #D8DEE6); background: var(--card); }
.style-opt input:checked + span { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.style-opt input:focus-visible + span { outline: 3px solid var(--ink); outline-offset: 2px; }

/* Stale-tab guard */
#stale { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 16px;
  background: rgba(17, 23, 31, .55); }
#stale .card { max-width: 360px; width: 100%; }

/* Kid filters on the Tasks tab: just the picture; the name shows on hover */
.filter-row .kid-filter { padding: 2px; width: 40px; height: 40px; flex: none; display: flex; align-items: center; justify-content: center; }
.filter-row .kid-filter .avatar { width: 32px; height: 32px; border-radius: 50%; overflow: hidden; display: block; }
.filter-row .kid-filter .avatar svg { width: 100%; height: 100%; display: block; }
.filter-row .kid-filter[aria-pressed="true"] { background: var(--card); border-color: var(--ink); box-shadow: 0 0 0 2px var(--ink); }
.filter-row button { min-height: 40px; }


/* Step editor: one row per step */
.step-edit { list-style: none; margin: 0 0 8px; padding: 0; display: grid; gap: 6px; counter-reset: step; }
.step-edit:empty { display: none; }
.step-edit li { display: flex; align-items: center; gap: 8px; counter-increment: step; }
.step-edit li::before { content: counter(step) "."; width: 20px; text-align: right; color: var(--ink-2); font-weight: 700; font-size: 14px; flex: none; }
.step-edit input { flex: 1; min-width: 0; }
.step-x { width: 40px; height: 40px; flex: none; border: 1.5px solid var(--line); border-radius: var(--r-ctl); background: var(--card); color: var(--ink-2); font-size: 22px; line-height: 1; cursor: pointer; }
.step-x:hover { color: var(--brick); border-color: var(--brick); }

/* Days-of-month picker */
.monthpick { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.monthpick label { position: relative; }
.monthpick input { position: absolute; opacity: 0; pointer-events: none; }
.monthpick span { display: grid; place-items: center; height: 38px; border-radius: 10px; border: 1.5px solid var(--line); font-weight: 700; font-size: 14px; }
.monthpick input:checked + span { background: var(--kid); border-color: var(--kid); color: #fff; }
.monthpick input:focus-visible + span { outline: 3px solid var(--ink); outline-offset: 2px; }

/* A checkbox with a label and a hint */
.check-row { display: flex; gap: 10px; align-items: flex-start; }
.check-row input { width: 22px; height: 22px; margin-top: 2px; flex: none; accent-color: var(--ink); }

/* Who picker: one chip per person */
.who-pick { display: flex; flex-wrap: wrap; gap: 8px; }
.who-pick label { position: relative; }
.who-pick input { position: absolute; opacity: 0; pointer-events: none; }
.who-pick > label > span { display: flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--card); font-weight: 700; }
.who-pick .avatar { width: 30px; height: 30px; font-size: 16px; }
.who-pick .avatar svg { width: 100%; height: 100%; border-radius: 50%; }
.who-pick input:checked + span { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); background: color-mix(in srgb, var(--kid) 14%, var(--card)); }
.who-pick input:focus-visible + span { outline: 3px solid var(--ink); outline-offset: 2px; }

/* Allowance card: green = protected, red = something due today could cost money */
.allowance { border-left: 6px solid var(--fern); }
.allowance.risk { border-left-color: var(--brick); }
.allowance-amt { font-family: var(--display); font-size: 30px; font-weight: 800; color: var(--fern); }
.allowance.risk .allowance-amt { color: var(--brick); }
.allowance-status { margin: 0; font-weight: 700; color: var(--fern); }
.allowance.risk .allowance-status { color: var(--brick); }
.misses { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: 14px; }
.misses li { display: flex; justify-content: space-between; gap: 8px; }

/* A parent's note on something sent back */
.sentback { margin-top: 8px; padding: 10px 12px; border-radius: 10px; background: var(--brick-soft); color: var(--ink); border-left: 4px solid var(--brick); font-size: 15px; }
.sentback strong { color: var(--brick); }
.sentback .small { margin-top: 4px; color: var(--ink-2); }
button.chip { border: 1.5px solid var(--line); background: var(--card); cursor: pointer; }
.sendback-btn { background: var(--brick); color: #fff; border-color: var(--brick); }

/* Money tab */
.money-top { text-align: center; }
.money-top .period-tabs { justify-content: center; }
.breakdown { list-style: none; margin: 12px auto 0; padding: 0; display: grid; gap: 6px; max-width: 320px; text-align: left; }
.breakdown li { display: flex; justify-content: space-between; border-bottom: 1px dashed var(--line); padding-bottom: 4px; }
.breakdown .minus { color: var(--brick); }
.paid-line { margin: 12px 0 0; color: var(--ink-2); }
.paid-line.owed { color: var(--fern); }
.allowance-big { margin: 0; font-family: var(--display); font-size: 24px; font-weight: 800; color: var(--fern); }
.history .area-head { padding-top: 12px; }
.period-tabs { flex-wrap: wrap; overflow: visible; }
.period-tabs button { padding: 6px 12px; }
.ledger-amt.neutral { color: var(--ink-2); }
.holiday-note { color: var(--gold-ink); font-weight: 700; }
.holiday-note:empty { display: none; }
.holiday-banner { background: var(--gold-soft); color: var(--gold-ink); font-weight: 700; text-align: center; }

/* Tasks tab rows: icon | title / when / tags | money */
.task-row { width: 100%; border: 0; background: none; text-align: left; align-items: flex-start; color: inherit; font: inherit; cursor: pointer; }
.task-row > .ti { margin-top: 2px; }
.task-when { font-size: 14px; color: var(--ink-2); margin-top: 2px; }
.task-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.task-tags .chip { font-size: 13px; padding: 2px 9px; }
.task-money { display: flex; flex-direction: column; align-items: flex-end; min-width: 72px; padding-top: 2px; }
.task-amt { font-family: var(--display); font-weight: 800; font-size: 16px; white-space: nowrap; }
.task-amt.plus { color: var(--fern); }
.task-amt.minus { color: var(--brick); }
.task-amt-label { font-size: 12px; color: var(--ink-2); }

/* Type groups: Required / Reminders / Extra money / Jobs */
.type-head { display: flex; justify-content: space-between; padding: 10px 14px 4px; border-top: 1px solid var(--line);
  font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); }
.type-label { margin: 14px 2px 0; font-weight: 800; font-size: 15px; }
.type-label .muted { font-weight: 400; margin-left: 4px; }

/* Goals */
.goal-row .goal-bar { height: 8px; border-radius: 999px; background: var(--bg); margin: 6px 0 2px; overflow: hidden; max-width: 260px; }
.goal-row .goal-bar i { display: block; height: 100%; background: var(--kid); border-radius: 999px; }
.goal-row.hit .goal-bar i { background: var(--fern); }
.goal-add { font-family: var(--display); font-weight: 800; font-size: 16px; }
.goal-add[disabled] { opacity: .55; cursor: default; }
.linklike { border: 0; background: none; padding: 0; color: var(--ink-2); text-decoration: underline; cursor: pointer; font: inherit; }
.chip.streak { background: var(--gold-soft); color: var(--gold-ink); }

/* Collapsible kid cards on Today */
.kid-card-head { display: flex; gap: 12px; align-items: center; width: 100%; padding: 14px; border: 0; background: none; text-align: left; color: inherit; font: inherit; cursor: pointer; }
.kid-card-head .kid-name { font-family: var(--display); font-size: 20px; }
.kid-card-side { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.kid-card-side .chev { color: var(--ink-2); font-size: 14px; }
.kid-card-head .progress { max-width: 220px; }

/* Task form: type first, then numbered questions */
.taskform { counter-reset: tf; }
.tf-block { display: grid; gap: 10px; }
.tf-q { margin: 0; font-family: var(--display); font-size: 19px; }
.tf-num { padding-top: 16px; border-top: 1px solid var(--line); }
.tf-num .tf-q::before { counter-increment: tf; content: counter(tf); display: inline-grid; place-items: center;
  width: 26px; height: 26px; margin-right: 10px; border-radius: 50%; background: var(--ink); color: var(--card); font-size: 14px; vertical-align: 2px; }
.type-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.type-card { position: relative; cursor: pointer; }
.type-card input { position: absolute; opacity: 0; pointer-events: none; }
.type-card > span { display: grid; gap: 4px; height: 100%; padding: 14px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card); }
.type-card .type-glyph { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--bg); font-size: 18px; font-weight: 800; }
.type-card strong { font-size: 17px; }
.type-card small { color: var(--ink-2); line-height: 1.35; }
.type-card input:checked + span { border-color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.type-card input:checked + span .type-glyph { background: var(--ink); color: var(--card); }
.type-card input:focus-visible + span { outline: 3px solid var(--ink); outline-offset: 2px; }
.taskform:has(input[name=kind]:checked) .type-card > span { padding: 10px 12px; }
.taskform:has(input[name=kind]:checked) .type-card small { display: none; }
.seg-wrap { flex-wrap: wrap; }
.tf-more { border-top: 1px solid var(--line); padding-top: 14px; }
.tf-more summary { cursor: pointer; font-weight: 800; font-size: 16px; list-style: none; }
.tf-more summary::before { content: '+ '; }
.tf-more[open] summary::before { content: '− '; }
.seg-wrap label { flex: 1 1 30%; } .seg-wrap span { white-space: nowrap; }
.punch.goal-add { border: 2.5px solid var(--kid); color: var(--kid); background: color-mix(in srgb, var(--kid) 10%, transparent); }
.punch.goal-add[disabled] { border: 0; background: var(--kid); color: #fff; opacity: 1; }

/* Stars and the Store */
.star-chip { margin-top: 6px; border: 0; border-radius: 999px; padding: 3px 10px; background: var(--gold-soft); color: var(--gold-ink); font-weight: 800; cursor: pointer; }
.store-top { display: flex; gap: 14px; align-items: center; }
.bigstars { font-family: var(--display); font-size: 40px; font-weight: 800; color: var(--gold); line-height: 1.1; }
.store-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; }
.store-item { display: grid; justify-items: center; gap: 4px; padding: 10px 6px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card); cursor: pointer; color: inherit; font: inherit; }
.store-item .store-av { width: 56px; height: 56px; }
.store-item .store-av svg { width: 100%; height: 100%; border-radius: 50%; }
.store-item.locked { background: var(--bg); border-style: dashed; }
.store-mystery { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: color-mix(in srgb, var(--ink) 10%, var(--card)); color: var(--ink-2); font: 800 28px/1 var(--display); }
.store-state.lock { color: var(--ink-2); font-weight: 700; }
.store-item.wearing { border-color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.store-name { font-weight: 700; font-size: 14px; }
.store-state { font-size: 13px; font-weight: 800; color: var(--ink-2); }
.store-state.on { color: var(--fern); }
.store-state.price { color: var(--gold-ink); background: var(--gold-soft); padding: 1px 8px; border-radius: 999px; }
.store-state.price.short { opacity: .6; }

/* A kid's first sign-in */
.welcome-kid { text-align: center; padding-top: 28px; padding-bottom: 40px; }
.welcome-kid h1 { margin: 8px 0 4px; }
.avatar.xl { width: 120px; height: 120px; margin: 8px auto; }
.avatar.xl svg { width: 100%; height: 100%; border-radius: 50%; }
.welcome-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 12px; }
.welcome-pic { display: grid; justify-items: center; gap: 4px; padding: 8px 2px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card); color: inherit; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.welcome-pic .avatar { width: 48px; height: 48px; }
.welcome-pic .avatar svg { width: 100%; height: 100%; border-radius: 50%; }
.welcome-pic.on { border-color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.welcome-color { width: 44px; height: 44px; border-radius: 50%; border: 3px solid var(--card); box-shadow: 0 0 0 1.5px var(--line); cursor: pointer; }
.welcome-color.on { box-shadow: 0 0 0 3px var(--ink); }
.tour { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 12px; text-align: left; }
.tour li { display: flex; gap: 12px; align-items: center; padding: 12px; border-radius: 14px; background: var(--card); box-shadow: var(--shadow); }
.tour-num { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--kid); color: #fff; font-weight: 800; flex: none; }
.tour-ic svg { width: 26px; height: 26px; stroke: var(--kid); }

/* ---------- Icon backgrounds: a hairline so a White background still reads ---------- */
.avatar:has(svg), .welcome-color.bg { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 10%, transparent); }
.welcome-color.bg { border-color: var(--card); }
.welcome-color.bg.on { box-shadow: 0 0 0 3px var(--ink); }

/* ---------- Mystery packs ---------- */
.pack-card { display: flex; align-items: center; gap: 14px; }
.pack-art { width: 56px; height: 56px; flex: none; }
.pack-art svg, .pack-box svg { width: 100%; height: 100%; display: block; }
.pack-card.ready .pack-art { animation: wiggle 2.4s ease-in-out infinite; }
@keyframes wiggle { 0%, 80%, 100% { transform: rotate(0); } 84% { transform: rotate(-9deg); } 90% { transform: rotate(8deg); } 95% { transform: rotate(-4deg); } }
.pack-overlay { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; padding: 16px;
  background: color-mix(in srgb, #0B1018 72%, transparent); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.pack-stage { position: relative; display: grid; justify-items: center; gap: 18px; width: min(340px, 100%); }
.pack-box { width: 150px; height: 150px; }
.pack-box.shake { animation: shake .32s ease-in-out infinite; }
@keyframes shake { 0%, 100% { transform: rotate(0) scale(1); } 25% { transform: rotate(-7deg) scale(1.03); } 75% { transform: rotate(7deg) scale(1.03); } }
.pack-reel { min-height: 1.4em; font: 800 26px/1.2 var(--display); color: #fff; text-align: center; letter-spacing: -0.01em; }
.pack-reveal { position: relative; z-index: 2; width: 100%; background: var(--card); color: var(--ink); border-radius: 22px; padding: 22px 18px 18px; text-align: center; box-shadow: 0 20px 50px -20px rgba(0,0,0,.6);
  animation: flipin .55s cubic-bezier(.2,.9,.3,1.3) both; }
@keyframes flipin { from { transform: perspective(700px) rotateY(90deg) scale(.7); opacity: 0; } to { transform: none; opacity: 1; } }
.pack-kind { font-weight: 800; color: var(--kid); text-transform: uppercase; letter-spacing: .08em; font-size: 13px; margin-top: 4px; }
.pack-name { font-size: 28px; }
.pack-rays { position: absolute; left: 50%; top: 50%; width: 520px; height: 520px; margin: -260px 0 0 -260px; z-index: 1; pointer-events: none;
  background: repeating-conic-gradient(from 0deg, rgba(255,201,60,.22) 0 10deg, transparent 10deg 24deg);
  -webkit-mask: radial-gradient(circle, #000 25%, transparent 68%); mask: radial-gradient(circle, #000 25%, transparent 68%);
  animation: spin 9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.pack-bit { position: absolute; left: 50%; top: 40%; width: 10px; height: 14px; border-radius: 2px; background: var(--c); z-index: 3; pointer-events: none;
  animation: burst .9s ease-out var(--d) both; }
@keyframes burst { from { transform: rotate(var(--a)) translateY(0) scale(.4); opacity: 1; } to { transform: rotate(var(--a)) translateY(-190px) scale(1); opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .pack-box.shake, .pack-rays, .pack-card.ready .pack-art { animation: none; }
  .pack-reveal { animation: none; }
  .pack-bit { display: none; }
}

/* ---------- Settings ---------- */
.kids-hidden { text-align: center; }

/* ---------- Desktop layout (Auto on wide screens, or chosen in Settings) ---------- */
.today-grid { display: block; }
html.desk .shell { max-width: 1240px; padding: 0 32px 48px 252px; }
html.desk .topbar { padding-top: 16px; }
html.desk .tabs { top: 0; bottom: 0; right: auto; width: 220px; border-top: 0; border-right: 1px solid var(--line); padding: 84px 12px 16px; justify-content: flex-start; }
html.desk .tabs-inner { flex-direction: column; gap: 4px; max-width: none; }
html.desk .tab { flex: none; flex-direction: row; justify-content: flex-start; gap: 12px; padding: 11px 14px; border-radius: 12px; font-size: 16px; }
html.desk .tab[aria-current="page"] { background: color-mix(in srgb, var(--kid) 12%, var(--card)); }
html.desk .tab .dot::after { left: auto; right: -10px; top: -4px; }
html.desk .topbar > .wordmark { visibility: hidden; }
.tabs-brand { display: none; }
html.desk .tabs-brand { display: block; position: absolute; top: 22px; left: 26px; }
html.desk .tabs { flex-direction: column; }
html.desk .toast { bottom: 24px; left: calc(50% + 110px); }
html.desk .today-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 28px; align-items: start; }
html.desk .today-col > .section:first-child, html.desk .today-col > :first-child { margin-top: 0; }
html.desk .store-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); }
html.desk .sheet { max-width: 640px; }
html.desk .scrim { align-items: center; padding: 24px; }
html.desk .sheet { border-radius: 22px; padding-bottom: 20px; }

/* Locked store items: compact name chips with a hidden picture */
.store-left-head { margin: 14px 0 8px; }
.store-left { display: flex; flex-wrap: wrap; gap: 6px; }
.store-locked { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 4px; border-radius: 999px; border: 1.5px dashed var(--line); background: transparent; color: var(--ink-2); font: inherit; font-size: 14px; cursor: pointer; }
.store-locked .store-mystery { width: 24px; height: 24px; font-size: 14px; }
.pack-card { flex-wrap: wrap; }
.pack-card > .grow { min-width: 160px; }
@media (max-width: 520px) { .pack-card > .btn { flex: 1 1 100%; } }

/* Your day: Coming up, date first */
.coming-up { border-top: 1px solid var(--line); padding: 4px 16px 12px; }
.coming-list { list-style: none; margin: 0; padding: 0; }
.coming-list li { display: grid; grid-template-columns: 104px 22px 1fr; align-items: center; gap: 10px; padding: 6px 0; font-size: 15px; }
.coming-date { font-weight: 700; color: var(--ink-2); font-size: 14px; white-space: nowrap; }
.coming-title { min-width: 0; }
.coming-up .area-head { padding-left: 0; padding-right: 0; }
.coming-list li { align-items: start; }
.coming-list .coming-date, .coming-list .ti { margin-top: 1px; }

/* ---------- Style picker (Family / Professional) ---------- */
.ui-style-pick { display: grid; gap: 8px; }
.ui-style { display: flex; gap: 12px; align-items: center; padding: 10px 12px; border: 1.5px solid var(--line); border-radius: 12px; cursor: pointer; }
.ui-style input { width: 18px; height: 18px; margin: 0; accent-color: var(--kid); }
.ui-style:has(input:checked) { border-color: var(--kid); background: color-mix(in srgb, var(--kid) 6%, var(--card)); }
.ui-style-art { width: 40px; height: 40px; border-radius: 10px; flex: none; display: grid; place-items: center; overflow: hidden; }
.ui-style-art svg { width: 100%; height: 100%; display: block; }
.ui-style-art.pro { background: #1F4FD1; }
.ui-style-art.pro svg { width: 22px; height: 22px; }

/* ---------- Professional style (parents) ---------- */
html.pro {
  --bg: #F4F5F7; --card: #FFFFFF; --ink: #111827; --ink-2: #4B5563; --line: #E3E6EB;
  --kid: #1F4FD1; --fern: #15803D; --fern-soft: #E7F5EC; --brick: #B42318; --brick-soft: #FDECEA;
  --gold: #B7791F; --gold-ink: #7A4D0B; --gold-soft: #FDF3E1;
  --shadow: none; --r-card: 10px; --r-ctl: 8px;
  --display: -apple-system, 'Segoe UI', 'Helvetica Neue', Arial, system-ui, sans-serif;
  --body: -apple-system, 'Segoe UI', 'Helvetica Neue', Arial, system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  html.pro:not([data-theme="light"]) {
    --bg: #0F141B; --card: #161C25; --ink: #E6EAF0; --ink-2: #A3ADBB; --line: #262E3A;
    --kid: #7EA2FF; --fern: #4ADE80; --fern-soft: #14301F; --brick: #F2877C; --brick-soft: #3A1F1D;
    --gold: #F2B935; --gold-ink: #F6D27A; --gold-soft: #33291A;
  }
}
html.pro[data-theme="dark"] {
  --bg: #0F141B; --card: #161C25; --ink: #E6EAF0; --ink-2: #A3ADBB; --line: #262E3A;
  --kid: #7EA2FF; --fern: #4ADE80; --fern-soft: #14301F; --brick: #F2877C; --brick-soft: #3A1F1D;
  --gold: #F2B935; --gold-ink: #F6D27A; --gold-soft: #33291A;
}
html.pro body { font-size: 15px; }
html.pro .card { border: 1px solid var(--line); }
html.pro h1 { font-weight: 650; font-size: 24px; letter-spacing: -0.01em; }
html.pro h2 { font-weight: 600; font-size: 17px; }
html.pro .wordmark { font-size: 21px; letter-spacing: -0.02em; }
html.pro .btn { border-radius: 8px; }
html.pro .chip { border-radius: 4px; }
html.pro .ti.work { color: var(--ink-2); display: inline-grid; place-items: center; flex: none; }
html.pro .ti.work svg { width: 100%; height: 100%; display: block; }
html.pro .pro-initials, .pro-initials { display: grid; place-items: center; width: 100%; height: 100%; border-radius: 50%; background: color-mix(in srgb, var(--ink) 12%, var(--card)); color: var(--ink); font: 600 13px/1 var(--body); letter-spacing: .02em; }
html.pro .av-inline.pro-initials { display: inline-grid; width: 1.6em; height: 1.6em; font-size: .7em; vertical-align: middle; }
html.pro .avatar:has(.pro-initials) { box-shadow: none; }
html.pro .punch { border-radius: 6px; }
html.pro .coming-date { font-variant-numeric: tabular-nums; }
.pro-family .list > li { border-top: 1px solid var(--line); }
.pro-kid { display: flex; align-items: center; gap: 12px; width: 100%; border: 0; background: none; padding: 12px 16px; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.pro-kid:hover { background: color-mix(in srgb, var(--kid) 5%, var(--card)); }
.pro-count { font-variant-numeric: tabular-nums; color: var(--ink-2); font-size: 14px; }
.pro-over { color: var(--brick); font-size: 13px; font-weight: 600; }
/* Professional: a compact checkbox instead of the big punch circle */
html.pro .punch { width: 30px; height: 30px; min-width: 30px; border-width: 2px; border-style: solid; border-radius: 6px; align-self: flex-start; margin-top: 2px; }
html.pro .punch svg { width: 18px; height: 18px; }

/* ---------- Professional: Today as a task table ---------- */
.pro-head { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin: 6px 0 18px; }
.pro-head h1 { margin: 0; }
.pro-head .muted { font-size: 14px; }
.pro-bar { display: block; height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.pro-bar i { display: block; height: 100%; border-radius: 3px; background: var(--kid); }
.pro-head > .pro-bar { flex: 1; max-width: 260px; min-width: 100px; }
.pro-new { margin-left: auto; }
.pro-table { overflow: hidden; padding: 0; }
.pro-thead, .pro-row { display: grid; grid-template-columns: 30px minmax(0, 1fr) 96px 92px 54px; gap: 12px; align-items: start; padding: 11px 16px; }
.pro-thead { font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); background: color-mix(in srgb, var(--bg) 50%, var(--card)); border-bottom: 1px solid var(--line); padding-top: 9px; padding-bottom: 9px; }
.pro-thead span:last-child, .pro-stepcount { text-align: right; }
.pro-row { border-top: 1px solid var(--line); }
.pro-table .list > li.pro-row:first-child { border-top: 0; }
.pro-check { width: 20px; height: 20px; margin-top: 1px; border: 1.5px solid color-mix(in srgb, var(--ink) 35%, var(--card)); border-radius: 4px; background: var(--card); padding: 0; display: grid; place-items: center; color: #fff; cursor: pointer; }
.pro-check svg { width: 13px; height: 13px; }
.pro-check[aria-pressed="true"] { background: var(--kid); border-color: var(--kid); }
.pro-check[data-state="pending"] { background: var(--gold-soft); border-color: var(--gold); color: var(--gold-ink); }
.pro-task { min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.pro-title { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-weight: 500; }
.pro-name { min-width: 0; }
.pro-row[data-done="true"] .pro-name { text-decoration: line-through; color: var(--ink-2); font-weight: 400; }
.pro-row[data-done="true"] .ti.work { opacity: .55; }
.pro-flag { font-size: 12px; font-weight: 600; color: var(--gold-ink); }
.pro-flag.bad { color: var(--brick); }
.pro-flag.money { color: var(--fern); }
.pro-steps-list { display: flex; flex-wrap: wrap; gap: 6px; }
.pro-step { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 4px; border: 1px solid var(--line); background: var(--card); color: var(--ink); font: inherit; font-size: 12.5px; cursor: pointer; }
.pro-step svg { width: 11px; height: 11px; }
.pro-step[aria-pressed="true"] { background: color-mix(in srgb, var(--kid) 10%, var(--card)); border-color: transparent; color: var(--kid); }
.pro-area { font-size: 13px; color: var(--ink-2); display: flex; align-items: center; gap: 7px; padding-top: 2px; }
.pro-area i, .pro-nav-row i { width: 8px; height: 8px; border-radius: 2px; flex: none; }
.pro-due, .pro-stepcount, .pro-num { font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace; font-size: 12.5px; color: var(--ink-2); padding-top: 2px; white-space: nowrap; }
.pro-due.late { color: var(--brick); }
.pro-side h2 { font-size: 14px; margin-bottom: 8px; }
.pro-side + .pro-side, .pro-grid .today-col > * + * { margin-top: 16px; }
.pro-side .coming-list li { grid-template-columns: 96px 18px 1fr; font-size: 14px; padding: 4px 0; }
.pro-goal { display: flex; flex-direction: column; gap: 6px; }
.pro-goal + .pro-goal { margin-top: 12px; }
.pro-goal .btn { padding: 2px 10px; min-height: 0; }
html.desk .pro-family-phone { display: none; }

/* Side menu extras on a computer */
.pro-nav { display: none; }
html.desk .pro-nav { display: flex; flex-direction: column; gap: 2px; margin-top: 18px; flex: 1; }
.pro-nav-head { font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); padding: 12px 14px 6px; }
.pro-nav-row { display: flex; align-items: center; gap: 10px; padding: 7px 14px; font-size: 15px; color: var(--ink); }
.pro-nav-btn { border: 0; background: none; font: inherit; text-align: left; cursor: pointer; border-radius: 8px; width: 100%; }
.pro-nav-btn:hover, .pro-nav-kid:hover { background: color-mix(in srgb, var(--kid) 6%, var(--card)); }
.pro-okbadge { font-size: 11px; font-weight: 700; color: #fff; background: var(--brick); border-radius: 9px; padding: 1px 8px; }
.pro-nav-kid { display: flex; align-items: center; border: 0; background: none; font: inherit; font-size: 14px; color: var(--ink-2); padding: 5px 14px 5px 32px; cursor: pointer; border-radius: 8px; width: 100%; text-align: left; }
.pro-nav-me { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 12px 14px 4px; border-top: 1px solid var(--line); }
.pro-nav-me .pro-initials { width: 30px; height: 30px; background: var(--ink); color: var(--card); font-size: 12px; }
.pro-nav-me small { display: block; color: var(--ink-2); font-size: 12px; }
.pro-tag { font-size: 11px; font-weight: 600; color: var(--ink-2); border: 1px solid var(--line); border-radius: 4px; padding: 0 5px; margin-left: 10px; vertical-align: 4px; }
html.desk.pro .tabs-brand { display: flex; align-items: center; }
html.desk.pro .tabs { overflow-y: auto; }
html.desk.pro .tab { font-size: 15px; padding: 9px 14px; }

/* Professional on a phone: no Area column, smaller table */
@media (max-width: 700px) {
  html:not(.desk) .pro-thead { display: none; }
  html:not(.desk) .pro-row { grid-template-columns: 26px minmax(0, 1fr) auto; }
  html:not(.desk) .pro-area, html:not(.desk) .pro-stepcount { display: none; }
}
html:not(.desk) .pro-head > .pro-bar { order: 3; flex-basis: 100%; max-width: none; }
.pro-title { flex-wrap: nowrap; }
.pro-title .pro-name { flex: 0 1 auto; }
.pro-title .pro-flag { white-space: nowrap; }
.pro-nav-me .pro-initials { flex: none; width: 30px; height: 30px; }
html.pro .section .avatar { width: 36px; height: 36px; }
html.pro .pro-grid .section { margin-top: 0; }
html.pro .pro-nav-me .pro-initials { width: 30px; height: 30px; flex: none; }
.pro-grid .today-col { display: flex; flex-direction: column; gap: 16px; }
.pro-grid .today-col > * + * { margin-top: 0; }
html.desk .pro-grid { grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); }
.pro-thead, .pro-row { grid-template-columns: 30px minmax(0, 1fr) 88px 84px 44px; }
/* Task form wording: grown-up words for your own tasks, kid words when a kid is ticked */
form[data-aud="adult"] .w-kid, form[data-aud="kid"] .w-adult { display: none; }

/* Reminder time, place and note */
.chore-when { font-size: 14px; color: var(--ink); margin-top: 2px; }
.chore-when .at-time { font-weight: 700; }
.place-link { color: var(--kid); text-decoration: underline; text-underline-offset: 2px; }
.task-note { font-size: 14px; color: var(--ink-2); white-space: pre-line; margin-top: 4px; }
.coming-time { color: var(--ink-2); font-size: 13px; margin-left: 4px; font-variant-numeric: tabular-nums; }
textarea { resize: vertical; min-height: 64px; }

/* ---------- Tracked numbers ---------- */
.measure-edit { list-style: none; margin: 0 0 8px; padding: 0; display: grid; gap: 6px; }
.measure-edit:empty { display: none; }
.measure-edit li { display: flex; align-items: center; gap: 8px; }
.measure-edit input { flex: 1; min-width: 0; }
.measure-edit .m-unit { flex: 0 0 84px; }
.measures { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.measure { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--card); color: var(--ink); font: inherit; font-size: 14px; cursor: pointer; }
span.measure { cursor: default; }
.measure b { font-variant-numeric: tabular-nums; }
.measure.has { border-color: color-mix(in srgb, var(--kid) 35%, var(--line)); background: color-mix(in srgb, var(--kid) 7%, var(--card)); }
.measure.chart-btn { color: var(--kid); border-style: dashed; }
html.pro .measure { border-radius: 6px; font-size: 13px; }
.trend-tabs { display: flex; gap: 6px; margin-bottom: 14px; }
.trend-tabs button { border: 1.5px solid var(--line); background: var(--card); border-radius: 999px; padding: 6px 12px; font: inherit; font-size: 14px; cursor: pointer; color: var(--ink); }
.trend-tabs button[aria-pressed="true"] { background: var(--ink); color: var(--card); border-color: var(--ink); }
.trend-block + .trend-block { margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
.trend-block h3 { margin-bottom: 8px; }
.trend-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-bottom: 10px; }
.trend-stats small { display: block; color: var(--ink-2); font-size: 12px; }
.trend-stats strong { font-size: 17px; font-variant-numeric: tabular-nums; }
.trend-stats .up { color: var(--ink); }
@media (max-width: 420px) { .trend-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.trend-chart { width: 100%; height: auto; display: block; }
.tc-grid { stroke: var(--line); stroke-width: 1; }
.tc-lab { fill: var(--ink-2); font-size: 11px; font-family: var(--body); }
.tc-line { fill: none; stroke: var(--kid); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.tc-dot { fill: var(--kid); }
.tc-last { fill: var(--card); stroke: var(--kid); stroke-width: 2.5; }

/* ---------- Shared lists ---------- */
.list-glyph { width: 40px; height: 40px; border-radius: 10px; flex: none; display: grid; place-items: center; background: color-mix(in srgb, var(--kid) 10%, var(--card)); color: var(--kid); }
.list-glyph svg { width: 22px; height: 22px; }
.list-index > li { border-top: 1px solid var(--line); }
.list-index > li:first-child { border-top: 0; }
.list-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px 16px; border: 0; background: none; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.list-row strong { display: block; }
.list-row small { display: block; font-size: 13px; }
.list-count { color: var(--ink-2); font-size: 14px; white-space: nowrap; }
.list-head h1 { margin-top: 6px; }
.list-add { margin-top: 14px; display: flex; flex-direction: column; gap: 8px; }
.list-add .li-qty-in { flex: 0 0 72px; width: 72px; }
.list-add .li-note-in { font-size: 14px; }
.li-row { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; }
.li-check { width: 24px; height: 24px; flex: none; margin-top: 1px; border: 2px solid color-mix(in srgb, var(--ink) 30%, var(--card)); border-radius: 6px; background: var(--card); display: grid; place-items: center; color: #fff; cursor: pointer; padding: 0; }
.li-check svg { width: 15px; height: 15px; }
.li-check[aria-pressed="true"] { background: var(--kid); border-color: var(--kid); }
.li-text { font-weight: 600; }
.li-row[data-done="true"] .li-text { text-decoration: line-through; color: var(--ink-2); font-weight: 400; }
.li-qty { font-weight: 700; color: var(--kid); font-variant-numeric: tabular-nums; }
.li-note { font-size: 14px; color: var(--ink-2); }
.li-by { font-size: 12px; color: var(--ink-2); margin-top: 2px; }
.li-x { width: 36px; height: 36px; flex: none; }
.li-x svg { width: 16px; height: 16px; }
.list-history summary { cursor: pointer; font-weight: 700; }
.lh-day { margin-top: 12px; }
.lh-day ul { margin: 6px 0 0; padding-left: 20px; font-size: 14px; }
/* Six tabs fit on a phone */
.tabs-inner .tab { min-width: 0; font-size: 12px; }

/* ---- Parent redesign: task type seg, Family hub, kid pages, Household ---- */
.type-seg { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); }
.type-seg span { white-space: nowrap; }

.req-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.req-card { position: relative; cursor: pointer; }
.req-card input { position: absolute; opacity: 0; pointer-events: none; }
.req-card > span { display: grid; gap: 2px; height: 100%; padding: 10px 12px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--card); }
.req-card small { color: var(--ink-2); font-size: 13px; line-height: 1.3; }
.req-card input:checked + span { border-color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.req-card input:focus-visible + span { outline: 3px solid var(--ink); outline-offset: 2px; }

.fam-ok { display: flex; align-items: center; gap: 12px; width: 100%; margin: 0 0 14px; padding: 12px 16px; border: 0; border-radius: 16px;
  background: var(--alert-bg, #FFF4D6); color: var(--alert-ink, inherit); font: inherit; text-align: left; cursor: pointer; }
.fam-ok-n { display: grid; place-items: center; min-width: 32px; height: 32px; padding: 0 8px; border-radius: 16px; background: var(--ink); color: var(--card); font-weight: 800; }
.fam-kids { display: grid; gap: 10px; }
.fam-kid { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 16px; border: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.fam-kid-body { display: grid; gap: 6px; min-width: 0; }
.fam-kid-top { display: flex; align-items: baseline; gap: 8px; }
.fam-kid-top strong { flex: 1; font-size: 18px; }
.fam-owed { font-weight: 800; color: var(--ink-2); white-space: nowrap; }
.fam-owed.pos { color: var(--gold-ink); }
.fam-line { color: var(--ink-2); }
.fam-bad { color: var(--brick, #C2410C); font-weight: 700; }
.fam-wait { font-weight: 700; color: var(--ink); }
.fam-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.fam-row:first-of-type { border-top: 0; }
.kid-page-head { display: grid; gap: 10px; }
.kid-page-head > .btn { justify-self: start; padding-left: 0; }
.kid-page-head h1 { margin: 0; }
.kid-page-head p { margin: 2px 0 0; }
.kid-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; padding: 4px; border-radius: 12px; background: var(--card); }
.kid-tabs button { height: 38px; border: 0; border-radius: 9px; background: transparent; font: inherit; font-size: 15px; color: var(--ink-2); cursor: pointer; }
.kid-tabs button[aria-selected=true] { background: var(--ink); color: var(--card); font-weight: 700; }
.balance.big { font-size: 34px; line-height: 1.1; }
.hh-code { display: flex; align-items: flex-start; gap: 12px; padding-top: 14px; border-top: 1px solid var(--line); }
.hh-code .codebox { margin: 4px 0; }
.jobs-section { margin-top: 18px; }
.seg span span { padding: 0; color: inherit; }
.type-hint { margin: 0; }
.tf-more-hint { display: block; font-weight: 400; margin-top: 2px; }
.kid-tabs { margin-top: 4px; }

/* Today's view pills: All · Work · Home · Family */
.view-pills { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 0 14px; padding: 2px 0; }
.view-pills::-webkit-scrollbar { display: none; }
.view-pill { position: relative; display: inline-flex; align-items: center; gap: 7px; flex: none; height: 38px; padding: 0 14px;
  border: 1.5px solid var(--line); border-radius: 999px; background: var(--card); color: var(--ink); font: inherit; font-size: 15px; font-weight: 700; cursor: pointer; }
.view-pill i { width: 9px; height: 9px; border-radius: 3px; flex: none; }
.view-pill[aria-pressed=true] { background: var(--ink); border-color: var(--ink); color: var(--card); }
.view-n { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--bg); color: var(--ink-2); font-size: 12px; display: inline-grid; place-items: center; }
.view-pill[aria-pressed=true] .view-n { background: color-mix(in srgb, var(--card) 22%, transparent); color: var(--card); }
.view-bad { position: absolute; top: 3px; right: 5px; width: 8px; height: 8px; border-radius: 50%; background: var(--brick); }
html.pro .view-pills { margin-top: 4px; }
@media (max-width: 520px) {
  .view-pills { gap: 6px; }
  .view-pill { height: 34px; padding: 0 10px; gap: 5px; font-size: 14px; }
  .view-n { min-width: 18px; height: 18px; padding: 0 5px; font-size: 11px; }
}

/* Payday card: one number for the allowance day */
.payday { gap: 6px; }
.payday .payday-total { margin: 2px 0; }
.payday-lines { margin-top: 8px; }
.payday-lines li { align-items: flex-start; }
.payday-lines li small { display: block; color: var(--ink-2); font-size: 12px; margin-top: 2px; }
.payday-lines .plus { color: var(--ok-ink, #13795B); font-weight: 700; }
.payday-lines .minus { color: var(--brick); font-weight: 700; }
.payday-risk { margin: 8px 0 0; padding: 10px 12px; border-radius: 10px; background: var(--brick-soft); color: var(--brick); font-size: 15px; }
.totals summary { cursor: pointer; list-style: none; }
.totals[open] summary { margin-bottom: 10px; }
.payday-lines { max-width: none; margin-left: 0; }
.fam-jobs { color: var(--ink); text-decoration: none; font-size: inherit; } .fam-jobs:hover { text-decoration: underline; }

/* New task: sharing, turns, rotation, number goals */
.share-cards { grid-template-columns: 1fr 1fr; }
.measure-edit .m-goal { flex: 0 0 74px; }
.m-goal-of { display: block; font-size: 11px; font-weight: 400; color: var(--ink-2); }
.chip.turns { background: var(--alert-bg); color: var(--alert-ink); }
.rot-line { font-size: 14px; margin: 4px 0 2px; color: var(--ink-2); }
.rot-line strong { color: var(--ink); }
.rot-dots { display: flex; flex-wrap: wrap; gap: 4px; margin: 2px 0 4px; }
.rot-dots span { font-size: 11px; padding: 2px 7px; border-radius: 999px; background: var(--bg); color: var(--ink-2); }
.rot-dots span.next { background: var(--ink); color: var(--card); font-weight: 700; }
.rot-pick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
/* Household: invites and phone */
.hh-block { padding-top: 14px; border-top: 1px solid var(--line); }
.invite-list { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 6px; }
.invite-list li { display: flex; align-items: center; gap: 8px; }
.invite-card h2 { margin: 0; }

/* Plan: Tasks | Jobs */
.plan-seg { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; margin-top: 10px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); }
.plan-seg button { height: 38px; border: 0; border-radius: 9px; background: transparent; font: inherit; font-size: 15px; color: var(--ink-2); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.plan-seg button[aria-selected=true] { background: var(--ink); color: var(--card); font-weight: 700; }

/* ---- Task form v3: what, who, when, then extras ---- */
.tf3 { gap: 20px; }
.tf-title input { font-size: 19px; min-height: 52px; }
.tf3 .who-pick > label > span { min-height: 44px; padding-right: 14px; }
.when-chips, .addons { display: flex; flex-wrap: wrap; gap: 8px; }
.when-chips label, .addon { position: relative; }
.when-chips input, .addon input { position: absolute; opacity: 0; pointer-events: none; }
.when-chips span, .addon span {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 16px; border-radius: 999px;
  border: 1.5px solid var(--line); background: var(--card); font-weight: 700; font-size: 15px; cursor: pointer; }
.addon span svg { width: 18px; height: 18px; }
.addon span::before { content: '+'; font-weight: 800; margin-right: 2px; }
.when-chips input:checked + span { background: var(--ink); color: var(--card); border-color: var(--ink); }
.addon input:checked + span { background: var(--kid, var(--ink)); color: #fff; border-color: var(--kid, var(--ink)); }
.addon input:checked + span::before { content: '✓'; }
.when-chips input:disabled + span { opacity: .35; cursor: not-allowed; }
.when-chips input:focus-visible + span, .addon input:focus-visible + span { outline: 3px solid var(--kid, var(--ink)); outline-offset: 2px; }
.tf-panel { display: grid; gap: 10px; padding: 14px; border-radius: 14px; background: var(--bg); border: 1px solid var(--line); }
.tf-panel .tf-q { font-size: 17px; }
.time-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.time-row { display: flex; gap: 8px; align-items: center; }
.time-row input { flex: 1; min-height: 50px; font-size: 20px; font-weight: 700; padding: 0 12px; border-radius: var(--r-ctl); border: 1.5px solid var(--line); background: var(--card); color: var(--ink); }
.time-row .icon-btn svg { width: 18px; height: 18px; }
.tf-foot { position: sticky; bottom: calc(-20px - env(safe-area-inset-bottom)); margin: 0 -16px; padding: 12px 16px calc(14px + env(safe-area-inset-bottom));
  background: var(--card); border-top: 1px solid var(--line); display: grid; gap: 8px; z-index: 2; }
.tf-summary { margin: 0; font-weight: 700; font-size: 15px; color: var(--ink-2); line-height: 1.35; }
.btn.big { min-height: 54px; font-size: 18px; }
.rot-edit summary { cursor: pointer; }
.rot-edit[open] { display: grid; gap: 8px; }

/* Text size (Settings, per device) */
html[data-text=large] body { zoom: 1.12; }
html[data-text=larger] body { zoom: 1.25; }

/* Pro Today on a phone: your work first, then habits, coming up, approvals, and the kids last */
html.pro:not(.desk) .pro-grid { display: flex; flex-direction: column; gap: 16px; }
html.pro:not(.desk) .pro-grid .today-col { display: contents; }
html.pro:not(.desk) .pro-grid .pro-table { order: 1; }
html.pro:not(.desk) .pro-grid .pro-habits { order: 2; }
html.pro:not(.desk) .pro-grid .pro-coming { order: 3; }
html.pro:not(.desk) .pro-grid .pro-fam { order: 4; }
html.pro:not(.desk) .pro-grid .pro-kids { order: 5; }
html.pro:not(.desk) .pro-grid .today-col > * + * { margin-top: 0; }
.pro-fam:empty { display: none; }
.pro-rot { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; font-size: 14px; color: var(--ink-2); }
.pro-rot strong { color: var(--ink); }
.pro-goal .rot-dots { margin-top: 0; }

/* Shout */
.shout-picks { display: flex; flex-wrap: wrap; gap: 8px; }
.shout-pick { min-height: 44px; padding: 8px 14px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card); color: var(--ink); font: inherit; font-weight: 700; font-size: 14px; text-align: left; cursor: pointer; }
.shout-pick[aria-pressed=true] { background: var(--ink); color: var(--card); border-color: var(--ink); }
.btn svg, .notif svg { width: 18px; height: 18px; vertical-align: -3px; }
.list-tools { gap: 10px; flex-wrap: wrap; justify-content: space-between; margin-top: 8px; }
.small-check { padding: 0; font-size: 14px; }
.notif.shout { border-left: 3px solid var(--accent, var(--ink)); }
.notif-open { all: unset; display: block; width: 100%; cursor: pointer; }

/* Every N days: "Every [7] days" and "Next due" side by side, same line, same height */
.iv-row { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 10px; align-items: start; margin-bottom: 6px; }
.iv-row .field { margin: 0; }
.iv-row input { height: 48px; min-height: 48px; box-sizing: border-box; width: 100%; }
.field > .suffix-input { display: flex; align-items: center; gap: 8px; margin: 0; font-size: inherit; }
.suffix-input input { width: 72px; flex: none; text-align: center; }
.suffix-input .suffix { font-weight: 700; color: var(--ink-2); }
.holiday-note:empty { display: none; }

/* ---- Plan > Table (computer) ---- */
.plan-seg.three { grid-template-columns: 1fr 1fr 1fr; }
.tbl-section { margin-top: 12px; }
.tbl-tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); margin-bottom: 12px; }
.tbl-tabs button { border: 0; background: transparent; font: inherit; font-weight: 700; padding: 6px 16px; border-radius: 9px; color: var(--ink-2); cursor: pointer; }
.tbl-tabs button[aria-selected=true] { background: var(--ink); color: var(--card); }
.tbl-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 10px; }
.tbl-bar input[type=search], .tbl-bar select { height: 36px; padding: 0 10px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--card); color: var(--ink); font: inherit; font-size: 14px; }
.tbl-bar input[type=search] { width: 200px; }
.tbl-wrap { overflow: auto; max-height: calc(100dvh - 220px); border: 1px solid var(--line); border-radius: 14px; background: var(--card); }
.tbl { border-collapse: separate; border-spacing: 0; width: 100%; font-size: 14px; }
.tbl th, .tbl td { padding: 6px 9px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; vertical-align: middle; }
.tbl thead th { position: sticky; top: 0; z-index: 2; background: var(--bg); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-2); }
.tbl thead th button { all: unset; cursor: pointer; font-weight: 800; }
.tbl th.num, .tbl td.num { text-align: right; }
.tbl .sticky { position: sticky; left: 0; z-index: 1; background: var(--card); box-shadow: 1px 0 0 var(--line); max-width: 260px; overflow: hidden; text-overflow: ellipsis; }
.tbl thead .sticky { z-index: 3; background: var(--bg); }
.tbl tbody tr:hover td { background: color-mix(in srgb, var(--kid, var(--ink)) 6%, var(--card)); }
.tbl tbody tr td.sticky { border-left: 3px solid var(--kid, transparent); }
.tbl-open { font-weight: 700; text-align: left; }
.tbl-in { font: inherit; font-size: 14px; color: var(--ink); background: transparent; border: 1px solid transparent; border-radius: 8px; padding: 4px 6px; min-width: 0; }
.tbl-in[type=number] { width: 84px; text-align: right; }
input.tbl-in:not([type]) , input.tbl-in[maxlength] { width: 120px; }
.tbl-in:hover { border-color: var(--line); background: var(--bg); }
.tbl-in:focus { outline: none; border-color: var(--kid, var(--ink)); background: var(--card); }
.tbl-in.saving { opacity: .5; }
.tbl-type { font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 999px; background: var(--bg); }
.tbl-type.t-paid, .tbl-type.j-approved { background: #DDF3E4; color: #1B6B3A; }
.tbl-type.t-goal { background: #E4E9FB; color: #2F4FB8; }
.tbl-type.t-reminder { background: #F1EEE6; color: #6B5D3F; }
.tbl-type.j-submitted, .tbl-type.j-claimed { background: #FFF1D6; color: #8A5A00; }
.wk { display: inline-flex; gap: 3px; vertical-align: middle; }
.wm { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 6px; font-style: normal; font-size: 11px; font-weight: 800; }
.wm.ok { background: #2E9E5B; color: #fff; }
.wm.late { background: #E8A33D; color: #fff; }
.wm.miss { background: #D9534F; color: #fff; }
.wm.open { border: 2px solid var(--kid, var(--ink)); color: var(--ink); }
.wm.none { color: var(--ink-2); opacity: .45; }
.tbl-key { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.chip.small { font-size: 11px; padding: 1px 7px; }
.chip.ok { background: #DDF3E4; color: #1B6B3A; }
.chip.bad { background: #FBE3E2; color: #A23B37; }
/* Table: keep controls compact even where global form styles apply */
.tbl-bar select, .tbl-bar input[type=search] { width: auto !important; min-height: 0 !important; height: 36px !important; flex: none; }
.tbl-bar input[type=search] { width: 220px !important; }
.tbl input.tbl-in, .tbl select.tbl-in { height: 30px !important; min-height: 0 !important; padding: 2px 6px !important; border: 1px solid transparent !important; background: transparent !important; box-shadow: none !important; font-size: 14px !important; }
.tbl input.tbl-in[type=number] { width: 84px !important; }
.tbl input.tbl-in[maxlength] { width: 120px !important; }
.tbl select.tbl-in { width: auto !important; }
.tbl input.tbl-in:hover, .tbl select.tbl-in:hover { border-color: var(--line) !important; background: var(--bg) !important; }
.tbl input.tbl-in:focus, .tbl select.tbl-in:focus { border-color: var(--kid, var(--ink)) !important; background: var(--card) !important; }
.tbl td { height: 38px; }
.tbl-open { text-decoration: none !important; }
.tbl-open:hover { text-decoration: underline !important; }

/* Table view uses the whole screen on a computer */
html.desk .shell.wide { max-width: none; padding-right: 24px; }
html.desk .shell.wide .tbl-wrap { max-height: calc(100dvh - 250px); }
html.desk .shell.wide .tbl { min-width: 100%; }
html.desk .shell.wide .tbl .sticky { max-width: 360px; }
html.desk .shell.wide .plan-seg { max-width: 640px; }
.tbl-check { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 700; color: var(--ink-2); cursor: pointer; }

/* Who pickers: picked people are filled in their color with a check; the rest are clearly off */
.who-pick > label > span { cursor: pointer; transition: background .12s, border-color .12s, opacity .12s; }
.who-pick input:not(:checked) + span { opacity: .62; background: transparent; border-style: dashed; }
.who-pick input:not(:checked) + span:hover { opacity: .9; }
.who-pick input:checked + span { opacity: 1; border-color: var(--kid, var(--ink)) !important; box-shadow: none !important;
  background: var(--kid, var(--ink)) !important; color: #fff; padding-right: 30px; position: relative; }
.who-pick input:checked + span::after { content: '✓'; position: absolute; right: 11px; top: 50%; transform: translateY(-50%); font-weight: 900; font-size: 14px; }

/* Printing a list: only the plain sheet goes to paper */
#print-root { display: none; }
@media print {
  @page { margin: 16mm; }
  body.printing > *:not(#print-root) { display: none !important; }
  body.printing #print-root { display: block !important; }
  body.printing { background: #fff !important; color: #000 !important; zoom: 1 !important; }
  .pl { font-family: Georgia, 'Times New Roman', serif; color: #000; }
  .pl header { border-bottom: 2px solid #000; padding-bottom: 6px; margin-bottom: 14px; }
  .pl h1 { font-size: 26pt; margin: 0; }
  .pl header p { margin: 4px 0 0; font-size: 10pt; color: #444; }
  .pl-items { list-style: none; margin: 0; padding: 0; font-size: 14pt; }
  ol.pl-items { list-style: decimal; padding-left: 1.4em; }
  .pl-items li { display: flex; align-items: flex-start; gap: 12px; padding: 7px 0; border-bottom: 1px solid #ccc; break-inside: avoid; }
  ol.pl-items li { display: list-item; }
  .pl-box { flex: none; width: 14pt; height: 14pt; border: 1.5pt solid #000; border-radius: 2pt; margin-top: 2pt; }
  .pl-text small { display: block; font-size: 10pt; color: #555; }
  .pl-blank li { border-bottom: 1px solid #ccc; }
  .pl-line { flex: 1; height: 14pt; }
}

/* Due soon: chores coming up in the next few days */
.chip.soon { background: #E6ECFF; color: #2F4FB8; }
.chip.soon.warn, .chip.warn { background: #FFE6C7; color: #8A4B00; }
.due-soon .list { border: 2px solid #FFD39A; }
.soon-row .chore-meta { align-items: center; }
.punch.locked { display: grid; place-items: center; background: var(--bg); border: 2px dashed var(--line); opacity: .8; }

/* ---- New task, step by step (same form, one question at a time) ---- */
.taskform:not([data-wiz]) .wiz-only { display: none !important; }
.taskform[data-wiz] .full-only { display: none !important; }
.taskform[data-wiz]:not([data-wiz="0"]) [data-step="0"],
.taskform[data-wiz]:not([data-wiz="1"]) [data-step="1"],
.taskform[data-wiz]:not([data-wiz="2"]) [data-step="2"],
.taskform[data-wiz]:not([data-wiz="3"]) [data-step="3"],
.taskform[data-wiz]:not([data-wiz="4"]) [data-step="4"],
.taskform[data-wiz]:not([data-wiz="5"]) [data-step="5"] { display: none !important; }
.taskform[data-wiz] { gap: 18px; min-height: 360px; }
.taskform[data-wiz] .tf-q { font-family: var(--display); font-size: 26px; letter-spacing: -.02em; line-height: 1.15; margin: 0; }
.taskform[data-wiz] .tf-title > span { font-family: var(--display); font-size: 26px; font-weight: 700; letter-spacing: -.02em; color: var(--ink); }
.taskform[data-wiz] .tf-title input { font-size: 20px; min-height: 54px; }
.taskform[data-wiz] .tf-block { border: 0; padding: 0; background: none; }
.taskform[data-wiz] .when-chips { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.taskform[data-wiz] .when-chips span { justify-content: center; text-align: center; padding: 16px 12px; font-size: 16px; border-radius: 14px; }
.taskform[data-wiz] .addons { display: grid; gap: 10px; }
.taskform[data-wiz] .addon span { display: grid; gap: 2px; padding: 14px 16px 14px 44px; border-radius: 14px; text-align: left; position: relative; font-weight: 400; }
.taskform[data-wiz] .addon span::before { position: absolute; left: 16px; top: 15px; width: 18px; height: 18px; border-radius: 6px; border: 2px solid currentColor; content: ''; }
.taskform[data-wiz] .addon input:checked + span::before { content: '✓'; border-color: transparent; font-weight: 900; line-height: 18px; text-align: center; }
.taskform[data-wiz] .addon b { font-size: 16px; }
.taskform[data-wiz] .addon small { font-size: 14px; opacity: .85; }
.taskform[data-wiz] .addon span svg { display: none; }
.taskform[data-wiz] .who-pick label > span { font-size: 17px; }
.taskform[data-wiz] .tf-summary { font-size: 19px; line-height: 1.5; padding: 18px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--card); }
.taskform[data-wiz]:not([data-wiz="5"]) .tf-foot { display: none !important; }
.wiz-head { display: flex; align-items: center; gap: 12px; }
.wiz-dots { display: flex; gap: 6px; margin-right: auto; }
.wiz-dots i { width: 28px; height: 6px; border-radius: 3px; background: var(--line); }
.wiz-dots i.on { background: var(--kid, var(--ink)); }
.wiz-tpls { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-btn { border: 1.5px solid var(--line); background: var(--card); color: var(--ink); border-radius: 999px; padding: 9px 15px; font: inherit; font-weight: 700; font-size: 15px; cursor: pointer; }
.chip-btn:hover { border-color: var(--ink-2); }
.taskform[data-aud="kid"] .aud-adult, .taskform[data-aud="adult"] .aud-kid { display: none !important; }
.wiz-kinds { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.wiz-kinds .req-card > span { padding: 16px; border-radius: 14px; }
.wiz-kinds strong { font-size: 17px; }
.wiz-kinds small { font-size: 14px; }
.wiz-nav { display: flex; align-items: center; gap: 10px; position: sticky; bottom: 0; background: var(--card); padding: 12px 0 2px; border-top: 1px solid var(--line); margin-top: 8px; }

/* ---- Computer layout: Money, Needs you, Family, person pages, side panel ---- */
.tab-settings { display: none; }
html.desk .tab-settings { display: flex; margin-top: auto; flex: none; flex-direction: row; justify-content: flex-start; gap: 12px; padding: 11px 14px; border-radius: 12px; font-size: 16px; border: 0; background: none; color: var(--ink-2); font: inherit; cursor: pointer; }
html.desk .tab-settings svg { width: 22px; height: 22px; }
html.desk .tab-settings:hover { color: var(--ink); }
.needs-you { display: grid; gap: 10px; }
.needs-you > .section { margin-top: 0; }
.needs-none { margin-top: 0; }
.pay-link .fam-ok-n { background: var(--fern); }
.money-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.money-stats > .card { display: grid; gap: 4px; text-align: left; border: 0; font: inherit; color: inherit; }
.money-stats strong { font-family: var(--display); font-size: 26px; letter-spacing: -.02em; }
.money-jobs { cursor: pointer; }
.money-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; align-items: start; }
.money-grid > .section { margin-top: 0; }
.money-two { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.person-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.person-grid > div > .section:first-child { margin-top: 0; }
.fam-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.fam-cards .fam-kid { margin: 0; }
.hm-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.hm { display: grid; place-items: center; aspect-ratio: 1; border-radius: 8px; background: var(--bg); font-size: 12px; color: var(--ink-2); }
.hm b { font-weight: 700; }
.hm-all { background: var(--fern); color: #fff; }
.hm-some { background: color-mix(in srgb, var(--fern) 45%, var(--card)); color: var(--ink); }
.hm-miss { background: var(--brick-soft); color: var(--brick); }
.hm-open { background: var(--gold-soft); color: var(--gold-ink); }
.hm-key { display: inline-flex; align-items: center; gap: 4px; }
.hm-key .hm { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }
html.desk .scrim.side { justify-content: flex-end; align-items: stretch; padding: 0; }
html.desk .scrim.side .sheet { max-width: 600px; max-height: none; height: 100dvh; border-radius: 0; animation: slidein .2s ease-out; }
@keyframes slidein { from { transform: translateX(40px); opacity: 0; } to { transform: none; opacity: 1; } }

/* ---- Strikes: the week as day bubbles ---- */
ol.wk { list-style: none; margin: 10px 0 0; padding: 0; display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; max-width: 420px; }
.wk-day { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.wk-lbl { font-size: 11px; font-weight: 700; letter-spacing: .04em; color: var(--ink-2); }
.wk-dot { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: 17px; line-height: 1; background: var(--bg); color: var(--ink-2); border: 2px solid transparent; }
.wk-good .wk-dot { background: var(--fern); color: #fff; }
.wk-strike .wk-dot { background: var(--brick); color: #fff; font-size: 19px; }
.wk-open .wk-dot { background: var(--card); border-color: var(--gold); border-style: dashed; }
.wk-future .wk-dot { background: transparent; border-color: var(--line); }
.wk-today .wk-lbl { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
ol.wk.wk-sm { gap: 3px; margin: 6px 0 0; max-width: 230px; }
.wk-sm .wk-lbl { font-size: 9px; }
.wk-sm .wk-dot { width: 22px; height: 22px; font-size: 11px; border-width: 1.5px; }
.wk-sm .wk-strike .wk-dot { font-size: 12px; }
.wk-line { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.wk-line .wk { flex: none; width: 210px; }
.wk-card.wk-out { border: 2px solid var(--brick); }
.wk-out-txt { color: var(--brick); font-weight: 700; }
.payday .wk { margin: 12px 0 4px; }
.payday-lines li > span:last-child { white-space: nowrap; padding-left: 10px; }
.payday-lines li small b { color: var(--ink); font-weight: 700; }
