/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ── Design Tokens ── */
:root {
  --indigo:        #4f46e5;
  --indigo-dark:   #4338ca;
  --indigo-light:  #eef2ff;
  --indigo-subtle: rgba(79,70,229,.08);
  --gold:          #d97706;
  --gold-bg:       rgba(217,119,6,.08);
  --gold-border:   rgba(217,119,6,.2);
  --red:           #dc2626;
  --red-bg:        rgba(220,38,38,.06);
  --red-border:    rgba(220,38,38,.22);
  --green:         #059669;
  --green-bg:      rgba(5,150,105,.08);
  --purple:        #7c3aed;
  --text-1:        #0f172a;
  --text-2:        #475569;
  --text-3:        #94a3b8;
  --border:        #e2e8f0;
  --bg:            #f8fafc;
  --surface:       #ffffff;
  --surface-2:     #f1f5f9;
  --shadow-xs:     0 1px 2px rgba(0,0,0,.05);
  --shadow-sm:     0 1px 3px rgba(0,0,0,.07), 0 1px 2px rgba(0,0,0,.04);
  --shadow-md:     0 4px 12px rgba(0,0,0,.09), 0 2px 4px rgba(0,0,0,.04);
  --shadow-lg:     0 8px 24px rgba(0,0,0,.12), 0 4px 8px rgba(0,0,0,.06);
  --r-xs: 4px; --r-sm: 6px; --r-md: 10px; --r-lg: 16px; --r-xl: 20px; --r-pill: 999px;
  --sidebar-w: 0px; --top-h: 60px; --tab-h: 68px; --max-w: 428px;
}

[data-theme="dark"] {
  --text-1:        #f1f5f9;
  --text-2:        #94a3b8;
  --text-3:        #475569;
  --border:        #1e293b;
  --bg:            #0a0f1e;
  --surface:       #111827;
  --surface-2:     #1e293b;
  --indigo-light:  rgba(79,70,229,.18);
  --indigo-subtle: rgba(79,70,229,.12);
  --red-bg:        rgba(220,38,38,.1);
  --green-bg:      rgba(5,150,105,.12);
  --shadow-sm:     0 1px 3px rgba(0,0,0,.3), 0 1px 2px rgba(0,0,0,.2);
  --shadow-md:     0 4px 12px rgba(0,0,0,.4), 0 2px 4px rgba(0,0,0,.2);
  --shadow-lg:     0 8px 24px rgba(0,0,0,.5), 0 4px 8px rgba(0,0,0,.3);
}

/* ── Base ── */
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg); color: var(--text-1);
  min-height: 100vh; overflow-x: hidden;
  font-size: 14px; line-height: 1.5;
  transition: background .25s, color .25s;
  -webkit-font-smoothing: antialiased;
}

/* ── App Shell ── */
#app { max-width: var(--max-w); margin: 0 auto; min-height: 100vh; position: relative; }

/* ── Utilities ── */
.hidden { display: none !important; }
[hidden]  { display: none !important; }
.mt-1 { margin-top: 8px; } .mt-2 { margin-top: 12px; } .mt-3 { margin-top: 16px; } .mt-4 { margin-top: 24px; }

/* ── Cards ── */
.card { background: var(--surface); border-radius: var(--r-md); box-shadow: var(--shadow-sm); overflow: hidden; }

