/* Layout: the client's own brand fills the app. A walnut (brand main) welcome with the food cards
   dealt onto it; inside, a brand-coloured hero with real food spilling over its edge, then the
   round's pieces, how approving works, and a question box. Launch Design is only the byline.
   Every colour below comes from the client's brand, set on :root by app.js; these are fallbacks. */
:root{
  --bg:#F6F3EE; --card:#FFFFFF; --text:#2A1E17; --muted:#6E625A;
  --main:#4A3427; --onMain:#FFFFFF;
  --hi:#E1BC5C; --onHi:#2A1E17;
  --acc:#ABAE46; --onAcc:#2A1E17;
  --acc2:#F78746; --onAcc2:#2A1E17;
  --line:color-mix(in srgb, var(--text) 12%, transparent);
  --soft:color-mix(in srgb, var(--main) 6%, var(--bg));
  --onMain-2:color-mix(in srgb, var(--onMain) 74%, var(--main));
  --onMain-3:color-mix(in srgb, var(--onMain) 52%, var(--main));
  --font:"Figtree", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --r:14px;
  color-scheme:light;
}
*{ box-sizing:border-box; }
html,body{ margin:0; }
body{ background:var(--bg); color:var(--text); font-family:var(--font); font-size:16px; line-height:1.5; -webkit-font-smoothing:antialiased; }
body.is-loading{ background:var(--main); }
img{ max-width:100%; display:block; }
[hidden]{ display:none !important; }
.sr{ position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; }
a{ color:inherit; }
:focus-visible{ outline:3px solid var(--hi); outline-offset:3px; border-radius:6px; }

.btn{ display:inline-flex; align-items:center; gap:10px; font:700 17px/1 var(--font); border:0; border-radius:12px;
  padding:16px 22px; cursor:pointer; text-decoration:none; transition:transform .15s ease, box-shadow .15s ease; }
.btn:hover{ transform:translateY(-1px); }
.btn:active{ transform:translateY(0); }
.btn-go{ background:var(--acc); color:var(--onAcc); box-shadow:0 10px 24px -12px rgba(0,0,0,.55); }
.btn-main{ background:var(--main); color:var(--onMain); font-size:15.5px; padding:13px 18px; }
.link-btn{ background:none; border:0; font:600 13.5px/1 var(--font); color:var(--onMain-2); cursor:pointer; padding:8px 4px; }
.link-btn:hover{ color:var(--onMain); text-decoration:underline; }
.byline{ font-size:12.5px; letter-spacing:.08em; text-transform:uppercase; font-weight:600; margin:0; }

/* ---------- Welcome ---------- */
.welcome{ min-height:100svh; background:var(--main); color:var(--onMain); display:flex; flex-direction:column; align-items:center;
  text-align:center; padding-inline:16px; padding-block:max(28px, env(safe-area-inset-top)) max(24px, env(safe-area-inset-bottom)); overflow:hidden; }
.welcome-kicker{ margin:0; font-size:13px; letter-spacing:.12em; text-transform:uppercase; font-weight:700; color:var(--onMain-2); }
.welcome-title{ margin:6px 0 0; font-weight:800; font-size:clamp(44px, 11vw, 84px); line-height:1; letter-spacing:-.025em; text-wrap:balance; }
.welcome-sub{ margin:14px 0 26px; font-size:clamp(17px, 2.6vw, 21px); color:var(--onMain-2); max-width:30ch; text-wrap:balance; }
.welcome-err{ margin:12px 0 0; color:var(--hi); font-weight:600; }
.code{ display:flex; flex-direction:column; align-items:center; }
.code-label{ font-size:13px; font-weight:700; letter-spacing:.1em; text-transform:uppercase; color:var(--onMain-2); margin-bottom:10px; }
.code-row{ display:flex; gap:10px; flex-wrap:wrap; justify-content:center; }
.code-input{ width:7.6em; font:700 26px/1 var(--font); letter-spacing:.14em; text-align:center; font-variant-numeric:tabular-nums;
  color:var(--text); background:var(--card); border:0; border-radius:12px; padding:13px 10px; box-shadow:0 10px 24px -14px rgba(0,0,0,.6); }
