@font-face { font-family: 'IBM Plex Mono'; src: url('/plex-mono-regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'IBM Plex Mono'; src: url('/plex-mono-semibold.woff2') format('woff2'); font-weight: 600 800; font-display: swap; }
:root {
  color-scheme: light;
  --ink: #22272c;
  --muted: #52606b;
  --line: #cbd3da;
  --page: #f3f6f8;
  --accent: #b23122;
  font: 100%/1.5 'IBM Plex Mono', ui-monospace, Consolas, monospace;
  color: var(--ink);
  background: var(--page);
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100dvh; }
.masthead {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: start;
  gap: .65rem 1rem;
  padding: 1rem clamp(1rem, 5vw, 3rem);
}
.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  width: max-content;
  max-width: 100%;
  min-height: clamp(100px, 15vw, 135px);
  margin-inline: auto;
  font-size: clamp(2.25rem, 6vw, 3.2rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -.075em;
}
.brand img { flex: none; display: block; width: 1.2em; height: 1.2em; margin-inline-end: -.1em; }
.brand-block { align-self: center; text-align: center; padding-block: .75rem .35rem; }
.brand-block .brand { display: grid; grid-template-columns: auto auto; min-height: 0; }
.brand-block .brand img { grid-row: 1 / 3; align-self: start; }
.brand-word { grid-column: 2; line-height: .98; }
.brand-claim {
  grid-column: 2;
  margin-top: .08rem;
  color: var(--accent);
  font-size: calc(.205em + 1px);
  letter-spacing: normal;
  line-height: 1.2;
  white-space: nowrap;
}
main { width: min(700px, calc(100% - 2rem)); margin: clamp(2rem, 11vh, 7rem) auto 4rem; }
.cooking-page { margin-top: clamp(.75rem, 4vh, 3rem); }
h1 { margin: 0 0 1.5rem; font-size: clamp(1.7rem, 5.3vw, 3.3rem); letter-spacing: -.065em; line-height: 1.14; text-align: center; }
#ingredients-title { font-size: clamp(1.45rem, 4vw, 2.35rem); }
.plate-page { margin-top: clamp(.75rem, 4vh, 3rem); }
.plate-page h1 { font-size: clamp(1.45rem, 4vw, 2.35rem); }
.plate-page .composer > p:first-child { margin: 0 0 .85rem; }
#plate-preview { display: block; width: 100%; max-height: 340px; object-fit: contain; border-radius: 14px; margin-bottom: .75rem; background: var(--page); }
#plate-page .result h3 { font-size: 1rem; margin-bottom: .35rem; }
#plate-match-link { color: var(--accent); text-underline-offset: .22em; }
.composer { border: 1px solid var(--line); border-radius: 24px; background: white; padding: 1rem; box-shadow: 0 12px 34px #2028330e; }
.composer:focus-within { border-color: #8c9ca9; }
textarea, input, select, button { font: inherit; color: inherit; }
textarea { width: 100%; min-height: 106px; max-height: 50vh; padding: .35rem .35rem .7rem; resize: vertical; border: 0; background: transparent; }
textarea::placeholder { color: var(--muted); opacity: 1; }
#attachments:not([hidden]) + #notes::placeholder { color: #767676; }
#notes:focus::placeholder { opacity: 0; }
#attachments:not([hidden]) { margin-bottom: .25rem; }
#notes {
  display: block;
  min-height: 2rem;
  padding-block: .25rem .5rem;
  line-height: 1.45;
  field-sizing: content;
  resize: none;
}
.composer textarea:focus { outline: 0; }
.composer-tools { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
.share-catalog-photos { display: flex; align-items: baseline; gap: .4rem; margin-top: .65rem; color: var(--muted); font-size: .8rem; }
.share-catalog-photos input { flex: none; margin: 0; accent-color: var(--accent); }
button { min-height: 42px; padding: .4rem .8rem; border: 1px solid var(--line); border-radius: 14px; font-weight: 600; background: white; cursor: pointer; }
button:hover:not(:disabled) { border-color: #778792; background: #f4f7f9; }
button:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
button:disabled { cursor: default; opacity: .55; }
.icon-button { display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0; color: var(--ink); }
.icon-button[aria-pressed='true'] { color: var(--accent); background: #fff2ef; border-color: var(--accent); }
.composer-submit { display: flex; align-items: center; gap: .4rem; margin-inline-start: auto; }
.composer-tools .primary { border-radius: 50%; background: var(--accent); border-color: var(--accent); color: white; }
.composer-tools .primary:disabled { opacity: .45; }
.composer-tools .primary:hover:not(:disabled) { background: #91281d; }
.icon { display: block; position: relative; width: 20px; height: 20px; }
.icon::before, .icon::after { content: ''; position: absolute; }
.paperclip::before { inset: 1px 5px 0 5px; border: 1.7px solid currentColor; border-top-color: transparent; border-radius: 7px; transform: rotate(38deg); }
.paperclip::after { width: 5px; height: 13px; top: 1px; left: 8px; border: 1.7px solid currentColor; border-bottom-color: transparent; border-radius: 6px; transform: rotate(38deg); }
.photo::before { inset: 5px 0 1px; border: 1.7px solid currentColor; border-radius: 3px; box-shadow: 0 -4px 0 -2px currentColor; }
.photo::after { width: 6px; height: 6px; top: 9px; left: 7px; border: 1.5px solid currentColor; border-radius: 50%; box-sizing: border-box; }
.video::before { inset: 4px 6px 4px 0; border: 1.7px solid currentColor; border-radius: 3px; }
.video::after { inset: 5px 0 5px 14px; border-radius: 2px; background: currentColor; clip-path: polygon(0 28%, 100% 0, 100% 100%, 0 72%); }
.mic::before { inset: 0 7px 7px; border: 1.6px solid currentColor; border-radius: 7px; }
.mic::after { inset: 5px 4px 2px; border: 1.6px solid currentColor; border-top: 0; border-radius: 0 0 8px 8px; }
.mic { background: linear-gradient(currentColor, currentColor) center bottom / 1.6px 3px no-repeat; }
.arrow::before { width: 1.8px; height: 14px; top: 3px; left: 9px; border-radius: 1px; background: currentColor; }
.arrow::after { width: 8px; height: 8px; top: 3px; left: 5.5px; border-top: 1.8px solid currentColor; border-left: 1.8px solid currentColor; transform: rotate(45deg); }
.message { margin: .7rem .25rem 0; color: var(--muted); font-size: .9rem; }
.message:empty { display: none; }
.message.loading-message { color: var(--accent); }
@media (prefers-reduced-motion: no-preference) {
  .loading-message { animation: loading-pulse 1.15s ease-in-out infinite; }
}
@keyframes loading-pulse { 50% { opacity: .35; } }
.attachments { list-style: none; padding: 0; margin: 0 0 .75rem; display: flex; flex-wrap: wrap; gap: .6rem; }
.attachments li { min-width: 0; display: flex; gap: .5rem; align-items: center; padding: .25rem; border: 1px solid var(--line); border-radius: 12px; }
.attachments img { width: 40px; height: 40px; object-fit: cover; border-radius: 8px; }
.attachments span { max-width: min(180px, 36vw); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .85rem; }
.attachments button { min-height: 36px; min-width: 36px; padding: 0 .35rem; border: 0; }
dialog { width: min(520px, calc(100% - 2rem)); max-height: 92dvh; padding: 1rem; border: 1px solid var(--line); border-radius: 20px; background: white; color: var(--ink); }
dialog::backdrop { background: #111c2980; }
.dialog-heading { display: flex; justify-content: space-between; align-items: center; gap: .5rem; margin-bottom: .75rem; }
.dialog-heading h2 { margin: 0; font-size: 1.25rem; }
#viewfinder { display: block; width: 100%; max-height: 52dvh; border-radius: 12px; background: #171d24; }
dialog .composer-tools { margin-top: .75rem; }
.result { margin-top: 1rem; padding: 1rem 1.2rem; background: white; border: 1px solid var(--line); border-radius: 18px; }
.result h2 { margin: 0; font-size: 1.15rem; }
.result ul { padding-left: 1.2rem; margin: .5rem 0 0; }
.result li { margin: .2rem 0; }
details.result > summary { cursor: pointer; }
details.result > summary h2 { display: inline; }
#result > summary h2 { font-size: clamp(.8rem, 4vw, 1rem); }
details.result > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.ingredient-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); gap: .75rem 1.25rem; margin-top: .75rem; }
.ingredient-group-other, .ingredient-group:has(+ .ingredient-group-other):first-child { grid-column: 1 / -1; }
.ingredient-group h3 { margin: 0; font-size: 1rem; }
.ingredient-group h4 { display: flex; align-items: baseline; gap: .45rem; margin: .65rem 0 0; color: var(--muted); font-size: .85rem; }
.ingredient-group h4::before { content: ''; flex: none; width: .4rem; height: .4rem; border-radius: 50%; background: var(--accent); }
.result .ingredient-group ul { margin: .15rem 0 0; padding: 0; padding-inline-start: 1.25rem; list-style: none; overflow-wrap: anywhere; }
#ingredients label { display: inline-flex; align-items: baseline; gap: .5rem; padding-block: .16rem; cursor: pointer; }
#ingredients li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .25rem; }
.ingredient-nutrition { font-size: .78rem; color: var(--muted); }
.add-more-ingredients {
  display: block;
  width: fit-content;
  margin: .65rem auto 0;
  color: var(--accent);
  font-size: .8rem;
  text-align: center;
}
.ingredient-catalog-note { color: var(--accent); font-size: .75rem; }
#detected-ingredient-count { color: var(--accent); }
body[data-recipe-origin="hidden"] :is(.recipe-origin, #explorer footer) { display: none; }
body[data-ingredient-nutrition="hidden"] :is(.ingredient-nutrition, .recipe-ingredient-nutrition) { display: none; }
#ingredients .ingredient-nutrition { flex-basis: 100%; margin-inline-start: 1.25rem; }
.ingredient-nutrition summary { cursor: pointer; }
.ingredient-nutrition div { white-space: pre-line; padding-block: .25rem; }
#ingredients input { margin: 0; accent-color: var(--accent); }
.ingredient-remove { flex: none; min-height: 36px; width: 36px; padding: 0; border-color: transparent; color: var(--accent); font-size: 1.2rem; }
.recipe-form { display: flex; align-items: end; flex-wrap: wrap; gap: .65rem; margin-top: .9rem; }
.recipe-limits { display: contents; }
.recipe-form label { display: block; margin-bottom: .3rem; font-size: .88rem; }
.recipe-form select { width: 100%; min-height: 42px; padding: .3rem .6rem; border: 1px solid var(--line); border-radius: 10px; background: white; }
.recipe-form button { border-color: var(--accent); background: var(--accent); color: white; }
.recipe-form button:hover:not(:disabled) { border-color: #91281d; background: #91281d; }
.recipe-sources { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: .35rem 1rem; }
.recipe-sources label { display: inline-flex; align-items: center; gap: .4rem; margin: 0; }
.recipe-sources input { margin: 0; accent-color: var(--accent); }
.recipe-nutrition-source { display: block; color: var(--muted); font-size: .74rem; }
.recipe .recipe-stock { color: var(--accent); }
.pantry-form { display: flex; flex-wrap: wrap; gap: .5rem; }
.pantry-form input { flex: 1 1 12rem; min-width: 0; padding: .4rem .6rem; border: 1px solid var(--line); border-radius: 10px; }
.pantry-list { list-style: none; padding: 0; margin: .65rem 0 0; }
.pantry-list li { display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding-block: .35rem; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.pantry-list button { font-size: .85rem; }
.recipes { display: grid; gap: .75rem; margin-top: 1rem; }
.recipes:empty { margin-top: 0; }
.recipe-suggestions { margin-top: 1rem; }
.recipe-suggestions h2 { margin: 0; font-size: 1.15rem; }
.recipe-suggestions .recipes { margin-top: .65rem; }
.suggestion-total { margin: .25rem 0; font-size: .9rem; color: var(--accent); }
.suggestion-pager { display: flex; align-items: center; justify-content: center; gap: .55rem; margin-top: .65rem; }
.suggestion-pager span { min-width: 6ch; text-align: center; }
.suggestion-pager button { min-width: 42px; color: var(--accent); }
.recipe-more-actions { margin-top: .8rem; }
.favorite-meal h3 { margin: 0; font-size: .95rem; }
.favorite-meal .recipes { margin-top: .35rem; }
.favorite-confirm-title { display: flex; align-items: center; gap: .55rem; margin: 0; font-size: 1.25rem; }
.favorite-confirm-title span { color: var(--accent); font: 1.5rem/1 system-ui, sans-serif; }
.confirm-actions { display: flex; justify-content: flex-end; gap: .5rem; }
.recipe-card { position: relative; }
.recipe { border: 1px solid var(--line); border-radius: 18px; background: white; overflow-wrap: anywhere; }
.recipe summary { padding: .85rem 3.5rem .85rem 1.2rem; border-radius: inherit; font-weight: 600; cursor: pointer; }
.recipe summary::marker { color: var(--accent); }
.recipe summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.favorite-button {
  position: absolute;
  inset-block-start: .25rem;
  inset-inline-end: .35rem;
  display: grid;
  place-items: center;
  width: 44px;
  min-height: 44px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--accent);
  font: 1.5rem/1 system-ui, sans-serif;
}
.recipe-content { padding: 0 1.2rem 1rem; }
.recipe-estimates { display: inline-flex; flex-wrap: wrap; gap: 0 .65rem; margin-inline-start: .6rem; color: var(--muted); font-size: .83rem; font-weight: 400; }
.recipe-estimates span { white-space: nowrap; }
.recipe h3, .recipe p, .recipe ul, .recipe ol { margin: 0; }
.recipe h3 { margin: .85rem 0 .3rem; font-size: .95rem; }
.recipe p { margin-top: .35rem; color: var(--muted); font-size: .85rem; }
.recipe ul, .recipe ol { padding-left: 1.3rem; }
.recipe li + li { margin-top: .3rem; }
.recipe-photo { margin-top: .8rem; }
.recipe-photo figure { margin: 0; max-width: 500px; }
.recipe-photo img { display: block; width: 100%; height: auto; border-radius: 12px; background: var(--page); }
.recipe-photo figcaption { margin-top: .3rem; color: var(--muted); font-size: .8rem; }
.recipe-photo button { margin-top: .5rem; }
.header-menu { position: relative; }
.header-menu[open] { z-index: 2; }
.general-menu { justify-self: start; }
.user-menu { justify-self: end; }
.header-menu-toggle {
  display: flex;
  align-items: center;
  gap: .45rem;
  min-height: 44px;
  padding: .35rem .65rem;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: white;
  font-size: .87rem;
  font-weight: 600;
  cursor: pointer;
}
.header-menu-toggle::-webkit-details-marker { display: none; }
.header-menu-toggle:hover { border-color: #778792; }
.header-menu[open] > .header-menu-toggle { border-color: #df9b92; background: #faece8; color: #842419; }
.header-menu-toggle:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.menu-bars { display: block; flex: none; width: .8rem; height: .65rem; border-block: 1px solid currentColor; background: linear-gradient(currentColor, currentColor) center / 100% 1px no-repeat; }
.user-menu-toggle { padding-inline-start: .4rem; }
.user-menu-toggle::after { content: '▾'; color: var(--muted); }
.user-identity { display: grid; min-width: 0; text-align: start; }
.user-name { max-width: min(26ch, 24vw); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-identity small { color: var(--muted); font-size: .68rem; font-weight: 400; white-space: nowrap; }
.user-avatar { position: relative; display: inline-grid; flex: none; place-items: center; width: 34px; height: 34px; overflow: hidden; border-radius: 50%; background: #fbe6e2; color: #842419; font-weight: 600; }
.user-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.header-menu-panel {
  position: absolute;
  inset-inline-start: 0;
  width: min(17rem, calc(100vw - 2rem));
  max-height: calc(100dvh - 5rem);
  overflow-y: auto;
  display: grid;
  gap: .15rem;
  margin-top: .35rem;
  padding: .4rem;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: white;
  box-shadow: 0 8px 26px #20283324;
}
.user-menu .header-menu-panel { inset-inline: auto 0; width: min(15rem, calc(100vw - 2rem)); }
.header-menu-label { margin: 0; padding: .25rem .5rem; color: var(--muted); font-size: .74rem; }
.header-menu-panel button, .header-menu-panel a {
  display: flex;
  align-items: center;
  gap: .45rem;
  width: 100%;
  min-height: 40px;
  padding: .4rem .5rem;
  border: 0;
  border-radius: 9px;
  background: transparent;
  text-align: start;
  font-size: .86rem;
  font-weight: 400;
}
.header-menu-panel a { color: inherit; text-decoration: none; }
.header-menu-panel a:hover { background: #f4f7f9; }
.header-menu-panel button:disabled { color: var(--muted); opacity: .8; }
.header-menu-panel :is(button, a):focus-visible { outline: 3px solid var(--accent); outline-offset: -2px; }
.header-menu-icon { flex: 0 0 1rem; text-align: center; }
.header-menu-panel small { display: block; color: var(--muted); font-size: .72rem; }
.header-menu-panel .header-menu-current { color: #842419; background: #faece8; }
.header-menu-panel .header-menu-current:hover { background: #f8e1dc; }
.header-menu-group { display: grid; gap: .15rem; margin-top: .2rem; padding-top: .2rem; border-top: 1px solid var(--line); }
.experiment-options { display: grid; gap: .25rem; margin: 1rem 0 0; padding: .15rem .75rem .5rem; border: 1px solid var(--line); border-radius: 12px; }
.experiment-options legend { padding-inline: .3rem; font-weight: 600; }
.experiment-options label { display: flex; align-items: flex-start; gap: .65rem; padding: .55rem .25rem; cursor: pointer; }
.experiment-options input { margin: .3rem 0 0; accent-color: var(--accent); }
body[data-query-costs='hidden'] [data-query-cost],
body[data-user-costs='hidden'] [data-query-cost='credits'],
body[data-global-costs='hidden'] [data-query-cost='usd'] { display: none; }
.profile-form { display: flex; align-items: flex-start; gap: .8rem; }
.profile-form .user-avatar { width: 52px; height: 52px; }
.profile-fields { flex: 1; min-width: 0; display: grid; gap: .4rem; }
.profile-fields input { max-width: 100%; }
.profile-fields input[type='text'] { min-height: 42px; border: 1px solid var(--line); border-radius: 10px; padding: .4rem .6rem; }
.profile-actions { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .3rem; }
.users-list { display: grid; gap: .5rem; padding: 0; margin: .75rem 0 0; list-style: none; }
.users-list:empty { margin: 0; }
.users-list li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .6rem; padding: .65rem; border: 1px solid var(--line); border-radius: 12px; }
.users-list li > div:first-child { min-width: 0; overflow-wrap: anywhere; }
.users-list li > div:first-child > div { color: var(--muted); font-size: .84rem; }
.user-status { display: inline-block; margin-top: .25rem; padding: .1rem .35rem; border-radius: 6px; background: var(--page); color: var(--muted); font-size: .78rem; }
.user-status[data-state='pending'] { background: #fff1d8; color: #6c4612; }
.user-status[data-state='approved'] { background: #e3f1e6; color: #285139; }
.user-status[data-state='rejected'] { background: #faece8; color: #842419; }
.user-actions { display: flex; gap: .35rem; }
.user-actions button { font-size: .84rem; }
.google-login { display: inline-flex; min-height: 44px; align-items: center; gap: 10px; padding: 0 12px; border: 1px solid #747775; border-radius: 14px; color: #1f1f1f; background: white; font: 500 .9rem/1.3 system-ui, sans-serif; text-decoration: none; }
.google-login:hover { background: #f7f8f9; }
.google-login:focus-visible, #balance:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.login-page { width: min(430px, calc(100% - 2rem)); margin: clamp(2rem, 9vh, 6rem) auto; }
.login-card { display: grid; margin-top: 1.4rem; padding: clamp(1.15rem, 5vw, 1.9rem); border: 1px solid var(--line); border-radius: 24px; background: white; }
.login-card h1 { margin: 0 0 1.25rem; text-align: start; font-size: clamp(1.65rem, 5.3vw, 2.38rem); }
.login-card form { display: grid; gap: .5rem; }
.login-card label { font-size: .9rem; }
.login-card input { width: 100%; margin-bottom: .45rem; min-height: 44px; border-radius: 10px; border: 1px solid var(--line); padding: .5rem .65rem; }
.login-card input:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.login-card input[type='file'] { font-size: .82rem; }
.login-method { margin: .5rem 0 1rem; text-align: center; color: var(--muted); font-size: .8rem; }
.privacy-link { color: #000; }
.login-card details { margin: 0 0 .4rem; font-size: .85rem; }
.login-card details label { display: block; margin-top: .4rem; }
.login-card summary { cursor: pointer; }
.login-submit { color: white; background: var(--accent); border-color: var(--accent); }
.login-submit:hover:not(:disabled), .stop-mic:hover:not(:disabled) { color: white; background: #91281d; border-color: #91281d; }
.login-switch { margin-top: .75rem; }
.login-card .google-login { justify-content: center; margin-top: .65rem; }
.dictation-progress { display: inline-flex; align-items: center; gap: .45rem; margin-inline-start: .25rem; color: var(--accent); }
.recording-dots { display: inline-flex; gap: 4px; }
.recording-dots i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; animation: recording-dot 1s infinite; }
.recording-dots i:nth-child(2) { animation-delay: .14s; }
.recording-dots i:nth-child(3) { animation-delay: .28s; }
@keyframes recording-dot { 0%, 80%, 100% { opacity: .4; transform: scale(.7); } 40% { opacity: 1; transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .recording-dots i { animation: none; } }
.stop-mic { margin-inline-start: auto; border-radius: 10px; border-color: var(--accent); background: var(--accent); color: white; }
.stop-mic span { display: block; width: 13px; height: 13px; border-radius: 2px; background: currentColor; }
.video-progress { display: inline-flex; align-items: center; gap: .6rem; color: var(--accent); font-variant-numeric: tabular-nums; }
.video-record-dot { width: .72rem; height: .72rem; border-radius: 50%; background: currentColor; animation: recording-dot 1s infinite; }
@media (prefers-reduced-motion: reduce) { .video-record-dot { animation: none; } }
#costs-dialog { width: min(620px, calc(100% - 2rem)); }
.cost-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; margin: .8rem 0; }
.cost-summary > div { min-width: 0; background: var(--page); border-radius: 12px; padding: .65rem .75rem; }
.usage-line { margin: .45rem .25rem 0; color: var(--muted); font-size: clamp(.65rem, 3vw, .75rem); }
.usage-line strong { color: var(--ink); }
.cost-summary dt, #balance-form label { display: block; font-size: .85rem; }
.cost-summary dd { overflow-wrap: anywhere; margin: .3rem 0 0; font-size: 1.08rem; font-weight: 600; }
#balance-form { margin-block: 1rem; }
.balance-actions, .cost-footer { display: flex; flex-wrap: wrap; gap: .55rem; align-items: center; margin-top: .35rem; }
#balance { min-width: 0; width: min(13rem, 100%); min-height: 42px; padding: .45rem .65rem; border: 1px solid var(--line); border-radius: 10px; }
#costs-content h3, #credits-content h3 { font-size: 1rem; margin: 0; }
.call-list { margin: .5rem 0 1rem; padding: 0; list-style: none; }
.call-list li { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .2rem .6rem; border-bottom: 1px solid var(--line); padding: .5rem 0; font-size: .9rem; overflow-wrap: anywhere; }
.cost-footer { justify-content: space-between; }
.cost-footer a { font-size: .88rem; color: var(--accent); }
.mobile-preview { display: grid; place-items: center; padding: min(1rem, 3vw); }
.mobile-preview iframe {
  display: block;
  max-width: 100%;
  max-height: calc(100dvh - min(2rem, 6vw));
  border: 1px solid var(--line);
  border-radius: 18px;
}
[hidden] { display: none !important; }
@media (max-width: 720px) {
  .masthead { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .masthead .brand-block { grid-area: 2 / 1 / auto / -1; }
  .user-name { max-width: min(20ch, 28vw); }
}
@media (max-width: 520px) {
  main { margin-top: 3rem; }
  .cooking-page { margin-top: .75rem; }
  #ingredients-title { font-size: clamp(1.05rem, 5.5vw, 1.45rem); }
  .plate-page h1 { font-size: clamp(1.05rem, 5.5vw, 1.45rem); }
  .masthead { padding-top: .65rem; }
  .composer { padding: .8rem; }
  .ingredient-groups { grid-template-columns: 1fr; }
  .recipe-limits { display: grid; flex-basis: 100%; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
  .recipe-limits label { font-size: clamp(.72rem, 3.3vw, .88rem); }
  .recipe-limits select { font-size: clamp(.78rem, 3.6vw, 1rem); }
}

.menu-combination small { color: var(--muted); font-size: .86rem; }
.menu-combination { margin: .45rem 0; padding: .8rem 1rem; background: white; border: 1px solid var(--line); border-radius: 14px; }
.menu-combination > summary { cursor: pointer; font-weight: 600; }
.menu-combination small { display: block; margin-top: .3rem; font-weight: 400; }
.menu-combination h4 { margin: 1rem 0 .3rem; }
