:root {
  --bg: #FBF6EE;
  --bg-2: #F3E9DA;
  --card: #FFFFFF;
  --ink: #1F1A16;
  --muted: #6E655C;
  --line: #E7DCCB;
  --red: #D62839;
  --red-soft: #FBE3E5;
  --mustard: #F4B23E;
  --navy: #1D3E6E;
  --plate: #FFFFFF;
  --plate-rim: #EFE8DE;
  --tint-s: 85%;
  --tint-l: 91%;
  --shadow: 0 1px 2px rgba(70, 45, 20, .06), 0 10px 30px -12px rgba(70, 45, 20, .22);
  --shadow-lg: 0 30px 60px -20px rgba(40, 25, 10, .35);
  --r: 22px;
  --hdr: 64px;
  --display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --sans: 'DM Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --emoji: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif;
  color-scheme: light;
}

/* dark theme — used when the OS asks for it, unless the user picked light */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #15110E; --bg-2: #1D1814; --card: #221C17; --ink: #F5EEE4; --muted: #A99E91;
    --line: #362D25; --red: #FF5263; --red-soft: #3A1C20; --mustard: #F6C35B; --navy: #9DB9E8;
    --plate: #F3ECE2; --plate-rim: #DCD2C5; --tint-s: 32%; --tint-l: 19%;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 10px 30px -12px rgba(0,0,0,.6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #15110E; --bg-2: #1D1814; --card: #221C17; --ink: #F5EEE4; --muted: #A99E91;
  --line: #362D25; --red: #FF5263; --red-soft: #3A1C20; --mustard: #F6C35B; --navy: #9DB9E8;
  --plate: #F3ECE2; --plate-rim: #DCD2C5; --tint-s: 32%; --tint-l: 19%;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 10px 30px -12px rgba(0,0,0,.6);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--hdr) + 120px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.locked { overflow: hidden; }

h1, h2, h3 { font-family: var(--display); line-height: 1.08; margin: 0; letter-spacing: -.01em; }
em { font-style: italic; color: var(--red); }
p { margin: 0; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--mustard); outline-offset: 2px; border-radius: 8px; }

.wrap { width: min(1200px, 100%); margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 28px; } }

.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--bg); padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 22px;
  border-radius: 999px; border: 2px solid transparent;
  font-weight: 700; text-decoration: none; white-space: nowrap;
  transition: transform .15s, background-color .2s, box-shadow .2s;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--red); color: #fff; box-shadow: 0 6px 18px -6px color-mix(in srgb, var(--red) 70%, transparent); }
.btn-primary:hover { background: color-mix(in srgb, var(--red) 88%, #000); }
.btn-ghost { background: transparent; border-color: var(--ink); }
.btn-ghost:hover { background: var(--ink); color: var(--bg); }

.icon-btn {
  position: relative; display: grid; place-items: center;
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--card);
  transition: transform .15s, background-color .2s;
}
.icon-btn:hover { background: var(--bg-2); }
.icon-btn:active { transform: scale(.92); }

/* the plate look, reused everywhere */
.plate {
  --ps: 120px;
  width: var(--ps); height: var(--ps); flex: none;
  display: grid; place-items: center; border-radius: 50%;
  background: radial-gradient(circle, var(--plate) 0 52%, var(--plate-rim) 53% 60%, var(--plate) 61%);
  box-shadow: 0 12px 24px -10px rgba(40, 20, 0, .4), inset 0 -3px 6px rgba(0, 0, 0, .06);
}
.food {
  font-family: var(--emoji); font-size: calc(var(--ps) * .46); line-height: 1;
  filter: drop-shadow(0 6px 5px rgba(0, 0, 0, .22));
  user-select: none;
}

/* red/white tablecloth strip */
.gingham {
  height: 22px;
  background:
    repeating-linear-gradient(90deg, color-mix(in srgb, var(--red) 55%, transparent) 0 11px, transparent 11px 22px),
    repeating-linear-gradient(0deg, color-mix(in srgb, var(--red) 55%, transparent) 0 11px, transparent 11px 22px),
    var(--bg);
}

/* hidden only until the intro kicks in (see index.html) */
.preload .topbar, .preload .hero-in { visibility: hidden; }

/* header */
.topbar {
  position: sticky; top: 0; z-index: 30; height: var(--hdr);
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s;
}
.topbar.scrolled { border-color: var(--line); }
.topbar-in { height: 100%; display: flex; align-items: center; justify-content: space-between; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 800 1.25rem/1 var(--display); }
.logo i { color: var(--red); }
.logo-mark {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px;
  background: var(--red); color: #fff; font: 800 20px/1 var(--display); transform: rotate(-8deg);
}
.top-actions { display: flex; align-items: center; gap: 8px; }
.nav-link { padding: 8px 12px; border-radius: 999px; text-decoration: none; font-weight: 500; }
.nav-link:hover { background: var(--bg-2); }
#savedBtn { color: var(--red); }
.count {
  position: absolute; top: -4px; right: -4px; min-width: 20px; height: 20px; padding: 0 5px;
  border-radius: 10px; background: var(--ink); color: var(--bg);
  font-size: 11px; font-weight: 700; line-height: 20px; text-align: center;
}
.count:empty, .count[data-n="0"] { display: none; }
.moon { display: none; }
:root[data-theme="dark"] .sun { display: none; }
:root[data-theme="dark"] .moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .sun { display: none; }
  :root:not([data-theme="light"]) .moon { display: block; }
}

