/* Donna: "warm cookbook" look.
   Cream ground, serif titles (Fraunces), Inter for everything else, deep green
   actions, terracotta for the Add button. Light and dark themes share tokens. */

:root {
  --bg: #FAF6EF;
  --surface: #FFFFFF;
  --text: #2A2622;
  --muted: #6B6259;
  --border: #E8DFD2;
  --line: #F1EAE0;
  --accent: #2F5D46;
  --accent-text: #FFFFFF;
  --clay: #C2603A;
  --warn: #7A5000;
  --warn-bg: #FBF0D9;
  --danger: #B3261E;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  --radius: 16px;
  --tabs-height: 64px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1C1915;
    --surface: #26221D;
    --text: #F1EBE2;
    --muted: #B3A898;
    --border: #3A342C;
    --line: #302B24;
    --accent: #8CC4A2;
    --accent-text: #10241A;
    --clay: #D9774F;
    --warn: #F2C46B;
    --warn-bg: #3A2D14;
    --danger: #F2B8B5;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.4;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}

a { color: var(--accent); }

.page {
  max-width: 560px;
  margin: 0 auto;
  padding: calc(20px + env(safe-area-inset-top)) 20px calc(40px + env(safe-area-inset-bottom));
}
body.with-tabs .page { padding-bottom: calc(var(--tabs-height) + 32px + env(safe-area-inset-bottom)); }

/* ---- Headings ---- */
.page-header { display: flex; flex-direction: column; gap: 4px; margin: 16px 0 20px; }
h1 { margin: 0; font-family: var(--serif); font-weight: 600; font-size: 34px; line-height: 1.1; letter-spacing: -0.01em; }
.eyebrow { font-size: 13px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); text-decoration: none; }
.sub { margin: 0; font-size: 14px; color: var(--muted); }
.header-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.header-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin: 16px 0 20px; }
.header-top .page-header { margin: 0; }
.round-btn { flex: none; width: 44px; height: 44px; border-radius: 22px; background: var(--surface); border: 1px solid var(--border); color: var(--accent); display: flex; align-items: center; justify-content: center; }
.section-title { margin: 24px 0 8px; font-size: 12px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.back { display: inline-flex; align-items: center; gap: 2px; min-height: 44px; margin-left: -6px; color: var(--accent); text-decoration: none; font-weight: 500; }

/* ---- Text helpers ---- */
.muted { color: var(--muted); }
.small { font-size: 14px; }
.hint { margin: 8px 0 0; font-size: 13px; color: var(--muted); text-align: center; }
.notice { margin: 0 0 12px; padding: 12px 14px; border-radius: 12px; font-size: 15px; background: var(--surface); border: 1px solid var(--border); }
.notice.success { color: var(--accent); }
.error { color: var(--danger); }

/* ---- Buttons ---- */
.btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; min-height: 52px; padding: 0 18px;
  border: 1px solid var(--border); border-radius: 14px;
  background: var(--surface); color: var(--text);
  font: 600 16px var(--sans); text-decoration: none; cursor: pointer;
}
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.btn.danger { background: none; border-color: transparent; color: var(--danger); font-weight: 500; }
.btn:disabled { opacity: 0.5; }
.pill {
  display: inline-flex; align-items: center; gap: 6px; flex: none;
  min-height: 44px; padding: 0 14px;
  border: 1px solid var(--border); border-radius: 22px;
  background: var(--surface); color: var(--accent);
  font: 600 14px var(--sans); text-decoration: none; cursor: pointer;
}
.pill:disabled { opacity: 0.5; }
.link-btn { background: none; border: 0; padding: 0; min-height: 44px; color: var(--accent); font: inherit; cursor: pointer; text-decoration: underline; }
.icon-btn {
  display: flex; align-items: center; justify-content: center; flex: none;
  width: 44px; height: 44px; border: 0; border-radius: 12px;
  background: none; color: var(--muted); cursor: pointer;
}
.stack { display: grid; gap: 10px; }

/* ---- Forms ---- */
label { display: block; margin-bottom: 14px; font-size: 14px; font-weight: 500; color: var(--muted); }
input:not([type=radio]):not([type=checkbox]):not([type=file]) {
  display: block; width: 100%; margin-top: 6px; padding: 12px 14px;
  font: 400 17px var(--sans); /* 16px+ stops iOS zooming in */
  color: var(--text); background: var(--surface);
  border: 1px solid var(--border); border-radius: 12px;
}
input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

