/* DM Sans (SIL Open Font License, se fonts/OFL.txt) ligger i appen, så ingen skrifttype hentes fra Google. */
/* dm-sans-latin-ext-opsz-normal */
@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-display: swap;
  font-weight: 100 1000;
  src: url(fonts/dm-sans-latin-ext-opsz-normal.woff2) format('woff2-variations'), url(fonts/dm-sans-latin-ext-opsz-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}

/* dm-sans-latin-opsz-normal */
@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-display: swap;
  font-weight: 100 1000;
  src: url(fonts/dm-sans-latin-opsz-normal.woff2) format('woff2-variations'), url(fonts/dm-sans-latin-opsz-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

/* Layout: grønt bånd øverst med logoet (maler under statuslinjen) og en fanebar i bunden med Ugen, Opskrifter og Profil.
   Hver fane viser ét panel. Farverne følger logoet med den grønne tallerken. */
:root{
  color-scheme:light;
  --bg:#F1F3EE; --surface:#FFFFFF; --sunk:#F7F8F4; --fg:#1C2A21; --muted:#5A675F; --line:#D8DED6;
  --brand:#22412F; --on-brand:#F6F0DA; --gold:#F3C14E;
  --accent:#22412F; --accent-soft:#E3EBE4; --on-accent:#F6F0DA;
  --apple-bg:#000000; --apple-fg:#FFFFFF; --check:#0A7AFF; --lock:#8A6410; --lock-soft:#FBF1D6; --warn:#A3322A;
  --p-kylling:#C58712; --p-okse:#A2342B; --p-lam:#7A5BA6; --p-gris:#D0677A; --p-fisk:#2D6E9E; --p-vegetar:#3E7D3A;
  --font:"DM Sans","Avenir Next","Segoe UI",system-ui,-apple-system,sans-serif;
}
@media (prefers-color-scheme: dark){ :root{
  color-scheme:dark;
  --bg:#101612; --surface:#18211B; --sunk:#141C16; --fg:#E9EEE8; --muted:#9AA79E; --line:#2A362D;
  --brand:#1A3324; --on-brand:#F6F0DA; --gold:#F3C14E;
  --accent:#A8D0B5; --accent-soft:#20302566; --on-accent:#0F1A13;
  --apple-bg:#FFFFFF; --apple-fg:#000000; --check:#3B9BFF; --lock:#E9BF5E; --lock-soft:#2E2715; --warn:#F0897C;
  --p-kylling:#E2AE47; --p-okse:#E07A6F; --p-lam:#B9A2E0; --p-gris:#EE9CAA; --p-fisk:#78B3DE; --p-vegetar:#86C27F; } }

*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--bg);color:var(--fg);font-family:var(--font);font-size:15px;line-height:1.5;padding-bottom:env(safe-area-inset-bottom,0px)}
img{max-width:100%}
[hidden]{display:none!important}

.topband{background:var(--brand);color:var(--on-brand);padding-top:env(safe-area-inset-top,0px)}
.topinner{max-width:980px;margin:0 auto;padding-block:14px;padding-left:max(16px,env(safe-area-inset-left,0px));padding-right:max(16px,env(safe-area-inset-right,0px));display:flex;align-items:center;justify-content:space-between;gap:12px}
.brand{display:flex;align-items:center;gap:12px}
.brand img{border-radius:10px;display:block}
.brand span{display:block;font-size:13px;opacity:.85;line-height:1.2;margin-top:2px}
.brand b{display:block;font-size:24px;font-weight:700;letter-spacing:-.01em;line-height:1.1}
.onband{color:var(--on-brand);border-color:color-mix(in srgb,var(--on-brand) 35%,transparent)}
/* fanebar i bunden: ikon og tekst, mindst 44 pt høj, over hjemmeindikatoren */
.tabbar{position:fixed;left:0;right:0;bottom:0;z-index:40;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:4px;
  padding:4px max(8px,env(safe-area-inset-right,0px)) max(4px,env(safe-area-inset-bottom,0px)) max(8px,env(safe-area-inset-left,0px));
  background:color-mix(in srgb,var(--surface) 94%,transparent);-webkit-backdrop-filter:blur(14px);backdrop-filter:blur(14px);border-top:1px solid var(--line)}
.tabbar button{background:transparent;border:0;border-radius:12px;min-height:50px;padding:4px 6px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;font-size:11px;font-weight:600;letter-spacing:.01em;color:var(--muted)}
.tabbar button:hover:not(:disabled){border-color:transparent;color:var(--fg)}
.tabbar svg{width:25px;height:25px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.tabbar button[aria-selected=true]{color:var(--accent)}
.tabbar button[aria-selected=true] svg{stroke-width:2.2}
@media (min-width:761px){ .tabbar{grid-template-columns:repeat(4,minmax(0,150px));justify-content:center} }
body:has(.tabbar:not([hidden])){padding-bottom:calc(60px + env(safe-area-inset-bottom,0px))}

.wrap{max-width:980px;margin:0 auto;padding-block:24px 56px;padding-left:max(16px,env(safe-area-inset-left,0px));padding-right:max(16px,env(safe-area-inset-right,0px));display:flex;flex-direction:column;gap:36px}
h1,h2,h3{font-weight:700;letter-spacing:-.01em;text-wrap:balance;margin:0}
h1{font-size:28px;line-height:1.1}
h2{font-size:22px;line-height:1.2}
h3{font-size:17px}
.eyebrow{font-size:12px;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);font-weight:600}
.lede{color:var(--muted);max-width:65ch;margin:6px 0 0}
.num{font-variant-numeric:tabular-nums}

button,select,input,textarea{font:inherit;color:var(--fg)}
button{cursor:pointer;border-radius:10px;border:1px solid var(--line);background:var(--surface);padding:8px 12px;font-weight:500;white-space:nowrap;min-height:44px;-webkit-tap-highlight-color:transparent}
button:hover:not(:disabled){border-color:var(--accent)}
button:disabled{opacity:.45;cursor:default}
.primary{background:var(--accent);border-color:var(--accent);color:var(--on-accent);font-weight:600}
.ghost{background:transparent}
.danger{color:var(--warn)}
.icon{min-width:44px;padding:6px 10px}
select,input[type=text],input[type=email],input[type=password],input[type=number],input[type=url],input[type=search],textarea{border:1px solid var(--line);background:var(--surface);border-radius:10px;padding:8px 10px;min-width:0;min-height:44px;font-size:16px}
textarea{width:100%;resize:vertical;line-height:1.45}
:is(button,select,input,textarea,summary,a):focus-visible{outline:2px solid var(--accent);outline-offset:2px}
label.f{display:flex;flex-direction:column;gap:4px;font-size:13px;font-weight:600;color:var(--muted);min-width:0}
label.f > :is(input,select,textarea){color:var(--fg);font-weight:400}

.dot{display:inline-block;width:9px;height:9px;border-radius:50%;background:var(--muted);flex:none}
.dot.kylling{background:var(--p-kylling)} .dot.okse{background:var(--p-okse)} .dot.lam{background:var(--p-lam)} .dot.gris{background:var(--p-gris)} .dot.fisk{background:var(--p-fisk)} .dot.vegetar{background:var(--p-vegetar)}

/* planner */
.plan{background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:18px;display:flex;flex-direction:column;gap:16px}
.planhead{display:flex;flex-wrap:wrap;gap:12px;align-items:flex-end;justify-content:space-between}
.titlerow{display:flex;align-items:center;justify-content:space-between;gap:8px;flex:1 1 auto}
.titlerow h2{margin:0}
.icon.share{display:inline-flex;align-items:center;justify-content:center;min-height:44px;color:var(--muted)}
.icon.share svg{width:21px;height:21px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.shop .planhead .meta{margin-top:4px}

.days{display:flex;flex-direction:column;gap:6px}
.day{border:1px solid var(--line);border-radius:12px;background:var(--sunk);display:flex;flex-direction:column}
.day.locked{border-color:var(--lock);background:var(--lock-soft)}
.day.today{box-shadow:inset 4px 0 0 var(--gold)}
.dsum:hover:not(:disabled){border-color:transparent;background:color-mix(in srgb,var(--accent) 5%,transparent)}
.dn b{display:block;font-weight:700;font-size:15px;line-height:1.15}
.dn span{display:block;font-size:12px;color:var(--muted);line-height:1.2}
.dmain{min-width:0;display:flex;flex-direction:column;gap:1px}
.nm{font-weight:700;font-size:16px;line-height:1.25;overflow:hidden;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow-wrap:anywhere}
.nm.empty{color:var(--muted);font-weight:500;font-size:15px}
.meta{display:flex;flex-wrap:nowrap;align-items:center;gap:8px;font-size:12px;color:var(--muted);white-space:nowrap;overflow:hidden}
.meta .p{display:inline-flex;align-items:center;gap:5px}
.ppl button{min-width:44px;padding:6px 0;font-weight:700}
.ppl .num{min-width:5.5ch;text-align:center;font-size:14px}
.star{color:var(--gold)}
.favbtn{display:inline-flex;align-items:center;gap:6px}
.favbtn span{color:var(--gold);font-size:17px;line-height:1}
.favbtn[aria-pressed=true]{border-color:var(--gold);font-weight:700}
.day.open .nm{-webkit-line-clamp:unset}
.chev{transition:transform .18s}
.day.open .dchev .chev{transform:rotate(180deg)}
.sel{position:relative;display:block;min-width:0}
.sel > span{position:absolute;left:9px;top:50%;transform:translateY(-50%);font-size:11px;font-weight:600;color:var(--muted);pointer-events:none;line-height:1}
.day.skipped{background:transparent;border-style:dashed}
.planfoot{display:flex;flex-wrap:wrap;gap:10px;align-items:center}
.weekfoot{margin-top:4px}
.tracts{display:flex;align-items:center;gap:8px;flex:none}
.fbbtn{flex:none;width:auto;min-width:44px;padding:0 14px 0 12px;gap:6px;border-radius:22px;font-size:14px;font-weight:600}
.fbbtn svg{width:21px;height:21px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.favcount{margin:2px 0 0}
.status{font-size:13px;color:var(--muted);min-height:1.4em;margin:0}
.status.err{color:var(--warn);font-weight:600}

@media (max-width:760px){
  .plan{padding:14px}
  .weeknav{flex-basis:100%;max-width:none;gap:4px}
  .wkarrow{width:40px;min-width:40px;padding:0}
  .seg3 button{font-size:13px}
}

/* ugevælger: pile og tre uger */
.weeknav{display:flex;align-items:center;gap:6px;flex:1 1 320px;max-width:460px}
.wkarrow{flex:none;font-size:18px;color:var(--muted)}
.seg3{flex:1;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:2px;padding:2px;background:var(--line);border-radius:12px}
.seg3 button{border:0;border-radius:10px;background:transparent;min-height:40px;padding:4px 2px;font-size:14px;font-weight:500;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.seg3 button[aria-pressed=true]{background:var(--surface);color:var(--fg);font-weight:700;box-shadow:0 1px 2px #0002}
.range{display:block;font-size:13px;color:var(--muted);margin-top:2px}

/* dagkortet */
.drow{display:flex;align-items:center;gap:2px;padding-right:4px}
.dsum{flex:1;min-width:0;display:grid;grid-template-columns:3rem minmax(0,1fr) auto;gap:8px;align-items:center;text-align:left;background:transparent;border:0;border-radius:12px;padding:8px 4px 8px 12px;min-height:56px;white-space:normal;font-weight:400}
.dic{display:inline-flex;color:var(--muted)}
.dic svg,.dlock svg,.dchev svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.dlock,.dchev{flex:none;width:44px;min-width:44px;height:44px;padding:0;display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:22px;background:transparent;color:var(--muted)}
.dlock[aria-pressed=true]{color:var(--lock);background:var(--surface)}
.dlock[aria-pressed=true] svg rect{fill:currentColor}
.dchev svg{width:16px;height:16px}
.ddetail{display:flex;flex-direction:column;gap:12px;padding:12px;border-top:1px solid var(--line)}
.chips{display:flex;flex-wrap:wrap;gap:6px}
/* Lukket filterrække: "Træk blandt  Alle  50 retter ▾"; folder chips ud under sig */
.fltrow{display:flex;align-items:center;gap:8px;width:100%;min-height:44px;padding:0 4px;border:0;border-top:1px solid var(--line);border-radius:0;background:transparent;color:var(--fg);text-align:left;cursor:pointer}
.fltrow .eyebrow{flex:none}
.fltrow .fltv{flex:1;min-width:0;font-size:14px;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.fltrow .cnt{flex:none;font-size:13px;color:var(--muted)}
.fltrow .chev{width:14px;height:14px;flex:none;fill:none;stroke:var(--muted);stroke-width:2;stroke-linecap:round;stroke-linejoin:round;transition:transform .15s}
.fltrow[aria-expanded=true] .chev{transform:rotate(180deg)}
.fltrow:last-child{margin-bottom:-8px}
.unlockbtn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;font-size:15px;font-weight:600}
.unlockbtn svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.chip{position:relative;display:inline-flex;align-items:center;gap:6px;min-height:40px;padding:0 12px;border:1px solid var(--line);border-radius:20px;background:var(--surface);font-size:14px;font-weight:500;color:var(--fg);cursor:pointer;white-space:nowrap}
.chip svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round;flex:none}
.chip .chev{width:13px;height:13px}
.chip[aria-pressed=true]{background:var(--accent);border-color:var(--accent);color:var(--on-accent);font-weight:700}
.chip:disabled,.chip:has(select:disabled){opacity:.45;cursor:default}
.selchip select{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer;font-size:16px}
.dbtns{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.dbtns .primary,.pickbtn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:48px;font-size:15px;font-weight:600}
.dbtns svg,.dfoot svg,.dmenu svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;flex:none}
.pickbtn{position:relative;border:1px solid var(--line);border-radius:10px;background:var(--surface);cursor:pointer}
.dfoot{display:flex;align-items:center;justify-content:space-between;gap:6px;flex-wrap:wrap;margin:0 -4px;padding-bottom:10px;border-bottom:1px solid var(--line)}
.dfr{display:flex;gap:4px}
.dfoot .link{display:inline-flex;align-items:center;gap:2px;border:0;background:transparent;color:var(--accent);font-weight:700;padding:0 6px}
.dfoot .ghost{display:inline-flex;align-items:center;gap:6px;border-color:transparent;padding:0 10px}
.favtg[aria-pressed=true]{color:var(--lock);border-color:var(--gold)}
.favtg[aria-pressed=true] svg{fill:var(--gold);stroke:var(--gold)}
.moretg[aria-expanded=true]{border-color:var(--accent);background:var(--accent-soft)}
.dmenu{display:flex;flex-direction:column;border:1px solid var(--line);border-radius:14px;background:var(--surface);overflow:hidden}
.dmenu .mi{display:flex;align-items:center;justify-content:space-between;gap:10px;min-height:52px;padding:4px 8px 4px 14px;border:0;border-top:1px solid var(--line);border-radius:0;background:transparent;font-size:15px;font-weight:500;text-align:left;width:100%}
.dmenu .mi:first-child{border-top:0}
.dmenu .mi[aria-expanded=true]{background:var(--accent-soft)}
.ppl{display:inline-flex;align-items:center;gap:6px}
.swaplist{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:6px;padding:8px;border-top:1px solid var(--line);background:var(--sunk)}
.swaplist button{display:flex;flex-direction:column;align-items:flex-start;gap:2px;text-align:left;white-space:normal;min-height:52px;font-size:13px;line-height:1.25}
.swaplist button span{color:var(--muted);overflow:hidden;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.day.skipped .ddetail{align-items:flex-start}

/* Vælg selv: ark med søgning */
#pickQ{width:100%;min-height:44px;font-size:16px}
.picklist{display:flex;flex-direction:column;gap:14px}
.psec ul{list-style:none;margin:6px 0 0;padding:0;display:flex;flex-direction:column}
.pitem{display:flex;align-items:center;gap:12px;width:100%;min-height:64px;padding:8px 4px;border:0;border-bottom:1px solid var(--line);border-radius:0;background:transparent;text-align:left;white-space:normal;font-weight:400}
.pitem:hover:not(:disabled){background:color-mix(in srgb,var(--accent) 5%,transparent)}
.pthumb{flex:none;width:44px;height:44px;border-radius:10px;display:inline-flex;align-items:center;justify-content:center;background:color-mix(in srgb,var(--muted) 16%,transparent)}
.pthumb .dot{width:14px;height:14px}
.pthumb{position:relative;overflow:hidden}
.pthumb img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.pthumb:has(img) .dot{display:none}
.rthumb{width:52px;height:52px}
.obthumb{width:40px;height:40px;border-radius:8px}
.obdishes .sitem:has(.obthumb){grid-template-columns:22px 40px minmax(0,1fr) auto}
.pthumb.kylling{background:color-mix(in srgb,var(--p-kylling) 18%,transparent)} .pthumb.okse{background:color-mix(in srgb,var(--p-okse) 18%,transparent)} .pthumb.lam{background:color-mix(in srgb,var(--p-lam) 18%,transparent)} .pthumb.gris{background:color-mix(in srgb,var(--p-gris) 18%,transparent)} .pthumb.fisk{background:color-mix(in srgb,var(--p-fisk) 18%,transparent)} .pthumb.vegetar{background:color-mix(in srgb,var(--p-vegetar) 18%,transparent)}
.ptext{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
/* Favoritstjernen: egen kolonne mellem billede og navn, lodret midt for billedet */
.lstar{flex:none;width:18px;display:flex;align-items:center;justify-content:center;color:var(--gold);font-size:17.5px;line-height:1}
.pitem .lstar{margin:0 -4px}
.pname{font-weight:700;font-size:15px;line-height:1.25}
.pmeta{font-size:12px;color:var(--muted)}
.ptag{flex:none;padding:3px 8px;border-radius:8px;background:var(--sunk);border:1px solid var(--line);font-size:12px;color:var(--muted)}
.ptag.cur{background:var(--accent-soft);border-color:var(--accent);color:var(--accent);font-weight:700}

.sharebtn{display:inline-flex;align-items:center;gap:8px}
.sharebtn svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}

/* AI-opskrift: Prøv en anden og Tilpas */
.aibar{display:flex;flex-direction:column;gap:10px;border:1px solid var(--line);background:var(--sunk);border-radius:14px;padding:12px}
.aibar .row{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.aibar .row button{display:inline-flex;align-items:center;justify-content:center;gap:8px;font-weight:600}
.aibar svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;flex:none}
.aibar #aiTune[aria-expanded=true]{background:var(--accent-soft);border-color:var(--accent);color:var(--accent)}
.aibar .uses{margin:0;font-size:13px;line-height:1.45}
.aibar .uses .buy{color:var(--muted)}
.aibar .tilpas{display:flex;flex-direction:column;gap:8px}
.aibar .mini{font-size:13px;color:var(--muted)}
.aibar .status:empty{display:none}

/* besked med Fortryd over fanebaren */
.toast{position:fixed;z-index:45;left:max(12px,env(safe-area-inset-left,0px));right:max(12px,env(safe-area-inset-right,0px));bottom:calc(72px + env(safe-area-inset-bottom,0px));max-width:520px;margin:0 auto;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:4px 4px 4px 16px;min-height:52px;border-radius:14px;background:var(--fg);color:var(--bg);font-size:14px;box-shadow:0 8px 24px #0004}
.toast span{min-width:0;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.toast .undo{flex:none;border:0;background:transparent;color:var(--gold);font-weight:700;padding:0 12px}
.tabbar .badge{position:absolute;top:2px;left:calc(50% + 6px);min-width:18px;height:18px;padding:0 5px;border-radius:9px;background:var(--accent);color:var(--on-accent);font-size:11px;font-weight:700;line-height:18px;text-align:center;box-sizing:border-box}
.tabbar button{position:relative}

/* recipe file */
.file{display:flex;flex-direction:column;gap:14px}
.filebar{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.filebar input[type=search]{flex:1 1 220px}
.group{display:flex;flex-direction:column;gap:6px}
.group h3{display:flex;align-items:center;gap:8px;font-size:15px;color:var(--muted);font-weight:700;letter-spacing:.02em}
.rlist{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:6px}
.ritem{display:flex;flex-direction:column;align-items:flex-start;gap:2px;text-align:left;width:100%;background:var(--surface);border:1px solid var(--line);border-radius:10px;padding:10px 12px;white-space:normal}
.ritem span{font-weight:600;min-width:0}
.ritem small{color:var(--muted);font-size:12px}
.ritem small .lk{color:var(--accent)}
.emptystate{border:1px dashed var(--line);border-radius:12px;padding:20px;color:var(--muted)}

/* profil */
.profile{display:flex;flex-direction:column;gap:14px;max-width:560px}
/* Profil i tre grupper som i iOS' Indstillinger: Husstand, Indstillinger og Konto. På iPad to kolonner. */
.profile:has(.pcols){max-width:1000px}
.ptitle{font-size:28px;line-height:1.1;letter-spacing:-.015em;margin:0}
.pcols{display:grid;grid-template-columns:minmax(0,1fr);gap:18px;align-items:start}
.pcol{display:flex;flex-direction:column;gap:18px;min-width:0}
@media (min-width:900px){ .pcols{grid-template-columns:minmax(0,1fr) minmax(0,1fr)} }
.pgroup{display:flex;flex-direction:column;gap:6px}
.pgroup>.eyebrow{padding-left:4px}
.plist{background:var(--surface);border:1px solid var(--line);border-radius:16px;overflow:hidden}
.prow{display:flex;flex-direction:column;gap:6px;padding:12px 16px;border-bottom:1px solid var(--line);min-height:48px;justify-content:center}
.plist>.prow:last-child,.plist>details:last-child{border-bottom:0}
.prow>b{font-size:17px;overflow-wrap:anywhere}
.prow2{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:4px 12px}
.prow2 label{display:flex;flex-direction:column;gap:2px;margin:0;font-size:15px;color:var(--fg)}
.prow2 label small{font-size:12px}
.prow2 select{min-height:40px;max-width:170px}
.prow2 .status{grid-column:1/-1}
.pval{overflow-wrap:anywhere;min-width:0}
.prow2 .pval{color:var(--muted);text-align:right}
.members{list-style:none;margin:0;padding:0;border-bottom:1px solid var(--line)}
.members li{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 16px;border-top:1px solid var(--line);min-height:48px}
.members li:first-child{border-top:0}
.members small{color:var(--muted);font-weight:600}
.members code{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;letter-spacing:.06em}
.pill{font-size:12px;font-weight:700;border-radius:999px;padding:3px 9px;background:var(--lock-soft);color:var(--lock);white-space:nowrap}
.pdet>summary{list-style:none;cursor:pointer;font-weight:600;min-height:24px;display:flex;align-items:center;justify-content:space-between}
.pdet>summary::-webkit-details-marker{display:none}
.pdet>summary::after{content:"›";color:var(--muted);font-size:20px;transition:transform .15s}
.pdet[open]>summary::after{transform:rotate(90deg)}
.pdet>summary:focus-visible{outline:2px solid var(--accent);outline-offset:4px;border-radius:6px}
.padd{color:var(--accent)}
.pdanger{color:var(--warn)}
.pbody{display:flex;flex-direction:column;gap:10px;padding-top:10px;margin:0}
.prow>.plain{align-self:flex-start;background:transparent;border:0;padding:0;min-height:24px;font-weight:600;color:var(--fg)}
.prow .kitchen{border:0;background:transparent;padding:0}
@media (prefers-reduced-motion:reduce){ .pdet>summary::after{transition:none} }
.pcard{background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:18px;display:flex;flex-direction:column;gap:12px;margin:0}
.pcard b{font-size:17px;word-break:break-all}
#inviteResult{display:flex;flex-direction:column;gap:8px}
.invacts{display:flex;flex-wrap:wrap;gap:8px}

/* login */
.login{min-height:60vh;justify-content:center}
.loginbox{max-width:380px;width:100%;margin:0 auto;background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:24px;display:flex;flex-direction:column;gap:14px}
.loginbox img{border-radius:16px}
/* velkomst og oprettelse (prototype) */
.ob{max-width:420px;width:100%;margin:0 auto;background:var(--surface);border:1px solid var(--line);border-radius:16px;padding:24px;display:flex;flex-direction:column;gap:16px}
.ob.obwide{max-width:980px}
.ob h1[tabindex="-1"]:focus{outline:none}
.obwelcome{text-align:center;align-items:center;gap:14px;padding-block:36px 28px}
.obwelcome img{border-radius:22px}
.obwelcome h1{font-size:34px}
.obsub{margin:2px 0 0;color:var(--muted);font-size:17px}
.oblead{margin:0;color:var(--fg);max-width:36ch}
.obactions{display:flex;flex-direction:column;gap:10px;width:100%}
.obactions button{min-height:48px;font-size:16px}
.obhead{display:flex;justify-content:space-between;align-items:center;margin:-8px -8px 0}
.obback{padding:6px 8px;min-height:44px}
.obstep{font-size:12px;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);font-weight:600}
.obrow{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.obrow select{width:100%}
.obsign{max-width:400px}
.obsign h1{text-align:center;font-size:30px}
.obmail{display:flex;flex-direction:column;gap:10px;border-radius:14px}
.obmail input,.obpw input{width:100%;min-height:52px;border-radius:12px;padding:12px 14px;font-size:16px;background:var(--sunk)}
.obmail input:focus{border-color:var(--fg);outline:2px solid var(--fg);outline-offset:0}
.obpw{position:relative}
.obpw input{padding-right:50px}
.obeye{position:absolute;right:6px;top:50%;transform:translateY(-50%);min-height:44px;min-width:44px;padding:0;border:0;background:transparent;color:var(--muted);display:grid;place-items:center}
.obeye[aria-pressed=true]{color:var(--fg)}
.obmail[aria-pressed=true] input{border-color:var(--accent)}
.obgo{min-height:54px;border-radius:999px;background:var(--brand);border-color:var(--brand);color:var(--on-brand);font-size:17px;font-weight:700}
.obor{display:flex;align-items:center;gap:10px;color:var(--muted);font-size:13px}
.obor::before,.obor::after{content:"";flex:1;border-top:1px solid var(--line)}
.obmethods{display:flex;flex-direction:column;gap:10px}
.obm{min-height:50px;border-radius:999px;font-size:15px;font-weight:700;display:flex;align-items:center;justify-content:center;gap:8px;position:relative}
.obm-google{background:var(--surface);color:var(--fg);border:1.5px solid var(--line)}
.obm-apple{background:var(--apple-bg);color:var(--apple-fg);border-color:var(--apple-bg)}
.obm-facebook{background:#1877F2;color:#FFFFFF;border-color:#1877F2}
.obm-instagram{background:#C13584;color:#FFFFFF;border-color:#C13584}
.obm[aria-pressed=true]{box-shadow:0 0 0 3px var(--bg),0 0 0 6px var(--gold)}
.obm[aria-pressed=true]::after{content:"✓";position:absolute;right:20px;font-size:17px}
.oblink{background:none;border:0;min-height:44px;color:var(--muted);text-decoration:underline;text-underline-offset:3px;font-weight:600;align-self:center}
.oblink[aria-pressed=true]{color:var(--fg);text-decoration-color:var(--gold);text-decoration-thickness:2px}
.obnote{text-align:center}
.obpick{border:0;margin:0;padding:14px;box-sizing:border-box;width:100%;min-width:0;text-align:left;background:var(--sunk);border-radius:14px;display:flex;flex-direction:column;gap:10px}
.obpicktitle{margin:0;font-weight:700;font-size:15px}
.obpick .obrow{grid-template-columns:minmax(0,.8fr) minmax(0,1.2fr)}
.obpick select{padding-inline:10px 6px}
.obpick .hint{margin:0}
.obdishbar{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap}
.obdishbar .ghost{min-height:44px}
.obdishes{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:8px 24px;align-items:start}
/* Retter: flueben betyder "med". En udstreget ret har ingen flueben. */
.obdishes .sitem .box{background:var(--accent);border-color:var(--accent)}
.obdishes .sitem .box::after{content:"";position:absolute;left:5px;top:1px;width:5px;height:10px;border:solid var(--on-accent);border-width:0 2px 2px 0;transform:rotate(45deg)}
.obdishes .sitem.struck .box{background:transparent;border-color:var(--line)}
.obdishes .sitem.struck .box::after{content:none}
/* Fravalgt i lister med valg (Ny bog, oprettelse, samlinger): tom cirkel og nedtonet tekst. Gennemstregning bruges kun til købt på indkøbslisten. */
.obdishes .sitem.struck .st{text-decoration:none;color:var(--muted);font-weight:500}
.obdishes .ssec h3{display:flex;align-items:center;gap:8px;margin-top:8px}
#obDishDone{position:sticky;align-self:center;width:min(100%,380px);bottom:calc(12px + env(safe-area-inset-bottom));min-height:50px;font-size:16px;box-shadow:0 6px 18px rgba(0,0,0,.18)}
/* Trin 4, favoritter: tæller med bjælke (stregen står ved 10 af 15), rækker med stjerne og to knapper i bunden. */
.obmeter{display:flex;flex-direction:column;gap:6px;background:var(--surface);border:1px solid var(--line);border-radius:12px;padding:10px 12px;position:sticky;top:calc(8px + env(safe-area-inset-top,0px));z-index:2}
.obmt{display:flex;justify-content:space-between;align-items:baseline;gap:10px;flex-wrap:wrap}
.obmt span{color:var(--muted);font-size:13px}
.obmeter .meter{position:relative;height:8px;border-radius:999px;background:var(--line)}
.obmeter .meter i{position:absolute;inset:0 auto 0 0;width:0;border-radius:999px;background:var(--gold);transition:width .2s}
.obmeter .meter u{position:absolute;top:-3px;bottom:-3px;left:66.6%;width:2px;background:var(--fg);opacity:.5}
.favrow{flex:1;min-width:0;display:flex;align-items:center;justify-content:space-between;gap:10px;text-align:left;background:transparent;border:0;border-radius:8px;padding:6px 4px;min-height:44px;font-weight:500;white-space:normal}
.favrow:hover:not(:disabled){border-color:transparent;background:color-mix(in srgb,var(--accent) 5%,transparent)}
.favrow .st{overflow-wrap:anywhere}
.favrow .favtog{display:inline-grid;place-items:center}
.favrow[aria-pressed=true] .favtog{color:var(--gold)}
.obfavfoot{position:sticky;bottom:calc(12px + env(safe-area-inset-bottom));align-self:center;width:min(100%,420px);display:grid;grid-template-columns:1fr 1fr;gap:10px}
.obfavfoot button{min-height:50px;font-size:16px;border-radius:999px;box-shadow:0 6px 18px rgba(0,0,0,.18)}
@media (prefers-reduced-motion:reduce){ .obmeter .meter i{transition:none} }

/* sheet */
.overlay{position:fixed;inset:0;background:color-mix(in srgb,#000 45%,transparent);z-index:50;display:flex;align-items:flex-start;justify-content:center;overflow-y:auto;-webkit-overflow-scrolling:touch;padding:max(24px,calc(env(safe-area-inset-top,0px) + 12px)) max(10px,env(safe-area-inset-right,0px)) max(24px,env(safe-area-inset-bottom,0px)) max(10px,env(safe-area-inset-left,0px))}
.sheet{background:var(--surface);color:var(--fg);border-radius:16px;max-width:720px;width:100%;padding:20px;display:flex;flex-direction:column;gap:16px;border:1px solid var(--line)}
.sheethead{display:flex;justify-content:space-between;gap:12px;align-items:flex-start}
.sheet h2{font-size:24px}
.cols{display:grid;grid-template-columns:minmax(0,2fr) minmax(0,3fr);gap:24px}
.cols ul,.cols ol{margin:6px 0 0;padding-left:1.2em;display:flex;flex-direction:column;gap:6px}
.cols li{max-width:65ch}
.sheetfoot{display:flex;flex-wrap:wrap;gap:8px;justify-content:flex-end}
.formgrid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.formgrid .wide{grid-column:1 / -1}
.formgrid .half{grid-column:span 2}
.sides{display:flex;flex-wrap:wrap;gap:6px 14px;font-weight:400;color:var(--fg);font-size:15px}
.sides label{display:inline-flex;gap:6px;align-items:center}
.hint{font-size:13px;color:var(--muted);margin:0}
a{color:var(--accent)}
.rimg{display:block;width:100%;aspect-ratio:4/3;max-height:300px;object-fit:cover;border-radius:12px;border:1px solid var(--line);background:var(--sunk)}
.rnote{margin:0;font-size:13px;color:var(--fg);background:var(--sunk);border:1px solid var(--line);border-left:4px solid var(--gold);border-radius:10px;padding:8px 12px}
.rnote.warn{border-left-color:var(--warn)}
.eimg{display:flex;flex-direction:column;align-items:flex-start;gap:8px}
.eimg .rimg{max-height:200px}
.rfig{margin:0;display:flex;flex-direction:column;gap:4px}
.rfig figcaption{font-size:11px;color:var(--muted);text-align:right}
.srclink{display:inline-flex;align-items:center;gap:4px;margin-top:10px;font-size:14px;font-weight:600;text-decoration:none;border:1px solid var(--line);border-radius:999px;padding:5px 12px;background:var(--accent-soft)}
.kitchen{position:relative;display:flex;align-items:center;gap:12px;padding:10px 12px;border-radius:12px;border:1px solid var(--line);background:var(--sunk);cursor:pointer;-webkit-tap-highlight-color:transparent}
.kitchen input{position:absolute;opacity:0;width:1px;height:1px;margin:0}
.sw{position:relative;flex:none;width:48px;height:28px;border-radius:999px;background:var(--line);transition:background .18s}
.sw::after{content:"";position:absolute;top:3px;left:3px;width:22px;height:22px;border-radius:50%;background:#fff;box-shadow:0 1px 3px rgba(0,0,0,.25);transition:transform .18s}
.kitchen input:checked + .sw{background:var(--accent)}
.kitchen input:checked + .sw::after{transform:translateX(20px)}
.kitchen input:focus-visible + .sw{outline:2px solid var(--accent);outline-offset:2px}
.kt{display:flex;flex-direction:column;min-width:0}
.kt b{font-weight:600}
.kt small{font-size:12px;color:var(--muted)}
.sdaywrap{display:flex;flex-direction:column;gap:6px}
.sdayhead{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:-6px}
.infobtn{width:36px;min-width:36px;height:36px;border:0;background:transparent;color:var(--muted);display:inline-flex;align-items:center;justify-content:center}
.infobtn[aria-expanded=true]{color:var(--accent)}
.sdays{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:6px}
.sday{display:flex;flex-direction:column;align-items:center;gap:4px;padding:8px 2px;min-height:58px;border-radius:10px;font-size:13px;font-weight:600;color:var(--muted)}
.sday.on{color:var(--fg);border-color:var(--check);background:color-mix(in srgb,var(--check) 8%,var(--surface))}
.sday[data-none]{opacity:.55}
.sday .cb{width:20px;height:20px;border-radius:6px;border:2px solid var(--line);position:relative}
.sday.on .cb{background:var(--check);border-color:var(--check)}
.sday.on .cb::after{content:"";position:absolute;left:5px;top:1px;width:5px;height:10px;border:solid #fff;border-width:0 2px 2px 0;transform:rotate(45deg)}
.shopbody{display:flex;flex-direction:column;gap:14px}
.ssec h3{font-size:13px;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);font-weight:700;margin-bottom:4px}
.ssec ul{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}
.srow{display:flex;align-items:center;gap:4px;border-bottom:1px solid var(--line)}
.srow:last-child{border-bottom:0}
.sitem{flex:1;min-width:0;display:grid;grid-template-columns:22px minmax(0,1fr) auto;align-items:center;gap:10px;text-align:left;background:transparent;border:0;border-radius:8px;padding:9px 4px;min-height:44px;white-space:normal;font-weight:500}
.sitem:hover:not(:disabled){border-color:transparent;background:color-mix(in srgb,var(--accent) 5%,transparent)}
.sitem .box{width:20px;height:20px;border-radius:50%;border:2px solid var(--line);position:relative}
.sitem.struck .box{background:var(--accent);border-color:var(--accent)}
.sitem.struck .box::after{content:"";position:absolute;left:5px;top:1px;width:5px;height:10px;border:solid var(--on-accent);border-width:0 2px 2px 0;transform:rotate(45deg)}
.sitem .st{overflow-wrap:anywhere}
.sitem.struck .st{text-decoration:line-through;color:var(--muted);font-weight:400}
.sitem small{font-size:11px;color:var(--muted);white-space:nowrap}
.xdel{min-width:44px;min-height:44px;padding:4px 8px;color:var(--muted)}
form.f,div.f{display:flex;flex-direction:column;gap:4px;font-size:13px;font-weight:600;color:var(--muted);margin:0}
form.f input{color:var(--fg);font-weight:400}
.or{display:flex;align-items:center;gap:10px;color:var(--muted);font-size:13px}
.or::before,.or::after{content:"";flex:1;border-top:1px solid var(--line)}
.linkrow{display:flex;gap:8px;flex-wrap:wrap}
.linkrow input{flex:1 1 220px}
@media (max-width:640px){ .cols{grid-template-columns:1fr} .formgrid{grid-template-columns:1fr 1fr} .formgrid .half{grid-column:1 / -1} }
@media (prefers-reduced-motion:no-preference){ .nm{transition:opacity .18s} .day.flash .nm{opacity:.2} }
@media (prefers-reduced-motion:reduce){ .chev,.sw,.sw::after{transition:none} }

/* Husstand i oprettelsen og invitationskode i Profil */
.obhh{display:flex;flex-direction:column;gap:10px}
.obhh .obm{background:var(--surface);color:var(--fg);border:1.5px solid var(--line);white-space:normal;text-align:center;padding:10px 44px}
.obhhfield input{width:100%;min-height:48px}
#obHhCodeIn{text-transform:uppercase;letter-spacing:.15em;font-family:ui-monospace,SFMono-Regular,Menlo,monospace}
.invcode{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:28px;font-weight:700;letter-spacing:.12em;margin:8px 0;color:var(--fg)}

/* Samlinger */
.libentry,.libitem{display:flex;flex-direction:column;align-items:flex-start;gap:2px;width:100%;text-align:left;white-space:normal;padding:12px 14px;border-radius:12px;background:var(--sunk)}
.libentry b,.libitem b{font-size:15px;color:var(--fg)}
.libentry span,.libitem span{font-size:13px;color:var(--muted);font-weight:400}
.libentry{border:1.5px solid var(--accent)}
.liblist{gap:8px}
.seg{display:flex;flex-wrap:wrap;gap:6px;margin-top:4px}
.seg button{min-height:44px;border-radius:999px;font-weight:600;font-size:14px;white-space:normal;text-align:center}
.seg button[aria-pressed=true]{background:var(--accent);border-color:var(--accent);color:var(--on-accent)}
.obdishes .sitem.owned{opacity:.55;cursor:default}
.obdishes .sitem small{font-size:12px;color:var(--muted);font-weight:500;margin-left:6px}

/* Til de kræsne */
.kidsbox{border:1px solid var(--line);border-left:4px solid var(--gold);border-radius:12px;padding:10px 14px;background:var(--sunk);display:flex;flex-direction:column;gap:4px}
.kidsbox h3{margin:0;font-size:14px}
.kidsbox p{margin:0}
.kidsbox.empty{flex-direction:row;flex-wrap:wrap;align-items:center;gap:8px 12px;border-left-width:1px}
.kidsbox.empty .status{flex-basis:100%}
/* Fortryd i beskeden efter Træk ny uge */
/* Uden net: besked over ugen */
.offline{margin:0;padding:10px 12px;border-radius:12px;background:var(--lock-soft);color:var(--lock);font-size:13px;font-weight:600;line-height:1.4}
#langSel{max-width:320px;width:100%}
/* Statuslinjen: fast grøn baggrund, så indholdet ikke løber ind under klokken, når man scroller */
body::before{content:"";position:fixed;top:0;left:0;right:0;height:env(safe-area-inset-top,0px);background:var(--brand);z-index:45;pointer-events:none}
/* Hjerte ved retterne i oprettelsen: favoritter */
.favtog{background:transparent;border:0;min-width:44px;min-height:44px;padding:0;font-size:22px;line-height:1;color:var(--muted)}
.favtog[aria-pressed=true]{color:var(--gold)}
.favtog:hover:not(:disabled){border-color:transparent;color:var(--gold)}
.wrap>.offline{margin-bottom:-24px}
/* Samlinger: en ret, der ikke er valgt, har en tom cirkel og ingen gennemstregning (gennemstregning betyder "købt"). */
#libDishes .sitem.struck .st{color:var(--fg)}
/* Forslag på dagkortet: en ret, der har været på planen 3 gange, kan blive favorit med ét tryk. */
.favsug{display:flex;flex-direction:column;gap:8px;padding:10px 12px;border-radius:12px;background:color-mix(in srgb,var(--gold) 14%,var(--surface));border:1px solid color-mix(in srgb,var(--gold) 45%,var(--line));font-size:14px}
.favsugb{display:flex;gap:8px;justify-content:flex-end;flex-wrap:wrap}
.favsugb button{min-height:40px;display:inline-flex;align-items:center;gap:6px}
.favsugb svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linejoin:round}
.plink{text-align:center}
.plist .status:empty{display:none}
/* Bred skærm (iPad vandret, computer): ugen til venstre (360 px) og den valgte dag til højre, der bliver stående ved scroll.
   Indkøbslisten står i to kolonner. Under 1000 px er alt som på telefonen. */
.daypane{min-width:0}
.pane{display:flex;flex-direction:column;gap:14px}
.phead{display:flex;flex-direction:column;gap:4px}
.ptl{display:flex;align-items:flex-start;justify-content:space-between;gap:8px}
.ptl h3{margin:0;font-size:24px;line-height:1.15;letter-spacing:-.01em;text-wrap:balance}
.pane .ddetail{border:1px solid var(--line);border-radius:12px;background:var(--sunk)}
.pane .ddetail>.dfoot:last-child{border-bottom:0;padding-bottom:0}
.prec h3{margin:0;font-size:16px}
.day.sel{border-color:var(--accent);box-shadow:0 0 0 1px var(--accent)}
@media (min-width:1000px){
  .wrap{max-width:1240px}
  #panel-week{display:grid;grid-template-columns:360px minmax(0,1fr);gap:16px 24px;align-items:start}
  #panel-week>:not(#dayPane){grid-column:1}
  #panel-week .planhead{flex-direction:column;align-items:stretch}
  #panel-week .weeknav{max-width:none;flex-basis:auto}
  #dayPane{grid-column:2;grid-row:1 / span 6;position:sticky;top:calc(16px + env(safe-area-inset-top,0px));max-height:calc(100vh - 120px);overflow:auto;padding-right:4px}
  .day .dchev{display:none}
  .day .dsum{padding-right:8px}
  #shopBody{display:block;columns:2;column-gap:32px}
  #shopBody .ssec{break-inside:avoid;margin-bottom:14px}
}
/* Opskriften som ark: antal personer, tre felter med stregikoner, køkkentilstand som kontakt og ingredienser i to kolonner. */
.rmeta2{display:flex;flex-wrap:wrap;align-items:center;gap:6px 12px;color:var(--muted);font-size:14px}
.rmeta2 .ppl{display:inline-flex;align-items:center;border:1px solid var(--line);border-radius:999px;overflow:hidden;color:var(--fg)}
.rmeta2 .ppl button{border:0;background:transparent;min-width:44px;min-height:40px;padding:0;font-size:18px;border-radius:0}
.rmeta2 .ppl .num{font-weight:700;min-width:5.5em;text-align:center}
.rtiles{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.rtile{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;min-height:92px;padding:12px 6px;border-radius:16px;border:1px solid var(--line);background:var(--sunk);color:var(--fg);font-weight:700;font-size:14px;text-align:center;white-space:normal}
.rtile svg{width:36px;height:36px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.rtile .ring{stroke:var(--p-okse)}
.rtile[aria-pressed=true]{border:2px solid var(--accent);background:var(--accent-soft);padding:11px 5px}
.rtile#favBtn[aria-pressed=true] svg .fillable{fill:var(--gold);stroke:var(--gold)}
.rtile:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.daypick{display:grid;grid-template-columns:repeat(auto-fill,minmax(140px,1fr));gap:6px}
.daypick button{display:flex;flex-direction:column;align-items:flex-start;gap:2px;text-align:left;min-height:52px;padding:8px 10px;border-radius:12px;white-space:normal}
.daypick span{font-size:12px;color:var(--muted);overflow-wrap:anywhere}
.scaled{margin:0;font-size:13px;color:var(--muted);background:var(--accent-soft);border-radius:10px;padding:8px 12px}
.cookbar{position:relative;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 14px;border-radius:14px;border:1px solid var(--line);background:var(--sunk);cursor:pointer;-webkit-tap-highlight-color:transparent}
.cookbar>span:first-child{display:flex;flex-direction:column;min-width:0}
.cookbar b{font-size:16px}
.cookbar small{font-size:13px;color:var(--muted)}
.cookbar input{position:absolute;opacity:0;width:1px;height:1px;margin:0}
.cookbar input:checked + .sw{background:var(--accent)}
.cookbar input:checked + .sw::after{transform:translateX(20px)}
.cookbar input:focus-visible + .sw{outline:2px solid var(--accent);outline-offset:2px}
.rbody{display:grid;grid-template-columns:minmax(0,1fr);gap:18px}
@media (min-width:700px){ .rbody{grid-template-columns:minmax(0,2fr) minmax(0,3fr);gap:24px} }
.rbody h3{margin:0 0 4px;font-size:18px}
.ings{list-style:none;margin:0;padding:0}
.ings li{display:grid;grid-template-columns:minmax(4.5rem,auto) minmax(0,1fr);gap:14px;padding:9px 0;border-bottom:1px solid var(--line);align-items:baseline}
.ings li b{font-weight:700;white-space:nowrap}
.ings li span{overflow-wrap:anywhere}
.steps{margin:0;padding-left:1.3em;display:flex;flex-direction:column;gap:8px}
/* Streg ud undervejs: trin altid, ingredienser i køkkentilstand */
.tick,.rbody.cook .ings li{cursor:pointer;-webkit-tap-highlight-color:transparent}
.tick{border-radius:6px}
.tick:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.tick.done,.ings li.done{text-decoration:line-through;color:var(--muted)}
.stephint{margin:-4px 0 6px;font-size:13px;color:var(--muted)}
.rbody.cook{font-size:19px;line-height:1.55}
.rbody.cook h3{font-size:21px}
/* Skitse 2: logoet og del-ikonet kun på Ugen (et lavere bånd). På de andre faner står kun den grønne stribe under statuslinjen,
   så den lyse tekst i statuslinjen stadig kan læses. Ugen har ingen ramme om sig; dagene står direkte på baggrunden. */
.topinner{padding-block:8px}
.brand img{width:32px;height:32px}
.brand b{font-size:19px}
.brand span{font-size:12px}
.topinner .share{flex:none}
body:not([data-tab="week"]) .topinner{display:none}
body:not([data-tab="week"]) .topband{padding-bottom:0}
#appView{padding-bottom:calc(96px + env(safe-area-inset-bottom,0px))}
#panel-week.plan{background:transparent;border:0;padding:0;border-radius:0}
#panel-week .day{background:var(--surface)}
#panel-week .day.locked{background:var(--lock-soft)}
.titlerow{align-items:flex-start}
.titlerow h2{text-wrap:balance}
.lockhint{margin:2px 0 0;font-size:13px}
.lockhint .link{border:0;background:transparent;color:var(--accent);font-weight:700;font-size:13px;padding:0 2px;min-height:32px;text-decoration:underline;text-underline-offset:2px}
/* Velkomst første gang efter oprettelsen */
.welcome{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;padding:12px 12px 12px 14px;border-radius:12px;background:var(--accent-soft);color:var(--fg);font-size:14px;line-height:1.4}
.welcome>span:first-child{flex:1 1 220px}
.welcomeb{display:flex;align-items:center;gap:6px}
.welcomeb .primary{min-height:40px;padding:0 16px;font-weight:600}
.welcomeb .icon{width:40px;min-width:40px;height:40px;font-size:20px;border:0;background:transparent;color:var(--muted)}
/* Dage før i dag i den igangværende uge er nedtonede */
.day.past:not(.open):not(.sel){opacity:.6}
#rollWeek{flex:none;min-height:44px;display:inline-flex;align-items:center;gap:6px}
/* Ugevælger: pile og én samlet uge med datoer; "Til denne uge", når man har bladret væk. */
.weeknav{flex-wrap:nowrap}
.wkcur{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:44px;padding:2px 8px;border-radius:12px;background:var(--sunk);border:1px solid var(--line);line-height:1.2}
.wkcur b{font-size:15px}
.wkcur .num{font-size:13px;color:var(--muted)}
.wkhome{flex:none;min-height:44px;padding:0 10px;font-size:13px;font-weight:600;color:var(--accent);border:1px solid var(--line);border-radius:12px;background:var(--surface)}
/* Dagrækker: lidt mindre luft, tid i en fast kolonne, låst med tekst og "I dag" som eget mærke */
#panel-week .dsum{padding-block:6px;min-height:52px}
.dright{display:inline-flex;align-items:center;gap:6px}
.dmin{min-width:4.2em;text-align:right;font-size:13px;color:var(--muted);white-space:nowrap}
.day.today{box-shadow:none}
.todaypill{display:inline-block!important;margin-top:2px;font-size:11px!important;font-weight:700;color:var(--on-accent)!important;background:var(--accent);border-radius:999px;padding:1px 7px;width:max-content}
.dlock .lktxt{font-size:11px;font-weight:700;margin-left:3px}
.dlock[aria-pressed=true]{width:auto;padding:0 10px;border-radius:999px}
.favcount{margin:0;font-size:13px}
/* Aktiv fane: farve og en blød baggrund, så man kan se, hvor man er */
.tabbar button[aria-selected=true]{background:var(--accent-soft)}
.tabbar button[aria-selected=true] svg{fill:color-mix(in srgb,var(--accent) 16%,transparent)}
/* Kartoteket: stjernen har sin egen kolonne, så navnene flugter, og tiden står til højre */
.ritem{display:grid!important;grid-template-columns:52px 18px minmax(0,1fr);align-items:center;gap:8px}
.ritem .rnm{display:flex;flex-direction:column;min-width:0}
.ritem .rnm>span{font-weight:600;overflow-wrap:anywhere}
.addbtn{flex:none;width:44px;height:44px;border-radius:12px}
.addbtn svg{width:22px;height:22px;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:round}
#fileChips{margin-top:-4px}
.topinner .share{background:transparent;color:var(--on-brand);border:1px solid color-mix(in srgb,var(--on-brand) 35%,transparent)}
.topinner .share:hover:not(:disabled){background:color-mix(in srgb,var(--on-brand) 12%,transparent)}
/* Dagrækken: protein, tilbehør og tid på én linje under navnet, adskilt af prikker; tilbehøret forkortes, hvis pladsen mangler */
#panel-week .day .meta{display:flex;flex-wrap:wrap;gap:0;white-space:normal}
#panel-week .day .meta>*{white-space:nowrap}
#panel-week .day .meta>*+*::before{content:"·";margin:0 4px;color:var(--muted)}
#panel-week .day .meta .msides:empty{display:none}
/* Favorit: en stjerne sidst i linjen under navnet */
#panel-week .day .meta .mfav{color:var(--lock);font-weight:600;font-size:14px;line-height:1}

/* Opskriftsbøger */
.bookbar{display:flex}
.bookchip svg:first-child{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.bookchips .chip svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.bookchips .cn{opacity:.7;font-weight:500}
#fileLede .link{border:0;background:transparent;color:var(--accent);font-weight:700;padding:0;cursor:pointer;font:inherit;font-weight:700}
.rbooks{display:flex;flex-direction:column;gap:6px}
.rbooks .chip svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.ghost.danger{color:var(--danger,#b3261e)}
.origname{margin:2px 0 0;font-size:13px;color:var(--muted)}
/* Vente-symbol: lille pille over fanebaren, når et kald tager mere end 1 sekund; over beskeden med Fortryd, når den vises, og nederst ved oprettelse og login */
.busy{position:fixed;left:50%;bottom:calc(76px + env(safe-area-inset-bottom,0px));transform:translateX(-50%);z-index:60;display:inline-flex;align-items:center;gap:8px;padding:8px 14px 8px 10px;border-radius:999px;background:var(--surface);color:var(--fg);border:1px solid var(--line);box-shadow:0 4px 16px rgba(0,0,0,.14);font-size:14px;font-weight:600}
.busy .spin{width:16px;height:16px;border-radius:50%;border:2px solid color-mix(in srgb,var(--accent) 25%,transparent);border-top-color:var(--accent);animation:busyspin .8s linear infinite}
@keyframes busyspin{to{transform:rotate(360deg)}}
@media (prefers-reduced-motion:reduce){.busy .spin{animation:none;border-top-color:color-mix(in srgb,var(--accent) 25%,transparent);background:var(--accent)}}
body:has(#toast:not([hidden])) .busy{bottom:calc(140px + env(safe-area-inset-bottom,0px))}
body:has(#tabs[hidden]) .busy{bottom:calc(20px + env(safe-area-inset-bottom,0px))}

/* Oprettelse trin 4: mellemtrin med Vælg favoritter og Spring over */
.obfavintro,.obfavpick{display:flex;flex-direction:column;gap:16px}
.obintroacts{display:flex;flex-wrap:wrap;gap:10px}
.obintroacts button{min-height:48px;padding:0 20px;font-weight:600}
