.dinner-surface{padding:1.15rem;border:1px solid var(--line,#d5e3e2);border-radius:16px;background:var(--card,#fffefa);margin:1rem 0 1.5rem}
.dinner-field-row{display:flex;gap:.7rem;align-items:center;flex-wrap:wrap}.dinner-field-row>label:not(.check){flex:1;min-width:110px}.dinner-field-row select{width:100%;min-height:44px;margin-top:.35rem}.dinner-field-row>.check{display:flex;align-items:center;gap:.4rem;min-height:44px}.dinner-field-row input[type=checkbox]{width:22px;height:22px}
.dinner-actions{display:flex;gap:.75rem;flex-wrap:wrap;margin-top:.8rem}.dinner-option{border-top:1px solid var(--line,#d5e3e2);padding:1.2rem 0}.dinner-option h3{font-size:1.35rem;line-height:1.5;margin:.4rem 0}.dinner-option details{margin:.8rem 0}.dinner-option summary,.saved-picks summary,#stock-tools summary{min-height:44px;cursor:pointer;display:flex;align-items:center;color:#276d7d}.dinner-empty{padding:1rem 0}.dinner-empty strong{font-size:1.1rem}
.quick-stock{display:flex;flex-wrap:wrap;gap:.5rem;margin:.7rem 0}.quick-stock button{font-size:1rem;padding:.55rem .8rem;min-height:44px}
.stock-status-actions{display:flex;gap:.5rem;flex-wrap:wrap;padding:.6rem 0}.stock-status-actions button{min-height:44px;border:1px solid #cfe0df;border-radius:12px;padding:.5rem .8rem;background:#eff6f5;color:#276d7d}.stock-status-actions button[aria-pressed=true]{background:#d8ece7;border-color:#4eae7d}.stock-basis{font-size:.9rem;color:#697f88;margin:.45rem 0}.step-controls{display:flex;align-items:center;justify-content:space-between;gap:.5rem;position:sticky;bottom:0;background:#fbfaf6;padding:.6rem 0}.step-controls button{min-height:44px}.current-step{outline:2px solid #91bfc7;outline-offset:6px;border-radius:6px}.shopping-tools{display:flex;gap:.5rem;flex-wrap:wrap;margin:.6rem 0}.shopping-tools input{flex:1;min-width:140px}
button,input,select{touch-action:manipulation}button:focus-visible,summary:focus-visible,input:focus-visible,select:focus-visible{outline:3px solid #287787;outline-offset:3px}.dialog-card{max-height:85dvh;overflow-y:auto}.dialog-card label{font-size:1rem}
@media(max-width:480px){.home-heading h1{font-size:2rem}.dinner-surface{padding:1rem}.dinner-field-row{gap:.5rem}.dinner-field-row>label:not(.check){min-width:95px;font-size:.9rem}.dinner-actions>button{flex:1}.stock-row{display:flex;flex-wrap:wrap!important}.stock-row input:first-child{flex-basis:100%}.stock-row .qty-input{width:calc(45% - .5rem)}.stock-row select{min-width:70px}.dinner-option .solid-button{width:100%}.dialog-card{padding-bottom:calc(1.25rem + env(safe-area-inset-bottom))}}
.status-buttons{display:flex;gap:.5rem;flex-wrap:wrap;padding:.6rem 0}.status-buttons button{min-height:44px;border:1px solid #cfe0df;border-radius:12px;padding:.5rem .8rem;background:#eff6f5;color:#276d7d}.cook-step-controls{display:flex;align-items:center;justify-content:space-between;gap:.5rem;position:sticky;bottom:0;background:#fbfaf6;padding:.6rem 0}.cook-step-controls button{min-height:44px}
.pantry-picker .quick-stock{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.5rem}.pantry-picker .check{display:flex;align-items:center;gap:.4rem;min-height:44px;font-size:.95rem}.pantry-picker input[type=checkbox]{width:22px;height:22px;flex-shrink:0}
/* Photo entry is a separate, list-first flow. All layout rules stay scoped. */
.inventory-add-actions{display:flex;align-items:center;gap:18px;flex-shrink:0}
#inventory-photo-add{display:inline-flex;align-items:center;justify-content:center;gap:9px;min-height:48px;margin:0;background:var(--blue-deep);box-shadow:none;white-space:nowrap}
.inventory-add-actions .text-button{min-height:44px;font-size:15px;font-weight:500;white-space:nowrap}
#photo-dialog{width:min(540px,calc(100% - 24px));max-width:none;max-height:none;overflow:hidden;background:var(--card);border-radius:20px}
#photo-dialog [hidden]{display:none!important}
#photo-dialog .photo-dialog-card{display:flex;flex-direction:column;padding:0;height:min(760px,calc(var(--photo-vh,100dvh) - 24px));max-height:calc(var(--photo-vh,100dvh) - 24px);overflow:hidden}
.photo-header{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-shrink:0;padding:10px 16px 10px 22px;border-bottom:1px solid var(--line);background:var(--card)}
#photo-dialog .photo-header h2{font-size:20px;font-weight:690;letter-spacing:0;line-height:1.4}
.photo-close{display:grid;place-items:center;flex:0 0 44px;width:44px;height:44px;border:0;border-radius:50%;background:transparent;color:var(--muted);font-size:30px;line-height:1}
.photo-body{flex:1;min-height:0;overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;padding:18px 22px 22px;scroll-padding-block:16px 28px}
.photo-kind-switch{display:grid;grid-template-columns:1.3fr 1fr 1fr;gap:4px;padding:4px;border-radius:11px;background:#e9efed;margin-bottom:18px}
.photo-kind-switch button{min-width:0;min-height:40px;border:0;border-radius:8px;color:#647780;background:transparent;padding:8px 6px;font-size:15px;font-weight:600}
.photo-kind-switch button[aria-pressed=true]{background:var(--card);color:var(--blue-deep);box-shadow:0 1px 3px rgba(40,67,70,.08)}
.photo-picker{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin:16px 0}
.photo-picker button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;min-width:0;min-height:112px;font-size:16px;border-radius:12px;background:transparent}
.photo-preview{display:flex;align-items:center;gap:16px;min-width:0;margin:16px 0}
.photo-preview img{display:block;max-width:min(210px,70%);width:auto;height:132px;object-fit:contain;border-radius:9px;background:#ebefec}
.photo-preview .text-button{min-height:44px;flex-shrink:0;padding:8px}
.photo-privacy{color:#667983;font-size:14px;line-height:1.5;margin:12px 0}
.photo-privacy summary{display:flex;justify-content:space-between;align-items:center;gap:8px;min-height:44px;cursor:pointer;list-style:none}
.photo-privacy summary::-webkit-details-marker{display:none}
.photo-privacy summary span{flex-shrink:0;color:var(--blue-deep);font-weight:550}
.photo-privacy p{margin:6px 0 12px;font-size:14px;line-height:1.65}
#photo-dialog .solid-button{background:var(--blue-deep);box-shadow:none;font-size:16px;min-height:48px}
#photo-recognize{width:100%;margin:4px 0 12px}
#photo-status{font-size:14px;line-height:1.55;margin:10px 0 12px;overflow-wrap:anywhere}
#photo-status:empty{display:none}
#photo-recover{min-height:44px;font-size:15px;margin-bottom:8px}
.photo-results-heading,.photo-list-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:18px 0 4px;font-size:17px;font-weight:650}
.photo-results-heading p,.photo-list-heading p{margin:0}
.photo-result{border:0;border-bottom:1px solid var(--line);border-radius:0;background:transparent;padding:0;margin:0;min-width:0}
.photo-result:first-child{border-top:1px solid var(--line)}
.photo-row{display:grid;grid-template-columns:36px minmax(0,1fr);gap:4px;align-items:center;min-width:0}
#photo-dialog .photo-row>.check,#photo-dialog .photo-row>label{display:flex;align-items:center;justify-content:center;margin:0;min-height:56px;min-width:36px;padding:0}
.photo-row input[type=checkbox]{width:22px;height:22px;margin:0;accent-color:var(--blue-deep);cursor:pointer}
.photo-row-toggle{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"name quantity" "location quantity";column-gap:12px;row-gap:4px;align-items:center;width:100%;min-width:0;min-height:82px;padding:14px 0 14px 4px;border:0;background:transparent;text-align:left;color:var(--ink)}
.photo-row-name{grid-area:name;min-width:0;font-size:16px;line-height:1.4;font-weight:620;overflow-wrap:anywhere}
.photo-row-quantity{grid-area:quantity;max-width:125px;min-width:0;text-align:right;font-size:16px;line-height:1.4;font-weight:550;overflow-wrap:anywhere}
.photo-row-quantity small,.photo-row-quantity .photo-estimate{display:block;margin-top:2px;font-size:14px;font-weight:400;color:var(--muted)}
.photo-row-location{grid-area:location;font-size:14px;font-weight:400;line-height:1.4;color:var(--muted);overflow-wrap:anywhere}
.photo-result.is-excluded .photo-row-name,.photo-result.is-excluded .photo-row-quantity{color:var(--muted)}
body:has(#photo-dialog[open]){overflow:hidden}
.photo-edit-fields{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;padding:4px 0 18px 40px;min-width:0}
#photo-dialog .photo-edit-fields>label{display:grid;gap:6px;margin:0;min-width:0;color:#647780;font-size:14px}
.photo-edit-fields>.photo-edit-name,.photo-edit-fields>.photo-edit-location,.photo-edit-fields>.photo-edit-note{grid-column:1/-1}
#photo-dialog .photo-edit-fields input,#photo-dialog .photo-edit-fields select{min-width:0;max-width:100%;width:100%;font-size:16px;min-height:46px;padding:10px 11px;margin:0;background:#fbfcf9}
.photo-edit-note{font-size:14px;color:var(--muted);line-height:1.5;margin:0}
.photo-purchase-confirm{margin:12px 0;padding:12px 14px;border-radius:12px;background:#edf3ef;border:1px solid var(--line)}
#photo-dialog .photo-purchase-confirm>.check{display:flex;align-items:center;gap:10px;min-height:44px;margin:0;font-size:16px;font-weight:600}
.photo-purchase-confirm input[type=checkbox]{width:22px;height:22px;flex:0 0 22px;margin:0;accent-color:var(--blue-deep)}
.photo-purchase-confirm .photo-edit-note{margin-top:3px}
.photo-edit-fields>.photo-edit-packages{grid-column:1/-1}
.photo-edit-packages small{font-size:14px;line-height:1.5;color:var(--muted)}
.photo-row-quantity small:empty{display:none}
.photo-fields{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr);gap:10px;min-width:0}
.photo-quantity{display:flex;align-items:center;gap:5px;min-width:0}
.photo-approx{color:var(--blue-deep);font-weight:600;flex-shrink:0}
.photo-footer{position:relative;flex-shrink:0;padding:12px 22px calc(12px + env(safe-area-inset-bottom));border-top:1px solid var(--line);background:var(--card);z-index:1}
#photo-confirm{display:block;position:static;width:100%;min-height:50px;margin:0}
.photo-success{padding:48px 0;text-align:center}
.photo-success-check{display:grid;place-items:center;width:52px;height:52px;margin:0 auto 18px;border-radius:50%;background:#e5f2ec;color:#357e65;font-size:27px}
.photo-success h3{font-size:21px;letter-spacing:0}
#photo-save-state{font-size:14px;line-height:1.6;margin:12px 0}
#photo-next{width:100%;margin-top:22px}
@media(max-width:600px){.inventory-add-actions{margin-top:18px}.inventory-heading{margin-bottom:24px}}
@media(max-width:540px){
 #photo-dialog{position:fixed;inset:var(--photo-top,0px) 0 auto;margin:0;width:100%;border:0;border-radius:0}
 #photo-dialog .photo-dialog-card{height:var(--photo-vh,100dvh);max-height:var(--photo-vh,100dvh)}
 .photo-header{padding:calc(8px + env(safe-area-inset-top)) 12px 8px 18px}
 .photo-body{padding:16px 18px 22px}
 .photo-footer{padding:12px 18px calc(12px + env(safe-area-inset-bottom))}
}
@media(max-width:359px){.photo-body{padding-left:14px;padding-right:14px}.photo-header{padding-left:14px}.photo-footer{padding-left:14px;padding-right:14px}.photo-row-quantity{max-width:92px}.photo-edit-fields{padding-left:0}.photo-row-toggle{column-gap:8px}.photo-picker{gap:8px}}
