/* Administration, in the shadcn/ui language: zinc neutrals, Socialo green as
   the primary, 8px controls, cards with a header, quiet tables and badges. */
:root {
  --bg: #fafafa; --card: #ffffff; --fg: #09090b; --fg-2: #3f3f46; --muted: #f4f4f5; --muted-fg: #71717a;
  --border: #e4e4e7; --input: #e4e4e7; --primary: #386a20; --primary-hover: #2f5a1b; --primary-soft: #eef5e9;
  --ring: rgba(56, 106, 32, .28); --danger: #dc2626;
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, .05);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, .06), 0 1px 2px -1px rgba(0, 0, 0, .06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, .1), 0 4px 6px -4px rgba(0, 0, 0, .1);
  /* What the scripts' markup and styles.css still name. */
  --ink: var(--fg); --ink-2: var(--fg-2); --ink-3: var(--muted-fg); --line: var(--border);
  --surface: var(--card); --page: var(--bg); --brand: var(--primary); --brand-soft: var(--primary-soft);
}
body { background: var(--bg); color: var(--fg); font-size: 14px; line-height: 1.5; }
.muted { color: var(--muted-fg); }
.small { font-size: 12.5px; }

/* Header and tabs */
.top { background: rgba(255, 255, 255, .85); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 3; backdrop-filter: saturate(1.5) blur(12px); }
.top-inner { max-width: 1200px; margin: 0 auto; height: 60px; display: flex; align-items: center; gap: 16px; padding: 0 20px; }
.brand { display: flex; align-items: center; gap: 10px; margin-right: 8px; }
.brand .mark { width: 30px; height: 30px; }
.brand > div { display: grid; line-height: 1.2; }
.brand strong { font-size: 14.5px; font-weight: 600; letter-spacing: -.01em; }
.brand span { font-size: 12px; }
nav { display: inline-flex; gap: 2px; padding: 3px; border-radius: 10px; background: var(--muted); margin-right: auto; overflow-x: auto; scrollbar-width: none; }
nav button { height: 30px; padding: 0 12px; border: none; border-radius: 7px; background: none; color: var(--muted-fg); font-size: 13.5px; font-weight: 500; white-space: nowrap; cursor: pointer; transition: background .15s, color .15s, box-shadow .15s; }
nav button:hover { color: var(--fg); }
nav button[aria-selected="true"] { background: var(--card); color: var(--fg); box-shadow: var(--shadow-sm); }
.who { font-size: 13px; white-space: nowrap; }
@media (max-width: 1000px) { .who { display: none; } }

