/*
 * Recipes — layout and components.
 *
 * Every colour, font and corner radius comes from a custom property set by
 * the active theme (assets/js/themes.js). The values below are the default
 * "Farmhouse" theme, used until the scripts load.
 */

:root {
  --bg: #f6efe4;
  --surface: #fffaf2;
  --surface-2: #f3e9da;
  --text: #3a2e24;
  --muted: #8a7563;
  --line: #e8dbc8;
  --accent: #c0623b;
  --accent-ink: #ffffff;
  --soft: #f6dccd;
  --star: #e0a526;
  --danger: #b83a2e;
  /* Favourites. Shared by every theme, so a heart always reads as a heart. */
  --heart: #e0476b;
  --radius: 16px;
  --font-head: Georgia, serif;
  --font-body: system-ui, -apple-system, 'Segoe UI', sans-serif;
  --head-scale: 1;
  --head-weight: 700;

  --radius-sm: calc(var(--radius) * 0.6);
  --shadow: 0 1px 2px color-mix(in srgb, var(--text) 8%, transparent), 0 6px 20px -8px color-mix(in srgb, var(--text) 18%, transparent);
  --shadow-lift: 0 2px 4px color-mix(in srgb, var(--text) 8%, transparent), 0 14px 32px -10px color-mix(in srgb, var(--text) 28%, transparent);
  --gutter: clamp(16px, 4vw, 32px);
  --max: 1180px;
  --tap: 44px;
  --ease: cubic-bezier(.2, .7, .2, 1);

  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--bg);
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: anywhere;
}

/* The notebook theme's ruled paper. */
html[data-paper="1"] body {
  background-image: repeating-linear-gradient(to bottom, transparent 0, transparent 31px, color-mix(in srgb, var(--accent) 12%, transparent) 31px, color-mix(in srgb, var(--accent) 12%, transparent) 32px);
  background-attachment: fixed;
}

html.modal-open { overflow: hidden; }

h1, h2, h3 {
  font-family: var(--font-head);
  font-weight: var(--head-weight);
  line-height: 1.15;
  margin: 0;
  letter-spacing: -0.01em;
  overflow-wrap: break-word;
}

h1 { font-size: calc(clamp(1.9rem, 5vw, 2.8rem) * var(--head-scale)); }
h2 { font-size: calc(1.35rem * var(--head-scale)); }
h3 { font-size: calc(1.02rem * var(--head-scale)); }

p { margin: 0; }
a { color: var(--accent); }
img { max-width: 100%; display: block; }

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
/* Long unbroken words (URLs) may break anywhere in text, but never in controls. */
button, .btn, .chip, .pill, .tp-row { overflow-wrap: normal; }
button:disabled { cursor: default; }

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 60%, transparent);
  outline-offset: 2px;
}

.icon { flex: none; display: block; }
.hint { color: var(--muted); font-size: 0.88rem; }
.hint.inline { font-weight: 400; }
.muted { color: var(--muted); }
.spacer { flex: 1; }
[hidden] { display: none !important; }

/* ---------------------------------------------------------------- buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  min-height: var(--tap);
  padding: 0.55em 1.1em;
  border-radius: 999px;
  border: 1.5px solid transparent;
  background: var(--surface-2);
  color: var(--text);
  font-weight: 700;
  font-size: 0.97rem;
  text-decoration: none;
  line-height: 1.2;
  transition: transform 0.12s var(--ease), background 0.15s, box-shadow 0.15s;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}
.btn:active:not(:disabled) { transform: scale(0.97); }
.btn:disabled { opacity: 0.55; }
.btn.primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 4px 14px -6px var(--accent); }
.btn.primary:hover:not(:disabled) { background: color-mix(in srgb, var(--accent) 88%, black); }
.btn.soft { background: var(--soft); color: color-mix(in srgb, var(--accent) 70%, var(--text)); }
.btn.soft:hover:not(:disabled) { background: color-mix(in srgb, var(--soft) 80%, var(--accent)); }
.btn.ghost { background: transparent; border-color: var(--line); }
.btn.ghost:hover { background: var(--surface-2); }
.btn.danger { background: var(--danger); color: #fff; }
.btn.big { min-height: 52px; padding: 0.7em 1.4em; font-size: 1.02rem; }
.btn.small { min-height: 36px; padding: 0.35em 0.9em; font-size: 0.9rem; }
.danger-text { color: var(--danger) !important; }

.btn.busy { position: relative; color: transparent !important; }
.btn.busy::after {
  content: '';
  position: absolute;
  width: 20px; height: 20px;
  border-radius: 50%;
  border: 2.5px solid currentColor;
  border-color: var(--accent-ink) transparent var(--accent-ink) transparent;
  animation: spin 0.8s linear infinite;
}
.btn.soft.busy::after, .btn.ghost.busy::after { border-color: var(--accent) transparent var(--accent) transparent; }

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: var(--tap);
  height: var(--tap);
  border-radius: 999px;
  border: 0;
  background: transparent;
  color: var(--text);
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}
.icon-btn:hover:not(:disabled) { background: var(--surface-2); }
.icon-btn:disabled { opacity: 0.35; }
.icon-btn.bordered { border: 1.5px solid var(--line); }

.link-btn {
  border: 0;
  background: none;
  padding: 0.25em 0.4em;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.button-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

.spinner {
  display: inline-block;
  width: 22px; height: 22px;
  border-radius: 50%;
  border: 3px solid var(--line);
  border-top-color: var(--accent);
  animation: spin 0.8s linear infinite;
}
.spinner.large { width: 40px; height: 40px; border-width: 4px; }
@keyframes spin { to { transform: rotate(360deg); } }

.boot { min-height: 70vh; display: grid; place-items: center; }

/* ------------------------------------------------------------------ chips */

