
/* Dr. Diyetoloq brand (Zeytun): olive, honey, paper. Lora for headings, Rubik for everything else. */
:root{
  --olive:#566B3F; --olive-ink:#3F5130; --honey:#B8873A; --honey-soft:#DCC39A;
  --paper:#FBFBF7; --card:#FFFFFF; --wash:#F0F2E8; --rule:#E2E5DA;
  --ink:#22261E; --ink-soft:#626858; --ink-faint:#9AA08F;
 
  --good:#566B3F; --warn:#B8873A; --alert:#A4573A;
  --on-olive:#FFFFFF;
  /* --warn is for fills, borders and dots; amber text uses --warn-ink (4.5:1 or more on card, paper and wash). */
  --warn-ink:#8A6424;
  /* the selected segment of a .subtabs track */
  --seg-on:#FFFFFF; --seg-on-ink:#22261E; --seg-on-edge:0 1px 2px rgba(0,0,0,.08);
  --f-display:"Lora", Georgia, "Times New Roman", serif;
  --f-body:"Rubik", system-ui, -apple-system, "Segoe UI", sans-serif;
  --r:16px;
}
@media (prefers-color-scheme: dark){:root:not([data-theme="light"]){
  --olive:#8FA672; --olive-ink:#B5C79C; --honey:#D2A55C; --honey-soft:#6E5A36;
  --paper:#171A14; --card:#20241C; --wash:#262B21; --rule:#33392C;
  --ink:#ECEEE5; --ink-soft:#AEB4A2; --ink-faint:#737A69;
 
  --good:#8FA672; --warn:#D2A55C; --alert:#D98B6A; --on-olive:#13160F;
  --warn-ink:#D2A55C; --seg-on:#3A4230; --seg-on-ink:#ECEEE5; --seg-on-edge:inset 0 0 0 1px #8FA672;
  color-scheme:dark}}
:root[data-theme="dark"]{
  --olive:#8FA672; --olive-ink:#B5C79C; --honey:#D2A55C; --honey-soft:#6E5A36;
  --paper:#171A14; --card:#20241C; --wash:#262B21; --rule:#33392C;
  --ink:#ECEEE5; --ink-soft:#AEB4A2; --ink-faint:#737A69;
 
  --good:#8FA672; --warn:#D2A55C; --alert:#D98B6A; --on-olive:#13160F;
  --warn-ink:#D2A55C; --seg-on:#3A4230; --seg-on-ink:#ECEEE5; --seg-on-edge:inset 0 0 0 1px #8FA672;
  color-scheme:dark}

*{box-sizing:border-box}
html,body,#root{height:100%}
body{margin:0;background:var(--paper);color:var(--ink);font-family:var(--f-body);font-size:15px;line-height:1.45;-webkit-font-smoothing:antialiased}
button{font:inherit;color:inherit;cursor:pointer;border:0;background:none;padding:0}
button:focus-visible,input:focus-visible,textarea:focus-visible{outline:2px solid var(--honey);outline-offset:2px}
.num{font-variant-numeric:tabular-nums}

/* app chrome */
.screen{flex:1;overflow-y:auto;overflow-x:hidden;padding:18px 16px 24px;display:flex;flex-direction:column;gap:16px}
.screen>*{flex-shrink:0}
.screen[hidden]{display:none!important}
/* margin-top:auto keeps the bar at the bottom even while the screen above is only a spinner. */
.tabbar{display:flex;flex-shrink:0;margin-top:auto;border-top:1px solid var(--rule);background:var(--card);padding-bottom:env(safe-area-inset-bottom,0px)}
.tabbar button{flex:1;padding:10px 4px 12px;display:flex;flex-direction:column;align-items:center;gap:3px;font-size:11.5px;color:var(--ink-soft)}
.tabbar button[aria-current="true"]{color:var(--olive)}
.tabbar svg{width:22px;height:22px}

