/* Full-screen recipe and meal-plan readers, available only through owner-gated APIs. */
html dialog.recipes-dialog { box-sizing:border-box; position:fixed; inset:0; margin:0; width:100%; max-width:none; height:100dvh; max-height:100dvh; padding:calc(env(safe-area-inset-top,0px) + 16px) max(22px,env(safe-area-inset-right,0px)) calc(env(safe-area-inset-bottom,0px) + 32px) max(22px,env(safe-area-inset-left,0px)); border:0; border-radius:0; background:#fafaf8; color:#1c1c20; overflow-y:auto; overflow-x:hidden; overscroll-behavior:contain; touch-action:pan-y; font-family:Inter,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
html dialog.recipes-dialog *, .nutrition-studio * { box-sizing:border-box; min-width:0; max-width:100%; overflow-wrap:anywhere; }
html:has(.recipes-dialog[open]),body:has(.recipes-dialog[open]) { overflow:hidden; }
.recipes-dialog::backdrop { background:#fafaf8; }
html .recipes-dialog h2 { font-family:inherit; font-size:28px; font-weight:700; letter-spacing:-.8px; line-height:1.15; margin:22px 0 12px; }
html .recipes-dialog h3 { font-family:inherit; font-size:18px; font-weight:650; margin:26px 0 10px; }
.recipes-dialog p,.recipes-dialog li { font-size:15px; line-height:1.6; }
.recipes-dialog li { padding:5px 0; }.recipes-dialog ul,.recipes-dialog ol { padding-left:22px; }
.recipes-dialog input,.recipes-dialog select { display:block; box-sizing:border-box; width:100%; min-height:50px; padding:12px 14px; margin:8px 0 14px; border:1px solid #dedee2; border-radius:14px; background:#fff; color:#1c1c20; font:inherit; font-size:16px; }
.recipes-dialog label { display:block; margin-top:16px; font-size:13px; font-weight:600; color:#62626a; }
.recipes-list { display:grid; gap:12px; margin-top:20px; }
html .recipes-item { position:relative; width:100%; text-align:left; border:1px solid #e7e7e9; border-radius:18px; background:#fff; color:#1c1c20; padding:19px 35px 19px 18px; min-height:82px; box-shadow:0 2px 8px #00000003; }
.recipes-item::after { content:'›'; position:absolute; right:16px; top:calc(50% - 15px); color:#96969c; font-size:24px; }
.recipes-item strong,.recipes-item span { display:block; line-height:1.4; }
.recipes-item strong { font-size:16px; font-weight:650; }.recipes-item span { font-size:13px; color:#72727a; margin-top:7px; }
.recipes-quick { display:flex; gap:8px; }.recipes-quick button { flex:1; min-height:44px; }
html .recipes-dialog .primary-btn { width:100%; min-height:52px; padding:14px 18px; border:0; border-radius:28px; background:#1c1c20; color:#fff; font:inherit; font-weight:650; }
html .recipes-dialog .secondary-btn { min-height:44px; padding:10px 15px; border:1px solid #e0e0e4; border-radius:24px; background:#fff; color:#1c1c20; font:inherit; font-weight:600; }
.recipes-macros { font-weight:600; padding:16px; background:#eeeef0; border-radius:14px; }
.recipes-status { padding:8px 0; }.recipes-dialog button:disabled { opacity:.55; }
.recipes-toolbar { position:sticky; top:calc(-16px - env(safe-area-inset-top,0px)); z-index:2; display:flex; justify-content:space-between; align-items:center; gap:12px; padding:12px 0; background:#fafaf8; }
.recipes-toolbar .recipes-close { margin-left:auto; }
.recipes-log-panel { margin-top:32px; padding-top:8px; border-top:1px solid #dedee2; }
.recipes-log-panel > h3 { font-size:22px; }
.nutrition-studio { padding:10px 0 24px; }
html .nutrition-studio h2 { font-family:inherit; font-size:30px; letter-spacing:-.8px; margin:0 0 10px; }
.nutrition-studio > p { color:#777780; font-size:15px; line-height:1.5; margin:0 0 24px; }
html #open-leanr-recipes,html #build-custom-meal-plan { width:100%; min-height:58px; border-radius:32px; font:inherit; font-size:16px; font-weight:650; padding:17px 20px; margin:0 0 12px; background:#1c1c20; color:#fff; border:1px solid #1c1c20; }
html #build-custom-meal-plan { background:#fff; color:#1c1c20; border-color:#dedee2; }
.nutrition-saved-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-top:28px; }
.nutrition-saved-heading h3 { margin:0; font-size:19px; }
html #open-meal-plans { background:none; border:0; color:#777780; padding:10px 0 10px 12px; font-size:13px; }
.nutrition-saved-list { display:grid; gap:10px; margin-top:12px; }
.nutrition-saved-empty { color:#777780; font-size:14px; line-height:1.6; }
/* Recipes-first preview retains existing nutrition tools until the planner launches. */
#screen-nutrition.nutrition-owner-preview #build-custom-meal-plan,
#screen-nutrition.nutrition-owner-preview #saved-meal-plans-section:has(.nutrition-saved-empty) { display:none!important; }
html .recipes-dialog .recipe-track-shortcut { margin:4px 0 8px; }
.recipe-track-hint { color:#72727a; font-size:13px!important; margin:0 0 18px; }
.meal-plan-meal { border-top:1px solid #e5e5e5; margin-top:24px; padding-top:8px; }
html .recipes-dialog .meal-plan-delete { margin-top:28px; color:#b73333; }
@media(min-width:760px) { html dialog.recipes-dialog { padding-left:max(32px,calc((100vw - 680px)/2)); padding-right:max(32px,calc((100vw - 680px)/2)); } }

html dialog.recipes-confirm { width:calc(100% - 40px); max-width:380px; border:0; border-radius:24px; padding:24px; font-family:Inter,-apple-system,sans-serif; color:#1c1c20; background:#fff; }
.recipes-confirm::backdrop { background:#0007; }.recipes-confirm h3{margin:0 0 12px;font-family:inherit}.recipes-confirm p{line-height:1.6;color:#666}.recipes-confirm button { min-height:46px; border:0; border-radius:24px; padding:12px 18px;margin-right:8px;font:inherit;font-weight:600; }.recipes-confirm .meal-plan-delete{background:#bb3535;color:white;}
html .nutrition-saved-heading h3 { font-family:inherit; font-weight:650; letter-spacing:-.3px; }
html #screen-nutrition.nutrition-owner-preview > .macro-history-card { background:#fff; border:1px solid #e7e7e9; border-radius:18px; box-shadow:none; }

/* Owner-only feature-card preview. API capability controls the parent class. */
.nutrition-history-summary { display:none; }
html #screen-nutrition.nutrition-owner-preview .nutrition-studio { padding:0; }
html #screen-nutrition.nutrition-owner-preview .nutrition-studio > p { margin:0 0 24px; }
html #screen-nutrition.nutrition-owner-preview .nutrition-feature { position:relative; display:block; overflow:hidden; isolation:isolate; width:100%; min-height:220px; padding:24px 20px; border-radius:24px; margin:0 0 16px; text-align:left; border:1px solid #e8e6e4; }
html #screen-nutrition.nutrition-owner-preview .nutrition-feature[hidden] { display:none; }
html #screen-nutrition.nutrition-owner-preview .nutrition-feature-recipes { background:#20201e url('/client-app/assets/recipe-book-hero.jpg') center/cover; color:white; border:0; }
.nutrition-feature-recipes::before { content:''; position:absolute; inset:0; z-index:-1; background:linear-gradient(90deg,#181818f0 0%,#181818cf 35%,#18181840 70%,transparent); }
.nutrition-feature-copy { display:block; position:relative; z-index:1; width:64%; }
.nutrition-feature-brand { display:block; color:#ee762d; font-size:12px; font-weight:750; letter-spacing:1px; margin-bottom:6px; }
.nutrition-feature-copy strong { display:block; font-size:25px; line-height:1.12; letter-spacing:-.8px; font-weight:750; }
.nutrition-feature-recipes .nutrition-feature-copy strong { font-family:Georgia,serif; font-size:32px; letter-spacing:-.6px; }
.nutrition-feature-description { display:block; font-size:13px; font-weight:400; line-height:1.45; margin:12px 0 18px; color:#6d6d73; }
.nutrition-feature-recipes .nutrition-feature-description { color:#e0dedb; max-width:195px; }
.nutrition-feature-action { display:inline-flex; align-items:center; gap:15px; background:#1c1c20; color:#fff; border-radius:30px; padding:12px 16px; font-size:13px; line-height:1.2; font-weight:700; white-space:nowrap; }
.nutrition-feature-action > span { font-size:23px; line-height:14px; }
.nutrition-feature-recipes .nutrition-feature-action { background:#fff; color:#1c1c20; }
html #screen-nutrition.nutrition-owner-preview .nutrition-feature-planner { background:linear-gradient(120deg,#fff,#f4f1ee); color:#1c1c20; }
.nutrition-feature-planner .nutrition-feature-copy { width:59%; }
.nutrition-plan-art { position:absolute; width:46%; right:-8px; top:34px; bottom:-22px; border:5px solid #e8e5e2; border-radius:30px; transform:rotate(-7deg); padding:24px 9px; display:flex; flex-direction:column; gap:10px; background:#ffffff45; }
.nutrition-plan-art > span { display:flex; align-items:center; gap:7px; color:#d9611c; background:#fff; border-radius:10px; padding:12px 8px; box-shadow:0 5px 10px #29201b0c; font-size:17px; }
.nutrition-plan-art b { color:#343438; font-size:9px; font-weight:600; line-height:1.3; }
html .nutrition-owner-preview .nutrition-saved-heading { margin-top:26px; }
html .nutrition-owner-preview .nutrition-saved-list .recipes-item { padding-left:64px; min-height:76px; }
.nutrition-owner-preview .nutrition-saved-list .recipes-item::before { content:'◇'; position:absolute; left:14px; top:calc(50% - 21px); width:38px; height:42px; border-radius:12px; background:#f3f2f0; display:grid; place-items:center; font-size:30px; color:#242428; }
html #screen-nutrition.nutrition-owner-preview > .macro-history-card { padding:0; margin-top:24px; }
.nutrition-owner-preview .nutrition-history-summary { display:flex; align-items:center; gap:12px; padding:18px 16px; cursor:pointer; list-style:none; }
.nutrition-history-summary::-webkit-details-marker { display:none; }
.nutrition-history-icon { display:grid; place-items:center; width:38px; height:42px; background:#f3f2f0; border-radius:12px; font-size:28px; }
.nutrition-history-summary strong { display:block; font-size:16px; }
.nutrition-history-summary span > span { display:block; font-size:12px; color:#777780; margin-top:4px; }
.nutrition-history-chevron { margin-left:auto; font-size:26px; color:#85858b; }
.nutrition-owner-preview .macro-history-card[open] .nutrition-history-chevron { transform:rotate(90deg); }
.nutrition-owner-preview .macro-history-card > .home-section-title { display:none; }
.nutrition-owner-preview .macro-history-list { padding:0 14px 14px; }
.nutrition-feature:focus-visible,.nutrition-history-summary:focus-visible { outline:3px solid #d9611c; outline-offset:4px; }
@media(max-width:360px) { .nutrition-feature-copy strong { font-size:22px; }.nutrition-feature-recipes .nutrition-feature-copy strong {font-size:28px}.nutrition-feature-description { font-size:12px; }.nutrition-plan-art {right:-20px;width:44%;opacity:.75}.nutrition-feature-planner .nutrition-feature-copy {width:65%;}.nutrition-feature-action{padding:12px;font-size:12px;gap:8px} }

.recipe-prep-actions { display:flex; gap:10px; margin:12px 0 20px; }
.recipe-prep-actions button { flex:1; }
.recipe-bulk-panel { padding:18px; background:#fff; border:1px solid #e7e7e9; border-radius:20px; margin:16px 0; }
.recipe-bulk-panel[hidden] { display:none; }
.recipe-prep-note { padding:14px; border-left:3px solid #d9611c; background:#f5f2ee; border-radius:8px; }
.recipe-shopping-row { display:flex; align-items:center; gap:12px; padding:14px 0; border-bottom:1px solid #e7e7e9; }
.recipe-shopping-row span { flex:1; font-size:14px; }
.recipe-shopping-row button { flex:none; font-size:13px!important; }