.chips { display: flex; flex-wrap: wrap; gap: 8px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  min-height: 36px;
  padding: 0.3em 0.85em;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--surface);
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  line-height: 1.2;
  -webkit-tap-highlight-color: transparent;
}
.chip:hover { border-color: color-mix(in srgb, var(--accent) 50%, var(--line)); }
.chip[aria-pressed="true"], .chip.on {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.chip.small { min-height: 30px; font-size: 0.85rem; padding: 0.2em 0.7em; }
.chip.off { text-decoration: line-through; opacity: 0.5; border-style: dashed; }
.chip-count { font-size: 0.78em; opacity: 0.6; font-weight: 700; }
.chip.removable .icon { opacity: 0.8; }

.badge {
  display: inline-grid;
  place-items: center;
  min-width: 20px; height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 0.75rem;
}

.segmented {
  display: inline-flex;
  padding: 3px;
  border-radius: 999px;
  background: var(--surface-2);
  gap: 2px;
}
.segmented button {
  border: 0;
  background: transparent;
  border-radius: 999px;
  padding: 0.4em 0.9em;
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--muted);
  min-height: 36px;
}
.segmented button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow); }
.segmented.small button { min-height: 30px; padding: 0.25em 0.7em; font-size: 0.82rem; }

/* ----------------------------------------------------------------- header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: calc(10px + env(safe-area-inset-top)) max(var(--gutter), env(safe-area-inset-right)) 10px max(var(--gutter), env(safe-area-inset-left));
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent);
}
html.cooking .site-header { display: none; }

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  min-width: 0;
  margin-right: auto;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  border-radius: 12px;
  background: var(--accent);
  color: var(--accent-ink);
  flex: none;
}
.brand-text { display: flex; flex-direction: column; min-width: 0; }
.brand-title { font-family: var(--font-head); font-weight: var(--head-weight); font-size: calc(1.3rem * var(--head-scale)); line-height: 1.1; }
.brand-sub { font-size: 0.8rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.header-actions { display: flex; align-items: center; gap: 4px; flex: none; }
.add-btn { margin-right: 6px; }

@media (max-width: 520px) {
  .brand-sub { display: none; }
  .add-btn .label { display: none; }
  .add-btn { width: var(--tap); padding: 0; }
}

/* ------------------------------------------------------------------ pages */

.page {
  max-width: var(--max);
  margin: 0 auto;
  padding: 20px max(var(--gutter), env(safe-area-inset-right)) calc(96px + env(safe-area-inset-bottom)) max(var(--gutter), env(safe-area-inset-left));
}

.back {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  min-height: var(--tap);
}
.back:hover { color: var(--text); }

.lede { color: var(--muted); font-size: 1.08rem; margin-top: 8px; max-width: 60ch; }

.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
  padding: 56px 16px;
  color: var(--muted);
}
.empty h2 { color: var(--text); }
.empty-art {
  display: grid;
  place-items: center;
  width: 84px; height: 84px;
  border-radius: 50%;
  background: var(--soft);
  color: var(--accent);
  margin-bottom: 6px;
}

/* ------------------------------------------------------------------- home */

.search-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.search-wrap > .icon { position: absolute; left: 18px; color: var(--muted); pointer-events: none; }
.search-input {
  width: 100%;
  min-height: 54px;
  padding: 0 18px 0 50px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--surface);
  font-size: 1.05rem;
  box-shadow: var(--shadow);
  -webkit-appearance: none;
  appearance: none;
}
.search-input:focus { outline: none; border-color: var(--accent); }

.cats {
  display: flex;
  gap: 8px;
  margin: 16px calc(var(--gutter) * -1) 0;
  padding: 2px var(--gutter) 6px;
  overflow-x: auto;
  scrollbar-width: none;
  scroll-snap-type: x proximity;
  scroll-padding-inline: var(--gutter);
}
.cats::-webkit-scrollbar { display: none; }