/* ── Top Bar ── */
.top-bar {
  position: fixed; top: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: var(--max-w); height: var(--top-h);
  background: var(--surface); border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 16px; z-index: 100; box-shadow: var(--shadow-xs);
}
.wordmark { display: flex; align-items: center; gap: 9px; }
.logo-mark {
  width: 28px; height: 28px; background: var(--indigo);
  border-radius: 7px; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.logo-mark svg { width: 14px; height: 14px; color: #fff; }
.logo-label { font-size: 17px; font-weight: 700; letter-spacing: -.4px; color: var(--text-1); }
.top-bar-page-title { font-size: 16px; font-weight: 600; color: var(--text-1); display: none; }
.top-bar-right { display: flex; align-items: center; gap: 8px; }
.btn-icon {
  position: relative; background: none; border: none; cursor: pointer;
  width: 38px; height: 38px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-2); transition: background .15s;
}
.btn-icon:hover { background: var(--surface-2); }
.btn-icon svg { width: 20px; height: 20px; }
.notif-badge {
  position: absolute; top: 3px; right: 3px;
  background: var(--red); color: #fff; font-size: 9px; font-weight: 700;
  min-width: 15px; height: 15px; padding: 0 3px; border-radius: var(--r-pill);
  display: flex; align-items: center; justify-content: center; border: 2px solid var(--surface);
}

/* ── Avatars ── */
.avatar {
  border-radius: 50%; font-weight: 700; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.avatar-sm { width: 28px; height: 28px; font-size: 10px; }
.avatar-md { width: 40px; height: 40px; font-size: 14px; }
.avatar-lg { width: 64px; height: 64px; font-size: 22px; }

/* ── Sidebar (always dark, desktop only) ── */
.sidebar {
  display: none; position: fixed; top: 0; left: 0; bottom: 0;
  width: 240px; z-index: 110; background: #0f172a;
  flex-direction: column; overflow: hidden;
}
.sidebar-logo {
  height: var(--top-h); padding: 0 20px;
  display: flex; align-items: center; gap: 10px;
  border-bottom: 1px solid rgba(255,255,255,.06); flex-shrink: 0;
}
.sidebar-logo .logo-label { color: #f8fafc; font-size: 16px; }
.sidebar-nav {
  flex: 1; padding: 10px; display: flex; flex-direction: column; gap: 1px; overflow-y: auto;
}
.sidebar-section-label {
  padding: 6px 12px 4px; font-size: 10px; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; color: #475569;
}
.sidebar-item {
  display: flex; align-items: center; gap: 11px; padding: 9px 12px;
  border-radius: var(--r-sm); border: none; background: none;
  color: #94a3b8; font-size: 13.5px; font-weight: 500;
  cursor: pointer; transition: all .12s; text-align: left; width: 100%;
  text-decoration: none;
}
.sidebar-item svg { width: 17px; height: 17px; flex-shrink: 0; }
.sidebar-item:hover { background: rgba(255,255,255,.07); color: #e2e8f0; }
.sidebar-item.active { background: rgba(79,70,229,.22); color: #a5b4fc; }
.sidebar-divider { height: 1px; background: rgba(255,255,255,.06); margin: 8px 0; }
.sidebar-footer {
  padding: 12px; border-top: 1px solid rgba(255,255,255,.06);
  display: flex; flex-direction: column; gap: 8px; flex-shrink: 0;
}
.sidebar-user { display: flex; align-items: center; gap: 10px; padding: 4px; }
.sidebar-user-info { min-width: 0; }
.sidebar-user-name { font-size: 13px; font-weight: 600; color: #e2e8f0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user-sub  { font-size: 11px; color: #64748b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-dark-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 6px 4px; font-size: 12.5px; color: #64748b; cursor: pointer;
  border-radius: var(--r-sm); transition: background .12s;
}
.sidebar-dark-row:hover { background: rgba(255,255,255,.05); }

/* ── Bottom Tab Bar (mobile) ── */
.tab-bar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: var(--max-w); height: var(--tab-h);
  background: var(--surface); border-top: 1px solid var(--border);
  display: flex; z-index: 100; box-shadow: 0 -1px 8px rgba(0,0,0,.06);
}
.tab-item {
  flex: 1; border: none; background: none; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px; padding-bottom: env(safe-area-inset-bottom, 0);
  color: var(--text-3); font-size: 10px; font-weight: 500;
  transition: color .12s; position: relative; text-decoration: none;
}
.tab-item svg { width: 22px; height: 22px; }
.tab-item.active { color: var(--indigo); }
.tab-item.active::before {
  content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 28px; height: 2px; background: var(--indigo); border-radius: 0 0 2px 2px;
}

/* ── Page Content ── */
.page-content { padding: calc(var(--top-h) + 16px) 16px calc(var(--tab-h) + 16px); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ── Section Headings ── */
.section-gap { margin-top: 20px; }
.section-header {
  display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px;
}
.section-title {
  font-size: 11px; font-weight: 700; color: var(--text-3);
  letter-spacing: .07em; text-transform: uppercase;
}
.link-action {
  background: none; border: none; cursor: pointer;
  color: var(--indigo); font-size: 12.5px; font-weight: 500;
}
.link-action:hover { text-decoration: underline; }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  border: none; border-radius: var(--r-sm); cursor: pointer;
  font-size: 13.5px; font-weight: 600; padding: 9px 16px;
  transition: all .15s; white-space: nowrap; line-height: 1;
}
.btn-sm { padding: 7px 12px; font-size: 12.5px; }
.btn-full { width: 100%; }
.btn-primary {
  background: var(--indigo); color: #fff;
  box-shadow: 0 1px 3px rgba(79,70,229,.3);
}
.btn-primary:hover {
  background: var(--indigo-dark);
  transform: translateY(-1px); box-shadow: 0 4px 10px rgba(79,70,229,.35);
}
.btn-primary:active { transform: translateY(0); }
.btn-danger {
  background: var(--red); color: #fff; box-shadow: 0 1px 3px rgba(220,38,38,.3);
}
.btn-danger:hover { background: #b91c1c; transform: translateY(-1px); box-shadow: 0 4px 10px rgba(220,38,38,.35); }
.btn-success {
  background: var(--green); color: #fff; box-shadow: 0 1px 3px rgba(5,150,105,.3);
}
.btn-success:hover { background: #047857; transform: translateY(-1px); }
.btn-outline {
  background: transparent; color: var(--text-2); border: 1px solid var(--border);
}
.btn-outline:hover { background: var(--surface-2); border-color: var(--text-3); }

/* ── Badges / Tags ── */
.badge {
  display: inline-flex; align-items: center;
  padding: 2px 7px; border-radius: var(--r-pill);
  font-size: 11px; font-weight: 600;
}
.diff-easy   { background: rgba(5,150,105,.1);  color: #059669; }
.diff-medium { background: rgba(217,119,6,.1);  color: #d97706; }
.diff-hard   { background: rgba(220,38,38,.1);  color: #dc2626; }
.cat-everyone { background: var(--indigo-light); color: var(--indigo); }
.cat-adult    { background: rgba(124,58,237,.1); color: var(--purple); }
.cat-child    { background: rgba(5,150,105,.1);  color: var(--green); }
.badge-count  { background: var(--red); color: #fff; font-size: 11px; padding: 1px 5px; border-radius: var(--r-pill); margin-left: 5px; }
.badge-grey   { background: var(--surface-2); color: var(--text-3); margin-left: 5px; font-size: 11px; padding: 1px 6px; border-radius: var(--r-pill); }
.badge-indigo { background: var(--indigo-light); color: var(--indigo); font-size: 10.5px; padding: 2px 6px; border-radius: var(--r-pill); }

/* ── Toggle ── */
.toggle {
  position: relative; width: 36px; height: 20px;
  background: var(--text-3); border: none; border-radius: var(--r-pill);
  cursor: pointer; transition: background .2s; flex-shrink: 0;
}
.toggle::after {
  content: ''; position: absolute; top: 2px; left: 2px;
  width: 16px; height: 16px; background: #fff; border-radius: 50%;
  transition: transform .2s; box-shadow: 0 1px 3px rgba(0,0,0,.2);
}
.toggle.on { background: var(--indigo); }
.toggle.on::after { transform: translateX(16px); }

/* ── Greeting & Stats ── */
.greeting-row { margin-bottom: 16px; }
.greeting-text { font-size: 22px; font-weight: 700; color: var(--text-1); letter-spacing: -.4px; }
.greeting-sub  { font-size: 13px; color: var(--text-3); margin-top: 2px; }
.stat-cards    { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stat-card {
  background: var(--surface); border-radius: var(--r-md);
  box-shadow: var(--shadow-sm); padding: 14px 10px; text-align: center;
}
.stat-value {
  font-size: 28px; font-weight: 700; letter-spacing: -.5px; line-height: 1.1;
  font-variant-numeric: tabular-nums; color: var(--text-1); margin-bottom: 4px;
}
.stat-value.indigo { color: var(--indigo); }
.stat-value.gold   { color: var(--gold); }
.stat-label { font-size: 10.5px; font-weight: 600; color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.stat-delta { font-size: 11px; color: var(--green); margin-top: 3px; font-weight: 600; }

/* ── Race Bar ── */
.race-card { padding: 16px; }
.race-label { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--text-3); margin-bottom: 12px; }
.race-bar-wrap { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.race-pts { font-size: 13px; font-weight: 700; min-width: 34px; font-variant-numeric: tabular-nums; }
.race-track { flex: 1; height: 7px; background: var(--surface-2); border-radius: var(--r-pill); overflow: hidden; display: flex; }
.race-message { font-size: 12.5px; color: var(--text-2); text-align: center; }

/* ── Chore Cards ── */
.chore-list { display: flex; flex-direction: column; gap: 8px; }
.chore-card {
  background: var(--surface); border-radius: var(--r-md);
  box-shadow: var(--shadow-sm); padding: 14px;
  transition: transform .15s, box-shadow .15s;
}
.chore-card:not(.completed):not(.not-eligible):hover {
  transform: translateY(-2px); box-shadow: var(--shadow-md);
}
.chore-card.overdue { border-left: 3px solid var(--red); }
.chore-card.completed { opacity: .72; }
.chore-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.chore-card-name { font-size: 14px; font-weight: 600; color: var(--text-1); }
.chore-card-name.completed-text { text-decoration: line-through; color: var(--text-3); }
.chore-pts { font-size: 12.5px; font-weight: 700; color: var(--gold); white-space: nowrap; font-variant-numeric: tabular-nums; }
.chore-card-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 8px; }
.chore-card-status {
  display: flex; align-items: center; gap: 7px;
  font-size: 12.5px; color: var(--text-2); margin-bottom: 10px;
  padding: 7px 10px; background: var(--surface-2); border-radius: var(--r-sm);
}
.chore-card-status.status-red   { background: var(--red-bg);   color: var(--red); }
.chore-card-status.status-green { background: var(--green-bg); color: var(--green); }
.chore-card-status.status-amber { background: var(--gold-bg);  color: var(--gold); flex-direction: column; align-items: flex-start; gap: 2px; }
.chore-card-status.status-grey  { background: var(--surface-2); color: var(--text-3); font-size: 12px; }
.claim-timer { font-size: 11px; font-weight: 600; opacity: .85; }
.claim-timer-assigned { color: var(--indigo); opacity: 1; }
.pending-dash-card .claim-timer,
.pending-dash-card .claim-timer-assigned { display: block; margin-bottom: 8px; color: var(--gold); opacity: 1; }
.chore-card-actions { display: flex; gap: 8px; margin-top: 4px; }
.claim-release-btn { flex-shrink: 0; }

/* Pending claims (account page) */
.pending-claim-card {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px; background: var(--surface); border-radius: var(--r-md);
  box-shadow: var(--shadow-sm); margin-bottom: 8px;
}
.pending-claim-actions { display: flex; gap: 6px; flex-shrink: 0; }
.regular-claim-wrap { display: flex; align-items: center; gap: 6px; flex-shrink: 0; flex-wrap: wrap; justify-content: flex-end; }
.regular-claimed-by { font-size: 11.5px; color: var(--text-3); flex-shrink: 0; }
.streak-callout {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 9px; border-radius: var(--r-pill);
  background: var(--gold-bg); border: 1px solid var(--gold-border);
  font-size: 11.5px; font-weight: 600; color: var(--gold); margin-bottom: 8px;
}
.check-circle {
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--green); color: #fff; font-size: 10px;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.status-icon { flex-shrink: 0; }

/* ── Dashboard layout helpers ── */
.dash-main  { min-width: 0; }
.dash-aside { min-width: 0; }
.section-divider {
  font-size: 10.5px; font-weight: 700; color: var(--text-3);
  letter-spacing: .06em; text-transform: uppercase;
  margin: 12px 0 6px; padding-top: 4px; border-top: 1px solid var(--border);
}
.btn-full { width: 100%; }
.dash-loading {
  padding: 20px; text-align: center; font-size: 13px; color: var(--text-3);
}

/* ── Coming Up ── */
.coming-day-label {
  font-size: 10.5px; font-weight: 700; color: var(--text-3);
  letter-spacing: .06em; text-transform: uppercase; margin: 12px 0 6px;
}
.coming-day-label:first-child { margin-top: 0; }
.coming-card {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 12px; background: var(--surface);
  border-radius: var(--r-sm); box-shadow: var(--shadow-xs);
}
.coming-card + .coming-card { margin-top: 5px; }
.coming-card-name { flex: 1; font-size: 13px; font-weight: 500; color: var(--text-1); }
.coming-pts { font-size: 12px; font-weight: 700; color: var(--gold); font-variant-numeric: tabular-nums; }

/* ── Mini Leaderboard ── */
.mini-lb-list { overflow: hidden; }
.mini-lb-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; transition: background .1s;
}
.mini-lb-row + .mini-lb-row { border-top: 1px solid var(--border); }
.mini-lb-row:hover { background: var(--surface-2); }
.mini-lb-row.current-user { background: var(--indigo-light); }
[data-theme="dark"] .mini-lb-row.current-user { background: var(--indigo-subtle); }
.mini-lb-rank { width: 18px; text-align: center; font-size: 12px; font-weight: 700; color: var(--text-3); font-variant-numeric: tabular-nums; }
.mini-lb-name { flex: 1; font-size: 13px; font-weight: 500; color: var(--text-1); }
.mini-lb-pts  { font-size: 12.5px; font-weight: 700; color: var(--text-2); font-variant-numeric: tabular-nums; }

/* ── Notifications Dropdown ── */
.notif-dropdown {
  position: fixed; top: calc(var(--top-h) + 6px);
  right: max(8px, calc(50vw - var(--max-w)/2 + 8px));
  width: 300px; z-index: 200; background: var(--surface);
  border-radius: var(--r-md); box-shadow: var(--shadow-lg);
  border: 1px solid var(--border); overflow: hidden;
}
.notif-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px; border-bottom: 1px solid var(--border);
  font-size: 13px; font-weight: 600; color: var(--text-1);
}
.notif-item {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 11px 14px; cursor: pointer; transition: background .1s;
}
.notif-item + .notif-item { border-top: 1px solid var(--border); }
.notif-item:hover { background: var(--surface-2); }
.notif-item.unread { background: var(--indigo-subtle); }
.notif-item.unread:hover { background: var(--indigo-light); }
.notif-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--indigo); flex-shrink: 0; margin-top: 5px; }
.notif-dot.read { background: var(--text-3); }
.notif-text { font-size: 12.5px; color: var(--text-1); line-height: 1.45; }
.notif-time { font-size: 11px; color: var(--text-3); margin-top: 2px; }
.notif-empty { padding: 24px 16px; text-align: center; font-size: 13px; color: var(--text-3); }

/* ── FAB ── */
.fab {
  position: fixed; bottom: calc(var(--tab-h) + 16px);
  right: max(16px, calc(50vw - var(--max-w)/2 + 16px));
  width: 48px; height: 48px; background: var(--indigo); color: #fff;
  border: none; border-radius: 50%; font-size: 22px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; z-index: 90; box-shadow: 0 4px 14px rgba(79,70,229,.45);
  transition: all .15s;
}
.fab:hover { transform: translateY(-2px) scale(1.05); box-shadow: 0 6px 18px rgba(79,70,229,.5); }

/* ── Room Sections ── */
.room-section { margin-bottom: 20px; }
.room-header {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; cursor: pointer;
  border-radius: var(--r-md); transition: background .12s;
  user-select: none;
}
.room-header:hover { background: var(--surface-2); }
.room-icon   { font-size: 20px; flex-shrink: 0; }
.room-name   { flex: 1; font-size: 14px; font-weight: 700; color: var(--text-1); }
.room-meta   { font-size: 11.5px; color: var(--text-3); }
.room-chevron {
  color: var(--text-3); transition: transform .2s; flex-shrink: 0;
  width: 18px; height: 18px;
}
.room-chevron.open { transform: rotate(90deg); }
.room-body   { display: flex; flex-direction: column; gap: 6px; padding: 0 4px 4px; }
.room-body.collapsed { display: none; }
.room-empty  { padding: 10px 2px; font-size: 13px; color: var(--text-3); }
.room-disabled .room-name { color: var(--text-3); }
.room-disabled .room-body { opacity: .45; pointer-events: none; }
.room-toggle-wrap { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

/* ── Filter Bar ── */
.filter-bar { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.filter-btn {
  padding: 5px 12px; border-radius: var(--r-pill);
  border: 1.5px solid var(--border); background: var(--surface);
  color: var(--text-2); font-size: 12.5px; font-weight: 500;
  cursor: pointer; transition: all .12s;
}
.filter-btn:hover { border-color: var(--indigo); color: var(--indigo); }
.filter-btn.active { background: var(--indigo); border-color: var(--indigo); color: #fff; }

/* ── Chore Def Cards ── */
.chore-def-card { padding: 14px; }
.chore-def-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; margin-bottom: 4px; }
.chore-def-name { font-size: 13.5px; font-weight: 600; color: var(--text-1); }
.chore-def-edit { background: none; border: none; cursor: pointer; color: var(--text-3); font-size: 14px; padding: 0; transition: color .1s; }
.chore-def-edit:hover { color: var(--text-2); }
.chore-def-delete { font-size: 13px; }
.chore-def-delete:hover { color: var(--red) !important; }
.chore-def-freq { font-size: 12px; color: var(--text-3); margin-bottom: 8px; }
.name-editable { cursor: pointer; border-radius: 4px; padding: 0 2px; margin: 0 -2px; transition: background .15s; }
.name-editable:hover { background: var(--surface-2); text-decoration: underline; text-decoration-style: dashed; text-underline-offset: 2px; }
.chore-def-desc {
  font-size: 12px; color: var(--text-2); line-height: 1.55;
  background: var(--surface-2); border-radius: var(--r-sm);
  padding: 7px 10px; margin-bottom: 8px; border-left: 2px solid var(--border);
}
.overrides-editable {
  cursor: pointer; border-radius: var(--r-sm);
  padding: 3px 6px; margin: -3px -6px;
  transition: background .15s;
}
.overrides-editable:hover { background: var(--surface-2); }
.overrides-edit-icon { font-size: 9px; opacity: .35; margin-left: 2px; }

.freq-editable {
  display: inline-flex; align-items: center; gap: 5px; cursor: pointer;
  padding: 3px 9px 3px 8px; border-radius: var(--r-pill);
  background: var(--surface-2); border: 1px solid var(--border);
  color: var(--text-2); transition: background .15s, border-color .15s, color .15s;
}
.freq-editable:hover { background: var(--indigo-subtle); border-color: var(--indigo); color: var(--indigo); }
.freq-edit-icon { font-size: 9px; opacity: .45; transition: opacity .15s; }
.freq-editable:hover .freq-edit-icon { opacity: 1; }
.sched-label { font-size: 11px; font-weight: 700; color: var(--text-3); letter-spacing: .06em; text-transform: uppercase; margin-bottom: 6px; }
.sched-hint  { font-size: 12px; color: var(--text-2); margin: 0 0 8px; line-height: 1.5; }
.freq-opt-grid { display: flex; flex-wrap: wrap; gap: 7px; margin: 4px 0 8px; }
.freq-opt {
  padding: 6px 12px; border-radius: var(--r-pill); font-size: 13px; font-weight: 500;
  border: 1.5px solid var(--border); background: var(--surface); color: var(--text-1);
  cursor: pointer; transition: border-color .15s, background .15s;
}
.freq-opt:hover { border-color: var(--indigo); color: var(--indigo); background: var(--indigo-subtle); }
.freq-opt-active { border-color: var(--indigo); background: var(--indigo); color: #fff; font-weight: 600; }
.freq-opt-active:hover { background: var(--indigo); color: #fff; }
.pts-label { font-size: 11.5px; font-weight: 700; color: var(--gold); font-variant-numeric: tabular-nums; }

.chore-def-tags { display: flex; flex-wrap: wrap; gap: 5px; align-items: center; margin-top: 4px; }

/* ── Regular Activities ── */
.regular-card {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 14px; background: var(--surface);
  border-radius: var(--r-md); border: 1px solid var(--border);
  margin-bottom: 6px;
}
.regular-icon { font-size: 20px; flex-shrink: 0; }
.regular-body { flex: 1; min-width: 0; }
.regular-name { font-size: 13.5px; font-weight: 600; color: var(--text-1); }
.regular-desc { font-size: 11.5px; color: var(--text-2); line-height: 1.5; margin-top: 2px; }
.regular-meta { font-size: 12px; color: var(--text-3); margin-top: 3px; }
.regular-claim-btn { flex-shrink: 0; font-size: 12px; white-space: nowrap; }

/* ── Today activity feed (dashboard) ── */
.today-empty {
  display: flex; align-items: center; gap: 10px; padding: 20px 16px;
  font-size: 13px; color: var(--text-3);
  background: var(--surface); border-radius: var(--r-md); border: 1.5px dashed var(--border);
}
.today-item {
  display: flex; align-items: center; gap: 10px; padding: 11px 14px;
  background: var(--surface); border-radius: var(--r-md);
  border: 1px solid var(--border); margin-bottom: 6px;
}
.today-check { color: var(--green); font-size: 14px; font-weight: 700; flex-shrink: 0; }
.today-name  { flex: 1; font-size: 13.5px; font-weight: 500; color: var(--text-1); }
.today-pts   { font-size: 12px; font-weight: 700; color: var(--gold); flex-shrink: 0; }

/* ── Leaderboard ── */
.sub-tabs {
  display: flex; background: var(--surface-2); border-radius: var(--r-md);
  padding: 3px; gap: 3px; margin-bottom: 16px;
}
.sub-tab {
  flex: 1; padding: 7px; border: none; background: none;
  border-radius: calc(var(--r-md) - 3px); font-size: 13px; font-weight: 600;
  color: var(--text-3); cursor: pointer; transition: all .15s;
}
.sub-tab.active { background: var(--surface); color: var(--text-1); box-shadow: var(--shadow-xs); }

.podium-wrap { display: flex; align-items: flex-end; justify-content: center; gap: 8px; margin-bottom: 20px; }
.podium-person { display: flex; flex-direction: column; align-items: center; gap: 5px; flex: 1; max-width: 120px; }
.podium-crown  { font-size: 18px; }
.podium-name   { font-size: 12.5px; font-weight: 600; color: var(--text-2); }
.podium-platform {
  width: 100%; border-radius: var(--r-sm) var(--r-sm) 0 0;
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end; padding-bottom: 10px;
}
.podium-1 { background: linear-gradient(180deg, rgba(79,70,229,.14), rgba(79,70,229,.07)); min-height: 90px; }
.podium-2 { background: linear-gradient(180deg, rgba(124,58,237,.1), rgba(124,58,237,.05)); min-height: 65px; }
.podium-3 { background: linear-gradient(180deg, rgba(217,119,6,.1), rgba(217,119,6,.05)); min-height: 45px; }
.podium-rank { font-size: 22px; font-weight: 700; color: var(--text-1); line-height: 1; font-variant-numeric: tabular-nums; }
.podium-pts-display { font-size: 11px; color: var(--text-3); font-weight: 600; }

.lb-full-list { background: var(--surface); border-radius: var(--r-md); box-shadow: var(--shadow-sm); overflow: hidden; }
.lb-row { display: flex; align-items: center; gap: 10px; padding: 12px 14px; transition: background .1s; }
.lb-row + .lb-row { border-top: 1px solid var(--border); }
.lb-row:hover { background: var(--surface-2); }
.lb-row.current-user { background: var(--indigo-light); }
[data-theme="dark"] .lb-row.current-user { background: var(--indigo-subtle); }
.lb-rank-num { width: 20px; text-align: center; font-size: 13px; font-weight: 700; color: var(--text-3); font-variant-numeric: tabular-nums; }
.lb-info { flex: 1; min-width: 0; }
.lb-name { font-size: 13.5px; font-weight: 600; color: var(--text-1); }
.lb-sub  { font-size: 11.5px; color: var(--text-3); }
.lb-pts-big { font-size: 18px; font-weight: 700; color: var(--text-1); font-variant-numeric: tabular-nums; }

/* Head-to-head */
.h2h-card { padding: 16px; }
.h2h-title { font-size: 12.5px; font-weight: 600; color: var(--text-2); margin-bottom: 12px; }
.h2h-bar-wrap { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.h2h-person { font-size: 12.5px; font-weight: 700; min-width: 46px; }
.h2h-person.right { text-align: right; }
.h2h-track { flex: 1; height: 7px; background: var(--surface-2); border-radius: var(--r-pill); overflow: hidden; display: flex; }

/* Household stats */
.hh-stats-card { padding: 16px; }
.hh-stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.hh-stat-item  { padding: 12px; background: var(--surface-2); border-radius: var(--r-sm); }
.hh-stat-val   { font-size: 22px; font-weight: 700; color: var(--text-1); font-variant-numeric: tabular-nums; }
.hh-stat-lbl   { font-size: 10.5px; color: var(--text-3); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; margin-top: 2px; }
.hh-stat-note  { font-size: 11.5px; color: var(--text-2); margin-top: 3px; }

/* ── Rewards ── */
.pts-balance-hero {
  background: linear-gradient(135deg, var(--indigo), var(--indigo-dark));
  border-radius: var(--r-lg); padding: 24px 20px; text-align: center; margin-bottom: 16px;
  box-shadow: 0 4px 16px rgba(79,70,229,.35);
}
.pts-balance-num {
  font-size: 48px; font-weight: 700; color: #fff;
  line-height: 1; letter-spacing: -1px; font-variant-numeric: tabular-nums;
}
.pts-balance-sub { font-size: 13px; color: rgba(255,255,255,.7); margin-top: 4px; font-weight: 500; }
.rewards-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.reward-card {
  background: var(--surface); border-radius: var(--r-md); box-shadow: var(--shadow-sm);
  padding: 16px; display: flex; flex-direction: column; align-items: flex-start; gap: 5px;
  transition: transform .15s, box-shadow .15s;
}
.reward-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.reward-icon { font-size: 26px; line-height: 1; }
.reward-name { font-size: 13px; font-weight: 600; color: var(--text-1); }
.reward-pts  { font-size: 15px; font-weight: 700; color: var(--gold); font-variant-numeric: tabular-nums; }
.reward-tag  { font-size: 11px; color: var(--text-3); }
.reward-card .btn { align-self: stretch; margin-top: 6px; }
.locked-reward { grid-column: 1 / -1; }
.reward-prog-wrap { width: 100%; margin-top: 6px; }
.reward-prog-bar  { height: 6px; background: var(--surface-2); border-radius: var(--r-pill); overflow: hidden; margin-bottom: 5px; }
.reward-prog-fill { height: 100%; background: var(--indigo); border-radius: var(--r-pill); transition: width .5s; }
.reward-prog-label { font-size: 11.5px; color: var(--text-2); font-weight: 600; font-variant-numeric: tabular-nums; }
.reward-need { font-size: 12px; color: var(--text-3); }

/* ── Profile / More ── */
.profile-hero {
  display: flex; align-items: center; gap: 14px;
  padding: 18px; background: var(--surface);
  border-radius: var(--r-md); box-shadow: var(--shadow-sm); margin-bottom: 16px;
}
.profile-info { min-width: 0; }
.profile-name { font-size: 18px; font-weight: 700; color: var(--text-1); letter-spacing: -.3px; }
.profile-role { font-size: 13px; color: var(--indigo); font-weight: 600; margin-top: 2px; }
.profile-hh   { font-size: 12px; color: var(--text-3); margin-top: 1px; }
.profile-stats { display: flex; gap: 16px; margin-top: 10px; }
.profile-stat-val { font-size: 17px; font-weight: 700; color: var(--text-1); font-variant-numeric: tabular-nums; }
.profile-stat-lbl { font-size: 10px; color: var(--text-3); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }

.badges-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.badge-card {
  background: var(--surface); border-radius: var(--r-md); box-shadow: var(--shadow-sm);
  padding: 14px 8px; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 4px;
}
.badge-icon { font-size: 24px; line-height: 1; }
.badge-name { font-size: 11px; font-weight: 600; color: var(--text-1); }
.badge-prog { font-size: 10.5px; color: var(--text-3); font-weight: 500; }
.locked-badge { opacity: .42; }

.settings-list { background: var(--surface); border-radius: var(--r-md); box-shadow: var(--shadow-sm); overflow: hidden; margin-bottom: 16px; }
.settings-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 13px 14px; cursor: pointer; transition: background .1s;
}
.settings-row + .settings-row { border-top: 1px solid var(--border); }
.settings-row:hover { background: var(--surface-2); }
.settings-row-left {
  display: flex; align-items: center; gap: 10px;
  font-size: 13.5px; color: var(--text-1); font-weight: 500;
}
.settings-row-left svg { color: var(--text-3); flex-shrink: 0; }
.settings-chevron { color: var(--text-3); font-size: 18px; }
.logout-btn {
  width: 100%; padding: 11px; background: none;
  border: 1.5px solid var(--border); border-radius: var(--r-md);
  color: var(--red); font-size: 13.5px; font-weight: 600; cursor: pointer; transition: all .15s;
}
.logout-btn:hover { background: var(--red-bg); border-color: var(--red); }

/* ── Household cards ── */
.house-info-card {
  display: flex; align-items: center; gap: 12px;
  background: var(--surface); border: 1.5px solid var(--border);
  border-radius: var(--r-md); padding: 14px 16px; margin-bottom: 4px;
}
.house-info-icon { font-size: 28px; line-height: 1; flex-shrink: 0; }
.house-info-body { flex: 1; min-width: 0; }
.house-info-name { font-size: 15px; font-weight: 700; color: var(--text-1); }
.house-info-role { font-size: 12px; color: var(--text-3); margin-top: 2px; }

.house-setup-card {
  display: flex; align-items: center; gap: 12px;
  background: var(--indigo-subtle); border: 1.5px solid var(--indigo-light);
  border-radius: var(--r-md); padding: 14px 16px; margin-bottom: 16px;
}
.house-setup-cta { cursor: pointer; transition: background .15s; }
.house-setup-cta:hover { background: var(--indigo-light); }
.house-setup-icon { font-size: 26px; line-height: 1; flex-shrink: 0; }
.house-setup-body { flex: 1; min-width: 0; }
.house-setup-title { font-size: 14px; font-weight: 700; color: var(--text-1); }
.house-setup-sub   { font-size: 12px; color: var(--text-2); margin-top: 2px; line-height: 1.4; }

.btn-sm { padding: 6px 12px; font-size: 12px; }
.btn-outline {
  border: 1.5px solid var(--border); background: none; border-radius: var(--r-sm);
  color: var(--text-2); font-size: 13px; font-weight: 600; cursor: pointer;
  padding: 8px 14px; transition: all .12s;
}
.btn-outline:hover { border-color: var(--indigo); color: var(--indigo); }

/* ── Modal ── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 300; background: rgba(0,0,0,.45);
  display: flex; align-items: flex-end; justify-content: center; animation: fadeIn .15s;
}
.modal {
  background: var(--surface); border-radius: var(--r-xl) var(--r-xl) 0 0;
  width: 100%; max-width: var(--max-w); padding: 24px 20px 36px;
  animation: slideUp .2s ease-out; box-shadow: 0 -4px 24px rgba(0,0,0,.18);
}
.modal-emoji  { font-size: 40px; text-align: center; margin-bottom: 10px; }
.modal-header { font-size: 20px; font-weight: 700; color: var(--text-1); text-align: center; margin-bottom: 6px; }
.modal-sub    { font-size: 14px; color: var(--text-2); text-align: center; margin-bottom: 16px; }
.modal-actions { display: flex; gap: 10px; margin-top: 20px; }

/* ── Toast ── */
.toast-wrap {
  position: fixed; bottom: calc(var(--tab-h) + 12px);
  left: 50%; transform: translateX(-50%); z-index: 400;
  display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none;
}
.toast {
  background: #0f172a; color: #fff; padding: 10px 20px;
  border-radius: var(--r-pill); font-size: 13.5px; font-weight: 600;
  box-shadow: var(--shadow-lg); white-space: nowrap;
  animation: toastIn .2s ease-out, toastOut .3s ease-in 2.6s forwards;
}
[data-theme="dark"] .toast { background: #334155; }

/* ── Confetti ── */
.confetti-container { position: fixed; inset: 0; pointer-events: none; z-index: 500; overflow: hidden; }
@keyframes confettiDrop {
  0%   { transform: translateY(-40px) rotate(0deg); opacity: 1; }
  100% { transform: translateY(110vh) rotate(720deg); opacity: 0; }
}
.confetti-particle { position: absolute; animation: confettiDrop linear both; }

/* ── Animations ── */
@keyframes fadeIn  { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { transform: translateY(30px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
@keyframes toastIn { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes toastOut { from { opacity: 1; } to { opacity: 0; transform: translateY(-6px); } }

/* ── Accessibility ── */
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
:focus-visible { outline: 2.5px solid var(--indigo); outline-offset: 2px; border-radius: 4px; }

/* ============================================================
   AUTH PAGES
   ============================================================ */
.auth-wrap {
  min-height: 100vh; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: 24px 16px; background: var(--bg);
}
.auth-card {
  width: 100%; max-width: 400px; background: var(--surface);
  border-radius: var(--r-lg); padding: 32px 28px;
  box-shadow: var(--shadow-md); border: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 14px;
}
.auth-brand { display: flex; justify-content: center; margin-bottom: 4px; color: var(--indigo); }
.auth-card h1 { font-size: 22px; font-weight: 800; text-align: center; color: var(--text-1); }
.auth-sub { font-size: 14px; color: var(--text-2); text-align: center; margin-top: -6px; }
.auth-card label {
  display: flex; flex-direction: column; gap: 5px;
  font-size: 13px; font-weight: 600; color: var(--text-2);
}
.auth-card input, .auth-card textarea {
  padding: 10px 12px; border: 1.5px solid var(--border);
  border-radius: var(--r-sm); font-size: 14px;
  background: var(--surface); color: var(--text-1);
  transition: border-color .2s; outline: none; font-family: inherit;
}
.auth-card input:focus, .auth-card textarea:focus { border-color: var(--indigo); }
.auth-card .btn-primary {
  width: 100%; padding: 12px; font-size: 15px;
  border-radius: var(--r-sm); font-weight: 700;
  min-height: 48px;
}
.auth-remember { flex-direction: row !important; align-items: center; gap: 8px !important; cursor: pointer; }
.auth-remember input { width: auto; }
.auth-error { font-size: 13px; color: var(--red); text-align: center; margin: -4px 0; }
.auth-note  { font-size: 13px; color: var(--indigo); text-align: center; }
.auth-alt   { font-size: 13px; text-align: center; color: var(--text-3); }
.auth-alt a { color: var(--indigo); text-decoration: none; font-weight: 600; }
.auth-alt a:hover { text-decoration: underline; }
.auth-alt .dot { margin: 0 6px; }
.hint { font-weight: 400; color: var(--text-3); font-size: 12px; }

/* ── Calendar ── */
.cal-toolbar {
  display: flex; align-items: center; gap: 10px; margin-bottom: 18px; flex-wrap: wrap;
}
.cal-view-toggle { display: flex; gap: 4px; }
.cal-view-btn {
  padding: 5px 14px; border-radius: var(--r-pill);
  border: 1.5px solid var(--border); background: none;
  color: var(--text-2); cursor: pointer; font-size: 13px; font-weight: 600; transition: all .15s;
}
.cal-view-btn.active { background: var(--indigo); border-color: var(--indigo); color: #fff; }
.cal-nav { display: flex; align-items: center; gap: 6px; }
.cal-nav-btn { width: 30px; height: 30px; }
.cal-period-label {
  font-size: 14px; font-weight: 600; color: var(--text-1);
  min-width: 160px; text-align: center;
}
.cal-board { overflow-x: auto; }

/* Week view */
.cal-week {
  display: grid; grid-template-columns: repeat(7, minmax(110px, 1fr));
  gap: 5px; min-width: 700px; margin-bottom: 12px;
}
.cal-col {
  display: flex; flex-direction: column; min-height: 180px;
  border-radius: var(--r-md); background: var(--surface); box-shadow: var(--shadow-sm); overflow: hidden;
}
.cal-col-today { box-shadow: 0 0 0 2px var(--indigo); }
.cal-col-head {
  display: flex; align-items: center; gap: 4px; padding: 7px 8px;
  background: var(--surface-2); border-bottom: 1px solid var(--border);
}
.cal-col-name { font-size: 11px; font-weight: 700; color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.cal-col-date { font-size: 13px; font-weight: 700; color: var(--text-1); margin-left: 3px; }
.cal-col-today .cal-col-date { color: var(--indigo); }
.cal-col-body {
  flex: 1; padding: 5px; display: flex; flex-direction: column; gap: 3px; transition: background .12s;
}
.cal-col-body.cal-drop-over { background: var(--indigo-subtle); }

/* Month view */
.cal-month {
  display: grid; grid-template-columns: repeat(7, 1fr);
  gap: 3px; min-width: 560px; margin-bottom: 12px;
}
.cal-month-hd {
  text-align: center; font-size: 11px; font-weight: 700;
  color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; padding: 5px 0;
}
.cal-month-cell {
  min-height: 72px; padding: 4px 5px; border-radius: var(--r-sm);
  background: var(--surface); border: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 2px; transition: background .12s;
}
.cal-month-cell.cal-drop-over { background: var(--indigo-subtle); border-color: var(--indigo); }
.cal-cell-today { border-color: var(--indigo); }
.cal-cell-pad { background: none !important; border-color: transparent !important; min-height: 0; }
.cal-cell-date {
  font-size: 11.5px; font-weight: 600; color: var(--text-3);
  display: flex; align-items: center; gap: 4px; margin-bottom: 1px;
}
.cal-cell-today .cal-cell-date { color: var(--indigo); font-weight: 700; }

/* Workload badge */
.cal-load {
  font-size: 10px; font-weight: 700; padding: 1px 5px;
  border-radius: 10px; margin-left: auto; line-height: 1.4;
}
.cal-load.load-ok   { background: var(--green-bg);  color: var(--green); }
.cal-load.load-warn { background: var(--gold-bg);   color: var(--gold); }
.cal-load.load-high { background: var(--red-bg);    color: var(--red); }

/* Chore chip */
.cal-chip {
  display: flex; align-items: center; gap: 5px; padding: 5px 7px;
  border-radius: var(--r-sm); background: var(--surface-2); border: 1px solid var(--border);
  cursor: grab; transition: border-color .12s, box-shadow .12s;
  font-size: 12px; user-select: none; min-width: 0;
}
.cal-chip:hover { border-color: var(--indigo); box-shadow: 0 1px 4px rgba(0,0,0,.1); }
.cal-chip:active { cursor: grabbing; }
.cal-chip-alt { opacity: .65; }
.cal-chip-unsched { border-style: dashed; }
.cal-chip-icon { font-size: 14px; flex-shrink: 0; line-height: 1; }
.cal-chip-body { display: flex; flex-direction: column; flex: 1; min-width: 0; gap: 1px; }
.cal-chip-name { font-weight: 600; color: var(--text-1); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.cal-chip-diff { font-size: 9px; padding: 1px 5px; align-self: flex-start; }
.cal-chip-pts { font-size: 11px; font-weight: 700; color: var(--gold); flex-shrink: 0; margin-left: auto; }

/* Month-view chips are compact */
.cal-month-cell .cal-chip { padding: 2px 4px; }
.cal-month-cell .cal-chip-name { font-size: 11px; }
.cal-month-cell .cal-chip-diff,
.cal-month-cell .cal-chip-pts  { display: none; }

/* Remove-pin drop zone */
.cal-unpin-zone {
  margin: 6px 0 10px; padding: 8px 14px; border-radius: var(--r-sm);
  border: 1.5px dashed var(--border); text-align: center;
  font-size: 12px; color: var(--text-3); transition: all .15s; cursor: default;
}
.cal-unpin-zone.cal-drop-over { border-color: var(--red); color: var(--red); background: var(--red-bg); }

/* Unscheduled panel */
.cal-unsched { margin-top: 4px; padding: 14px; background: var(--surface); border-radius: var(--r-md); box-shadow: var(--shadow-sm); }
.cal-unsched-label {
  font-size: 11px; font-weight: 700; color: var(--text-3);
  text-transform: uppercase; letter-spacing: .06em; margin-bottom: 10px;
}
.cal-unsched-chips { display: flex; flex-wrap: wrap; gap: 6px; }

/* ── Desktop ── */
@media (min-width: 900px) {
  :root { --sidebar-w: 240px; --tab-h: 0px; }

  #app { max-width: none; display: flex; min-height: 100vh; }

  .sidebar { display: flex; }
  .tab-bar { display: none; }

  .top-bar {
    left: var(--sidebar-w); transform: none;
    width: calc(100% - var(--sidebar-w)); max-width: none;
  }
  .wordmark { display: none; }
  .top-bar-page-title { display: block; }

  .page-content {
    margin-left: var(--sidebar-w); width: calc(100% - var(--sidebar-w));
    max-height: 100vh; overflow-y: auto;
    padding: calc(var(--top-h) + 28px) 40px 40px;
  }

  .notif-dropdown { right: 16px; }
  .toast-wrap { left: calc(var(--sidebar-w) / 2 + 50vw); transform: translateX(-50%); bottom: 24px; }

  .modal-overlay { align-items: center; }
  .modal { border-radius: var(--r-lg); max-width: 440px; animation: fadeIn .15s; }

  .fab { right: 28px; bottom: 28px; }

  /* Dashboard 2-col */
  .dash-grid { display: grid; grid-template-columns: 1fr 360px; gap: 24px; align-items: start; }
  .dash-aside { position: sticky; top: calc(var(--top-h) + 28px); }
  .greeting-text { font-size: 26px; }
  .stat-value { font-size: 32px; }
  .stat-cards { gap: 14px; margin-bottom: 8px; }

  /* Leaderboard 2-col */
  .lb-desktop-grid { display: grid; grid-template-columns: 1fr 340px; gap: 24px; align-items: start; }
  .podium-1 { min-height: 110px !important; }
  .podium-2 { min-height: 80px !important; }
  .podium-3 { min-height: 55px !important; }

  /* Chores grid */
  .room-body:not(.collapsed) { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 8px; padding: 0 4px 4px; }
  .room-empty { grid-column: 1 / -1; }

  /* Dashboard chore list grid */
  .chore-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
  .chore-list .section-divider,
  .today-empty { grid-column: 1 / -1; }

  /* Rewards 4-col */
  .rewards-grid { grid-template-columns: repeat(4, 1fr); }
  .locked-reward { flex-direction: row; align-items: center; gap: 20px; }
  .locked-reward .reward-prog-wrap { width: 260px; flex-shrink: 0; margin-top: 0; }
  .pts-balance-hero { padding: 28px 24px; }
  .pts-balance-num  { font-size: 56px; }

  /* More 2-col */
  .more-desktop-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: start; }
  .badges-grid { grid-template-columns: repeat(6, 1fr); }
  .badge-card  { padding: 16px 8px; }
}
