:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color:#24362e;
  background:#f6f4ee;
  font-synthesis:none;
  text-rendering:optimizeLegibility;
  --bg:#f6f4ee;
  --surface:#f7f5ef;
  --surface-2:#e6eee3;
  --text:#24362e;
  --muted:#5c6a61;
  --accent:#245d48;
  --border:#d9dfd5;
  --status-online:#2d7457;
  --status-offline:#965b49;
  --top-header-content-h:52px;
  --top-header-top-gap:10px;
  --top-header-h:calc(var(--top-header-content-h) + var(--top-header-top-gap) + env(safe-area-inset-top));
  --primary-nav-h:70px;
  --subheader-h:48px;
  --filterbar-h:42px;
  --subheader-current-h:calc(var(--subheader-h) + var(--filterbar-h));
  --bottom-chrome-h:calc(var(--primary-nav-h) + var(--subheader-current-h));
  --bottom-stack-h:calc(var(--bottom-chrome-h) + env(safe-area-inset-bottom));
  --page-inline-pad:18px;
  --shell-max-w:760px;
  --chrome-max-w:800px;
  --glass-blur:12px;
  --overlay-obscure-blur:1.5px;
}

* { box-sizing:border-box; }
html, body {
  width:100%;
  height:100%;
  overflow:hidden;
}
body {
  margin:0;
  min-width:320px;
  position:relative;
  background:var(--bg);
  color:var(--text);
  isolation:isolate;
  overscroll-behavior:none;
}

/* One shared body background for every page. Visual ownership stays at app level. */
body::before {
  content:"";
  position:fixed;
  inset:0;
  z-index:0;
  pointer-events:none;
  background-image:url('../assets/backgrounds/background-light.jpg');
  background-position:center;
  background-repeat:no-repeat;
  background-size:cover;
}
button, input, select, textarea { font:inherit; }
button { -webkit-tap-highlight-color:transparent; }
h1, h2, h3, h4, p { margin:0; }

/* Shared visual effects. Components opt into these classes; interaction code never owns blur values. */
.glass-surface {
  backdrop-filter:blur(var(--glass-blur));
  -webkit-backdrop-filter:blur(var(--glass-blur));
}

.overlay-obscurable { transition:filter 180ms ease; }
.overlay-active .overlay-obscurable { filter:blur(var(--overlay-obscure-blur)); }

.top-header {
  position:fixed;
  top:0;
  left:0;
  right:0;
  z-index:140;
  height:var(--top-header-h);
  pointer-events:none;
}

.top-header__inner {
  width:min(100%,var(--chrome-max-w));
  height:100%;
  margin:0 auto;
  padding-top:calc(env(safe-area-inset-top) + var(--top-header-top-gap));
  padding-left:max(12px, env(safe-area-inset-left));
  padding-right:max(12px, env(safe-area-inset-right));
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}

.top-header-control {
  min-height:40px;
  border:1px solid color-mix(in srgb, var(--border) 78%, transparent);
  border-radius:11px;
  background:color-mix(in srgb, var(--surface) 72%, transparent);
  color:var(--text);
  box-shadow:0 4px 18px rgba(23,34,28,.07);
  pointer-events:auto;
}

.top-header__status {
  display:flex;
  align-items:center;
  gap:7px;
  padding:0 12px;
}

.top-header__status-dot {
  width:8px;
  height:8px;
  flex:0 0 auto;
  border-radius:50%;
  background:var(--status-online);
  box-shadow:0 0 0 3px color-mix(in srgb, var(--status-online) 15%, transparent);
}
.top-header__status[data-network="offline"] .top-header__status-dot {
  background:var(--status-offline);
  box-shadow:0 0 0 3px color-mix(in srgb, var(--status-offline) 15%, transparent);
}
.top-header__status-label { font-size:.74rem; font-weight:760; }
.top-header__version {
  padding-left:7px;
  border-left:1px solid color-mix(in srgb, var(--border) 78%, transparent);
  color:var(--muted);
  font-size:.68rem;
  font-weight:720;
}

.top-header__panel-button {
  width:42px;
  padding:0;
  display:grid;
  place-items:center;
}
.top-header__icon {
  display:grid;
  place-items:center;
  font-size:19px;
  line-height:1;
}

.app-shell {
  position:fixed;
  top:var(--top-header-h);
  left:0;
  right:0;
  bottom:var(--bottom-stack-h);
  z-index:1;
  width:min(100%,var(--shell-max-w));
  margin:0 auto;
  overflow:hidden;
}

.page-host {
  width:100%;
  height:100%;
  overflow-x:hidden;
  overflow-y:auto;
  overscroll-behavior-y:contain;
  -webkit-overflow-scrolling:touch;
  scrollbar-gutter:stable;
  scroll-padding-block:8px;
}
.overlay-active .page-host { overflow-y:hidden; }

.page-surface {
  width:100%;
  min-height:100%;
  padding:8px max(var(--page-inline-pad),env(safe-area-inset-right)) 20px max(var(--page-inline-pad),env(safe-area-inset-left));
  display:grid;
  align-content:start;
  gap:14px;
}


.json-inspector {
  width:100%;
  min-width:0;
}