.pill {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  min-height: 42px;
  padding: 0.4em 1em;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--surface);
  font-weight: 700;
  font-size: 0.95rem;
  scroll-snap-align: start;
  -webkit-tap-highlight-color: transparent;
}
.pill[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.pill-emoji { font-size: 1.1em; }
.pill-count { font-size: 0.78em; opacity: 0.55; }

.filter-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  flex-wrap: wrap;
}
.filter-toggle[aria-expanded="true"] { background: var(--accent); color: var(--accent-ink); }
.active-chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; flex: 1; min-width: 0; }

.sort {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  margin-left: auto;
}
.sort select {
  border: 0;
  background: transparent;
  font-weight: 700;
  color: var(--text);
  padding: 8px 4px;
  min-height: var(--tap);
  max-width: 11em;
}

.filter-panel {
  margin-top: 12px;
  padding: 18px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  display: grid;
  gap: 18px;
  animation: drop 0.2s var(--ease);
}
@keyframes drop { from { opacity: 0; transform: translateY(-6px); } }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.panel-title { font-weight: 800; }
.panel-group { display: grid; gap: 10px; }
.panel-group h3 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-family: var(--font-body); }
.group-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.mini-search {
  min-height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--bg);
  font-size: 0.9rem;
  width: min(220px, 100%);
}

/* The "been a while" shelf */
.shelf {
  margin-top: 26px;
  padding: 18px 0 18px 18px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--soft), color-mix(in srgb, var(--soft) 40%, var(--surface)));
}
.shelf-head { padding-right: 18px; }
.shelf-head p { color: color-mix(in srgb, var(--text) 65%, var(--soft)); font-size: 0.95rem; }
.shelf-row {
  display: flex;
  gap: 12px;
  margin-top: 12px;
  padding-right: 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 0 18px;
  scrollbar-width: none;
}
.shelf-row::-webkit-scrollbar { display: none; }
.shelf-card {
  position: relative;
  flex: none;
  width: 190px;
  scroll-snap-align: start;
}
.shelf-link {
  display: flex;
  flex-direction: column;
  gap: 2px;
  height: 100%;
  padding: 8px 8px 12px;
  border-radius: calc(var(--radius) * 0.85);
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  box-shadow: var(--shadow);
}
.shelf-thumb { aspect-ratio: 4 / 3; border-radius: var(--radius-sm); overflow: hidden; margin-bottom: 6px; }
.shelf-title { font-weight: 800; line-height: 1.25; padding: 0 4px; }
.shelf-when { font-size: 0.82rem; color: var(--muted); padding: 0 4px; }
.shelf-snooze {
  position: absolute;
  top: 12px; right: 12px;
  width: 30px; height: 30px;
  background: color-mix(in srgb, var(--surface) 85%, transparent);
  backdrop-filter: blur(6px);
}

/* Results */
.results { margin-top: 22px; }
.result-count { color: var(--muted); font-size: 0.9rem; margin-bottom: 8px; }

.group { margin-top: 26px; }
.group:first-of-type { margin-top: 8px; }
.group-title button {
  display: inline-flex;
  align-items: baseline;
  gap: 0.45em;
  border: 0;
  background: none;
  padding: 0;
  font: inherit;
  color: inherit;
  text-align: left;
}
.group-emoji { font-size: 0.9em; }
.group-count { font-family: var(--font-body); font-size: 0.6em; color: var(--muted); font-weight: 700; }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(230px, 100%), 1fr));
  gap: clamp(12px, 2vw, 20px);
  margin-top: 14px;
}
@media (max-width: 460px) {
  .grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .card-title { font-size: 1rem !important; }
  .card-meta { font-size: 0.8rem !important; }
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid color-mix(in srgb, var(--line) 60%, transparent);
  transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.card:active { transform: scale(0.985); }

.card-img, .shelf-thumb {
  aspect-ratio: 4 / 3;
  background: var(--surface-2);
  overflow: hidden;
}
.card-img img, .shelf-thumb img { width: 100%; height: 100%; object-fit: cover; }
.placeholder {
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 30% 25%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 55%),
    radial-gradient(circle at 80% 90%, color-mix(in srgb, var(--star) 18%, transparent), transparent 50%),
    var(--soft);
}
.placeholder span {
  font-size: clamp(2.2rem, 7vw, 3rem);
  font-family: var(--font-head);
  color: color-mix(in srgb, var(--accent) 75%, var(--text));
  filter: saturate(0.9);
}
.card-wrap { position: relative; display: flex; }
.card-wrap > .card { flex: 1; }
.card-fav {
  position: absolute;
  top: 8px; right: 8px;
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  border: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  color: var(--muted);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  box-shadow: 0 1px 4px color-mix(in srgb, var(--text) 15%, transparent);
  transition: transform 0.15s var(--ease), color 0.15s, opacity 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.card-fav:hover { color: var(--heart); }
.card-fav:active { transform: scale(0.9); }
.card-fav.on { color: var(--heart); }
/* With a mouse, empty hearts appear on hover; on touch they're always there. */
@media (hover: hover) {
  .card-fav:not(.on) { opacity: 0; }
  .card-wrap:hover .card-fav, .card-fav:focus-visible { opacity: 1; }
}
.card-body { padding: 12px 14px 14px; display: grid; gap: 4px; }
.card-title { font-size: calc(1.12rem * var(--head-scale)); line-height: 1.2; }
.card-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; color: var(--muted); font-size: 0.86rem; }
.card-meta span { display: inline-flex; align-items: center; gap: 4px; }
.card-rating { color: var(--star); letter-spacing: 1px; }
.card-made { font-size: 0.8rem; color: color-mix(in srgb, var(--accent) 70%, var(--muted)); font-weight: 700; }