/* Buttons */
.btn { height: 36px; min-height: 36px; padding: 0 14px; gap: 8px; border-radius: 8px; border: 1px solid var(--border); background: var(--card); color: var(--fg); font-size: 14px; font-weight: 500; white-space: nowrap; box-shadow: var(--shadow-xs); transition: background .15s, border-color .15s, box-shadow .15s; }
.btn:hover { background: var(--muted); border-color: var(--border); }
.btn:active { transform: none; }
.btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn.primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
.btn.ghost { background: transparent; border-color: transparent; box-shadow: none; color: var(--fg-2); }
.btn.ghost:hover { background: var(--muted); }
.btn:focus-visible, nav button:focus-visible, .chip:focus-visible, .icon-btn:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--ring); }
.link-btn { justify-self: start; height: 32px; padding: 0; border: none; background: none; color: var(--primary); font-size: 13.5px; font-weight: 500; cursor: pointer; text-underline-offset: 4px; }
.link-btn:hover { text-decoration: underline; }
.link { border: none; background: none; padding: 0; color: var(--danger); font-size: 13.5px; font-weight: 500; cursor: pointer; text-underline-offset: 4px; }
.link:hover { text-decoration: underline; }
.icon-btn { width: 36px; height: 36px; border: none; border-radius: 8px; background: none; color: var(--muted-fg); display: grid; place-items: center; cursor: pointer; transition: background .15s, color .15s; }
.icon-btn:hover { background: #fef2f2; color: var(--danger); }

/* Inputs */
.field { display: grid; gap: 6px; font-size: 13px; font-weight: 500; color: var(--fg); }
.field input, .field select, .rules input[type=text], .rules input[type=number], .rules input[type=time], .rules input[type=search], .rules select, .link-field {
  height: 36px; min-height: 36px; padding: 0 12px; border: 1px solid var(--input); border-radius: 8px; background: var(--card);
  color: var(--fg); font-size: 14px; font-weight: 400; box-shadow: var(--shadow-xs); outline: none; min-width: 0;
  transition: border-color .15s, box-shadow .15s;
}
.field input:focus-visible, .field select:focus-visible, .rules input:focus-visible, .rules select:focus-visible, .link-field:focus-visible {
  border-color: var(--primary); box-shadow: 0 0 0 3px var(--ring);
}
.field select, .rules select { appearance: none; padding-right: 34px; cursor: pointer;
  background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2371717a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 9 5 5 5-5'/%3E%3C/svg%3E") no-repeat right 10px center; }
input::placeholder { color: #a1a1aa; }

/* Page */
.page { max-width: 1200px; margin: 0 auto; padding: 32px 20px 72px; }
.tab:not([hidden]) { animation: show .22s cubic-bezier(.16, 1, .3, 1); }
@keyframes show { from { opacity: 0; transform: translateY(4px); } }
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.head h1 { margin: 0; font-size: 24px; font-weight: 600; letter-spacing: -.025em; }
.head p { margin: 4px 0 0; }
h2 { font-size: 15px; font-weight: 600; letter-spacing: -.01em; margin: 32px 0 12px; }
h3 { font-size: 14px; font-weight: 600; margin: 0 0 8px; color: var(--fg); }
.lead { margin: -12px 0 20px; }
.filters { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }

/* Cards */
.panel-box, .card, .group, .meal { background: var(--card); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow-sm); overflow: hidden; }
.card + .card, .card + .title-row { margin-top: 20px; }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 20px 24px; flex-wrap: wrap; }
.card-head h2, .card-head h3 { margin: 0; font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
.card-head p { margin: 4px 0 0; color: var(--muted-fg); font-size: 13.5px; max-width: 64ch; }
.head-actions { display: flex; align-items: center; gap: 12px; }
.head-actions > :empty { display: none; }
.card-body { padding: 0 24px 24px; }
.scroll { overflow-x: auto; }
.card > .scroll, .card > .rows { border-top: 1px solid var(--border); }
.empty { padding: 28px 24px; color: var(--muted-fg); text-align: center; }

/* Tables */
table { border-collapse: collapse; width: 100%; font-size: 14px; }
th { height: 40px; padding: 8px 16px; vertical-align: middle; text-align: left; font-size: 13px; font-weight: 500; color: var(--muted-fg); background: transparent; border-bottom: 1px solid var(--border); white-space: nowrap; }
td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: #fafafa; }
th:first-child, td:first-child { padding-left: 24px; }
th:last-child, td:last-child { padding-right: 24px; }
td.lines { white-space: pre-line; }
tr.total td { font-weight: 600; background: #fafafa; }

/* Badges */
.tag { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border: 1px solid var(--border); border-radius: 6px; background: var(--muted); color: var(--fg-2); font-size: 12px; font-weight: 500; white-space: nowrap; }
.tag.ok { background: #f0fdf4; border-color: #bbf7d0; color: #15803d; }
.tag.no { background: #fef2f2; border-color: #fecaca; color: #b91c1c; }
.tag.warn { background: #fffbeb; border-color: #fde68a; color: #b45309; }

/* Hoy */
.meals { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; }
.meals + .card { margin-top: 20px; }
details.more { margin-top: 20px; }
details.more > summary { cursor: pointer; list-style: none; }
details.more > summary::-webkit-details-marker { display: none; }
details.more > summary::after { content: "Ver"; align-self: center; color: var(--primary); font-size: 13.5px; font-weight: 500; }
details.more[open] > summary::after { content: "Ocultar"; }
details.more[open] > .scroll { border-top: 1px solid var(--border); }
.meal { padding: 24px; display: grid; gap: 16px; align-content: start; }
.meal-head { display: flex; justify-content: space-between; align-items: baseline; }
.meal-head h2 { margin: 0; font-size: 14px; font-weight: 500; color: var(--muted-fg); }
.big { font-size: 36px; font-weight: 700; line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; color: var(--fg); margin-bottom: 4px; }
.meal dl { margin: 0; display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; font-size: 14px; }
.meal dt { color: var(--muted-fg); }
.meal dd { margin: 0; text-align: right; font-weight: 500; font-variant-numeric: tabular-nums; }
.meal .sub { border-top: 1px solid var(--border); padding-top: 12px; }

/* Informes */
.presets { margin-right: 4px; align-self: flex-end; padding-bottom: 2px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 20px; }
.kpi { display: grid; gap: 4px; align-content: start; padding: 18px 20px; background: var(--card); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow-sm); }
.kpi-label { font-size: 13px; font-weight: 500; color: var(--muted-fg); }
.kpi-value { font-size: 28px; font-weight: 600; line-height: 1.15; letter-spacing: -.02em; color: var(--fg); }
.kpi-sub { font-size: 12.5px; color: var(--muted-fg); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; }
.key { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--fg-2); }
.swatch { display: inline-block; flex: none; width: 10px; height: 10px; border-radius: 3px; }
.chart { padding: 0 8px 12px; border-top: 1px solid var(--border); }
.chart svg { display: block; overflow: visible; }
.chart .grid { stroke: #f0f0f2; stroke-width: 1; }
.chart .base { stroke: #d4d4d8; stroke-width: 1; }
.chart .tick { fill: var(--muted-fg); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.chart .peak { fill: var(--fg-2); font-size: 12px; font-weight: 600; }
.chart .hit { fill: transparent; }
.chart .hit:hover { fill: #f4f4f5; }
.chart .marks { pointer-events: none; }
.insights { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin: 20px 0; align-items: start; }
.insights .card + .card { margin-top: 0; }
@media (max-width: 900px) { .insights { grid-template-columns: minmax(0, 1fr); } }
.bars-box { border-top: 1px solid var(--border); }
.bars { display: grid; gap: 14px; padding: 18px 24px 22px; }
.bar-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "label value" "track track"; gap: 6px 12px; align-items: baseline; }
.bar-label { grid-area: label; display: flex; align-items: baseline; gap: 8px; min-width: 0; font-size: 14px; }
.bar-label .swatch { align-self: center; }
.bar-label .muted { font-size: 12.5px; }
.bar-value { grid-area: value; font-weight: 600; font-variant-numeric: tabular-nums; }
.bar-track { grid-area: track; height: 8px; border-radius: 4px; background: var(--muted); overflow: hidden; }
.bar-fill { display: block; height: 100%; border-radius: 4px; background: var(--primary); }
.slots-box { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); border-top: 1px solid var(--border); }
.slots-box > .empty { grid-column: 1 / -1; }
.slots-meal { display: grid; gap: 10px; align-content: start; padding: 18px 24px 20px; border-right: 1px solid var(--border); }
.slots-meal:last-child { border-right: none; }
.slots-head { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 2px 8px; font-size: 14px; }
.slots-head strong { font-weight: 600; }
.slots-head .muted { grid-column: 2; font-size: 13px; }
.slots-plot { display: grid; gap: 6px; width: min(100%, calc(var(--slots) * 24px)); }
.slots { display: flex; align-items: flex-end; gap: 2px; height: 80px; }
.slot { flex: 1 1 0; min-width: 0; height: 100%; display: flex; align-items: flex-end; border-radius: 4px 4px 0 0; }
.slot:hover { background: var(--muted); }
.slot-fill { display: block; width: 100%; border-radius: 4px 4px 0 0; }
.slots-axis { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--muted-fg); font-variant-numeric: tabular-nums; }
td.heat { background: rgba(56, 106, 32, calc(var(--heat) * .22)); }
tr.day-start td { border-top: 2px solid var(--border); }
td.day-cell { vertical-align: top; background: #fcfcfc; border-right: 1px solid var(--border); white-space: nowrap; }
td.day-cell strong { display: block; font-weight: 600; }
td.day-cell .muted { font-size: 12.5px; }
td.meal-cell { padding-left: 16px; }
.tip { position: fixed; z-index: 10; max-width: 260px; padding: 8px 10px; border-radius: 8px; background: var(--fg); color: #fff; font-size: 12.5px; line-height: 1.5; white-space: pre-line; pointer-events: none; box-shadow: var(--shadow-lg); }

/* Puestos de escaneo */
.device-link { display: grid; gap: 14px; padding: 20px 24px; border-top: 1px solid var(--border); background: var(--primary-soft); animation: fade .25s ease-out; }
.device-link p { margin: 0; color: var(--fg-2); }
.device-link-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.device-link-head strong { font-size: 15px; font-weight: 600; }
.link-row { display: flex; gap: 8px; }
.link-field { flex: 1; font-size: 13px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--fg-2); }
.device-code { display: flex; align-items: baseline; gap: 12px; }
.device-code b { font-size: 30px; font-weight: 600; letter-spacing: .12em; font-variant-numeric: tabular-nums; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }
@keyframes fade { from { opacity: 0; } }

/* Reglas del comedor */
.title-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin: 40px 0 16px; }
.title-row h2 { margin: 0; font-size: 18px; letter-spacing: -.02em; }
.title-row p { margin: 4px 0 0; font-size: 13.5px; }
.rules { display: grid; gap: 20px; }
.rules .field { font-size: 13px; }
.rows { display: grid; }
.meal-row { display: grid; grid-template-columns: minmax(0, 1fr) 140px 140px 36px; gap: 12px; align-items: end; padding: 14px 24px; border-bottom: 1px solid var(--border); }
.meal-row:last-child { border-bottom: none; }
.groups-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-top: 8px; }
.groups-head h3 { margin: 0; font-size: 15px; }
.groups-head p { margin: 4px 0 0; color: var(--muted-fg); font-size: 13.5px; }
.group-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(180px, 280px) 36px; gap: 12px; align-items: end; padding: 18px 24px; border-bottom: 1px solid var(--border); }
.group-head input[type=text] { font-size: 15px; font-weight: 600; }
.group.summary { display: grid; gap: 12px; padding: 18px 24px; }
.summary-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.summary-head h4 { margin: 0 0 2px; font-size: 15px; font-weight: 600; }
.summary-head .muted { font-size: 13px; }
.summary-facts { margin: 0; display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 6px 16px; font-size: 14px; }
.summary-facts dt { color: var(--muted-fg); }
.summary-facts dd { margin: 0; }
.group.summary .preview { width: 100%; margin-top: 0; }
.group-foot { display: flex; justify-content: flex-end; padding: 14px 24px; border-top: 1px solid var(--border); }
.who-row, .meal-rule { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 16px; padding: 16px 24px; align-items: start; }
td strong { font-weight: 500; }
.who-row { border-bottom: 1px solid var(--border); align-items: start; background: #fcfcfc; }
.row-label { font-size: 13px; font-weight: 500; color: var(--fg); padding-top: 8px; }
.who-pick { display: grid; gap: 8px; justify-items: start; }
.who-sentence { margin: 0; padding-top: 7px; color: var(--fg-2); }
.cond { display: grid; gap: 10px; width: min(640px, 100%); padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px; background: var(--card); }
.cond-head { display: grid; grid-template-columns: minmax(0, 1fr) auto 36px; gap: 8px; align-items: center; }
.cond-head select { min-width: 0; }
.cond-head select + select { min-width: 180px; }
.and { padding-left: 14px; font-size: 12px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--muted-fg); }
.preview { display: grid; gap: 12px; width: min(640px, 100%); margin-top: 4px; padding-top: 12px; border-top: 1px dashed var(--border); font-size: 14px; }
.preview-line { display: flex; align-items: baseline; gap: 4px 14px; flex-wrap: wrap; }
.preview-count b { font-size: 18px; font-weight: 600; }
.preview-error { color: var(--danger); }
.preview-list { display: grid; gap: 12px; }
.preview-list input[type=search] { width: min(320px, 100%); }
.preview-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 16px; }
.preview-cols h4 { margin: 0 0 6px; font-size: 13px; font-weight: 600; }
.preview-cols ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; max-height: 280px; overflow: auto; font-size: 13.5px; }
.preview-cols li { display: grid; }
.preview-cols li .muted { font-size: 12.5px; }
.meal-rule + .meal-rule { border-top: 1px solid var(--border); }
.meal-name { display: grid; gap: 2px; padding-top: 6px; align-content: start; }
.meal-name strong { font-size: 14px; font-weight: 500; }
.meal-name span { font-size: 12.5px; font-variant-numeric: tabular-nums; }
.meal-rule.off .meal-name strong { color: var(--muted-fg); }
.meal-how { display: grid; gap: 10px; justify-items: start; }
.how-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.how-row select { min-width: 180px; }
.money { display: inline-flex; align-items: center; gap: 8px; color: var(--muted-fg); font-weight: 500; }
.money input { width: 96px; text-align: right; font-variant-numeric: tabular-nums; }
.options { display: grid; gap: 8px; width: min(520px, 100%); }
.option-row { display: grid; grid-template-columns: minmax(0, 1fr) auto 36px; gap: 8px; align-items: center; }

/* Toggles, as shadcn's outline Toggle */
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { height: 32px; padding: 0 12px; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--border); border-radius: 8px; background: var(--card); color: var(--fg-2); font-size: 13px; font-weight: 500; box-shadow: var(--shadow-xs); cursor: pointer; transition: background .12s, border-color .12s, color .12s; }
.chip:hover { background: var(--muted); }
.chip[aria-pressed="true"] { background: var(--primary-soft); border-color: rgba(56, 106, 32, .45); color: var(--primary); }
.chip[aria-pressed="true"]::before { content: ""; width: 12px; height: 12px; background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5 10 17.5 19 7'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5 10 17.5 19 7'/%3E%3C/svg%3E") center / contain no-repeat; }

/* Checkboxes, as shadcn's Switch */
.check { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 500; color: var(--fg); cursor: pointer; }
.check input { appearance: none; flex: none; width: 36px; height: 20px; margin: 0; border-radius: 999px; cursor: pointer;
  background: #e4e4e7 radial-gradient(circle, #fff 7px, transparent 7.5px) no-repeat 0 0 / 20px 20px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .04); transition: background-color .15s, background-position .15s; }
.check input:checked { background-color: var(--primary); background-position: 16px 0; }
.check input:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--ring); }
.socialo { width: min(640px, 100%); }
.socialo.on { border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; background: #fcfcfc; }
.socialo-detail { display: grid; gap: 12px; margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--border); }
.inline { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14px; font-weight: 500; color: var(--fg); }