.code-input::placeholder{ color:color-mix(in srgb, var(--text) 25%, var(--card)); }
.code-input:focus{ outline:3px solid var(--hi); outline-offset:3px; }
.code-input[aria-invalid="true"]{ outline:3px solid var(--acc2); outline-offset:3px; }
.welcome .byline{ margin-top:auto; padding-top:28px; color:var(--onMain-3); }

/* The food cards, fanned like a hand of cards. app.js sets each card's --x, --y, --r and --d. */
.fan{ --cw:clamp(96px, 17vw, 136px); position:relative; width:100%; max-width:760px; height:calc(var(--cw) * 1.78 + 70px); margin:clamp(22px, 5vh, 48px) 0 clamp(18px, 4vh, 36px); }
.fcard{ position:absolute; left:50%; top:24px; width:var(--cw); aspect-ratio:251/435; margin-left:calc(var(--cw) / -2);
  transform:translate(var(--x), var(--y)) rotate(var(--r)); transform-origin:50% 120%;
  border-radius:6px; overflow:visible; box-shadow:0 18px 30px -16px rgba(0,0,0,.7), 0 2px 6px rgba(0,0,0,.25);
  animation:deal .9s cubic-bezier(.2,.8,.2,1) both; animation-delay:var(--d); }
.fcard-top{ position:relative; height:65%; border-radius:6px 6px 0 0; }
.fcard-top img{ position:absolute; left:6%; right:6%; top:8%; bottom:8%; width:88%; height:84%; object-fit:contain;
  filter:drop-shadow(0 6px 8px rgba(0,0,0,.28)); }