/* ----------------------------------------------------------------- recipe */

.recipe-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

.recipe-head {
  display: grid;
  gap: clamp(18px, 3vw, 36px);
  margin-top: 8px;
}
@media (min-width: 860px) {
  .recipe-head:has(.hero) { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); align-items: start; }
}
.hero {
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lift);
  background: var(--surface-2);
  aspect-ratio: 4 / 3;
}
.hero img { width: 100%; height: 100%; object-fit: cover; }

.recipe-titles { display: grid; gap: 12px; align-content: start; }
.eyebrow {
  justify-self: start;
  font-size: 0.85rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent);
  text-decoration: none;
}

.facts { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 0; }
.fact {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--line);
  min-width: 84px;
}
.fact dt { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-weight: 800; }
.fact dd { margin: 0; font-weight: 700; }

.recipe-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; }
.fav-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 0;
  background: none;
  padding: 6px 0;
  font-weight: 700;
  color: var(--muted);
  min-height: var(--tap);
}
.fav-btn:hover { color: var(--heart); }
.fav-btn[aria-pressed="true"] { color: var(--heart); }
.made-btn.done {
  background: color-mix(in srgb, #3a9a5b 16%, var(--surface));
  color: color-mix(in srgb, #2f7d49 75%, var(--text));
}
.stars { display: inline-flex; color: var(--star); font-size: 1.45rem; line-height: 1; }
.stars button { border: 0; background: none; padding: 4px 3px; color: inherit; font-size: inherit; min-height: var(--tap); }
.stars.readonly { font-size: 1.2rem; letter-spacing: 2px; }

.recipe-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

.made-log summary, .made-line {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
}
.made-log summary::-webkit-details-marker { display: none; }
.made-log summary { list-style: none; min-height: 36px; }
.made-log summary::after { content: '▾'; font-size: 0.8em; }
.made-list { list-style: none; padding: 0; margin: 6px 0 10px; display: grid; gap: 2px; max-width: 320px; }
.made-list li { display: flex; justify-content: space-between; align-items: center; padding: 2px 0; border-bottom: 1px dashed var(--line); }
.made-other { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 0.92rem; }
.made-other input { padding: 6px 8px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }

.recipe-body {
  display: grid;
  gap: clamp(18px, 3vw, 36px);
  margin-top: clamp(24px, 4vw, 40px);
}
@media (min-width: 860px) {
  .recipe-body { grid-template-columns: minmax(280px, 0.8fr) minmax(0, 1.6fr); align-items: start; }
  .ingredients-card { position: sticky; top: 84px; max-height: calc(100vh - 100px); overflow: auto; }
}

.ingredients-card {
  padding: 20px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.ingredients-card h2, .method h2 { margin-bottom: 12px; }

.ingredient-list, .step-list { list-style: none; margin: 0; padding: 0; }
.ingredient-list li.sub, .step-list li.sub {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: calc(1.02rem * var(--head-scale));
  margin: 14px 0 4px;
  color: var(--accent);
}
.tick {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 8px 0;
  border-bottom: 1px dashed var(--line);
  cursor: pointer;
}
.tick input {
  flex: none;
  width: 22px; height: 22px;
  margin: 2px 0 0;
  accent-color: var(--accent);
}
.tick input:checked + span { text-decoration: line-through; color: var(--muted); }

.step-list { display: grid; gap: 16px; counter-reset: none; }
.step { display: grid; grid-template-columns: 36px 1fr; gap: 12px; align-items: start; }
.step-num {
  display: grid;
  place-items: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--soft);
  color: color-mix(in srgb, var(--accent) 80%, var(--text));
  font-weight: 800;
  font-family: var(--font-head);
}
.step p { padding-top: 5px; font-size: 1.05rem; }

.time-chip {
  display: inline;
  padding: 0.08em 0.5em;
  margin: 0 0.05em;
  border-radius: 999px;
  border: 1.5px solid color-mix(in srgb, var(--accent) 40%, transparent);
  background: var(--soft);
  color: color-mix(in srgb, var(--accent) 80%, var(--text));
  font: inherit;
  font-weight: 700;
  white-space: nowrap;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  -webkit-tap-highlight-color: transparent;
}
.time-chip .icon { display: inline-block; vertical-align: -0.12em; margin-right: 0.25em; width: 0.9em; height: 0.9em; }
.time-chip:hover { background: var(--accent); color: var(--accent-ink); }

.notes { margin-top: 28px; }
.notes-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 8px; }
.save-status { color: var(--muted); font-size: 0.85rem; }
.notes-text {
  white-space: pre-wrap;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--star) 12%, var(--surface));
  border-left: 4px solid var(--star);
}
.notes-edit {
  width: 100%;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--line);
  border-left: 4px solid var(--star);
  background: color-mix(in srgb, var(--star) 10%, var(--surface));
  resize: vertical;
  min-height: 90px;
}

