/* Food tab styles — moved out of index.html (queue 7.24, 2026-09-25). Linked right after the
   inline <style> block, so the cascade order is unchanged. */
/* ── Food tab ──────────────────────────────────────────────────
   Local-first macro tracking. Every surface here is designed to render
   with zero network: the seed DB is a static file cached by sw.js, the
   log lives in localStorage, and GitHub is a background sync rather than
   a read path. Lumen searches online first and stalls on weak signal;
   nothing in this tab ever waits on a request to show a number. */

/* Date strip */
.fd-datebar { display:flex; align-items:center; gap:8px; padding:4px 0 2px; }
.fd-datebar button { background:var(--surface); border:1px solid var(--border);
  color:var(--text); border-radius:8px; min-width:34px; min-height:32px;
  font-size:14px; cursor:pointer; }
.fd-datebar button:disabled { opacity:.35; }
.fd-date { flex:1; text-align:center; font-size:16px; font-weight:600; }
.fd-date span { font-size:14px; color:var(--text-dim); font-weight:400; margin-left:6px; }
.fd-fast-btn { font-size:14px !important; padding:0 10px; min-width:auto !important; }
.fd-fast-btn.remind { background:#f4c21b !important; border-color:#d9a900 !important; color:#1b1b1b !important; }
.fd-fast-btn.active { background:#5a47c9 !important; border-color:#5a47c9 !important; color:#fff !important; }
.fd-today-btn { font-size:14px !important; padding:0 12px; min-width:auto !important; }

/* Hero: calories remaining + macro bars */
/* No card around the two bars (Brett, 2026-10-01): the border and padding only cost height. */
.fd-hero { margin-bottom:12px; }
/* Calories bar for the day: three equal slots (breakfast, lunch, dinner + snacks)
   split by the dark pace lines. Each meal fills its own slot from its line, so an
   unused part of a slot stays light; a meal past its third doubles back from the
   slot's right edge in dark purple (Brett, 2026-11-08). */
.fd-kslot { position:absolute; top:0; bottom:0; width:33.333%; }
.fd-kslot-fill { position:absolute; inset:0 auto 0 0; background:#9d8ff5; transition:width .25s ease; }
.fd-kslot-over { position:absolute; inset:0 0 0 auto; background:#5a47c9; transition:width .25s ease; }
.fd-kbar { position:relative; height:24px; border-radius:8px; overflow:hidden; background:#ddd8fb; }
.fd-kbar-fill { position:absolute; inset:0 auto 0 0; background:#9d8ff5; transition:width .25s ease; }
/* Over target, no red (Brett, 2026-11-08): the part past the target is a deeper
   shade of whatever color sits under it, with a dark edge marking the target. */
.fd-over { position:absolute; top:0; bottom:0; right:0; pointer-events:none;
  background:repeating-linear-gradient(135deg, rgba(0,0,0,.24) 0 5px, transparent 5px 10px);
  border-left:2px solid #1b1b1b; }
.fd-kbar-pace { position:absolute; top:0; bottom:0; width:2px; margin-left:-1px; background:#1b1b1b; opacity:.55; }
.fd-kbar-tick { position:absolute; top:6px; bottom:6px; width:1px; background:#1b1b1b; opacity:.2; }
.fd-kbar-txt { position:relative; height:100%; display:flex; align-items:center; justify-content:space-between;
  padding:0 12px; color:#1b1b1b; font-variant-numeric:tabular-nums; }
.fd-kbar-txt span { font-size:15px; }
.fd-kbar-txt b { font-size:17px; font-weight:700; }
.fd-macros { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; margin-top:10px; }
.fd-macro-label { display:flex; justify-content:space-between; font-size:14px; margin-bottom:5px; }
.fd-macro-label b { font-weight:600; }
.fd-macro-label span { color:var(--text-dim); }
.fd-track { height:7px; background:var(--surface2); border-radius:4px; overflow:hidden; }
.fd-fill { height:100%; border-radius:4px; transition:width .25s ease; }
.fd-fill.p { background:var(--accent); }
.fd-fill.c { background:var(--yellow); }
.fd-fill.f { background:var(--green); }
.fd-fill.over { background:var(--red); }
/* Proportional macro bar, Lumen colors. Track colors are fixed light tints
   in both themes so the dark label text always reads. */
.fd-macros { display:block; margin-top:0; }
.fd-macros + .fd-kbar { margin-top:6px; }
.fd-pbar { display:flex; height:24px; border-radius:8px; overflow:hidden; gap:2px; }
.fd-seg { position:relative; min-width:0; }
.fd-seg.c { background:#fbe8a6; } .fd-seg.c .fd-seg-fill { background:#f4c21b; }
.fd-seg.p { background:#e8dcf6; } .fd-seg.p .fd-seg-fill { background:#bf9ae6; }
.fd-seg.f { background:#c2eee2; } .fd-seg.f .fd-seg-fill { background:#2bbf9e; }
.fd-seg-fill { position:absolute; inset:0 auto 0 0; transition:width .25s ease; }
.fd-seg-txt { position:relative; height:100%; display:flex; align-items:center; justify-content:center; gap:5px;
  padding:0 8px; color:#1b1b1b; line-height:1.2; white-space:nowrap; overflow:hidden; }
.fd-seg-txt b { font-size:14px; font-weight:700; }
.fd-seg-txt span { font-size:15px; font-variant-numeric:tabular-nums; }
.fd-minibar { display:flex; width:100%; height:16px; border-radius:4px; overflow:hidden; margin-top:3px; gap:1px; }
.fd-minibar i { font-style:normal; font-size:14px; font-weight:700; line-height:16px; text-align:center;
  color:#1b1b1b; min-width:0; overflow:hidden; }
.fd-minibar i.c { background:#f4c21b; } .fd-minibar i.p { background:#bf9ae6; } .fd-minibar i.f { background:#2bbf9e; }

/* Offline / sync status chip */
.fd-status { display:none; align-items:center; gap:8px; font-size:14px;
  padding:8px 12px; border-radius:8px; margin-bottom:12px; }
.fd-status.show { display:flex; }
.fd-status.offline { background:rgba(224,180,74,.12); border:1px solid var(--yellow); color:var(--yellow); }
.fd-status.synced  { background:rgba(76,175,130,.12); border:1px solid var(--green); color:var(--green); }
.fd-dot { width:8px; height:8px; border-radius:50%; background:currentColor; flex-shrink:0; }

/* Meal cards */
.fd-meal { background:var(--surface); border:1px solid var(--border);
  border-radius:12px; margin-bottom:10px; overflow:hidden; }
.fd-meal-compact .fd-meal-head { padding:6px 14px; min-height:0; }
.fd-meal-compact .fd-meal-head h3 { font-size:14px; }
.fd-meal-head { display:flex; align-items:center; gap:10px; padding:12px 14px; }
.fd-meal-head h3 { flex:1; margin:0; font-size:16px; font-weight:600; }
.fd-meal-kcal { font-size:14px; color:var(--text-dim); }
.fd-add { background:var(--accent-dim); border:1px solid var(--accent); color:var(--text);
  width:34px; height:34px; border-radius:9px; font-size:20px; line-height:1;
  cursor:pointer; flex-shrink:0; }
.fd-entry { display:flex; align-items:center; gap:10px; padding:10px 14px;
  border-top:1px solid var(--border); cursor:pointer; }
.fd-entry-body { flex:1; min-width:0; }
.fd-entry-name { font-size:15px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.fd-entry-sub { font-size:14px; color:var(--text-dim); margin-top:2px; }
.fd-entry-kcal { font-size:15px; font-weight:600; flex-shrink:0; }
.fd-entry-del { background:none; border:none; color:var(--text-dim); font-size:18px;
  cursor:pointer; padding:0 2px; flex-shrink:0; min-width:32px; min-height:32px; }
/* Recipe assistant (queue 7.101). */
.fd-rc-ask { width:100%; box-sizing:border-box; margin-top:4px; background:var(--bg); color:var(--text);
  border:1px solid var(--border); border-radius:8px; padding:10px; font-size:17px; font-family:inherit; resize:vertical; }
.fd-rc-ask:focus { border-color:var(--accent); outline:none; }
.fd-rc-p100 { margin:10px 0 4px; font-size:17px; }
.fd-rc-miss { display:block; width:100%; text-align:left; margin-top:6px; padding:8px 10px; font-size:15px;
  background:rgba(224,180,74,.12); border:1px solid var(--yellow); color:var(--text); border-radius:8px; cursor:pointer; }
/* Quantity stepper: two eggs log as 50 g x 2 (queue 7.104). */
.fd-qty { display:inline-flex; align-items:center; gap:4px; flex-shrink:0; }
.fd-qty-btn { background:var(--surface2); border:1px solid var(--border); color:var(--text);
  border-radius:8px; min-width:32px; min-height:32px; font-size:17px; cursor:pointer; }
.fd-qty-btn:disabled { opacity:.4; cursor:default; }
.fd-qty-n { min-width:30px; text-align:center; font-size:15px; font-weight:600; }
.fd-qty-tag { font-size:14px; color:var(--text-dim); font-weight:400; }
.fd-meal-empty { padding:10px 14px; border-top:1px solid var(--border);
  font-size:14px; color:var(--text-dim); }

/* Targets drawer */
.fd-targets { background:var(--surface); border:1px solid var(--border);
  border-radius:12px; margin-bottom:10px; }
.fd-targets summary { padding:12px 14px; font-size:15px; cursor:pointer;
  color:var(--text-dim); list-style:none; }
.fd-targets summary::-webkit-details-marker { display:none; }
.fd-targets-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:10px; padding:0 14px 14px; }
.fd-targets-grid label { font-size:14px; color:var(--text-dim); display:block; margin-bottom:4px; }
.fd-targets-grid input { width:100%; background:var(--bg); border:1px solid var(--border);
  color:var(--text); border-radius:8px; padding:9px 8px; font-size:15px; }
.fd-targets-grid input:focus { border-color:var(--accent); outline:none; }

/* ── Add sheet ─────────────────────────────────────────────── */
/* Full screen rather than a bottom sheet: the add flow uses the whole
   display, starting at the top where the thumb and eye already are. */
.fd-sheet { position:fixed; inset:0; z-index:60; background:var(--bg);
  display:none; align-items:stretch; }
.fd-sheet.open { display:flex; }
.fd-sheet-inner { width:100%; max-width:680px; margin:0 auto; background:var(--bg);
  height:100%; max-height:100dvh; display:flex; flex-direction:column;
  padding-top:env(safe-area-inset-top);
  padding-bottom:env(safe-area-inset-bottom); }
.fd-sheet-head { display:flex; align-items:center; gap:10px; padding:14px;
  border-bottom:1px solid var(--border); }
.fd-sheet-head h3 { flex:1; margin:0; font-size:17px; font-weight:600; }
.fd-sheet-head button { background:none; border:none; color:var(--text-dim);
  font-size:22px; cursor:pointer; min-width:40px; min-height:40px; }
.fd-sheet-body { overflow-y:auto; padding:14px; }

.fd-scan-btn { width:100%; display:flex; align-items:center; justify-content:center;
  gap:6px; background:var(--accent-dim); border:1px solid var(--accent);
  color:var(--text); border-radius:10px; padding:6px 8px; min-height:44px; font-size:15px;
  font-weight:600; cursor:pointer; margin-bottom:12px; }
.fd-scan-btn svg { width:18px; height:18px; flex:none; }
.fd-search { width:100%; background:var(--surface); border:1px solid var(--border);
  color:var(--text); border-radius:10px; padding:13px 14px; font-size:16px; }
.fd-search:focus { border-color:var(--accent); outline:none; }
.fd-hint { font-size:14px; color:var(--text-dim); margin:10px 2px 6px; }

.fd-result { display:flex; align-items:center; gap:10px; padding:11px 4px;
  border-bottom:1px solid var(--border); cursor:pointer; }
.fd-result-body { flex:1; min-width:0; }
.fd-result-name { font-size:15px; }
.fd-result-sub { font-size:14px; color:var(--text-dim); margin-top:2px; }
.fd-result-kcal { font-size:14px; color:var(--text-dim); flex-shrink:0; }
.fd-tagsrc { display:inline-block; font-size:14px; padding:1px 6px; border-radius:5px;
  background:var(--surface2); color:var(--text-dim); margin-left:6px; }

/* Portion picker */
.fd-portion-name { font-size:17px; font-weight:600; margin-bottom:4px; }
.fd-portion-sub { font-size:14px; color:var(--text-dim); margin-bottom:14px; }
.fd-serv-row { display:flex; flex-wrap:wrap; gap:8px; margin-bottom:14px; }
.fd-serv { background:var(--surface); border:1px solid var(--border); color:var(--text);
  border-radius:16px; padding:8px 14px; font-size:14px; cursor:pointer; min-height:40px; }
.fd-serv.active { background:var(--accent-dim); border-color:var(--accent); }
.fd-gram-row { display:flex; align-items:center; gap:8px; margin-bottom:16px; }
.fd-gram-row input { flex:1; min-width:0; width:0; background:var(--surface); border:1px solid var(--border);
  color:var(--text); border-radius:10px; padding:13px 14px; font-size:17px; }
.fd-gram-row input:focus { border-color:var(--accent); outline:none; }
.fd-gram-row span { font-size:15px; color:var(--text-dim); }
/* Saved meals + day plans (Lumen carry-over) */
.fd-plans { margin:10px 0 12px; }
/* Narrow side padding so the C|P|F minibar spans nearly the whole chip (Brett, 2026-10-01). */
.fd-plans .fd-serv { flex:1; display:flex; flex-direction:column; align-items:stretch; text-align:center;
  line-height:1.2; padding:4px 5px; min-height:0; }
/* A fixed light fill with dark text (Brett, 2026-09-21): --surface2 sat one
   shade off the card and read as part of the background in the dark theme. */
.fd-save-meal { background:#e4ddff; border:1px solid #b9aaf5; color:#2a2160; font-weight:600;
  border-radius:14px; padding:6px 10px; font-size:14px; cursor:pointer; }
.fd-meal-item { display:flex; align-items:center; gap:10px; margin-bottom:10px; }
.fd-meal-item-name { flex:1; font-size:15px; min-width:0; }
.fd-renamable { cursor:pointer; text-decoration:underline dotted var(--text-dim); text-underline-offset:3px; }
.fd-meal-item input { width:90px; background:var(--surface); border:1px solid var(--border);
  color:var(--text); border-radius:10px; padding:10px 12px; font-size:17px; }
.fd-meal-item span { font-size:15px; color:var(--text-dim); }
.fd-result-meal .fd-result-name { font-weight:600; }
.fd-nf { display:block; font-size:14px; color:var(--text-dim); margin-top:10px; }
.fd-nf input { font-size:17px; margin-top:4px; }
.fd-danger { color:#e06c6c; border-color:#e06c6c55; margin-top:8px; }
.fd-preview { display:grid; grid-template-columns:repeat(4,1fr); gap:8px;
  background:var(--surface); border:1px solid var(--border); border-radius:10px;
  padding:12px; margin-bottom:16px; text-align:center; }
.fd-preview div span { display:block; font-size:14px; color:var(--text-dim); }
.fd-preview div b { font-size:18px; font-weight:600; }
.fd-primary { width:100%; background:var(--accent); border:none; color:#fff;
  border-radius:10px; padding:15px; font-size:16px; font-weight:600; cursor:pointer; }
.fd-secondary { width:100%; background:none; border:1px solid var(--border);
  color:var(--text-dim); border-radius:10px; padding:13px; font-size:15px;
  cursor:pointer; margin-top:10px; }

/* Scanner */
.fd-cam-wrap { position:relative; background:#000; border-radius:12px;
  overflow:hidden; aspect-ratio:4/3; margin-bottom:12px; }
.fd-cam-wrap video { width:100%; height:100%; object-fit:cover; display:block; }
.fd-reticle { position:absolute; left:12%; right:12%; top:34%; bottom:34%;
  border:2px solid var(--accent); border-radius:10px; box-shadow:0 0 0 100vmax rgba(0,0,0,.35); }
.fd-scan-msg { font-size:14px; color:var(--text-dim); text-align:center; margin-bottom:12px; }

/* Input-method row: scan and speak are peers, both faster than typing. */
.fd-btn-row { display:flex; gap:10px; margin-bottom:12px; }
.fd-btn-row .fd-scan-btn { flex:1 1 0; min-width:0; margin-bottom:0; white-space:nowrap; }
.fd-voice-rows { margin-top:4px; }
.fd-vrow { display:flex; align-items:center; gap:10px; padding:10px 4px;
  border-bottom:1px solid var(--border); }
.fd-vrow-body { flex:1; min-width:0; }
.fd-vrow-name { font-size:15px; }
.fd-vrow-sub { font-size:14px; color:var(--text-dim); margin-top:2px; }
.fd-vrow.miss .fd-vrow-name { color:var(--yellow); }
.fd-vrow input { width:72px; background:var(--bg); border:1px solid var(--border);
  color:var(--text); border-radius:8px; padding:8px; font-size:15px; }
.fd-vrow button { background:none; border:none; color:var(--text-dim);
  font-size:14px; cursor:pointer; min-height:36px; }
.fd-mic { width:96px; height:96px; border-radius:50%; border:none;
  background:var(--accent); color:#fff; font-size:34px; cursor:pointer;
  display:block; margin:18px auto; }
.fd-mic.live { animation:fdpulse 1.2s ease-in-out infinite; }
@keyframes fdpulse { 0%,100% { box-shadow:0 0 0 0 rgba(124,106,247,.5); }
                     50%     { box-shadow:0 0 0 18px rgba(124,106,247,0); } }
.fd-transcript { min-height:52px; font-size:17px; text-align:center;
  color:var(--text); margin:10px 0 14px; }
.fd-transcript.interim { color:var(--text-dim); }
.fd-ocr-field { margin-bottom:10px; }
.fd-ocr-field label { display:block; font-size:14px; color:var(--text-dim); margin-bottom:4px; }
.fd-ocr-field input { width:100%; background:var(--surface); border:1px solid var(--border);
  color:var(--text); border-radius:8px; padding:11px; font-size:16px; }
.fd-ocr-field.missing input { border-color:var(--yellow); }

/* Weight + TDEE calibration */
.fd-weight { background:var(--surface); border:1px solid var(--border);
  border-radius:12px; padding:12px 14px; margin-bottom:10px; }
.fd-weight-row { display:flex; align-items:center; gap:10px; }
.fd-weight-row label { font-size:15px; font-weight:600; }
.fd-weight-row input { width:88px; background:var(--bg); border:1px solid var(--border);
  color:var(--text); border-radius:8px; padding:9px 10px; font-size:16px; }
.fd-weight-row input:focus { border-color:var(--accent); outline:none; }
.fd-unit { background:var(--surface2); border:1px solid var(--border); color:var(--text-dim);
  border-radius:8px; padding:9px 11px; font-size:14px; cursor:pointer; min-height:40px; }
.fd-steps-row { margin-top:8px; flex-wrap:wrap; }
/* Walks and Steps share one row (2026-11-08): the steps box takes what is left. */
.fd-steps-row label[for="fd-steps"] { min-width:0; margin-left:4px; }
.fd-steps-row #fd-steps, .fd-steps-row input[type=number] { flex:1; min-width:64px; width:0; }
.fd-weight-row label { min-width:52px; }
.fd-trend { flex:1; text-align:right; font-size:14px; color:var(--text-dim); }
.fd-calib { padding-top:10px; }
.fd-calib-wrap { border-top:1px solid var(--border); margin-top:12px; padding-top:10px; }
.fd-calib-wrap summary { font-size:15px; font-weight:600; cursor:pointer; min-height:32px;
  display:flex; align-items:center; color:var(--text-dim); }
/* Meal cards fold by tapping the meal name; the + stays usable when folded. */
.fd-meal-head h3 { cursor:pointer; user-select:none; }
.fd-chev { display:inline-block; width:20px; color:var(--text-dim); font-size:14px; }
.fd-meal.shut .fd-entry, .fd-meal.shut .fd-meal-empty { display:none; }
/* Day plans: one row dragged sideways, three chips visible, snapping to a chip. */
.fd-plans { flex-wrap:nowrap; overflow-x:auto; scroll-snap-type:x mandatory; scrollbar-width:none;
  overscroll-behavior-x:contain; cursor:grab; }
.fd-plans::-webkit-scrollbar { display:none; }
.fd-plans.dragging { scroll-snap-type:none; cursor:grabbing; user-select:none; }
.fd-plans .fd-serv { flex:0 0 calc((100% - 16px) / 3); min-width:0; scroll-snap-align:start; }
/* Tiny edge triangles, shown only while more plans sit off that edge. */
.fd-plans-wrap { display:flex; align-items:center; gap:2px; margin:10px 0 12px; }
.fd-plans-wrap .fd-plans { flex:1; min-width:0; margin:0; }
.fd-plans-hint { flex:0 0 12px; font-size:14px; line-height:1; text-align:center; color:var(--text-dim);
  visibility:hidden; }
.fd-plans-wrap.can-l .fd-plans-hint.l, .fd-plans-wrap.can-r .fd-plans-hint.r { visibility:visible; }
.fd-exercise { font-size:15px; margin:10px 0 4px; }
.fd-exercise span { color:var(--text-dim); font-size:14px; }
.fd-calib-head { font-size:14px; color:var(--text-dim); text-transform:uppercase;
  letter-spacing:.06em; margin-bottom:6px; }
.fd-calib-value { font-size:32px; font-weight:700; letter-spacing:-.5px; margin-bottom:6px; }
.fd-calib-value i { font-style:normal; font-size:15px; font-weight:400; color:var(--text-dim); }
.fd-calib-note { margin-top:8px; }
.fd-calib-apply { margin-top:12px; }
.fd-goal-row { display:flex; align-items:center; gap:10px; margin:12px 0 8px; }
.fd-goal-row label { font-size:15px; font-weight:600; }
.fd-goal-row input { width:80px; background:var(--bg); border:1px solid var(--border);
  color:var(--text); border-radius:8px; padding:9px 10px; font-size:16px; }
.fd-goal-row span { font-size:14px; color:var(--text-dim); }

/* History import + weighed/estimated */
.fd-import summary { padding:12px 14px; font-size:15px; cursor:pointer;
  color:var(--text-dim); list-style:none; }
.fd-import summary::-webkit-details-marker { display:none; }
.fd-import-body { padding:0 14px 14px; }
.fd-import-body textarea { width:100%; min-height:120px; background:var(--bg);
  border:1px solid var(--border); color:var(--text); border-radius:8px;
  padding:11px; font-size:15px; font-family:ui-monospace,Menlo,Consolas,monospace; }
.fd-import-body textarea:focus { border-color:var(--accent); outline:none; }
.fd-import-stat { display:grid; grid-template-columns:repeat(4,1fr); gap:8px;
  background:var(--bg); border:1px solid var(--border); border-radius:10px;
  padding:10px; margin:10px 0; text-align:center; }
.fd-import-stat div span { display:block; font-size:14px; color:var(--text-dim); }
.fd-import-stat div b { font-size:17px; font-weight:600; }
.fd-warn { color:var(--yellow); }
.fd-ok { color:var(--green); }
.fd-est-tag { font-size:14px; color:var(--yellow); margin-left:6px; }
.fd-imported-note { padding:10px 14px; border-top:1px solid var(--border);
  font-size:14px; color:var(--text-dim); }

/* Meal tiles: one row of four (7.77). 4 across at 360px, >=44px tall, 14px text. */
.fd-tiles { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:6px; margin-bottom:10px; }
.fd-tile { display:flex; flex-direction:column; align-items:center; justify-content:center;
  gap:1px; min-height:44px; padding:3px 2px; background:var(--accent-dim);
  border:1px solid var(--accent); border-radius:10px; color:var(--text); cursor:pointer; }
.fd-tile-name { font-size:14px; font-weight:600; }
.fd-tile-kcal { font-size:14px; color:var(--text-dim); white-space:nowrap; }
/* The meal's C/P/F split by grams, same colors as the day's macro bar. */
.fd-tilebar { display:flex; width:80%; height:6px; border-radius:3px; overflow:hidden; gap:1px; margin-top:2px; }
.fd-tilebar.empty { background:var(--surface2); }
.fd-tilebar i { display:block; min-width:0; }
.fd-tilebar i.c { background:#f4c21b; } .fd-tilebar i.p { background:#bf9ae6; } .fd-tilebar i.f { background:#2bbf9e; }

/* Add-sheet multi-select (7.77) */
.fd-chk { display:flex; align-items:center; justify-content:center; width:44px; min-height:44px;
  flex-shrink:0; cursor:pointer; margin:-4px 0 -4px -4px; }
.fd-chk input { width:24px; height:24px; margin:0; cursor:pointer; accent-color:var(--accent); }
.fd-selbar { position:sticky; bottom:0; padding:10px 0 4px; background:var(--bg); }
.fd-selbar-note { text-align:center; font-size:14px; color:var(--text-dim); padding-top:6px; }
.fd-link { display:block; background:none; border:none; color:var(--text-dim); font-size:14px;
  text-decoration:underline; padding:14px 0; min-height:44px; cursor:pointer; margin:0 auto; }

/* Add sheet: favourites (star per row, filter button beside the search box) */
.fd-topbar { display:flex; gap:8px; align-items:stretch; }
.fd-topbar .fd-search { flex:1; min-width:0; }
.fd-favbtn { flex-shrink:0; min-height:44px; padding:0 12px; font-size:14px; cursor:pointer;
  background:none; border:1px solid var(--border); border-radius:10px; color:var(--text-dim); }
.fd-favbtn.on { color:var(--yellow); border-color:var(--yellow); font-weight:600; }
#fd-favbtn, #fd-dessertbtn { font-size:20px; min-width:44px; padding:0 10px; }
#fd-dessertbtn { filter:grayscale(1); opacity:.45; }
#fd-dessertbtn.on { filter:none; opacity:1; }
/* Marks: star then dessert, side by side, on every list row (Brett, 2026-10-04) */
.fd-marks { display:flex; flex-direction:row; align-items:center; width:52px; flex-shrink:0; align-self:stretch; }
.fd-marks .fd-star, .fd-dessert { width:26px; height:auto; min-height:0; align-self:stretch; padding:0; }
.fd-marks .fd-star { font-size:17px; }
.fd-dessert { background:none; border:none; font-size:14px; line-height:1; cursor:pointer;
  filter:grayscale(1); opacity:.35; }
.fd-dessert.on { filter:none; opacity:1; }
.fd-star { flex-shrink:0; width:44px; min-height:44px; background:none; border:none;
  font-size:22px; line-height:1; cursor:pointer; color:var(--text-dim); }
.fd-star.on { color:var(--yellow); }

/* Macro columns (Brett, 2026-09-30): name left, then g / C / P / F / kcal in
   fixed right-aligned columns so values line up down every list. */
.fd-row-body { flex:1; min-width:0; }
.fd-row-name { font-size:15px; line-height:1.3; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.fd-row-body .fd-cols { margin-top:2px; }
.fd-result-meal .fd-row-name { font-weight:600; }
.fd-cols { display:flex; gap:3px; flex-shrink:0; font-size:14px; color:var(--text-dim);
  font-variant-numeric:tabular-nums; }
.fd-cols span { text-align:left; }
.fd-c-g { width:48px; } .fd-c-c, .fd-c-p { width:44px; } .fd-c-f { width:40px; }
.fd-cols .fd-c-k { width:72px; color:var(--text); font-weight:600; }
.fd-result { gap:6px; }
.fd-entry { gap:8px; }
.fd-star { width:36px; }
.fd-star-pad { width:36px; flex-shrink:0; }
/* Compact list rows (Brett, 2026-10-04): small checkbox, thin padding. The
   checkbox label and the mark buttons stretch to the full row height, so the
   tap areas stay as tall as the row. */
.fd-result { padding:5px 2px; gap:4px; min-height:0; }
.fd-result .fd-chk { width:28px; min-height:0; align-self:stretch; margin:0; }
.fd-result .fd-chk input { width:18px; height:18px; }
