@layer components {
.recipe-style-description{grid-column:1/-1;min-height:0;margin:0}.recipe-style-description:empty{display:none}
.recipe-starter form{margin:12px 0}.recipe-starter .inline-check{margin:12px 0}.recipe-structure{margin:16px 0}.recipe-structure>.details-body{padding:12px 0}
.recipe-plan-fields{margin-top:14px}.recipe-equipment-preview{padding:14px;background:#f4f5f1;border:1px solid var(--border);border-radius:6px;margin:12px 0}.recipe-equipment-preview[hidden]{display:none}
.recipe-step-targets{margin:8px 0 0;font-size:var(--font-label)}.recipe-step-targets summary:where(:not(.brew-accordion>summary)){padding:4px 0;cursor:pointer;font-weight:400;background:transparent}.recipe-step-targets>div{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin-top:6px}
.recipe-step-targets label{min-width:0;display:flex;flex-direction:column;gap:4px}.brew-page .recipe-step-targets input{min-width:0;width:100%;max-width:100%}
.recipe-plan-summary .equipment-facts{margin:12px 0}.recipe-plan-summary dt{font-size:var(--font-label)}.recipe-plan-summary dd{margin:4px 0 0}
.recipe-taste-profile[hidden]{display:none}
.taste-style{font-weight:400;margin-left:8px}
.taste-chart-layout{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(0,1fr);gap:12px 24px;align-items:center;max-width:760px;margin-inline:auto}
.taste-wheel{margin:0;min-width:0;text-align:center}.taste-wheel svg{display:block;width:100%;max-width:420px;margin:auto}
.taste-wheel svg text{fill:var(--text);font-size:18px;font-family:inherit}
.taste-grid{fill:none;stroke:var(--border);stroke-width:1}
.taste-shape{fill:#819b75;fill-opacity:.3;stroke:#52734f;stroke-width:2.5;stroke-linejoin:round}
.taste-values{display:grid;gap:8px;margin:0;min-width:0;font-size:var(--font-label)}
.taste-values>div{display:flex;justify-content:space-between;gap:8px;padding-bottom:6px;border-bottom:1px solid var(--border)}
.taste-values dt{font-weight:400}.taste-values dd{margin:0;text-align:right;font-weight:600}
.recipe-prediction[hidden],.ingredient-brewing label[hidden],.prediction-missing[hidden]{display:none}
.taste-reference{fill:none;stroke:#90978a;stroke-width:2;stroke-dasharray:4 4}
.taste-estimate-line{stroke:#52734f;stroke-width:3}.taste-estimate-dot{fill:#52734f}
.taste-abv-background{fill:#edf2e9}.taste-wheel svg text.taste-abv{fill:#45674c;font-size:21px;font-weight:700}
.prediction-metrics{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:12px;margin:16px 0}
.prediction-metrics dt{font-size:var(--font-label)}.prediction-metrics dd{font-size:var(--font-section);font-weight:600;margin:4px 0}
.ingredient-brewing-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
@media(max-width:600px){.prediction-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:600px){.taste-chart-layout{grid-template-columns:minmax(0,1fr);gap:12px}.taste-values{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 16px}.taste-values>div{display:block}.taste-values dd{text-align:left;margin-top:2px}.taste-style{display:block;margin:2px 0 0}}
}
@layer layout {
.recipe-classification{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px 16px}
.recipe-plan-fields{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:12px 16px}
.recipe-plan-fields>label{grid-column:span 2}
.recipe-plan-fields>.recipe-plan-text{grid-column:span 3}
.recipe-classification>label,.recipe-plan-fields>label{display:flex;flex-direction:column;gap:4px;min-width:0;margin:0}
.recipe-classification select,.recipe-plan-fields :is(input,select){width:100%;min-width:0;max-width:100%;margin:0;margin-top:auto}
.brew-page .recipe-structure>.details-body{padding:12px 0}
.brew-page .recipe-classification>.recipe-taste-profile{grid-column:1/-1;min-width:0;margin:0}
.brew-page .recipe-taste-profile>.details-body{padding:12px 0}
.brew-page .recipe-prediction>.details-body{padding:12px 0}
.brew-page .ingredient-brewing{margin:6px 0 0;white-space:normal}
.brew-page .ingredient-brewing>summary:where(:not(.brew-accordion>summary)){padding:6px 0;font-size:var(--font-label)}
.ingredient-brewing-fields>label{display:flex;flex-direction:column;gap:4px;min-width:0;margin:0;font-size:var(--font-label)}
.brew-page .ingredient-brewing-fields :is(input,select){width:100%;min-width:0;max-width:100%;margin:0;margin-top:auto}
@media(max-width:700px){
  .recipe-classification{grid-template-columns:repeat(2,minmax(0,1fr))}
  .recipe-classification>.recipe-style-field{grid-column:1/-1}
  .recipe-classification,.recipe-plan-fields{column-gap:12px}
  .recipe-classification select,.recipe-plan-fields :is(input,select){min-height:44px}
}
@media(max-width:600px){.recipe-plan-fields>.recipe-plan-text{grid-column:1/-1}}
@media(max-width:359px){
  .recipe-plan-fields>label{grid-column:span 3}
  .recipe-plan-fields>.recipe-plan-volume{grid-column:1/-1}
}
}

@layer layout {
.recipe-starter .recipe-classification{grid-template-columns:repeat(4,minmax(0,1fr))}
.recipe-storage-field small{font-size:var(--font-label);font-weight:400;line-height:1.4;margin-top:4px}
.recipe-starter .recipe-classification select{margin-top:0}
.recipe-template-actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.brew-page .recipe-template-browser{width:min(1000px,calc(100vw - 24px));max-width:1000px}
.template-browser-filters{display:grid;grid-template-columns:2fr 1fr;gap:12px}
.template-browser-filters label{display:flex;flex-direction:column;gap:4px;min-width:0}
.template-browser-filters :is(input,select){width:100%;min-width:0;margin:0}
.template-browser-list{display:grid;gap:0;border:1px solid var(--border);border-radius:6px;overflow:hidden}
.template-browser-item{display:grid;grid-template-columns:minmax(150px,1fr) minmax(180px,1.3fr) minmax(300px,1.7fr) auto;align-items:center;gap:12px;padding:12px;background:#fff;min-width:0;border-bottom:1px solid var(--border)}
.template-browser-item:last-child{border-bottom:0}
.template-browser-item{background:var(--list-row-neutral)}
.template-browser-item:nth-child(even){background:var(--list-row-sage)}
.template-browser-item[hidden]{display:none}
.template-item-heading{display:flex;align-items:center;gap:8px;min-width:0}
.template-item-heading h3{margin:0;font-size:var(--font-body);overflow-wrap:anywhere}
.template-browser-item>p{grid-column:2;grid-row:1;margin:0;font-size:var(--font-label);line-height:1.4}
.template-browser-item .template-profile{grid-column:3;grid-row:1}
.template-browser-item .template-use{grid-column:4;grid-row:1;justify-self:end;width:auto;margin:0;white-space:nowrap}
.template-color{display:block;width:24px;height:34px;border:1px solid #9c998b;border-radius:3px 3px 7px 7px;flex:none;background:#ebece6}
.template-color-gold{background:#edcd75}.template-color-amber{background:#bb8341}.template-color-dark{background:#4e3324}
.template-profile{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin:0;font-size:var(--font-label)}
.template-profile dt{color:#687267}.template-profile dd{margin:2px 0 0;line-height:1.3}
.template-profile meter{display:block;width:80px;max-width:100%;height:12px}
@media(max-width:700px){.recipe-starter .recipe-classification{grid-template-columns:repeat(2,minmax(0,1fr))}.recipe-starter .recipe-classification>.recipe-style-field{grid-column:auto}.template-profile{grid-template-columns:repeat(2,minmax(0,1fr))}.template-browser-filters{grid-template-columns:1fr}.template-item-heading{flex-wrap:wrap}.template-item-heading h3{overflow-wrap:anywhere}}
}

@layer layout {
@media(max-width:1050px){.template-browser-item{grid-template-columns:minmax(0,1fr) auto}.template-browser-item>p{grid-column:1/-1;grid-row:2}.template-browser-item .template-profile{grid-column:1/-1;grid-row:3}.template-browser-item .template-use{grid-column:2;grid-row:1}.template-browser-item .template-profile{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:600px){.brew-page .recipe-template-browser .dialog-body{padding:12px}.template-browser-item{padding:10px;gap:8px}.template-browser-filters{gap:8px}.template-browser-item .template-profile{gap:6px;font-size:12px}.template-profile meter{width:60px}.template-color{width:16px;height:25px}.template-item-heading h3{font-size:15px}.template-browser-item .template-use{padding:8px;min-height:40px}.template-profile dd small{font-size:inherit}}
}

@layer layout {
.recipe-ingredient-identity{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.recipe-ingredient-identity>input:not([type=hidden]){flex:1;min-width:100px;width:0;margin:0}
.brew-page .recipe-ingredient-identity .ingredient-brewing{margin:0;flex:none}
.brew-page .recipe-ingredient-identity .ingredient-brewing[open]{flex-basis:100%}
.brew-page #recipe-form .ingredient-brewing>summary:where(:not(.brew-accordion>summary)){padding:8px;min-height:40px;border:1px solid var(--border);border-radius:5px;white-space:nowrap}
.ingredient-brewing[hidden]{display:none}
.brew-page #recipe-form .recipe-notes-below{display:block;margin:16px 0 0}
.brew-page #recipe-form .recipe-notes-below textarea{height:64px;min-height:64px}
.recipe-section-divider{border:0;border-top:1px solid var(--border);margin:24px 0 20px}
}

@layer layout {
.brew-page #recipe-form :is([data-move-step],[data-remove-row]){display:inline-flex;align-items:center;justify-content:center;text-align:center;padding:0;line-height:1;min-height:40px;min-width:32px;flex:none;margin:0}
.recipe-step-content{display:flex;align-items:flex-start;gap:8px;min-width:0}
.brew-page #recipe-form .recipe-step-content>.text-preview{flex:1;width:0;margin:0;}

.brew-page #recipe-form .recipe-step-content>.recipe-step-targets{flex:1;min-width:0;margin:0}
.brew-page #recipe-form .recipe-step-content>.recipe-step-targets>summary:where(:not(.brew-accordion>summary)){min-height:44px;padding:10px 28px 10px 10px;white-space:normal;line-height:1.4}
@media(max-width:1000px){.recipe-step-content{flex-direction:column}.brew-page #recipe-form .recipe-step-content>:is(.text-preview,.recipe-step-targets){width:100%;flex:auto}}
}

@layer layout {
.brew-page #recipe-form .recipe-header-grid{grid-template-columns:minmax(0,1.3fr) 140px minmax(0,2fr);align-items:end}
.brew-page #recipe-form .recipe-header-grid>label{min-width:0;margin:0}
.brew-page #recipe-form .recipe-header-notes .recipe-short-notes{height:44px;min-height:44px;margin:0;resize:vertical}
.brew-page #recipe-form :is(.recipe-name-label,.recipe-name-input){text-transform:none}
@media(max-width:700px){.brew-page #recipe-form .recipe-header-grid{grid-template-columns:minmax(0,1fr) 100px}.brew-page #recipe-form .recipe-header-grid>.recipe-header-notes{grid-column:1/-1}}
}

@layer layout {
.brew-page #recipe-form .recipe-header-grid{grid-template-columns:minmax(0,1.3fr) auto minmax(0,2fr);align-items:center}
.brew-page #recipe-form .recipe-header-grid :is(input,textarea){margin:0;height:44px;min-height:44px;box-sizing:border-box}
.brew-page #recipe-form .recipe-header-grid .recipe-abv-inline{display:flex;align-items:center;gap:8px;white-space:nowrap}
.brew-page #recipe-form .recipe-abv-inline input{width:90px;flex:none}
.brew-page #recipe-form .recipe-header-notes{display:block;line-height:0}
.brew-page #recipe-form .recipe-header-notes textarea{display:block;line-height:1.4}
.recipe-ingredient-heading{justify-content:flex-end;margin:12px 0}
.brew-page .recipe-steps-sheet thead{height:0}
.brew-page .recipe-steps-sheet th{padding-block:0;border:0;height:0}
.step-day-inline{display:flex!important;align-items:center;gap:6px;margin:0!important}
.brew-page .step-day-inline input{width:65px;min-width:0;margin:0}
.brew-page #recipe-form .recipe-step-content{display:grid;grid-template-columns:minmax(100px,1fr) minmax(170px,1fr);align-items:center;gap:8px}
.brew-page #recipe-form .recipe-step-content .step-instruction-field{margin:0;min-width:0}
.brew-page #recipe-form .recipe-step-content textarea{width:100%;min-width:0;height:52px;min-height:52px;margin:0;padding:8px;resize:vertical}
.brew-page #recipe-form .recipe-inline-targets{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:0;width:auto}
.brew-page #recipe-form .recipe-inline-targets label{margin:0;font-size:var(--font-label)}
.brew-page #recipe-form .recipe-inline-targets input{margin:0;min-height:40px;height:40px}
@media(max-width:1000px){.brew-page #recipe-form .recipe-step-content{grid-template-columns:minmax(0,1fr)}.brew-page #recipe-form .recipe-header-grid{grid-template-columns:minmax(0,1fr) auto}.brew-page #recipe-form .recipe-header-grid>.recipe-header-notes{grid-column:1/-1}}
@media(max-width:450px){.brew-page #recipe-form .recipe-header-grid{grid-template-columns:minmax(0,1fr)}.brew-page #recipe-form .recipe-header-grid>.recipe-header-notes{grid-column:auto}}
}

@layer layout {
.brew-page #recipe-form .recipe-structure{margin:12px 0;padding:0;border-radius:0}
.brew-page #recipe-form .recipe-structure>summary:where(:not(.brew-accordion>summary)){margin-inline:0}
.brew-page #recipe-form .recipe-save-actions,.recipe-lifecycle-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:16px 0 0}
.brew-page #recipe-form .recipe-save-actions>button,.recipe-lifecycle-actions button{width:100%;margin:0}
.recipe-lifecycle-actions form{margin:0}
.brew-page #recipe-form .recipe-steps-sheet :is(input,select,textarea){height:44px;min-height:44px;margin:0;box-sizing:border-box}
.brew-page #recipe-form .recipe-step-content{align-items:center}
.brew-page #recipe-form .recipe-inline-targets label{position:relative;display:block}
.brew-page #recipe-form .recipe-inline-targets label>input{padding-top:15px;font-size:var(--font-body)}
.brew-page #recipe-form .recipe-inline-targets label{font-size:0}
.brew-page #recipe-form .recipe-inline-targets label::before{position:absolute;top:2px;left:8px;font-size:10px;line-height:12px;pointer-events:none;color:var(--muted)}
.brew-page #recipe-form .recipe-inline-targets label[data-step-temperature]::before{content:'°C'}
.brew-page #recipe-form .recipe-inline-targets label[data-step-duration]::before{content:'min'}
.brew-page #recipe-form .recipe-inline-targets input{margin:0}
}
@layer layout {
.brew-page #recipe-form .recipe-steps-sheet :is(input,select,textarea){display:block;line-height:1.4}
.brew-page #recipe-form .step-instruction-field{line-height:0}
.brew-page #recipe-form .recipe-steps-sheet td{vertical-align:middle}
}

@layer layout {
.brew-page #recipe-form .recipe-process-panel{margin:24px 0 0;padding:16px;border:1px solid var(--border);border-radius:8px;background:var(--surface-sage);min-width:0}
.brew-page #recipe-form .recipe-process-panel>h2{margin-top:0}
.brew-page #recipe-form .recipe-process-panel>.brew-meta:last-child{margin-bottom:0}
.brew-page #recipe-form .recipe-process-panel .edge-list{--list-inset:16px}
@media(max-width:600px){.brew-page #recipe-form .recipe-process-panel{padding:12px}.brew-page #recipe-form .recipe-process-panel .edge-list{--list-inset:12px}}
}

@layer layout {
.recipe-editor-shell{min-width:0}
.brew-page .recipe-editor-shell #recipe-form{margin:0}
.brew-page #recipe-form>.recipe-main-panel{margin:6px;padding:16px;min-width:0}
.brew-page #recipe-form>.recipe-process-panel{margin:18px 6px 6px;padding:16px;background:#fff;border-radius:6px}
.brew-page #recipe-form .recipe-save-actions{display:inline-grid;grid-template-columns:repeat(2,1fr);width:max-content;max-width:100%;gap:12px;margin:16px 0 0}
.brew-page #recipe-form .recipe-save-actions>button{width:100%;margin:0;}
.brew-page #recipe-form .recipe-save-actions>button:where(:not(button[data-button-role])){white-space:nowrap;}
.brew-page .recipe-editor-shell .recipe-lifecycle-actions{width:max-content;max-width:calc(100% - 12px);margin:12px 6px}
@media(max-width:600px){.brew-page #recipe-form>.recipe-main-panel,.brew-page #recipe-form>.recipe-process-panel{padding:12px}.brew-page #recipe-form>.recipe-main-panel .edge-list,.brew-page #recipe-form>.recipe-process-panel .edge-list{--list-inset:12px}.brew-page #recipe-form .recipe-save-actions{gap:8px}}
}

@layer layout {
.brew-page .ingredient-brewing{flex:none;margin:0}
.brew-page .ingredient-brewing [data-brew-open]{margin:0;padding:8px;white-space:nowrap;min-height:40px}
.ingredient-brewing-popover{display:none;position:fixed;inset:0;margin:auto;width:min(560px,calc(100vw - 24px));max-width:calc(100vw - 24px);max-height:85dvh;overflow:auto;padding:16px;border:1px solid var(--border);border-radius:8px;background:#fff;color:var(--text);box-shadow:0 10px 40px #0003;z-index:1000}
.ingredient-brewing-popover:popover-open,.ingredient-brewing-popover.is-open{display:block}
.ingredient-brewing-popover::backdrop{background:#0002}
.brewing-popover-header{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.brewing-popover-header button{margin:0;}
.brewing-popover-header button:where(:not(button[data-button-role])){min-height:40px;}
.ingredient-brewing-popover .ingredient-brewing-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.ingredient-brewing-popover .ingredient-brewing-fields>label{white-space:normal}
.brew-page .ingredient-brewing-popover :is(input,select){min-width:0;width:100%;margin:0}
.brew-page .recipe-prediction{margin:16px 0 0}
[data-prediction-result][hidden],[data-brew-unknown][hidden]{display:none}
@media(max-width:400px){.ingredient-brewing-popover .ingredient-brewing-fields{grid-template-columns:minmax(0,1fr)}}
}

/* Compact records retain 44px touch targets and the original form controls. */
@layer mobile {
.recipe-template-tools{display:grid;grid-template-columns:minmax(180px,1fr) auto;gap:8px 16px;align-items:end;margin:12px 0}
.recipe-template-tools>label{display:flex;flex-direction:column;gap:4px;margin:0;min-width:0}
.recipe-template-tools select{width:100%;margin:0}
.recipe-template-tools .recipe-template-actions{margin:0}
.recipe-template-tools>p{grid-column:1/-1;margin:0}
@media(max-width:700px){
 .recipe-template-tools{grid-template-columns:minmax(0,1fr);gap:8px}
 .recipe-template-tools .recipe-template-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .recipe-template-tools button{margin:0;}
.recipe-template-tools button:where(:not(button[data-button-role])){white-space:normal;min-height:44px;padding:8px;}
 .brew-page #recipe-form .recipe-classification,.brew-page #recipe-form .recipe-plan-fields{gap:8px}
 .brew-page #recipe-form .recipe-header-grid{grid-template-columns:minmax(0,1fr) auto;gap:8px}
 .brew-page #recipe-form .recipe-header-grid>.recipe-header-notes{grid-column:1/-1}
 .brew-page #recipe-form .recipe-abv-inline{gap:4px;font-size:12px}
 .brew-page #recipe-form .recipe-abv-inline input{width:56px}
 .brew-page #recipe-form .recipe-ingredients-sheet[data-mobile-sheet]>tbody>tr{grid-template-columns:repeat(4,minmax(0,1fr));gap:6px 8px;padding-block:10px}
 .recipe-ingredients-sheet[data-mobile-sheet] td:first-child{grid-column:1/4;grid-row:1}
 .recipe-ingredients-sheet[data-mobile-sheet] td:nth-child(2){grid-column:1/3;grid-row:2}
 .recipe-ingredients-sheet[data-mobile-sheet] td:nth-child(3){grid-column:3;grid-row:2}
 .recipe-ingredients-sheet[data-mobile-sheet] td:nth-child(4){grid-column:4;grid-row:2}
 .recipe-ingredients-sheet[data-mobile-sheet] td:nth-child(5){grid-column:1/-1;grid-row:3;font-size:12px}
 .brew-page .recipe-ingredients-sheet[data-mobile-sheet] td:nth-child(5)[data-empty-volume=true]{display:none}
 .recipe-ingredients-sheet[data-mobile-sheet] td:nth-child(5)::before{display:inline;margin-right:6px}
 .recipe-ingredients-sheet[data-mobile-sheet] td:last-child{grid-column:4;grid-row:1}
 .recipe-ingredient-identity{gap:6px;flex-wrap:nowrap}
 .recipe-ingredient-identity>input:not([type=hidden]){min-width:60px}
 .brew-page .ingredient-brewing [data-brew-open]{font-size:12px;padding:6px;min-height:44px}
 .brew-page .recipe-steps-sheet[data-mobile-sheet]>tbody>tr{grid-template-columns:44px minmax(0,1fr) 60px 36px;gap:6px 8px;padding-block:10px}
 .brew-page .recipe-steps-sheet[data-mobile-sheet] .step-order-cell{grid-column:1;grid-row:1/4;align-self:start}
 .recipe-steps-sheet[data-mobile-sheet] td:nth-child(2){grid-column:2/4;grid-row:1}
 .recipe-steps-sheet[data-mobile-sheet] td:nth-child(3){grid-column:2;grid-row:2}
 .recipe-steps-sheet[data-mobile-sheet] td:nth-child(4){grid-column:3/5;grid-row:2}
 .recipe-steps-sheet[data-mobile-sheet] td:nth-child(5){grid-column:2/-1;grid-row:3}
 .recipe-steps-sheet[data-mobile-sheet] td:last-child{grid-column:4;grid-row:1}
 .brew-page .recipe-steps-sheet[data-mobile-sheet] td::before{display:none}
 .recipe-steps-sheet .step-row-actions{gap:6px}
 .brew-page #recipe-form .recipe-steps-sheet .step-row-actions button:where(:not(button[data-button-role])){min-width:44px;min-height:44px;}
 .brew-page #recipe-form .recipe-ingredient-heading{margin:8px 0;font-size:12px}
 .brew-page #recipe-form :is(.recipe-main-panel,.recipe-process-panel){margin-inline:0}
}
}

@layer mobile {
@media(max-width:700px){
 .brew-page #recipe-form .step-day-inline>span{white-space:nowrap;flex:none}
 .brew-page #recipe-form .step-day-inline input{width:0;min-width:0;flex:1}
}
}

@layer layout {
.brew-page #recipe-form .recipe-header-grid{align-items:start}
.brew-page #recipe-form .recipe-header-notes .recipe-short-notes{overflow:hidden;resize:none;min-height:44px}
}

@layer layout {
.brew-page #recipe-form .recipe-ingredient-actions{display:inline-grid;grid-template-columns:repeat(2,minmax(0,1fr));width:max-content;max-width:100%}
}

@layer layout {
.recipe-choice-layout{display:grid;grid-template-columns:minmax(0,1fr) max-content;gap:12px 20px;align-items:center}
.recipe-choice-fields{min-width:0;display:grid;gap:12px}
.recipe-choice-fields>.recipe-storage-field{display:flex;flex-direction:column;gap:4px;min-width:0;margin:0}
.recipe-choice-fields>.recipe-storage-field select{width:100%;margin:0}
.brew-page #recipe-form .recipe-choice-layout>.recipe-template-actions{display:grid;grid-template-columns:max-content;gap:8px;align-self:center;margin:0}
.brew-page #recipe-form .recipe-template-actions>button{width:100%;margin:0;}
.brew-page #recipe-form .recipe-template-actions>button:where(:not(button[data-button-role])){min-height:44px;white-space:nowrap;}
.recipe-template-hint{grid-column:1/-1;margin:0}
.recipe-choice-layout:not([data-recipe-starter]){grid-template-columns:minmax(0,1fr)}
.brew-page #recipe-form .recipe-structure>.details-body>.recipe-plan-fields{grid-template-columns:minmax(0,2fr) minmax(0,1fr)}
.brew-page #recipe-form .recipe-structure>.details-body>.recipe-plan-fields>label{grid-column:auto}
.recipe-legacy-fields{margin:12px 0}
@media(max-width:700px){.recipe-choice-layout{grid-template-columns:minmax(0,1fr);gap:10px}.brew-page #recipe-form .recipe-choice-layout>.recipe-template-actions{justify-self:start}.recipe-choice-fields{gap:8px}}
}

@layer layout {
.brew-page #recipe-form .recipe-inline-targets[hidden],.brew-page #recipe-form .recipe-inline-targets label[hidden]{display:none}
.brew-page #recipe-form .recipe-step-content:has(.recipe-inline-targets[hidden]){grid-template-columns:minmax(0,1fr)}
.brew-page #recipe-form .recipe-inline-targets[data-target-count="1"]{grid-template-columns:minmax(0,1fr)}
.brew-page .recipe-editor-shell .recipe-lifecycle-actions{display:inline-grid;grid-template-columns:repeat(2,max-content);gap:12px;width:max-content}
.brew-page .recipe-editor-shell .recipe-lifecycle-actions button{display:flex;align-items:center;justify-content:center;margin:0;}
.brew-page .recipe-editor-shell .recipe-lifecycle-actions button:where(:not(button[data-button-role])){min-height:44px;padding:10px 16px;font:inherit;font-weight:700;line-height:1.4;}
@media(min-width:1001px){.brew-page #recipe-form .recipe-step-content:has(.recipe-inline-targets[data-target-count="1"]){grid-template-columns:minmax(100px,1fr) 100px}}
@media(max-width:700px){.brew-page #recipe-form .recipe-steps-sheet[data-mobile-sheet]>tbody>tr{grid-template-columns:44px minmax(0,1fr) 80px 36px}.brew-page #recipe-form .step-day-inline input{min-width:40px}}
}

@layer layout {
.recipe-volume-details{margin:0 0 12px;text-align:right}
.recipe-volume-details p{margin:4px 0;font-size:var(--font-label)}
.brew-page #recipe-form .recipe-structure>.details-body>.recipe-plan-fields{grid-template-columns:minmax(0,1fr)}
.brew-page #recipe-form .recipe-choice-layout>.recipe-template-actions{align-self:start;padding-top:24px;gap:12px}
@media(max-width:700px){.brew-page #recipe-form .recipe-choice-layout>.recipe-template-actions{padding-top:0}.recipe-volume-details{text-align:left}}
}

/* Process fields follow the operation; optional conditions open above the page. */
@layer layout {
.brew-page #recipe-form .recipe-steps-sheet .step-kind{width:150px}
.brew-page #recipe-form .recipe-steps-sheet td:nth-child(3){width:150px;min-width:0}
.brew-page #recipe-form .recipe-steps-sheet .step-day{width:122px}
.brew-page #recipe-form .recipe-steps-sheet td:nth-child(4){width:122px;min-width:122px}
.brew-page #recipe-form .step-day-inline>span{white-space:nowrap;flex:none}
.brew-page #recipe-form .step-day-inline input{width:74px;min-width:74px;flex:none;padding-inline:8px}
.brew-page #recipe-form .recipe-step-content{align-items:start}
.brew-page #recipe-form .recipe-step-content textarea{height:auto;min-height:44px;overflow:hidden;resize:none}
.brew-page #recipe-form .recipe-steps-sheet td{vertical-align:top}
.brew-page #recipe-form .step-conditions-toggle[hidden]{display:none}
.brew-page #recipe-form .recipe-step-content[data-target-mode=optional]{grid-template-columns:minmax(0,1fr) auto}
.brew-page #recipe-form .recipe-step-content[data-target-mode=none]{grid-template-columns:minmax(0,1fr)}
.brew-page #recipe-form .step-conditions-toggle{margin:0;}

.brew-page #recipe-form .step-conditions-popover{position:fixed;inset:0;margin:auto;width:min(440px,calc(100vw - 24px));max-width:calc(100vw - 24px);max-height:80dvh;overflow:auto;padding:20px;background:#fff;color:var(--text);border:1px solid var(--border);border-radius:8px;box-shadow:0 10px 40px #0003;z-index:1000}
.brew-page #recipe-form .step-conditions-popover{display:none}
.brew-page #recipe-form .step-conditions-popover:popover-open{display:grid}
.brew-page #recipe-form .step-conditions-popover.is-open{display:grid}
.step-conditions-popover::backdrop{background:#0002}
.brew-page #recipe-form [data-step-close]{display:none}
.brew-page #recipe-form .step-conditions-popover [data-step-close]{display:block;grid-column:1/-1;justify-self:end;margin:8px 0 0}
.brew-page #recipe-form .step-conditions-popover label{font-size:var(--font-label)}
.brew-page #recipe-form .step-conditions-popover label::before{display:none}
.brew-page #recipe-form .step-conditions-popover label>input{padding:8px}
@media(max-width:700px){
 .brew-page #recipe-form .recipe-steps-sheet[data-mobile-sheet]>tbody>tr{grid-template-columns:44px minmax(0,1fr) 84px 36px}
 .brew-page #recipe-form .recipe-steps-sheet td:nth-child(3){width:auto;min-width:0}
 .brew-page #recipe-form .recipe-steps-sheet td:nth-child(4){width:auto;min-width:0}
 .brew-page #recipe-form .step-day-inline input{width:74px;min-width:74px;flex:none}
}
}

/* Reserve both shared icon buttons plus the table cell's horizontal padding. */
@media(min-width:701px){
 .brew-page #recipe-form .recipe-steps-sheet :is(.step-order-cell,.step-arrows) {
  width:calc(2 * var(--button-min-height,38px) + 4px + 18px);
  min-width:calc(2 * var(--button-min-height,38px) + 4px + 18px);
 }
 .brew-page #recipe-form .step-row-actions {width:max-content;}
}