.gallery-block { margin-top: 28px; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; margin-top: 10px; }
.gallery-item {
  padding: 0;
  border: 0;
  border-radius: var(--radius-sm);
  overflow: hidden;
  aspect-ratio: 1;
  background: var(--surface-2);
}
.gallery-item img { width: 100%; height: 100%; object-fit: cover; }

.source-photos { margin-top: 24px; }
.source-photos summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  cursor: pointer;
  min-height: var(--tap);
  color: var(--muted);
}
.source { margin-top: 20px; color: var(--muted); }

.keywords {
  margin-top: 30px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 14px;
}
.keywords h3 { font-family: var(--font-body); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin-bottom: 8px; }

/* -------------------------------------------------------------- cook mode */

html.cooking body { overflow: hidden; }

.cook {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  background: var(--bg);
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
}
.cook-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
}
.cook-title { flex: 1; min-width: 0; display: grid; }
.cook-title strong { font-family: var(--font-head); font-size: calc(1.1rem * var(--head-scale)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cook-title > span { display: flex; gap: 10px; color: var(--muted); font-size: 0.85rem; }
.awake-note:not(:empty)::before { content: '· '; }
.cook-ing-toggle[aria-expanded="true"] { background: var(--soft); }

.cook-progress { height: 4px; background: var(--surface-2); }
.cook-progress span { display: block; height: 100%; background: var(--accent); transition: width 0.3s var(--ease); }

.cook-main {
  display: grid;
  grid-template-columns: 1fr;
  min-height: 0;
  overflow: hidden;
}
.cook:not(.ings-hidden) .cook-main { grid-template-columns: minmax(240px, 340px) 1fr; }
@media (max-width: 899px) {
  .cook:not(.ings-hidden) .cook-main { grid-template-columns: 1fr; grid-template-rows: minmax(0, 45%) 1fr; }
}
.cook.ings-hidden .cook-ingredients { display: none; }

.cook-ingredients {
  overflow: auto;
  padding: 18px;
  background: var(--surface);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.cook-ingredients h2 { margin-bottom: 8px; }
.cook-ingredients ul { list-style: none; margin: 0; padding: 0; }
.cook-ingredients li.sub { font-weight: 800; color: var(--accent); margin: 12px 0 4px; }
.cook-ing {
  display: flex;
  gap: 10px;
  width: 100%;
  text-align: left;
  border: 0;
  background: none;
  padding: 9px 0;
  border-bottom: 1px dashed var(--line);
  font-size: 1.08rem;
  line-height: 1.35;
}
.cook-ing .box {
  flex: none;
  width: 22px; height: 22px;
  margin-top: 1px;
  border-radius: 6px;
  border: 2px solid var(--line);
}
.cook-ing[aria-pressed="true"] { color: var(--muted); text-decoration: line-through; }
.cook-ing[aria-pressed="true"] .box { background: var(--accent); border-color: var(--accent); }

.cook-stage {
  overflow: auto;
  display: grid;
  align-content: center;
  padding: clamp(20px, 5vw, 64px);
  touch-action: pan-y;
}
.cook-stage.enter .cook-step { animation: stepIn 0.28s var(--ease); }
@keyframes stepIn { from { opacity: 0; transform: translateX(14px); } }
.cook-step { max-width: 38ch; margin: 0 auto; display: grid; gap: 18px; width: 100%; }
.cook-section { font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent); font-size: 0.9rem; }
.cook-text { font-size: clamp(1.5rem, 3.6vw, 2.3rem); line-height: 1.4; font-weight: 500; }
.cook-text .time-chip { padding: 0 0.45em; }
.cook-upnext { color: var(--muted); font-size: 1rem; padding-top: 14px; border-top: 1px dashed var(--line); }
.cook-upnext span { font-weight: 800; }
.cook-done { text-align: center; justify-items: center; }
.cook-done .btn { min-width: 260px; }

.cook-nav {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 12px;
  padding: 12px 14px;
  border-top: 1px solid var(--line);
  background: var(--surface);
}
.cook-nav .btn { min-height: 60px; font-size: 1.1rem; }

/* ----------------------------------------------------------------- timers */

.timer-tray {
  position: fixed;
  right: max(14px, env(safe-area-inset-right));
  bottom: calc(14px + env(safe-area-inset-bottom));
  z-index: 60;
  display: grid;
  gap: 8px;
  width: min(330px, calc(100vw - 28px));
}
html.cooking .timer-tray { bottom: calc(96px + env(safe-area-inset-bottom)); }
.timer {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 8px 8px 16px;
  border-radius: 999px;
  background: var(--text);
  color: var(--bg);
  box-shadow: var(--shadow-lift);
  animation: drop 0.25s var(--ease);
}
.timer .icon-btn { color: var(--bg); width: 38px; height: 38px; }
.timer .icon-btn:hover { background: color-mix(in srgb, var(--bg) 16%, transparent); }
.timer-text { flex: 1; min-width: 0; display: grid; line-height: 1.2; }
.timer-clock { font-variant-numeric: tabular-nums; font-weight: 800; font-size: 1.2rem; }
.timer-label { font-size: 0.78rem; opacity: 0.75; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.timer-actions { display: flex; }
.plus-min { font-weight: 800; font-size: 0.85rem; }
.timer.paused .timer-clock { opacity: 0.6; }
.timer.done { background: var(--accent); color: var(--accent-ink); animation: pulse 1.1s ease-in-out infinite; }
.timer.done .icon-btn { color: var(--accent-ink); }
@keyframes pulse { 50% { transform: scale(1.03); box-shadow: 0 0 0 8px color-mix(in srgb, var(--accent) 25%, transparent); } }

/* --------------------------------------------------------- add and editor */

.add-page h1, .edit-page h1 { margin-top: 4px; }
.add-page > * + * { margin-top: 16px; }

.add-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr));
  gap: 14px;
  margin-top: 24px !important;
}
.add-tile {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 20px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1.5px solid var(--line);
  color: var(--text);
  text-decoration: none;
  box-shadow: var(--shadow);
  transition: transform 0.15s var(--ease), border-color 0.15s;
}
.add-tile:hover { transform: translateY(-2px); border-color: var(--accent); }
.add-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 52px; height: 52px;
  border-radius: 14px;
  background: var(--soft);
  color: var(--accent);
}
.add-text { display: grid; gap: 2px; }
.add-text strong { font-family: var(--font-head); font-size: calc(1.15rem * var(--head-scale)); }
.add-text span { color: var(--muted); font-size: 0.93rem; }

