/* Cooking Mode and setup */
.br-cooking-customization-prompt{display:flex;align-items:center;justify-content:space-between;gap:1rem;margin:1rem 0;padding:1rem 1.2rem;border:1px solid #c8cfb7;border-radius:16px;background:#f2f1e6;color:#28372c}
.br-cooking-customization-prompt{box-sizing:border-box;width:100%;max-width:100%;grid-column:1/-1}
.br-cooking-customization-prompt p{margin:0;font-weight:600;flex:1 1 auto;min-width:0}
.br-cooking-customization-prompt>div{display:flex;gap:.55rem;flex-wrap:wrap}
.br-cooking-customization-prompt button,.br-cooking-customize,.br-step-cooking-launch{border:1px solid #52694f;border-radius:999px;padding:.68rem 1rem;background:#365444;color:#fff;font:inherit;font-weight:600;cursor:pointer}
.br-cooking-customization-prompt button.br-cooking-not-now{background:transparent;color:inherit}
.br-cooking-customize{margin:.45rem}
.br-step-cooking-launch{display:block;margin:1rem 0}
.br-cooking-editor-shade,.br-cooking-mode-shade{position:fixed;inset:0;z-index:10050;display:grid;place-items:center;padding:clamp(12px,3vw,32px);background:rgba(16,24,19,.74);overscroll-behavior:contain}
.br-cooking-editor,.br-cooking-mode{box-sizing:border-box;width:min(760px,100%);border:1px solid #d1d0bd;border-radius:22px;background:#faf7ef;color:#27362c;box-shadow:0 24px 80px #0005;padding:clamp(18px,4vw,34px)}
.br-cooking-editor{max-height:min(92dvh,980px);overflow:auto}
.br-cooking-mode{height:auto;max-height:min(92dvh,980px);display:flex;flex-direction:column;gap:.75rem;overflow:hidden}
.br-cooking-editor-top,.br-cooking-mode-header{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}
.br-cooking-mode-header{flex:0 0 auto;align-items:flex-start;width:100%;margin:0;padding:0;background:transparent;color:inherit}
.br-cooking-mode-header>div{display:flex;flex-direction:column;align-items:flex-start;gap:.1rem;min-width:0}
.br-cooking-mode-header>div>p.small.muted{margin:0;font-size:.95rem;line-height:1.2}
.br-cooking-editor h2,.br-cooking-mode h2{margin:.1rem 0}
.br-cooking-mode h2#br-cooking-title{font-size:clamp(1.45rem,3vw,2rem);line-height:1.12}
.br-cooking-close{flex:0 0 auto;width:42px;height:42px;border:1px solid currentColor;border-radius:50%;background:transparent;color:inherit;font-size:1.8rem;line-height:1;cursor:pointer}
.br-cooking-progress,.br-cooking-step-progress{color:#365444}
.br-cooking-main{flex:0 1 auto;min-height:0;overflow-y:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
.br-cooking-step-progress{display:inline-flex;width:max-content;max-width:100%;margin:.15rem 0 .6rem;padding:.35rem .75rem;border:1px solid #9eae9e;border-radius:999px;background:#e7ece3;color:#365444;font-family:inherit;font-size:1rem;font-weight:700;line-height:1.2}
.br-cooking-instruction{margin:1.2rem 0;padding:1.1rem 1.2rem;border-left:4px solid #6e805e;border-radius:0 12px 12px 0;background:#f0eee2;font-family:Georgia,serif;font-size:1.2rem;line-height:1.55;white-space:pre-wrap}
.br-cooking-step-instruction{margin:.25rem 0 .8rem;font-family:Georgia,serif;font-size:clamp(1.6rem,3vw,2.15rem);line-height:1.32;white-space:pre-wrap}
.br-cooking-ingredient-choices{margin:1rem 0;padding:0;border:0}
.br-cooking-ingredient-choices legend,.br-cooking-step-ingredients h3{margin:0 0 .55rem;font-size:clamp(1.2rem,2vw,1.5rem);font-weight:700}
.br-cooking-step-ingredients{padding-top:.35rem}
.br-cooking-checklist,.br-cooking-step-list{display:grid;gap:.4rem}
.br-cooking-checklist label,.br-cooking-step-list label{display:flex;align-items:flex-start;gap:.7rem;padding:.7rem .8rem;border:1px solid #d8d6c8;border-radius:12px;background:#fffdf7;line-height:1.4}
.br-cooking-checklist input,.br-cooking-step-list input{width:1.15rem;height:1.15rem;flex:0 0 auto;margin:.12rem 0 0;accent-color:#365444}
.br-cooking-editor-actions,.br-cooking-mode-footer{display:flex;justify-content:space-between;gap:.8rem}
.br-cooking-editor-actions{margin-top:1.35rem}
.br-cooking-mode-footer{display:flex;flex:0 0 auto;width:100%;max-width:none;align-self:stretch;box-sizing:border-box;justify-content:space-between;flex-wrap:nowrap;margin:0!important;padding:.55rem 0 0!important;border:0!important;font-size:inherit;color:inherit}
.br-cooking-mode-footer button{box-sizing:border-box;min-width:120px;min-height:48px;padding:.65rem 1rem;border:1px solid #819687;border-radius:12px;background:#e9ede4;color:#28372c;font:inherit;font-weight:600}
.br-cooking-mode-footer .br-cooking-prev{background:transparent;color:inherit}
.br-cooking-mode-footer .br-cooking-next,.br-cooking-editor-actions .br-cooking-next{background:#365444;color:#fff}
.br-cooking-open{overflow:hidden}
.br-cooking-customize[hidden],#cooking-mode[hidden]{display:none!important}
.br-editor-cooking-settings{margin:.85rem 0 1rem;padding:.9rem 1.1rem;border:1px solid #c8cfb7;border-radius:16px;background:#f2f1e6;color:#28372c}
.br-editor-cooking-settings>summary{cursor:pointer;font-weight:700;list-style-position:inside}
.br-editor-cooking-content{padding:.25rem .15rem 0}
.br-editor-cooking-content p{margin:.35rem 0 .8rem}
.br-editor-cooking-settings .br-cooking-customize{margin:.1rem 0}
.br-editor-cooking-status{min-height:1.4em;color:#52694f}
@media(max-width:600px){
 .br-cooking-customization-prompt{align-items:stretch;flex-direction:column}
 .br-cooking-customization-prompt>div{display:grid;grid-template-columns:1fr 1fr}
 .br-cooking-editor-shade,.br-cooking-mode-shade{align-items:stretch;padding:0;background:#faf7ef}
 .br-cooking-mode-shade{align-items:stretch}
 .br-cooking-editor,.br-cooking-mode{width:100%;height:100dvh;max-height:100dvh;border:0;border-radius:0;padding:calc(14px + env(safe-area-inset-top)) 14px calc(14px + env(safe-area-inset-bottom));box-shadow:none}
 .br-cooking-editor{overflow:auto}
 .br-cooking-mode{height:100dvh;max-height:100dvh;align-self:stretch;gap:.55rem}
 .br-cooking-main{flex:1 1 0;max-height:none}
 html[data-theme=dark] .br-cooking-mode-shade{background:#1e2e24}
 .br-cooking-mode-header{position:relative;padding-right:44px;gap:.4rem}.br-cooking-mode-header>div{width:100%;flex:1 1 auto}
 .br-cooking-mode-header>div>p.small.muted{font-size:.92rem}
 .br-cooking-mode h2#br-cooking-title{font-size:clamp(1.45rem,5vw,1.8rem);line-height:1.08}
 .br-cooking-mode .br-cooking-close{position:absolute;top:0;right:0;display:grid;place-items:center;box-sizing:border-box;width:38px;height:38px;min-width:38px;min-height:38px;max-width:38px;max-height:38px;padding:0;font-size:1.35rem}
 .br-cooking-step-progress{margin:.1rem 0 .45rem;font-size:1.05rem}
 .br-cooking-step-instruction{font-size:clamp(1.6rem,6vw,2rem);line-height:1.25}
 .br-cooking-step-ingredients h3{margin-bottom:.4rem;font-size:1.3rem}
 .br-cooking-step-list{gap:.35rem}
 .br-cooking-step-list label{min-height:46px;align-items:center}
 .br-cooking-mode-footer{gap:.65rem;margin:0!important;padding:.55rem 0 0!important}
 .br-cooking-mode-footer button{min-width:0;min-height:50px;flex:1}
}
@media(orientation:landscape) and (max-height:600px){
 .br-cooking-mode-shade{align-items:stretch;padding:0}
 .br-cooking-mode{width:100%;height:100dvh;align-self:stretch;max-height:100dvh;gap:.25rem;padding:calc(7px + env(safe-area-inset-top)) max(18px,env(safe-area-inset-right)) calc(7px + env(safe-area-inset-bottom)) max(18px,env(safe-area-inset-left))}
 .br-cooking-mode-header{position:relative;padding-right:48px;gap:.25rem}.br-cooking-mode-header>div{width:100%;flex:1 1 auto}
 .br-cooking-mode-header>div>p.small.muted{font-size:.9rem}
 .br-cooking-mode h2#br-cooking-title{font-size:clamp(1.5rem,4vh,2.05rem);line-height:1.05;margin:.08rem 0 .12rem}
 .br-cooking-mode .br-cooking-close{position:absolute;top:0;right:0;display:grid;place-items:center;box-sizing:border-box;width:38px;height:38px;min-width:38px;min-height:38px;max-width:38px;max-height:38px;padding:0;font-size:1.35rem}
 .br-cooking-step-progress{font-size:1.02rem;margin:.08rem 0 .35rem}
 .br-cooking-step-instruction{font-size:clamp(1.55rem,4.4vh,2rem);line-height:1.2;margin:.15rem 0 .5rem}
 .br-cooking-step-ingredients h3{font-size:1.25rem;margin-bottom:.35rem}
 .br-cooking-main{flex:1 1 0;max-height:none}
 .br-cooking-mode-footer{display:flex;width:100%;align-self:stretch;box-sizing:border-box;justify-content:space-between;gap:.55rem;margin:0!important;padding:.2rem 0 0!important}
 .br-cooking-mode-footer button{flex:0 0 auto;min-height:42px}
 .br-cooking-mode-footer .br-cooking-prev{margin-right:auto}
 .br-cooking-mode-footer .br-cooking-next{margin-left:auto}
}
html[data-theme=dark] .br-cooking-editor,html[data-theme=dark] .br-cooking-mode{background:#1e2e24;color:#f5efdf;border-color:#596752}
html[data-theme=dark] .br-editor-cooking-settings{background:#25372a;color:#f5efdf;border-color:#596752}
html[data-theme=dark] .br-cooking-customization-prompt{background:#25372a;color:#f5efdf;border-color:#65745e}
html[data-theme=dark] .br-cooking-instruction{background:#293a2e;color:#f5efdf}
html[data-theme=dark] .br-cooking-checklist label,html[data-theme=dark] .br-cooking-step-list label{background:#26372b;border-color:#596752}
html[data-theme=dark] .br-cooking-step-progress{background:#374b3b;border-color:#819687;color:#e8efe1}
html[data-theme=dark] .br-cooking-mode-footer button{color:#f5efdf;border-color:#758673}
html[data-theme=dark] .br-cooking-mode-footer .br-cooking-prev{background:transparent;color:#f5efdf}
html[data-theme=dark] .br-cooking-mode-footer .br-cooking-next{background:#365444;color:#fff}
.personal-recipe-optional{margin:1.1rem 0;padding:0 1rem .9rem;border:1px solid var(--line);border-radius:12px;background:rgba(255,255,255,.22)}.personal-recipe-optional>summary{margin:0 -1rem 1rem;padding:.85rem 1rem;cursor:pointer;color:var(--green);font-weight:700;list-style-position:inside}.personal-recipe-optional[open]>summary{border-bottom:1px solid var(--line)}
html[data-theme=dark] .personal-recipe-optional{background:rgba(255,255,255,.035)}
.personal-line-editor{width:100%;min-height:12rem;max-height:34rem;overflow:auto;border:1px solid #a6b7ae;border-radius:8px;padding:10px 14px;background:var(--paper);color:var(--ink);font:inherit;line-height:1.35;white-space:pre-wrap;overflow-wrap:anywhere}.personal-line-editor:focus{outline:3px solid #da8d3d;outline-offset:3px}.personal-line-editor-row{min-height:1.35em;line-height:1.35;margin:0 0 1.1rem;white-space:pre-wrap;overflow-wrap:anywhere}.personal-line-editor-row:last-child{margin-bottom:0}@media(max-width:560px){.personal-line-editor{min-height:10rem;max-height:42vh;padding:9px 11px}.personal-line-editor-row{margin-bottom:1rem}}
/* Cooking Mode timers: tap-to-start chips found in the step text; never auto-start. The shared kitchen timer dock sits above the Cooking Mode screen. */
body.br-cooking-open #kitchen-timers{z-index:10060;bottom:92px;max-height:36vh;overflow-y:auto}
body.br-cooking-open #kitchen-timers>p.small{display:none}
@media(min-width:720px){body.br-cooking-open #kitchen-timers{bottom:16px;left:50%;right:auto;transform:translateX(-50%);width:min(400px,calc(100vw - 32px));max-width:none}}
.br-cooking-timers{margin:18px 0}
.br-cooking-timers h3{margin:0 0 10px}
.br-cooking-timers .br-timer-row{display:flex;flex-wrap:wrap;align-items:center;gap:10px 12px;margin:0 0 10px;padding:10px 12px;border:1px solid var(--line);border-radius:12px}
.br-cooking-timers .br-timer-info{display:flex;flex-direction:column;flex:1 1 150px;min-width:0}
.br-cooking-timers .br-timer-label{font-weight:700}
.br-cooking-timers .br-timer-stepper{display:inline-flex;align-items:center;gap:6px}
.br-cooking-timers .br-timer-stepper button{width:44px;min-height:44px;padding:0;font-size:22px;line-height:1;justify-content:center}
.br-cooking-timers .br-timer-stepper output{min-width:76px;text-align:center;font-weight:700}
.br-cooking-timers .br-timer-start{min-height:44px;padding:8px 16px;background:var(--green);border-color:var(--green);color:var(--paper);font-weight:700}
.br-cooking-timers .br-timer-other{margin:0 0 10px}
.br-cooking-timers .br-timer-other>summary{min-height:44px;display:flex;align-items:center;cursor:pointer;font-weight:600}
.br-cooking-timers .br-timer-status{margin:4px 0 0;min-height:1.2em;color:var(--green);font-weight:600}
.br-cooking-step-instruction .rp-time{font-weight:700;white-space:nowrap;padding:0 2px;border-radius:4px;background:rgba(54,84,68,.12)}
html[data-theme=dark] .br-cooking-step-instruction .rp-time{background:rgba(173,198,173,.2)}
/* Cooking Mode: suggested step ingredients with a tap to fix (My Recipe Book). Neutral secondary styling; the green accent stays on the main buttons. */
.br-ing-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:.6rem}
.br-ing-head h3{margin:0}
.br-ing-hint{margin:2px 0 10px}
.br-fix-toggle,.br-fix-reset{box-sizing:border-box;min-height:44px;min-width:72px;padding:8px 16px;border:1px solid #819687;border-radius:12px;background:#e9ede4;color:#28372c;font:inherit;font-weight:600;cursor:pointer;justify-content:center}
.br-fix-toggle[aria-expanded="true"]{background:#d9e1d3}
.br-fix-panel{margin:12px 0 4px;padding:12px;border:1px solid #d1d0bd;border-radius:14px;background:#f2f1e6}
.br-fix-panel fieldset{margin:0;padding:0;border:0;min-width:0}
.br-fix-panel legend{margin:0 0 8px;padding:0;font-weight:700}
.br-fix-list{display:grid;gap:6px}
.br-fix-list label{display:flex;align-items:center;gap:12px;min-height:46px;padding:8px 12px;border:1px solid #d8d6c8;border-radius:12px;background:#fffdf7;line-height:1.4}
.br-fix-list input{width:1.15rem;height:1.15rem;flex:0 0 auto;margin:0;accent-color:#365444}
.br-fix-reset{margin-top:10px}
.br-fix-status{min-height:1.2em;margin:8px 0 0;color:#52694f;font-weight:600}
html[data-theme=dark] .br-fix-toggle,html[data-theme=dark] .br-fix-reset{background:transparent;color:#f5efdf;border-color:#758673}
html[data-theme=dark] .br-fix-toggle[aria-expanded="true"]{background:#374b3b}
html[data-theme=dark] .br-fix-panel{background:#25372a;border-color:#596752}
html[data-theme=dark] .br-fix-list label{background:#26372b;border-color:#596752}
html[data-theme=dark] .br-fix-status{color:#bcd2b8}
/* Finish screen: "cooked it" note for the kitchen notebook */
.br-cooked-form{display:flex;flex-direction:column;gap:.5rem;padding:.4rem 0 .2rem}
.br-cooked-form h3{margin:0;font-size:clamp(1.5rem,3vw,2rem);line-height:1.2;outline:0}
.br-cooked-form p{margin:0}
.br-cooked-form label{margin:.6rem 0 0;font-weight:700}
.br-cooked-form textarea{box-sizing:border-box;width:100%;min-height:9rem;padding:.8rem .9rem;border:1px solid #819687;border-radius:12px;background:#fffdf7;color:#27362c;font:inherit;font-size:1.05rem;line-height:1.45;resize:vertical}
.br-cooked-form textarea:focus-visible{outline:2px solid #365444;outline-offset:2px}
.br-cooked-status{min-height:1.4em;color:#8a3b3b}
.br-cooked-actions{display:flex;justify-content:space-between;gap:.8rem}
.br-cooked-actions button{box-sizing:border-box;min-width:120px;min-height:48px;padding:.65rem 1rem;border:1px solid #819687;border-radius:12px;background:transparent;color:inherit;font:inherit;font-weight:600}
.br-cooked-actions .br-cooked-add{flex:1 1 auto;background:#365444;color:#fff;border-color:#365444}
html[data-theme=dark] .br-cooked-form textarea{background:#26372b;color:#f5efdf;border-color:#596752}
html[data-theme=dark] .br-cooked-status{color:#f0b3b3}
html[data-theme=dark] .br-cooked-actions button{color:#f5efdf;border-color:#758673}
html[data-theme=dark] .br-cooked-actions .br-cooked-add{background:#365444;color:#fff}

/* Pan notes while cooking: one line, notes a tap away */
.br-cooking-pan{margin:0 0 .7rem;padding:.2rem .8rem;border-left:4px solid var(--green,#365b3b);border-radius:8px;background:rgba(127,127,127,.1)}
.br-cooking-pan summary{cursor:pointer;min-height:44px;display:flex;align-items:center;font-weight:600}
.br-cooking-pan ul{margin:.2rem 0 .6rem;padding-left:1.2rem}
.br-cooking-pan li{margin:.25rem 0}