/* ---- Groups & empty states ---- */
.group { list-style: none; margin: 0; padding: 0 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; }
.group > li { border-bottom: 1px solid var(--line); }
.group > li:last-child { border-bottom: 0; }
.empty { padding: 24px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); color: var(--muted); }
.empty-title { margin: 0 0 6px; font-family: var(--serif); font-size: 20px; font-weight: 600; color: var(--text); }
.empty p:last-child { margin-bottom: 0; }

/* ---- This Week: recipe cards ---- */
.recipe-list { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 12px; }
.recipe-card { display: flex; align-items: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }
.recipe-card > a { flex: 1; min-width: 0; display: flex; align-items: center; gap: 14px; padding: 12px; color: inherit; text-decoration: none; }
.thumb {
  flex: none; width: 64px; height: 64px; border-radius: 12px; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--serif); font-size: 22px; font-weight: 600; color: #FFFFFF;
}
.thumb img { width: 100%; height: 100%; object-fit: cover; }
.recipe-body { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.recipe-title { font-family: var(--serif); font-weight: 600; font-size: 18px; line-height: 1.2; }
.recipe-meta { font-size: 13px; color: var(--muted); }
.recipe-card form { margin-right: 4px; }

/* ---- Add chooser ---- */
.choice { display: flex; align-items: center; gap: 16px; padding: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); color: inherit; text-decoration: none; }
.choice-icon { flex: none; width: 52px; height: 52px; border-radius: 14px; background: var(--bg); color: var(--accent); display: flex; align-items: center; justify-content: center; }
.choice-title { display: block; font-family: var(--serif); font-size: 20px; font-weight: 600; }
.choice-text { display: block; margin-top: 2px; font-size: 14px; color: var(--muted); }