.top{display:flex;align-items:center;justify-content:space-between;gap:8px}
.wordmark{font-family:var(--f-body);font-weight:500;letter-spacing:-.02em;font-size:18px}
.wordmark i{font-style:normal;color:var(--honey)}
.chip{display:inline-flex;align-items:center;gap:6px;padding:5px 10px;border-radius:999px;background:var(--wash);font-size:13px;font-weight:500;white-space:nowrap}
.chip svg{width:14px;height:14px}
h1,h2{font-family:var(--f-display);font-weight:500;margin:0;text-wrap:balance}
h1{font-size:24px;line-height:1.2}
h2{font-size:18px}
.eyebrow{font-size:11.5px;letter-spacing:.08em;text-transform:uppercase;color:var(--ink-soft);font-weight:500}
.muted{color:var(--ink-soft)}
.small{font-size:13px}
.card{background:var(--card);border:1px solid var(--rule);border-radius:var(--r);padding:14px}
.row{display:flex;align-items:center;gap:12px}
.grow{flex:1;min-width:0}

/* hero: ring + branch */

/* note from her */
.hero{display:grid;grid-template-columns:92px 1fr;gap:14px;align-items:center}
.ring{position:relative;width:92px;height:92px}
.ring svg{width:92px;height:92px;transform:rotate(-90deg)}
.ring .lbl{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;line-height:1.1}
.ring .lbl b{font-size:22px;font-weight:600}
.ring .lbl span{font-size:11px;color:var(--ink-soft)}
.note{background:var(--wash);border-radius:var(--r);padding:14px 16px;display:flex;gap:12px;align-items:flex-start}
.avatar{flex:none;width:36px;height:36px;border-radius:50%;background:var(--olive);color:var(--on-olive);display:flex;align-items:center;justify-content:center;font-weight:500;letter-spacing:-.02em}
.avatar i{font-style:normal;color:var(--honey-soft)}
.note q{font-family:var(--f-display);font-style:italic;font-size:16px;quotes:none;display:block}
.note .by{font-size:12.5px;color:var(--ink-soft);margin-top:4px}