.big-text, .big-input {
  width: 100%;
  padding: 16px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--line);
  background: var(--surface);
  font-size: 1rem;
}
.big-text { min-height: 260px; resize: vertical; }
.big-input { min-height: 56px; font-size: 1.1rem; }
.big-text:focus, .big-input:focus { outline: none; border-color: var(--accent); }
.link-form { display: grid; gap: 12px; }
.link-form .btn { justify-self: start; }

.photo-picks { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.pick { position: relative; display: grid; gap: 8px; justify-items: center; }
.pick-img {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--surface-2);
  display: grid;
  place-items: center;
}
.pick-img img { width: 100%; height: 100%; object-fit: cover; }
.pick-x {
  position: absolute;
  top: 6px; right: 6px;
  width: 32px; height: 32px;
  background: color-mix(in srgb, var(--surface) 90%, transparent);
}

.working {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.working-box {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: 28px 34px;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-lift);
  text-align: center;
  font-weight: 700;
  max-width: calc(100vw - 32px);
}

.editor {
  display: grid;
  gap: 24px;
  margin-top: 18px;
}
@media (min-width: 1000px) {
  .editor.has-ref { grid-template-columns: minmax(0, 1fr) minmax(300px, 0.8fr); align-items: start; }
  .editor.has-ref .reference { position: sticky; top: 84px; max-height: calc(100vh - 100px); overflow: auto; order: 2; }
}
.editor-main { display: grid; gap: 18px; min-width: 0; }
.reference {
  display: grid;
  gap: 10px;
  align-content: start;
}
.reference:empty { display: none; }
@media (max-width: 999px) {
  .reference { order: -1; }
  .editor.has-ref .reference { grid-auto-flow: column; grid-auto-columns: 70%; overflow-x: auto; }
  .editor.has-ref .reference h2 { display: none; }
}
.reference-img { padding: 0; border: 1.5px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; background: var(--surface-2); }
.reference-img img { width: 100%; }

.banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  background: var(--soft);
  font-size: 0.95rem;
}

.title-input {
  width: 100%;
  border: 0;
  border-bottom: 2px solid var(--line);
  background: transparent;
  padding: 8px 0;
  font-family: var(--font-head);
  font-size: calc(clamp(1.5rem, 4vw, 2.1rem) * var(--head-scale));
  font-weight: var(--head-weight);
  border-radius: 0;
}
.title-input:focus { outline: none; border-bottom-color: var(--accent); }