/* hero */
.hero { position: relative; overflow: hidden; }
.hero-in {
  display: grid; grid-template-columns: 1.1fr .9fr; align-items: center; gap: 40px;
  padding-top: 48px; padding-bottom: 64px;
}
.kicker {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px;
  background: var(--card); border: 1px solid var(--line); font-size: .875rem; font-weight: 500;
}
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 4px var(--red-soft); }
.hero-title { margin: 22px 0 18px; font-size: clamp(2.6rem, 5.4vw + .6rem, 5.4rem); font-weight: 800; }
.hero-title .line { display: block; overflow: hidden; padding-bottom: .06em; }
.hero-title .line > span { display: inline-block; }
.hero-sub { max-width: 34em; font-size: 1.125rem; color: var(--muted); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.stats { display: flex; gap: 32px; margin: 36px 0 0; padding: 0; list-style: none; }
.stats b { display: block; font: 800 2rem/1 var(--display); }
.stats span { font-size: .875rem; color: var(--muted); }

.hero-art { position: relative; aspect-ratio: 1; max-width: 520px; width: 100%; justify-self: center; }
.hero-art::before {
  content: ''; position: absolute; inset: 8%; border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--mustard) 45%, transparent), transparent 70%);
}
.big-plate {
  position: absolute; inset: 0; display: grid; place-items: center; align-content: center; gap: 18px;
  border: 0; background: none; cursor: pointer;
}
.big-plate .plate { --ps: clamp(200px, 26vw, 300px); }
.now-serving {
  padding: 8px 16px; border-radius: 999px; background: var(--ink); color: var(--bg);
  font-size: .875rem; white-space: nowrap;
}
.mini { position: absolute; --ps: clamp(64px, 8vw, 92px); }
.m1 { top: 4%; left: 6%; }
.m2 { top: 2%; right: 10%; }
.m3 { bottom: 16%; right: 0; }
.m4 { bottom: 10%; left: 2%; }
.m5 { top: 42%; left: -4%; --ps: clamp(54px, 6vw, 72px); }

/* recipe of the day */
.featured { margin-top: 56px; }
.feat-card {
  --h: 20;
  position: relative; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 28px;
  padding: 28px 32px; border-radius: 28px;
  background: hsl(var(--h) var(--tint-s) var(--tint-l));
  overflow: hidden;
}
.feat-card .plate { --ps: 140px; }
.feat-label { display: inline-block; margin-bottom: 8px; font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--red); }
.feat-card h2 { font-size: clamp(1.6rem, 2.6vw, 2.4rem); }
.feat-card p { margin-top: 8px; color: var(--muted); max-width: 40em; }