/* meals */
.meals{display:flex;flex-direction:column;gap:8px}
.meal{display:flex;align-items:center;gap:12px;padding:10px 12px 10px 10px;background:var(--card);border:1px solid var(--rule);border-radius:var(--r);text-align:left;width:100%}
.meal .thumb{flex:none;width:52px;height:52px;border-radius:12px;background:var(--wash);display:flex;align-items:center;justify-content:center;overflow:hidden;position:relative}
.meal .thumb img{width:100%;height:100%;object-fit:cover}
.meal .thumb svg{width:24px;height:24px;color:var(--olive)}
.meal.next .thumb{background:var(--olive);color:var(--on-olive)}
.meal.next .thumb svg{color:var(--on-olive)}
.meal .t{font-weight:500}
.meal .s{font-size:13px;color:var(--ink-soft);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tag{font-size:12px;font-weight:500;padding:3px 8px;border-radius:999px;white-space:nowrap}
.tag.ok{background:var(--olive);color:var(--on-olive)}
.tag.swap{background:var(--honey-soft);color:var(--ink)}
.tag.skip{background:var(--wash);color:var(--ink-soft)}
.heart{position:absolute;right:2px;bottom:2px;background:var(--card);color:var(--alert);border-radius:999px;font-size:11px;line-height:1;padding:3px 4px}

/* trackers */
.track{display:flex;flex-direction:column;gap:10px}
/* 40×44 tap areas without a gap (the icon is narrower): 8 glasses still fit one row at 390px */
.glasses{display:flex;flex-wrap:wrap}
.glass{min-width:40px;height:44px;display:flex;align-items:center;justify-content:center;color:var(--rule)}
.glass svg{width:30px;height:38px}
.glass.on{color:var(--olive)}
.moods{display:flex;justify-content:space-between;gap:6px}
.mood{width:44px;height:44px;border-radius:50%;display:flex;align-items:center;justify-content:center;color:var(--ink-faint);border:1px solid var(--rule)}
.mood[aria-pressed="true"]{background:var(--olive);color:var(--on-olive);border-color:var(--olive)}
.mood svg{width:26px;height:26px}

/* weeks */
.week{display:flex;align-items:center;gap:12px}
.week .dots{display:flex;gap:4px;margin-top:6px}
.dot{width:12px;height:12px;border-radius:50%;border:1.5px solid var(--rule)}
.dot.a{background:var(--olive);border-color:var(--olive)}
.dot.b{background:var(--honey);border-color:var(--honey)}
.dot.c{background:var(--honey-soft);border-color:var(--honey-soft)}
.dot.today{border-color:var(--olive);border-style:dashed}
.week.locked{opacity:.7}
.lock{width:40px;height:40px;border-radius:12px;background:var(--wash);display:flex;align-items:center;justify-content:center;color:var(--ink-soft);flex:none}
.lock svg{width:20px;height:20px}
.weekbadge{width:40px;height:40px;border-radius:12px;background:var(--olive);color:var(--on-olive);display:flex;align-items:center;justify-content:center;font-weight:600;flex:none}
.weekbadge.cur{background:var(--honey)}

/* photos grid */
.grid{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}
.ph{position:relative;aspect-ratio:1;border-radius:10px;overflow:hidden;background:var(--wash);max-width:100%}
.ph img{width:100%;height:100%;object-fit:cover;display:block}
.ph .r{position:absolute;left:4px;bottom:4px;background:var(--card);border-radius:999px;font-size:11px;padding:2px 6px;color:var(--alert);font-weight:500}
.dayhead{display:flex;justify-content:space-between;align-items:baseline;margin-top:4px}

/* progress */
.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.stat{background:var(--card);border:1px solid var(--rule);border-radius:14px;padding:10px;text-align:center}
.stat b{display:block;font-size:20px;font-weight:600}
.stat span{font-size:12px;color:var(--ink-soft)}
.badges{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.badge{display:flex;flex-direction:column;align-items:center;gap:6px;text-align:center;font-size:12px;padding:10px 4px;border-radius:14px;background:var(--wash)}
.badge .b{width:42px;height:42px;border-radius:50%;background:var(--olive);color:var(--on-olive);display:flex;align-items:center;justify-content:center}
.badge.off{opacity:.45}
.badge.off .b{background:var(--ink-faint)}
.badge svg{width:22px;height:22px}

/* buttons */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:13px 16px;border-radius:14px;font-weight:500;background:var(--olive);color:var(--on-olive);width:100%}
.btn.ghost{background:var(--wash);color:var(--ink)}
.btn svg{width:20px;height:20px}
.btn[disabled]{opacity:.45;cursor:not-allowed}
/* text-sized links with a 40px tap area; the negative margin keeps the layout as tight as plain text */
.link{color:var(--olive);font-weight:500;font-size:13.5px;display:inline-flex;align-items:center;justify-content:center;min-height:40px;min-width:40px;padding:0 12px;margin:-10px -12px}

/* sheet */
.scrim{position:fixed;inset:0;background:rgba(20,22,16,.45);display:flex;align-items:flex-end;z-index:20}
.sheet{background:var(--paper);width:100%;max-height:92%;overflow-y:auto;border-radius:24px 24px 0 0;padding:10px 16px 20px;display:flex;flex-direction:column;gap:14px;animation:up .25s ease}
@keyframes up{from{transform:translateY(30px)}to{transform:none}}
.sheet>*{flex-shrink:0}
.grab{width:40px;height:4px;border-radius:2px;background:var(--rule);margin:0 auto 4px}
.items{margin:0;padding:0;list-style:none;display:flex;flex-direction:column;gap:6px}
.items li{display:flex;justify-content:space-between;gap:10px;padding-bottom:6px;border-bottom:1px solid var(--rule)}
.items li:last-child{border-bottom:0}
.items .alt{color:var(--ink-soft);font-style:italic;justify-content:center;border:0}
.preview{border-radius:var(--r);overflow:hidden;aspect-ratio:4/3;background:var(--wash);display:flex;align-items:center;justify-content:center;max-width:100%}
.preview img{width:100%;height:100%;object-fit:cover}
.seg{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}
.seg button{padding:10px 4px;border-radius:12px;border:1px solid var(--rule);background:var(--card);font-size:13px;font-weight:500}
.seg button[aria-pressed="true"]{background:var(--olive);color:var(--on-olive);border-color:var(--olive)}
.field{width:100%;padding:11px 12px;border-radius:12px;border:1px solid var(--rule);background:var(--card);font:inherit;color:var(--ink)}
.two{display:grid;grid-template-columns:1fr 1fr;gap:8px}

/* celebration */
.celebrate{position:fixed;inset:0;z-index:30;display:flex;align-items:center;justify-content:center;background:rgba(20,22,16,.5)}
.cbox{background:var(--paper);border-radius:24px;padding:24px 20px;margin:0 24px;text-align:center;display:flex;flex-direction:column;gap:10px;align-items:center;animation:pop .3s cubic-bezier(.2,.8,.2,1)}
.cbox>svg{width:84px;height:84px}
.cbox .moods{width:100%}
@keyframes pop{from{transform:scale(.85);opacity:0}to{transform:none;opacity:1}}
.leafgrow{transform-origin:50% 90%;animation:grow .6s .1s both cubic-bezier(.2,1.1,.4,1)}
@keyframes grow{from{transform:scale(0) rotate(-30deg)}to{transform:none}}
.toast{position:fixed;left:16px;right:16px;bottom:78px;z-index:40;background:var(--ink);color:var(--paper);padding:11px 14px;border-radius:12px;font-size:13.5px;animation:up .2s ease}

/* dietitian */
.kpis{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.kpi{background:var(--card);border:1px solid var(--rule);border-radius:14px;padding:10px 12px}
.kpi b{font-size:22px;font-weight:600;display:block}
.kpi span{font-size:12px;color:var(--ink-soft)}
.kpi.warn b{color:var(--alert)}
.pt{display:flex;align-items:center;gap:12px;padding:12px;background:var(--card);border:1px solid var(--rule);border-radius:var(--r);width:100%;text-align:left}
.pt.flag{border-left:4px solid var(--alert)}
.pt.mild{border-left:4px solid var(--warn)}
.pav{flex:none;width:38px;height:38px;border-radius:50%;background:var(--wash);display:flex;align-items:center;justify-content:center;font-weight:500;font-size:13px;color:var(--olive-ink)}
.pt .n{font-weight:500}
.pt .f{font-size:13px;color:var(--alert)}
.pt.mild .f{color:var(--warn-ink)}
.pt .ok{font-size:13px;color:var(--ink-soft)}
.wa{flex:none;min-height:40px;padding:0 14px;border-radius:999px;background:var(--wash);font-size:14px;font-weight:500;color:var(--ink);display:inline-flex;gap:6px;align-items:center;text-decoration:none}
.wa:active,.chip.btn-chip:active{opacity:.7}
.wa svg{width:16px;height:16px;color:var(--olive)}
.feed{display:flex;flex-direction:column;gap:12px}
.post{background:var(--card);border:1px solid var(--rule);border-radius:var(--r);overflow:hidden}
.post .ph2{aspect-ratio:4/3;background:var(--wash);max-width:100%}
.post .ph2 img{width:100%;height:100%;object-fit:cover;display:block}
.post .body{padding:12px 14px;display:flex;flex-direction:column;gap:10px}
.planned{font-size:13px;background:var(--wash);border-radius:10px;padding:8px 10px;color:var(--ink-soft)}
.reacts{display:flex;gap:6px;flex-wrap:wrap}
.reacts button{min-height:40px;min-width:40px;padding:7px 12px;border-radius:999px;border:1px solid var(--rule);font-size:13px;font-weight:500;background:var(--card)}
.reacts button[aria-pressed="true"]{background:var(--olive);color:var(--on-olive);border-color:var(--olive)}
.section-h{display:flex;justify-content:space-between;align-items:baseline}
.bar{height:6px;border-radius:3px;background:var(--wash);overflow:hidden;width:70px}
.bar i{display:block;height:100%;background:var(--olive)}
.dl{display:inline-flex;align-items:center;gap:6px;min-height:40px;padding:6px 12px;border-radius:999px;background:var(--wash);font-size:13px;font-weight:500;color:var(--olive-ink)}
.dl svg{width:16px;height:16px}
a.dl{text-decoration:none}
.opt{display:flex;align-items:center;gap:12px;padding:12px;border:1px solid var(--rule);border-radius:14px;background:var(--card);width:100%;text-align:left}
.opt[aria-pressed="true"]{border-color:var(--olive);box-shadow:inset 0 0 0 1px var(--olive)}
.opt .ic{flex:none;width:38px;height:38px;border-radius:10px;background:var(--wash);display:flex;align-items:center;justify-content:center;color:var(--olive)}
.opt .ic svg{width:20px;height:20px}
.fmt{font-size:11px;font-weight:600;letter-spacing:.06em;color:var(--ink-soft);border:1px solid var(--rule);border-radius:6px;padding:2px 6px}
.paper{background:#FBFBF7;color:#22261E;border-radius:12px;padding:16px 16px 14px;border:1px solid var(--rule);box-shadow:0 10px 24px -16px rgba(0,0,0,.35);font-size:12.5px;display:flex;flex-direction:column;gap:8px}
.paper .ph-h{display:flex;justify-content:space-between;align-items:baseline;border-bottom:1px solid #E2E5DA;padding-bottom:8px}
.paper .wm{font-weight:500;letter-spacing:-.02em;font-size:15px}
.paper .wm i{font-style:normal;color:#B8873A}
.paper h3{font-family:var(--f-display);font-weight:500;font-size:13.5px;margin:4px 0 0;color:#566B3F}
.paper ul{margin:0;padding-left:16px}
.paper .qeyd{background:#F0F2E8;border-radius:8px;padding:8px 10px}
.paper .day{font-family:var(--f-display);font-size:14px;font-weight:500;margin-top:6px}
.back{align-self:flex-start;display:inline-flex;align-items:center;gap:4px;min-height:40px;padding:0 14px 0 8px;border-radius:999px;background:var(--wash);color:var(--ink);font-weight:500;font-size:14px;text-decoration:none}
.back:active{opacity:.7}
.back svg{width:20px;height:20px}
.prof{display:flex;align-items:center;gap:12px}
.prof .pav{width:56px;height:56px;font-size:18px}
.subtabs{display:flex;gap:4px;background:var(--wash);border-radius:12px;padding:4px;overflow-x:auto}
.subtabs button{flex:1;min-height:40px;padding:8px 6px;border-radius:9px;font-size:13px;font-weight:500;color:var(--ink-soft);white-space:nowrap}
.subtabs button[aria-pressed="true"]{background:var(--seg-on);color:var(--seg-on-ink);box-shadow:var(--seg-on-edge)}
.dayrow{display:flex;align-items:center;gap:10px;padding:10px 0;border-bottom:1px solid var(--rule)}
.dayrow:last-child{border-bottom:0}
/* a whole row that opens: the row itself is the 44px tap area */
.dayrow.tap{padding:0}
.dayrow.tap>button{min-height:44px}
.mini{display:flex;gap:4px}
.menurow{text-decoration:none;color:inherit;min-height:52px}
.menurow svg{width:20px;height:20px;flex-shrink:0;color:var(--olive-ink)}
.menurow span{white-space:nowrap}
.mini span{width:22px;height:22px;border-radius:6px;background:var(--wash);display:flex;align-items:center;justify-content:center;font-size:10px;color:var(--ink-soft)}
.mini .ok{background:var(--olive);color:var(--on-olive)}
.mini .swap{background:var(--honey-soft);color:var(--ink)}
.mini .skip{background:var(--card);border:1px solid var(--rule)}
.hbar{display:grid;grid-template-columns:92px 1fr 40px;align-items:center;gap:10px;font-size:13px}
.hbar .tr{height:10px;border-radius:5px;background:var(--wash);overflow:hidden}
.hbar .tr i{display:block;height:100%;border-radius:5px;background:var(--olive)}
.hbar .tr i.low{background:var(--honey)}
.kv{display:grid;grid-template-columns:auto 1fr;gap:6px 14px;font-size:13.5px}
.kv dt{color:var(--ink-soft)}
.kv dd{margin:0}
textarea.field{resize:vertical;min-height:70px}
.pt.click{cursor:pointer}
.empty{padding:24px;text-align:center;color:var(--ink-soft);font-size:14px}
/* folds a block open and closed without the layout jumping */
.collapse{display:grid;grid-template-rows:1fr;opacity:1;transition:grid-template-rows .28s ease,opacity .2s ease,margin-top .28s ease}
.collapse>*{overflow:hidden;min-height:0}
.collapse.closed{grid-template-rows:0fr;opacity:0;margin-top:-14px}
.preview img{animation:fade .25s ease}
@keyframes fade{from{opacity:0}to{opacity:1}}
@media (prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important}}

/* app shell */
.app{height:100%;max-width:480px;margin:0 auto;display:flex;flex-direction:column;background:var(--paper)}
.app .screen{padding-top:calc(18px + env(safe-area-inset-top,0px))}
.center{flex:1;display:flex;flex-direction:column;justify-content:center;gap:16px;padding:24px 20px}
.error{color:var(--alert);font-size:13.5px}
.load-error{display:flex;flex-direction:column;gap:12px}
.load-error p{margin:0}
.spinner{width:28px;height:28px;border-radius:50%;border:3px solid var(--wash);border-top-color:var(--olive);animation:spin .8s linear infinite;margin:40px auto}
@keyframes spin{to{transform:rotate(360deg)}}
.scrim .sheet{max-width:480px;margin:0 auto}
.staffbar{padding:calc(14px + env(safe-area-inset-top,0px)) 16px 0}
.app .staffbar + .screen{padding-top:12px}

/* admin panel (desktop) */
.admin{display:grid;grid-template-columns:232px minmax(0,1fr);min-height:100%;background:var(--paper)}
.admin-nav{border-right:1px solid var(--rule);padding:22px 12px;display:flex;flex-direction:column;gap:2px;position:sticky;top:0;height:100vh}
.admin-nav a{display:flex;gap:10px;align-items:center;padding:9px 10px;border-radius:10px;color:var(--ink-soft);text-decoration:none;font-weight:500;font-size:14px}
.admin-nav a svg{width:19px;height:19px}
.admin-nav a.active{background:var(--wash);color:var(--olive-ink)}
.admin-main{padding:28px 32px 48px;max-width:1200px;width:100%;display:flex;flex-direction:column;gap:18px;min-width:0}
.admin-main>.screen{overflow:visible;padding:0}
.stack{display:flex;flex-direction:column;gap:16px;min-width:0}
.three{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.menu-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:24px;align-items:start}
.split{display:grid;grid-template-columns:400px minmax(0,1fr);gap:24px;align-items:start}
.phone{width:390px;max-width:100%;height:780px;transform:translateZ(0);border:1px solid var(--rule);border-radius:28px;overflow:hidden;display:flex;flex-direction:column;background:var(--paper)}
.phone .staffbar{padding-top:14px}
.table-wrap{overflow-x:auto;border:1px solid var(--rule);border-radius:var(--r);background:var(--card)}
.tbl{width:100%;border-collapse:collapse;font-size:14px}
.tbl th{text-align:left;font-weight:500;color:var(--ink-soft);font-size:11.5px;letter-spacing:.06em;text-transform:uppercase;padding:10px 14px;border-bottom:1px solid var(--rule);white-space:nowrap}
.tbl td{padding:12px 14px;border-bottom:1px solid var(--rule);vertical-align:middle}
.tbl tr:last-child td{border-bottom:0}
.tbl tbody tr{cursor:pointer}
.tbl tbody tr:hover{background:var(--wash)}
.warn-text{color:var(--warn-ink)}
.alert-text{color:var(--alert)}
.weeknav{display:flex;align-items:center;justify-content:space-between;gap:10px}
.weeknav .back{min-width:44px;justify-content:center;font-size:20px;line-height:1}
.weeknav .back:disabled{opacity:.35}
.mday.past{opacity:.6}
.mday.today{border-color:var(--olive)}
.pt[aria-current="true"]{border-color:var(--olive);box-shadow:inset 0 0 0 1px var(--olive)}
.alert-text{color:var(--alert)}
@media (max-width:900px){
  .admin{grid-template-columns:1fr}
  .admin-nav{position:static;height:auto;flex-direction:row;flex-wrap:wrap;border-right:0;border-bottom:1px solid var(--rule);padding:12px}
  .admin-nav button{margin-top:0!important}
  .admin-main{padding:18px 16px 40px}
  .menu-grid,.split{grid-template-columns:1fr}
}

/* Menu card for the PDF: the same look as menu-template. Its colours are fixed (it is the printed
   paper, light in dark mode too), so it carries its own copy of the light brand palette. */
.mcard{--m-paper:#FBFBF7;--m-ink:#22261E;--m-soft:#626858;--m-olive:#566B3F;--m-honey:#B8873A;--m-honey-soft:#DCC39A;--m-rule:#E2E5DA;--m-wash:#F0F2E8;
  width:420px;background:var(--m-paper);color:var(--m-ink);font-family:var(--f-body);border-top:5px solid var(--m-olive);display:flex;flex-direction:column;line-height:1.45}
.mcard header{padding:26px 24px 8px;display:grid;gap:14px}
.mcard .brand-name{font-weight:500;letter-spacing:-.02em;font-size:20px;line-height:1.1}
.mcard i{font-style:normal;color:var(--m-honey)}
.mcard .brand-sub{font-size:12.5px;color:var(--m-soft);margin-top:3px}
.mcard .meta{display:grid;gap:6px;border-bottom:1px solid var(--m-rule);padding:6px 0 14px}
.mcard .meta .name{font-family:var(--f-display);font-size:29px;font-weight:500;line-height:1.1;margin:0}
.mcard .meta .when{font-size:15px;font-weight:600;color:var(--m-soft)}
.mcard .mmeals{padding:0 24px 16px}
.mcard .mmeal{display:grid;gap:8px;padding:15px 0;border-bottom:1px solid var(--m-rule)}
.mcard .mmeal:last-child{border-bottom:0}
.mcard .meal-head{display:flex;align-items:baseline;gap:10px}
.mcard .meal-name{font-family:var(--f-display);font-weight:600;font-size:16.5px;line-height:1.2}
.mcard .meal-time{font-size:12px;font-weight:600;color:var(--m-olive)}
.mcard .snack .meal-name{font-size:14.5px;color:var(--m-soft)}
.mcard .mitems{list-style:none;margin:0;padding:0;display:grid;gap:6px}
.mcard .mitems li{font-size:14px;padding-left:16px;position:relative}
.mcard .mitems li::before{content:"";position:absolute;left:2px;top:.62em;width:5px;height:5px;border-radius:50%;background:var(--m-honey)}
.mcard .snack .mitems li::before{background:var(--m-honey-soft)}
.mcard .qty{color:var(--m-soft)}
.mcard .mitems .or{padding-left:0;font-size:11px;letter-spacing:.12em;text-transform:uppercase;color:var(--m-soft)}
.mcard .mitems .or::before{display:none}
.mcard .mnotes{margin:4px 24px 24px;padding:14px 16px;background:var(--m-wash);border-radius:4px;display:grid;gap:6px}
.mcard .mnotes .k{font-size:9.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--m-honey);font-weight:600}
.mcard .mnotes ul{margin:0;padding:0;list-style:none;display:grid;gap:4px}
.mcard .mnotes li{font-size:13px}

/* No visible scrollbars: the app scrolls by touch and wheel, the bar only adds noise. Wide tables keep theirs. */
*{scrollbar-width:none}
*::-webkit-scrollbar{display:none}
.table-wrap{scrollbar-width:thin}
.table-wrap::-webkit-scrollbar{display:block;height:8px}

/* motion: calm and short. Everything here is switched off by the prefers-reduced-motion rule above. */
html,body{overscroll-behavior:none}
.screen{overscroll-behavior-y:contain;-webkit-overflow-scrolling:touch}
a,button,label{-webkit-tap-highlight-color:transparent}
button,a,.field,.mini span,.tabbar svg{transition:background-color .2s ease,color .2s ease,border-color .2s ease,box-shadow .2s ease,opacity .15s ease,transform .15s ease}
button:not([disabled]):active,a:active{opacity:.75}
.btn:not([disabled]):active,.seg button:active{transform:scale(.98)}
/* new content fades in instead of popping, e.g. after the spinner or when a day opens */
.screen>*,.track{animation:fade .22s ease both}
/* a quick load never flashes the spinner */
.spinner{animation:spin .8s linear infinite,fade .2s .3s both}
.scrim{animation:fade .2s ease}
.sheet{animation:sheet-in .3s cubic-bezier(.2,.8,.2,1)}
.scrim.closing{animation:fade-out .2s ease forwards}
.scrim.closing .sheet{animation:sheet-out .2s ease forwards}
@keyframes sheet-in{from{transform:translateY(100%)}to{transform:none}}
@keyframes sheet-out{to{transform:translateY(100%)}}
@keyframes fade-out{to{opacity:0}}
.celebrate{animation:fade .2s ease}
/* day history: photo thumbnails open full size */
.hthumb{width:56px;height:56px;border-radius:10px;background:var(--wash);flex-shrink:0;overflow:hidden;display:block}
.hthumb img{width:100%;height:100%;object-fit:cover;display:block}
.scrim.zoom{align-items:center;justify-content:center;padding:16px;cursor:zoom-out}
.scrim.zoom img{max-width:100%;max-height:100%;border-radius:12px;object-fit:contain}
.btn[aria-disabled="true"]{opacity:.45;pointer-events:none}
.quote{margin:0;padding:2px 0 2px 14px;border-left:3px solid var(--honey);font-family:var(--f-display);font-style:italic;font-size:17px;line-height:1.45;color:var(--ink)}