.field { display: grid; gap: 6px; min-width: 0; }
.field-label { font-weight: 800; font-size: 0.92rem; }
.field input[type="text"], .field input[type="number"], .field input[type="password"], .field input[type="url"],
.field select, .field textarea, .login-form input, .tag-input {
  width: 100%;
  min-height: var(--tap);
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--line);
  background: var(--surface);
  font-size: 1rem;
}
.field textarea { resize: vertical; line-height: 1.5; }
.field :is(input, select, textarea):focus, .login-form input:focus, .tag-input:focus-within { outline: none; border-color: var(--accent); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 460px) { .field-row { grid-template-columns: 1fr; } }

.tag-input { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 6px 8px; }
.tag-input input { flex: 1; min-width: 140px; border: 0; background: transparent; padding: 6px; min-height: 34px; }
.tag-input input:focus { outline: none; }

.key-preview { min-height: 30px; }

.check-row { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; min-height: var(--tap); cursor: pointer; }
.check-row input { width: 22px; height: 22px; accent-color: var(--accent); }

.editor-actions {
  position: sticky;
  bottom: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px 0 calc(14px + env(safe-area-inset-bottom));
  background: linear-gradient(to top, var(--bg) 70%, transparent);
}

.edit-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 10px; }
.edit-photo {
  display: grid;
  gap: 6px;
  padding: 6px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1.5px solid var(--line);
}
.edit-photo.is-cover { border-color: var(--star); }
.edit-photo-img {
  padding: 0;
  border: 0;
  aspect-ratio: 1;
  border-radius: calc(var(--radius-sm) * 0.7);
  overflow: hidden;
  background: var(--surface-2);
  display: grid;
  place-items: center;
}
.edit-photo-img img { width: 100%; height: 100%; object-fit: cover; }
.edit-photo-tools { display: flex; gap: 4px; justify-content: space-between; }
.mini {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  border: 0;
  border-radius: 999px;
  background: var(--surface-2);
  padding: 4px 8px;
  font-size: 0.78rem;
  font-weight: 800;
  min-height: 30px;
}
.mini[aria-pressed="true"] { background: var(--star); color: #2b1d00; }
.mini.danger { color: var(--danger); }
.edit-photo-add {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 6px;
  min-height: 130px;
  border-radius: var(--radius-sm);
  border: 2px dashed var(--line);
  background: transparent;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.9rem;
}
.edit-photo-add:hover { border-color: var(--accent); color: var(--accent); }

/* ---------------------------------------------------------------- dialogs */

.dialog {
  width: min(560px, calc(100vw - 24px));
  max-height: min(88vh, 900px);
  padding: 0;
  border: 0;
  border-radius: calc(var(--radius) * 1.2);
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.45);
  animation: pop 0.2s var(--ease);
}
.dialog.small { width: min(420px, calc(100vw - 24px)); }
.dialog.wide { width: min(820px, calc(100vw - 24px)); }
.dialog.closing { animation: popOut 0.16s ease-in forwards; }
.dialog::backdrop { background: rgba(20, 14, 10, 0.45); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
@keyframes pop { from { opacity: 0; transform: translateY(12px) scale(0.98); } }
@keyframes popOut { to { opacity: 0; transform: translateY(8px) scale(0.98); } }

@media (max-width: 600px) {
  .dialog:not(.full) {
    width: 100vw;
    max-width: 100vw;
    max-height: 92vh;
    margin: auto 0 0;
    border-radius: calc(var(--radius) * 1.2) calc(var(--radius) * 1.2) 0 0;
    animation: sheet 0.25s var(--ease);
  }
  @keyframes sheet { from { transform: translateY(40px); opacity: 0; } }
}

.dialog-inner { display: flex; flex-direction: column; max-height: inherit; }
.dialog-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 12px 8px 22px;
}
.dialog-head h2 { flex: 1; }
.dialog-body { padding: 8px 22px 22px; overflow: auto; display: grid; gap: 16px; }
.dialog-foot {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  padding: 12px 22px calc(16px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
}
.confirm-text { font-size: 1.05rem; }

.login-form { display: grid; gap: 12px; }
.form-error { color: var(--danger); font-weight: 700; min-height: 1.4em; }

.theme-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; }
.theme-card {
  display: grid;
  gap: 4px;
  padding: 8px 8px 12px;
  text-align: left;
  border-radius: calc(var(--radius) * 0.9);
  border: 2px solid var(--line);
  background: var(--surface);
  color: var(--text);
  font-family: var(--font-body);
}
.theme-card[aria-pressed="true"] { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 30%, transparent); }
.theme-preview {
  display: grid;
  gap: 6px;
  padding: 10px;
  border-radius: calc(var(--radius) * 0.6);
  background: var(--bg);
  margin-bottom: 4px;
}
.tp-bar { height: 8px; width: 40%; border-radius: 4px; background: var(--accent); }
.tp-title { font-family: var(--font-head); font-weight: var(--head-weight); font-size: calc(1.1rem * var(--head-scale)); line-height: 1.1; }
.tp-line { height: 6px; width: 80%; border-radius: 3px; background: var(--line); }
.tp-row { display: flex; gap: 4px; align-items: center; white-space: nowrap; overflow: hidden; }
.tp-chip { font-size: 0.68rem; padding: 1px 6px; border-radius: 999px; background: var(--soft); font-weight: 700; }
.tp-btn { margin-left: auto; font-size: 0.68rem; padding: 2px 8px; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font-weight: 800; }
.theme-name { display: flex; align-items: center; justify-content: space-between; font-weight: 800; padding: 0 4px; }
.theme-name .icon { color: var(--accent); }
.theme-note { font-size: 0.8rem; color: var(--muted); padding: 0 4px; }