/* ---- Photo upload ---- */
.dropzone {
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  margin: 8px 0 16px; padding: 40px 16px;
  border: 2px dashed var(--border); border-radius: var(--radius);
  background: var(--surface); color: var(--text); font-size: 17px; font-weight: 500; text-align: center; cursor: pointer;
}
.dropzone svg { color: var(--accent); }
.working { text-align: center; padding: 48px 0; }
.working p { margin: 4px 0; }
.spinner { width: 36px; height: 36px; margin: 0 auto 14px; border: 4px solid var(--border); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- Review / edit recipe ---- */
.ingredient-list { list-style: none; margin: 8px 0 12px; padding: 0; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; }
.ingredient-row { display: flex; flex-wrap: wrap; align-items: flex-start; padding-left: 14px; border-bottom: 1px solid var(--line); }
.ingredient-row:last-child { border-bottom: 0; }
.ingredient-row textarea {
  flex: 1; min-width: 0; margin: 0; padding: 12px 4px 12px 0;
  border: 0; background: transparent; resize: none; overflow: hidden;
  font: 400 16px/1.4 var(--sans); color: var(--text);
}
.ingredient-row textarea:focus { outline: none; }
.ingredient-row:focus-within { box-shadow: inset 3px 0 0 var(--accent); }
.ingredient-row.needs-check { background: var(--warn-bg); }
.check-note { flex-basis: 100%; margin: -6px 0 10px; font-size: 13px; font-weight: 500; color: var(--warn); }
.photos { margin: 20px 0; }
.photos summary { min-height: 44px; display: flex; align-items: center; color: var(--accent); font-weight: 500; cursor: pointer; }
.photos img { width: 100%; border-radius: 12px; margin-top: 8px; }
.source-link { margin: -6px 0 14px; font-size: 14px; color: var(--muted); }
.sticky-actions { position: sticky; bottom: 0; padding: 12px 0 calc(12px + env(safe-area-inset-bottom)); background: linear-gradient(to top, var(--bg) 75%, transparent); }

/* ---- Shopping list ---- */
.progress { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.progress-track { flex: 1; height: 6px; border-radius: 3px; background: var(--border); overflow: hidden; }
.progress-fill { height: 100%; border-radius: 3px; background: var(--accent); transition: width 0.25s; }
.progress-label { font-size: 13px; color: var(--muted); white-space: nowrap; }
.shop-list { list-style: none; margin: 0; padding: 0 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; }
.shop-item { display: flex; align-items: center; gap: 12px; min-height: 48px; border-bottom: 1px solid var(--line); cursor: pointer; user-select: none; }
.shop-item:last-child { border-bottom: 0; }
.check { flex: none; width: 22px; height: 22px; border: 2px solid #C9BCA9; border-radius: 7px; display: flex; align-items: center; justify-content: center; color: var(--accent-text); }
.check svg { visibility: hidden; }
.shop-name { flex: 1; font-size: 16px; }
.shop-amount { font-size: 14px; color: var(--muted); text-align: right; }
.shop-item.done .check { background: var(--accent); border-color: var(--accent); }
.shop-item.done .check svg { visibility: visible; }
.shop-item.done .shop-name, .shop-item.done .shop-amount { opacity: 0.45; text-decoration: line-through; }
.list-footer { margin-top: 28px; display: grid; gap: 4px; justify-items: center; font-size: 14px; color: var(--muted); text-align: center; }

/* ---- Household ---- */
.person { display: flex; align-items: center; gap: 12px; min-height: 56px; }
.avatar { flex: none; width: 36px; height: 36px; border-radius: 18px; background: var(--accent); color: var(--accent-text); display: flex; align-items: center; justify-content: center; font-weight: 600; text-transform: uppercase; }
.person-meta { font-size: 13px; color: var(--muted); }
.invite-box { display: grid; gap: 10px; margin: 12px 0; padding: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; }
.invite-box p { margin: 0; }
.rename { display: flex; gap: 8px; align-items: center; }
.rename input { margin: 0 !important; }
.rename .btn { width: auto; flex: none; }
.setting { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; padding: 6px 0; }
.setting-label { display: block; font-weight: 500; }
.setting-value { display: block; font-size: 14px; color: var(--muted); }
form.inline { display: inline; }
.radio-row { display: flex; align-items: center; gap: 12px; min-height: 52px; margin: 0; color: var(--text); font-size: 16px; font-weight: 400; cursor: pointer; }
.radio-row input { margin: 0; width: 20px; height: 20px; accent-color: var(--accent); }

/* ---- Sign-in screens ---- */
.brand { display: flex; flex-direction: column; align-items: center; gap: 10px; margin: 40px 0 28px; text-align: center; }
.brand img { width: 72px; height: 72px; border-radius: 18px; }
.brand-name { margin: 0; font-family: var(--serif); font-size: 30px; font-weight: 600; }
.brand-tag { margin: 0; color: var(--muted); font-size: 15px; }
.narrow { max-width: 380px; margin: 0 auto; }

/* ---- Tab bar ---- */
.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 10;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  padding: 6px max(8px, env(safe-area-inset-left)) calc(6px + env(safe-area-inset-bottom));
  background: var(--surface); border-top: 1px solid var(--border);
}
.tab { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 3px; min-height: 52px; font-size: 11px; font-weight: 500; color: var(--muted); text-decoration: none; }
.tab.active { color: var(--accent); font-weight: 600; }
.tab-add-circle { width: 48px; height: 48px; margin-top: -18px; border-radius: 24px; background: var(--clay); color: #FFFFFF; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15); }

/* ---- To Do ---- */
.quick-add { display: flex; gap: 8px; margin-bottom: 8px; }
.view-switch { display: flex; gap: 6px; margin-top: 10px; }
.view-switch a { flex: none; min-height: 36px; padding: 0 14px; display: flex; align-items: center; border-radius: 18px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font-size: 14px; font-weight: 500; text-decoration: none; }
.view-switch a[aria-current] { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.needs-details-title { color: var(--warn); }
.needs-details-list { border-color: var(--warn-bg); box-shadow: inset 4px 0 0 var(--warn-bg); padding-left: 18px; }
.chevron { flex: none; color: var(--muted); display: flex; }
.overdue-note { color: var(--danger); margin: -6px 0 8px; }
.push-card, .hint-card { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 24px; padding: 14px 16px; background: var(--surface); border: 1px dashed var(--border); border-radius: 14px; color: var(--accent); text-decoration: none; }
.push-card .setting-label, .hint-card .setting-label { color: var(--text); }

/* The bottom-right + on To Do screens, and the bottom-right Create / Add to list button
   on the add flow. They share a spot so a quick double tap creates and adds. */
.fab {
  position: fixed; z-index: 11; right: max(20px, env(safe-area-inset-right));
  bottom: calc(var(--tabs-height) + 18px + env(safe-area-inset-bottom));
  width: 60px; height: 60px; border-radius: 30px; background: var(--clay); color: #FFFFFF;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}
.fixed-action {
  position: fixed; z-index: 11; right: max(20px, env(safe-area-inset-right)); bottom: calc(20px + env(safe-area-inset-bottom));
  min-width: 150px; min-height: 60px; padding: 0 24px; border: 0; border-radius: 30px;
  background: var(--accent); color: var(--accent-text); font: 600 17px var(--sans);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2); cursor: pointer; touch-action: manipulation;
}
body.with-fab .page { padding-bottom: calc(var(--tabs-height) + 110px + env(safe-area-inset-bottom)); }
body.with-fixed-action .page { padding-bottom: calc(110px + env(safe-area-inset-bottom)); }

/* "Done" moment: a short pop at the bottom of the screen. */
.notice.celebrate {
  position: fixed; z-index: 20; left: 50%; bottom: calc(var(--tabs-height) + 92px + env(safe-area-inset-bottom));
  display: flex; align-items: center; gap: 8px; max-width: calc(100% - 40px); margin: 0;
  background: var(--accent); border-color: var(--accent); color: var(--accent-text); font-weight: 600;
  transform: translateX(-50%); animation: celebrate 2.8s ease-out forwards; pointer-events: none;
}
.celebrate-check { display: flex; }
@keyframes celebrate {
  0% { opacity: 0; transform: translate(-50%, 16px) scale(0.9); }
  12% { opacity: 1; transform: translate(-50%, 0) scale(1.04); }
  20% { transform: translate(-50%, 0) scale(1); }
  80% { opacity: 1; }
  100% { opacity: 0; }
}
@keyframes celebrate-fade { 0%, 80% { opacity: 1; } 100% { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .notice.celebrate { animation-name: celebrate-fade; } }
.quick-add input { margin: 0 !important; }
.quick-add .btn { width: 52px; flex: none; padding: 0; }
.needs-details-sub { color: var(--warn); font-weight: 500; }
.section-title.overdue { color: var(--danger); }
.task-list { list-style: none; margin: 0; padding: 0 14px 0 4px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; }
.task { display: flex; align-items: center; gap: 4px; min-height: 56px; border-bottom: 1px solid var(--line); }
.task:last-child { border-bottom: 0; }
.task-check { width: 44px; height: 44px; flex: none; display: flex; align-items: center; justify-content: center; background: none; border: 0; padding: 0; cursor: pointer; }
.task-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; padding: 10px 0; color: inherit; text-decoration: none; }
.task-title { font-size: 16px; overflow-wrap: anywhere; }
.task-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 13px; color: var(--muted); }
.task-meta:empty { display: none; }
.task-meta .overdue { color: var(--danger); font-weight: 500; }
.badge { padding: 1px 8px; border-radius: 10px; background: var(--warn-bg); color: var(--warn); font-weight: 600; font-size: 12px; }
.task.done .check { background: var(--accent); border-color: var(--accent); }
.task.done .check svg { visibility: visible; }
.task.done .task-title { opacity: 0.45; text-decoration: line-through; }
.done-list { margin-top: 24px; }
.done-list summary { min-height: 44px; display: flex; align-items: center; color: var(--accent); font-weight: 500; cursor: pointer; }
.task-form select, .task-form textarea {
  display: block; width: 100%; margin-top: 6px; padding: 12px 14px;
  font: 400 17px var(--sans); color: var(--text); background: var(--surface);
  border: 1px solid var(--border); border-radius: 12px;
}
.task-form textarea { resize: vertical; }
.segmented { display: flex; gap: 6px; margin: 0 0 14px; padding: 0; border: 0; }
.segmented { margin-bottom: 14px; }
.segmented legend { margin-bottom: 6px; padding: 0; font-size: 14px; font-weight: 500; color: var(--muted); }
.segmented label { flex: 1; margin: 0; }
.segmented input { position: absolute; opacity: 0; }
.segmented label > span { display: flex; align-items: center; justify-content: center; min-height: 44px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); color: var(--text); font-weight: 500; cursor: pointer; }
.segmented input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.segmented input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 1px; }
.segmented:disabled label > span { opacity: 0.6; cursor: default; }
.toggle-row { display: flex; align-items: center; gap: 12px; min-height: 52px; color: var(--text); font-weight: 400; cursor: pointer; }
.toggle-row input { flex: none; width: 20px; height: 20px; margin: 0; accent-color: var(--accent); }
.part-count { font-size: 13px; font-weight: 600; color: var(--accent); font-variant-numeric: tabular-nums; }
a.task-check { text-decoration: none; }
.form-sub { margin: -4px 0 12px; }
.part-add { margin-top: 10px; }
.part-actions { display: flex; align-items: center; gap: 12px; margin-top: 2px; }
.part-actions select { padding: 6px 10px; min-height: 36px; font: 500 14px var(--sans); color: var(--accent); background: var(--bg); border: 1px solid var(--border); border-radius: 10px; }
.part-actions .link-btn { min-height: 36px; font-size: 14px; }

/* ---- This Week ---- */
.header-actions { display: flex; gap: 8px; flex: none; }
.needs-when-link { display: flex; align-items: center; justify-content: space-between; min-height: 48px; margin-bottom: 12px; padding: 0 14px; border-radius: 12px; background: var(--warn-bg); color: var(--warn); font-weight: 600; text-decoration: none; }
.day { margin-bottom: 18px; }
.day-title { display: flex; align-items: baseline; gap: 8px; margin: 0 0 8px; font-family: var(--serif); font-size: 20px; font-weight: 600; }
.day-date { font-family: var(--sans); font-size: 13px; font-weight: 500; color: var(--muted); }
.day.today .day-title { color: var(--accent); }
.day-empty { margin: 0; padding: 12px 14px; border: 1px dashed var(--border); border-radius: 14px; color: var(--muted); font-size: 14px; }
.day-list { list-style: none; margin: 0; padding: 0 10px 0 4px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; }
.day-list > li { border-bottom: 1px solid var(--line); }
.day-list > li:last-child { border-bottom: 0; }
.day.sometime .day-title, .day.to-place .day-title { font-size: 16px; color: var(--muted); }
.meal { display: flex; align-items: center; gap: 6px; min-height: 60px; }
.meal-link { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; padding: 8px 0 8px 6px; color: inherit; text-decoration: none; }
.meal-thumb { flex: none; width: 40px; height: 40px; border-radius: 10px; overflow: hidden; display: flex; align-items: center; justify-content: center; font-family: var(--serif); font-size: 15px; font-weight: 600; color: #FFFFFF; }
.meal-thumb img { width: 100%; height: 100%; object-fit: cover; }
.meal-title { font-family: var(--serif); font-size: 17px; font-weight: 600; line-height: 1.2; overflow-wrap: anywhere; }
.day-picker { max-width: 112px; padding: 6px 8px; min-height: 36px; font: 500 14px var(--sans); color: var(--accent); background: var(--bg); border: 1px solid var(--border); border-radius: 10px; }
.select { display: block; width: 100%; margin-top: 6px; padding: 12px 14px; font: 400 17px var(--sans); color: var(--text); background: var(--surface); border: 1px solid var(--border); border-radius: 12px; }
.top-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }

/* ---- Household: links to every page ---- */
.nav-list a { display: flex; align-items: center; gap: 12px; min-height: 52px; color: var(--text); text-decoration: none; font-weight: 500; }
.nav-list a svg:first-child { color: var(--accent); }
.nav-list a span { flex: 1; }
.nav-list a svg:last-child { color: var(--muted); }
.side-picker { margin-bottom: 4px; }
.side-hint { text-align: left; margin-top: 4px; }

/* The + on the left, for people who set it that way. */
body.fab-left .fab { right: auto; left: max(20px, env(safe-area-inset-left)); }
.hint-card { margin: 0 0 16px; }
.pick-day { display: flex; align-items: center; gap: 10px; margin: -4px 0 14px; color: var(--text); font-weight: 500; }
.pick-day input[type=radio] { flex: none; width: 20px; height: 20px; margin: 0; accent-color: var(--accent); }
.pick-day span { flex: none; }
.pick-day input[type=date] { flex: 1; margin: 0 !important; padding: 8px 10px !important; font-size: 16px !important; }

/* ---- This Week: add to a day, drag between days ---- */
a.day-title { color: inherit; text-decoration: none; min-height: 36px; }
.day-add { margin-left: auto; width: 32px; height: 32px; border-radius: 16px; display: flex; align-items: center; justify-content: center; color: var(--accent); background: var(--surface); border: 1px solid var(--border); }
.day > h2 { margin: 0; font-size: inherit; }
.day-list .day-empty { display: none; padding: 12px 10px; color: var(--muted); font-size: 14px; border: 0; }
.day-list .day-empty:only-child { display: block; }
.day-list:has(> .day-empty:only-child) { border-style: dashed; background: transparent; }
.drag-ghost { opacity: 0.4; background: var(--warn-bg); }
.day-list .drag, .day-list .locked { touch-action: pan-y; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.notice.error-toast { background: var(--text); border-color: var(--text); color: var(--bg); }

/* ---- The + menu ---- */
.fab-wrap > summary { list-style: none; cursor: pointer; }
.fab-wrap > summary::-webkit-details-marker { display: none; }
.fab-wrap[open] > .fab svg { transform: rotate(45deg); transition: transform 0.15s; }
.fab-menu {
  position: fixed; z-index: 12; right: max(20px, env(safe-area-inset-right));
  bottom: calc(var(--tabs-height) + 90px + env(safe-area-inset-bottom));
  display: grid; min-width: 220px; padding: 6px; background: var(--surface); border: 1px solid var(--border);
  border-radius: 16px; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.18);
}
.fab-menu a { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 0 14px; border-radius: 12px; color: var(--text); font-weight: 600; text-decoration: none; }
.fab-menu a svg { color: var(--accent); }
.fab-menu a:active { background: var(--bg); }
body.fab-left .fab-menu { right: auto; left: max(20px, env(safe-area-inset-left)); }

/* ---- Shopping: typed-in items, stores ---- */
.add-item { margin-bottom: 12px; }
.item-store-pick { flex: none; max-width: 120px; padding: 0 8px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); color: var(--text); font: 500 15px var(--sans); }
.store-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 8px; }
.store-chips a { min-height: 34px; padding: 0 12px; display: flex; align-items: center; border-radius: 17px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font-size: 14px; font-weight: 500; text-decoration: none; }
.store-chips a[aria-current] { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.store-chips .link-btn { margin-left: auto; min-height: 34px; font-size: 14px; }
.store-editor { margin-bottom: 8px; }
.shop-meta { display: block; font-size: 12px; color: var(--muted); }
.shop-edit { display: none; align-items: center; gap: 4px; }
body.editing-stores .shop-edit { display: flex; }
body.editing-stores .shop-item { cursor: default; }
.tag-pick { max-width: 110px; padding: 4px 6px; min-height: 34px; font: 500 13px var(--sans); color: var(--accent); background: var(--bg); border: 1px solid var(--border); border-radius: 10px; }
.clear-checked { text-align: center; margin-top: 12px; }
/* The item under your finger while dragging: a lifted tile, not a bare row. */
.sortable-fallback { background: var(--surface); border: 1px solid var(--border) !important; border-radius: 14px; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22); opacity: 1 !important; list-style: none; }
.sortable-chosen.drag { background: var(--surface); }

/* ---- Recipe book ---- */
#book-search { margin-bottom: 4px; }
.heart.on { color: var(--clay); }
.heart.on svg { fill: currentColor; }
.small-pill { min-height: 36px; padding: 0 12px; font-size: 13px; white-space: nowrap; }
.page-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }

/* ---- Feedback ---- */
.feedback-btn { margin-top: 32px; }
.feedback-list > li { padding: 12px 0; }
.feedback-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 0 4px; font-size: 13px; color: var(--muted); }
.feedback-meta strong { color: var(--text); }
.feedback-text { margin: 0; overflow-wrap: anywhere; }
.badge.feedback-like { background: var(--accent); color: var(--accent-text); }
.badge.feedback-idea { background: var(--bg); color: var(--accent); border: 1px solid var(--border); }