/* toolbar */
.browse { margin-top: 64px; }
.toolbar {
  position: sticky; top: var(--hdr); z-index: 20;
  padding: 12px 0 10px;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.toolbar-row { display: flex; gap: 10px; }
.search {
  flex: 1; display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 16px;
  border-radius: 999px; background: var(--card); border: 1px solid var(--line); color: var(--muted);
  transition: border-color .2s, box-shadow .2s;
}
.search:focus-within { border-color: var(--ink); box-shadow: 0 0 0 4px color-mix(in srgb, var(--mustard) 35%, transparent); }
.search input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; color: var(--ink); font-size: 1rem; }
.search input::-webkit-search-cancel-button { cursor: pointer; }
kbd { padding: 2px 8px; border-radius: 6px; border: 1px solid var(--line); font: 600 .75rem var(--sans); }
.sort {
  min-height: 48px; padding: 0 38px 0 16px; border-radius: 999px; border: 1px solid var(--line);
  background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23887' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 16px center;
  appearance: none; -webkit-appearance: none; cursor: pointer; font-weight: 500;
}
.chips {
  display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; scrollbar-width: none;
  scroll-snap-type: x proximity; padding-bottom: 2px;
}
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 16px;
  border-radius: 999px; border: 1px solid var(--line); background: var(--card);
  font-weight: 500; font-size: .9375rem; scroll-snap-align: start;
  transition: background-color .2s, color .2s, border-color .2s;
}
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chip .e { font-family: var(--emoji); }
.chip-sep { flex: none; width: 1px; margin: 8px 2px; background: var(--line); }

.result-count { margin: 20px 0 14px; color: var(--muted); font-size: .9375rem; }

/* recipe grid */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; }
.card {
  --h: 20;
  position: relative; display: flex; flex-direction: column;
  background: var(--card); border-radius: var(--r); overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform .25s cubic-bezier(.2, .8, .2, 1), box-shadow .25s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.card-media {
  position: relative; display: grid; place-items: center; aspect-ratio: 4 / 3;
  background: hsl(var(--h) var(--tint-s) var(--tint-l));
}
.card-media .plate { width: auto; height: 64%; aspect-ratio: 1; }
.card-media .food { font-size: clamp(44px, 5.6vw, 70px); transition: transform .35s cubic-bezier(.3, 1.6, .5, 1); }
.card:hover .card-media .food { transform: scale(1.12) rotate(-6deg); }
.badge {
  position: absolute; left: 12px; bottom: 12px; padding: 4px 10px; border-radius: 999px;
  background: var(--card); font-size: .78rem; font-weight: 700;
}
.card-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.eyebrow { font-size: .72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--red); }
.card h3 { font-size: 1.3rem; font-weight: 600; }
.card-link { text-decoration: none; }
.card-link::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.region { color: var(--muted); font-size: .875rem; }
.meta { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 10px; font-size: .85rem; color: var(--muted); }
.lvl { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; color: var(--ink); }
.lvl i { display: inline-flex; gap: 3px; }
.lvl i::before, .lvl i::after, .lvl i span { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--line); }
.lvl i span { display: block; }
.lvl[data-l="1"] i::before,
.lvl[data-l="2"] i::before, .lvl[data-l="2"] i span,
.lvl[data-l="3"] i::before, .lvl[data-l="3"] i span, .lvl[data-l="3"] i::after { background: var(--red); }

.fav {
  position: absolute; top: 10px; right: 10px; z-index: 2;
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; border: 0;
  background: var(--card); color: var(--muted); box-shadow: 0 4px 10px -4px rgba(0, 0, 0, .3);
  transition: transform .15s, color .2s;
}
.fav:active { transform: scale(.85); }
.fav[aria-pressed="true"] { color: var(--red); }
.fav svg { width: 20px; height: 20px; }
.fav path { fill: none; stroke: currentColor; stroke-width: 2; }
.fav[aria-pressed="true"] path { fill: currentColor; }

.empty { display: grid; justify-items: center; gap: 10px; padding: 48px 0; text-align: center; }
.empty .plate { --ps: 110px; margin-bottom: 8px; }
.empty p { color: var(--muted); margin-bottom: 8px; }

/* how it works */
.how { margin-top: 96px; }
.section-title { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 28px; }
.how-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.how-card { padding: 28px; border-radius: var(--r); background: var(--card); box-shadow: var(--shadow); }
.how-card h3 { font-size: 1.35rem; margin: 16px 0 8px; }
.how-card p { color: var(--muted); }
.how-num {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px;
  background: var(--mustard); color: #1F1A16; font: 800 1.2rem var(--display);
}

.footer { margin-top: 96px; }
.footer-in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding-top: 28px; padding-bottom: calc(28px + env(safe-area-inset-bottom)); }
.footer p { color: var(--muted); font-size: .9375rem; }

