:root {
  color-scheme: light;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #252b23;
  background: #f5f4ec;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --paper: #f5f4ec;
  --surface: #fffefa;
  --ink: #252b23;
  --muted: #777d72;
  --line: #e7e8de;
  --green: #35573e;
  --green-dark: #24442f;
  --green-pale: #e7efe4;
  --lime: #d8ed91;
  --orange: #f2a65a;
  --orange-pale: #fff0df;
  --red: #aa4b3f;
  --target: 48px;
  --radius: 22px;
  --shadow: 0 10px 34px rgb(47 56 43 / 7%);
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-padding-block-end: calc(92px + env(safe-area-inset-bottom, 0px)); }
body { margin: 0; min-width: 320px; min-height: 100vh; padding: 0 0 calc(104px + env(safe-area-inset-bottom, 0px)); overflow-wrap: break-word; }
button, input, select, textarea { font: inherit; font-size: max(1rem, 1em); }
button, select, input[type="search"], input[type="text"], textarea { min-block-size: var(--target); }
button { color: inherit; cursor: pointer; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, label:has(input:focus-visible) { outline: 3px solid #b48542; outline-offset: 3px; }
img, video { max-inline-size: 100%; block-size: auto; }
h1, h2, h3 { font-family: Manrope, 'DM Sans', system-ui, sans-serif; letter-spacing: -.035em; text-wrap: balance; }
p, li { text-wrap: pretty; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

.topbar { min-height: 76px; padding: max(12px, env(safe-area-inset-top, 0px)) clamp(18px, 5vw, 56px) 12px; display: flex; align-items: center; justify-content: space-between; gap: 16px; max-width: 1240px; margin-inline: auto; }
.brand { border: 0; background: transparent; display: flex; align-items: center; gap: 10px; padding: 3px 0; min-block-size: 48px; }
.brand-mark { display: grid; width: 38px; height: 38px; color: var(--green); }
.brand-mark svg { display: block; width: 100%; height: 100%; }
.brand-name { font: 800 21px/1 Manrope, sans-serif; letter-spacing: -.06em; }
.brand-name span { color: var(--green); }
.device-note { display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; min-height: 36px; border-radius: 99px; background: #ebece3; color: #646c5e; font-size: 12px; font-weight: 600; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #6ca879; }
.app-main { max-width: 1120px; min-height: 68vh; margin-inline: auto; padding: 10px clamp(16px, 4.5vw, 48px) 34px; }
.page-shell { animation: appear .2s ease-out both; }
@keyframes appear { from { opacity: .5; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin: 20px 0 25px; }
.page-heading h1 { margin: 5px 0 5px; font-size: clamp(30px, 6vw, 43px); line-height: 1.06; }
.page-heading p { margin: 0; color: var(--muted); }
.eyebrow { margin: 0; color: #7a886b; text-transform: uppercase; letter-spacing: .12em; font-size: 11px; font-weight: 700; }
.muted { color: var(--muted); }
.small-text { font-size: 13px; }
.page-actions { display: flex; gap: 9px; align-items: center; flex-wrap: wrap; }
.section-title { margin: 0; font: 700 20px/1.2 Manrope, sans-serif; letter-spacing: -.04em; }
.section-subtitle { color: var(--muted); font-size: 13px; margin: 5px 0 0; }

.button { border: 1px solid transparent; border-radius: 14px; min-height: var(--target); padding: 0 16px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; font-weight: 700; font-size: 14px; text-decoration: none; transition: transform .15s ease, background-color .15s ease, border-color .15s ease; }
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0); }
.button-primary { color: #fffefa; background: var(--green); }
.button-primary:hover { background: var(--green-dark); }
.button-lime { color: #263a29; background: var(--lime); }
.button-soft { color: var(--green-dark); background: var(--green-pale); }
.button-quiet { color: #60695e; background: transparent; border-color: var(--line); }
.button-danger { color: var(--red); background: #f9ebe8; }
.button:disabled { cursor: wait; opacity: .65; transform: none; }
.button-hero-quiet { color: #fffefa; background: rgb(255 255 255 / 8%); border-color: rgb(255 255 255 / 30%); }
.button-hero-quiet:hover { background: rgb(255 255 255 / 15%); }
.button-small { min-height: 44px; padding-inline: 12px; border-radius: 12px; font-size: 12px; }
.button-wide { width: 100%; }
.icon-button { width: 46px; height: 46px; min-width: 46px; border: 0; border-radius: 50%; background: #eff0e9; color: #4a5145; font-size: 25px; line-height: 1; display: inline-grid; place-items: center; }
.text-button { min-height: 44px; padding: 4px 0; border: 0; color: var(--green); background: transparent; font-size: 13px; font-weight: 700; }

.hero { isolation: isolate; position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 18px; min-height: 245px; padding: clamp(24px, 5vw, 42px); border-radius: 30px; color: #fffef5; background: var(--green); box-shadow: var(--shadow); }
.hero::before, .hero::after { content: ''; position: absolute; z-index: -1; border-radius: 50%; border: 1px solid rgb(238 242 214 / 13%); }
.hero::before { width: 330px; height: 330px; right: -54px; top: -134px; box-shadow: 0 0 0 30px rgb(238 242 214 / 4%), 0 0 0 60px rgb(238 242 214 / 4%); }
.hero::after { width: 90px; height: 90px; right: 117px; bottom: -47px; background: var(--orange); opacity: .9; }
.hero-copy { max-width: 540px; }
.hero .eyebrow { color: #cbd9bd; }
.hero h1 { max-width: 550px; margin: 10px 0 12px; font-size: clamp(30px, 6vw, 46px); line-height: 1.05; }
.hero p { max-width: 430px; margin: 0; color: #dce7d7; line-height: 1.6; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.hero-art { width: 156px; height: 156px; margin-right: 16px; position: relative; display: grid; place-items: center; border: 1px solid rgb(244 248 231 / 28%); border-radius: 50%; background: rgb(255 255 255 / 5%); }
.hero-art::before, .hero-art::after { content: ''; position: absolute; border: 1px solid rgb(244 248 231 / 25%); border-radius: 50%; }
.hero-art::before { inset: 13px; }
.hero-art::after { inset: 26px; }
.hero-bowl { position: relative; z-index: 1; color: #f7f2dd; font-size: 69px; transform: rotate(-12deg); }
.hero-spark { position: absolute; z-index: 2; color: var(--lime); font-size: 21px; }
.hero-spark-one { right: 30px; top: 17px; }
.hero-spark-two { left: 24px; bottom: 29px; color: var(--orange); font-size: 17px; }

.stats-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 18px 0 32px; }
.stat-card { min-width: 0; padding: 17px 18px; border: 1px solid var(--line); border-radius: 19px; background: rgb(255 254 250 / 72%); }
.stat-value { display: block; font: 800 25px/1 Manrope, sans-serif; color: var(--green); }
.stat-label { display: block; margin-top: 7px; color: var(--muted); font-size: 12px; }
.content-section { margin-top: 32px; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 14px; margin-bottom: 15px; }
.surface { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 5px 22px rgb(47 56 43 / 3%); }
.planner { padding: clamp(17px, 3.5vw, 27px); }
.planner-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 14px; }
.week-range { min-width: 0; font: 700 13px/1.3 Manrope, sans-serif; color: #5f665b; text-align: center; }
.week-switch { width: 42px; height: 42px; min-width: 42px; border: 1px solid var(--line); border-radius: 14px; background: #fffefa; color: var(--green); font-size: 20px; }
.week-today { min-height: 44px; padding-inline: 11px; border: 1px solid var(--line); border-radius: 14px; background: #fffefa; color: var(--green); font-size: 12px; font-weight: 700; }
.day-list { display: grid; gap: 9px; }
.day-row { display: grid; grid-template-columns: minmax(105px, .62fr) repeat(2, minmax(0, 1fr)); align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid #eeefe8; }
.weekly-count-field { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 10px 0 4px; padding: 13px 14px; border-radius: 14px; background: #eef2e9; }
.weekly-count-field label { color: #435442; font-size: 13px; font-weight: 700; }
.weekly-count-field select { width: auto; min-width: 125px; min-height: 44px; padding: 8px 30px 8px 11px; border: 1px solid #d6dfd0; border-radius: 11px; background: #fffefa; color: var(--green-dark); font-size: 13px; font-weight: 700; }
.plan-row { display: grid; grid-template-columns: minmax(78px, .45fr) minmax(150px, .85fr) minmax(0, 1.55fr); align-items: center; gap: 12px; padding: 13px 0; border-top: 1px solid #eeefe8; }
.plan-number { color: var(--green); font: 700 13px/1.2 Manrope, system-ui, sans-serif; }
.day-label { display: flex; flex-direction: column; gap: 3px; }
.day-label strong { font: 700 13px/1.2 Manrope, sans-serif; text-transform: capitalize; }
.day-label span { color: var(--muted); font-size: 11px; }
.plan-slot { min-width: 0; }
.plan-slot label { display: block; margin-bottom: 5px; color: #81867d; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.plan-slot select, .field select, .roulette-form select, .field input, .field textarea, .search-field { width: 100%; min-width: 0; min-height: 48px; padding: 10px 12px; border: 1px solid #dfe2d8; border-radius: 12px; background: #fff; color: var(--ink); }
.plan-slot select { min-height: 44px; padding: 9px 30px 9px 10px; font-size: 12px; }
select { accent-color: var(--green); }

.today-strip { display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: center; padding: 18px 20px; background: var(--orange-pale); border: 1px solid #f6dfc6; border-radius: 19px; }
.today-strip h2 { margin: 0 0 5px; font-size: 16px; }
.today-strip p { margin: 0; color: #7c694f; font-size: 13px; }
.today-meals { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.today-meal { padding: 8px 11px; border-radius: 99px; background: #fffaf3; font-size: 12px; font-weight: 700; color: #69553f; }

.category-pills { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0; }
.category-pill { min-height: 44px; padding: 0 15px; border: 1px solid var(--line); border-radius: 99px; background: var(--surface); color: #666d61; font-size: 12px; font-weight: 700; }
.category-pill[aria-pressed="true"] { background: var(--green); border-color: var(--green); color: white; }
.search-row { display: flex; gap: 10px; align-items: center; margin: 18px 0; }
.search-wrap { flex: 1; min-width: 0; }
.search-wrap label { display: block; margin-bottom: 6px; font-size: 12px; font-weight: 700; }
.search-field { min-height: 48px; background: #fffefa; }
.menu-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.menu-card { min-width: 0; overflow: hidden; background: var(--surface); border: 1px solid var(--line); border-radius: 21px; box-shadow: 0 5px 22px rgb(47 56 43 / 3%); }
.menu-card-image { width: 100%; height: 150px; display: block; object-fit: cover; background: #ecefe6; }
.menu-card-placeholder { display: grid; place-items: center; color: #729070; background: linear-gradient(135deg, #e9f0e4, #f9eddc); font: 500 57px/1 Georgia, serif; }
.menu-card-body { padding: 16px 17px 17px; }
.menu-card-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.category-tag { display: inline-flex; align-items: center; min-height: 27px; padding: 0 10px; border-radius: 99px; background: var(--green-pale); color: #45634a; font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.category-tag[data-category="desayuno"] { background: #fff1da; color: #94642b; }
.category-tag[data-category="almuerzo"] { background: #e3efdc; color: #3b6847; }
.category-tag[data-category="cena"] { background: #ece8f6; color: #675486; }
.category-tag[data-category="merienda"] { background: #fae6e0; color: #9a5949; }
.menu-rating { color: #797f73; font-size: 11px; white-space: nowrap; }
.menu-card h3 { margin: 12px 0 7px; font-size: 18px; line-height: 1.2; }
.menu-title-button { min-height: 44px; padding: 0; border: 0; background: transparent; color: var(--ink); font: inherit; font-weight: inherit; line-height: inherit; text-align: left; }
.menu-card-ingredients { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.menu-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 14px; color: #878c81; font-size: 11px; }
.menu-card-open { min-height: 44px; padding: 0; border: 0; background: transparent; color: var(--green); font-size: 11px; font-weight: 800; white-space: nowrap; }
.menu-card-arrow { color: var(--green); font-size: 19px; }
.empty-state { padding: 30px 22px; text-align: center; border: 1px dashed #cdd5c9; border-radius: 21px; background: rgb(255 254 250 / 55%); }
.empty-illustration { width: 54px; height: 54px; margin: 0 auto 13px; display: grid; place-items: center; border-radius: 18px; background: var(--green-pale); color: var(--green); font-size: 27px; }
.empty-state h3 { margin: 0 0 6px; font-size: 17px; }
.empty-state p { max-width: 360px; margin: 0 auto 16px; color: var(--muted); font-size: 13px; line-height: 1.5; }

.pantry-layout { display: grid; grid-template-columns: minmax(240px, .8fr) minmax(0, 1.4fr); gap: 20px; align-items: start; }
.pantry-panel { padding: 20px; }
.pantry-panel h2 { margin: 0 0 6px; font-size: 18px; }
.pantry-panel > p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.pantry-count { margin: 15px 0 11px; color: var(--green); font-size: 12px; font-weight: 800; }
.ingredient-list { display: grid; gap: 7px; max-height: 510px; margin-top: 14px; overflow: auto; overscroll-behavior: contain; }
.pantry-ingredient-row { display: flex; align-items: center; gap: 6px; min-width: 0; }
.pantry-ingredient-row .ingredient-check { flex: 1; min-width: 0; }
.pantry-add { flex: 0 0 44px; }
.ingredient-check { display: flex; align-items: center; gap: 11px; min-height: 48px; padding: 7px 11px; border: 1px solid #eceee7; border-radius: 13px; background: #fff; cursor: pointer; }
.ingredient-check:has(input:checked) { border-color: #c5d7bf; background: #f1f6ed; }
.ingredient-check input { width: 20px; height: 20px; margin: 0; accent-color: var(--green); }
.ingredient-check span { min-width: 0; flex: 1; font-size: 13px; }
.ingredient-check small { color: #8b9086; font-size: 10px; }
.suggestions { display: grid; gap: 10px; }
.suggestion-card { padding: 16px; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.suggestion-card h3 { margin: 9px 0 5px; font-size: 17px; }
.suggestion-card p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.suggestion-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.fit-badge { padding: 6px 9px; border-radius: 99px; background: var(--green-pale); color: var(--green); font-size: 10px; font-weight: 800; white-space: nowrap; }
.fit-badge.missing { background: #f3f0e7; color: #82724e; }
.suggestion-action { margin-top: 12px; }
.suggestions-note { margin: 0 0 9px; color: var(--muted); font-size: 12px; }

.shopping-board { max-width: 730px; margin-inline: auto; padding: clamp(19px, 4vw, 29px); }
.shopping-summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.shopping-summary strong { color: var(--green); font-size: 13px; }
.shopping-form { display: flex; gap: 9px; margin: 15px 0 19px; }
.shopping-form input { flex: 1; width: 100%; min-width: 0; min-height: 50px; padding: 10px 14px; border: 1px solid #dfe2d8; border-radius: 13px; background: #fff; }
.shopping-list { display: grid; gap: 8px; list-style: none; margin: 0; padding: 0; }
.shopping-item { display: flex; align-items: center; gap: 10px; min-height: 55px; padding: 7px 8px 7px 12px; border: 1px solid #eceee7; border-radius: 14px; background: #fff; }
.shopping-item input { width: 21px; height: 21px; flex: 0 0 auto; accent-color: var(--green); }
.shopping-item span { flex: 1; min-width: 0; font-size: 14px; }
.shopping-item.is-checked span { color: #92978f; text-decoration: line-through; }
.remove-shopping { width: 44px; height: 44px; min-width: 44px; border: 0; border-radius: 11px; background: transparent; color: #94988f; font-size: 20px; }
.shopping-divider { margin: 18px 0 9px; border: 0; border-top: 1px solid var(--line); }

.sheet-dialog { width: min(620px, calc(100% - 24px)); max-width: 620px; max-height: min(88dvh, 900px); padding: 0; overflow: auto; border: 1px solid #e6e8df; border-radius: 26px; background: var(--paper); color: var(--ink); box-shadow: 0 26px 100px rgb(28 38 28 / 25%); }
.sheet-dialog::backdrop { background: rgb(31 42 33 / 45%); backdrop-filter: blur(3px); }
.dialog-content { padding: clamp(20px, 5vw, 30px); }
.dialog-topline { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 21px clamp(20px, 5vw, 30px) 0; }
.dialog-topline-form { padding: 0 0 19px; }
.dialog-topline h2 { margin: 5px 0 0; font-size: 25px; line-height: 1.1; }
.dialog-close-row { display: flex; justify-content: flex-end; margin: -4px -4px 11px; }
.form-stack { display: grid; gap: 17px; }
.field { display: grid; gap: 7px; }
.field-label { display: block; color: #51594d; font-size: 12px; font-weight: 800; }
.field textarea { min-height: 110px; resize: vertical; line-height: 1.5; }
.field textarea.recipe-field { min-height: 145px; }
.field-help { margin: -2px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.field input[type="file"] { min-height: 48px; padding: 11px; font-size: 12px; }
.media-pending, .media-existing-list { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.media-pending li, .media-existing-item { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px; border-radius: 11px; background: #ecefe6; font-size: 11px; }
.media-pending li span { min-width: 0; flex: 1; overflow-wrap: anywhere; }
.media-pending-remove { width: 44px; height: 44px; min-width: 44px; border: 0; border-radius: 9px; background: #fff; color: var(--red); font-size: 19px; }
.media-existing-item span { min-width: 0; overflow-wrap: anywhere; }
.media-existing-item button { width: 44px; height: 44px; min-width: 44px; border: 0; border-radius: 9px; background: #fff; color: var(--red); font-size: 19px; }
.form-actions { display: flex; justify-content: flex-end; gap: 9px; padding-top: 3px; }
.form-divider { height: 1px; border: 0; background: var(--line); }
.detail-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 13px 0 21px; }
.detail-title { margin: 6px 0 0; font-size: 30px; line-height: 1.1; overflow-wrap: anywhere; }
.detail-stat { padding: 8px 11px; border-radius: 99px; background: #e9ede4; color: #596550; font-size: 11px; font-weight: 700; }
.detail-section { margin-top: 20px; }
.detail-section h3 { margin: 0 0 10px; font-size: 16px; }
.detail-ingredients { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; list-style: none; }
.detail-ingredients li { display: flex; align-items: center; gap: 8px; min-height: 39px; padding: 6px 10px; border: 1px solid #e5e9df; border-radius: 99px; background: #fffefa; font-size: 12px; }
.ingredient-add { width: 44px; height: 44px; min-width: 44px; padding: 0; border: 0; border-radius: 50%; background: var(--green-pale); color: var(--green); font-size: 17px; line-height: 1; }
.recipe-copy { margin: 0; padding: 15px; border-left: 3px solid var(--orange); border-radius: 0 12px 12px 0; background: #fffefa; color: #51574e; font-size: 13px; line-height: 1.65; white-space: pre-wrap; }
.media-gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.media-item { min-width: 0; overflow: hidden; border-radius: 15px; background: #e8ebe3; }
.media-item img, .media-item video { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: contain; background: #ecefe8; }
.media-caption { padding: 8px 10px; margin: 0; color: #666e62; font-size: 10px; overflow-wrap: anywhere; }
.detail-actions { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 21px; }
.detail-actions .button { flex: 1 1 140px; }

.roulette-dialog { max-width: 450px; }
.roulette-form { padding: 20px clamp(20px, 5vw, 30px) 27px; }
.roulette-form select { margin-top: 7px; }
.roulette-stage { min-height: 242px; margin: 19px 0; padding: 19px 15px; border-radius: 22px; background: #e9efe4; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.roulette-plate { width: 118px; height: 118px; display: grid; place-items: center; border: 7px solid #fffefa; border-radius: 50%; background: repeating-conic-gradient(from 12deg, #35573e 0 27deg, #52785a 27deg 53deg, #d8ed91 53deg 58deg); box-shadow: 0 6px 16px rgb(43 62 44 / 15%), inset 0 0 0 2px rgb(255 255 255 / 35%); color: #f7f5e9; font-size: 42px; }
.roulette-plate span { text-shadow: 0 1px 5px rgb(0 0 0 / 20%); }
.roulette-plate.is-spinning { animation: roulette-spin .35s linear infinite; }
@keyframes roulette-spin { to { transform: rotate(1turn); } }
.roulette-result { min-height: 27px; margin: 15px 0 2px; font: 800 19px/1.25 Manrope, sans-serif; }
.roulette-dialog .small-text { margin: 2px 0 0; }

.bottom-nav { position: fixed; z-index: 20; inset-inline: 0; bottom: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 3px; padding: 8px max(12px, env(safe-area-inset-left, 0px)) max(8px, env(safe-area-inset-bottom, 0px)); border-top: 1px solid #e6e8df; background: rgb(255 254 250 / 94%); backdrop-filter: blur(14px); }
.bottom-nav button { min-width: 0; min-height: 58px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 0; border-radius: 14px; background: transparent; color: #81877e; font-size: 10px; font-weight: 700; }
.bottom-nav button[aria-current="page"] { color: var(--green-dark); background: #e9efe4; }
.bottom-nav svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.toast { position: fixed; z-index: 50; inset-inline: 18px; bottom: calc(88px + env(safe-area-inset-bottom, 0px)); width: fit-content; max-width: min(480px, calc(100% - 36px)); margin-inline: auto; padding: 12px 16px; border-radius: 14px; background: #263d2b; color: white; box-shadow: 0 8px 30px rgb(18 28 18 / 20%); font-size: 13px; font-weight: 600; opacity: 0; transform: translateY(9px); pointer-events: none; transition: opacity .18s ease, transform .18s ease; }
.toast.is-visible { opacity: 1; transform: translateY(0); }
.app-footnote { margin: 26px 0 4px; color: #92968d; font-size: 11px; text-align: center; }

@media (max-width: 700px) {
  .topbar { min-height: 67px; padding-inline: 17px; }
  .device-note { padding-inline: 10px; font-size: 10px; }
  .app-main { padding-top: 5px; }
  .hero { min-height: 229px; grid-template-columns: minmax(0, 1fr) 92px; padding: 24px 20px; border-radius: 24px; }
  .hero-art { width: 92px; height: 92px; margin-right: 0; }
  .hero-bowl { font-size: 43px; }
  .hero-spark-one { right: 17px; top: 9px; font-size: 15px; }
  .hero-spark-two { left: 13px; bottom: 16px; font-size: 12px; }
  .hero::before { right: -110px; }
  .hero::after { right: 53px; }
  .menu-grid { grid-template-columns: 1fr; }
  .menu-card { display: grid; grid-template-columns: 104px minmax(0, 1fr); }
  .menu-card-image { grid-column: 1; grid-row: 1; height: 100%; min-height: 168px; }
  .menu-card-body { grid-column: 2; grid-row: 1; padding: 14px 13px; }
  .menu-card h3 { font-size: 16px; }
  .menu-card-top { align-items: flex-start; flex-direction: column; gap: 6px; }
  .menu-card-foot { margin-top: 10px; }
  .pantry-layout { grid-template-columns: 1fr; }
  .ingredient-list { max-height: 290px; }
  .section-head { align-items: flex-start; flex-direction: column; }
  .page-heading { align-items: flex-start; }
  .plan-row { grid-template-columns: minmax(0, .85fr) minmax(0, 1.5fr); }
  .plan-number { grid-column: 1 / -1; }
}
@media (max-width: 470px) {
  .device-note { max-width: 162px; line-height: 1.2; }
  .hero { grid-template-columns: minmax(0, 1fr); }
  .hero-art { position: absolute; width: 100px; height: 100px; right: 14px; top: 15px; opacity: .44; }
  .hero-copy { position: relative; z-index: 1; }
  .hero h1 { max-width: 280px; font-size: 33px; }
  .hero p { max-width: 290px; font-size: 13px; }
  .hero-actions { margin-top: 17px; }
  .hero-actions .button { min-height: 44px; padding-inline: 12px; font-size: 12px; }
  .stats-row { gap: 7px; }
  .stat-card { padding: 13px 10px; border-radius: 15px; }
  .stat-value { font-size: 22px; }
  .stat-label { font-size: 10px; line-height: 1.35; }
  .today-strip { grid-template-columns: 1fr; gap: 11px; }
  .today-meals { justify-content: flex-start; }
  .day-row { grid-template-columns: 70px minmax(0, 1fr) minmax(0, 1fr); gap: 7px; }
  .plan-slot select { font-size: 11px; padding-inline: 7px 23px; }
  .day-label strong { font-size: 11px; }
  .week-today { padding-inline: 8px; }
  .week-range { font-size: 11px; }
  .plan-row { grid-template-columns: minmax(0, 1fr); gap: 9px; }
  .plan-number { grid-column: auto; }
  .weekly-count-field { align-items: flex-start; flex-direction: column; }
  .menu-card { grid-template-columns: 88px minmax(0, 1fr); }
  .menu-card-image { min-height: 170px; }
  .menu-card-body { padding: 12px 10px; }
  .menu-card-ingredients { font-size: 11px; }
  .page-heading { flex-direction: column; gap: 13px; }
  .page-actions { width: 100%; }
  .page-actions .button { flex: 1; }
  .shopping-form { flex-wrap: wrap; }
  .shopping-form input { flex-basis: 100%; }
  .shopping-form button { flex: 1; }
  .detail-actions .button { flex-basis: 100%; }
  .media-gallery { grid-template-columns: 1fr; }
}
@media (pointer: coarse) {
  .bottom-nav button, .week-switch, .icon-button, .remove-shopping { min-block-size: 44px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