.fcard-label{ height:35%; background:#FAF9F6; border-radius:0 0 6px 6px; text-align:left; padding:9% 9% 0; color:#1E1A17; display:flex; flex-direction:column; }
.fcard-label b{ font-weight:800; font-size:calc(var(--cw) * .1); line-height:1.1; text-transform:uppercase; letter-spacing:.01em; }
.fcard-label span{ margin-top:auto; padding-bottom:12%; font-size:calc(var(--cw) * .075); color:#77706A; font-variant-numeric:tabular-nums; }
.fan.measure .fcard{ animation:none; }
.fan{ transform-origin:50% 0; }
@keyframes deal{
  from{ transform:translate(0, 34px) rotate(0deg); }
  to{ transform:translate(var(--x), var(--y)) rotate(var(--r)); }
}

.nolink{ min-height:100svh; background:var(--main); color:var(--onMain); display:flex; flex-direction:column; justify-content:center;
  padding-inline:16px; padding-block:40px; max-width:none; text-align:center; align-items:center; }
.nolink h1{ font-size:clamp(28px, 6vw, 40px); line-height:1.1; margin:0 0 12px; letter-spacing:-.015em; text-wrap:balance; }
.nolink p{ margin:0; color:var(--onMain-2); max-width:44ch; }
.nolink .byline{ margin-top:40px; color:var(--onMain-3); }

/* ---------- Home ---------- */
.home{ overflow-x:clip; }
.preview-bar{ margin:0; background:var(--hi); color:var(--onHi); text-align:center; font-weight:700; font-size:14px; padding-inline:16px; padding-block:max(8px, env(safe-area-inset-top)) 8px; }
.preview-bar:not([hidden]) + .bar{ padding-top:14px; }
.bar{ background:var(--main); color:var(--onMain); display:flex; align-items:center; justify-content:space-between; gap:12px;
  padding-inline:max(16px, calc((100% - 1040px) / 2)); padding-block:max(14px, env(safe-area-inset-top)) 14px;
  border-bottom:1px solid color-mix(in srgb, var(--onMain) 12%, var(--main)); }
.bar-who{ display:flex; align-items:baseline; gap:10px; flex-wrap:wrap; min-width:0; }
.bar-client{ font-weight:800; font-size:16.5px; }
.bar-project{ font-size:14px; color:var(--onMain-2); }
.bar-me{ display:flex; align-items:center; gap:8px; }
.avatar{ width:34px; height:34px; border-radius:50%; background:var(--hi); color:var(--onHi); display:grid; place-items:center; font-weight:800; font-size:15px; }

.hero{ background:var(--main); color:var(--onMain); position:relative; padding-inline:16px; padding-block:clamp(30px, 6vw, 64px) clamp(120px, 20vw, 92px); }
.hero-inner{ max-width:1040px; margin:0 auto; position:relative; display:grid; grid-template-columns:minmax(0, 1fr); }
.hero-copy{ position:relative; z-index:2; max-width:34rem; min-width:0; }
.hero-round{ margin:0 0 10px; display:inline-flex; align-items:center; gap:8px; font-size:13px; font-weight:700; letter-spacing:.1em; text-transform:uppercase; color:var(--onMain-2); }
.hero-round::before{ content:""; width:8px; height:8px; border-radius:50%; background:var(--hi); }
.hero-title{ margin:0; font-weight:800; font-size:clamp(36px, 7vw, 64px); line-height:1.02; letter-spacing:-.025em; text-wrap:balance; }
.hero-sub{ margin:14px 0 26px; font-size:clamp(17px, 2.2vw, 20px); color:var(--onMain-2); max-width:32ch; }

/* Real food on the brand colour, spilling over the hero's bottom edge into the page. */
.plate{ position:absolute; z-index:1; right:-24px; bottom:calc(-1 * clamp(150px, 24vw, 170px)); width:clamp(210px, 52vw, 470px); aspect-ratio:1; pointer-events:none; }
.plate img{ position:absolute; filter:drop-shadow(0 14px 16px rgba(0,0,0,.32)); animation:settle 1s cubic-bezier(.2,.8,.2,1) both; }
.plate .p-avocado{ width:44%; left:30%; top:4%; transform:rotate(-24deg); --from:rotate(-40deg) translateY(-30px); animation-delay:.05s; }
.plate .p-lemon{ width:40%; left:2%; top:30%; transform:rotate(8deg); --from:rotate(-10deg) translateY(-24px); animation-delay:.15s; }
.plate .p-salmon{ width:38%; left:60%; top:36%; transform:rotate(14deg); --from:rotate(30deg) translateY(-24px); animation-delay:.25s; }
.plate .p-blueberry{ width:42%; left:30%; top:56%; transform:rotate(-6deg); --from:rotate(10deg) translateY(-20px); animation-delay:.35s; }
.plate .p-chickpea{ width:9%; left:22%; top:76%; transform:rotate(20deg); --from:rotate(80deg) translateY(-40px); animation-delay:.5s; }
@keyframes settle{ from{ transform:var(--from); opacity:0; } }

.page{ max-width:1040px; margin:0 auto; padding-inline:16px; padding-block:0 56px; position:relative; z-index:2; }

.tally{ list-style:none; margin:-38px 0 0; padding:0; display:flex; flex-wrap:wrap; gap:8px; position:relative; z-index:3; max-width:calc(100% - clamp(120px, 26vw, 300px)); }
.tally li{ display:flex; align-items:center; gap:8px; background:var(--card); border-radius:999px; padding:9px 14px 9px 12px; font-size:14px; color:var(--muted);
  box-shadow:0 6px 18px -10px rgba(42,30,23,.45); }
.tally b{ font-weight:800; color:var(--text); font-variant-numeric:tabular-nums; }
.tally .dot{ width:10px; height:10px; border-radius:50%; flex:none; }

.round{ margin-top:clamp(56px, 9vw, 84px); }
.round-head{ display:flex; flex-direction:column; gap:4px; margin-bottom:18px; }
.round-head h2, .how h2, .ask h2{ margin:0; font-weight:800; font-size:clamp(24px, 3.4vw, 30px); letter-spacing:-.015em; line-height:1.15; }
.round-head p{ margin:0; color:var(--muted); font-size:16.5px; }

.items{ list-style:none; margin:0; padding:0; display:grid; grid-template-columns:repeat(auto-fill, minmax(min(100%, 232px), 1fr)); gap:16px; }
.item a{ display:flex; flex-direction:column; height:100%; background:var(--card); border-radius:var(--r); overflow:hidden; text-decoration:none;
  box-shadow:0 1px 2px rgba(42,30,23,.06), 0 12px 28px -18px rgba(42,30,23,.45); transition:transform .18s ease, box-shadow .18s ease; }
.item a:hover{ transform:translateY(-3px); box-shadow:0 1px 2px rgba(42,30,23,.06), 0 20px 36px -18px rgba(42,30,23,.5); }
.thumb{ position:relative; aspect-ratio:16/11; display:grid; place-items:center; }
.thumb img{ width:62%; height:78%; object-fit:contain; filter:drop-shadow(0 10px 12px rgba(0,0,0,.25)); transition:transform .3s ease; }
.item a:hover .thumb img{ transform:scale(1.05) rotate(-3deg); }
.item-body{ padding:14px 16px 16px; display:flex; flex-direction:column; gap:4px; flex:1; }
.item-title{ font-weight:800; font-size:18px; line-height:1.25; }
.item-line{ color:var(--muted); font-size:15px; margin:0; }
.pill{ align-self:flex-start; margin-top:10px; font-size:12.5px; font-weight:700; border-radius:999px; padding:5px 10px; }
.pill-ready{ background:var(--hi); color:var(--onHi); }
.pill-ok{ background:var(--acc); color:var(--onAcc); }
.pill-change{ background:var(--acc2); color:var(--onAcc2); }

/* On a phone the pieces read as a list: picture on the left, words on the right. */
@media (max-width:560px){
  .item a{ flex-direction:row; }
  .thumb{ aspect-ratio:auto; width:112px; flex:none; }
  .thumb img{ width:78%; height:72%; }
  .item-body{ padding:12px 14px 14px; }
  .item-title{ font-size:17px; }
  .item-line{ font-size:14.5px; }
  .pill{ margin-top:6px; }
  .tally{ max-width:none; margin-top:84px; }
  /* The food gets its own row under the button and spills over the brown band's edge. */
  .hero{ padding-block:28px 22px; }
  .plate{ position:relative; right:auto; bottom:auto; width:min(100%, 340px); aspect-ratio:2/1; margin:22px auto -74px; }
  .plate .p-lemon{ width:31%; left:0; top:24%; }
  .plate .p-avocado{ width:25%; left:25%; top:0; }
  .plate .p-salmon{ width:31%; left:68%; top:14%; }
  .plate .p-blueberry{ width:36%; left:38%; top:44%; }
  .plate .p-chickpea{ width:7%; left:27%; top:84%; }
  .tally li{ padding:7px 12px 7px 10px; font-size:13.5px; }
}

.how{ margin-top:56px; }
.steps{ list-style:none; margin:18px 0 0; padding:0; display:grid; grid-template-columns:repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap:14px; }
.steps li{ display:flex; gap:14px; align-items:flex-start; background:var(--soft); border-radius:var(--r); padding:16px; }
.step-n{ flex:none; width:32px; height:32px; border-radius:50%; background:var(--main); color:var(--onMain); display:grid; place-items:center; font-weight:800; font-variant-numeric:tabular-nums; }
.steps b{ font-weight:800; font-size:16.5px; }
.steps p{ margin:3px 0 0; color:var(--muted); font-size:15px; }

.ask{ margin-top:56px; max-width:640px; }
.ask form{ margin-top:14px; }
.ask textarea{ display:block; width:100%; min-height:96px; resize:vertical; font:16px/1.5 var(--font); color:var(--text);
  background:var(--card); border:1.5px solid var(--line); border-radius:12px; padding:12px 14px; }
.ask textarea:focus{ outline:none; border-color:var(--main); box-shadow:0 0 0 4px color-mix(in srgb, var(--main) 14%, transparent); }
.ask-row{ display:flex; align-items:center; gap:14px; flex-wrap:wrap; margin-top:10px; }
.ask-note{ color:var(--muted); font-size:14.5px; }

.byline-home{ margin-top:64px; color:var(--muted); text-align:center; }

.toast{ position:fixed; left:50%; bottom:max(20px, env(safe-area-inset-bottom)); transform:translateX(-50%); z-index:20;
  background:var(--text); color:var(--bg); border-radius:12px; padding:12px 16px; font-weight:600; font-size:15px; max-width:calc(100% - 32px);
  box-shadow:0 12px 30px -10px rgba(0,0,0,.5); }

/* ---------- A piece, opened ---------- */
.pill-coming{ background:var(--soft); color:var(--muted); }
.item-coming{ display:flex; flex-direction:column; height:100%; background:var(--card); border-radius:var(--r); overflow:hidden;
  box-shadow:0 1px 2px rgba(42,30,23,.06); }
.item-coming .thumb{ filter:saturate(.75); opacity:.85; }
@media (max-width:560px){ .item-coming{ flex-direction:row; } }

.piece{ max-width:1040px; margin:0 auto; padding-inline:16px; padding-block:22px 200px; }
.back{ display:inline-flex; gap:6px; align-items:center; font-weight:700; font-size:15px; color:var(--muted); text-decoration:none; padding:6px 0; }
.back:hover{ color:var(--text); text-decoration:underline; }
.piece-title-row{ display:flex; align-items:center; gap:12px; flex-wrap:wrap; margin:10px 0 18px; }
.piece-title-row h1{ margin:0; font-weight:800; font-size:clamp(34px, 6vw, 54px); line-height:1.02; letter-spacing:-.025em; }
.piece-title-row .pill{ margin-top:0; align-self:center; }
.note{ display:flex; gap:14px; align-items:flex-start; background:var(--card); border-radius:var(--r); padding:16px 18px; max-width:44rem;
  box-shadow:0 1px 2px rgba(42,30,23,.06), 0 10px 24px -18px rgba(42,30,23,.4); }
.note-who{ flex:none; width:36px; height:36px; border-radius:50%; background:var(--main); color:var(--onMain); display:grid; place-items:center; font-weight:800; }
.note-body b{ font-size:14px; font-weight:700; color:var(--muted); }
.note-body p{ margin:2px 0 0; font-size:17px; line-height:1.55; }

.pal-group{ margin-top:44px; }
.pal-group h2, .pal-example h2, .thread h2{ margin:0; font-weight:800; font-size:clamp(21px, 3vw, 25px); letter-spacing:-.01em; }
.pal-row{ display:grid; gap:12px; margin-top:14px; }
.pal-base{ grid-template-columns:2fr 1fr 1fr 1fr; }
.pal-food{ grid-template-columns:repeat(3, minmax(0, 1fr)); margin-top:22px; }
.sw{ position:relative; border-radius:var(--r); min-height:200px; padding:16px; display:flex; flex-direction:column; justify-content:space-between; gap:14px;
  box-shadow:inset 0 0 0 1px rgba(42,30,23,.1); min-width:0; }
.sw-hex{ font-size:13px; font-weight:600; letter-spacing:.05em; font-variant-numeric:tabular-nums; opacity:.78; }
.sw-name{ display:block; font-weight:800; font-size:clamp(18px, 2.4vw, 24px); line-height:1.1; }
.sw-job{ display:block; font-size:15px; font-weight:500; opacity:.85; margin-top:3px; }
.sw-food img{ position:absolute; right:-10px; top:-22px; width:min(52%, 150px); filter:drop-shadow(0 10px 12px rgba(0,0,0,.28)); }

.pal-example{ margin-top:52px; display:grid; grid-template-columns:auto minmax(0, 1fr); gap:clamp(24px, 5vw, 56px); align-items:center; }
.pal-example h2{ margin-bottom:12px; }
.uses{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:12px; }
.uses li{ display:flex; gap:12px; align-items:flex-start; font-size:16.5px; }
.uses .chip{ flex:none; width:22px; height:22px; border-radius:6px; box-shadow:inset 0 0 0 1px rgba(42,30,23,.12); margin-top:1px; }
.uses b{ font-weight:800; }
.pal-foot{ margin:18px 0 0; color:var(--muted); font-size:14.5px; }
.mock-cap{ text-align:center; font-size:13px; color:var(--muted); margin:10px 0 0; }

/* The example phone: the client app's own meal screen, drawn in the brand colours. */
.mock{ width:290px; max-width:100%; border-radius:34px; padding:10px; background:#141210; box-shadow:0 24px 44px -20px rgba(42,30,23,.6); }
.m-scr{ border-radius:26px; overflow:hidden; background:var(--bg); color:var(--text); display:flex; flex-direction:column; }
.m-bar{ background:var(--main); color:var(--onMain); padding:22px 18px 18px; }
.m-hi{ font-weight:700; font-size:19px; line-height:1.2; }
.m-sub{ font-size:12.5px; opacity:.85; margin-top:3px; }
.m-body{ padding:14px 14px 12px; display:flex; flex-direction:column; gap:12px; }
.m-tiles{ display:grid; grid-template-columns:1fr 1fr; gap:8px; }
.m-tile{ background:var(--card); border-radius:14px; padding:11px 11px 10px; box-shadow:0 1px 2px rgba(0,0,0,.06); }
.m-tile.on{ outline:2px solid var(--main); outline-offset:-2px; }
.m-tile svg{ width:22px; height:22px; color:var(--main); display:block; }
.m-t{ font-weight:600; font-size:14px; margin-top:7px; }
.m-n{ font-size:11.5px; color:var(--muted); }
.m-open{ background:var(--card); border-radius:14px; padding:12px; display:flex; flex-direction:column; gap:9px; box-shadow:0 1px 2px rgba(0,0,0,.06); }
.m-lbl{ font-size:11px; font-weight:600; letter-spacing:.06em; text-transform:uppercase; color:var(--muted); }
.m-rec{ font-weight:600; font-size:14.5px; line-height:1.3; }
.m-supp{ display:flex; gap:8px; align-items:center; background:var(--hi); color:var(--onHi); border-radius:10px; padding:8px 10px; font-size:12.5px; font-weight:600; }
.m-supp svg{ width:16px; height:16px; flex:none; }
.m-add{ display:flex; justify-content:center; align-items:center; gap:6px; background:var(--acc); color:var(--onAcc); border-radius:10px; padding:9px 10px; font-size:13px; font-weight:600; }
.m-tags{ display:flex; gap:6px; flex-wrap:wrap; }
.m-tag{ background:var(--acc2); color:var(--onAcc2); border-radius:999px; padding:4px 9px; font-size:11.5px; font-weight:600; }
.m-nav{ display:grid; grid-template-columns:repeat(3,1fr); background:var(--card); border-top:1px solid rgba(0,0,0,.06); padding:8px 6px 12px; }
.m-nav span{ text-align:center; font-size:11px; color:var(--muted); font-weight:500; }
.m-nav span.on{ color:var(--main); font-weight:700; }
.m-nav svg{ display:block; width:18px; height:18px; margin:0 auto 2px; }

.thread{ margin-top:52px; max-width:44rem; }
.thread-list{ list-style:none; margin:12px 0 0; padding:0; }
.thread-list li{ display:grid; grid-template-columns:30px minmax(0, 1fr); gap:12px; padding:14px 0; border-top:1px solid var(--line); }
.t-mark{ width:30px; height:30px; border-radius:50%; display:grid; place-items:center; font-weight:800; font-size:14px; }
.t-head{ margin:4px 0 0; font-size:15px; color:var(--muted); }
.t-head b{ color:var(--text); font-weight:700; }
.t-text{ margin:6px 0 0; font-size:16.5px; white-space:pre-wrap; overflow-wrap:anywhere; }
.t-wait{ margin:6px 0 0; font-size:14.5px; color:var(--muted); font-style:italic; }

/* The decision bar: fixed to the foot of the screen while a piece is open. */
.decide{ position:fixed; left:0; right:0; bottom:0; z-index:15; background:var(--card); border-top:1px solid var(--line);
  box-shadow:0 -14px 30px -22px rgba(42,30,23,.55);
  padding-inline:max(16px, calc((100% - 1040px) / 2)); padding-block:12px max(12px, env(safe-area-inset-bottom)); }
.decide-row{ display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; }
.decide-state{ margin:0; display:flex; align-items:center; gap:8px; font-weight:600; font-size:15px; color:var(--muted); min-width:0; }
.decide-state .dot{ width:10px; height:10px; border-radius:50%; flex:none; }
.decide-btns{ display:flex; gap:8px; }
.decide .btn{ font-size:16px; padding:13px 18px; }
.narrow{ display:none; }
.btn-ghost{ background:transparent; color:var(--text); box-shadow:inset 0 0 0 1.5px color-mix(in srgb, var(--text) 22%, transparent); }
.btn-ghost:hover{ box-shadow:inset 0 0 0 1.5px var(--text); }
.btn-ghost[aria-pressed="true"]{ background:var(--text); color:var(--card); box-shadow:none; }
.btn:disabled{ opacity:.55; cursor:default; transform:none; }
.composer{ margin-bottom:12px; }
.composer-label{ display:block; font-weight:800; font-size:16.5px; margin-bottom:8px; }
.composer textarea{ display:block; width:100%; min-height:88px; max-height:40vh; resize:vertical; font:16px/1.5 var(--font); color:var(--text);
  background:var(--bg); border:1.5px solid var(--line); border-radius:12px; padding:11px 13px; }
.composer textarea:focus{ outline:none; border-color:var(--main); background:var(--card); box-shadow:0 0 0 4px color-mix(in srgb, var(--main) 14%, transparent); }
.composer-row{ display:flex; align-items:center; gap:14px; flex-wrap:wrap; margin-top:10px; }
.link-dark{ color:var(--muted); }
.link-dark:hover{ color:var(--text); }
.composer-err{ color:#A3361A; font-weight:600; font-size:14.5px; }

/* The food colour cards, laid out on the brand colour like the header they came from. */
.fc-panel{ margin-top:36px; background:var(--main); border-radius:calc(var(--r) + 6px); padding:clamp(28px, 5vw, 56px) clamp(16px, 4vw, 48px); }
.fc-grid{ display:grid; grid-template-columns:repeat(6, minmax(0, 1fr)); gap:clamp(10px, 2vw, 22px); }
.fc-grid .fcard{ position:relative; left:auto; top:auto; margin:0; width:100%; transform:none; animation:none; --cw:100%; }
.fc-grid .fcard-label b{ font-size:clamp(11px, 1.3vw, 15px); }
.fc-grid .fcard-label span{ font-size:clamp(10px, 1.05vw, 12.5px); }
.fc-foot{ margin:16px 0 0; color:var(--muted); font-size:14.5px; }
@media (max-width:860px){ .fc-grid{ grid-template-columns:repeat(3, minmax(0, 1fr)); row-gap:28px; } }
@media (max-width:420px){ .fc-grid{ grid-template-columns:repeat(2, minmax(0, 1fr)); } }

@media (max-width:700px){
  .pal-base{ grid-template-columns:repeat(3, minmax(0, 1fr)); gap:8px; }
  .pal-base .sw:first-child{ grid-column:span 3; }
  .sw{ min-height:132px; }
  .pal-example{ grid-template-columns:minmax(0, 1fr); justify-items:center; }
  .pal-example > div:last-child{ justify-self:stretch; }
}
@media (max-width:560px){
  .pal-food{ gap:8px; }
  .pal-base .sw:not(:first-child){ padding:12px; }
  .pal-base .sw-job, .sw-food .sw-job{ font-size:13.5px; }
  /* On a phone the food sits centred above the words, and the colour code moves to the foot. */
  .sw-food{ padding:84px 12px 12px; min-height:0; justify-content:flex-end; }
  .sw-food img{ width:70%; left:50%; right:auto; top:-14px; transform:translateX(-50%); }
  .sw-food .sw-hex{ order:2; font-size:12px; }
  .wide{ display:none; }
  .narrow{ display:inline; }
  .decide-row{ flex-direction:column; align-items:stretch; gap:8px; }
  .decide-btns{ display:grid; grid-template-columns:1fr 1fr 1.15fr; }
  .decide .btn{ justify-content:center; padding:13px 8px; font-size:15.5px; }
  .decide-state{ font-size:14px; }
}

/* While a piece is open, messages sit above the decision bar instead of over it. */
body:has(#decide:not([hidden])) .toast{ bottom:calc(96px + env(safe-area-inset-bottom)); }
@media (max-width:560px){ body:has(#decide:not([hidden])) .toast{ bottom:calc(120px + env(safe-area-inset-bottom)); } }

@media (prefers-reduced-motion: reduce){
  .fcard, .plate img{ animation:none; }
  .btn, .item a, .thumb img{ transition:none; }
  .btn:hover{ transform:none; }
}