/* recipe sheet */
.sheet { position: fixed; inset: 0; z-index: 50; display: flex; align-items: flex-end; justify-content: center; }
.sheet-backdrop { position: absolute; inset: 0; background: rgba(20, 12, 5, .55); backdrop-filter: blur(3px); }
.sheet-panel {
  --h: 20;
  position: relative; display: flex; flex-direction: column;
  width: min(1080px, 100%); height: 96dvh;
  background: var(--bg); border-radius: 28px 28px 0 0; overflow: hidden;
  box-shadow: var(--shadow-lg);
}
@media (min-width: 900px) {
  .sheet { align-items: center; }
  .sheet-panel { height: min(92dvh, 980px); border-radius: 28px; }
}
.sheet-top {
  position: absolute; top: 0; left: 0; right: 0; z-index: 3;
  display: flex; align-items: center; justify-content: space-between; padding: 12px 14px;
  pointer-events: none;
}
.sheet-top > * { pointer-events: auto; }
.sheet-top { transition: background-color .2s, box-shadow .2s; }
.sheet-top.solid { background: var(--bg); box-shadow: 0 1px 0 var(--line); pointer-events: auto; }
.sheet-tools { display: flex; gap: 8px; }
.grab { width: 44px; height: 5px; border-radius: 3px; background: color-mix(in srgb, var(--ink) 25%, transparent); }
@media (min-width: 900px) { .grab { visibility: hidden; } }
.sheet-scroll { flex: 1; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }

