/* Meal check screen: sized for a shared tablet held in one hand, with large tap targets. */
.meal-controls{display:flex;flex-wrap:wrap;align-items:flex-end;gap:14px 18px}.meal-controls .field{display:grid;gap:6px;min-width:0}.meal-controls label{font-size:var(--font-sm);color:var(--muted);font-weight:600}.meal-controls select{min-width:220px}
/* 上部の「‹」「›」「今日」と日付欄は「最新に更新」と同じ高さ・文字の大きさ（PC 34px、タッチ端末とスマホ 44px）にそろえる（v0.13.48）。
   矢印は細くならないよう高さと同じ幅の正方形にし、記号だけ少し大きく見せる。 */
.meal-date{display:flex;gap:6px;align-items:stretch}.meal-date button{white-space:nowrap}
.meal-date [data-meal-action=prev],.meal-date [data-meal-action=next]{min-width:44px;padding-left:0;padding-right:0;font-size:18px;line-height:1}
@media screen and (min-width:1001px){.meal-date [data-meal-action=prev],.meal-date [data-meal-action=next]{min-width:34px}}
@media screen and (min-width:1001px) and (pointer:coarse){.meal-date [data-meal-action=prev],.meal-date [data-meal-action=next]{min-width:44px}}
.meal-tabs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin-bottom:12px}.meal-tabs button{min-height:60px;font-size:18px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;border-width:2px}.meal-tabs button small{font-size:var(--font-xs);color:var(--muted);font-weight:500}.meal-tabs button[aria-selected=true]{background:var(--accent);border-color:var(--accent);color:white}.meal-tabs button[aria-selected=true] small{color:#e3f3f0}
.meal-summary{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px;padding:12px 16px;background:white;border:1px solid var(--line);border-radius:var(--radius-lg);margin-bottom:12px;font-size:var(--font-md)}.meal-summary button{min-height:48px}
.meal-list{list-style:none;margin:0;padding:0;display:grid;gap:8px}
.meal-row{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:12px;padding:12px 14px;background:white;border:1px solid var(--line);border-radius:var(--radius-lg)}.meal-row.away{background:var(--surface-grey)}
.meal-person{display:flex;align-items:center;gap:14px;min-width:0}.meal-person strong{font-size:18px;display:block}.meal-person small{color:var(--muted);font-size:var(--font-xs)}.meal-room{min-width:52px;text-align:center;font-weight:700;font-size:18px;color:var(--heading);background:var(--surface-tint);border-radius:var(--radius-md);padding:8px 6px}
/* The portrait fills the row's existing height so tiles and tap targets keep their size; unregistered residents show the initial on the same tint. */
.meal-row .meal-person{align-self:stretch}.meal-row .resident-photo{align-self:stretch;height:auto;min-height:60px;width:56px;border-radius:var(--radius-md)}.meal-row .resident-photo img{object-fit:cover;object-position:center 25%}.meal-row .resident-photo-fallback{font-size:22px}
.meal-flags{display:flex;flex-wrap:wrap;gap:4px 10px;margin-top:4px;align-items:center}.meal-flags .small{font-size:var(--font-xs);color:var(--muted)}
.meal-choices{display:flex;gap:8px}.meal-choice{min-width:76px;min-height:60px;font-size:17px;border-width:2px}
.meal-choice[aria-pressed=true].choice-喫食{background:#13786d;border-color:#13786d;color:white}.meal-choice[aria-pressed=true].choice-一部{background:#b7791f;border-color:#b7791f;color:white}.meal-choice[aria-pressed=true].choice-欠食{background:var(--red);border-color:var(--red);color:white}
@media(max-width:700px){.meal-row{grid-template-columns:minmax(0,1fr)}.meal-person{gap:10px}.meal-row .resident-photo{width:52px}.meal-room{min-width:46px}.meal-choices{display:grid;grid-template-columns:repeat(3,minmax(0,1fr))}.meal-choice{min-width:0}.meal-controls select{min-width:0;width:100%}.meal-controls .field{flex:1 1 100%}}

/* Printed room and meal sheets share the report document styles. */
.sheet-table{width:100%;border-collapse:collapse;table-layout:fixed}.sheet-table th,.sheet-table td{border:1px solid #777;padding:4px 5px;vertical-align:middle;text-align:left}.sheet-table th{background:#eee;font-weight:700}.sheet-table td small{display:block;font-size:7.5pt;color:#444}.sheet-table .num{text-align:center}.sheet-table .mark{text-align:center;font-size:13pt}.sheet-table .small-total{font-size:8pt}.sheet-table .vacant{color:#555}.sheet-table tfoot th,.sheet-table tfoot td{background:#f6f6f6}
.meal-document .sheet-table td{height:9mm}.room-document .sheet-table td{height:7.5mm}
/* Hospitalised residents: a diagonal line through each meal cell. */
.meal-document .sheet-table td.struck{background:linear-gradient(to top right,transparent calc(50% - .6px),#333 calc(50% - .6px),#333 calc(50% + .6px),transparent calc(50% + .6px));print-color-adjust:exact}
/* Larger facilities: shorter rows, then two or three columns side by side, so one facility stays on one A4 page. */
.meal-medium .sheet-table td{height:6.8mm;padding:1px 4px;font-size:9.5pt;line-height:1.3}.meal-medium .sheet-table td small{display:inline;margin-left:4px;font-size:7pt}.meal-medium .sheet-table .mark{font-size:12pt}
.meal-cols-2 .doc-head,.meal-cols-3 .doc-head{padding-bottom:5px;margin-bottom:6px}.meal-cols-2 .doc-top,.meal-cols-3 .doc-top{margin-bottom:4px}.meal-cols-2 .doc-title h1,.meal-cols-3 .doc-title h1{font-size:15pt}
.meal-columns{display:grid;gap:0 4mm;align-items:start}.meal-cols-2 .meal-columns{grid-template-columns:1fr 1fr}.meal-cols-3 .meal-columns{grid-template-columns:1fr 1fr 1fr}
.meal-columns .sheet-table th{padding:2px 1px;font-size:8pt;line-height:1.3;white-space:nowrap;text-align:center}.meal-columns .sheet-table td{padding:1px 3px;line-height:1.3;white-space:nowrap;overflow:hidden}.meal-columns .sheet-table td strong{font-weight:600}
.meal-compact .sheet-table td{height:6mm;font-size:9pt}.meal-compact .sheet-table .mark{font-size:11pt}
.meal-totals{display:flex;flex-wrap:wrap;gap:4px 14px;margin:5px 0 0;font-size:9pt}.meal-totals b{margin-right:4px}.meal-cols-2 .doc-footnote,.meal-cols-3 .doc-footnote{margin-top:5px;padding-top:4px}
@media print{.sheet-document{break-after:page}.sheet-document:last-child{break-after:auto}.sheet-table thead{display:table-header-group}.sheet-table tr{break-inside:avoid}.sheet-table th{print-color-adjust:exact}}
@media screen{.report-preview .sheet-document+.sheet-document{margin-top:12mm;padding-top:10mm;border-top:1px dashed #999}}

/* 食事不要の申請（v0.13.45）: 申請のある食事は、ボタンの前に大きな「不」を出し、行を薄い赤にする。記録が要るときのためにボタンは残す。 */
.meal-row.has-skip-request{background:#fff7f8;border-color:var(--red-border)}
.meal-skip-mark{min-width:76px;min-height:60px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;border:2px solid var(--red);border-radius:9px;background:var(--red-soft);color:var(--red-text);line-height:1.1}
.meal-skip-mark b{font-size:26px;font-weight:800}.meal-skip-mark small{font-size:var(--font-2xs);font-weight:700}
.meal-skip-count{color:var(--red-text);font-weight:700}
@media(max-width:700px){.meal-choices.has-skip{grid-template-columns:64px repeat(3,minmax(0,1fr))}.meal-skip-mark{min-width:0}}
/* 印刷シートの「不」。記録もあるときは記録の印の後ろに小さく添える。 */
.sheet-table .skip-mark{font-weight:700}.sheet-table td small.skip-mark,.meal-medium .sheet-table td small.skip-mark{display:inline;margin-left:1px;font-size:8pt;color:#000}