.json-inspector__summary {
  width:max-content;
  max-width:100%;
  display:flex;
  align-items:center;
  gap:7px;
  padding:6px 28px 6px 10px;
  position:relative;
  overflow:hidden;
  border:1px solid var(--border);
  border-radius:999px;
  background:color-mix(in srgb, var(--surface) 82%, transparent);
  color:var(--text);
  box-shadow:0 2px 8px rgba(30,42,35,.036);
  cursor:pointer;
  font-size:.68rem;
  line-height:1;
  list-style:none;
  -webkit-tap-highlight-color:transparent;
}
.json-inspector__summary::-webkit-details-marker { display:none; }
.json-inspector__summary::after {
  content:"›";
  position:absolute;
  right:10px;
  top:50%;
  font-size:1rem;
  line-height:1;
  transform:translateY(-50%) rotate(90deg);
  transition:transform 140ms ease;
}
.json-inspector[open] .json-inspector__summary::after {
  transform:translateY(-50%) rotate(-90deg);
}
.json-inspector__kind {
  flex:0 0 auto;
  font-weight:800;
  letter-spacing:.056em;
}
.json-inspector__path {
  min-width:0;
  overflow:hidden;
  color:var(--muted);
  font:inherit;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.json-inspector__code {
  width:100%;
  max-height:46dvh;
  margin:8px 0 0;
  padding:12px;
  overflow:auto;
  border:1px solid var(--border);
  border-radius:14px;
  background:color-mix(in srgb, var(--surface) 94%, transparent);
  color:var(--text);
  box-shadow:0 8px 28px rgba(30,42,35,.05);
  font:500 .72rem/1.5 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  tab-size:2;
  white-space:pre;
}

.page-block {
  width:100%;
}

.page-block--intro,
.page-block--empty {
  padding:18px;
  border:1px solid var(--border);
  border-radius:18px;
  background:color-mix(in srgb, var(--surface) 88%, transparent);
  box-shadow:0 8px 28px rgba(30,42,35,.045);
}

.page-block--empty {
  min-height:180px;
  display:grid;
  place-content:center;
  text-align:center;
}

.page-title {
  font-size:1.28rem;
  line-height:1.15;
  letter-spacing:-.025em;
}

.page-lede {
  margin-top:7px;
  max-width:58ch;
  color:var(--muted);
  font-size:.88rem;
  line-height:1.5;
}

.page-block--placeholder .page-lede { color:#d93636; font-weight:800; }

.page-section-title {
  margin:0 0 8px 3px;
  font-size:.78rem;
  color:var(--muted);
  text-transform:uppercase;
  letter-spacing:.06em;
}

.content-card-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}

.content-card {
  min-width:0;
  padding:14px;
  border:1px solid var(--border);
  border-radius:15px;
  background:var(--surface);
}

.content-card__title { font-size:.9rem; }
.content-card__body { margin-top:5px; color:var(--muted); font-size:.78rem; line-height:1.4; }


/* Shared barcode scanner primitive. JSON supplies semantics/endpoints only; app CSS owns appearance. */
.barcode-scanner {
  display:grid;
  gap:12px;
}

.barcode-scanner__heading,
.barcode-scanner__camera,
.barcode-scanner__controls,
.barcode-scanner__result {
  width:100%;
}

.barcode-scanner__heading {
  padding:18px;
  border:1px solid var(--border);
  border-radius:18px;
  background:color-mix(in srgb, var(--surface) 88%, transparent);
  box-shadow:0 8px 28px rgba(30,42,35,.045);
}

.barcode-scanner__camera {
  position:relative;
  width:100%;
  aspect-ratio:4/3;
  overflow:hidden;
  display:grid;
  place-items:center;
  border:1px solid var(--border);
  border-radius:18px;
  background:color-mix(in srgb, var(--surface) 92%, transparent);
}

.barcode-scanner__camera-target {
  position:absolute;
  inset:0;
  overflow:hidden;
  background:#000;
}

.barcode-scanner__camera-target > video,
.barcode-scanner__camera-target video {
  width:100% !important;
  height:100% !important;
  display:block !important;
  object-fit:cover;
}

/* Quagga uses internal canvases for decoding. They are implementation detail, not UI. */
.barcode-scanner__camera-target canvas {
  display:none !important;
}

.barcode-scanner__camera-placeholder {
  position:relative;
  z-index:1;
  color:var(--muted);
  font-size:.82rem;
  font-weight:700;
}

.barcode-scanner__controls {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto auto;
  gap:8px;
}

.barcode-scanner__input,
.barcode-scanner__button {
  min-height:44px;
  border:1px solid var(--border);
  border-radius:12px;
}

.barcode-scanner__input {
  min-width:0;
  padding:0 12px;
  background:color-mix(in srgb, var(--surface) 92%, transparent);
  color:var(--text);
  outline:none;
}
.barcode-scanner__input:focus {
  border-color:color-mix(in srgb, var(--accent) 55%, var(--border));
  box-shadow:0 0 0 3px color-mix(in srgb, var(--accent) 11%, transparent);
}

.barcode-scanner__button {
  padding:0 13px;
  background:color-mix(in srgb, var(--surface) 90%, transparent);
  color:var(--text);
  font-size:.78rem;
  font-weight:780;
}
.barcode-scanner__button--primary {
  border-color:var(--accent);
  background:var(--accent);
  color:#fff;
}
.barcode-scanner__button:disabled { opacity:.55; }

.barcode-scanner__status {
  min-height:1.2em;
  color:var(--muted);
  font-size:.78rem;
  font-weight:680;
}
.barcode-scanner__status[data-state="error"] { color:#a3483c; }
.barcode-scanner__status[data-state="success"] { color:var(--status-online); }

.barcode-scanner__result {
  display:grid;
  gap:8px;
}

.barcode-result {
  margin:0;
  overflow:hidden;
  border:1px solid var(--border);
  border-radius:15px;
  background:var(--surface);
}

.barcode-result__row {
  min-height:46px;
  display:grid;
  grid-template-columns:minmax(92px,.38fr) minmax(0,1fr);
  align-items:center;
  gap:12px;
  padding:9px 13px;
  border-bottom:1px solid var(--border);
}
.barcode-result__row:last-child { border-bottom:0; }
.barcode-result__term { color:var(--muted); font-size:.72rem; font-weight:720; }
.barcode-result__value { margin:0; min-width:0; overflow-wrap:anywhere; font-size:.84rem; font-weight:700; }

.barcode-response {
  overflow:hidden;
  border:1px solid var(--border);
  border-radius:14px;
  background:color-mix(in srgb, var(--surface) 92%, transparent);
}
.barcode-response__summary {
  padding:10px 12px;
  cursor:pointer;
  color:var(--muted);
  font-size:.74rem;
  font-weight:760;
}

.barcode-diagnostics {
  overflow:hidden;
  border:1px solid var(--border);
  border-radius:14px;
  background:color-mix(in srgb, var(--surface) 92%, transparent);
}
.barcode-diagnostics__summary {
  padding:10px 12px;
  cursor:pointer;
  color:var(--muted);
  font-size:.74rem;
  font-weight:760;
}
.barcode-diagnostics__body {
  margin:0;
  border-top:1px solid var(--border);
}
.barcode-diagnostics__row {
  min-height:40px;
  display:grid;
  grid-template-columns:minmax(110px,.42fr) minmax(0,1fr);
  align-items:center;
  gap:12px;
  padding:8px 12px;
  border-bottom:1px solid var(--border);
}
.barcode-diagnostics__row:last-child { border-bottom:0; }
.barcode-diagnostics__term { color:var(--muted); font-size:.71rem; font-weight:720; }
.barcode-diagnostics__value { margin:0; font-size:.78rem; font-weight:700; overflow-wrap:anywhere; }
.barcode-response__code {
  max-height:38dvh;
  margin:0;
  padding:12px;
  overflow:auto;
  border-top:1px solid var(--border);
  color:var(--text);
  font:500 .7rem/1.45 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  white-space:pre;
}

@media (max-width:560px) {
  .barcode-scanner__controls { grid-template-columns:minmax(0,1fr) auto; }
  .barcode-scanner__controls .barcode-scanner__button:last-child { grid-column:1 / -1; }
}

.abstract-list {
  display:grid;
  gap:14px;
}

.abstract-list__section {
  min-width:0;
}

.section-pill {
  width:max-content;
  max-width:calc(100% - 6px);
  margin:0 0 7px 3px;
  padding:6px 10px;
  overflow:hidden;
  border:1px solid var(--border);
  border-radius:999px;
  background:color-mix(in srgb, var(--surface) 82%, transparent);
  color:var(--text);
  box-shadow:0 2px 8px rgba(30,42,35,.036);
  font-size:.72rem;
  font-weight:750;
  line-height:1;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.abstract-list__surface {
  overflow:hidden;
  border:1px solid var(--border);
  border-radius:15px;
  background:var(--surface);
}


/* Shared recipe-card collection. API/config supplies semantics; app CSS owns layout. */
.recipe-card-collection {
  display:grid;
  gap:16px;
}

.recipe-card-group {
  min-width:0;
}

.recipe-card-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}

.recipe-card {
  min-width:0;
  overflow:hidden;
  display:flex;
  flex-direction:column;
  padding:0;
  border:1px solid var(--border);
  border-radius:18px;
  background:color-mix(in srgb, var(--surface) 92%, transparent);
  color:var(--text);
  box-shadow:0 5px 18px rgba(30,42,35,.045);
  text-align:left;
  appearance:none;
}

.recipe-card__body {
  min-width:0;
  padding:10px;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:8px;
  align-items:center;
}

.recipe-card__actions {
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:2px;
}

.recipe-card__open {
  min-width:0;
  padding:0;
  display:flex;
  gap:11px;
  align-items:center;
  align-self:center;
  border:0;
  border-radius:10px;
  background:transparent;
  color:inherit;
  text-align:left;
  appearance:none;
}
.recipe-card__open--interactive { cursor:pointer; }
.recipe-card__open--interactive:active { background:color-mix(in srgb, var(--accent) 7%, transparent); }
.recipe-card__open--interactive:focus-visible,
.recipe-card__icon-action:focus-visible {
  outline:2px solid color-mix(in srgb, var(--accent) 62%, transparent);
  outline-offset:2px;
}

.recipe-card__icon-action {
  width:36px;
  height:36px;
  display:grid;
  place-items:center;
  border:1px solid transparent;
  border-radius:10px;
  background:transparent;
  color:var(--muted);
  cursor:pointer;
}
.recipe-card__icon-action:active { background:color-mix(in srgb,var(--accent) 12%,var(--surface)); }
.recipe-card__more {
  border-color:var(--border);
  background:color-mix(in srgb,var(--surface-2) 78%,transparent);
  color:var(--text);
}
.recipe-card__favorite.is-active {
  border-color:color-mix(in srgb,#d6a429 35%,transparent);
  background:color-mix(in srgb,#d6a429 18%,transparent);
  color:#d6a429;
}

.recipe-card__action-icon { width:18px; height:18px; display:grid; place-items:center; font-size:1.1rem; }

.recipe-card__title {
  min-width:0;
  font-size:1rem;
  font-weight:760;
  line-height:1.25;
}

.recipe-card__copy { min-width:0; flex:1; display:grid; gap:5px; }

.recipe-card__meta {
  min-width:0;
  overflow:hidden;
  color:var(--muted);
  font-size:.8rem;
  line-height:1.35;
  text-overflow:ellipsis;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
}

/* Shared recipe media: user photos override bundled dish assets. Remote API images are ignored. */
.recipe-user-image[hidden] { display:none !important; }
.recipe-user-image { min-width:0; }
.recipe-user-image__image {
  width:100%;
  display:block;
  object-fit:cover;
  background:var(--surface-2);
}
.recipe-user-image--card { flex:0 0 84px; width:84px; height:84px; overflow:hidden; border-radius:14px; border:1px solid var(--border); }
.recipe-user-image__image--card { width:100%; height:100%; aspect-ratio:1; }
/* Recipes collection media follows the card edges; Menu and picker retain their own layouts. */
.recipe-user-image__image--detail { max-height:420px; aspect-ratio:16/9; }
.recipe-user-image__controls {
  min-height:48px;
  display:flex;
  align-items:center;
  gap:8px;
  padding:10px 12px;
  border-top:1px solid var(--border);
}
.recipe-user-image:not(.recipe-user-image--has-image) .recipe-user-image__controls {
  border-top:0;
  justify-content:flex-start;
}
.recipe-user-image__action {
  min-height:34px;
  display:inline-flex;
  align-items:center;
  gap:7px;
  padding:0 11px;
  border:1px solid var(--border);
  border-radius:10px;
  background:color-mix(in srgb, var(--surface) 82%, transparent);
  color:var(--text);
  font:inherit;
  font-size:.72rem;
  font-weight:760;
  cursor:pointer;
}
.recipe-user-image__action--danger { color:var(--danger, #9d3d37); }
.recipe-user-image__action-icon {
  width:16px;
  height:16px;
  display:grid;
  place-items:center;
  flex:0 0 16px;
  font-size:.86rem;
}
.recipe-user-image__input {
  position:absolute;
  width:1px;
  height:1px;
  overflow:hidden;
  clip:rect(0 0 0 0);
  clip-path:inset(50%);
  white-space:nowrap;
}

.recipe-card-state {
  min-height:120px;
  display:grid;
  place-items:center;
  margin:0;
  padding:18px;
  border:1px solid var(--border);
  border-radius:15px;
  background:color-mix(in srgb, var(--surface) 88%, transparent);
  color:var(--muted);
  font-size:.82rem;
  font-weight:700;
}

.abstract-list__row {
  min-height:48px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  padding:10px 14px;
  border-bottom:1px solid var(--border);
}
.abstract-list__row:last-child { border-bottom:0; }
.abstract-list__label { min-width:0; font-size:.86rem; font-weight:700; }
.abstract-list__meta { flex:0 0 auto; color:var(--muted); font-size:.73rem; }


.bottom-chrome {
  position:fixed;
  left:0;
  right:0;
  bottom:0;
  z-index:120;
  display:flex;
  flex-direction:column;
  width:100%;
  padding-bottom:env(safe-area-inset-bottom);
  pointer-events:none;
}

.page-subheader,
.primary-nav {
  position:relative;
  flex:0 0 auto;
  width:100%;
  box-sizing:border-box;
  pointer-events:auto;
}

.page-subheader {
  height:var(--subheader-h);
  max-width:var(--chrome-max-w);
  margin:0 auto;
  padding:5px 10px;
  display:flex;
  align-items:center;
  background:color-mix(in srgb,var(--surface) 64%,transparent);
  border-top:1px solid color-mix(in srgb,var(--border) 72%,transparent);
  border-left:0;
  border-right:0;
  border-bottom:0;
  border-radius:0;
  box-shadow:none;
}

.page-subheader--with-text-filter {
  height:calc(var(--subheader-h) + var(--filterbar-h));
  padding:5px 10px 5px;
  flex-direction:column;
  align-items:stretch;
  gap:5px;
}

.page-subheader--filter-only { height:var(--filterbar-h); padding-block:4px; }

.page-subheader--detail {
  height:var(--subheader-h);
  padding:6px 8px;
}

.detail-back-control {
  width:100%;
  min-width:0;
  height:100%;
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:8px;
  padding:0 13px;
  border:1px solid var(--border);
  border-radius:11px;
  background:color-mix(in srgb, var(--surface) 88%, transparent);
  color:var(--text);
  box-shadow:0 2px 8px rgba(30,42,35,.036);
  font:inherit;
  font-size:.76rem;
  font-weight:780;
  cursor:pointer;
}
.detail-back-control:active { background:color-mix(in srgb,var(--accent) 10%,var(--surface)); }
.detail-back-control:focus-visible {
  outline:2px solid color-mix(in srgb,var(--accent) 58%,transparent);
  outline-offset:1px;
}
.detail-back-control__icon { font-size:1.05rem; line-height:1; }
.detail-back-control__label { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }

.page-subheader__filterbar {
  flex:0 0 37px;
  width:100%;
  min-width:0;
  display:flex;
}

.page-filter-input {
  width:100%;
  min-width:0;
  height:37px;
  padding:0 15px;
  border:1px solid color-mix(in srgb,var(--text) 34%,var(--border));
  border-radius:12px;
  background:color-mix(in srgb,var(--surface) 70%,transparent);
  color:var(--text);
  box-shadow:none;
  outline:none;
  font-size:.78rem;
}
.page-filter-input::placeholder { color:var(--muted); opacity:.86; }
.page-filter-input:focus {
  border-color:color-mix(in srgb,var(--text) 56%,var(--accent));
  box-shadow:0 0 0 1px color-mix(in srgb,var(--accent) 18%,transparent);
}

.page-subheader__scroller {
  width:100%;
  min-width:0;
  flex:1 1 auto;
  display:flex;
  align-items:center;
  gap:7px;
  overflow-x:auto;
  overscroll-behavior-inline:contain;
  scrollbar-width:none;
}
.page-subheader__scroller::-webkit-scrollbar { display:none; }

.subheader-control {
  flex:1 1 0;
  min-width:100px;
  min-height:37px;
  padding:0 12px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  border:1px solid color-mix(in srgb,var(--text) 42%,var(--border));
  border-radius:15px;
  background:color-mix(in srgb,var(--surface) 58%,transparent);
  color:var(--text);
  box-shadow:none;
  font-size:.73rem;
  font-weight:760;
  line-height:1;
  white-space:nowrap;
  pointer-events:none;
  opacity:1;
  -webkit-text-fill-color:currentColor;
}

.subheader-control--button,
.subheader-control--filter {
  background:color-mix(in srgb,var(--surface) 58%,transparent);
  border-color:color-mix(in srgb,var(--text) 42%,var(--border));
  color:var(--text);
}

.subheader-control__symbol {
  display:grid;
  place-items:center;
  min-width:14px;
  font-size:.92rem;
  line-height:1;
}

.subheader-control__label { line-height:1; }

.subheader-control[data-control-id="recipe-library"] { flex:0 0 auto; min-width:0; padding-inline:9px; }
.subheader-control.is-active {
  background:color-mix(in srgb,var(--accent) 20%,var(--surface));
  border-color:var(--accent);
  color:var(--text);
}
.recipe-library-title { margin:0; font-size:1.15rem; font-weight:760; }
.recipe-library-header { display:flex; flex-wrap:wrap; gap:8px; align-items:center; justify-content:space-between; }
.recipe-library-controls { display:flex; gap:6px; align-items:center; margin-left:auto; }
.recipe-library-header .menu-button { min-height:32px; padding:4px 10px; font-size:.8rem; }
.recipe-archive-status { color:var(--status-offline); font-size:.85rem; overflow-wrap:anywhere; }
.recipe-archive-hint { margin:0; color:var(--muted); font-size:.8rem; line-height:1.4; }
.recipe-transfer-dialog .menu-dialog__panel { display:flex; flex-direction:column; max-height:calc(100dvh - 44px); gap:8px; }
.recipe-transfer-dialog .menu-dialog__heading { flex:0 0 auto; margin:0; }
.recipe-transfer-dialog .menu-dialog__heading .menu-button--icon { width:32px; min-height:32px; }
.recipe-transfer-body, .recipe-transfer-import-selection { display:flex; flex-direction:column; gap:10px; min-height:0; }
.recipe-transfer-body { overflow:auto; }
.recipe-transfer-scope, .recipe-transfer-file { display:grid; gap:5px; font-size:.82rem; color:var(--muted); }
.recipe-transfer-selection { display:flex; justify-content:space-between; gap:8px; align-items:center; flex-wrap:wrap; }
.recipe-transfer-all { display:flex; align-items:center; gap:7px; font-size:.85rem; cursor:pointer; }
.recipe-transfer-dialog input[type="checkbox"] { width:18px; height:18px; flex:0 0 18px; accent-color:var(--accent); }
.recipe-transfer-count, .recipe-transfer-status { color:var(--muted); font-size:.78rem; line-height:1.4; margin:0; overflow-wrap:anywhere; }
.recipe-transfer-status[role="alert"], .recipe-transfer-row__meta.is-error { color:var(--status-offline); }
.recipe-transfer-list { overflow:auto; min-height:64px; max-height:45dvh; border:1px solid var(--border); border-radius:10px; }
.recipe-transfer-row { display:flex; align-items:center; gap:10px; min-height:52px; padding:8px 10px; border-bottom:1px solid var(--border); cursor:pointer; }
.recipe-transfer-row:last-child { border-bottom:0; }
.recipe-transfer-row:has(input:disabled) { cursor:default; }
.recipe-transfer-row__copy { display:grid; gap:3px; min-width:0; overflow-wrap:anywhere; }
.recipe-transfer-row__name { font-size:.9rem; }
.recipe-transfer-row__meta { color:var(--muted); font-size:.72rem; line-height:1.3; }
.recipe-transfer-footer { display:flex; justify-content:flex-end; gap:8px; flex:0 0 auto; }
.recipe-transfer-footer .menu-button { min-height:40px; padding:7px 14px; }
.recipe-transfer-empty, .recipe-transfer-success { padding:10px; color:var(--muted); font-size:.9rem; }

/* Compact add/sort actions share the control row; Categories takes the remaining width. */
.subheader-control[data-control-id="new-recipe"],
.subheader-control[data-control-id="new-ingredient"],
.subheader-control[data-control-id="new-technique"],
.subheader-control[data-control-id="menu-print"],
.subheader-control[data-control-id="menu-options"],
.subheader-control[data-control-id="sort"] {
  position:relative;
  flex:0 0 37px;
  width:37px;
  min-width:37px;
  height:37px;
  padding:0;
  gap:0;
}

.subheader-control[data-control-id="new-recipe"] .subheader-control__label,
.subheader-control[data-control-id="new-ingredient"] .subheader-control__label,
.subheader-control[data-control-id="new-technique"] .subheader-control__label,
.subheader-control[data-control-id="menu-print"] .subheader-control__label,
.subheader-control[data-control-id="menu-options"] .subheader-control__label,
.subheader-control[data-control-id="sort"] .subheader-control__label {
  position:absolute;
  width:1px;
  height:1px;
  padding:0;
  margin:-1px;
  overflow:hidden;
  clip-path:inset(50%);
  white-space:nowrap;
}


.primary-nav {
  height:var(--primary-nav-h);
  width:100%;
  background:rgba(247,245,239,.98);
  border-top:1px solid var(--border);
  box-shadow:0 -4px 22px rgba(0,0,0,.05);
}

.primary-nav__inner {
  width:min(100%,var(--chrome-max-w));
  height:100%;
  margin:0 auto;
  padding:6px 8px;
  display:grid;
  grid-template-columns:repeat(var(--nav-item-count,5),minmax(0,1fr));
}

.primary-nav .shell-control {
  min-width:0;
  min-height:52px;
  padding:2px 1px;
  border:0;
  border-radius:10px;
  background:transparent;
  color:var(--muted);
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:1px;
  font-size:9.5px;
  line-height:1.05;
  font-weight:650;
  overflow:hidden;
}

.primary-nav .shell-control.is-active {
  background:var(--surface-2);
  color:var(--text);
  font-weight:800;
}

.nav-icon { height:25px; display:grid; place-items:center; font-size:20px; line-height:1.2; }
.nav-icon--svg svg { width:21px; height:21px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.nav-label { max-width:100%; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }

.shell-error {
  width:min(100%,var(--chrome-max-w));
  margin:0 auto;
  padding:12px 16px calc(12px + env(safe-area-inset-bottom));
  background:var(--surface);
  border-top:1px solid var(--border);
  color:#c62828;
  font-weight:800;
  text-align:center;
}

.workspace-drawer__spacer { flex:1 1 auto; min-height:24px; }
.workspace-drawer__workspaces { flex:0 0 auto; display:grid; gap:8px; padding:8px 2px 10px; }
.workspace-drawer__settings {
  flex:0 0 auto;
  padding:10px 2px 0;
  border-top:1px solid var(--border);
}

.drawer-item {
  width:100%;
  min-height:58px;
  display:grid;
  grid-template-columns:42px minmax(0,1fr);
  align-items:center;
  gap:10px;
  padding:8px 12px;
  border:1px solid transparent;
  border-radius:14px;
  background:transparent;
  color:var(--text);
  text-align:left;
  pointer-events:auto;
  opacity:1;
  -webkit-text-fill-color:currentColor;
}


.drawer-item.is-active {
  background:var(--surface-2);
  border-color:color-mix(in srgb, var(--accent) 18%, var(--border));
}

.drawer-item__icon {
  width:38px;
  height:38px;
  display:grid;
  place-items:center;
  border-radius:11px;
  background:color-mix(in srgb, var(--accent) 9%, var(--surface));
  color:var(--accent);
  font-size:20px;
  line-height:1;
}

.drawer-item__label {
  min-width:0;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  font-size:.95rem;
  font-weight:760;
}

.workspace-drawer__settings .drawer-item { background:color-mix(in srgb, var(--surface) 80%, transparent); }
.overlay-active { overflow:hidden; }

.edge-drawer-backdrop {
  position:fixed;
  inset:0;
  z-index:190;
  background:rgba(12,18,15,.34);
  opacity:0;
  pointer-events:none;
  transition:opacity 180ms ease;
}
.edge-drawer-backdrop.is-open { opacity:1; pointer-events:auto; }

.edge-drawer {
  position:fixed;
  top:0;
  bottom:0;
  left:var(--panel-left);
  right:var(--panel-right);
  z-index:200;
  width:min(84vw,360px);
  display:flex;
  flex-direction:column;
  padding:max(10px, env(safe-area-inset-top)) 10px max(10px, env(safe-area-inset-bottom));
  background:rgba(247,245,239,.97);
  border-left:var(--panel-border-left);
  border-right:var(--panel-border-right);
  box-shadow:var(--panel-shadow-x) 0 42px rgba(20,28,24,.16);
  transform:translateX(var(--panel-closed-x));
  transition:transform 220ms cubic-bezier(.22,.8,.2,1);
  overflow:hidden;
  overscroll-behavior:contain;
}
.edge-drawer[data-side="left"] {
  --panel-left:0;
  --panel-right:auto;
  --panel-closed-x:-102%;
  --panel-shadow-x:14px;
  --panel-border-left:0;
  --panel-border-right:1px solid var(--border);
}
.edge-drawer[data-side="right"] {
  --panel-left:auto;
  --panel-right:0;
  --panel-closed-x:102%;
  --panel-shadow-x:-14px;
  --panel-border-left:1px solid var(--border);
  --panel-border-right:0;
}
.edge-drawer.is-open { transform:translateX(0); }

@media (max-width:390px) {
  .primary-nav .shell-control { font-size:8.4px; }
  .nav-icon { font-size:19px; }
  .page-subheader { padding-inline:7px; }
  .content-card-grid { grid-template-columns:1fr; }
}

@media (max-width:760px) {
  .recipe-card-grid { grid-template-columns:1fr; }
  .recipe-user-image--card { flex-basis:76px; width:76px; height:76px; border-radius:13px; }
}


:root:where([data-theme="dark"]) {
    color:#f2f5f7;
    background:#10171c;
    --bg:#10171c;
    --surface:#172733;
    --surface-2:#20394a;
    --text:#f2f5f7;
    --muted:#aab7c1;
    --accent:#4a7fd4;
    --border:#344a59;
    --status-online:#39b77b;
    --status-offline:#d06a61;
  }
:where([data-theme="dark"]) body::before { background-image:url('../assets/backgrounds/background-dark.jpg'); }
:where([data-theme="dark"]) .page-subheader {
    background:rgba(13,27,35,.64);
    border-color:rgba(187,206,216,.20);
  }
:where([data-theme="dark"]) .page-filter-input {
    background:rgba(10,25,35,.76);
    border-color:rgba(218,228,232,.38);
  }
:where([data-theme="dark"]) .subheader-control,
:where([data-theme="dark"]) .subheader-control--button,
:where([data-theme="dark"]) .subheader-control--filter {
    background:rgba(15,30,38,.62);
    border-color:rgba(225,232,235,.52);
    color:#f4f6f7;
  }
:where([data-theme="dark"]) .primary-nav {
    background:rgba(32,48,43,.97);
    border-color:rgba(111,151,174,.16);
  }
:where([data-theme="dark"]) .primary-nav .shell-control.is-active {
    background:linear-gradient(180deg,#243c56,#20374c);
    color:#f7f9fb;
  }
:where([data-theme="dark"]) .edge-drawer {
    background:rgba(22,37,45,.97);
    border-color:rgba(111,151,174,.20);
  }
:where([data-theme="dark"]) .top-header-control {
    background:rgba(24,40,49,.72);
    border-color:rgba(111,151,174,.22);
  }
:where([data-theme="dark"]) .section-pill {
    background:rgba(47,55,38,.82);
    border-color:rgba(154,169,119,.20);
  }
:where([data-theme="dark"]) .recipe-card,
:where([data-theme="dark"]) .abstract-list__surface,
:where([data-theme="dark"]) .content-card,
:where([data-theme="dark"]) .page-block--intro,
:where([data-theme="dark"]) .page-block--empty,
:where([data-theme="dark"]) .recipe-card-state {
    border-color:rgba(93,128,149,.26);
  }
:where([data-theme="dark"]) .drawer-item.is-active {
    background:linear-gradient(180deg,#243c56,#20374c);
    border-color:rgba(74,127,212,.48);
  }
:where([data-theme="dark"]) .drawer-item__icon {
    background:rgba(74,127,212,.12);
    color:#6d9be3;
  }



@media (min-width:700px) {
  :root { --page-inline-pad:28px; }
}

@media (min-width:900px) {
  :root {
    --shell-max-w:1080px;
    --chrome-max-w:1120px;
    --page-inline-pad:32px;
    --top-header-content-h:56px;
    --primary-nav-h:72px;
  }

  .top-header__inner {
    padding-left:max(20px, env(safe-area-inset-left));
    padding-right:max(20px, env(safe-area-inset-right));
  }

  .top-header-control { min-height:42px; }
  .top-header__status { padding-inline:14px; }
  .top-header__panel-button { width:46px; }
  .page-surface { gap:18px; padding-bottom:28px; }
  .content-card-grid { grid-template-columns:repeat(3,minmax(0,1fr)); gap:14px; }
  .recipe-card-grid { grid-template-columns:repeat(3,minmax(0,1fr)); gap:14px; }
  .primary-nav__inner { padding-inline:12px; }
  .primary-nav .shell-control { font-size:10.5px; }
  .edge-drawer { width:min(36vw,400px); }
}

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

/* Shared remote-list interaction. Data chooses whether a row is actionable; CSS owns appearance. */
.abstract-list__row--interactive {
  width:100%;
  margin:0;
  border:0;
  border-bottom:1px solid var(--border);
  border-radius:0;
  background:transparent;
  color:inherit;
  text-align:left;
  cursor:pointer;
  appearance:none;
}
.abstract-list__row--interactive:last-child { border-bottom:0; }
.abstract-list__row--interactive:active { background:color-mix(in srgb, var(--accent) 7%, transparent); }
.abstract-list__row--interactive:focus-visible {
  position:relative;
  z-index:1;
  outline:2px solid color-mix(in srgb, var(--accent) 62%, transparent);
  outline-offset:-2px;
}

/* Shared marker for inspectable linked ingredient/product information. */
.ingredient-info-marker {
  flex:0 0 18px;
  width:18px;
  height:18px;
  display:grid;
  place-items:center;
  border:1px solid color-mix(in srgb, var(--accent) 58%, var(--border));
  border-radius:50%;
  background:color-mix(in srgb, var(--accent) 9%, transparent);
  color:var(--accent);
  opacity:.74;
  transition:opacity 120ms ease, background-color 120ms ease;
}
.ingredient-info-marker__icon {
  font-size:10px;
  font-weight:850;
  line-height:1;
}
.abstract-list__row--interactive:hover .ingredient-info-marker,
.abstract-list__row--interactive:focus-visible .ingredient-info-marker {
  opacity:1;
  background:color-mix(in srgb, var(--accent) 15%, transparent);
}

/* Shared recipe detail view. Recipe JSON supplies content only; app CSS owns layout. */
.recipe-detail {
  width:100%;
  display:grid;
  gap:14px;
}

.recipe-detail__hero {
  overflow:hidden;
  border:1px solid var(--border);
  border-radius:18px;
  background:color-mix(in srgb, var(--surface) 90%, transparent);
  box-shadow:0 8px 28px rgba(30,42,35,.045);
}

.recipe-detail__header { padding:18px; }
.recipe-detail__title {
  font-size:1.36rem;
  line-height:1.15;
  letter-spacing:-.025em;
}
.recipe-detail__description {
  margin-top:8px;
  color:var(--muted);
  font-size:.86rem;
  line-height:1.5;
}
.recipe-detail__description-section {
  padding:13px 14px;
  border:1px solid var(--border);
  border-radius:15px;
  background:color-mix(in srgb, var(--surface) 88%, transparent);
}
.recipe-detail__description-section .recipe-detail__description { margin:0; }

.recipe-detail__facts {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:8px;
}
.recipe-detail__fact {
  min-width:0;
  padding:11px 12px;
  display:grid;
  gap:3px;
  border:1px solid var(--border);
  border-radius:13px;
  background:color-mix(in srgb, var(--surface) 90%, transparent);
}
.recipe-detail__fact-label {
  color:var(--muted);
  font-size:.68rem;
  font-weight:720;
}
.recipe-detail__fact-value {
  overflow:hidden;
  font-size:.86rem;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.recipe-detail__taxonomy {
  display:grid;
  gap:9px;
  padding:12px 13px;
  border:1px solid var(--border);
  border-radius:15px;
  background:color-mix(in srgb, var(--surface) 90%, transparent);
}
.recipe-detail__taxonomy-group { display:grid; gap:6px; }
.recipe-detail__taxonomy-label {
  color:var(--muted);
  font-size:.68rem;
  font-weight:740;
}
.recipe-detail__tags {
  display:flex;
  flex-wrap:wrap;
  gap:6px;
}
.recipe-detail__tag {
  padding:5px 8px;
  border:1px solid var(--border);
  border-radius:999px;
  background:var(--surface-2);
  font-size:.69rem;
  font-weight:700;
  line-height:1;
}

.recipe-detail__section { min-width:0; }
.recipe-detail__steps {
  margin:0;
  padding:0;
  overflow:hidden;
  list-style:none;
  counter-reset:recipe-step;
  border:1px solid var(--border);
  border-radius:15px;
  background:var(--surface);
}
.recipe-detail__step {
  counter-increment:recipe-step;
  min-height:52px;
  display:grid;
  grid-template-columns:28px minmax(0,1fr);
  gap:10px;
  align-items:start;
  padding:12px 14px;
  border-bottom:1px solid var(--border);
  font-size:.82rem;
  line-height:1.45;
}
.recipe-detail__step:last-child { border-bottom:0; }
.recipe-detail__step::before {
  content:counter(recipe-step);
  width:24px;
  height:24px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:var(--surface-2);
  color:var(--muted);
  font-size:.67rem;
  font-weight:800;
}

.recipe-detail__source {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:11px 13px;
  border:1px solid var(--border);
  border-radius:13px;
  background:color-mix(in srgb, var(--surface) 88%, transparent);
}
.recipe-detail__source-label { color:var(--muted); font-size:.7rem; font-weight:720; }
.recipe-detail__source-value { min-width:0; overflow-wrap:anywhere; font-size:.76rem; font-weight:700; text-align:right; }

@media (max-width:520px) {
  .recipe-detail__facts { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .recipe-detail__fact { padding:9px 8px; }
  .recipe-detail__fact-label { font-size:.62rem; }
  .recipe-detail__fact-value { font-size:.78rem; }
}

/* Shared actionable subheader controls. Inert controls remain non-interactive until they receive a page action. */
.subheader-control--actionable {
  pointer-events:auto;
  cursor:pointer;
}
.subheader-control--actionable:active {
  background:color-mix(in srgb,var(--accent) 14%,var(--surface));
  border-color:color-mix(in srgb,var(--accent) 58%,var(--border));
}
.subheader-control--actionable:focus-visible {
  outline:2px solid color-mix(in srgb, var(--accent) 62%, transparent);
  outline-offset:2px;
}

/* Shared add-to-menu action panel. Compact floating treatment follows Kitcherette's contextual menu language. */
.add-menu-dialog {
  position:fixed;
  inset:auto max(14px,calc((100vw - min(100vw,var(--chrome-max-w))) / 2 + 14px)) calc(var(--bottom-stack-h) + 14px) auto;
  width:min(370px,calc(100vw - 28px));
  max-width:none;
  margin:0;
  padding:0;
  border:0;
  background:transparent;
  color:var(--text);
}
.add-menu-dialog::backdrop { background:rgba(10,18,14,.20); }
.add-menu-dialog__panel {
  overflow:hidden;
  border:1px solid color-mix(in srgb,var(--border) 92%,transparent);
  border-radius:21px;
  background:color-mix(in srgb,var(--surface) 90%,transparent);
  box-shadow:0 18px 46px rgba(10,18,14,.28);
}
.add-menu-dialog__heading {
  display:grid;
  gap:4px;
  padding:17px 18px 15px;
  border-bottom:1px solid color-mix(in srgb,var(--border) 88%,transparent);
}
.add-menu-dialog__title { font-size:1rem; font-weight:790; }
.add-menu-dialog__recipe {
  color:var(--muted);
  font-size:.76rem;
  line-height:1.35;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.add-menu-dialog__field {
  min-height:62px;
  padding:8px 14px 8px 18px;
  display:grid;
  grid-template-columns:minmax(0,1fr) 82px;
  align-items:center;
  gap:12px;
  border-bottom:1px solid color-mix(in srgb,var(--border) 88%,transparent);
}
.add-menu-dialog__label { color:var(--text); font-size:.88rem; font-weight:680; }
.add-menu-dialog__input {
  width:82px;
  min-height:42px;
  padding:0 10px;
  border:1px solid color-mix(in srgb,var(--border) 92%,transparent);
  border-radius:11px;
  background:color-mix(in srgb,var(--surface-2) 82%,transparent);
  color:var(--text);
  text-align:center;
  font-size:.96rem;
  font-weight:760;
  outline:none;
}
.add-menu-dialog__input:focus {
  border-color:color-mix(in srgb,var(--accent) 62%,var(--border));
  box-shadow:0 0 0 2px color-mix(in srgb,var(--accent) 14%,transparent);
}
.add-menu-dialog__actions { display:grid; }
.add-menu-dialog__button {
  min-height:61px;
  padding:0 18px;
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:11px;
  border:0;
  border-radius:0;
  background:transparent;
  color:var(--text);
  font:inherit;
  font-size:.91rem;
  font-weight:650;
  text-align:left;
  cursor:pointer;
}
.add-menu-dialog__button + .add-menu-dialog__button {
  border-top:1px solid color-mix(in srgb,var(--border) 88%,transparent);
}
.add-menu-dialog__button:active { background:color-mix(in srgb,var(--accent) 10%,transparent); }
.add-menu-dialog__button[hidden] { display:none; }
.add-menu-dialog__button--primary { color:var(--text); }
.add-menu-dialog__button--primary .add-menu-dialog__button-icon { color:var(--accent); }
.add-menu-dialog__button-icon {
  width:20px;
  height:20px;
  flex:0 0 20px;
  display:grid;
  place-items:center;
  color:var(--muted);
}
@media (min-width:900px) {
  .add-menu-dialog {
    width:390px;
    inset:auto max(24px,calc((100vw - var(--chrome-max-w)) / 2 + 24px)) calc(var(--bottom-stack-h) + 18px) auto;
  }
}

/* Global optional category selector. Pages only opt into a JSON category set; shell owns presentation. */
.category-grid-dialog {
  position:fixed;
  inset:auto 14px calc(var(--bottom-chrome-h) + env(safe-area-inset-bottom) + 8px);
  width:min(calc(100vw - 28px),680px);
  max-width:none;
  max-height:min(64dvh,560px);
  margin:0 auto;
  padding:0;
  border:0;
  background:transparent;
  color:var(--text);
  overflow:visible;
}
.category-grid-dialog::backdrop { background:rgba(10,18,14,.18); backdrop-filter:blur(2px); }
.category-grid-dialog__panel {
  max-height:min(64dvh,560px);
  overflow:auto;
  padding:10px;
  border:1px solid color-mix(in srgb,var(--border) 92%,transparent);
  border-radius:18px;
  background:color-mix(in srgb,var(--surface) 91%,transparent);
  box-shadow:0 10px 34px rgba(15,24,19,.18);
}
.category-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; }
.category-grid__item {
  min-width:0; min-height:92px; padding:10px 5px; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:8px;
  border:1px solid var(--border); border-radius:15px; background:color-mix(in srgb,var(--surface-2) 82%,transparent); color:var(--text);
  font:inherit; cursor:pointer;
}
.category-grid__icon { width:24px; height:24px; display:grid; place-items:center; color:var(--muted); font-size:1.35rem; }
.category-grid__label { overflow-wrap:anywhere; min-width:0; max-width:100%; white-space:normal; font-size:.72rem; font-weight:760; line-height:1.25; }
.category-grid__item.is-active { border-color:color-mix(in srgb,var(--accent) 74%,var(--border)); background:color-mix(in srgb,var(--accent) 13%,var(--surface)); color:var(--text); box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--accent) 24%,transparent); }
.category-grid__item.is-active .category-grid__icon { color:var(--accent); }
.category-grid__item:focus-visible { outline:2px solid color-mix(in srgb,var(--accent) 62%,transparent); outline-offset:2px; }
@media (min-width:700px) {
  .category-grid-dialog { inset-inline:50%; transform:translateX(-50%); width:min(680px,calc(100vw - 48px)); }
  .category-grid__item { min-height:96px; }
  .category-grid { grid-template-columns:repeat(4,minmax(0,1fr)); }
}
@media (min-width:1100px) {
  .category-grid { grid-template-columns:repeat(5,minmax(0,1fr)); }
}


/* Shared recipe-card actions: compact floating menu beside the triggering control. */
.recipe-context-dialog {
  position:fixed;
  inset:8px auto auto 8px;
  width:min(228px,calc(100vw - 16px));
  max-width:none;
  margin:0;
  padding:0;
  border:0;
  border-radius:14px;
  overflow:auto;
  background:transparent;
  color:var(--text);
}
.recipe-context-dialog::backdrop { background:rgba(10,18,14,.12); }
.recipe-context-dialog__panel {
  padding:5px 6px;
  border:1px solid var(--border);
  border-radius:14px;
  background:color-mix(in srgb,var(--surface) 97%,transparent);
  box-shadow:0 10px 30px rgba(10,18,14,.22);
}
.recipe-context-dialog__panel:focus { outline:none; }
.recipe-context-dialog__action {
  width:100%;
  min-height:44px;
  padding:10px 11px;
  display:flex;
  align-items:center;
  border:0;
  border-radius:7px;
  background:transparent;
  color:var(--text);
  font:inherit;
  font-size:.88rem;
  font-weight:400;
  line-height:1.4;
  text-align:left;
  cursor:pointer;
}
.recipe-context-dialog__action:hover,
.recipe-context-dialog__action:active { background:color-mix(in srgb,var(--accent) 10%,transparent); }
.recipe-context-dialog__action--danger { gap:8px; color:var(--status-offline); }
.recipe-context-dialog__icon { width:16px; height:16px; flex:0 0 16px; }
.recipe-context-dialog__action:focus-visible { outline:2px solid var(--accent); outline-offset:-2px; }

/* Shared page editor: the page host scrolls, the shell retains navigation/actions. */
.recipe-edit-dialog--page { width:calc(100% - 16px); margin:12px 8px 0; min-width:0; color:var(--text); --accent:#366bea; }
.recipe-edit-dialog__panel {
  padding:20px 18px 24px; min-width:0; border:1px solid var(--border); border-radius:20px;
  background:color-mix(in srgb,var(--surface) 96%,transparent); box-shadow:0 10px 34px rgba(10,18,14,.15);
}
.recipe-edit-dialog__field { display:grid; min-width:0; gap:7px; margin-top:12px; }
.recipe-edit-dialog__label { color:var(--muted); font-size:.75rem; font-weight:600; }
.recipe-edit-dialog__input {
  width:100%; min-width:0; min-height:42px; padding:9px 10px; border:1px solid var(--border);
  border-radius:10px; background:color-mix(in srgb,var(--surface-2) 30%,transparent); color:var(--text); font:inherit; outline:none;
}
.recipe-edit-dialog__input:focus { border-color:var(--accent); box-shadow:0 0 0 1px var(--accent); }
.recipe-edit-dialog__input--textarea { min-height:104px; resize:vertical; border:0; border-bottom:1px solid var(--border); border-radius:0; background:transparent; }
.recipe-edit-dialog__field--name { margin:0 0 10px; }
.recipe-edit-dialog__field--name .recipe-edit-dialog__label { display:none; }
.recipe-edit-dialog__field--name input { padding:4px 0; border:0; border-radius:0; background:transparent; font-size:1.6rem; font-weight:600; }
.recipe-edit-dialog__field--name input:focus { box-shadow:none; }
.recipe-edit-dialog__compact-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:10px; margin:12px 0 0; }
.recipe-edit-dialog__compact-grid .recipe-edit-dialog__field { display:flex; flex-direction:column-reverse; gap:6px; }
.recipe-edit-dialog__compact-grid input { text-align:center; }
.recipe-edit-dialog--page input[type=number] { appearance:textfield; }
.recipe-edit-dialog--page input[type=number]::-webkit-inner-spin-button,
.recipe-edit-dialog--page input[type=number]::-webkit-outer-spin-button { appearance:none; margin:0; }
.recipe-edit-dialog__button { min-height:40px; padding:7px 12px; border:1px solid var(--border); border-radius:10px; background:var(--surface-2); color:var(--text); font:inherit; cursor:pointer; }
.recipe-editor-status:empty { display:none; }
.recipe-editor-status { margin-top:16px; color:var(--muted); font-size:.85rem; }
.page-subheader--editor { display:grid; grid-template-columns:1fr 1fr 1.5fr; align-items:center; gap:8px; padding:5px max(12px,calc((100vw - var(--chrome-max-w)) / 2)); }
.recipe-editor-action { min-width:0; height:38px; border:0; border-radius:12px; background:transparent; color:var(--text); font:inherit; font-size:.8rem; cursor:pointer; }
.recipe-editor-action--primary { color:white; background:#2862ec; box-shadow:inset 0 1px 0 rgba(255,255,255,.12); }
.recipe-editor-action:focus-visible { outline:2px solid #5b8cff; outline-offset:1px; }
.recipe-user-image--editor { margin:14px 0 20px; }
.recipe-user-image--editor .recipe-user-image__controls { padding:0; }
.recipe-user-image--editor .recipe-user-image__action { width:40px; height:40px; padding:0; border-style:dashed; border-radius:12px; font-size:0; }
.recipe-user-image--editor .recipe-user-image__action-icon { font-size:1.2rem; }
.recipe-user-image--editor .recipe-user-image__image { max-height:190px; width:100%; object-fit:cover; border-radius:14px; }

:where([data-theme="dark"]) .recipe-edit-dialog--page { --surface:#171f29; --surface-2:#202932; --text:#e1e5eb; --muted:#a9b3bf; --border:#34414d; }



.recipe-print-sheet { display:none; }
@media print {
  body > :not(.recipe-print-sheet) { display:none !important; }
  .recipe-print-sheet {
    display:block !important;
    position:static;
    padding:18mm;
    background:#fff;
    color:#111;
    font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
    font-size:11pt;
    line-height:1.45;
  }
  .recipe-print-sheet__title { margin:0 0 8mm; font-size:24pt; }
  .recipe-print-sheet__facts { display:flex; gap:10mm; margin-bottom:7mm; color:#444; }
  .recipe-print-sheet h2 { margin:8mm 0 3mm; font-size:15pt; }
  .recipe-print-sheet li { margin-bottom:2mm; }
  .recipe-print-sheet__description { margin-top:10mm; color:#444; }
}
@media (max-width:520px) {
  .recipe-card__actions { gap:2px; }
  .recipe-card__icon-action { width:34px; height:34px; }
}

/* Shared offline catalogue presentation. */
.catalogue__status { margin:0 0 10px; color:var(--muted); font-size:.8rem; }
.catalogue__entry { border-bottom:1px solid var(--border); }
.catalogue__entry:last-child { border-bottom:0; }
.catalogue__entry > summary { cursor:pointer; border-bottom:0; list-style:none; }
.catalogue__entry > summary::-webkit-details-marker { display:none; }
.catalogue__entry > summary::after { content:'›'; flex:0 0 auto; color:var(--muted); }
.catalogue__entry[open] > summary::after { transform:rotate(90deg); }
.catalogue__entry > summary:focus-visible { outline:2px solid var(--accent); outline-offset:-3px; }
.catalogue__label { display:grid; gap:4px; min-width:0; flex:1 1 auto; }
.catalogue__category { color:var(--muted); font-size:.72rem; line-height:1.4; overflow-wrap:anywhere; }
.catalogue__detail { padding:0 14px 14px; font-size:.8rem; overflow-wrap:anywhere; }
.catalogue__fact { margin:0 0 10px; line-height:1.5; }
.catalogue__profile { display:grid; gap:4px; padding:8px 0; border-bottom:1px solid var(--border); }
.catalogue__profile:last-child { border-bottom:0; }
.catalogue__empty { padding:16px; color:var(--muted); }
.catalogue__more { display:block; width:100%; min-height:40px; margin-top:12px; padding:8px 14px; border:1px solid var(--border); border-radius:12px; background:var(--surface); color:var(--text); font:inherit; font-size:.8rem; font-weight:750; cursor:pointer; }
.catalogue__more[hidden] { display:none; }
.catalogue__more:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }

.catalogue__reference { display:block; margin:8px 0; color:var(--text); text-decoration:underline; overflow-wrap:anywhere; }


/* Shared linked-recipe instruction controls and expandable library notes. */
.recipe-detail__mode-controls { display:flex; gap:8px; margin:10px 0; }
.recipe-detail__mode-button { padding:9px 14px; border:1px solid var(--border); border-radius:15px; background:var(--surface); color:var(--text); font:inherit; font-size:.8rem; cursor:pointer; }
.recipe-detail__mode-button[aria-pressed="true"] { border-color:var(--accent); background:color-mix(in srgb,var(--accent) 15%,var(--surface)); }
.recipe-detail__mode-button:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
.recipe-detail__notes { margin:10px 0; color:var(--muted); font-size:.8rem; }
.recipe-detail__notes summary { cursor:pointer; }
.recipe-detail__step > .recipe-detail__notes { grid-column:2; margin:4px 0 0; }

/* Linked recipe sections share the original Kitcherette form rhythm. */
.recipe-authoring__section { margin-top:22px; padding-top:18px; border-top:1px solid var(--border); min-width:0; }
.recipe-authoring__section h3 { margin:0 0 14px; padding-bottom:10px; border-bottom:1px solid var(--border); font-size:.8rem; letter-spacing:.035em; text-transform:uppercase; color:var(--muted); font-weight:650; }
.recipe-authoring__section:has(textarea) .recipe-edit-dialog__label { display:none; }
.recipe-authoring__section .recipe-authoring__category-heading { font-size:1rem; color:var(--text); text-transform:none; border:0; padding:0; margin-bottom:14px; }
.recipe-authoring__section:has(.category-grid) { border:0; padding-top:0; }
.recipe-authoring__section .category-grid { gap:6px; margin-inline:-6px; }
.recipe-authoring__section .category-grid__item { min-height:70px; border-radius:13px; padding:8px 2px; gap:6px; background:color-mix(in srgb,var(--surface-2) 60%,transparent); }
.recipe-authoring__section .category-grid__label { font-size:.66rem; font-weight:550; }
.recipe-authoring__section .category-grid__icon svg { width:24px; height:24px; }
.recipe-authoring__category-value .recipe-edit-dialog__label { display:none; }
.recipe-authoring__category-value select { border:0; border-radius:0; font-size:1rem; background:var(--surface-2); }
.recipe-authoring__row { min-width:0; margin:12px 0; padding:12px; border:1px solid var(--border); border-radius:12px; }
.recipe-authoring__row legend { font-weight:650; padding:0 5px; overflow-wrap:anywhere; }
.recipe-authoring__row > .recipe-edit-dialog__button { margin-top:12px; }
.recipe-edit-dialog__field[hidden] { display:none; }
.recipe-authoring__suggestions { display:grid; gap:6px; max-height:240px; overflow:auto; }
.recipe-authoring__suggestions button { text-align:left; padding:10px; height:auto; overflow-wrap:anywhere; }
.recipe-authoring__hint { color:var(--muted); font-size:.85rem; }
.recipe-authoring__hint:empty { display:none; }
.recipe-authoring__search .recipe-edit-dialog__label { display:none; }
.recipe-authoring__search input { border:0; border-bottom:1px solid var(--border); border-radius:0; padding-inline:4px; background:transparent; }
.recipe-authoring__reference { display:grid; grid-template-columns:22px minmax(0,1fr) 72px; align-items:center; gap:8px; margin:8px 0; }
.recipe-authoring__reference > span { overflow-wrap:anywhere; }
.recipe-authoring__reference .recipe-edit-dialog__input { padding:8px; }
.recipe-authoring__preview { overflow-wrap:anywhere; margin-top:14px; }
.recipe-authoring__preview li { margin-bottom:10px; }
.recipe-authoring__error { color:var(--text); font-weight:700; overflow-wrap:anywhere; margin-top:14px; }
.recipe-authoring__error:empty { display:none; }
.recipe-authoring__row--ingredient { padding:10px 0; border:0; border-bottom:1px solid var(--border); border-radius:0; }
.recipe-authoring__row--ingredient .recipe-authoring__ingredient-legend { position:absolute; width:1px; height:1px; clip-path:inset(50%); overflow:hidden; }
.recipe-authoring__ingredient-main { display:grid; grid-template-columns:minmax(0,1fr) 65px 48px; gap:6px; align-items:center; }
.recipe-authoring__ingredient-name { font-size:.92rem; overflow-wrap:anywhere; }
.recipe-authoring__ingredient-main .recipe-edit-dialog__field { margin:0; }
.recipe-authoring__ingredient-main .recipe-edit-dialog__label { display:none; }
.recipe-authoring__ingredient-main input { border:0; border-bottom:1px solid var(--border); border-radius:0; background:transparent; padding:6px 3px; }
.recipe-authoring__ingredient-details summary { color:var(--muted); font-size:.72rem; cursor:pointer; padding-top:10px; }
@media (min-width:700px) {
  .recipe-edit-dialog__panel { padding:28px; }
  .recipe-edit-dialog__field--name input { font-size:2rem; }
  .recipe-authoring__section .category-grid__item { min-height:85px; }
  .recipe-authoring__section .category-grid__label { font-size:.78rem; }
  .recipe-authoring__ingredient-main { grid-template-columns:minmax(0,1fr) 95px 65px; }
}

/* Ingredient references stay inline and use the existing exact-profile info flow. */
.recipe-detail__instruction { min-width:0; grid-column:2; overflow-wrap:anywhere; }
.recipe-instruction__ingredient {
  display:inline; padding:0; min-width:0; min-height:0; border:0; border-radius:3px;
  background:transparent; color:inherit; font:inherit; line-height:inherit;
  text-align:inherit; white-space:normal; cursor:pointer;
  text-decoration:underline; text-decoration-style:dotted; text-underline-offset:3px;
}
.recipe-instruction__ingredient:hover { color:var(--accent); }
.recipe-instruction__ingredient:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
.ingredient-information-dialog {
  width:min(640px,calc(100vw - 28px)); max-height:calc(100dvh - 48px); overflow:auto;
  padding:16px; border:1px solid var(--border); border-radius:18px;
  background:var(--surface); color:var(--text);
}
.ingredient-information-dialog::backdrop { background:rgba(10,18,14,.35); backdrop-filter:blur(2px); }
.ingredient-information-dialog > .ingredient-detail { padding:16px 0 0; }
.ingredient-information-dialog > .abstract-list__row { width:100%; text-align:left; }

/* Shared ingredient product inspection: recipe, preview and Knowledge base. */
.ingredient-products__note, .ingredient-products__status { color:var(--muted); font-size:.76rem; line-height:1.5; overflow-wrap:anywhere; }
.ingredient-products__search { display:grid; grid-template-columns:minmax(0,1fr) minmax(100px,.4fr); gap:10px; margin:12px 0; }
.ingredient-products__label { display:grid; gap:6px; min-width:0; font-size:.72rem; color:var(--muted); }
.ingredient-products__input { box-sizing:border-box; width:100%; min-width:0; min-height:44px; border:1px solid var(--border); border-radius:12px; background:var(--surface); color:var(--text); padding:9px 10px; font:inherit; font-size:.84rem; }
.ingredient-products__search > button { grid-column:1/-1; min-height:44px; margin:0; }
.ingredient-products__search > button:disabled { opacity:.55; cursor:wait; }
.ingredient-products__input:focus-visible, .ingredient-products__link:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
.ingredient-products__list { display:grid; gap:10px; }
.ingredient-products__item { min-width:0; padding:13px; border:1px solid var(--border); border-radius:14px; background:var(--surface); overflow-wrap:anywhere; }
.ingredient-products__item > strong { font-size:.9rem; }
.ingredient-products__meta { margin:6px 0; color:var(--muted); font-size:.75rem; line-height:1.5; }
.ingredient-products__ean { margin:8px 0; font-size:.8rem; font-variant-numeric:tabular-nums; }
.ingredient-products__link, .ingredient-products__note a { color:var(--text); font-size:.75rem; text-underline-offset:3px; }

/* Catalogue images share the existing rounded recipe thumbnail presentation. */
.catalogue__technique-summary { align-items:center; gap:12px; }
.catalogue__technique-summary .abstract-list__label { flex:1; min-width:0; }
.catalogue__image { display:block; object-fit:cover; border:1px solid var(--border); border-radius:12px; }
.catalogue__image[hidden] { display:none; }
.catalogue__image--small { flex:0 0 auto; width:64px; height:64px; }
.catalogue__image--large { width:min(100%,320px); height:auto; aspect-ratio:1; margin:8px 0 14px; border-radius:16px; }

/* Shared menu editing component; global chrome remains outside its scroll surface. */
.subheader-control--selector { justify-content:space-between; min-width:0; padding:0 16px; border-radius:22px; background:var(--surface); }
.subheader-control--selector .subheader-control__label { overflow:hidden; text-overflow:ellipsis; line-height:1.2; }
.subheader-control__chevron { flex:0 0 auto; font-size:1.1rem; }
.menu-draft { width:min(100%,760px); margin:0 auto; min-width:0; }
.menu-button { min-height:40px; border:1px solid var(--border); border-radius:16px; padding:8px 12px; background:color-mix(in srgb,var(--surface) 90%,transparent); color:var(--text); cursor:pointer; font-size:.84rem; }
.menu-button:disabled, .menu-dialog__option:disabled { opacity:.4; cursor:default; }
.menu-button:focus-visible, .menu-dish__information:focus-visible, .menu-dialog__option:focus-visible, .menu-dialog__recipe:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
.menu-button--icon { width:42px; min-height:42px; padding:0; display:inline-grid; place-items:center; border-color:transparent; background:transparent; font-size:1.25rem; flex:0 0 auto; }
.menu-button--primary { background:var(--accent); color:white; }
.menu-button--danger { color:#cf4444; }
.menu-draft__header { padding:10px 12px; border:1px solid var(--border); border-radius:21px; background:color-mix(in srgb,var(--surface) 94%,transparent); margin-bottom:10px; }
.menu-draft__title, .menu-draft__description { display:block; width:100%; min-width:0; padding:0; border:0; background:transparent; color:var(--text); }
.menu-draft__title { font-family:Georgia,'Times New Roman',serif; font-size:1.55rem; font-weight:700; line-height:1.35; }
.menu-draft__description { margin-top:8px; color:var(--muted); font-size:.85rem; line-height:1.4; resize:vertical; }
.menu-draft__description-area[hidden], .menu-draft__description-action[hidden] { display:none; }
.menu-draft__description-action { min-height:32px; margin-top:5px; padding:4px 0; border:0; background:transparent; color:var(--muted); font-size:.75rem; }
.menu-draft__metadata { display:flex; flex-wrap:wrap; align-items:center; column-gap:16px; }
.menu-inline-price { display:flex; align-items:center; gap:5px; min-width:0; color:var(--muted); font-size:.75rem; }
.menu-inline-price__amount { min-width:0; width:62px; height:28px; padding:1px 2px; border:0; border-bottom:1px solid var(--border); border-radius:0; background:transparent; color:var(--text); font:inherit; text-align:center; }
.menu-inline-price--menu .menu-inline-price__amount { width:70px; }
.menu-inline-price__currency { width:48px; height:28px; padding:0; border:0; background:transparent; color:var(--muted); font:inherit; cursor:pointer; }
.menu-inline-price__amount:focus-visible, .menu-inline-price__currency:focus-visible { outline:1px solid var(--accent); outline-offset:2px; border-radius:3px; }
.menu-inline-price__amount:invalid { border-color:var(--status-offline); }
.menu-dish__sell .menu-inline-price__amount { width:100%; max-width:65px; }
.swipe-confirmation { grid-area:controls; display:flex; align-items:center; gap:4px; min-width:0; height:28px; }
.swipe-confirmation__track { position:relative; flex:1; min-width:0; height:28px; border:1px solid color-mix(in srgb,var(--status-offline) 45%,var(--border)); border-radius:14px; background:color-mix(in srgb,var(--status-offline) 8%,var(--surface)); overflow:hidden; }
.swipe-confirmation__label { position:absolute; inset:0 8px 0 30px; display:grid; place-items:center; color:var(--status-offline); font-size:.65rem; pointer-events:none; }
.swipe-confirmation__range { appearance:none; -webkit-appearance:none; width:100%; height:26px; margin:0; padding:0; background:transparent; cursor:ew-resize; touch-action:none; position:relative; }
.swipe-confirmation__range::-webkit-slider-runnable-track { height:26px; background:transparent; }
.swipe-confirmation__range::-webkit-slider-thumb { appearance:none; -webkit-appearance:none; width:28px; height:26px; border:0; border-radius:13px; background:var(--status-offline); }
.swipe-confirmation__range::-moz-range-track { height:26px; background:transparent; }
.swipe-confirmation__range::-moz-range-thumb { width:28px; height:26px; border:0; border-radius:13px; background:var(--status-offline); }
.swipe-confirmation__range:focus-visible { outline:2px solid var(--accent); outline-offset:-2px; border-radius:13px; }
.swipe-confirmation__cancel { flex:0 0 28px; width:28px; height:28px; padding:0; border:0; border-radius:50%; background:transparent; color:var(--muted); font-size:1.2rem; cursor:pointer; }
.menu-price__fields { display:grid; grid-template-columns:minmax(0,1fr) 90px; gap:10px; }
.menu-price__actions { display:flex; flex-wrap:wrap; gap:8px; }
.menu-draft__title:focus-visible, .menu-draft__description:focus-visible { outline:1px solid var(--accent); outline-offset:4px; border-radius:4px; }
.menu-draft__description::placeholder { color:var(--muted); opacity:.7; }
.menu-draft__sections { display:grid; gap:10px; }
.menu-section { min-width:0; }
.menu-section__header { display:flex; align-items:center; gap:4px; padding:0 3px; }
.menu-section__header h3 { flex:1; min-width:0; padding-left:3px; color:var(--muted); font-size:.7rem; line-height:1.3; margin:0; font-weight:500; letter-spacing:.06em; text-transform:uppercase; overflow-wrap:anywhere; }
.menu-section__header .menu-button--icon { width:30px; min-height:28px; font-size:.95rem; }
.menu-section__header [aria-pressed="true"] { color:var(--accent); background:var(--surface-2); }
.menu-dish { --menu-card-padding:6px; --menu-thumbnail-width:52px; position:relative; margin:6px 0 0; touch-action:pan-y; }
.menu-dish:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
.menu-dish input { -webkit-user-select:text; user-select:text; }
.recipe-card.is-removing > .recipe-card__body { visibility:hidden; pointer-events:none; }
.card-swipe-action { position:absolute; inset:0; display:grid; grid-template-columns:minmax(0,1fr); grid-template-rows:auto minmax(0,1fr); gap:3px; padding:var(--menu-card-padding,8px); }
.card-swipe-action__heading { display:flex; align-items:center; gap:6px; min-width:0; }
.card-swipe-action__heading > .card-swipe-action__title { flex:1; min-width:0; margin:0; }
.card-swipe-action__heading > .swipe-confirmation__cancel { flex:0 0 32px; width:32px; height:28px; }
.swipe-confirmation--card { grid-area:auto; min-width:0; min-height:0; width:100%; height:auto; }
.swipe-confirmation--card .swipe-confirmation__track { height:100%; border-radius:12px; }
.swipe-confirmation--card .swipe-confirmation__label { inset:0 8px 0 48px; font-size:.78rem; line-height:1.3; text-align:center; }
.swipe-confirmation--card .swipe-confirmation__range { display:block; height:100%; }
.swipe-confirmation--card .swipe-confirmation__range::-webkit-slider-runnable-track { height:100%; }
.swipe-confirmation--card .swipe-confirmation__range::-webkit-slider-thumb { width:44px; height:100%; border-radius:11px; }
.swipe-confirmation--card .swipe-confirmation__range::-moz-range-track { height:100%; }
.swipe-confirmation--card .swipe-confirmation__range::-moz-range-thumb { width:44px; height:100%; border-radius:11px; }
.menu-dish .recipe-card__body { height:136px; display:grid; grid-template-columns:minmax(0,1fr); grid-template-areas:'recipe' 'details' 'controls'; grid-template-rows:minmax(0,1fr) 12px 28px; gap:3px 6px; align-items:stretch; padding:var(--menu-card-padding); }
.menu-dish .menu-dish__body--thumbnail { grid-template-columns:var(--menu-thumbnail-width) minmax(0,1fr); grid-template-areas:'media recipe' 'media details' 'media controls'; }
.menu-dish .menu-dish__body--thumbnail:has(> .recipe-user-image[hidden]) { grid-template-columns:minmax(0,1fr); grid-template-areas:'recipe' 'details' 'controls'; }
.menu-dish__recipe { grid-area:recipe; min-width:0; min-height:0; display:flex; flex-direction:column; gap:2px; padding-right:32px; }
.menu-dish__remove { position:absolute; top:3px; right:3px; width:32px; min-height:32px; padding:0; border:0; border-radius:6px; background:transparent; color:var(--status-offline); display:grid; place-items:center; cursor:pointer; }
.menu-dish__remove .nav-icon { width:16px; height:16px; }
.menu-dish__remove:hover { background:color-mix(in srgb,var(--status-offline) 12%,transparent); }
.menu-dish .recipe-card__open { align-self:stretch; align-items:flex-start; flex:none; min-height:0; padding:0; }
.menu-dish .recipe-card__copy { display:grid; grid-template-rows:auto auto; gap:2px; }
.menu-dish .recipe-card__title { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; font-size:.85rem; line-height:1.2; }
.menu-dish .recipe-card__meta { font-size:.69rem; line-height:1.25; -webkit-line-clamp:2; }
.menu-dish__details { grid-area:details; min-width:0; min-height:0; display:flex; align-items:center; gap:10px; overflow:hidden; }
.menu-dish .recipe-user-image--card { grid-area:media; position:absolute; inset:0 auto 0 0; width:calc(var(--menu-thumbnail-width) + var(--menu-card-padding)); height:auto; min-height:0; border:0; border-radius:0; overflow:hidden; -webkit-mask-image:linear-gradient(to right,#000 0%,#000 25%,transparent 100%); mask-image:linear-gradient(to right,#000 0%,#000 25%,transparent 100%); }
.menu-dish .recipe-user-image__image--card { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; }
.menu-dish__controls { grid-area:controls; min-width:0; display:grid; grid-template-columns:64px minmax(64px,.8fr) minmax(0,1fr); gap:4px; align-items:stretch; }
.menu-dish__controls[hidden] { display:none; }
.menu-dish__availability { min-width:0; }
.menu-dish__pantry { width:100%; height:28px; padding:1px 3px; border:0; border-radius:6px; background:color-mix(in srgb,var(--muted) 7%,transparent); color:var(--muted); font-size:.59rem; line-height:1.15; text-align:center; cursor:pointer; }
.menu-dish__pantry:focus-visible, .menu-dish__sell:focus-visible, .menu-dish__allergens:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
.menu-dish__warning { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; color:var(--status-offline); font-size:.6rem; line-height:1.25; }
.menu-dish__sell { min-width:0; height:28px; display:flex; align-items:center; justify-content:center; gap:2px; color:var(--text); font-size:.85rem; }
.menu-dish__prep, .menu-dish__allergens { margin:0; color:var(--muted); font-size:.61rem; line-height:1.3; overflow:hidden; }
.menu-dish__prep { white-space:nowrap; text-overflow:ellipsis; }
.menu-dish__allergens { flex:0 0 auto; border:0; padding:0; background:transparent; text-align:left; cursor:pointer; display:-webkit-box; -webkit-line-clamp:1; -webkit-box-orient:vertical; }
.menu-requirements { display:grid; gap:0; padding:0; margin:10px 0 0; list-style:none; }
.menu-requirements__item { display:grid; gap:5px; padding:12px 0; border-top:1px solid var(--border); font-size:.85rem; line-height:1.45; overflow-wrap:anywhere; }
.menu-requirements__stock { color:var(--muted); font-size:.75rem; }
.menu-dish__counts { height:28px; min-height:0; min-width:0; display:flex; align-items:stretch; gap:0; border:0; border-bottom:1px solid var(--border); border-radius:0; background:transparent; }
.menu-button--count { min-height:34px; width:30px; padding:0; border:0; border-radius:50%; font-size:1.1rem; background:color-mix(in srgb,var(--surface-2) 45%,transparent); }
.menu-dish__count { width:18px; min-width:0; height:27px; padding:0; text-align:center; color:var(--text); background:transparent; border:0; font-size:.85rem; border-radius:0; appearance:textfield; }
.menu-dish__count::-webkit-inner-spin-button, .menu-dish__count::-webkit-outer-spin-button { appearance:none; margin:0; }
.menu-section__add { width:100%; margin-top:6px; min-height:28px; padding:0; border-radius:18px; color:var(--muted); font-size:1rem; }
.menu-draft__add-section { margin-top:14px; border-radius:20px; color:var(--muted); }
.menu-draft__status { padding:10px 0; color:var(--muted); font-size:.8rem; }
.menu-section__empty, .menu-section__hint { padding:12px; color:var(--muted); font-size:.75rem; }
.menu-dish__ordering[hidden] { display:none; }
.menu-dish__ordering { grid-area:controls; display:flex; gap:4px; min-width:0; align-items:stretch; }
.menu-dish__ordering .menu-button { min-width:0; width:auto; min-height:28px; padding:0 5px; font-size:.6rem; }
.menu-dish__ordering .menu-button--icon, .menu-dish__ordering .menu-dish__drag { width:28px; flex:0 0 28px; }
.menu-dish__drag { touch-action:none; cursor:grab; min-width:40px; font-size:1.15rem !important; }
.is-drop-target { outline:2px solid var(--accent); outline-offset:2px; }
.menu-dialog { width:min(340px,calc(100vw - 32px)); max-height:calc(100dvh - 40px); border:1px solid var(--border); border-radius:18px; padding:0; background:var(--surface); color:var(--text); box-shadow:0 15px 50px rgba(0,0,0,.22); }
.menu-dialog--wide { width:min(520px,calc(100vw - 32px)); }
.menu-dialog::backdrop { background:rgba(0,0,0,.22); }
.menu-dialog__panel { padding:12px; }
.menu-dialog__heading { display:flex; align-items:center; gap:8px; margin-bottom:8px; }
.menu-dialog__heading h2 { flex:1; min-width:0; font-size:1rem; overflow-wrap:anywhere; }
.menu-dialog__form, .menu-dialog__field { display:grid; gap:10px; }
.menu-dialog__field { color:var(--muted); font-size:.82rem; }
.menu-dialog__input, .add-menu-dialog__select { width:100%; min-width:0; min-height:44px; padding:8px 10px; border:1px solid var(--border); border-radius:10px; background:var(--surface-2); color:var(--text); }
.menu-dialog__option, .menu-dialog__recipe { display:block; width:100%; padding:12px 8px; min-height:44px; text-align:left; border:0; border-bottom:1px solid var(--border); background:transparent; color:var(--text); cursor:pointer; font-size:.9rem; overflow-wrap:anywhere; }
.menu-dialog__option:last-child { border-bottom:0; }
.menu-dialog__option[aria-pressed="true"] { color:var(--accent); font-weight:700; }
.menu-dialog__option.menu-button--danger { color:#cf4444; }
.menu-dialog__recipe { display:flex; align-items:center; gap:10px; padding:8px; }
.menu-dialog__recipe-copy { display:grid; gap:4px; min-width:0; }
.menu-dialog__recipe .recipe-user-image--card { flex:0 0 48px; width:48px; height:48px; border-radius:9px; }
.menu-dialog__recipe-copy span { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.menu-dialog__recipe span, .menu-dialog__note { font-size:.78rem; line-height:1.4; color:var(--muted); }
.menu-dialog__note { padding:10px 0; }
.menu-dialog__results { max-height:50dvh; overflow-y:auto; overscroll-behavior:contain; }
.add-menu-dialog__destination { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); padding:0 18px; gap:12px; }
.add-menu-dialog__destination .add-menu-dialog__field { padding:0 0 12px; }
@media (min-width:768px) {
  .menu-draft__header { padding:12px 14px; }
  .menu-draft__title { font-size:1.85rem; }
  .menu-button--count { width:40px; min-height:40px; }
}

/* Common workbench and optional assistant import. */
.recipe-workbench__area { min-width:0; overflow-wrap:anywhere; }
.recipe-workbench__area h2 { margin-bottom:12px; font-size:1rem; }
.recipe-secretary__input { min-height:120px; }
.recipe-secretary__reply { font-size:.8rem; color:var(--muted); line-height:1.5; }
.recipe-secretary > button { margin:6px 6px 0 0; font-size:.78rem; }

/* Menu financial information shares the compact dish card and Menu state. */
.menu-draft__totals { color:var(--muted); font-size:.72rem; line-height:1.45; margin:14px 0 0; padding-top:10px; border-top:1px solid var(--border); }
.menu-draft__totals[hidden] { display:none; }
.menu-dish__pricing { white-space:nowrap; min-width:0; padding:0; border:0; background:transparent; color:var(--muted); text-align:left; font-size:.61rem; line-height:1.2; overflow:hidden; text-overflow:ellipsis; cursor:pointer; }
.menu-dish__pricing:focus-visible { outline:2px solid var(--accent); outline-offset:2px; border-radius:4px; }
.menu-dish__counts .menu-button--count { min-width:0; min-height:0; height:27px; width:23px; padding:0; border:0; border-radius:0; background:transparent; font-size:.85rem; }
.menu-dish-price__fields { display:grid; gap:12px; }

.app-settings__toggle { display:flex; justify-content:space-between; align-items:center; gap:16px; padding:12px 0; font-size:.9rem; cursor:pointer; }
.app-settings__toggle input { appearance:none; position:relative; width:36px; height:22px; margin:0; flex:0 0 36px; border:1px solid var(--border); border-radius:999px; background:var(--surface-2); cursor:pointer; }
.app-settings__toggle input::before { content:''; position:absolute; top:2px; left:2px; width:16px; height:16px; border-radius:50%; background:var(--muted); transition:transform .15s; }
.app-settings__toggle input:checked { background:var(--accent); }
.app-settings__toggle input:checked::before { transform:translateX(14px); background:white; }
.app-settings__toggle input:focus-visible { outline:2px solid var(--accent); outline-offset:3px; }
@media (min-width:768px) {
  .menu-dish { --menu-card-padding:8px; --menu-thumbnail-width:76px; }
  .menu-dish .recipe-card__body { height:148px; grid-template-rows:minmax(0,1fr) 14px 28px; column-gap:10px; }
  .menu-dish .recipe-card__title { font-size:.94rem; }
  .menu-dish .recipe-card__meta { font-size:.75rem; }
  .menu-dish__pricing { font-size:.68rem; }
  .menu-dish__pantry { font-size:.7rem; }
  .menu-dish__prep, .menu-dish__allergens { font-size:.64rem; }
}

/* Shared compact ingredient-list cards: Preparation and its supply lists. */
.recipe-detail__stages { display:grid; gap:10px; }
.recipe-detail__stage .page-section-title, .recipe-authoring__stage .page-section-title { margin:10px 0 6px; font-size:.72rem; }
.recipe-detail__stage-empty { list-style:none; color:var(--muted); font-size:.8rem; }
.recipe-detail__storage, .recipe-detail__portion-note { margin:4px 0; color:var(--muted); font-size:.76rem; line-height:1.4; }
.recipe-step__storage { border-top:1px solid var(--border); margin-top:6px; padding-top:5px; }
.preparation { width:min(100%,760px); margin:0 auto; min-width:0; }
.preparation__title { font-size:1.45rem; margin-bottom:12px; }
.preparation__lists { display:grid; gap:14px; }
.ingredient-list { min-width:0; }
.ingredient-list__header { display:flex; align-items:center; justify-content:space-between; gap:8px; min-height:28px; margin-bottom:5px; }
.ingredient-list__header .page-section-title { margin:0 0 0 3px; font-size:.7rem; line-height:1.3; font-weight:500; }
.ingredient-list__card { width:100%; }
.ingredient-list__row { display:flex; align-items:center; gap:7px; min-width:0; padding:6px 8px; }
.ingredient-list__row + .ingredient-list__row { border-top:1px solid var(--border); }
.ingredient-list__check-target { display:grid; place-items:center; flex:0 0 36px; width:36px; min-height:44px; cursor:pointer; }
.ingredient-list__check-target input { width:18px; height:18px; margin:0; accent-color:var(--accent); cursor:pointer; }
.ingredient-list__copy { flex:1; min-width:0; }
.ingredient-list__main { display:flex; flex-wrap:wrap; align-items:baseline; gap:2px 7px; font-size:.85rem; line-height:1.35; overflow-wrap:anywhere; }
.ingredient-list__main strong { font-weight:700; }
.ingredient-list__quantity { color:var(--muted); font-size:.78rem; }
.ingredient-list__support { margin:3px 0 0; color:var(--muted); font-size:.7rem; line-height:1.35; overflow-wrap:anywhere; }
.ingredient-list__warning { margin:3px 0 0; color:var(--status-offline); font-size:.7rem; line-height:1.4; overflow-wrap:anywhere; }
.ingredient-list__error { padding:8px 0; color:var(--status-offline); font-size:.8rem; line-height:1.4; }
.ingredient-list__error[hidden] { display:none; }
.ingredient-list__empty { padding:12px; color:var(--muted); font-size:.8rem; line-height:1.4; }
.ingredient-list__action { flex:0 0 auto; min-height:44px; max-width:88px; padding:5px 7px; border-radius:10px; font-size:.68rem; line-height:1.25; }
.ingredient-list__header .ingredient-list__action { max-width:150px; min-height:44px; border:0; padding:5px 0; background:transparent; color:var(--muted); text-align:right; }
.ingredient-list__remove { flex:0 0 28px; min-height:44px; padding:0; border:0; border-radius:8px; background:transparent; color:var(--muted); font-size:1.2rem; }
.ingredient-list__added { display:flex; flex-direction:column; align-items:center; justify-content:center; gap:3px; flex:0 0 58px; min-height:44px; color:var(--accent); font-size:.68rem; }
.ingredient-list__added .nav-icon { font-size:1rem; }
.ingredient-list__row.is-checked .ingredient-list__copy { opacity:.5; }
.ingredient-list__check-target:focus-within, .ingredient-list__remove:focus-visible { outline:2px solid var(--accent); outline-offset:1px; border-radius:8px; }
@media (min-width:768px) {
  .ingredient-list__row { padding:7px 12px; gap:10px; }
  .ingredient-list__main { font-size:.94rem; }
  .ingredient-list__quantity { font-size:.84rem; }
  .ingredient-list__support, .ingredient-list__warning { font-size:.76rem; }
  .ingredient-list__action { max-width:none; font-size:.76rem; padding:6px 10px; }
  .ingredient-list__header .ingredient-list__action { max-width:none; }
}

/* External recipe prompt reuses the editor workbench and contained scrolling. */
.recipe-exchange__prompt { margin:10px 0; }
.recipe-exchange__prompt textarea { min-height:180px; font-size:.75rem; white-space:pre-wrap; overflow-wrap:anywhere; }
.recipe-exchange__response { min-height:150px; }
.recipe-exchange__notes { padding-left:18px; font-size:.8rem; color:var(--muted); overflow-wrap:anywhere; }

/* Product catalogue uses the shared compact expandable catalogue rows. */
.ingredient-products--catalogue .ingredient-products__list { gap:0; }
.ingredient-products--catalogue .ingredient-products__list > .page-section-title { margin:12px 0 8px; }
.ingredient-products--catalogue .catalogue__label .ingredient-products__meta { margin:0; }

/* Recipe ingredient inspection stays immediately below its ingredient row. */
.recipe-ingredient__entry { min-width:0; border-bottom:1px solid var(--border); }
.recipe-ingredient__entry:last-child { border-bottom:0; }
.recipe-ingredient__summary { width:100%; cursor:pointer; list-style:none; border-bottom:0; }
.recipe-ingredient__summary::-webkit-details-marker { display:none; }
.recipe-ingredient__summary::marker { content:""; }
.recipe-ingredient__summary:focus-visible { outline:2px solid var(--accent); outline-offset:-2px; }
/* The opened reference sits inside (rather than extending) the ingredient card.
   One theme-aware surface provides separation in both light and dark mode. */
.recipe-ingredient__entry[open] > .recipe-ingredient__summary { background:color-mix(in srgb, var(--accent) 9%, var(--surface)); }
.recipe-ingredient__panel {
  margin:0 10px 12px;
  padding:12px 14px 14px;
  border:1px solid color-mix(in srgb, var(--border) 82%, var(--accent));
  border-left:3px solid color-mix(in srgb, var(--accent) 52%, var(--border));
  border-radius:11px;
  background:color-mix(in srgb, var(--accent) 12%, var(--surface-2));
  color:var(--text);
  box-shadow:0 2px 10px rgba(10,20,25,.10);
}
.ingredient-inline { min-width:0; }
.ingredient-inline__name { display:block; font-size:.9rem; margin:0 0 5px; }
.ingredient-inline__meta { margin:3px 0; font-size:.75rem; color:var(--muted); line-height:1.4; }
.recipe-ingredient__panel .ingredient-products {
  margin-top:12px;
  padding-top:10px;
  border-top:1px solid color-mix(in srgb, var(--border) 78%, transparent);
}
.recipe-ingredient__panel .ingredient-products .page-section-title { margin:0 0 5px; font-size:.8rem; }
.ingredient-products__item { padding:0; }
.ingredient-products__summary { display:flex; justify-content:space-between; align-items:center; gap:10px; cursor:pointer; padding:12px; font-size:.85rem; }
.ingredient-products__summary > .ingredient-products__meta { margin:0; }
.ingredient-products__summary:focus-visible { outline:2px solid var(--accent); outline-offset:2px; }
.ingredient-products__detail { padding:2px 12px 12px; border-top:1px solid var(--border); }
@media (max-width:480px) { .ingredient-products__summary { flex-wrap:wrap; gap:3px 8px; } .ingredient-products__summary > strong { width:100%; } }

/* v117: compact nutrition references inside the existing ingredient disclosure. */
.ingredient-inline__heading { display:flex; align-items:baseline; gap:5px 10px; flex-wrap:wrap; }
.ingredient-inline__name { display:inline; font-size:.88rem; line-height:1.35; margin:0; }
.ingredient-inline__category { color:var(--muted); font-size:.72rem; }
.ingredient-inline__aliases { font-size:.72rem; color:var(--muted); margin:3px 0 8px; }
.ingredient-inline__aliases > summary { cursor:pointer; width:fit-content; }
.ingredient-inline__aliases .ingredient-inline__meta { padding-left:12px; overflow-wrap:anywhere; }
.ingredient-nevo { padding:8px 0; margin:9px 0 6px; border-block:1px solid var(--border); }
.ingredient-nevo__heading { margin:0 0 5px; font-size:.76rem; font-weight:700; letter-spacing:.01em; }
.ingredient-nevo__status, .ingredient-nevo__sub, .ingredient-nevo__disclaimer { font-size:.7rem; color:var(--muted); line-height:1.35; }
.ingredient-nevo__status { margin:0 0 4px; }
.ingredient-nevo__item { border-radius:8px; border:1px solid var(--border); margin:4px 0; background:color-mix(in srgb,var(--surface) 72%,var(--surface-2)); }
.ingredient-nevo__summary { display:flex; flex-wrap:wrap; gap:2px 10px; padding:8px 10px; cursor:pointer; line-height:1.35; align-items:baseline; font-size:.77rem; }
.ingredient-nevo__summary > strong { font-weight:600; }
.ingredient-nevo__summary:focus-visible { outline:2px solid var(--accent); border-radius:8px; }
.ingredient-nevo__values { border-top:1px solid var(--border); padding:9px 10px; }
.ingredient-nevo__facts { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:5px 12px; }
.ingredient-nevo__fact { display:flex; justify-content:space-between; gap:5px; font-size:.74rem; }
.ingredient-nevo__fact > span { color:var(--muted); }
.ingredient-nevo__disclaimer { margin:8px 0 0; font-size:.66rem; }
.ingredient-nevo__search { font-size:.71rem; color:var(--muted); margin-top:6px; }
.ingredient-nevo__search > summary { cursor:pointer; }
.ingredient-nevo__input { display:block; margin:7px 0; width:100%; min-height:36px; background:var(--surface); border:1px solid var(--border); border-radius:8px; padding:6px 9px; color:var(--text); font-size:.78rem; }
.ingredient-products--compact .ingredient-products__note { margin:2px 0 4px; font-size:.7rem; }
.recipe-ingredient__panel .ingredient-products--compact { margin-top:5px; }
@media(max-width:380px) { .ingredient-nevo__facts { grid-template-columns:minmax(0,1fr); } }

/* v117: recipe content density — conserve vertical space, retain touch targets. */
.recipe-detail { gap:9px; }
.recipe-detail__header { padding:11px 13px; }
.recipe-detail__facts { gap:6px; }
.recipe-detail__fact { padding:7px 9px; gap:2px; }
.recipe-detail__taxonomy {
  display:flex; gap:6px 12px; flex-wrap:wrap; align-items:center;
  padding:0 2px; border:0; border-radius:0; background:transparent;
}
.recipe-detail__taxonomy-group { display:flex; flex-wrap:wrap; align-items:center; gap:5px; }
.recipe-detail__taxonomy-label { font-size:.64rem; }
.recipe-detail__tag { padding:4px 7px; }
.recipe-detail__step { min-height:44px; padding:9px 12px; }
.recipe-ingredient__panel { padding:10px 12px; margin:0 8px 9px; }

/* v118: a reviewed NEVO reference is visibly distinct from text-search suggestions */
.ingredient-nevo__item[data-link-status="approved"] { border-color: color-mix(in srgb, var(--accent) 48%, var(--border)); background: color-mix(in srgb, var(--accent) 8%, var(--surface)); }
.ingredient-nevo__retry { margin-top:5px; padding:6px 10px; color:var(--text); background:var(--surface); border:1px solid var(--border); border-radius:8px; cursor:pointer; }

/* v119: product lookup lives in a second-level disclosure, not a new page. */
.ean-search { margin-top:8px; border-top:1px solid var(--border); padding-top:8px; }
.ean-search__saved { display:grid; gap:5px; }
.ean-search__saved-title { margin:2px 0 5px; font-size:.71rem; font-weight:600; }
.ean-search__finder { padding:7px 9px; border:1px solid var(--border); border-radius:9px; background:color-mix(in srgb,var(--surface) 75%,transparent); font-size:.75rem; }
.ean-search__finder > summary { cursor:pointer; font-weight:600; }
.ean-search__controls { display:grid; grid-template-columns:minmax(0,1fr) auto; align-items:center; gap:4px 7px; margin-top:8px; }
.ean-search__controls .ingredient-nevo__input { margin:0; min-width:0; }
.ean-search__button,.ean-search__remove { border:1px solid var(--border); border-radius:8px; background:var(--surface); color:var(--text); padding:7px 9px; min-height:34px; cursor:pointer; font-size:.74rem; }
.ean-search__button:disabled { opacity:.6; cursor:wait; }
.ean-search__results { display:grid; gap:5px; margin-top:5px; }
.ean-search .ingredient-products__item { background:color-mix(in srgb,var(--surface) 78%,transparent); border-radius:9px; }
.ean-search__information { padding:5px 10px 9px; border-top:1px solid var(--border); }
.ean-search__detail { overflow-wrap:anywhere; margin:5px 0; font-size:.72rem; color:var(--muted); }
.ean-search .ingredient-products__item > button { margin:3px 10px 9px; }
@media(max-width:400px){.ean-search__controls { grid-template-columns:minmax(0,1fr); }}

/* OFF navigation fallback: visible only when browser API access fails. */
.ean-search__provider-link:not([hidden]) { display:inline-flex; align-items:center; margin:5px 0 1px; color:var(--text); font-size:.76rem; font-weight:600; text-decoration:underline; text-underline-offset:3px; }
.ean-search__provider-link:focus-visible { outline:2px solid var(--accent); outline-offset:3px; }

/* Preparation checklist: compact view, explicit selection, one primary action. */
.preparation--overview { width:min(100%,860px); }
.preparation__header { margin-bottom:4px; }
.preparation__heading { display:flex; align-items:center; justify-content:space-between; gap:10px; }
.preparation--overview .preparation__title { margin:0; font-size:1.15rem; }
.preparation__context { display:flex; align-items:center; gap:6px; color:var(--muted); font-size:.76rem; min-width:0; }
.preparation__context > span { overflow-wrap:anywhere; }
.preparation__edit,.preparation__select-mode { padding:4px 7px; min-height:36px; font-size:.72rem; border:0; background:transparent; color:var(--accent); }
.preparation__select-mode[hidden] { display:none; }
.preparation__notice { margin:2px 0 0; color:var(--muted); font-size:.69rem; line-height:1.35; }
.preparation__overview { margin-bottom:9px; }
.preparation__summary { display:flex; align-items:center; justify-content:space-between; gap:6px; min-height:25px; }
.preparation__summary-counts { font-size:.73rem; line-height:1.45; color:var(--muted); }
.preparation__readiness { margin-top:4px; }
.preparation__readiness progress { display:block; width:100%; height:3px; border:0; border-radius:3px; background:var(--border); accent-color:var(--accent); overflow:hidden; }
.preparation__readiness progress::-webkit-progress-bar { background:var(--border); border-radius:3px; }
.preparation__readiness progress::-webkit-progress-value { background:var(--accent); border-radius:3px; }
.preparation__readiness progress::-moz-progress-bar { background:var(--accent); border-radius:3px; }
.preparation--overview .preparation__lists { gap:8px; }
.preparation__section { border-radius:13px; overflow:hidden; }
.preparation__section-heading { display:flex; align-items:center; gap:5px 8px; padding:4px 10px; min-height:42px; cursor:pointer; list-style:none; }
.preparation__section-heading::-webkit-details-marker { display:none; }
.preparation__section-heading::after { content:'⌄'; color:var(--muted); font-size:1rem; }
.preparation__section:not([open]) .preparation__section-heading::after { content:'›'; }
.preparation__section-heading h3 { flex:1; margin:0; font-size:.79rem; font-weight:650; line-height:1.3; overflow-wrap:anywhere; }
.preparation__section[data-preparation-section=missing] .preparation__section-heading { border-left:3px solid color-mix(in srgb,var(--danger,#c66565) 65%,var(--border)); }
.preparation__section[data-preparation-section=available] .preparation__section-heading { border-left:3px solid color-mix(in srgb,var(--accent) 65%,var(--border)); }
.preparation__section[data-preparation-section=unknown] .preparation__section-heading { border-left:3px solid var(--muted); }
.preparation__section[open] .preparation__section-heading { border-bottom:1px solid var(--border); }
.preparation__add-all { padding:4px 6px; min-height:36px; font-size:.66rem; line-height:1.2; }
.preparation__section-note { margin:0; font-size:.7rem; line-height:1.4; color:var(--muted); }
.preparation__select input { accent-color:var(--accent); width:17px; height:17px; margin:0; cursor:pointer; }
.preparation__select { display:grid; place-items:center; min-height:44px; cursor:pointer; }
.preparation__select:focus-within { outline:2px solid var(--accent); outline-offset:-2px; border-radius:7px; }
.preparation__row { display:grid; grid-template-columns:minmax(0,1fr) auto; padding:3px 10px; min-height:64px; gap:0 8px; align-items:center; }
.preparation__row--selectable { grid-template-columns:32px minmax(0,1fr) auto; padding-left:3px; }
.preparation__row .ingredient-list__copy { display:contents; }
.preparation__row .ingredient-list__main { display:grid; grid-template-columns:minmax(0,1fr) auto; grid-column:1 / -1; align-items:start; gap:3px 9px; font-size:.82rem; }
.preparation__row .ingredient-list__main strong { min-width:0; font-weight:650; }
.preparation__ingredient-name { display:block; max-width:100%; min-height:24px; padding:2px 0; border:0; background:transparent; color:inherit; font:inherit; font-weight:650; text-align:left; overflow-wrap:anywhere; cursor:pointer; }
.preparation__ingredient-name:hover { text-decoration:underline; text-underline-offset:3px; }
.preparation__ingredient-name:focus-visible { outline:2px solid var(--accent); outline-offset:2px; border-radius:3px; }
.preparation__row .ingredient-list__quantity { padding-top:2px; color:var(--text); font-size:.79rem; font-weight:600; font-variant-numeric:tabular-nums; text-align:right; overflow-wrap:anywhere; }
.preparation__row .ingredient-list__support { grid-column:1; grid-row:2; margin:0; min-width:0; font-size:.68rem; line-height:1.4; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.preparation__row .ingredient-list__warning,.preparation__row .preparation__quantity-edit { grid-column:1 / -1; }
.preparation__row > .preparation__select { grid-column:1; grid-row:1 / 3; }
.preparation__quick-actions { grid-column:2; grid-row:2; display:flex; align-items:center; justify-content:flex-end; }
.preparation__quick-action { min-height:44px; padding:4px 7px; border:0; background:transparent; font-size:.7rem; line-height:1.3; color:var(--accent); white-space:nowrap; }
.preparation__on-list { display:inline-flex; align-items:center; min-height:44px; font-size:.7rem; color:var(--muted); }
.preparation__ready-mark { color:var(--accent); font-size:.78rem; }
.preparation__row--selectable .ingredient-list__main { grid-column:2 / -1; }
.preparation__row--selectable .ingredient-list__support { grid-column:2; }
.preparation__row--selectable .preparation__quick-actions { grid-column:3; }
.preparation__row--selectable .ingredient-list__warning,.preparation__row--selectable .preparation__quantity-edit { grid-column:2 / -1; }
.preparation__quantity-edit { display:flex; flex-wrap:wrap; align-items:center; gap:5px; margin-top:5px; color:var(--muted); font-size:.68rem; }
.preparation__quantity-edit input { width:90px; min-width:0; min-height:36px; padding:4px 6px; border:1px solid var(--border); border-radius:7px; background:var(--surface); color:var(--text); font-size:.77rem; }
.preparation__toolbar { display:flex; align-items:center; flex-wrap:wrap; gap:5px 10px; margin:0 0 10px; padding:8px 10px; background:var(--surface); border:1px solid var(--border); border-radius:12px; font-size:.74rem; }
.preparation__toolbar[hidden] { display:none; }
.preparation__toolbar-actions { display:flex; flex-wrap:wrap; gap:5px; }
.preparation__toolbar-actions .menu-button { min-height:40px; padding:5px 8px; font-size:.7rem; }
.preparation__toolbar .preparation__section-note { padding:2px 0; flex-basis:100%; }
.preparation__feedback { font-size:.76rem; line-height:1.4; color:var(--accent); margin:3px 0 7px; }
.preparation__feedback[hidden] { display:none; }
.preparation__row-actions { display:grid; gap:7px; }
.preparation__row-actions .menu-button { text-align:left; min-height:44px; }
.preparation__portion-field { display:flex; justify-content:space-between; align-items:center; gap:10px; }
.preparation__portion-field .menu-dialog__input { max-width:90px; }
.preparation__receipt { border-top:1px solid var(--border); padding:10px 0; display:grid; gap:6px; }
.preparation__receipt .menu-dialog__field { display:flex; align-items:center; gap:8px; justify-content:space-between; flex-wrap:wrap; }
.preparation__receipt .menu-dialog__input { flex:1; min-width:105px; max-width:230px; }
.preparation__unit { font-size:.75rem; color:var(--muted); }
.preparation__receipt-form > .menu-button { margin-top:10px; }
.preparation__buy-item { margin:8px 0; border:1px solid var(--border); border-radius:10px; padding:9px 11px; background:var(--surface-2); }
.preparation__buy-summary { font-size:.83rem; font-weight:650; cursor:pointer; }
.preparation__buy-item > .ingredient-products,.preparation__buy-item > .ean-search { margin-top:10px; }
@media(max-width:400px){
 .preparation__section-heading { padding:4px 8px; }
 .preparation__section-heading h3 { font-size:.75rem; }
 .preparation__add-all { max-width:95px; }
}

/* Shared stage headings and instruction controls. */
.preparation__stage {display:grid;gap:8px;min-width:0;}
.preparation__stage-modes {margin:0 0 2px;}
.preparation__stage-summary {display:flex;justify-content:space-between;align-items:baseline;flex-wrap:wrap;gap:3px 10px;padding:8px 2px;cursor:pointer;list-style:none;font-size:.78rem;}
.preparation__stage-summary::-webkit-details-marker{display:none;}
.preparation__stage-summary::after {content:'▾';color:var(--muted);margin-left:auto;}
.preparation__stage-group:not([open]) .preparation__stage-summary::after{content:'▸';}
.preparation__stage-count {font-size:.71rem;color:var(--muted);font-variant-numeric:tabular-nums;}
.preparation__stage-content {padding:0;border:0;}
.preparation__stage-caution {margin:9px 0;font-size:.72rem;line-height:1.4;color:var(--muted);}
@media(max-width:440px){.preparation__stage-count{font-size:.67rem;}}

/* Mise en place / Cook: one compact recipe-style card per executable step. */
.preparation__stage-group {min-width:0;}
.preparation__step-list {display:grid;gap:8px;margin:5px 0 12px;padding:0;list-style:none;}
.preparation__step-card {display:block;padding:0;min-width:0;overflow-wrap:anywhere;border-radius:13px;cursor:pointer;}
.preparation__step-card.is-complete {border-color:color-mix(in srgb,var(--accent) 40%,var(--border));}
 .preparation__step-heading {display:flex;align-items:center;gap:8px;padding:8px 12px;min-height:48px;}
.preparation__step-toggle {flex:1;min-width:0;align-self:stretch;min-height:32px;padding:0;border:0;background:transparent;color:var(--text);text-align:left;font-size:.78rem;font-weight:650;line-height:1.35;cursor:pointer;}
.preparation__step-toggle[aria-disabled="true"] {cursor:default;}
.preparation__step-toggle:focus-visible,.preparation__step-review:focus-visible {outline:2px solid var(--accent);outline-offset:3px;border-radius:4px;}
.preparation__step-review {display:grid;place-items:center;flex:none;width:36px;height:32px;padding:0;border:0;border-radius:6px;background:transparent;color:var(--muted);font-size:.8rem;cursor:pointer;}
.preparation__step-review:hover {background:color-mix(in srgb,var(--accent) 10%,transparent);}
.preparation__step-body {padding:0 12px 12px;}
.preparation__step-body[hidden] {display:none;}
.preparation__step-body .preparation__stage-caution {margin:0 0 7px;}
.preparation__step-card[data-expanded="true"] {border-color:color-mix(in srgb,var(--accent) 40%,var(--border));}
.preparation__step-card.is-complete[data-expanded="false"] .preparation__step-toggle {color:var(--muted);}
@media(prefers-reduced-motion:no-preference){
 .preparation__step-card {transition:border-color .16s ease;}
 .preparation__step-card[data-expanded="true"] > .preparation__step-body {animation:preparation-step-reveal .16s ease;}
}
@keyframes preparation-step-reveal {from{opacity:0;transform:translateY(-3px);}to{opacity:1;transform:translateY(0);}}
.preparation__step-done {font-size:.68rem;color:var(--accent);flex:none;}
.preparation__step-card .recipe-detail__instruction {font-size:.84rem;line-height:1.45;}
.preparation__step-inputs,.preparation__step-output,.preparation__step-hint {margin:5px 0 0;font-size:.72rem;line-height:1.4;color:var(--muted);}
.preparation__step-output {font-weight:550;}
.preparation__actual-amounts {font-size:.72rem;margin-top:6px;}
.preparation__actual-amounts summary,.preparation__undo summary {cursor:pointer;color:var(--muted);}
.preparation__actual-row {display:grid;grid-template-columns:minmax(0,1fr) 80px 65px;align-items:center;gap:6px;margin-top:5px;}
.preparation__actual-row .menu-dialog__input {padding:6px;width:100%;min-width:0;font-size:.74rem;}
.preparation__undo {margin:6px 0;font-size:.75rem;}
.preparation__undo button {margin-top:6px;}


/* Compact recipe header retained from v136. */
.recipe-edit-dialog--conversational .recipe-edit-dialog__panel { padding:14px 14px 18px; }
.recipe-editor__hero { display:flex; align-items:center; gap:12px; min-width:0; }
.recipe-editor__hero .recipe-edit-dialog__field--name { flex:1 1 auto; min-width:0; margin:0; }
.recipe-editor__hero .recipe-edit-dialog__field--name input { font-size:1.4rem; min-height:48px; }
.recipe-editor__hero .recipe-user-image--editor { flex:0 0 auto; position:relative; margin:0; }
.recipe-editor__hero .recipe-user-image__controls { min-height:0; padding:0; }
.recipe-editor__hero .recipe-user-image--has-image { width:70px; height:70px; border-radius:12px; overflow:hidden; }
.recipe-editor__hero .recipe-user-image--has-image .recipe-user-image__image { width:100%; height:100%; object-fit:cover; border-radius:12px; }
.recipe-editor__hero .recipe-user-image--has-image .recipe-user-image__controls { position:absolute; inset:auto 3px 3px auto; display:flex; gap:2px; }
.recipe-editor__hero .recipe-user-image--has-image .recipe-user-image__action { width:24px; height:24px; min-height:24px; background:var(--surface); border-radius:7px; }
.recipe-editor__hero .recipe-user-image--has-image .recipe-user-image__action-icon { font-size:.8rem; }
.recipe-workbench--manual .recipe-edit-dialog__compact-grid { margin-top:8px; gap:8px; }
.recipe-workbench--manual .recipe-edit-dialog__compact-grid .recipe-edit-dialog__field { margin:0; gap:4px; }
.recipe-workbench--manual .recipe-edit-dialog__compact-grid .recipe-edit-dialog__input { min-height:36px; padding:6px; }
.recipe-workbench--manual .recipe-authoring__section { margin-top:12px; padding-top:10px; }
.recipe-workbench--manual .recipe-authoring__section h3 { margin-bottom:8px; padding-bottom:7px; font-size:.72rem; }
.recipe-editor__more { margin-top:9px; }
.recipe-editor__more > summary { font-size:.73rem; color:var(--muted); cursor:pointer; padding:6px 0; }
.recipe-editor__more > .recipe-edit-dialog__field { margin-top:8px; }

/* The existing editor now owns one instruction-first work surface. */
.recipe-edit-dialog--conversational.recipe-edit-dialog--page { width:min(calc(100% - 16px),860px); margin-inline:auto; }
.recipe-workbench--manual { display:block; }
.recipe-workbench--manual > .recipe-workbench__recipe { display:block; padding:0; border:0; background:transparent; }
.recipe-editor-extra { margin:12px 0; padding:8px 10px; border:1px solid var(--border); border-radius:12px; background:var(--surface-2); }
.recipe-editor-extra > summary { padding:4px; cursor:pointer; color:var(--muted); font-size:.8rem; }
.recipe-editor-extra .recipe-workbench__area { background:transparent; border:0; padding:8px 0; }
.recipe-editor__utility { display:flex; gap:8px; padding-top:10px; }
.recipe-step-card { margin:8px 0; border:1px solid var(--border); border-radius:13px; background:var(--surface); overflow:visible; }
.recipe-step-card[open] { border-color:color-mix(in srgb,var(--accent) 55%,var(--border)); }
.recipe-step-card.has-error { border-color:var(--status-offline); }
.recipe-step-card__summary { display:flex; flex-direction:column; gap:4px; list-style:none; padding:10px 12px; cursor:pointer; }
.recipe-step-card__summary::-webkit-details-marker { display:none; }
.recipe-step-card__summary:focus-visible { outline:2px solid var(--accent); outline-offset:-3px; border-radius:12px; }
.recipe-step-card__heading { font-size:.9rem; font-weight:650; overflow-wrap:anywhere; }
.recipe-step-editor__preview { font-size:.85rem; line-height:1.4; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; white-space:pre-line; }
.recipe-step-card[open] .recipe-step-editor__preview { display:none; }
.recipe-step-card__flow { font-size:.72rem; line-height:1.4; color:var(--muted); overflow-wrap:anywhere; }
.recipe-step-card__body { padding:0 12px 10px; border-top:1px solid var(--border); }
.recipe-step-editor .recipe-edit-dialog__field { margin:8px 0 0; gap:4px; }
.recipe-step-editor .recipe-edit-dialog__input { font-size:16px; min-height:38px; padding:7px 9px; }
.recipe-step-editor__instruction-field > .recipe-edit-dialog__label { display:none; }
.recipe-step-editor .recipe-step-editor__instruction { min-height:84px; border:0; border-radius:0; resize:vertical; background:transparent; padding:9px 0; line-height:1.5; }
.recipe-step-picker { min-width:0; }
.recipe-step-editor__parameters { display:grid; grid-template-columns:repeat(auto-fit,minmax(125px,1fr)); gap:6px 8px; }
.recipe-step-editor__parameters:empty,.recipe-step-editor__suggestions:empty { display:none; }
.recipe-step-editor__uses { margin-top:10px; }
.recipe-step-editor__chips { display:flex; flex-wrap:wrap; gap:5px; margin-top:5px; }
.recipe-step-editor__chip { display:flex; align-items:center; max-width:100%; border:1px solid var(--border); border-radius:14px; background:var(--surface-2); }
.recipe-step-editor__chip-label { border:0; background:transparent; color:var(--text); padding:7px 8px; font:inherit; font-size:.76rem; text-align:left; overflow-wrap:anywhere; }
.recipe-step-editor__chip-remove { background:transparent; border:0; color:var(--muted); padding:6px 8px; font-size:1rem; }
.recipe-step-editor__input-quantity { display:grid; grid-template-columns:minmax(0,1fr) minmax(70px,.7fr); gap:6px; }
.recipe-step-editor__input-quantity > button,.recipe-step-editor__input-quantity > p { grid-column:1/-1; }
.recipe-step-editor__suggestion { border:0; background:transparent; color:var(--accent); padding:6px 0; font:inherit; font-size:.76rem; text-align:left; cursor:pointer; }
.recipe-step-card__advanced { margin-top:10px; padding-top:8px; border-top:1px solid var(--border); }
.recipe-step-card__advanced > summary,.recipe-step-editor__technique-help > summary { color:var(--muted); font-size:.76rem; cursor:pointer; }
.recipe-step-editor__output-details { padding-top:6px; }
.recipe-step-editor__output-details h4 { margin:4px 0; font-size:.8rem; }
.recipe-step-editor__actions { display:flex; flex-wrap:wrap; gap:6px; margin-top:10px; }
.recipe-step-editor__actions button { min-height:32px; padding:5px 9px; font-size:.75rem; }
.recipe-step-editor__error { color:var(--status-offline); font-size:.78rem; line-height:1.4; }
.recipe-step-editor__error:empty { display:none; }
.recipe-step-editor__error p { margin:6px 0 0; }
.recipe-step-card__create { margin-top:8px; border:1px solid var(--border); border-radius:10px; padding:8px; }
.recipe-step-card__create[hidden] { display:none; }
.recipe-step-card__create-actions { display:flex; gap:6px; margin-top:10px; }
.recipe-step-card__create-actions button { flex:1; min-width:0; font-size:.8rem; }
.recipe-step-editor__parameter-create { border-bottom:1px solid var(--border); padding:6px 0; }
.recipe-instruction-popup { position:fixed; z-index:300; border:1px solid var(--border); border-radius:10px; padding:3px; background:var(--surface-2); color:var(--text); box-shadow:0 8px 24px #0003; overflow-y:auto; overscroll-behavior:contain; }
.recipe-instruction-popup[hidden] { display:none; }
.recipe-instruction-popup__option { display:flex; justify-content:space-between; gap:10px; align-items:center; min-height:39px; width:100%; text-align:left; padding:8px; background:transparent; border:0; border-radius:7px; color:inherit; font:inherit; font-size:.82rem; cursor:pointer; }
.recipe-instruction-popup__option small { color:var(--muted); font-size:.7rem; }
.recipe-instruction-popup__option:hover,.recipe-instruction-popup__option[aria-selected=true] { background:var(--surface); }
.recipe-instruction-popup__create { border-top:1px solid var(--border); color:var(--accent); }
body[data-recipe-editor] .bottom-chrome { bottom:var(--editor-keyboard-inset,0px); }
body[data-recipe-editor] .app-shell { bottom:calc(var(--bottom-stack-h) + var(--editor-keyboard-inset,0px)); }
/* v148: The mobile keyboard is the primary control surface while editing.
   Temporarily remove BOTH fixed editor actions and workspace navigation;
   reclaim the space rather than pushing them above the keyboard. */
@media (max-width:820px) and (pointer:coarse) {
  body[data-recipe-editor][data-recipe-typing] .bottom-chrome { display:none; }
  body[data-recipe-editor][data-recipe-typing] .app-shell { bottom:var(--editor-keyboard-inset,0px); }
}

.recipe-step-editor input,.recipe-step-editor textarea { scroll-margin-top:70px; scroll-margin-bottom:12px; }
/* v138: compact, action-first manual recipe and shared technique editing */
.recipe-step-editor__recognition:empty {display:none}
.recipe-step-editor__recognition {margin:0 0 5px}
.recipe-step-editor__recognition button {background:var(--surface-2);border:1px solid var(--border);border-radius:9px;padding:7px 10px;text-align:left;width:100%;}
.recipe-step-editor__mapping,.recipe-step-editor__questions {border-top:1px solid var(--border);margin-top:9px;padding-top:7px}
.recipe-step-editor__mapping > summary,.recipe-step-editor__questions > summary {cursor:pointer;font-size:.79rem;font-weight:600;color:var(--muted);padding:4px 0}
.recipe-step-editor__mapping .recipe-step-editor__uses {margin-top:5px}
.recipe-step-editor__mapping .recipe-step-editor__makes {margin:5px 0}
.recipe-step-editor__hint,.technique-definition-form__help {font-size:.75rem;color:var(--muted);line-height:1.4;margin:5px 0}
.recipe-step-editor__questions .recipe-step-editor__parameters {margin-top:7px}
.technique-definition-form {display:grid;gap:8px;min-width:0}
.technique-definition-form .recipe-edit-dialog__field {margin:0;}
.technique-definition-form textarea {min-height:65px;resize:vertical}
.technique-definition-form__params {display:grid;gap:8px}
.technique-definition-form__param {padding:8px;border:1px solid var(--border);border-radius:9px;display:grid;grid-template-columns:1fr 1fr;gap:6px}
.technique-definition-form__param > *:first-child {grid-column:1/-1}
.technique-definition-form__param > select {min-width:0}
.technique-library__editor {padding:12px;border:1px solid var(--border);border-radius:12px;margin:12px 0;background:var(--surface)}
.technique-library__editor[hidden] {display:none}
.technique-library__toolbar {display:flex;justify-content:flex-end}
.technique-definition-form .recipe-step-card__create-actions {display:flex;flex-wrap:wrap}
@media(max-width:400px){.technique-definition-form__param {grid-template-columns:1fr}.technique-definition-form__param > *:first-child{grid-column:auto}}

/* v140: instruction-first authoring, compact visible links, no large mapping form by default */
.recipe-step-editor .recipe-step-editor__instruction {min-height:56px;max-height:170px;padding:8px 0 5px;font-size:1rem;line-height:1.45;resize:vertical}
.recipe-step-editor__instruction-field {margin-top:3px!important}
.recipe-step-editor__technique-chooser {margin-top:5px;padding:2px 0}
.recipe-step-editor__technique-chooser > summary {color:var(--accent);font-size:.78rem;cursor:pointer;list-style:none;padding:5px 0}
.recipe-step-editor__edit-method {display:inline-flex;align-self:flex-start;border:0;background:transparent;color:var(--muted);font:inherit;font-size:.73rem;padding:3px 1px;margin:2px 0 0;cursor:pointer;text-decoration:underline;text-decoration-color:transparent;}
.recipe-step-editor__edit-method:hover,.recipe-step-editor__edit-method:focus-visible {color:var(--accent);text-decoration-color:currentColor;}
.technique-definition-form__storage[open] {padding:7px 0;border-top:1px solid var(--border);}
.technique-definition-form__storage .recipe-edit-dialog__field {margin:5px 0;}
.recipe-step-editor__technique-chooser > summary::-webkit-details-marker {display:none}
.recipe-step-editor__technique-chooser > summary:before {content:'⌄ ';color:var(--muted)}
.recipe-step-editor__technique-chooser[open] > summary:before {content:'⌃ '}
.recipe-step-editor__technique-chooser > .recipe-step-picker {margin-bottom:5px}
.recipe-step-editor__overview {display:grid;gap:2px;margin-top:6px}
.recipe-step-editor__compact-row {display:flex;align-items:baseline;gap:8px;min-width:0;min-height:27px}
.recipe-step-editor__compact-label {color:var(--muted);font-size:.75rem;min-width:35px}
.recipe-step-editor__compact-text {font-size:.82rem;min-width:0;flex:1;overflow-wrap:anywhere}
.recipe-step-editor__mini-action {flex:0 0 auto;border:0;background:transparent;color:var(--accent);font-size:.76rem;padding:5px 0 5px 5px;cursor:pointer}
.recipe-step-editor__compact-suggestion {display:block;text-align:left;border:1px solid var(--border);background:var(--surface-2);color:var(--accent);border-radius:8px;padding:7px 10px;font-size:.77rem;cursor:pointer;width:100%}
.recipe-step-editor__questions {border:1px solid var(--border);padding:6px 9px;border-radius:9px;background:var(--surface-2);margin-top:9px}
.recipe-step-editor__questions > summary {font-size:.78rem;font-weight:600;color:var(--text);padding:3px 0}
.recipe-step-editor__questions .recipe-step-editor__parameters {grid-template-columns:repeat(auto-fit,minmax(145px,1fr))}
.recipe-step-editor__questions .recipe-edit-dialog__field {margin:6px 0 0}
.recipe-step-editor__mapping {margin-top:8px}
.recipe-step-editor__mapping > summary {font-weight:400}
.recipe-step-editor__recognition button {padding:7px 9px;border-color:color-mix(in srgb,var(--accent) 45%,var(--border));color:var(--accent)}
.recipe-step-editor .recipe-step-card__body {padding-bottom:10px}

/* v141: keep ingredient entry and action writing lightweight */
.recipe-authoring__ingredient-simple {display:flex;flex-direction:column;gap:0;margin:5px 0;padding:7px 0 5px;border:0;border-bottom:1px solid var(--border);min-width:0;}
.recipe-authoring__ingredient-simple .recipe-authoring__ingredient-main {gap:8px;}
.recipe-authoring__ingredient-simple .recipe-authoring__ingredient-notes {border:0;margin:0;padding:0;}
.recipe-authoring__ingredient-notes > summary {font-size:.75rem;color:var(--muted);padding:4px 0;cursor:pointer;}
.recipe-authoring__remove-ingredient {font-size:.75rem!important;margin-top:5px;}
.recipe-authoring__suggestions:empty {display:none}
.recipe-step-editor__overview {margin:2px 0 0;}
.recipe-step-editor__inline-flow {display:flex;gap:5px 8px;flex-wrap:wrap;align-items:center;font-size:.78rem;color:var(--muted);line-height:1.3;min-height:20px}
.recipe-step-editor__inline-flow:empty {display:none}
.recipe-step-editor__inline-output {color:var(--text)}
.recipe-step-editor__arrange {padding:5px 0 0;margin-top:7px;border-top:1px solid var(--border)}
.recipe-step-editor__arrange > summary {font-size:.75rem;color:var(--muted);cursor:pointer}
.recipe-step-editor__arrange .recipe-step-editor__actions {margin-top:6px}
.recipe-step-editor__compact-suggestion {border:0;background:transparent;padding:4px 0;}

.recipe-step-editor__recognition {display:flex;gap:5px;flex-wrap:wrap;}
.recipe-step-editor__recognition .recipe-step-editor__completion {width:auto;max-width:100%;font-size:.77rem;border-radius:18px;padding:5px 9px;background:var(--surface-2);border:1px solid var(--border);color:var(--accent);}

/* v142: recipe entry stays as compact as ingredient entry. Never show a
   multi-line instruction box until the content itself needs multiple lines. */
.recipe-step-editor .recipe-step-editor__instruction,
.recipe-step-composer__input {
  display:block;width:100%;box-sizing:border-box;min-height:33px;max-height:176px;
  height:33px;margin:0;overflow-y:hidden;resize:none;
  padding:5px 0;border:0;border-radius:0;background:transparent;color:var(--text);
  font:inherit;font-size:1rem;line-height:1.4;
}
.recipe-step-editor .recipe-step-editor__instruction:focus,
.recipe-step-composer__input:focus {outline:none;border:0;box-shadow:none;}
.recipe-step-editor__instruction-field {margin:0!important;}
.recipe-step-editor__recognition {display:grid;gap:6px;margin:3px 0 0;max-height:170px;overflow-y:auto;}
.recipe-step-editor__recognition .recipe-step-editor__completion {
  width:100%;max-width:none;border:1px solid var(--border);background:var(--surface-2);
  border-radius:10px;padding:9px 12px;display:flex;align-items:center;justify-content:space-between;
  text-align:left;font-size:.9rem;color:var(--text);min-height:40px;
}
.recipe-step-editor__recognition .recipe-step-editor__completion small {font-size:.72rem;color:var(--muted);margin-left:10px;}
.recipe-step-editor__recognition .recipe-step-editor__completion[aria-selected=true] {border-color:var(--accent);}
.recipe-step-composer {border-bottom:1px solid var(--border);margin:9px 0 3px;padding:4px 8px;}
.recipe-step-composer:focus-within {border-color:var(--accent);}
.recipe-step-composer__input::placeholder {color:var(--muted);}

/* v143: remove is directly reachable; routine recipe writing is one compact
   text field followed by only unsatisfied transformation questions. */
.recipe-authoring__ingredient-row{display:flex;align-items:center;gap:6px;min-width:0;}
.recipe-authoring__ingredient-row .recipe-authoring__ingredient-main{flex:1;min-width:0;}
.recipe-authoring__remove-ingredient{
 flex:0 0 32px;width:32px;height:34px;min-height:34px;padding:0!important;
 margin:0!important;border:0;background:transparent;color:var(--muted);
 font-size:1.28rem!important;line-height:1;cursor:pointer;border-radius:8px;
}
.recipe-authoring__remove-ingredient:focus-visible,.recipe-step-editor__toolbar-button:focus-visible {outline:2px solid var(--accent)}
.recipe-step-card {position:relative;}
.recipe-step-card__summary {padding-right:85px;min-height:47px;}
.recipe-step-editor__toolbar{position:absolute;right:6px;top:6px;display:flex;align-items:center;gap:2px;z-index:2;}
.recipe-step-editor__toolbar-button{
 border:0;background:transparent;color:var(--muted);width:34px;height:34px;
 font-size:1.25rem;cursor:pointer;border-radius:8px;padding:0;line-height:1;
}
.recipe-step-editor__toolbar-button:hover,.recipe-authoring__remove-ingredient:hover{background:var(--surface-2)}
.recipe-step-editor__needs{display:grid;gap:5px;margin-top:5px;}
.recipe-step-editor__needs:empty{display:none;}
.recipe-step-editor__need{display:flex;align-items:center;gap:9px;min-width:0;min-height:34px;}
.recipe-step-editor__need-label{color:var(--muted);font-size:.77rem;min-width:65px;flex:0 0 65px;}
.recipe-step-editor__need-action{color:var(--accent);background:transparent;border:0;padding:6px 2px;
 font:inherit;font-size:.82rem;text-align:left;cursor:pointer;min-width:0;overflow-wrap:anywhere;}
.recipe-step-editor__need-input{flex:1;min-width:0;width:100%;font-size:16px;border:1px solid var(--border);
 background:var(--surface-2);color:var(--text);padding:6px 9px;border-radius:8px;min-height:35px;}
.recipe-step-editor__more{margin-top:4px;}
.recipe-step-editor__more > summary {position:absolute;left:-99999px;}
.recipe-step-editor__more:not([open]) {height:0;margin:0;padding:0;}
.recipe-step-editor__more[open]{border-top:1px solid var(--border);padding-top:7px;margin-top:8px;}
.recipe-step-editor__more[open] > .recipe-step-editor__technique-chooser,
.recipe-step-editor__more[open] > .recipe-step-editor__mapping {margin:5px 0;}
.recipe-step-card[open] .recipe-step-card__flow {display:none;}
.recipe-step-editor__overview:empty,.recipe-step-editor__suggestions:empty {display:none;}

.recipe-step-editor__needs[hidden]{display:none;}

/* Recipe step fat uses the same inline canonical ingredient suggestions as Ingredients. */
.recipe-step-editor__ingredient-search{flex:1;min-width:0;display:grid;gap:4px;}
.recipe-step-editor__ingredient-input{width:100%;}
.recipe-step-editor__ingredient-suggestions:empty{display:none;}
.recipe-step-editor__ingredient-suggestions{max-height:185px;overflow-y:auto;overscroll-behavior:contain;}
.recipe-step-editor__ingredient-option{display:flex;align-items:center;justify-content:space-between;gap:8px;width:100%;min-height:39px;padding:8px 10px;text-align:left;background:var(--surface-2);border:1px solid var(--border);border-radius:9px;color:var(--text);font:inherit;cursor:pointer;}
.recipe-step-editor__ingredient-option small{color:var(--muted);font-size:.7rem;white-space:nowrap;}
.recipe-step-editor__ingredient-option:focus-visible{outline:2px solid var(--accent);outline-offset:1px;}
.recipe-step-editor__ingredient-measure{flex:1;min-width:0;display:flex;gap:7px;}
.recipe-step-editor__ingredient-measure input:first-child{flex:2;min-width:0;}
.recipe-step-editor__ingredient-measure input:last-child{flex:1;min-width:65px;max-width:95px;}

/* v145: step title stays in the chef's words; validated technique method
   is shown only after its recipe-specific parameters are known. */
.recipe-step-editor__method-preview {margin:7px 0 3px;padding:8px 10px;border-radius:9px;
  border-left:2px solid var(--accent);background:var(--surface-2);
  font-size:.83rem;line-height:1.5;color:var(--muted);overflow-wrap:anywhere;}
.recipe-step-editor__method-preview[hidden]{display:none;}

/* v146: shared-ingredient fat row and compact value/unit controls */
.recipe-step-editor__ingredient-measure,.recipe-step-editor__measure-control{min-width:0;display:grid;grid-template-columns:minmax(0,1fr) minmax(66px,88px);gap:6px;align-items:center;}
.recipe-step-editor__ingredient-measure input,.recipe-step-editor__ingredient-measure select,.recipe-step-editor__measure-control input,.recipe-step-editor__measure-control select{width:100%;max-width:100%;min-width:0;box-sizing:border-box;}
.recipe-step-editor__measure-control{flex:1;}
.recipe-step-editor__measure-hint{font-size:.73rem;color:var(--muted);grid-column:1/-1;}
@media(max-width:420px){.recipe-step-editor__need-label{min-width:76px;flex-basis:76px;}.recipe-step-editor__ingredient-measure,.recipe-step-editor__measure-control{grid-template-columns:minmax(0,1fr) 70px;}}

/* v149 — Manual editor uses the recipe viewer's section pills and card surfaces.
   All form controls, focus handling, and saved recipe structures remain unchanged. */
.recipe-edit-dialog--conversational .recipe-edit-dialog__panel {
  padding:0 0 24px;
  border:0;
  border-radius:0;
  background:transparent;
  box-shadow:none;
}
.recipe-workbench--manual > .recipe-workbench__recipe {
  display:grid;
  gap:14px;
  min-width:0;
}
.recipe-editor__overview {
  padding:15px;
  min-width:0;
  border:1px solid var(--border);
  border-radius:18px;
  background:color-mix(in srgb,var(--surface) 92%,transparent);
}
.recipe-editor__overview .recipe-editor__hero {gap:10px;}
.recipe-editor__overview .recipe-editor__hero .recipe-edit-dialog__field--name {margin:0;}
.recipe-editor__overview .recipe-edit-dialog__compact-grid {margin-top:11px;}
.recipe-editor__overview .recipe-editor__more {margin-top:8px;}
.recipe-workbench--manual .recipe-authoring__section.recipe-editor__block {
  margin:0;
  padding:0;
  border:0;
  min-width:0;
}
.recipe-workbench--manual .recipe-editor__block > h3.section-pill {
  display:block;
  width:max-content;
  max-width:calc(100% - 6px);
  margin:0 0 7px 3px;
  padding:6px 10px;
  border:1px solid var(--border);
  border-radius:999px;
  background:color-mix(in srgb,var(--surface) 82%,transparent);
  color:var(--text);
  text-transform:none;
  letter-spacing:0;
  font-size:.72rem;
  font-weight:750;
  line-height:1;
}
.recipe-editor__section-surface {
  min-width:0;
  padding:8px 13px;
  border:1px solid var(--border);
  border-radius:15px;
  background:color-mix(in srgb,var(--surface) 92%,transparent);
}
.recipe-editor__section-surface--ingredients .recipe-authoring__ingredient-simple {
  margin:0;
  padding:10px 0 7px;
}
.recipe-editor__section-surface--ingredients .recipe-authoring__ingredient-simple:first-child {padding-top:4px;}
.recipe-editor__section-surface--ingredients .recipe-authoring__ingredient-simple:last-child {border-bottom:0;}
.recipe-editor__section-surface--ingredients .recipe-authoring__search {margin:5px 0 0;}
.recipe-editor__section-surface--ingredients .recipe-authoring__search .recipe-edit-dialog__input {
  padding:10px 4px;
}
.recipe-editor__section-surface--ingredients .recipe-authoring__suggestions {margin:5px 0 8px;}
.recipe-editor__section-surface--method {padding:4px 9px;}
.recipe-editor__method-list .recipe-step-card {
  margin:0;
  border:0;
  border-bottom:1px solid var(--border);
  border-radius:0;
  background:transparent;
  box-shadow:none;
}
.recipe-editor__method-list .recipe-step-card[open] {
  margin:5px 0;
  border:1px solid color-mix(in srgb,var(--accent) 58%,var(--border));
  border-radius:12px;
  background:color-mix(in srgb,var(--accent) 5%,var(--surface));
}
.recipe-editor__method-list .recipe-step-card.has-error {border-color:var(--status-offline);}
.recipe-editor__method-list .recipe-step-card__summary {
  display:grid;
  grid-template-columns:26px minmax(0,1fr);
  align-items:start;
  column-gap:9px;
  row-gap:3px;
  padding:10px 8px;
  padding-right:78px;
  min-height:46px;
}
.recipe-editor__method-list .recipe-step-card__number {
  grid-row:1 / span 3;
  width:25px;
  height:25px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:var(--surface-2);
  color:var(--muted);
  font-size:.71rem;
  font-weight:750;
}
.recipe-editor__method-list .recipe-step-card__heading {
  grid-column:2;
  font-weight:600;
  font-size:.91rem;
  line-height:1.45;
}
.recipe-editor__method-list .recipe-step-card__flow,
.recipe-editor__method-list .recipe-step-editor__preview {
  grid-column:2;
  font-size:.73rem;
  line-height:1.4;
}
.recipe-editor__method-list .recipe-step-card__body {padding:2px 12px 12px 43px;border-top:0;}
.recipe-editor__method-list .recipe-step-composer {
  margin:0;
  padding:11px 9px 9px 43px;
  border-bottom:0;
}
.recipe-editor__method-list .recipe-step-composer__input {font-size:.92rem;}
.recipe-editor__section-surface--notes {padding:5px 13px;}
.recipe-editor__section-surface--notes .recipe-edit-dialog__field {margin:0;}
.recipe-editor__section-surface--notes textarea {
  min-height:55px;
  padding:10px 0;
  border-bottom:0;
}
.recipe-editor__section-surface--preview .recipe-authoring__preview {margin:0;}
.recipe-editor__section-surface--preview .recipe-authoring__preview:empty {display:none;}
@media(max-width:420px) {
  .recipe-editor__overview {padding:13px;}
  .recipe-editor__section-surface {padding-inline:10px;}
  .recipe-editor__section-surface--method {padding-inline:6px;}
  .recipe-editor__method-list .recipe-step-card__body {padding-left:39px;}
  .recipe-editor__method-list .recipe-step-composer {padding-left:40px;}
}

/* v151: finished instructions become compact, readable recipe rows.
   The full method form remains accessible by tapping the row. */
.recipe-editor__method-list .recipe-step-card:not([open]) .recipe-step-card__summary {
  min-height:42px;
  row-gap:2px;
  padding-top:8px;
  padding-bottom:8px;
}
.recipe-editor__method-list .recipe-step-card:not([open]) .recipe-step-card__flow {
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  min-width:0;
}

/* v152: compact, always-visible input choices follow a recognised method.
   They use the recipe's own ingredient and previous-output references. */
.recipe-step-editor__quick-ingredients {margin:6px 0 9px; min-width:0;}
.recipe-step-editor__quick-ingredients[hidden] {display:none;}
.recipe-step-editor__quick-title {font-size:.75rem;color:var(--muted);margin:0 0 5px;}
.recipe-step-editor__quick-search {box-sizing:border-box;width:100%;min-width:0;border:1px solid var(--border);border-radius:9px;background:var(--surface-2);color:var(--text);font:inherit;font-size:.85rem;padding:9px 11px;outline-offset:1px;}
.recipe-step-editor__quick-search:focus {border-color:var(--accent);outline:1px solid var(--accent);}
.recipe-step-editor__quick-options {display:flex;gap:5px;flex-wrap:wrap;max-height:128px;overflow-y:auto;overscroll-behavior:contain;padding:7px 1px 2px;}
.recipe-step-editor__quick-options[hidden] {display:none;}
.recipe-step-editor__quick-choice {border:1px solid var(--border);background:var(--surface-2);color:var(--text);border-radius:16px;padding:6px 9px;font:inherit;font-size:.77rem;line-height:1.35;text-align:left;max-width:100%;overflow-wrap:anywhere;}
.recipe-step-editor__quick-choice.is-selected {border-color:var(--accent);color:var(--accent);}
.recipe-step-editor__quick-hint {font-size:.75rem;color:var(--muted);}

/* v153: unmatched techniques are offered inline, not hidden behind ellipsis. */
.recipe-step-editor__technique-unmatched {
  margin:7px 0 5px; padding:6px 9px 9px;
  border:1px solid var(--border); border-radius:10px;
  background:var(--surface-2);
}
.recipe-step-editor__technique-unmatched > summary {color:var(--muted);font-size:.77rem;}
.recipe-step-editor__technique-unmatched .recipe-step-picker {margin-top:6px;}
.recipe-step-editor__new-technique {
  margin-top:5px; min-height:34px; border:0; background:transparent;
  color:var(--accent); padding:5px 2px; font:inherit;font-size:.82rem; cursor:pointer;
}

/* v155: selected step inputs show their actual share of recipe quantities. */
.recipe-step-editor__quick-amount {border:0;background:transparent;color:var(--color-text-muted, #aebac8);font:inherit;font-size:.78rem;padding:.3rem .45rem;cursor:pointer;}
.recipe-step-editor__quick-quantity:empty {display:none;}
.recipe-step-editor__quick-quantity {padding:.4rem 0;}


/* v159: recipe-editor visual consolidation, model and entry behavior unchanged.
   Keep all selectors scoped so viewers, menu cards and other workspaces stay intact. */
.recipe-edit-dialog--conversational.recipe-edit-dialog--page {
  width:min(calc(100% - 24px),860px);margin-inline:auto;
}
.recipe-edit-dialog--conversational {--recipe-editor-radius:18px;}
.recipe-workbench--manual > .recipe-workbench__recipe {gap:16px;}
.recipe-edit-dialog--conversational .recipe-editor__overview,
.recipe-edit-dialog--conversational .recipe-editor__section-surface {
  border:1px solid color-mix(in srgb,var(--border) 91%,var(--text) 9%);
  border-radius:var(--recipe-editor-radius);
  background:color-mix(in srgb,var(--surface) 93%,transparent);
  box-shadow:0 8px 24px rgba(0,0,0,.095);
}
.recipe-edit-dialog--conversational .recipe-editor__overview {padding:18px 16px 14px;}
.recipe-edit-dialog--conversational .recipe-editor__hero {gap:14px;align-items:stretch;}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-edit-dialog__field--name {
  display:flex;flex-direction:column;justify-content:center;align-items:stretch;gap:4px;min-width:0;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-edit-dialog__field--name .recipe-edit-dialog__label {
  display:block;font-size:.64rem;font-weight:650;letter-spacing:.15em;text-transform:uppercase;
  color:var(--muted);
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-edit-dialog__field--name input {
  min-height:42px;max-width:100%;margin:0;padding:5px 0;background:transparent;border:0;
  font-size:clamp(1.35rem,4.8vw,1.85rem);font-weight:680;line-height:1.2;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-edit-dialog__field--name input::placeholder {
  color:var(--muted);opacity:.85;
}
/* The photo remains the same staged/persistent file-control, now a clear thumbnail tile. */
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor {
  width:clamp(96px,28%,140px);height:112px;flex:0 0 clamp(96px,28%,140px);
  margin:0;position:relative;isolation:isolate;overflow:hidden;
  border-radius:15px;border:1px solid color-mix(in srgb,var(--border) 80%,var(--accent) 20%);
  background:linear-gradient(135deg,color-mix(in srgb,var(--surface-2) 90%,var(--accent) 10%),var(--surface));
  box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--text) 5%,transparent);
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor:not(.recipe-user-image--has-image) {
  background:radial-gradient(circle at 76% 12%,color-mix(in srgb,var(--accent) 17%,transparent),transparent 66%),
   linear-gradient(145deg,var(--surface-2),color-mix(in srgb,var(--surface) 95%,transparent));
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor .recipe-user-image__controls {
  display:flex;justify-content:center;align-items:stretch;gap:5px;padding:0;min-height:0;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor:not(.recipe-user-image--has-image) .recipe-user-image__controls {
  width:100%;height:100%;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor .recipe-user-image__action--choose {
  border:0;background:transparent;color:var(--text);font-weight:630;cursor:pointer;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor:not(.recipe-user-image--has-image) .recipe-user-image__action--choose {
  width:100%;height:100%;min-height:0;display:flex;flex-direction:column;gap:6px;
  align-items:center;justify-content:center;padding:6px 5px;border-radius:14px;
  font-size:.71rem;line-height:1.2;text-align:center;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor:not(.recipe-user-image--has-image) .recipe-user-image__action-icon {
  display:grid;place-items:center;width:38px;height:38px;flex:0 0 38px;
  border:1px dashed color-mix(in srgb,var(--muted) 75%,transparent);border-radius:50%;
  font-size:1.4rem;font-weight:430;color:var(--text);
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor.recipe-user-image--has-image {
  width:clamp(96px,28%,140px);height:112px;border-radius:15px;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--has-image .recipe-user-image__image {
  position:absolute;inset:0;width:100%;height:100%;max-height:none;object-fit:cover;border-radius:0;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--has-image .recipe-user-image__controls {
  position:absolute;inset:auto 0 0;z-index:1;display:flex;align-items:stretch;justify-content:space-around;
  padding:12px 4px 4px;gap:3px;background:linear-gradient(transparent,rgba(3,10,16,.92));
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--has-image .recipe-user-image__action {
  width:auto;min-width:0;height:29px;min-height:29px;padding:0 6px;border-radius:7px;
  font-size:.65rem;background:rgba(7,22,32,.74);color:#f1f5f9;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--has-image .recipe-user-image__action-icon {
  width:14px;flex-basis:14px;font-size:.76rem;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image__action:focus-visible {
  outline:2px solid var(--accent);outline-offset:-2px;
}
/* Three equal, space-efficient fields; labels are under the values as before. */
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid {margin:13px 0 0;gap:9px;}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid .recipe-edit-dialog__field {gap:5px;}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid .recipe-edit-dialog__input {
  border:1px solid var(--border);border-radius:11px;min-height:42px;
  padding:7px 8px;background:color-mix(in srgb,var(--surface-2) 42%,transparent);text-align:center;
  font-size:1rem;font-variant-numeric:tabular-nums;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid .recipe-edit-dialog__label {
  font-size:.72rem;font-weight:520;padding-inline:2px;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more {
  padding:0;border-top:1px solid var(--border);margin-top:10px;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid + .recipe-editor__more {margin-top:15px;}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more > summary {
  display:flex;align-items:center;min-height:36px;padding:8px 2px;
  font-size:.78rem;color:var(--text);list-style:none;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more > summary::-webkit-details-marker {display:none;}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more > summary::after {
  content:'⌄';margin-left:auto;color:var(--muted);font-size:1rem;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more[open] > summary::after {transform:rotate(180deg);}
/* Section headings: matching surfaces, deliberate hierarchy, no extra empty space. */
.recipe-edit-dialog--conversational .recipe-editor__section-heading {
  display:flex;align-items:center;justify-content:space-between;gap:12px;min-width:0;margin:0 1px 8px;
}
.recipe-edit-dialog--conversational .recipe-editor__block > .recipe-editor__section-heading > .section-pill {
  margin:0 0 0 2px;padding:6px 12px;font-size:.76rem;
}
.recipe-edit-dialog--conversational .recipe-editor__focus-ingredient {
  min-height:30px;max-width:55%;padding:4px 10px;border-radius:9px;
  border:1px solid var(--border);background:color-mix(in srgb,var(--accent) 7%,var(--surface));
  color:var(--text);font-size:.73rem;line-height:1.2;text-align:center;cursor:pointer;
}
.recipe-edit-dialog--conversational .recipe-editor__focus-ingredient:focus-visible {outline:2px solid var(--accent);}
.recipe-edit-dialog--conversational .recipe-editor__section-surface {padding:11px 15px;}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--ingredients .recipe-authoring__ingredient-simple {
  padding:10px 0 7px;border-color:color-mix(in srgb,var(--border) 85%,transparent);
}
.recipe-edit-dialog--conversational .recipe-authoring__ingredient-row {gap:2px;}
.recipe-edit-dialog--conversational .recipe-authoring__ingredient-main {
  grid-template-columns:minmax(0,1fr) minmax(65px,82px) minmax(42px,58px);gap:7px;
}
.recipe-edit-dialog--conversational .recipe-authoring__ingredient-name {
  font-size:.88rem;font-weight:540;overflow-wrap:anywhere;
}
.recipe-edit-dialog--conversational .recipe-authoring__ingredient-main input {
  min-height:37px;margin:0;padding:5px 7px;border:1px solid var(--border);border-radius:9px;
  background:color-mix(in srgb,var(--surface-2) 35%,transparent);font-size:.88rem;
}
.recipe-edit-dialog--conversational .recipe-authoring__remove-ingredient {
  width:29px;flex-basis:29px;height:35px;margin:0;color:var(--muted);
}
.recipe-edit-dialog--conversational .recipe-authoring__ingredient-notes > summary {
  padding:3px 0 2px;font-size:.69rem;
}
/* One continuous add-ingredient row, not a second card nested inside Ingredients. */
.recipe-edit-dialog--conversational .recipe-editor__section-surface--ingredients .recipe-authoring__search {
  display:flex;align-items:center;gap:9px;min-height:45px;
  margin:7px 0 0;padding:5px 2px 0;
  border-top:1px solid color-mix(in srgb,var(--border) 80%,transparent);
  transition:border-color .16s ease;
}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--ingredients .recipe-authoring__search::before {
  content:'+';flex:0 0 22px;display:grid;place-items:center;
  width:22px;height:22px;border-radius:7px;
  color:var(--muted);background:color-mix(in srgb,var(--surface-2) 38%,transparent);
  font-size:19px;font-weight:400;line-height:1;pointer-events:none;
}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--ingredients .recipe-authoring__search .recipe-edit-dialog__input {
  flex:1;min-width:0;min-height:37px;margin:0;padding:6px 1px;
  border:0;border-radius:0;background:transparent;
  box-shadow:none;font-size:16px;
}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--ingredients .recipe-authoring__search .recipe-edit-dialog__input::placeholder {color:var(--muted);opacity:1;}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--ingredients .recipe-authoring__search:focus-within {border-top-color:color-mix(in srgb,var(--accent) 58%,var(--border));}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--ingredients .recipe-authoring__search:focus-within::before {color:var(--accent);}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--ingredients .recipe-authoring__search .recipe-edit-dialog__input:focus {border:0;box-shadow:none;outline:none;}
/* Keep continuous step entry; make it look intentional without adding a fake Add button. */
.recipe-edit-dialog--conversational .recipe-editor__section-surface--method {padding:5px 11px;}
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-step-composer {
  margin:5px 0;padding:10px 12px 10px 34px;position:relative;
}
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-step-composer::before {
  content:'✎';position:absolute;left:10px;top:12px;color:var(--muted);font-size:1rem;
}
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-step-card[open] {border-radius:12px;}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--notes {padding:4px 14px;}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--notes textarea {
  min-height:46px;height:48px;padding:9px 2px;background:transparent;resize:vertical;
  font-size:.88rem;line-height:1.5;
}
.recipe-edit-dialog--conversational .recipe-editor__section-surface--notes textarea:focus {min-height:88px;}
@media(max-width:420px){
  .recipe-edit-dialog--conversational.recipe-edit-dialog--page {width:calc(100% - 18px);}
  .recipe-edit-dialog--conversational .recipe-editor__overview {padding:15px 13px;}
  .recipe-edit-dialog--conversational .recipe-editor__hero {gap:9px;}
  .recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor,
  .recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor.recipe-user-image--has-image {
    flex-basis:101px;width:101px;height:97px;
  }
  .recipe-edit-dialog--conversational .recipe-editor__section-surface {padding-inline:11px;}
  .recipe-edit-dialog--conversational .recipe-authoring__ingredient-main {
    grid-template-columns:minmax(0,1fr) minmax(56px,71px) minmax(36px,49px);gap:5px;
  }
  .recipe-edit-dialog--conversational .recipe-authoring__ingredient-name {font-size:.83rem;}
  .recipe-edit-dialog--conversational .recipe-authoring__ingredient-main input {padding-inline:4px;font-size:.83rem;}
  .recipe-edit-dialog--conversational .recipe-authoring__remove-ingredient {flex-basis:25px;width:25px;}
}
@media(prefers-reduced-motion:reduce){
  .recipe-edit-dialog--conversational .recipe-editor__overview,
  .recipe-edit-dialog--conversational .recipe-editor__section-surface {scroll-behavior:auto;}
}

/* v160: Category is a first-class viewer-style section between overview and ingredients.
   The selection grid is visible only until a category has been chosen, or reopened. */
.recipe-edit-dialog--conversational .recipe-editor__section-surface--category {padding:7px 12px;}
.recipe-edit-dialog--conversational .recipe-editor__category-picker {margin:0;min-width:0;}
.recipe-edit-dialog--conversational .recipe-editor__category-selection {
  display:flex;align-items:center;justify-content:space-between;gap:10px;
  list-style:none;cursor:pointer;padding:9px 6px;min-height:38px;
  color:var(--text);font-size:.88rem;font-weight:580;
}
.recipe-edit-dialog--conversational .recipe-editor__category-selection::-webkit-details-marker {display:none;}
.recipe-edit-dialog--conversational .recipe-editor__category-selection::after {
  content:'⌄';font-size:1rem;color:var(--muted);transition:transform .15s ease;
}
.recipe-edit-dialog--conversational .recipe-editor__category-picker[open] > .recipe-editor__category-selection::after {transform:rotate(180deg);}
.recipe-edit-dialog--conversational .recipe-editor__category-picker .category-grid {
  display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;
  padding:6px 0 7px;
}
.recipe-edit-dialog--conversational .recipe-editor__category-picker .category-grid__item {
  min-height:76px;border-radius:12px;padding:8px 4px;gap:5px;
  background:color-mix(in srgb,var(--surface-2) 70%,transparent);
}
.recipe-edit-dialog--conversational .recipe-editor__category-picker .category-grid__label {
  font-size:.75rem;line-height:1.25;overflow-wrap:anywhere;
}
@media(min-width:700px){
  .recipe-edit-dialog--conversational .recipe-editor__category-picker .category-grid {grid-template-columns:repeat(4,minmax(0,1fr));}
}
@media(min-width:1100px){
  .recipe-edit-dialog--conversational .recipe-editor__category-picker .category-grid {grid-template-columns:repeat(5,minmax(0,1fr));}
}

/* v162: viewport-anchored AI action. Mount it as a direct body child because
   the blurred editor card creates a containing block for fixed descendants.
   It never replaces the manual-entry surface. */
body[data-recipe-editor] > .recipe-editor__ai-launch {
  position:fixed;
  z-index:125;
  right:max(16px,calc((100vw - var(--shell-max-w))/2 + 14px));
  bottom:calc(var(--bottom-stack-h) + 18px);
  width:46px;height:46px;min-width:46px;min-height:46px;padding:0;
  display:grid;place-items:center;
  border:1px solid color-mix(in srgb,var(--accent) 58%,var(--border));
  border-radius:50%;
  background:color-mix(in srgb,var(--surface) 78%,var(--accent) 22%);
  color:var(--accent);font-size:1.65rem;font-weight:650;line-height:1;
  box-shadow:0 5px 18px rgba(0,0,0,.24);
  backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
  cursor:pointer;
}
body[data-recipe-editor] > .recipe-editor__ai-launch:focus-visible {outline:2px solid var(--accent);outline-offset:3px;}
body[data-recipe-editor][data-recipe-typing] .recipe-editor__ai-launch {display:none;}
.recipe-editor__ai-dialog {
  width:min(560px,calc(100vw - 28px));
  max-height:min(86dvh,760px);
  margin:auto;padding:0;
  border:1px solid var(--border);border-radius:18px;
  background:var(--surface);color:var(--text);
  box-shadow:0 24px 70px rgba(0,0,0,.4);
  overscroll-behavior:contain;
}
.recipe-editor__ai-dialog::backdrop {background:rgba(0,0,0,.6);backdrop-filter:blur(2px);}
.recipe-editor__ai-dialog:not([open]) {display:none;}
.recipe-editor__ai-panel {padding:17px;max-height:min(86dvh,760px);overflow-y:auto;overscroll-behavior:contain;}
.recipe-editor__ai-heading {display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 8px;}
.recipe-editor__ai-heading h2 {margin:0;font-size:1.05rem;line-height:1.35;}
.recipe-editor__ai-close {
  flex:0 0 36px;width:36px;height:36px;padding:0;border:1px solid var(--border);
  border-radius:10px;background:var(--surface-2);color:var(--text);font-size:1.45rem;cursor:pointer;
}
.recipe-editor__ai-intro {margin:6px 0 9px;color:var(--muted);font-size:.84rem;line-height:1.45;}
.recipe-editor__ai-steps {margin:0 0 16px;padding-left:23px;color:var(--text);font-size:.82rem;line-height:1.5;}
.recipe-editor__ai-steps li + li {margin-top:5px;}
.recipe-editor__ai-dialog .recipe-secretary {display:grid;gap:8px;min-width:0;}
.recipe-editor__ai-dialog .recipe-secretary .recipe-edit-dialog__input {max-width:100%;min-width:0;}
.recipe-editor__ai-dialog .recipe-secretary__input {min-height:110px;}
.recipe-editor__ai-dialog .recipe-exchange__response {min-height:110px;}
@media(max-width:420px){
  body[data-recipe-editor] > .recipe-editor__ai-launch {right:15px;width:44px;height:44px;min-height:44px;min-width:44px;}
  .recipe-editor__ai-panel {padding:14px;}
}

/* v165: compact recipe metadata entry without changing any field bindings.
   The labels and their combined focus areas remain generous for touch screens. */
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid {
  margin-top:9px;
  gap:8px;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid .recipe-edit-dialog__field {
  gap:3px;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid .recipe-edit-dialog__input {
  min-height:34px;
  height:34px;
  padding:4px 7px;
  border-radius:9px;
  font-size:.93rem;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid .recipe-edit-dialog__label {
  font-size:.7rem;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid + .recipe-editor__more {
  margin-top:10px;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more > .recipe-edit-dialog__field {
  margin-top:6px;
  gap:4px;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more > .recipe-edit-dialog__field .recipe-edit-dialog__label {
  font-size:.73rem;
  font-weight:530;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more > .recipe-edit-dialog__field .recipe-edit-dialog__input {
  min-height:34px;
  height:34px;
  padding:5px 8px;
  font-size:.88rem;
  border-radius:8px;
}
/* Numeric minimum portions is a single compact row, not a full-width box. */
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__minimum-row {
  display:grid;
  grid-template-columns:minmax(0,1fr) 104px;
  align-items:center;
  column-gap:10px;
  padding:3px 0;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__minimum-row .recipe-edit-dialog__input {
  width:100%;
  text-align:center;
}
/* The serving description can be long, but only one compact line is needed. */
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__portion-description-row {
  margin-top:7px;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more > summary {
  min-height:34px;
  padding:6px 2px;
}
/* Reusable ingredient metadata uses the same scale when expanded. */
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__component .recipe-authoring__component-fields .recipe-edit-dialog__field {
  margin-top:8px;
  gap:4px;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__component .recipe-authoring__component-fields .recipe-edit-dialog__input {
  min-height:36px;
  padding:6px 8px;
}

/* v166 — The optional base-ingredient output is part of More recipe details.
   Keep the simple on/off choice visible without an extra nested accordion. */
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__component {
  margin-top:9px;
  padding-top:7px;
  border-top:1px solid color-mix(in srgb,var(--border) 70%,transparent);
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__base-toggle {
  display:flex;
  align-items:center;
  gap:9px;
  min-height:34px;
  padding:4px 2px;
  font-size:.78rem;
  font-weight:520;
  color:var(--text);
  cursor:pointer;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__base-toggle input[type="checkbox"] {
  width:17px;
  height:17px;
  flex:0 0 auto;
  accent-color:var(--accent);
  cursor:pointer;
}

/* v167 — Only portions belongs to the always-visible recipe header.
   Preparation and cooking estimates remain the original inputs, now grouped
   inside More recipe details; keep both compact and touch accessible. */
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-edit-dialog__compact-grid {
  grid-template-columns:minmax(0,144px);
  max-width:144px;
}
.recipe-editor__time-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  align-items:start;
  gap:10px;
  margin-top:8px;
}
.recipe-editor__time-grid .recipe-edit-dialog__field {min-width:0;margin:0;gap:4px;}
.recipe-editor__time-grid .recipe-edit-dialog__label {font-size:.73rem;}
.recipe-editor__time-grid .recipe-edit-dialog__input {
  width:100%;min-width:0;min-height:34px;height:34px;
  padding:5px 8px;border-radius:8px;font-size:.88rem;
}

/* v168 — Title + portion entry share the photo row. Keep the existing input
   and data binding, but avoid an empty standalone metadata row. */
.recipe-edit-dialog--conversational .recipe-editor__hero {
  display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:stretch;gap:12px;
}
.recipe-editor__hero-fields {
  display:flex;flex-direction:column;align-items:stretch;justify-content:space-between;
  gap:8px;min-width:0;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-edit-dialog__field--name {
  justify-content:flex-start;gap:0;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-edit-dialog__field--name .recipe-edit-dialog__label {
  display:none;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-edit-dialog__field--name input {
  padding:0;min-height:36px;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid {
  margin:0;display:grid;grid-template-columns:minmax(0,140px);max-width:140px;gap:0;
}
.recipe-edit-dialog--conversational .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid .recipe-edit-dialog__field {
  display:block;margin:0;
}
.recipe-edit-dialog--conversational .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid .recipe-edit-dialog__label {
  position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;
  clip:rect(0,0,0,0);white-space:nowrap;border:0;
}
.recipe-edit-dialog--conversational .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid .recipe-edit-dialog__input {
  width:100%;height:36px;min-height:36px;text-align:left;padding:6px 10px;
}
.recipe-edit-dialog--conversational .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid .recipe-edit-dialog__input::placeholder {
  color:var(--muted);opacity:.85;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__more {margin-top:13px;}
@media(max-width:420px){
 .recipe-edit-dialog--conversational .recipe-editor__hero {gap:9px;}
 .recipe-edit-dialog--conversational .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid {grid-template-columns:minmax(0,125px);max-width:125px;}
}

/* v169 — Compact inline yield control: visible Portions: + a small numeric
   input share a single row beneath the name, opposite the photo tile. */
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid {
  display:flex;
  width:max-content;
  max-width:100%;
  margin:0;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid .recipe-edit-dialog__field {
  display:flex;
  flex-direction:row;
  align-items:center;
  gap:9px;
  width:max-content;
  max-width:100%;
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid .recipe-edit-dialog__label {
  position:static;
  display:inline;
  width:auto;
  height:auto;
  padding:0;
  margin:0;
  overflow:visible;
  clip:auto;
  white-space:nowrap;
  border:0;
  font-size:.79rem;
  font-weight:520;
  letter-spacing:0;
  color:var(--muted);
}
.recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid .recipe-edit-dialog__input {
  flex:0 0 62px;
  width:62px;
  min-width:0;
  max-width:62px;
  height:36px;
  min-height:36px;
  padding:5px 7px;
  text-align:center;
  font-variant-numeric:tabular-nums;
}
@media(max-width:370px){
  .recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid .recipe-edit-dialog__field {gap:6px;}
  .recipe-edit-dialog--conversational .recipe-editor__overview .recipe-editor__hero-fields .recipe-edit-dialog__compact-grid .recipe-edit-dialog__input {flex-basis:56px;width:56px;max-width:56px;}
}

/* v170: single inline category autocomplete instead of the tile picker. */
.recipe-edit-dialog--conversational .recipe-editor__category-input {
  display:block;width:100%;min-height:38px;padding:7px 8px;
  background:transparent;border:0;border-bottom:1px solid var(--border,rgba(255,255,255,.16));
  border-radius:0;color:var(--text);font:inherit;outline-offset:2px;
}
.recipe-edit-dialog--conversational .recipe-editor__category-input:focus {border-bottom-color:var(--accent,#6d9dff);}

/* v171: Category completes the three-row left-hand recipe hero (title,
   portions, category); no redundant Category section or separate surface. */
.recipe-edit-dialog--conversational .recipe-editor__hero-fields {
  justify-content:space-between;
  gap:5px;
}
.recipe-edit-dialog--conversational .recipe-editor__hero-fields .recipe-editor__category-input {
  box-sizing:border-box;
  flex:0 0 34px;
  width:100%;
  min-width:0;
  min-height:34px;
  height:34px;
  padding:4px 2px;
  font-size:.88rem;
  line-height:1.2;
  border-bottom-color:color-mix(in srgb,var(--border) 80%,transparent);
}
.recipe-edit-dialog--conversational .recipe-editor__hero-fields .recipe-editor__category-input::placeholder {
  color:var(--muted);
  opacity:.85;
}
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor,
.recipe-edit-dialog--conversational .recipe-editor__hero .recipe-user-image--editor.recipe-user-image--has-image {
  height:124px;
}

/* v173: An unresolved personal ingredient is a first-class editable recipe line.
   Show a small linking hint in the name cell, never an extra grid column. */
.recipe-edit-dialog--conversational .recipe-authoring__ingredient-title {display:flex;flex-direction:column;align-items:flex-start;gap:2px;min-width:0}
.recipe-edit-dialog--conversational .recipe-authoring__unlinked {border:0!important;box-shadow:none!important;background:transparent!important;color:var(--muted);padding:0!important;font-size:.67rem;line-height:1.2;text-align:left;min-height:0!important;min-width:0!important}
.recipe-edit-dialog--conversational .recipe-authoring__unlinked:hover {color:var(--accent)}
.recipe-edit-dialog--conversational .recipe-authoring__unknown-choice {color:var(--accent);border-style:dashed}

/* v177 — a technique-led mini form, using the existing recipe references. */
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-step-card[open] {
  border-color:var(--border);background:var(--surface);box-shadow:none;
}
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-step-card[open] .recipe-step-card__summary {min-height:30px;padding-block:7px 3px;}
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-step-card[open] .recipe-step-card__heading {display:none;}
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-step-card__body {padding:4px 10px 10px;border-top:0;}
.recipe-editor__method-list .recipe-step-card {scroll-margin-top:76px;}
.recipe-edit-dialog--conversational .recipe-step-editor__technique-chooser {display:grid;grid-template-columns:minmax(0,1fr) auto;gap:7px;align-items:end;margin:0 0 8px;}
.recipe-step-editor__technique-chooser .recipe-edit-dialog__field {margin:0;}
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-edit-dialog__label {display:block;font-size:.73rem;color:var(--muted);}
.recipe-step-editor__new-technique {min-height:38px;padding:6px 8px;white-space:nowrap;border:0;background:transparent;color:var(--accent);font:inherit;font-size:.78rem;cursor:pointer;}
.recipe-step-editor__selected-ingredients {display:flex;flex-wrap:wrap;gap:5px;margin:4px 0 6px;}
.recipe-step-editor__selected-ingredients:empty {display:none;}
.recipe-edit-dialog--conversational .recipe-step-editor__quick-ingredients {margin:0 0 9px;}
.recipe-edit-dialog--conversational .recipe-step-editor__quick-search {min-height:38px;padding:7px 9px;font-size:.88rem;}
.recipe-edit-dialog--conversational .recipe-step-editor__needs {gap:5px;margin:5px 0 8px;}
.recipe-edit-dialog--conversational .recipe-step-editor__need {display:grid;grid-template-columns:88px minmax(0,1fr);gap:6px;align-items:center;min-width:0;}
.recipe-edit-dialog--conversational .recipe-step-editor__need-label {font-size:.73rem;color:var(--muted);}
.recipe-edit-dialog--conversational .recipe-step-editor__need-input {min-width:0;max-width:100%;min-height:36px;font-size:.86rem;}
.recipe-step-editor__form-preview {font-size:.82rem;line-height:1.45;color:var(--muted);margin:8px 0 4px;overflow-wrap:anywhere;}
.recipe-step-editor__form-preview[hidden] {display:none;}
.recipe-edit-dialog--conversational .recipe-step-editor__more {margin-top:3px;border:0;padding:0;}
.recipe-edit-dialog--conversational .recipe-step-editor__more > summary {position:static;display:inline-block;font-size:.73rem;opacity:.72;padding:6px 0;cursor:pointer;}
.recipe-edit-dialog--conversational .recipe-step-editor__more:not([open]) {height:auto;}
.recipe-step-editor__wording > summary,.recipe-step-editor__extra-parameters > summary,.technique-definition-form__options > summary {color:var(--muted);font-size:.77rem;padding:6px 0;cursor:pointer;}
.recipe-step-editor__wording {margin:5px 0;}
.recipe-step-editor__extra-parameters .recipe-step-editor__needs {margin-top:5px;}
.technique-definition-form__options > .recipe-edit-dialog__field {margin-top:8px;}
.recipe-edit-dialog--conversational .recipe-step-editor__instruction {min-height:44px;max-height:176px;resize:none;padding:8px 0;}
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-step-composer {padding:8px 2px;}
.recipe-edit-dialog--conversational .recipe-editor__method-list .recipe-step-composer::before {content:none;}
.recipe-step-editor__quick-quantity {display:grid;grid-template-columns:minmax(0,1fr) 70px;gap:6px;}
.recipe-step-editor__quick-quantity > p,.recipe-step-editor__quick-quantity > button {grid-column:1/-1;}
@media(max-width:360px){.recipe-edit-dialog--conversational .recipe-step-editor__need {grid-template-columns:72px minmax(0,1fr);}}

/* Compact correction controls use the draft actions inside the cooking view. */
.recipe-editor__review-answer {display:flex;flex-wrap:wrap;align-items:end;gap:8px;width:100%;min-width:0;}
.recipe-editor__review-answer > .recipe-edit-dialog__field {flex:1 1 180px;min-width:0;margin:0;}
.recipe-edit-dialog--conversational .recipe-editor__review-answer .recipe-edit-dialog__label {display:block;font-size:.75rem;color:var(--muted);}
.recipe-editor__review-answer .recipe-edit-dialog__input {min-height:38px;max-width:100%;min-width:0;font-size:16px;}
.recipe-editor__review-answer > select {width:auto;}
.recipe-editor__review-answer > .recipe-authoring__suggestions {flex-basis:100%;}
.recipe-editor__review-answer > .recipe-authoring__suggestions button {min-height:38px;font-size:.82rem;}
.recipe-editor__review-answer .recipe-editor__review-measure {display:flex;flex-wrap:wrap;align-items:end;width:100%;}
.recipe-editor__review-answer .recipe-editor__review-measure > .recipe-edit-dialog__field {width:110px;max-width:42%;margin:0;}
.recipe-editor__review-answer .recipe-editor__review-measure input {width:100%;max-width:100%;}
.recipe-editor__review-answer .recipe-editor__review-measure > select {width:85px;max-width:32%;}
.recipe-editor__review-answer > .recipe-step-card__create {width:100%;}
.recipe-editor__review-answer > .recipe-step-editor__error {flex-basis:100%;margin:3px 0;}

/* The final check is the same cooking page, with local corrections in context. */
.recipe-workbench__recipe > [hidden] {display:none!important;}
.recipe-editor__preview-start {width:100%;text-align:left;border:0;background:transparent;color:var(--text);padding:5px 0;font:inherit;font-size:.9rem;cursor:pointer;}
.recipe-completion-preview {min-width:0;scroll-margin-top:80px;}
.recipe-preview__toolbar {position:sticky;top:74px;z-index:3;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:7px;padding:11px 12px;margin-bottom:14px;border:1px solid var(--border);border-radius:14px;background:var(--surface);box-shadow:0 5px 18px #0001;}
.recipe-preview__status {font-size:.82rem;margin:0;color:var(--muted);}
.recipe-preview__navigation {display:flex;flex-wrap:wrap;gap:5px;}
.recipe-preview__button,.recipe-preview__missing,.recipe-preview__close,.recipe-preview__later,.recipe-preview__edit-link {font:inherit;font-size:.76rem;line-height:1.35;padding:7px 10px;min-height:34px;border:1px solid var(--border);border-radius:10px;background:var(--surface-2);color:var(--text);cursor:pointer;text-align:left;max-width:100%;overflow-wrap:anywhere;}
.recipe-preview__navigation .recipe-preview__button:last-child {border:0;background:transparent;color:var(--muted);}
.recipe-preview__corrections {display:flex;flex-wrap:wrap;gap:5px;align-items:center;margin-top:7px;min-width:0;}
.recipe-preview__missing {color:var(--text);border-color:color-mix(in srgb,#c7923e 70%,var(--border));background:color-mix(in srgb,#c7923e 12%,var(--surface));}
.recipe-preview__missing::before {content:'+';margin-right:5px;color:var(--muted);}
.recipe-preview__missing[aria-expanded=true] {border-color:var(--accent);background:color-mix(in srgb,var(--accent) 12%,var(--surface));}
.recipe-preview__edit-link,.recipe-preview__edit-menu > summary {border:0;background:transparent;color:var(--muted);font-size:.72rem;cursor:pointer;padding:5px 0;}
.recipe-preview__add {font:inherit;font-size:.8rem;padding:7px 10px;min-height:36px;border:0;border-radius:9px;background:transparent;color:var(--accent);cursor:pointer;text-align:left;}
.recipe-preview__add::before {content:'+';margin-right:6px;}
.recipe-preview__add:focus-visible {outline:2px solid var(--accent);outline-offset:2px;}
.recipe-completion-preview .recipe-ingredient__list > .recipe-preview__corrections {padding:5px 8px;margin:0;border-top:1px solid var(--border);}
.recipe-detail__stage > .recipe-preview__corrections {margin:5px 0;}
.recipe-preview__edit-menu > select {margin-top:6px;min-height:36px;width:100%;max-width:250px;font-size:16px;}
.recipe-preview__edit-menu {min-width:0;}
.recipe-preview__edit {margin:10px 0 3px;padding:11px;border:1px solid var(--accent);border-radius:12px;background:var(--surface-2);min-width:0;scroll-margin-top:140px;}
.recipe-preview__edit-heading {display:flex;align-items:center;justify-content:space-between;gap:7px;margin-bottom:9px;font-size:.8rem;}
.recipe-preview__close {padding:4px 7px;font-size:.68rem;background:transparent;border:0;color:var(--muted);}
.recipe-preview__later {margin-top:8px;border:0;background:transparent;padding:4px 0;color:var(--muted);font-size:.7rem;}
.recipe-completion-preview .recipe-detail__step > .recipe-preview__corrections,.recipe-completion-preview .recipe-detail__step > .recipe-preview__edit {grid-column:2;}
.recipe-completion-preview .recipe-ingredient__entry > .recipe-preview__corrections,.recipe-completion-preview .recipe-ingredient__entry > .recipe-preview__edit {margin-inline:12px;margin-bottom:9px;}
.recipe-completion-preview .recipe-detail__fact:has(.recipe-preview__edit) {grid-column:1/-1;}
.recipe-completion-preview .recipe-detail__fact-value {white-space:normal;}
.recipe-completion-preview .recipe-detail__facts {grid-template-columns:repeat(auto-fit,minmax(100px,1fr));}
.recipe-completion-preview .recipe-user-image--editor {width:100%;height:180px;min-height:0;border-radius:0;}
.recipe-completion-preview .recipe-detail__hero:has(.recipe-user-image:not(.recipe-user-image--has-image)) .recipe-user-image {display:none;}
.recipe-preview__error {font-size:.82rem;line-height:1.45;color:var(--danger,#bc4747);}
.recipe-preview__error:empty {display:none;}
.recipe-preview__input-share {display:flex;gap:7px;align-items:end;width:100%;}
.recipe-preview__input-share .recipe-edit-dialog__field {flex:1;min-width:0;margin:0;}
.recipe-preview__input-share button {margin-bottom:2px;}
.recipe-completion-preview .recipe-editor__review-answer > .recipe-authoring__suggestions:empty {display:none;}
.recipe-completion-preview .recipe-preview__button:focus-visible,.recipe-completion-preview .recipe-preview__missing:focus-visible {outline:2px solid var(--accent);outline-offset:2px;}
@media(max-width:400px){.recipe-preview__toolbar {top:68px;padding:9px;}.recipe-preview__navigation {gap:3px;}.recipe-preview__navigation .recipe-preview__button {font-size:.7rem;padding:6px 7px;}.recipe-completion-preview .recipe-detail__step {grid-template-columns:24px minmax(0,1fr);gap:6px;padding-inline:9px;}}
@media(prefers-reduced-motion:reduce){.recipe-completion-preview {scroll-behavior:auto;}}

/* Shared resolution sheet: one contextual form, within the visual viewport. */
.ingredient-resolution { position:fixed; inset:var(--resolution-offset,0px) 0 calc(100% - var(--resolution-viewport,100dvh) - var(--resolution-offset,0px)); margin:auto; width:min(560px,calc(100vw - 32px)); max-height:calc(var(--resolution-viewport,100dvh) - 24px); overflow:hidden; }
.ingredient-resolution > .menu-dialog__panel { display:flex; flex-direction:column; max-height:calc(var(--resolution-viewport,100dvh) - 26px); padding:14px; gap:10px; }
.ingredient-resolution__handle { flex:none; width:34px; height:4px; border-radius:4px; background:var(--border); margin:0 auto 2px; }
.ingredient-resolution .menu-dialog__heading { flex:none; margin:0; }
.ingredient-resolution .menu-dialog__heading h2 { margin:0; font-size:1.18rem; line-height:1.3; }
.ingredient-resolution__summary,.ingredient-resolution__note,.ingredient-resolution__status { margin:0; color:var(--muted); font-size:.79rem; line-height:1.4; overflow-wrap:anywhere; }
.ingredient-resolution__summary,.ingredient-resolution__status { flex:none; }
.ingredient-resolution__tabs { flex:none; display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:4px; padding-bottom:10px; border-bottom:1px solid var(--border); }
.ingredient-resolution__tabs .menu-button { min-width:0; min-height:44px; padding:5px 3px; font-size:.75rem; line-height:1.25; border-radius:10px; background:transparent; }
.ingredient-resolution__tabs [aria-pressed="true"] { color:var(--accent); background:var(--surface-2); border-color:var(--accent); }
.ingredient-resolution__body { overflow-y:auto; overscroll-behavior:contain; min-height:0; display:grid; gap:10px; padding:2px 2px max(2px,env(safe-area-inset-bottom)); scroll-padding:8px 8px 58px; }
.ingredient-resolution .menu-dialog__form { gap:10px; min-width:0; }
.ingredient-resolution .menu-dialog__field { grid-template-columns:minmax(0,1fr) minmax(0,1.2fr); align-items:center; gap:8px; min-width:0; }
.ingredient-resolution .ingredient-resolution__form .menu-dialog__field { grid-template-columns:minmax(0,1fr); gap:4px; }
.ingredient-resolution__measure { display:grid; grid-template-columns:minmax(0,1.5fr) minmax(0,1fr); gap:10px; }
.ingredient-resolution .menu-dialog__input { font-size:1rem; }
.ingredient-resolution .menu-button { min-height:44px; }
.ingredient-resolution .menu-button--primary { position:sticky; bottom:0; z-index:1; margin-top:2px; }
.ingredient-resolution .ingredient-resolution__close { flex:none; width:44px; padding:0; font-size:1.4rem; background:transparent; border:0; }
.ingredient-resolution__secondary { padding:5px 8px; border:0; background:transparent; color:var(--accent); font-size:.82rem; }
.ingredient-resolution__lot { display:flex; justify-content:space-between; align-items:center; gap:8px; padding:6px 0; border-bottom:1px solid var(--border); }
.ingredient-resolution__lot > div { min-width:0; overflow-wrap:anywhere; }
.ingredient-resolution__search { display:flex; gap:6px; }
.ingredient-resolution__search input { flex:1; width:0; }
.ingredient-resolution__search button { flex:none; font-size:.8rem; padding:6px 9px; }
.ingredient-resolution__products { display:grid; }
.ingredient-resolution__product { border-bottom:1px solid var(--border); }
.ingredient-resolution__product-open { display:grid; gap:3px; width:100%; min-height:60px; padding:10px 2px; border:0; color:var(--text); background:transparent; text-align:left; font:inherit; cursor:pointer; overflow-wrap:anywhere; }
.ingredient-resolution__product-open:disabled { opacity:.65; cursor:default; }
.ingredient-resolution__product-open:focus-visible { outline:2px solid var(--accent); outline-offset:-2px; }
.ingredient-resolution__exact { display:flex; align-items:flex-start; gap:10px; font-size:.83rem; min-height:44px; }
.ingredient-resolution__exact input { flex:none; width:22px; height:22px; margin:2px 0; accent-color:var(--accent); }
.ingredient-resolution__selected { overflow-wrap:anywhere; }
.ingredient-resolution .barcode-scanner--compact { border:0; padding:0; background:transparent; box-shadow:none; min-width:0; }
.ingredient-resolution .barcode-scanner--compact .barcode-scanner__controls { grid-template-columns:repeat(2,minmax(0,1fr)); }
@media(max-width:600px){
 .ingredient-resolution { margin:auto 0 0; width:100%; max-width:100%; border-radius:18px 18px 0 0; max-height:calc(var(--resolution-viewport,100dvh) - max(12px,env(safe-area-inset-top))); }
 .ingredient-resolution > .menu-dialog__panel { max-height:calc(var(--resolution-viewport,100dvh) - max(14px,env(safe-area-inset-top))); padding:10px 12px max(10px,env(safe-area-inset-bottom)); }
}


/* Camera failures replace the unused preview with actionable, copyable details. */
.barcode-scanner [hidden] { display:none !important; }
.barcode-scanner__status:empty { display:none; }
.barcode-scanner__error { display:grid; gap:7px; min-width:0; }
.barcode-scanner__reason,.barcode-scanner__hint { margin:0; font-size:.8rem; line-height:1.45; overflow-wrap:anywhere; }
.barcode-scanner__reason { color:var(--text); }
.barcode-scanner__hint { color:var(--muted); }
.barcode-scanner__report-actions { display:grid; gap:5px; }
.barcode-scanner__report { width:100%; min-width:0; min-height:160px; padding:9px; border:1px solid var(--border); border-radius:9px; background:var(--surface-2); color:var(--text); font:12px/1.4 monospace; }
.barcode-scanner .barcode-diagnostics { min-width:0; }
.barcode-scanner .barcode-diagnostics__row { grid-template-columns:minmax(80px,.8fr) minmax(0,1.5fr); }

/* v199 Pantry: one quiet inventory surface, with contextual stock controls. */
.pantry { display:grid; gap:14px; padding-bottom:14px; }
.pantry [hidden],.pantry-sheet [hidden],.ingredient-resolution [hidden] { display:none !important; }
.pantry-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; position:relative; }
.pantry-heading .page-title { margin:0; }
.pantry-overflow { position:relative; }
.pantry-overflow > summary { list-style:none; display:grid; place-items:center; min-width:44px; min-height:44px; padding:4px 10px; font-size:1.6rem; line-height:1; cursor:pointer; }
.pantry-overflow > summary::-webkit-details-marker { display:none; }
.pantry-options { position:absolute; top:calc(100% + 6px); right:0; z-index:5; width:min(280px,calc(100vw - 44px)); display:grid; gap:12px; padding:14px; background:var(--surface); border:1px solid var(--border); border-radius:14px; box-shadow:0 12px 30px #0004; }
.pantry-options .menu-dialog__field { margin:0; }
.pantry-search { width:100%; min-height:48px; border-radius:13px; font-size:1rem; }
.pantry-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
.pantry-primary { display:flex; justify-content:center; align-items:center; gap:8px; min-height:54px; padding:10px 8px; border-radius:13px; font-size:.9rem; }
.pantry-primary .nav-icon { font-size:1.4rem; line-height:1; }
.pantry .ingredient-list { margin:4px 0 0; min-width:0; }
.pantry .ingredient-list__header { min-height:36px; margin:0 0 7px; gap:8px; align-items:center; }
.pantry .ingredient-list__header h3 { margin:0; color:var(--text); font-size:.98rem; font-weight:650; text-transform:none; letter-spacing:0; }
.pantry .ingredient-list__card { padding:0; overflow:hidden; border-radius:16px; }
.pantry-row { width:100%; display:flex; align-items:center; gap:10px; min-height:64px; padding:12px 14px; background:transparent; border:0; border-radius:0; color:var(--text); text-align:left; font:inherit; cursor:pointer; }
.pantry-row + .pantry-row { border-top:1px solid var(--border); }
.pantry-row__copy { min-width:0; flex:1; display:grid; gap:4px; }
.pantry-row strong { font-size:.92rem; font-weight:600; line-height:1.35; overflow-wrap:anywhere; }
.pantry-row__support { font-size:.8rem; color:var(--muted); line-height:1.35; overflow-wrap:anywhere; }
.pantry-row__chevron { flex:none; color:var(--muted); font-size:1.5rem; line-height:1; }
.pantry-row__quantity { flex:0 0 auto; max-width:30%; color:var(--muted); font-size:.79rem; overflow-wrap:anywhere; text-align:right; }
.pantry-row__urgency { width:5px; height:26px; flex:none; background:color-mix(in srgb,var(--accent) 50%,var(--muted)); border-radius:4px; }
.pantry-row__urgency[data-severity="0"],.pantry-row__urgency[data-severity="1"] { background:#c68368; }
.pantry-row:focus-visible,.pantry-text-button:focus-visible { outline:2px solid var(--accent); outline-offset:-3px; }
.pantry-row:hover { background:color-mix(in srgb,var(--surface-2) 60%,transparent); }
.pantry-location { max-width:48%; min-height:44px; min-width:0; border:0; background:transparent; color:var(--muted); font:inherit; font-size:.8rem; text-overflow:ellipsis; cursor:pointer; }
.pantry-location option { background:var(--surface); color:var(--text); }
.pantry-text-button { border:0; background:none; padding:8px 0 8px 8px; min-height:44px; color:var(--accent); font:inherit; font-size:.8rem; cursor:pointer; }
.pantry-empty { display:grid; justify-items:start; gap:8px; padding:20px 16px; }
.pantry-empty p { margin:0; color:var(--muted); font-size:.85rem; line-height:1.45; }
.pantry-result-heading { margin:10px 0 6px; color:var(--muted); font-size:.73rem; font-weight:600; }
.pantry-result-list { border:1px solid var(--border); border-radius:13px; overflow:hidden; background:var(--surface); }
.pantry-suggestions { order:6; }
.pantry-attention { order:4; }.pantry-inventory { order:5; }
.pantry-sheet { width:min(560px,calc(100vw - 24px)); max-height:calc(100dvh - 24px); overflow:auto; }
.pantry-sheet > .menu-dialog__panel { display:grid; gap:12px; padding:16px; }
.pantry-sheet .menu-dialog__heading { margin:0; }
.pantry-sheet .menu-dialog__heading h2 { overflow-wrap:anywhere; margin:0; font-size:1.15rem; }
.pantry-sheet .menu-dialog__input { min-width:0; font-size:1rem; }
.pantry-sheet .menu-dialog__field { grid-template-columns:minmax(0,1fr) minmax(0,1.2fr); align-items:center; gap:8px; }
.pantry-sheet .menu-button { min-height:44px; }
.pantry-sheet__balance { color:var(--muted); margin:0; font-size:.95rem; }
.pantry-sheet__warning { padding:8px 10px; border:0; border-left:3px solid #c68368; background:var(--surface-2); color:var(--text); text-align:left; font:inherit; font-size:.82rem; cursor:pointer; }
.pantry-details { min-width:0; color:var(--text); }
.pantry-details > summary { min-height:44px; display:flex; align-items:center; cursor:pointer; font-size:.83rem; color:var(--muted); }
.pantry-details > summary::after { content:'⌄'; margin-left:auto; padding-left:8px; }
.pantry-details[open] > summary { margin-bottom:8px; }
.pantry-details .menu-dialog__field + .menu-dialog__field { margin-top:8px; }
.pantry-json { max-width:100%; white-space:pre-wrap; overflow-wrap:anywhere; margin:0; font-size:.7rem; line-height:1.5; }
.pantry-lot { border-top:1px solid var(--border); padding:12px 0; overflow-wrap:anywhere; }
.pantry-lot > strong { display:block; margin-bottom:8px; }
.pantry-search-results { display:grid; }
@media(max-width:600px){
 .pantry-sheet { margin:auto 0 0; width:100%; max-width:100%; border-radius:18px 18px 0 0; max-height:calc(100dvh - max(12px,env(safe-area-inset-top))); }
 .pantry-sheet > .menu-dialog__panel { padding:14px 14px max(14px,env(safe-area-inset-bottom)); }
}

/* Product scanning starts on the preview; manual and camera controls are optional. */
.barcode-scanner__options { min-width:0; }
.barcode-scanner__options > summary { display:flex; align-items:center; min-height:44px; color:var(--muted); font-size:.83rem; cursor:pointer; }
.barcode-scanner__options > summary::after { content:'⌄'; margin-left:auto; }
.barcode-scanner__options[open] > summary { margin-bottom:6px; }

/* v201 ingredient explorer shares Pantry's quiet row/card hierarchy. */
.ingredient-explorer { display:grid; gap:12px; padding-bottom:12px; }
.ingredient-explorer [hidden],.ingredient-explorer-detail [hidden] { display:none !important; }
.ingredient-explorer__heading { display:flex; align-items:center; justify-content:space-between; gap:10px; }
.ingredient-explorer__heading .page-title { margin:0; }
.ingredient-explorer__subtitle { margin:-5px 0 2px; color:var(--muted); font-size:.82rem; line-height:1.45; }
.ingredient-explorer__overflow { position:relative; }
.ingredient-explorer__overflow > summary { display:grid; place-items:center; min-width:44px; min-height:44px; padding:4px 10px; list-style:none; font-size:1.6rem; cursor:pointer; }
.ingredient-explorer__overflow > summary::-webkit-details-marker { display:none; }
.ingredient-explorer__options { position:absolute; top:calc(100% + 6px); right:0; z-index:5; width:min(230px,calc(100vw - 44px)); padding:10px; background:var(--surface); border:1px solid var(--border); border-radius:13px; box-shadow:0 12px 30px #0004; display:grid; gap:8px; }
.ingredient-explorer__options button { width:100%; min-height:44px; }
.ingredient-explorer__search { min-height:48px; width:100%; font-size:1rem; border-radius:13px; }
.ingredient-explorer__tabs { display:flex; gap:6px; overflow-x:auto; min-width:0; padding:1px 1px 4px; scrollbar-width:thin; }
.ingredient-explorer__tab { flex:0 0 auto; min-height:44px; border:1px solid var(--border); border-radius:12px; background:var(--surface); color:var(--muted); font:inherit; font-size:.8rem; padding:8px 11px; cursor:pointer; }
.ingredient-explorer__tab[aria-pressed="true"] { background:var(--surface-2); border-color:var(--accent); color:var(--text); }
.ingredient-explorer__count,.ingredient-explorer__status { margin:0; font-size:.78rem; color:var(--muted); line-height:1.4; }
.ingredient-explorer__group { margin:0 0 12px; min-width:0; }
.ingredient-explorer__group > h3 { margin:2px 2px 8px; font-size:.78rem; font-weight:650; color:var(--muted); }
.ingredient-explorer__card { padding:0; overflow:hidden; border-radius:16px; }
.ingredient-explorer__row { display:flex; align-items:center; gap:12px; min-height:62px; width:100%; padding:12px 14px; border:0; border-radius:0; color:var(--text); background:transparent; text-align:left; font:inherit; cursor:pointer; }
.ingredient-explorer__row + .ingredient-explorer__row { border-top:1px solid var(--border); }
.ingredient-explorer__copy { flex:1; min-width:0; display:grid; gap:4px; }
.ingredient-explorer__row strong { font-weight:600; font-size:.92rem; line-height:1.4; overflow-wrap:anywhere; }
.ingredient-explorer__meta { font-size:.76rem; color:var(--muted); line-height:1.4; overflow-wrap:anywhere; }
.ingredient-explorer__chevron { flex:none; color:var(--muted); font-size:1.5rem; }
.ingredient-explorer__row:focus-visible,.ingredient-explorer__tab:focus-visible { outline:2px solid var(--accent); outline-offset:-3px; }
.ingredient-explorer__row:hover { background:color-mix(in srgb,var(--surface-2) 60%,transparent); }
.ingredient-explorer__categories { border:1px solid var(--border); border-radius:16px; overflow:hidden; background:var(--surface); }
.ingredient-explorer__category { display:flex; align-items:center; justify-content:space-between; gap:12px; width:100%; min-height:49px; padding:10px 14px; border:0; color:var(--text); background:transparent; text-align:left; font:inherit; font-size:.87rem; cursor:pointer; }
.ingredient-explorer__category + .ingredient-explorer__category { border-top:1px solid var(--border); }
.ingredient-explorer__category > span:first-child { min-width:0; overflow-wrap:anywhere; }
.ingredient-explorer__selection { display:flex; align-items:center; flex-wrap:wrap; gap:4px 8px; color:var(--muted); font-size:.8rem; }
.ingredient-explorer__back { min-height:44px; border:0; background:transparent; color:var(--accent); font:inherit; padding:4px 0; cursor:pointer; }
.ingredient-explorer__pagination { display:flex; align-items:center; justify-content:space-between; gap:8px; }
.ingredient-explorer__pagination button { min-height:44px; font-size:.8rem; }
.ingredient-explorer__pagination span { color:var(--muted); font-size:.74rem; text-align:center; }
.ingredient-explorer__empty { padding:18px 4px; margin:0; font-size:.85rem; line-height:1.5; color:var(--muted); }
.ingredient-explorer-detail { width:min(560px,calc(100vw - 24px)); max-height:calc(100dvh - 24px); overflow:auto; }
.ingredient-explorer-detail > .menu-dialog__panel { display:grid; gap:14px; padding:16px; }
.ingredient-explorer-detail .menu-dialog__heading { margin:0; align-items:flex-start; }
.ingredient-explorer-detail h2 { margin:0; font-size:1.2rem; overflow-wrap:anywhere; }
.ingredient-explorer-detail h3 { margin:0 0 8px; font-size:.83rem; font-weight:650; }
.ingredient-explorer-detail__favorite { justify-self:start; min-height:44px; padding:6px 12px; font-size:.8rem; }
.ingredient-explorer-detail__favorite[aria-pressed=true] { color:var(--accent); border-color:var(--accent); }
.ingredient-explorer-detail__section { min-width:0; }
.ingredient-explorer-detail__section p { margin:0; color:var(--muted); font-size:.82rem; line-height:1.5; overflow-wrap:anywhere; }
.ingredient-explorer-detail__category,.ingredient-explorer-detail__link { display:block; width:100%; min-height:44px; padding:9px 0; border:0; border-bottom:1px solid var(--border); background:transparent; color:var(--accent); text-align:left; font:inherit; font-size:.85rem; overflow-wrap:anywhere; cursor:pointer; }
.ingredient-explorer-detail__advanced,.ingredient-explorer-detail__raw { min-width:0; }
.ingredient-explorer-detail__advanced > summary,.ingredient-explorer-detail__raw > summary,.ingredient-products__evidence > summary { min-height:44px; display:flex; align-items:center; cursor:pointer; color:var(--muted); font-size:.82rem; }
.ingredient-explorer-detail__advanced > summary::after,.ingredient-explorer-detail__raw > summary::after { content:'⌄'; margin-left:auto; }
.ingredient-explorer-detail__facts { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1.4fr); gap:8px; font-size:.76rem; margin:8px 0; }
.ingredient-explorer-detail__facts dt { color:var(--muted); }.ingredient-explorer-detail__facts dd { margin:0; overflow-wrap:anywhere; }
.ingredient-explorer-detail .ingredient-products { margin:0; padding:0; }
@media(max-width:600px){
 .ingredient-explorer-detail { width:100%; max-width:100%; margin:auto 0 0; border-radius:18px 18px 0 0; max-height:calc(100dvh - max(12px,env(safe-area-inset-top))); }
 .ingredient-explorer-detail > .menu-dialog__panel { padding:14px 14px max(14px,env(safe-area-inset-bottom)); }
}

/* v205: instruction-first writing uses the existing step card and pickers. */
.recipe-step-composer {display:grid;grid-template-columns:minmax(0,1fr) auto;gap:4px 8px;align-items:center;}
.recipe-step-composer__add {min-height:44px;min-width:44px;padding:7px 10px;border:1px solid var(--border);border-radius:10px;background:var(--surface-2);color:var(--text);font:inherit;font-size:.82rem;cursor:pointer;}
.recipe-step-composer > .recipe-step-editor__error {grid-column:1/-1;margin:0;}
.recipe-step-composer > .recipe-step-editor__error:empty {display:none;}
.recipe-edit-dialog--conversational .recipe-step-editor__instruction-field {margin:0 0 5px!important;}
.recipe-edit-dialog--conversational .recipe-step-editor__instruction-field > .recipe-edit-dialog__label {display:none;}
.recipe-step-composer:focus-within,.recipe-step-editor__instruction-field:focus-within {outline:2px solid var(--accent);outline-offset:3px;border-radius:6px;}
.recipe-step-editor__method-details > summary,.recipe-step-editor__ingredient-details > summary {font-size:.78rem;color:var(--muted);cursor:pointer;padding:8px 0;min-height:32px;box-sizing:border-box;}
.recipe-step-editor__method-details[hidden] {display:none;}
.recipe-step-editor__ingredient-details {margin:2px 0;}
.recipe-step-editor__more .recipe-step-editor__technique-chooser {margin-top:8px;}
.recipe-step-editor__more .recipe-step-card__create:not(:empty) {margin-bottom:8px;}
.recipe-instruction-popup__option small {margin-left:10px;flex-shrink:0;}
@media(max-width:360px){.recipe-step-composer__add {font-size:.76rem;padding-inline:7px;}}