.settings-section { display: grid; gap: 12px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.settings-section:last-child { border-bottom: 0; }
.settings-section h3 { display: flex; align-items: center; gap: 8px; }
.radio-cards { display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.radio-card {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--line);
  cursor: pointer;
}
.radio-card:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--soft) 50%, var(--surface)); }
.radio-card input { margin-top: 4px; accent-color: var(--accent); width: 18px; height: 18px; flex: none; }
.radio-card > span { display: grid; gap: 2px; }
.shortcut-howto { display: grid; gap: 10px; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--bg); }
.shortcut-howto .btn { justify-self: start; }
.howto { margin: 0; padding-left: 1.3em; display: grid; gap: 4px; }

.cat-list { display: grid; gap: 8px; }
.cat-row { display: flex; gap: 6px; align-items: center; }
.cat-row input {
  min-height: var(--tap);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--line);
  background: var(--bg);
}
.cat-emoji { width: 56px; text-align: center; font-size: 1.2rem; }
.cat-name { flex: 1; min-width: 0; }

/* Lightbox */
.dialog.full {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-height: none;
  border-radius: 0;
  background: #0d0b0a;
  color: #fff;
}
.lightbox .dialog-head { position: absolute; top: env(safe-area-inset-top); right: 0; z-index: 2; background: none; }
.lightbox .dialog-head h2 { display: none; }
.lightbox .dialog-x { color: #fff; background: rgba(255, 255, 255, 0.12); }
.lightbox .dialog-body { padding: 0; height: 100%; }
.lightbox-stage { position: relative; height: 100%; display: grid; place-items: center; }
.lightbox-img { max-width: 100%; max-height: calc(100dvh - 60px); object-fit: contain; }
.lightbox-caption { position: absolute; bottom: calc(14px + env(safe-area-inset-bottom)); left: 0; right: 0; text-align: center; font-size: 0.9rem; opacity: 0.75; }
.lb-prev, .lb-next { position: absolute; top: 50%; transform: translateY(-50%); color: #fff; background: rgba(255, 255, 255, 0.12); width: 52px; height: 52px; }
.lb-prev { left: 12px; }
.lb-next { right: 12px; }

/* ----------------------------------------------------------------- toasts */

.toasts {
  position: fixed;
  left: 50%;
  bottom: calc(20px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  z-index: 100;
  display: grid;
  gap: 8px;
  width: min(460px, calc(100vw - 28px));
  pointer-events: none;
}
html.has-timers .toasts { bottom: calc(90px + env(safe-area-inset-bottom)); }
.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px 12px 18px;
  border-radius: 14px;
  background: var(--text);
  color: var(--bg);
  font-weight: 600;
  box-shadow: var(--shadow-lift);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.2s, transform 0.2s var(--ease);
  pointer-events: auto;
}
.toast.in { opacity: 1; transform: none; }
.toast.bad { background: var(--danger); color: #fff; }
.toast > span { flex: 1; }
.toast-action { border: 0; background: color-mix(in srgb, var(--bg) 18%, transparent); color: inherit; font-weight: 800; padding: 6px 12px; border-radius: 999px; }

/* ------------------------------------------------------------------ print */

@media print {
  .site-header, .recipe-top, .recipe-actions, .recipe-controls, .made-log, .made-line, .timer-tray, .toasts,
  .keywords, .gallery-block, .source-photos, .notes-edit { display: none !important; }
  body { background: #fff !important; color: #000; font-size: 12pt; }
  .page { padding: 0; }
  .hero { max-height: 6cm; box-shadow: none; aspect-ratio: auto; }
  .recipe-head { grid-template-columns: 1fr 1fr !important; }
  .recipe-body { grid-template-columns: 1fr 1.6fr !important; }
  .ingredients-card { position: static !important; max-height: none !important; box-shadow: none; border: 1px solid #ccc; }
  .time-chip { border: 0; background: none; padding: 0; color: inherit; }
  .time-chip .icon { display: none; }
  .tick input { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
