/* Release H: mobile-first live cooking interface */
body.cook-mode-active{overflow:hidden}
.cook-mode-dialog[hidden]{display:none!important}
.cook-mode-dialog{position:fixed;inset:0;z-index:10000;background:rgba(31,18,34,.72);padding:24px;overflow:auto}
.cook-mode-panel{width:min(1180px,100%);min-height:min(760px,calc(100vh - 48px));margin:0 auto;background:#fffaf4;border:1px solid #e4d2c2;border-radius:24px;box-shadow:0 24px 80px rgba(35,20,37,.3);display:grid;grid-template-rows:auto 1fr;overflow:hidden}
.cook-mode-header{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:20px 24px;border-bottom:1px solid #eadbd0;background:#fff}
.cook-mode-title{margin:0;color:#40264b;font-size:clamp(1.5rem,3vw,2.15rem);line-height:1.1}
.cook-mode-exit{width:48px;height:48px;min-width:48px;border:2px solid #5a315f;border-radius:999px;background:#fff;color:#40264b;font:inherit;font-weight:800;cursor:pointer}
.cook-mode-exit:hover,.cook-mode-exit:focus-visible,.cook-mode-dialog button:focus-visible,.cook-mode-dialog summary:focus-visible,.cook-mode-dialog select:focus-visible{outline:3px solid rgba(143,59,98,.3);outline-offset:2px}
.cook-mode-layout{display:grid;grid-template-columns:minmax(250px,330px) minmax(0,1fr);min-height:0}
.cook-mode-layout>*{min-width:0}
.cook-mode-ingredients{padding:24px;border-right:1px solid #eadbd0;background:#fff7ec;overflow:auto;min-width:0}
.cook-mode-ingredients h2{margin:0 0 16px;color:#5a315f;font-size:1.15rem}
.cook-mode-ingredient-list,.cook-mode-step-ingredients ul{list-style:none;margin:0;padding:0;display:grid;gap:10px}
.cook-mode-ingredient-list label,.cook-mode-step-ingredients label{display:grid;grid-template-columns:24px minmax(0,1fr);align-items:start;gap:10px;line-height:1.35;color:#342b36;min-width:0}
.cook-mode-ingredient-list span,.cook-mode-step-ingredients span{overflow-wrap:anywhere}
.cook-mode-ingredient-list input,.cook-mode-step-ingredients input,.cook-mode-step-toggle{width:22px;height:22px;min-width:22px;margin:1px 0 0;accent-color:#8f3b62}
.cook-mode-ingredient-list input:checked+span,.cook-mode-step-ingredients input:checked+span{color:#887b84;text-decoration:line-through}
.cook-mode-main{padding:clamp(22px,4vw,44px);display:grid;align-content:start;gap:22px;min-width:0}
.cook-storage-warning,.cook-recovery-notice{margin:0;padding:12px 14px;border:1px solid #b96e38;border-radius:12px;background:#fff1df;color:#5a351f;font-weight:700}
.cook-recovery-notice{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;border-color:#bba3b8;background:#fff6fb;color:#51354d}
.cook-recovery-notice[hidden]{display:none!important}
[data-cook-recovery-actions]{display:flex;gap:8px;flex-wrap:wrap}
[data-cook-recovery-actions] button{min-height:44px;padding:8px 12px;border:2px solid #5a315f;border-radius:12px;background:#fff;color:#5a315f;font:inherit;font-weight:800}
.cook-section-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;min-width:0}
.cook-live-section,.cook-running-section,.cook-next-section{min-width:0}
.cook-live-section h2,.cook-running-section h2,.cook-next-section h2{margin:0 0 10px;color:#5a315f;font-size:1rem;letter-spacing:.04em;text-transform:uppercase}
.cook-mode-counter{margin:0;color:#77536e;font-size:.9rem;font-weight:800;white-space:nowrap}
.cook-mode-step-ingredients{margin:0 0 16px;padding:14px 16px;border:1px solid #e4d2c2;border-radius:16px;background:#fff7ec}
.cook-mode-step-ingredients[hidden]{display:none!important}
.cook-mode-step-ingredients h3{margin:0 0 12px;color:#5a315f;font-size:1rem;line-height:1.2}
.cook-mode-step{display:block;color:#2e2730;min-width:0}
.cook-mode-step-text{font-size:clamp(1.45rem,3vw,2.45rem);line-height:1.35;font-weight:650;overflow-wrap:anywhere;min-width:0}
.cook-step-state{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:16px}
.cook-step-state button,.cook-step-state label{min-height:44px;display:inline-flex;align-items:center;gap:8px;padding:8px 13px;border:2px solid #cdbac4;border-radius:999px;background:#fff;color:#5a315f;font:inherit;font-weight:800;cursor:pointer}
.cook-step-state button.is-active{border-color:#8f3b62;background:#f8e7ef;color:#6e2449}
.cook-step-state label:has(input:checked){border-color:#547d5d;background:#edf7ee;color:#365c3f}
.cook-suggested-timer,.cook-running-section button,.cook-secondary-actions button,.cook-mode-nav button,.cook-secondary-menu summary{min-height:44px;padding:10px 16px;border:2px solid #5a315f;border-radius:13px;background:#5a315f;color:#fff;font:inherit;font-weight:800;cursor:pointer}
.cook-suggested-timers{display:grid;gap:9px;margin-top:16px;padding:13px;border:1px solid #e4d2c2;border-radius:14px;background:#fff7ec}
.cook-suggested-timers[hidden]{display:none!important}
.cook-suggested-timer-row{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:8px;min-width:0}
.cook-suggested-timer-row>span{font-size:.92rem;color:#5b4b58;overflow-wrap:anywhere}
.cook-suggested-timer-row button{min-height:44px;padding:8px 12px;border:2px solid #8f3b62;border-radius:12px;background:#8f3b62;color:#fff;font:inherit;font-weight:800;white-space:nowrap}
.cook-running-section{padding:18px;border:1px solid #e4d2c2;border-radius:18px;background:#fff}
.cook-timer-form{display:grid;grid-template-columns:minmax(0,1fr) minmax(90px,130px) auto;align-items:end;gap:10px;margin-top:12px;padding:12px;border:1px solid #e4d2c2;border-radius:14px;background:#fffaf4}
.cook-timer-form[hidden]{display:none!important}
.cook-timer-form label,.cook-timer-controls label{display:grid;gap:5px;color:#49384b;font-size:.88rem;font-weight:800;min-width:0}
.cook-timer-form input,.cook-timer-controls input{width:100%;min-width:0;min-height:44px;padding:8px 10px;border:1px solid #cdbac4;border-radius:10px;background:#fff;color:#342b36;font:inherit}
.cook-timer-form>div{display:flex;gap:7px;flex-wrap:wrap}
.cook-timer-form [data-cook-timer-form-cancel]{background:#fff;color:#5a315f}
.cook-primary-timer,.cook-secondary-timers{display:grid;gap:10px;min-width:0}
.cook-primary-timer:empty,.cook-secondary-timers:empty{display:none}
.cook-primary-timer{margin-top:12px}
.cook-secondary-timers{margin-top:10px}
.cook-timer-card{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:14px;padding:12px 14px;border:1px solid #e2d3d7;border-radius:14px;background:#fffaf4;min-width:0}
.cook-timer-card.is-primary{grid-template-columns:1fr;padding:18px;border-width:2px;border-color:#8f3b62;background:#fff5f1}
.cook-timer-card.is-finished{border-color:#b84a4a;background:#fff0ef}
.cook-timer-copy{display:flex;align-items:center;justify-content:space-between;gap:14px;min-width:0}
.cook-timer-copy strong{overflow-wrap:anywhere;min-width:0}
.cook-timer-countdown{font-variant-numeric:tabular-nums;font-size:1.55rem;font-weight:850;color:#40264b;white-space:nowrap}
.cook-timer-card.is-primary .cook-timer-countdown{font-size:clamp(2.6rem,8vw,5rem);line-height:1}
.cook-timer-card.is-finished .cook-timer-countdown{color:#9d3232}
.cook-timer-controls{display:flex;flex-wrap:wrap;gap:8px;min-width:0}
.cook-timer-controls button{min-height:44px;padding:8px 11px;background:#fff;color:#5a315f;font-size:.9rem}
.cook-timer-controls label{flex:1 1 150px}
[data-cook-view-all-timers]{margin-top:10px;background:#fff!important;color:#5a315f!important}
.cook-next-section{padding-top:2px}
.cook-next-section p{margin:0;font-size:1.05rem;line-height:1.45;color:#423642;overflow-wrap:anywhere}
.cook-mode-nav{display:flex;align-items:center;justify-content:space-between;gap:16px}
.cook-mode-nav button{min-width:120px}
.cook-mode-nav button:disabled{background:#e7dedf;color:#81777e;border-color:#cec4c7;cursor:not-allowed}
.cook-secondary-menu{border-top:1px solid #eadbd0;padding-top:12px}
.cook-secondary-menu summary{display:inline-flex;align-items:center;background:#fff;color:#5a315f;list-style:none}
.cook-secondary-menu summary::-webkit-details-marker{display:none}
.cook-secondary-actions{display:flex;flex-wrap:wrap;align-items:end;gap:12px;margin-top:12px}
.cook-secondary-actions label{display:grid;gap:6px;font-weight:700;color:#49384b}
.cook-secondary-actions select{min-height:44px;max-width:100%;padding:8px 10px;border:1px solid #cdbac4;border-radius:10px;background:#fff;color:#342b36;font:inherit}
.cook-secondary-actions [data-cook-end-session]{background:#fff;color:#8a3030;border-color:#a64b4b}
.cook-alert-live{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.cook-mode-dialog input:focus-visible{outline:3px solid rgba(143,59,98,.35);outline-offset:3px}

@media(max-width:1050px){
  .cook-timer-card,.cook-timer-card.is-primary{grid-template-columns:1fr}
  .cook-timer-form{grid-template-columns:minmax(0,1fr) 110px}
  .cook-timer-form>div{grid-column:1/-1}
}

@media(max-width:760px){
  .cook-mode-dialog{padding:0;background:#fffaf4}
  .cook-mode-panel{min-height:100dvh;border:0;border-radius:0;box-shadow:none;overflow:visible}
  .cook-mode-header{padding:14px 16px;position:sticky;top:0;z-index:3}
  .cook-mode-exit{width:44px;height:44px;min-width:44px}
  .cook-mode-layout{display:flex;flex-direction:column;min-width:0}
  .cook-mode-main{order:1;padding:18px 16px;gap:18px;min-width:0}
  .cook-mode-ingredients{order:2;border-right:0;border-top:1px solid #eadbd0;padding:16px;max-height:none;min-width:0}
  .cook-mode-step-text{font-size:clamp(1.35rem,6.5vw,2rem)}
  .cook-mode-nav{position:sticky;bottom:0;z-index:2;background:#fffaf4;padding:10px 0 2px;gap:10px}
  .cook-mode-nav button{min-width:0;flex:1}
  .cook-timer-card,.cook-timer-card.is-primary{grid-template-columns:1fr;min-width:0}
  .cook-timer-controls{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));min-width:0}
  .cook-timer-controls label{grid-column:1/-1}
  .cook-timer-controls button{min-width:0;white-space:normal;overflow-wrap:anywhere}
  .cook-section-heading{align-items:flex-start}
  .cook-timer-form{grid-template-columns:1fr 110px}
  .cook-timer-form>div{grid-column:1/-1}
}

@media(max-width:390px){
  .cook-mode-main{padding:14px 12px;gap:16px}
  .cook-mode-header{padding:10px 12px}
  .cook-running-section{padding:14px 10px}
  .cook-mode-step-text{font-size:1.35rem}
  .cook-step-state{display:grid;grid-template-columns:1fr 1fr}
  .cook-step-state label{grid-column:1/-1}
  .cook-suggested-timer-row{grid-template-columns:1fr}
  .cook-suggested-timer-row button{width:100%;white-space:normal}
  .cook-timer-copy{align-items:flex-start;flex-direction:column;gap:6px}
  .cook-timer-card.is-primary .cook-timer-countdown{font-size:2.7rem}
  .cook-timer-controls{grid-template-columns:1fr 1fr}
  .cook-timer-form{grid-template-columns:1fr}
  .cook-timer-form>div{grid-column:1}
  .cook-secondary-actions{display:grid;grid-template-columns:1fr;align-items:stretch}
  .cook-secondary-actions select,.cook-secondary-actions button{width:100%;min-width:0}
  .cook-mode-nav{gap:8px}
}

@media print{.cook-mode-dialog{display:none!important}}