.d-hero {
  display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 32px;
  padding: 72px 40px 36px; background: hsl(var(--h) var(--tint-s) var(--tint-l));
}
.d-hero .plate { --ps: 200px; }
.d-hero h2 { font-size: clamp(2rem, 4.4vw, 3.4rem); font-weight: 800; margin: 6px 0 6px; }
.d-region { color: var(--muted); font-weight: 500; }
.d-desc { margin-top: 12px; max-width: 38em; font-size: 1.0625rem; }
.d-meta { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 20px; max-width: 560px; }
.d-meta div { padding: 10px 12px; border-radius: 14px; background: color-mix(in srgb, var(--card) 75%, transparent); }
.d-meta small { display: block; font-size: .7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.d-meta b { font-size: 1rem; }
.d-extra { margin-top: 10px; font-size: .875rem; color: var(--muted); }
.d-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.d-actions .fav-big[aria-pressed="true"] { background: var(--red-soft); border-color: var(--red); color: var(--red); }

.d-body { display: grid; grid-template-columns: 340px 1fr; gap: 40px; padding: 36px 40px 24px; align-items: start; }
.d-ing { position: sticky; top: 16px; padding: 22px; border-radius: var(--r); background: var(--card); box-shadow: var(--shadow); }
.d-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.d-body h3 { font-size: 1.5rem; }
.stepper { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; }
.stepper button { width: 36px; height: 36px; border: 0; background: none; font-size: 1.15rem; font-weight: 700; border-radius: 50%; }
.stepper button:hover { background: var(--bg-2); }
.stepper output { min-width: 64px; text-align: center; font-size: .875rem; font-weight: 600; }
.ing-group { margin: 16px 0 6px; font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--red); }
.ing-list { list-style: none; margin: 0; padding: 0; }
.ing-list label {
  display: flex; gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--line); cursor: pointer;
  line-height: 1.4;
}
.ing-list li:last-child label { border-bottom: 0; }
.ing-list input { appearance: none; -webkit-appearance: none; flex: none; width: 20px; height: 20px; margin: 1px 0 0; border: 2px solid var(--line); border-radius: 6px; display: grid; place-items: center; transition: background-color .15s, border-color .15s; cursor: pointer; }
.ing-list input:checked { background: var(--red); border-color: var(--red); }
.ing-list input:checked::after { content: ''; width: 5px; height: 10px; border: solid #fff; border-width: 0 2px 2px 0; transform: translateY(-1px) rotate(45deg); }
.ing-list input:checked + span { color: var(--muted); text-decoration: line-through; }
.qty { font-weight: 700; }
.ing-reset { margin-top: 12px; border: 0; background: none; color: var(--muted); font-size: .875rem; text-decoration: underline; padding: 0; }

.steps { list-style: none; margin: 16px 0 0; padding: 0; counter-reset: s; }
.steps li {
  counter-increment: s; position: relative; padding: 16px 16px 16px 64px; margin-bottom: 10px;
  border-radius: 18px; background: var(--card); box-shadow: var(--shadow); cursor: pointer;
  transition: opacity .2s;
}
.steps li::before {
  content: counter(s); position: absolute; left: 16px; top: 14px;
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
  background: var(--ink); color: var(--bg); font: 800 1rem var(--display);
}
.steps li.done { opacity: .5; }
.steps li.done::before { content: '✓'; background: var(--red); color: #fff; }
.steps li.done p { text-decoration: line-through; text-decoration-color: var(--muted); }
.timer-chip {
  position: relative; z-index: 1;
  display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; padding: 6px 12px;
  border-radius: 999px; border: 1px solid var(--line); background: var(--bg); font-size: .85rem; font-weight: 600;
}
.timer-chip:hover { border-color: var(--red); color: var(--red); }

.d-box { margin-top: 28px; padding: 22px; border-radius: var(--r); }
.d-tips { background: color-mix(in srgb, var(--mustard) 22%, var(--card)); }
.d-tips ul { margin: 10px 0 0; padding-left: 20px; }
.d-tips li { margin: 6px 0; }
.d-story { background: var(--card); border: 1px dashed var(--line); }
.d-story p { margin-top: 8px; color: var(--muted); }

.d-more { padding: 12px 40px 48px; }
.d-more h3 { font-size: 1.5rem; margin-bottom: 16px; }
.more-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.more-card {
  --h: 20;
  display: flex; align-items: center; gap: 14px; padding: 12px; border-radius: 18px; text-decoration: none;
  background: hsl(var(--h) var(--tint-s) var(--tint-l)); transition: transform .2s;
}
.more-card:hover { transform: translateY(-3px); }
.more-card .plate { --ps: 60px; }
.more-card b { display: block; font-family: var(--display); font-weight: 600; line-height: 1.2; }
.more-card small { color: var(--muted); }

/* cook mode — always dark, easier to read from across the kitchen */
.cook {
  position: fixed; inset: 0; z-index: 60; display: flex; flex-direction: column;
  background: #15110E; color: #F7F0E6;
  padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
  --line: #3A3029; --card: #241D18; --bg-2: #2C241E; --ink: #F7F0E6; --bg: #15110E;
}
.cook-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; }
.cook-title { text-align: center; min-width: 0; }
.cook-title small { display: block; font-size: .7rem; letter-spacing: .14em; text-transform: uppercase; color: var(--mustard); }
.cook-title b { display: block; font-family: var(--display); font-size: 1.1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cook-progress { height: 4px; margin: 0 16px; border-radius: 2px; background: #3A3029; overflow: hidden; }
.cook-progress span { display: block; height: 100%; width: 0; background: var(--mustard); border-radius: 2px; transition: width .4s ease; }
.cook-ing {
  margin: 14px 16px 0; max-height: 40dvh; overflow-y: auto; padding: 8px 18px;
  border-radius: 18px; background: #241D18;
}
.cook-ing .ing-list label { border-color: #3A3029; }
.cook-stage {
  flex: 1; display: flex; flex-direction: column; justify-content: center; align-items: flex-start;
  width: min(820px, 100%); margin: 0 auto; padding: 24px 24px; overflow-y: auto;
}
.cook-count { font: 600 1rem var(--display); font-style: italic; color: var(--mustard); margin-bottom: 14px; }
.cook-text { font: 600 clamp(1.5rem, 3.4vw + .6rem, 2.6rem)/1.3 var(--display); }
.timer-btn { margin-top: 28px; background: var(--mustard); color: #1F1A16; }
.cook-nav { display: grid; grid-template-columns: 1fr 2fr; gap: 12px; width: min(820px, 100%); margin: 0 auto; padding: 12px 16px 16px; }
.cook-nav .btn { min-height: 58px; font-size: 1.05rem; }
.cook .btn-ghost { border-color: #4A3F36; color: #F7F0E6; }
.cook .btn-ghost:disabled { opacity: .35; pointer-events: none; }
.cook-hint { text-align: center; padding-bottom: 12px; font-size: .8rem; color: #8C8076; }
.confetti { position: fixed; z-index: 90; pointer-events: none; font-family: var(--emoji); font-size: 28px; left: 50%; top: 55%; }

/* timer pill */
.timer-pill {
  position: fixed; z-index: 70; left: 50%; bottom: calc(16px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 16px; max-width: calc(100% - 32px);
  border-radius: 999px; background: #1F1A16; color: #FBF6EE; box-shadow: 0 14px 30px -10px rgba(0, 0, 0, .5);
}
.timer-pill.ringing { background: var(--red); animation: shake .5s infinite; }
@keyframes shake { 25% { transform: translateX(calc(-50% - 3px)); } 75% { transform: translateX(calc(-50% + 3px)); } }
.t-ring { width: 10px; height: 10px; border-radius: 50%; background: var(--mustard); flex: none; }
.timer-pill.paused .t-ring { background: #8C8076; }
.t-label { font-size: .85rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; color: #CFC4B8; }
.t-time { font: 700 1.15rem var(--sans); font-variant-numeric: tabular-nums; }
.timer-pill button { width: 34px; height: 34px; flex: none; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .12); color: inherit; font-size: .75rem; }
.timer-pill button:hover { background: rgba(255, 255, 255, .22); }

.toast {
  position: fixed; z-index: 80; left: 50%; top: calc(var(--hdr) + 12px); transform: translate(-50%, -20px);
  padding: 10px 18px; border-radius: 999px; background: var(--ink); color: var(--bg);
  font-weight: 600; font-size: .9375rem; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s;
  white-space: nowrap;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* tablet */
@media (max-width: 960px) {
  .hero-in { grid-template-columns: 1fr; padding-top: 28px; gap: 8px; }
  .hero-art { max-width: 400px; order: -1; }
  .d-body { grid-template-columns: 1fr; gap: 28px; }
  .d-ing { position: static; }
  .how-grid { grid-template-columns: 1fr; }
}

/* phones */
@media (max-width: 640px) {
  :root { --hdr: 58px; }
  .hide-sm { display: none !important; }
  .hero-art { max-width: 300px; }
  .big-plate .plate { --ps: 170px; }
  .mini { --ps: 56px; }
  .m1 { top: 2%; left: 0; }
  .m2 { top: 4%; right: 0; }
  .m3 { top: 46%; bottom: auto; right: -6px; }
  .m4 { top: 52%; bottom: auto; left: -6px; }
  .m5 { display: none; }
  .hero-title { margin-top: 16px; }
  .hero-sub { font-size: 1rem; }
  .hero-cta .btn { flex: 1; }
  .stats { gap: 22px; }
  .stats b { font-size: 1.6rem; }

  .featured { margin-top: 40px; }
  .feat-card { grid-template-columns: auto 1fr; gap: 16px; padding: 20px; }
  .feat-card .plate { --ps: 84px; }
  .feat-card p { display: none; }
  .feat-card .btn { grid-column: 1 / -1; }

  .browse { margin-top: 44px; }
  .sort { width: 48px; padding: 0; color: transparent; background-position: center; }
  .sort option { color: var(--ink); }

  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .card { border-radius: 18px; }
  .card-body { padding: 12px 12px 14px; }
  .card h3 { font-size: 1.05rem; }
  .eyebrow { font-size: .62rem; }
  .region { font-size: .78rem; }
  .meta { font-size: .75rem; }
  .meta .serves { display: none; }
  .badge { left: 8px; bottom: 8px; font-size: .7rem; padding: 3px 8px; }
  .fav { width: 34px; height: 34px; top: 8px; right: 8px; }
  .fav svg { width: 17px; height: 17px; }

  .d-hero { grid-template-columns: 1fr; justify-items: center; text-align: center; padding: 64px 16px 24px; gap: 14px; }
  .d-hero .plate { --ps: 140px; }
  .d-meta { grid-template-columns: repeat(2, 1fr); margin-left: auto; margin-right: auto; }
  .d-actions { justify-content: center; }
  .d-actions .btn { flex: 1; }
  .d-body { padding: 24px 16px; }
  .d-ing { padding: 18px; }
  .steps li { padding: 14px 14px 14px 56px; }
  .steps li::before { left: 12px; width: 30px; height: 30px; font-size: .9rem; }
  .d-more { padding: 8px 16px 40px; }
  .more-row { grid-template-columns: 1fr; }
  .how-card { padding: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation: none !important; }
}

@media print {
  body > *:not(#sheet) { display: none !important; }
  .sheet { position: static; display: block; }
  .sheet-backdrop, .sheet-top, .d-actions, .d-more, .timer-chip { display: none !important; }
  .sheet-panel { height: auto; box-shadow: none; border-radius: 0; }
  .sheet-scroll { overflow: visible; }
  .d-body { grid-template-columns: 1fr 1.6fr; }
  .steps li, .d-ing { box-shadow: none; border: 1px solid #ddd; }
}