/* Saving */
.save-bar { position: sticky; bottom: 20px; z-index: 2; margin: 20px 0 0 auto; display: flex; align-items: center; gap: 16px;
  padding: 10px 10px 10px 18px; width: fit-content; max-width: 100%; border: 1px solid var(--border); border-radius: 12px;
  background: var(--card); box-shadow: var(--shadow-lg); animation: rise .2s cubic-bezier(.16, 1, .3, 1); }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } }
.errors { margin: 16px 0 0; padding: 12px 16px 12px 36px; border: 1px solid #fecaca; border-radius: 10px; background: #fef2f2; color: #b91c1c; font-size: 14px; line-height: 1.55; }
.errors.ok { border-color: #bbf7d0; background: #f0fdf4; color: #15803d; list-style: none; padding-left: 16px; }
.errors.warn { border-color: #fde68a; background: #fffbeb; color: #92400e; }

/* Personas */
#ppl-errors { margin: 0 0 16px; }
.count { margin: 0; padding: 12px 24px; border-bottom: 1px solid var(--border); font-size: 13px; }
tr.person { cursor: pointer; }
tr.person:focus-visible td { background: #f4f4f5; outline: none; }
tr.person[aria-expanded="true"] td { background: #fafafa; border-bottom-color: transparent; }
tr.detail td, tr.detail:hover td { background: #fafafa; padding-top: 4px; }
.plan { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px 24px; }
.plan-meal ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; }
.plan-meal li { display: grid; grid-template-columns: auto 1fr; gap: 2px 8px; align-items: center; font-size: 13.5px; }
.plan-days { grid-column: 1 / -1; color: var(--muted-fg); font-size: 12.5px; }
.plan-text { line-height: 1.4; white-space: pre-line; }

@media (max-width: 720px) {
  .top-inner { padding: 0 12px; gap: 10px; }
  .brand > div { display: none; }
  .page { padding: 24px 12px 64px; }
  .card-head, .device-link { padding-left: 16px; padding-right: 16px; }
  th:first-child, td:first-child { padding-left: 16px; }
  th:last-child, td:last-child { padding-right: 16px; }
  .meal-row { grid-template-columns: 1fr 1fr 36px; padding: 14px 16px; }
  .meal-row > .field:first-child { grid-column: 1 / -1; }
  .group-head { grid-template-columns: minmax(0, 1fr) 36px; padding: 16px; }
  .group.summary, .group-foot { padding: 16px; }
  .summary-facts { grid-template-columns: 1fr; gap: 2px; }
  .summary-facts dd + dt { margin-top: 8px; }
  .group-head > .field:nth-child(2) { grid-row: 2; grid-column: 1 / -1; }
  .who-row, .meal-rule { grid-template-columns: 1fr; gap: 8px; padding: 14px 16px; }
  .row-label, .meal-name { padding-top: 0; }
  .who-pick select { min-width: 0; width: 100%; }
}
