#production-view { min-width:0; }
#production-view>.page-heading { padding:20px 24px; border:1px solid var(--border);border-radius:16px;background:var(--surface); }
#production-content { display:grid;gap:16px;min-width:0; }
.production-cost-analysis{display:grid;gap:16px;min-width:0;}
.production-cost-analysis-section{min-width:0;padding:18px 20px;}
.production-cost-analysis-section h3{margin:0 0 8px;font-size:1.05rem;}
.production-cost-analysis-section>p{margin:6px 0 12px;}
html:root .production-filters.production-cost-analysis-filters{display:grid;grid-template-columns:repeat(2,minmax(0,260px));}
html:root .production-cost-analysis :is(th,td)[data-column="change"]{text-align:right;}
.production-cost-analysis-kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin:16px 0;}
.production-cost-analysis-kpis>div{display:grid;align-content:start;gap:7px;padding-right:12px;border-right:1px solid var(--border);}
.production-cost-analysis-kpis>div:last-child{border:0;}
.production-cost-analysis-kpis span,.production-cost-analysis-kpis small{font-size:.8rem;color:var(--text-secondary);}
.production-cost-analysis-kpis strong{font-size:1.35rem;font-variant-numeric:tabular-nums;overflow-wrap:anywhere;}
.production-cost-analysis-comparison{border-top:1px solid var(--border);padding-top:14px;}
.production-cost-analysis-comparison p{margin:8px 0;}
.production-cost-analysis-comparison .production-cost-effects{max-width:560px;}
.production-cost-analysis-pair{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:start;gap:16px;}
.production-cost-analysis-list{min-width:0;}
.production-cost-analysis .production-table{width:100%;margin-top:12px;}
.production-cost-analysis .production-table td{vertical-align:top;}
.production-cost-analysis .production-table small{display:block;line-height:1.45;margin-top:4px;font-size:.75rem;}
.production-cost-analysis .production-table td p{margin:0 0 6px;font-size:.81rem;line-height:1.5;}
.production-cost-analysis .production-table td p:last-child{margin:0;}
html:root .production-cost-analysis .production-table .production-name{display:block;text-align:left;max-width:100%;white-space:normal;overflow-wrap:anywhere;}
.production-cost-analysis .production-table td[data-align=number]{font-variant-numeric:tabular-nums;}
.production-cost-analysis-signal{color:var(--theme-accent);font-weight:600;}
.production-cost-analysis-filter{display:flex;flex-wrap:wrap;gap:7px;margin:12px 0;}
.production-cost-analysis-filter button{padding:6px 9px;min-height:34px;font-size:.75rem;}
.production-cost-analysis-filter button[aria-pressed=true]{background:var(--accent-soft);border-color:var(--theme-accent);color:var(--theme-accent);}
html:root .production-cost-analysis-chef .production-table{table-layout:fixed;}
html:root .production-cost-analysis-chef .production-table :is(th,td)[data-column]{width:auto;}
html:root .production-cost-analysis .production-table tbody td{vertical-align:top;}
html:root .production-cost-analysis-chef .production-table thead th[data-align=number]{white-space:nowrap;overflow-wrap:normal;word-break:normal;}
html:root .production-cost-analysis-chef .production-table .production-cost-previous{white-space:nowrap;}
html:root .production-cost-analysis-chef td>strong{display:block;line-height:1.5;}
html:root .production-cost-analysis-chef col[data-column=name]{width:28%;}
html:root .production-cost-analysis-chef col[data-column=quantity]{width:12%;}
html:root .production-cost-analysis-chef col[data-column=food_cost]{width:18%;}
html:root .production-cost-analysis-chef col[data-column=action]{width:42%;}
.production-cost-analysis-quality{padding:0;min-width:0;}
.production-cost-analysis-quality>summary{padding:14px 20px;cursor:pointer;font-weight:600;}
.production-cost-analysis-quality>div{padding:0 20px 16px;}
.production-cost-analysis-missing{display:flex;flex-wrap:wrap;gap:6px 16px;max-height:240px;overflow:auto;}
.production-cost-analysis-observations{display:grid;gap:0;}
.production-cost-analysis-observation{display:grid;gap:5px;padding:12px 0;border-bottom:1px solid var(--border);min-width:0;}
.production-cost-analysis-observation:last-child{border-bottom:0;}
.production-cost-observation-metrics{display:flex;flex-wrap:wrap;gap:3px 16px;font-size:.8rem;line-height:1.5;color:var(--text-secondary);font-variant-numeric:tabular-nums;}
html:root .production-cost-analysis a.production-cost-link{display:inline-block;width:fit-content;max-width:100%;min-height:0;margin:0;padding:0;border:0;border-radius:0;background:transparent!important;box-shadow:none!important;color:var(--theme-accent);font-size:.86rem;font-weight:600;line-height:1.5;text-align:left;white-space:normal;overflow-wrap:anywhere;text-decoration:none;}
html:root .production-cost-analysis a.production-cost-link:is(:hover,:focus-visible){text-decoration:underline;text-underline-offset:3px;}
.production-cost-group-control{display:grid;gap:6px;min-width:0;align-content:end;font-size:.85rem;line-height:1.3;}
html:root .production-filters.production-cost-analysis-filters{grid-template-columns:repeat(2,minmax(0,260px)) max-content;}
html:root .production-cost-group-select{width:auto;justify-self:start;white-space:nowrap;padding-inline:14px;}
.production-cost-selected-groups{overflow-wrap:anywhere;}
.production-dish-abc{display:flex;align-items:center;flex-wrap:wrap;gap:8px 14px;padding:12px 14px;margin:0 0 16px;border:1px solid var(--border);border-radius:12px;}
.production-dish-abc .production-abc-classes{justify-content:flex-start;}
.production-dish-abc>small{flex-basis:100%;line-height:1.5;}
.production-recipe-history{border-top:1px solid var(--border);margin-top:20px;padding-top:16px;min-width:0;}
.production-recipe-history>h3{margin:0 0 12px;}
html:root button.production-recipe-entry{display:grid;grid-template-columns:100px minmax(0,1fr);gap:4px 16px;width:100%;margin:8px 0;padding:12px 14px;text-align:left;white-space:normal;border:1px solid var(--border);background:var(--surface);border-radius:12px;color:var(--text-primary);line-height:1.5;}
.production-recipe-entry>small{grid-column:2;color:var(--text-secondary);font-weight:400;}
.production-recipe-entry>*{min-width:0;overflow-wrap:anywhere;}
html:root .production-dialog.crm-standard-window:not(.window-maximized).production-recipe-change-dialog{width:min(820px,var(--window-width-limit));}
.production-recipe-change{min-width:0;}
.production-recipe-change>h3{margin-top:0;}
.production-recipe-cost{padding:14px;border:1px solid var(--border);border-radius:12px;background:var(--accent-soft);margin:16px 0;}
.production-recipe-cost>h3{margin:0 0 8px;}
.production-recipe-cost>strong{font-size:1.1rem;}
.production-recipe-cost p{margin:8px 0 0;line-height:1.5;overflow-wrap:anywhere;}
.production-recipe-diff{padding:14px 0;border-bottom:1px solid var(--border);min-width:0;}
.production-recipe-diff>small{display:block;margin:4px 0 8px;}
.production-recipe-diff>h4{margin:0 0 10px;}
.production-recipe-text-diff{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;}
.production-recipe-text-diff p{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.5;font-size:.85rem;}
@media(max-width:700px){
  html:root .production-filters.production-cost-analysis-filters{grid-template-columns:minmax(0,1fr);}
  html:root button.production-recipe-entry{grid-template-columns:minmax(0,1fr);gap:4px;}
  .production-recipe-entry>small{grid-column:1;}
  .production-recipe-text-diff{grid-template-columns:minmax(0,1fr);}
}
html:root .production-cost-groups-dialog{display:flex;flex-direction:column;max-width:620px;min-width:0;overflow:hidden;}
.production-cost-groups-dialog>header{flex:none;}
.production-cost-groups-body{min-height:0;overflow:auto;padding:0 2px;}
.production-cost-groups-footer{flex:none;justify-content:flex-end;gap:8px;padding-top:14px;border-top:1px solid var(--border);margin-top:14px;flex-wrap:wrap;}
.production-cost-groups-dialog .production-abc-group-options{max-height:min(340px,35dvh);}
.production-cost-groups-top{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;min-width:0;}
.production-cost-group-directions{display:flex;gap:6px;flex-wrap:wrap;}
html:root .production-cost-group-directions button[aria-pressed="true"]{background:var(--accent-soft);border-color:var(--theme-accent);color:var(--text-primary);}
.production-cost-groups-choose{justify-self:start;max-width:100%;white-space:normal;}
.production-cost-group-mixed{margin-left:auto;color:var(--text-secondary);font-size:.75rem;flex-shrink:0;}
@media(max-width:600px){.production-cost-group-directions{width:100%;}.production-cost-group-directions button{flex:1;}.production-cost-groups-choose{width:100%;}}
@media(max-width:1000px){.production-cost-analysis-kpis{grid-template-columns:repeat(2,minmax(0,1fr));}.production-cost-analysis-kpis>div:nth-child(2){border:0;}.production-cost-analysis-pair{grid-template-columns:minmax(0,1fr);}}
@media(max-width:600px){.production-cost-analysis-section{padding:14px;}.production-cost-analysis-kpis{gap:16px 10px;}.production-cost-analysis-kpis strong{font-size:1.12rem;}html:root .production-filters.production-cost-analysis-filters{grid-template-columns:minmax(0,1fr);}.production-cost-analysis-quality>summary{padding:14px;}.production-cost-analysis-quality>div{padding:0 14px 14px;}}
@media(max-width:700px){html:root .production-cost-analysis-chef :is(th,td)[data-column]{width:auto;}html:root .production-cost-analysis-chef td[data-column=action]{grid-column:1 / -1;}.production-cost-analysis-filter button{flex:1 1 auto;}}
@media(max-width:900px){html:root .production-cost-analysis-chef .production-table td[data-column=action]{grid-column:1 / -1;}}
.production-abc-group{margin-top:18px;border:1px solid var(--border);border-radius:12px;overflow:hidden;}
.production-abc-group h3{margin:0;padding:12px 14px;background:color-mix(in srgb,var(--theme-accent) 9%,var(--surface));font-size:1rem;}
.production-abc-group>summary{display:flex;align-items:center;gap:10px;padding:12px 14px;background:color-mix(in srgb,var(--theme-accent) 9%,var(--surface));cursor:pointer;list-style:none;}
.production-abc-group>summary::before{content:'▸';color:var(--theme-accent);transition:transform var(--motion-reveal) var(--motion-ease);}
.production-abc-group[open]>summary::before{transform:rotate(90deg);}
.production-abc-group>summary::-webkit-details-marker{display:none;}
.production-abc-group>summary h3{padding:0;flex:1;background:transparent;min-width:0;overflow-wrap:anywhere;}
.production-abc-group>summary span{font-size:.82rem;white-space:nowrap;}
.production-abc-body>.production-pagination{padding:12px 14px;border-top:1px solid var(--border);margin:0;}
.production-abc-title{display:grid;gap:4px;min-width:0;flex:1;}
.production-abc-group>summary .production-abc-count{font-size:.76rem;color:var(--text-secondary);}
.production-abc-group-revenue{flex:none;font-size:.94rem;font-variant-numeric:tabular-nums;}
.production-abc-header h2{margin:0;font-size:1.15rem;}
.production-abc-header>a{display:inline-flex;align-items:center;justify-content:center;min-height:36px;padding:7px 12px;border:1px solid var(--border);border-radius:9px;color:var(--theme-accent);font-size:.8rem;text-decoration:none;transition:background-color var(--motion-reveal) var(--motion-ease);}
.production-abc-header>a:hover{background:var(--accent-soft);}
.production-abc>p{margin:12px 0;font-size:.86rem;}
.production-abc-legend{display:flex;flex-wrap:wrap;gap:8px 18px;margin:14px 0 18px;font-size:.76rem;color:var(--text-secondary);}
.production-abc-legend>span{display:flex;align-items:center;gap:7px;}
.production-abc-legend strong{display:grid;place-items:center;width:24px;height:24px;border-radius:7px;background:var(--accent-soft);color:var(--theme-accent);}
.production-abc-legend .production-abc-legend-A{background:color-mix(in srgb,#238362 16%,var(--surface));color:var(--text-primary);}
.production-abc-legend .production-abc-legend-C{background:color-mix(in srgb,#ba7b20 16%,var(--surface));color:var(--text-primary);}
.production-abc .production-abc-group{margin-top:10px;border-radius:14px;}
.production-abc-group>summary{padding:14px 16px;transition:background-color var(--motion-reveal) var(--motion-ease);}
.production-abc-group>summary:hover{background:color-mix(in srgb,var(--theme-accent) 13%,var(--surface));}
.production-abc-group>summary:focus-visible{outline:2px solid var(--theme-accent);outline-offset:-3px;}
.production-abc-classes{display:flex;justify-content:flex-end;flex-wrap:wrap;gap:4px;}
.production-abc-class{display:flex;align-items:center;gap:4px;padding:5px 6px;border-radius:7px;background:var(--accent-soft);color:var(--text-primary);font-variant-numeric:tabular-nums;}
.production-abc-class small{opacity:.75;font-size:.65rem;}
.production-abc-class strong{font-size:.8rem;}
.production-abc-class[data-class="A"]{background:color-mix(in srgb,#238362 16%,var(--surface));}
.production-abc-class[data-class="C"]{background:color-mix(in srgb,#ba7b20 16%,var(--surface));}
.production-abc-class[data-class="unknown"]{background:color-mix(in srgb,var(--text-secondary) 10%,var(--surface));}
.production-abc-group .production-table-scroll :is(th,td){padding:12px 10px;vertical-align:middle;font-size:.82rem;}
.production-abc-group .production-table-scroll th{font-size:.74rem;background:var(--surface);color:var(--text-secondary);}
html:root .production-abc-group .production-table-scroll table thead th{background:color-mix(in srgb,var(--theme-accent) 4%,var(--surface))!important;}
.production-abc-group .production-table-scroll :is(th,td):first-child{position:static;min-width:0;max-width:none;background:transparent;}
html:root .production-abc-group .production-table-scroll .production-table-sort{width:100%;min-height:32px;border-radius:0;font:inherit;font-weight:600;white-space:normal;}
html:root .production-abc-group .production-name{font-size:.86rem;font-weight:600;min-height:32px;line-height:1.45;max-width:100%;}
html:root .production-abc-group .production-table-scroll :is(.production-table-sort,.production-name){background:transparent!important;box-shadow:none!important;border:0!important;}
.production-abc-group .production-name:hover{text-decoration:underline;text-underline-offset:3px;}
.production-abc-group tbody tr{transition:background-color var(--motion-reveal) var(--motion-ease);}
.production-abc-group tbody tr:hover{background:color-mix(in srgb,var(--theme-accent) 4%,var(--surface));}
.production-abc-group .production-abc-warning{color:var(--text-secondary);font-size:.72rem;}
@media(min-width:701px){.production-abc-group .production-table-scroll table{table-layout:fixed;}.production-abc-group .production-table-scroll :is(th,td)[data-column="name"]{width:27%;}.production-abc-group .production-table-scroll :is(th,td)[data-column="abc"]{width:17%;}.production-abc-group .production-table-scroll :is(th,td)[data-column="food_cost"]{width:9%;}.production-abc-group :is(th,td){overflow-wrap:anywhere;}}
@media(max-width:700px){.production-abc{padding:14px;}.production-abc-header{gap:8px;}.production-abc-header h2{margin-right:auto;}.production-abc-header>a{min-height:44px;}.production-abc-legend{gap:8px 12px;}.production-abc-group>summary{padding:12px;gap:8px;}.production-abc-group-revenue{font-size:.82rem;}.production-abc-group .production-table-scroll :is(th,td){padding:6px 12px;}.production-abc-group .production-table-scroll tr{padding:12px 0;}.production-abc-group .production-table-scroll td::before{color:var(--text-secondary);font-weight:400;font-size:.8rem;}.production-abc-group .production-table-scroll td[data-column="name"]{margin-bottom:6px;}.production-abc-group .production-table-scroll .production-name{min-height:44px;}.production-abc-group .production-table-scroll td[data-column="name"] small{padding-bottom:6px;}}
.production-catalog-actions { justify-content:flex-start;gap:8px; }
.production-catalog-actions h2 { margin:0 auto 0 0;font-size:1.05rem; }
.production-catalog-sort { display:flex;align-items:flex-end;gap:8px 14px;flex-wrap:wrap;margin:16px 0; }
.production-catalog-sort label { display:grid;gap:5px;margin:0;font-size:.83rem;min-width:0; }
.production-catalog-sort :is(select,button) { margin:0; }
.production-catalog-sort label:last-child { margin-left:auto; }
.production-catalog-group { margin-top:10px;border:1px solid var(--border);border-radius:12px;min-width:0;overflow:hidden; }
.production-catalog-group>summary { display:flex;align-items:center;gap:10px;padding:12px 14px;cursor:pointer;list-style:none;background:color-mix(in srgb,var(--theme-accent) 6%,var(--surface)); }
.production-catalog-group>summary::-webkit-details-marker { display:none; }
.production-catalog-group>summary::before { content:'▸';flex:none;color:var(--theme-accent);transition:transform var(--motion-reveal) var(--motion-ease); }
.production-catalog-group[open]>summary::before { transform:rotate(90deg); }
.production-catalog-group>summary h3 { margin:0;min-width:0;flex:1;overflow-wrap:anywhere;font-size:.94rem; }
.production-catalog-group>summary span { flex:none;font-size:.78rem; }
.production-catalog-body { min-width:0;padding:0 12px 12px; }
.production-catalog-body>.production-catalog-group { margin-left:8px; }
.production-catalog-table { min-width:0;padding-top:5px; }
.production-catalog-table table { table-layout:fixed; }
.production-catalog-table :is(th,td) { overflow-wrap:anywhere; }
.production-catalog-table :is(th,td):first-child { width:29%;min-width:0; }
.production-catalog-table :is(th,td):nth-child(2) { width:25%; }
.production-group-meta { display:flex;align-items:center;justify-content:flex-end;gap:6px 10px;flex-wrap:wrap;min-width:0; }
.production-group-meta .production-group-edit { margin:0;flex:none;white-space:nowrap; }
html:root .production-catalog-table th button { background:transparent;border:0;box-shadow:none;padding:0;white-space:normal; }
.production-catalog-body>.production-pagination { margin-top:8px;padding-top:10px; }
@media(max-width:700px) { .production-catalog { padding:14px; }.production-catalog-sort label:last-child { margin-left:0; }.production-catalog-sort label:first-child { flex:1; }.production-catalog-actions h2 { flex-basis:100%; }.production-catalog-actions button { flex:1; }.production-catalog-body { padding:0 8px 8px; }.production-catalog-body>.production-catalog-group { margin-left:0; }.production-catalog-group>summary { padding:11px 10px;gap:8px; }.production-catalog-table :is(th,td):first-child,.production-catalog-table :is(th,td):nth-child(2) { width:auto; }.production-catalog-table td { align-items:center;gap:8px; }.production-catalog-table td::before { flex:none;white-space:nowrap; }.production-catalog-table .production-group-meta { flex:1; } }
.production-abc>.production-actions>label{display:flex;align-items:center;gap:8px;margin:0 0 0 auto;font-size:.85rem;}
.production-abc>.production-actions select{width:auto;min-width:76px;}
.production-monthly .production-group-edit{display:block;margin-top:6px;padding:3px 8px;min-height:28px;font-size:.78rem;}
.production-monthly :is(th,td):nth-child(2){text-align:left;}
.production-monthly th button{border:0;background:transparent;box-shadow:none;padding:6px 0;min-height:0;font-weight:700;text-align:inherit;}
.production-list-sort{display:none;}
@media(max-width:700px){.production-list-sort{display:flex;align-items:flex-end;gap:8px;margin-top:12px;}.production-list-sort>label{flex:1;display:grid;gap:5px;min-width:0;font-size:.85rem;}.production-list-sort>button{flex:0 0 42px;}.production-abc>.production-actions>label{margin-left:0;}}
.production-dish-name{display:flex;align-items:center;gap:8px;min-width:0;}
.production-dish-name>.production-name{flex:1;min-width:0;overflow-wrap:anywhere;}
@media(min-width:701px){.production-abc-group table{table-layout:fixed;}.production-abc-group :is(th,td):first-child{width:28%;}.production-abc-group :is(th,td){overflow-wrap:anywhere;}}
html:root .production-move{flex:0 0 36px;width:36px;padding:0;}
.production-dialog-search{display:flex;gap:10px;align-items:flex-end;margin:16px 0;}
.production-abc-filter-form { display:grid;gap:14px;min-width:0; }
.production-abc-filter-form>p { margin:0; }
.production-abc-filter-form>label:not(.production-abc-filter-all) { display:grid;gap:6px;min-width:0; }
.production-abc-filter-all,.production-abc-group-options>label { display:flex;align-items:center;gap:10px;min-width:0;margin:0; }
.production-abc-filter-form input[type="checkbox"] { width:20px;height:20px;flex:0 0 20px;margin:0; }
.production-abc-group-options { display:grid;gap:4px;max-height:min(340px,35dvh);overflow:auto;border:1px solid var(--border);border-radius:12px;padding:8px; }
.production-abc-group-options>label { min-height:44px;padding:8px;border-radius:8px;overflow-wrap:anywhere; }
.production-abc-group-options>label:hover { background:var(--accent-soft); }
.production-abc-filter-form>.production-actions { justify-content:flex-end; }
html:root .production-group-filter[aria-pressed="true"] { background:var(--accent-soft);border-color:var(--accent); }
.production-dialog-search label{display:grid;gap:6px;flex:1;min-width:0;margin:0;}
.production-supplier-body{min-width:0;}
.production-product-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 0;border-bottom:1px solid var(--border);}
.production-product-row>div{min-width:0;overflow-wrap:anywhere;}
.production-product-row small{display:block;color:var(--text-secondary);margin-top:5px;}
.production-monthly h2{margin:0;font-size:1.2rem;}
.production-monthly .production-table-scroll{margin-top:16px;}
.production-monthly td small{margin-top:5px;color:var(--text-secondary);font-size:.78rem;}
@media(min-width:701px){.production-monthly table{table-layout:fixed;}.production-monthly :is(th,td):first-child{width:30%;}.production-monthly :is(th,td):nth-child(2){width:24%;}.production-monthly :is(th,td){overflow-wrap:anywhere;}}
.production-product-options{display:grid;gap:6px;margin-top:12px;max-height:320px;overflow-y:auto;}
.production-product-options button{white-space:normal;text-align:left;overflow-wrap:anywhere;}
.production-price-dialog{width:min(780px,calc(100vw - 32px));}
.production-price-summary{display:flex;align-items:baseline;justify-content:space-between;gap:12px;margin:18px 0 8px;flex-wrap:wrap;}
.production-price-summary strong{font-size:1.35rem;}
.production-price-chart svg{display:block;width:100%;height:auto;overflow:visible;}
.production-price-grid{stroke:var(--border);stroke-width:1;}
.production-price-axis{fill:var(--text-secondary);font-size:12px;font-variant-numeric:tabular-nums;}
.production-price-line{stroke:var(--theme-accent);stroke-width:3;stroke-linejoin:round;stroke-linecap:round;stroke-dasharray:1;stroke-dashoffset:0;animation:production-price-draw 900ms var(--motion-ease);}
.production-price-line{stroke:var(--price-color,var(--theme-accent));}
.production-price-point{fill:var(--surface);stroke:var(--theme-accent);stroke-width:3;cursor:pointer;}
.production-price-point{stroke:var(--price-color,var(--theme-accent));}
.production-price-point:is(:hover,:focus){fill:var(--theme-accent);outline:none;stroke-width:5;}
.production-price-point:is(:hover,:focus){fill:var(--price-color,var(--theme-accent));}
.production-price-readout{min-height:2.8em;padding:10px 12px;border-radius:10px;background:color-mix(in srgb,var(--theme-accent) 7%,var(--surface));font-variant-numeric:tabular-nums;}
.production-price-history{max-height:280px;overflow:auto;margin-top:14px;}
.production-product-history-dialog{width:min(1100px,calc(100vw - 32px));}
.production-product-history-dialog .production-price-body{min-width:0;}
.production-purchase-totals{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:10px;padding:12px 14px;border:1px solid var(--border);border-radius:12px;background:var(--accent-soft);}
.production-price-chart{position:relative;min-width:0;}
.production-price-legend{display:flex;flex-wrap:wrap;gap:6px;margin:12px 0;}
html:root .production-price-legend button{display:inline-flex;align-items:center;gap:7px;padding:5px 9px;min-height:32px;max-width:100%;border-radius:8px;font-size:.8rem;text-align:left;overflow-wrap:anywhere;}
.production-price-legend button::before{content:'';width:8px;height:8px;flex-shrink:0;border-radius:50%;background:var(--price-color);}
.production-price-tooltip{position:absolute;z-index:3;display:grid;gap:4px;width:max-content;max-width:min(310px,100%);padding:12px 14px;border:1px solid var(--border);border-radius:12px;background:var(--surface-solid,var(--surface));color:var(--text-primary);box-shadow:var(--shadow-dropdown);pointer-events:none;font-size:.82rem;overflow-wrap:anywhere;font-variant-numeric:tabular-nums;}
.production-price-tooltip[hidden]{display:none;}
.production-price-tooltip strong{font-size:.88rem;}
.production-product-suppliers{margin-top:24px;border-top:1px solid var(--border);padding-top:16px;min-width:0;}
.production-product-suppliers h3{font-size:1rem;margin:0 0 14px;}
.production-purchase-table{width:100%;table-layout:fixed;border-collapse:collapse;font-size:.82rem;}
.production-purchase-table :is(th,td){padding:12px 9px;text-align:left;vertical-align:top;border-bottom:1px solid var(--border);overflow-wrap:anywhere;}
.production-purchase-table th{background:var(--accent-soft);font-size:.78rem;color:var(--text-secondary);}
html:root .production-purchase-table .production-table-sort{display:block;width:100%;min-height:32px;padding:0;border:0;background:transparent;box-shadow:none;color:var(--theme-accent);font:inherit;font-weight:600;text-align:left;white-space:normal;}
.production-purchase-table .production-table-sort:hover{text-decoration:underline;}
.production-dish-composition{margin:16px 0;}
.production-purchase-table.production-dish-ingredients :is(th,td):first-child{width:60%;}
.production-purchase-table.production-dish-ingredients :is(th,td):nth-child(2){width:20%;text-align:left;}
html:root .production-product-kinds{justify-content:flex-start;}
html:root .production-product-kinds button[aria-current="true"]{background:var(--theme-accent);color:var(--theme-on-accent,#fff);border-color:var(--theme-accent);}
@media(max-width:700px){.production-purchase-table.production-dish-ingredients td:nth-child(3){grid-row:2;grid-column:2;}}
.production-purchase-table :is(th,td):first-child{width:24%;}
.production-purchase-table :is(th,td):nth-child(2){width:9%;text-align:center;}
html:root .production-purchase-table .production-name{white-space:normal;text-align:left;font-weight:600;font-size:.84rem;padding:0;min-height:32px;max-width:100%;border:0;background:transparent;box-shadow:none;color:var(--theme-accent);}
.production-purchase-table .production-name:hover{text-decoration:underline;}
.production-purchase-table td>small{display:block;margin-top:4px;}
.production-supplier-products-dialog{width:min(1100px,calc(100vw - 32px));}
.production-supplier-products-table [data-column="actions"]{width:46px;text-align:center;padding-inline:5px;}
html:root .production-unlink{display:grid;place-items:center;width:36px;height:36px;min-height:36px;padding:0;background:transparent;border:0;box-shadow:none;color:var(--text-secondary);}
.production-unlink svg{width:18px;height:18px;}
html:root .production-unlink:hover{color:var(--danger);background:color-mix(in srgb,var(--danger) 8%,var(--surface));}
.production-purchase-unit{display:grid;gap:3px;margin-bottom:8px;font-variant-numeric:tabular-nums;}
.production-purchase-unit:last-child{margin-bottom:0;}
.production-purchase-unit strong{font-weight:600;}
@media(max-width:700px){
 .production-product-history-dialog,.production-supplier-products-dialog{width:calc(100vw - 16px);}
 .production-purchase-table,.production-purchase-table tbody{display:block;}
 .production-purchase-table thead{display:none;}
 .production-purchase-table tr{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;padding:14px 0;border-bottom:1px solid var(--border);}
 .production-purchase-table :is(th,td){display:block;width:auto!important;padding:0;border:0;text-align:left!important;}
 .production-purchase-table td::before{content:attr(data-label);display:block;margin-bottom:5px;color:var(--text-secondary);font-size:.76rem;}
 .production-purchase-table td:first-child{grid-column:1 / -1;}
 .production-purchase-table td:nth-child(2){grid-row:2;grid-column:1;}
 .production-purchase-table td:nth-child(5){grid-row:2;grid-column:2;}
 .production-purchase-table td:nth-child(3){grid-row:3;grid-column:1;}
 .production-purchase-table td:nth-child(4){grid-row:3;grid-column:2;}
 .production-purchase-table td:nth-child(6){grid-row:4;grid-column:1 / -1;}
 .production-supplier-products-table td[data-column="amount"]{grid-row:2;grid-column:2;}
 .production-supplier-products-table td[data-column="last"]{grid-row:3;grid-column:1 / -1;}
 .production-supplier-products-table td[data-column="firstPrice"]{grid-row:4;grid-column:1;}
 .production-supplier-products-table td[data-column="lastPrice"]{grid-row:4;grid-column:2;}
 .production-supplier-products-table td[data-column="actions"]{grid-row:1;grid-column:2;justify-self:end;}
 .production-supplier-products-table tr:has(td[data-column="actions"]) td:first-child{grid-row:1;grid-column:1;}
 html:root .production-purchase-table .production-name,html:root .production-price-legend button{min-height:44px;}
 html:root .production-unlink{width:44px;height:44px;min-height:44px;}
}
@keyframes production-price-draw{from{stroke-dashoffset:1;}to{stroke-dashoffset:0;}}
@media(prefers-reduced-motion:reduce){.production-price-line{animation:none;}}
@media(max-width:700px){.production-dialog-search{flex-wrap:wrap;}.production-product-row{align-items:flex-start;}.production-price-dialog{width:calc(100vw - 16px);}.production-move{min-height:44px;min-width:44px;}.production-price-summary strong{font-size:1.15rem;}.production-price-axis{font-size:22px;}}
.production-tabs,.production-actions,.production-pagination { display:flex;align-items:center;gap:10px;flex-wrap:wrap; }
.production-tabs { padding:12px; }
:root .production-tabs button[aria-current="true"] { background:var(--theme-accent);color:var(--theme-on-accent,#fff); }
.production-refresh { margin-left:auto; }
.production-filters { display:flex;align-items:flex-end;gap:14px 12px;flex-wrap:wrap;padding:18px; }
.production-filters label { display:grid;gap:6px;flex:1 1 170px;min-width:0;margin:0;font-size:.85rem;line-height:1.3; }
.production-filters :is(input,select) { width:100%;min-width:0;height:46px;min-height:46px;margin:0;font-size:.9rem;line-height:1.3; }
.production-filter-actions { display:flex;gap:8px;align-items:center;flex:0 0 auto; }
.production-filters :is(button,.production-filter-actions button) { height:46px;min-height:46px;padding:8px 16px;margin:0; }
.production-filters details { flex-basis:100%; }
.production-filters>details { order:1; }
.production-extra-filters { display:flex;flex-wrap:wrap;gap:12px;align-items:end;padding-top:12px; }
.production-source { display:flex;flex-wrap:wrap;gap:8px 24px;font-size:.84rem;padding:14px 18px;line-height:1.5; }
.production-source:is(details) { display:block; }
.production-source:is(details) p { margin-top:10px; }
.production-source p { margin:0;flex-basis:100%; }
.production-kpis { display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:12px; }
.production-kpis section { display:grid;gap:12px;margin:0; }
.production-kpis strong { font-size:1.5rem;line-height:1.3;overflow-wrap:anywhere;font-variant-numeric:tabular-nums; }
.production-overview { display:grid;grid-template-columns:minmax(250px,300px) minmax(0,1fr);gap:16px;align-items:stretch; }
html:root .production-overview :is(.production-overview-metrics,.production-purchase-chart) { margin:0;min-width:0;padding:16px; }
.production-overview-metrics { display:flex;flex-direction:column; }
.production-overview-metrics header { display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:2px; }
.production-overview h2 { margin:0;font-size:1rem; }
html:root .production-info { flex:none;width:30px;height:30px;min-height:30px;padding:0;border-radius:50%;font:italic 1rem Georgia,serif; }
.production-metric-row { display:grid;flex:1;align-content:center;gap:4px;padding:10px 0;border-bottom:1px solid var(--border); }
.production-metric-row:last-child { border-bottom:0;padding-bottom:0; }
.production-metric-row span { color:var(--text-secondary);font-size:.86rem;line-height:1.4; }
.production-metric-row strong { color:var(--text-primary);font-size:1.35rem;line-height:1.25;font-variant-numeric:tabular-nums;overflow-wrap:anywhere; }
.production-cost-note { grid-column:1/-1;color:var(--text-secondary);font-size:.74rem;line-height:1.45;overflow-wrap:anywhere; }
.production-purchase-chart { display:flex;flex-direction:column;background:var(--surface); }
.production-purchase-chart h3 { font-size:1rem;line-height:1.4; }
.production-purchase-chart p { margin-bottom:8px;font-size:.8rem;line-height:1.4; }
.production-purchase-summary { display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin:0;padding:9px 0;border-block:1px solid var(--border);font-size:.86rem; }
.production-purchase-summary strong { font-size:1.15rem;font-variant-numeric:tabular-nums; }
.production-purchase-chart .analytics-plot { margin:8px 0 0;padding-top:56px; }
.production-purchase-chart .analytics-chart-hint { top:16px;left:0; }
.production-purchase-chart .analytics-axis { font-size:12px; }
.production-purchase-chart .analytics-bar { transform-box:fill-box;transform-origin:center bottom;animation:production-purchase-rise 700ms var(--motion-ease,ease-out) both; }
.production-purchase-chart .is-resizing .analytics-bar { animation:none; }
.production-purchase-chart .analytics-tooltip-state { font-size:.72rem;line-height:1.4; }
.production-problems { padding:0; }
.production-problems>summary { cursor:pointer;padding:12px 16px;min-height:44px;font-size:.9rem;font-weight:650; }
.production-problems-body { padding:0 16px 4px; }
.production-problems-body>.production-problem:first-child { border-top:1px solid var(--border); }
.production-problems-body>.production-problem:last-child { border-bottom:0; }
@keyframes production-purchase-rise { from { transform:scaleY(0);opacity:0; } to { transform:scaleY(1);opacity:.75; } }
@media(max-width:850px) { .production-overview { grid-template-columns:1fr; } .production-overview-metrics { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 20px; } .production-overview-metrics header { grid-column:1/-1; } .production-metric-row span { display:flex;align-items:end;min-height:2.8em; } .production-metric-row strong { font-size:1.3rem; } .production-purchase-chart .analytics-chart-tooltip { gap:2px 8px; } }
@media(max-width:480px) { .production-overview-metrics { display:flex; } .production-metric-row { flex:none;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:center;padding:12px 0; } .production-metric-row span { display:block;min-height:0; } .production-metric-row strong { font-size:1.1rem;white-space:nowrap; } html:root .production-info { width:44px;height:44px;min-height:44px;min-width:44px; } .production-problems>summary { padding:16px; } .production-problems-body { padding:0 16px 8px; } .production-purchase-chart .analytics-tooltip-value { font-size:.9rem; } .production-purchase-chart .analytics-chart-tooltip { padding:8px; } }
@media(prefers-reduced-motion:reduce) { .production-purchase-chart .analytics-bar { animation:none; } }
.production-problem { display:flex;justify-content:space-between;gap:16px;align-items:center;padding:10px 0;border-bottom:1px solid var(--border); }
.production-problem>div { min-width:0;overflow-wrap:anywhere; }
.production-problem-info { display:grid;gap:2px; }
.production-problem-heading { display:flex;flex-wrap:wrap;align-items:center;gap:4px 8px;min-width:0; }
.production-problem .production-problem-reason { margin:0;color:var(--text-secondary);font-size:.76rem;line-height:1.45; }
.production-problem-status { flex:none;padding:2px 7px;border:1px solid var(--border);border-radius:20px;color:var(--text-secondary);font-size:.65rem;line-height:1.3;white-space:nowrap; }
html:root .production-problem-name { min-width:0;max-width:100%;min-height:24px;margin:0;padding:0;border:0;border-radius:4px;background:transparent;box-shadow:none;color:var(--accent);font:inherit;font-size:.84rem;font-weight:650;line-height:1.4;text-align:left;white-space:normal;overflow-wrap:anywhere; }
/* Theme button surfaces must not turn dish links into white rectangular pills. */
html:root .production-problems .production-problem-name { background:transparent!important;border:0!important;box-shadow:none!important; }
html:root .production-problem-action { flex:none;min-height:var(--control-height,36px);margin:0;padding:6px 12px;font-size:.78rem;line-height:1.4; }
html:root .production-problem-name:hover:not(:disabled) { background:transparent;text-decoration:underline;text-underline-offset:3px; }
html:root .production-problem-name:focus-visible { outline:2px solid var(--accent);outline-offset:3px; }
@media(pointer:coarse) { html:root .production-problem-name { min-height:44px; } }
@media(max-width:480px) {
  .production-problems>summary { padding:12px 14px; }
  .production-problems-body { padding:0 14px 4px; }
  .production-problem { display:grid;grid-template-columns:minmax(0,1fr) auto;gap:4px 10px; }
  .production-problem-info { display:contents; }
  .production-problem-heading { grid-column:1 / -1; }
  .production-problem-reason { grid-column:1; }
  .production-problem-action { grid-column:2;grid-row:2;align-self:center; }
  html:root .production-problem-name { min-height:44px; }
}
.production-actions { justify-content:space-between; }
.production-table-scroll { overflow-x:auto;max-width:100%; }
.production-table-scroll table { width:100%;border-collapse:collapse;font-variant-numeric:tabular-nums; }
.production-table-scroll :is(th,td) { padding:9px 10px;border-bottom:1px solid var(--border);text-align:right;font-size:.88rem; }
.production-table-scroll th:first-child,.production-table-scroll td:first-child { text-align:left;position:sticky;left:0;background:var(--surface);min-width:220px;max-width:300px;z-index:1; }
.production-table-scroll td small { display:block; }
.production-table-scroll th button { border:0;padding:0;background:transparent;color:inherit;box-shadow:none;text-align:inherit;min-height:36px; }
.production-table-scroll .production-name { padding:0;border:0;box-shadow:none;background:transparent;color:var(--theme-accent);text-align:left;white-space:normal; }
.production-pagination { padding-top:16px; }
.production-pagination label { display:flex;align-items:center;gap:8px;margin-left:auto; }
.production-pagination select { width:auto; }
.production-dialog { width:min(900px,calc(100vw - 40px));max-height:min(800px,calc(100dvh - 48px));padding:22px;border:1px solid var(--border);border-radius:20px;background:var(--surface);color:var(--text-primary);box-shadow:0 24px 90px #0005;overflow:auto; }
.production-dialog::backdrop { background:#13203466;opacity:1;transition:opacity var(--motion-window) var(--motion-ease); }
.production-dialog[hidden]::backdrop { opacity:0; }
@starting-style { .production-dialog[open]::backdrop { opacity:0; } }
.production-dialog>header { position:sticky;top:-22px;padding:8px 0;background:var(--surface);z-index:3; }
.production-dialog header h2 { margin:0;max-width:calc(100% - 60px);font-size:1.2rem; }
.production-dialog header button { width:40px;height:40px;padding:0;font-size:1.4rem; }
.production-form { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin-top:16px; }
.production-form label { display:grid;gap:6px;align-content:start;min-width:0;margin:0; }
.production-form :is(input,select,textarea) { width:100%;min-width:0; }
.production-form textarea { min-height:90px; }
.production-form>button { justify-self:start;grid-column:1/-1; }
.production-details { display:grid;grid-template-columns:1fr 1fr;gap:10px; }
.production-details dd { margin:0;text-align:right;font-variant-numeric:tabular-nums; }
.production-access { margin-top:24px;border-top:1px solid var(--border);padding-top:16px; }
.production-access>p { max-width:70ch;font-size:.85rem;line-height:1.6; }
.production-access-status { margin:8px 0 0;font-size:.76rem;line-height:1.5;color:var(--text-secondary); }
.production-access-error { color:var(--theme-danger,#b83249); }
html:root .production-access .crm-route-table :is(th,td)[data-column="restaurant"] { width:34%; }
html:root .production-access .crm-route-table :is(th,td)[data-column="people"] { width:66%; }
@media(max-width:900px) {
  html:root .production-access .crm-route-table tbody tr { grid-template-columns:minmax(0,1fr); }
  html:root .production-access .crm-route-table tbody tr>td { min-height:0; }
  html:root .production-access .crm-route-table td[data-column="people"]::before { margin-bottom:10px; }
}
@media(max-width:700px) { .production-form { grid-template-columns:1fr; }.production-dialog { width:calc(100vw - 16px);padding:16px;max-height:calc(100dvh - 24px); }.production-dialog>header{top:-16px;}.production-problem { align-items:flex-start; }.production-kpis{grid-template-columns:repeat(2,minmax(0,1fr));}.production-kpis strong{font-size:1.12rem;}.production-table-scroll :is(table,thead,tbody,tr,td){display:block;}.production-table-scroll thead{display:none;}.production-table-scroll tr{padding:10px 0;border-bottom:1px solid var(--border);}.production-table-scroll td{display:flex;justify-content:space-between;text-align:right;border:0;}.production-table-scroll td::before{content:attr(data-label);text-align:left;font-weight:600;padding-right:10px;}.production-table-scroll td:first-child{position:static;max-width:none;display:block;min-width:0;}.production-table-scroll td:first-child::before{display:none;} }
.production-plan-dialog{width:min(1100px,calc(100vw - 48px));}
.production-plan-body,.production-plan-list{min-width:0;}
.production-plan-loading{position:sticky;bottom:0;display:flex;align-items:center;justify-content:center;gap:12px;padding:10px;background:var(--surface);border:1px solid var(--border);border-radius:12px;z-index:4;}
.production-plan-loading .analytics-loading-orbit{width:52px;height:52px;}
.production-plan-loading .analytics-loading-character{width:40px;height:40px;}
.production-plan-row{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:16px;align-items:center;padding:16px 0;border-bottom:1px solid var(--border);}
.production-plan-row strong,.production-plan-row small{display:block;overflow-wrap:anywhere;}
.production-plan-row small,.production-plan-history small{font-size:.85rem;color:var(--text-secondary);margin-top:6px;}
.production-plan-badge{display:inline-flex;align-items:center;padding:5px 12px;border-radius:20px;font-size:.83rem;background:color-mix(in srgb,var(--text-primary) 8%,var(--surface));white-space:nowrap;}
.production-plan-badge:is(.planned,.completed,.received){color:var(--text-primary);background:color-mix(in srgb,#53b783 22%,var(--surface));}
.production-plan-badge:is(.in_progress,.ordered,.partial){background:color-mix(in srgb,#de9b51 22%,var(--surface));}
.production-plan-badge.cancelled{opacity:.65;}
.production-plan-wide{grid-column:1/-1;min-width:0;}
.production-plan-line{display:grid;grid-template-columns:minmax(0,1fr) minmax(100px,140px) 40px;align-items:center;gap:12px;padding:10px 0;border-bottom:1px solid var(--border);}
.production-plan-line>div{overflow-wrap:anywhere;}
.production-plan-line>button{padding:0;width:36px;height:36px;}
.production-plan-picker{background:color-mix(in srgb,var(--theme-accent) 5%,var(--surface));padding:16px;border:1px solid var(--border);border-radius:14px;}
.production-plan-options{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;margin-top:10px;max-height:240px;overflow-y:auto;}
.production-plan-options button{text-align:left;white-space:normal;overflow-wrap:anywhere;min-width:0;font-size:.87rem;box-shadow:none;}
.production-plan-options small{grid-column:1/-1;}
.production-plan-footer,.production-plan-controls{display:flex;gap:10px;flex-wrap:wrap;margin-top:18px;padding:12px 0;}
.production-plan-editor .production-plan-footer{position:sticky;bottom:-22px;background:var(--surface);border-top:1px solid var(--border);justify-content:flex-end;z-index:2;}
.production-plan-table input{max-width:120px;min-width:85px;width:100%;}
.production-plan-history{border-top:1px solid var(--border);padding-top:14px;margin-top:16px;}
.production-plan-history p>*{display:block;margin-top:4px;}
.production-plan-warning{border-left:3px solid #c68a49;padding:12px;background:color-mix(in srgb,#de9b51 12%,var(--surface));border-radius:8px;}
.production-shortage{color:var(--text-primary);background:color-mix(in srgb,#de9b51 18%,var(--surface));border-radius:6px;padding:3px 6px;}
.production-form-error{color:var(--danger,#ae3d32);background:var(--surface);padding:10px;border:1px solid currentColor;border-radius:8px;grid-column:1/-1;}
.production-calculating::before{content:'◌';display:inline-block;margin-right:8px;animation:production-spin 1s linear infinite;}
@keyframes production-spin{to{transform:rotate(360deg);}}
@media(max-width:700px){.production-plan-dialog{width:calc(100vw - 16px);}.production-plan-row{grid-template-columns:minmax(0,1fr) auto;gap:10px;}.production-plan-row>div{grid-column:1/-1;}.production-plan-line{grid-template-columns:minmax(0,1fr) 90px 32px;gap:8px;}.production-plan-options{grid-template-columns:1fr;}.production-plan-table td{gap:10px;overflow-wrap:anywhere;}.production-plan-editor .production-plan-footer{bottom:-16px;}.production-plan-footer button{flex:1 1 auto;}}
@media(prefers-reduced-motion:reduce){.production-calculating::before{animation:none;}}
@media(prefers-reduced-motion:reduce){.production-dialog::backdrop{transition:none;}}
@media(max-width:700px) { .production-filters { padding:14px; }.production-filters label { flex-basis:calc(50% - 12px); }.production-filters label:has(input[name="q"]) { flex-basis:100%; }.production-filter-actions { width:100%;justify-content:flex-end; }.production-extra-filters label { flex-basis:100%; }.production-tabs { gap:8px; }.production-tabs button { flex:1 1 auto;min-width:0;font-size:.87rem; }.production-pagination { gap:8px; }.production-pagination label { margin-left:0; }.production-pagination>span { font-size:.85rem; } }
@media(max-width:420px) { .production-filters label { flex-basis:100%; }.production-filter-actions button { flex:1; }.production-filters>button { width:100%; } }

/* One table language for ABC, the catalogs and all production cards. */
html:root .production-table {
  width:100%;table-layout:fixed;border-collapse:separate;border-spacing:0;
  border:1px solid var(--border);border-radius:12px;overflow:hidden;
  background:var(--surface);color:var(--text-primary);font-variant-numeric:tabular-nums;
}
html:root .production-table-scroll:has(>.production-table) { border:1px solid var(--border);border-radius:12px; }
html:root .production-table-scroll>.production-table { border:0;border-radius:0; }
html:root .production-table :is(th,td) {
  padding:6px 10px;vertical-align:middle;text-align:left;font-size:.84rem;line-height:1.45;
  border:0;border-bottom:1px solid var(--border);overflow-wrap:anywhere;
  position:static;min-width:0;max-width:none;background:transparent;
}
html:root .production-table thead th {
  background:color-mix(in srgb,var(--theme-accent) 6%,var(--surface))!important;
  color:var(--text-primary);font-size:.76rem;font-weight:600;
}
html:root .production-table tbody tr { transition:background-color var(--motion-reveal) var(--motion-ease); }
html:root .production-table tbody tr:is(:hover,:focus-within) { background:color-mix(in srgb,var(--theme-accent) 5%,var(--surface)); }
html:root .production-table tbody tr:last-child td { border-bottom:0; }
html:root .production-table :is(th,td)[data-align="number"] { text-align:right; }
html:root .production-table :is(th,td)[data-align="text"] { text-align:left; }
html:root .production-table :is(th,td):first-child { width:32%;background:transparent; }
html:root .production-table :is(th,td):nth-child(2) { width:auto; }
html:root .production-table .production-table-sort {
  display:flex;align-items:center;justify-content:flex-start;width:100%;min-height:28px;
  margin:0;padding:0;border:0;border-radius:5px;background:transparent!important;
  box-shadow:none!important;color:inherit;font:inherit;font-weight:600;text-align:inherit;white-space:normal;
}
html:root .production-table [data-align="number"] .production-table-sort { justify-content:flex-end; }
html:root .production-table .production-table-sort:is(:hover,:focus-visible) { color:var(--theme-accent);text-decoration:underline;text-underline-offset:3px; }
html:root .production-table .production-name {
  display:inline-block;min-height:28px;max-width:100%;padding:3px 0;margin:0;
  border:0;background:transparent!important;box-shadow:none!important;
  font-size:.86rem;font-weight:600;line-height:1.5;color:var(--theme-accent);text-align:left;white-space:normal;overflow-wrap:anywhere;
}
html:root .production-table .production-name:is(:hover,:focus-visible) { text-decoration:underline;text-underline-offset:3px; }
html:root .production-table td>small { display:block;margin:3px 0 0;color:var(--text-secondary);font-size:.76rem;line-height:1.45; }
html:root .production-table .production-group-meta { justify-content:flex-start;gap:5px; }
html:root .production-table .production-purchase-unit { gap:3px;margin:0 0 8px; }
html:root .production-table .production-purchase-unit:last-child { margin-bottom:0; }
html:root .production-table .production-purchase-unit small { color:var(--text-secondary);font-size:.75rem; }
html:root .production-table[data-kind="abc"] :is(th,td)[data-column="name"] { width:27%; }
html:root .production-table[data-kind="abc"] :is(th,td)[data-column="abc"] { width:17%; }
html:root .production-table[data-kind="abc"] :is(th,td)[data-column="food_cost"] { width:9%; }
html:root .production-table:is([data-kind="products"],[data-kind="suppliers"]) :is(th,td)[data-column="name"] { width:40%; }
html:root .production-table:is([data-kind="products"],[data-kind="suppliers"]) :is(th,td)[data-column="last_delivery"] { width:19%; }
html:root .production-table[data-kind="dishes"] :is(th,td)[data-column="name"] { width:55%; }
html:root .production-table[data-kind="dishes"] :is(th,td)[data-column="unit"] { width:15%; }
html:root .production-table[data-kind="ingredients"] :is(th,td)[data-column="name"] { width:60%; }
html:root .production-table[data-kind="ingredients"] :is(th,td)[data-column="quantity"] { width:25%; }
html:root .production-table[data-kind="ingredients"] :is(th,td)[data-column="unit"] { width:15%; }
html:root .production-table[data-kind="daily-sales"] :is(th,td)[data-column="name"] { width:76%; }
html:root .production-table:is([data-kind="supplier-products"],[data-kind="product-suppliers"]) :is(th,td)[data-column="name"] { width:32%; }
html:root .production-table:is([data-kind="supplier-products"],[data-kind="product-suppliers"]) :is(th,td)[data-column="deliveries"] { width:8%; }
html:root .production-table[data-kind="supplier-names"] :is(th,td)[data-column="name"] { width:100%; }
html:root .production-catalog-actions { justify-content:flex-start;gap:8px; }

/* Stable card title, content spacing and the shared CRM window controls. */
html:root .production-dialog.crm-standard-window { padding:20px; }
html:root .production-dialog.crm-standard-window:not(.window-maximized):is(.production-dish-dialog,.production-product-history-dialog,.production-supplier-products-dialog) { width:min(1100px,var(--window-width-limit)); }
html:root .production-dialog.crm-standard-window>.window-titlebar {
  top:-20px;margin:-20px -20px 18px;padding:14px 20px;border-bottom:1px solid var(--border);
  background:var(--surface-solid,var(--surface));
}
html:root .production-dialog h3 { margin:20px 0 12px;font-size:1rem;line-height:1.45; }
html:root .production-dialog .production-catalog-group>summary { min-height:44px;padding:10px 14px; }
html:root .production-dialog .production-catalog-group>summary h3 { margin:0;font-size:.92rem;line-height:1.4; }
html:root .production-settings-rules { margin-top:0; }
html:root .production-settings-rules .production-form { margin-top:12px; }
html:root .production-access { margin-top:16px;padding-top:16px; }
html:root .production-access>h3 { margin:0 0 8px; }
html:root .production-access>p { margin:0 0 14px; }
html:root .production-dialog.crm-standard-window:not(.window-maximized):is(.production-dish-dialog,.production-day-dialog) { width:min(820px,var(--window-width-limit)); }
html:root .production-dish-composition { margin:0; }
html:root .production-dish-composition>h3 { margin:0 0 4px; }
html:root .production-dish-composition>p { margin:0 0 12px;font-size:.8rem;line-height:1.5; }
html:root .production-dish-composition>.production-table+p { margin:10px 0 0; }
html:root .production-day-body[aria-busy="true"] { min-height:180px; }
html:root .production-day-body>p { margin:0 0 12px;font-size:.85rem; }
.production-day-summary { display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px;padding-bottom:12px;border-bottom:1px solid var(--border);font-size:.85rem;font-variant-numeric:tabular-nums; }
html:root .production-day-group>.production-catalog-body { padding:0; }
html:root .production-day-group .production-table { border:0;border-radius:0; }
html:root .production-dialog>p.muted { margin:0 0 16px;font-size:.84rem;line-height:1.5; }
html:root .production-dialog :is(.production-price-body,.production-supplier-body,.production-dish-composition) { min-width:0; }
html:root .production-dialog :is(.production-price-body,.production-supplier-body,.production-dish-composition)[aria-busy="true"] { min-height:180px; }
html:root .production-dialog-search { padding:14px;border:1px solid var(--border);border-radius:12px;background:color-mix(in srgb,var(--theme-accent) 4%,var(--surface)); }
html:root .production-supplier-body>.production-actions { margin-bottom:12px; }
html:root .production-supplier-body>.production-actions p { margin:0;font-size:.85rem;color:var(--text-secondary); }
html:root .production-price-chart { margin-top:16px;padding:14px;border:1px solid var(--border);border-radius:14px;background:color-mix(in srgb,var(--theme-accent) 2%,var(--surface)); }
html:root .production-price-chart svg { max-height:260px; }
html:root .production-price-summary { margin:0 0 10px;padding-bottom:12px;border-bottom:1px solid var(--border);font-size:.85rem; }
html:root .production-price-summary strong { font-size:1.3rem;color:var(--theme-accent); }
html:root .production-dialog .production-details { grid-template-columns:minmax(0,1fr) auto;gap:0;margin:12px 0;border:1px solid var(--border);border-radius:12px;overflow:hidden; }
html:root .production-details :is(dt,dd) { padding:11px 14px;border-bottom:1px solid var(--border);margin:0;font-size:.85rem;line-height:1.5; }
html:root .production-details dt { color:var(--text-secondary);background:color-mix(in srgb,var(--theme-accent) 3%,var(--surface)); }
html:root .production-details dd { font-weight:600; }
html:root .production-details :is(dt:nth-last-child(2),dd:last-child) { border-bottom:0; }

@media(max-width:900px) {
  html:root .production-table,html:root .production-table tbody { display:block;width:100%; }
  html:root .production-table thead { display:none; }
  html:root .production-table tbody tr { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px 14px;padding:12px;border-bottom:1px solid var(--border); }
  html:root .production-table tbody tr:last-child { border-bottom:0; }
  html:root .production-table tbody tr>td {
    display:flex;flex-direction:column;align-items:stretch;justify-content:flex-start;grid-area:auto;
    width:auto!important;min-width:0;max-width:none;margin:0;padding:0;border:0;text-align:left;
  }
  html:root .production-table tbody tr>td[data-align] { text-align:left!important; }
  html:root .production-table tbody tr>td:first-child { grid-column:1/-1; }
  html:root .production-table tbody tr>td::before { content:attr(data-label);display:block;margin:0 0 4px;padding:0;font-size:.75rem;font-weight:400;color:var(--text-secondary);text-align:left;white-space:normal; }
  html:root .production-table tbody tr>td:first-child::before { display:none; }
  html:root .production-table .production-name { min-height:44px; }
  html:root .production-table .production-abc-classes { justify-content:flex-start; }
  html:root .production-list-sort { display:flex;align-items:flex-end;gap:8px;margin:12px 0; }
  html:root .production-list-sort>label { flex:1;display:grid;gap:5px;min-width:0;font-size:.84rem; }
  html:root .production-dialog.crm-standard-window { padding:14px; }
  html:root .production-dialog.crm-standard-window>.window-titlebar { top:-14px;margin:-14px -14px 14px;padding:12px 14px; }
  html:root .production-dialog-search { padding:12px;gap:8px; }
  html:root .production-price-chart { padding:10px; }
  html:root .production-dialog .production-details { grid-template-columns:minmax(0,1fr) minmax(0,1fr); }
  html:root .production-details :is(dt,dd) { padding:10px;font-size:.8rem;overflow-wrap:anywhere; }
  html:root .production-table:is([data-kind="ingredients"],[data-kind="daily-sales"]) { display:table; }
  html:root .production-table:is([data-kind="ingredients"],[data-kind="daily-sales"]) thead { display:table-header-group; }
  html:root .production-table:is([data-kind="ingredients"],[data-kind="daily-sales"]) tbody { display:table-row-group; }
  html:root .production-table:is([data-kind="ingredients"],[data-kind="daily-sales"]) :is(thead,tbody) tr { display:table-row;padding:0; }
  html:root .production-table:is([data-kind="ingredients"],[data-kind="daily-sales"]) tr>:is(th,td) { display:table-cell;padding:6px 8px;font-size:.8rem;vertical-align:middle;border-bottom:1px solid var(--border); }
  html:root .production-table:is([data-kind="ingredients"],[data-kind="daily-sales"]) tbody tr>td::before { display:none; }
  html:root .production-table:is([data-kind="ingredients"],[data-kind="daily-sales"]) tbody tr>td[data-align="number"] { text-align:right!important; }
  html:root .production-table:is([data-kind="ingredients"],[data-kind="daily-sales"]) :is(th,td)[data-column="quantity"] { width:90px!important; }
  html:root .production-table[data-kind="ingredients"] :is(th,td)[data-column="unit"] { width:52px!important; }
  html:root .production-table:is([data-kind="ingredients"],[data-kind="daily-sales"]) .production-name { min-height:32px; }
}

/* Menu sales share the existing daily chart controls and production table style. */
.production-sales-overview { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;align-items:stretch; }
.production-sales-overview:has(>.card:only-child) { grid-template-columns:1fr; }
html:root .production-sales-overview>.card { min-width:0;margin:0;padding:16px; }
.production-sales-chart { display:flex;flex-direction:column;background:var(--surface); }
.production-sales-chart h3 { font-size:1rem;line-height:1.4; }
.production-sales-chart>p { margin-bottom:8px;font-size:.8rem;line-height:1.4; }
.production-sales-chart .analytics-plot { margin-block:auto;padding-top:56px; }
.production-sales-chart .analytics-chart-hint { top:16px;left:0; }
.production-sales-chart .analytics-axis { font-size:12px; }
.production-sales-chart .analytics-tooltip-state { font-size:.72rem;line-height:1.4; }
@media(max-width:1000px) { .production-sales-overview { grid-template-columns:1fr; } }
.production-cost-chart .analytics-chart-tooltip.is-interactive { z-index:3;pointer-events:auto; }
.production-cost-chart .analytics-tooltip-content { grid-column:1/-1;min-width:0; }
.production-cost-explanation { display:grid;gap:10px;min-width:0;color:var(--text-primary);font-size:.85rem; }
.production-cost-explanation p { margin:0;font-size:inherit;line-height:1.45;overflow-wrap:anywhere; }
.production-cost-explanation small { display:block;color:var(--text-secondary);font-size:.75rem;line-height:1.45; }
.production-cost-effects { display:grid;grid-template-columns:minmax(0,1fr) auto;gap:5px 12px;margin:0;font-size:.8rem; }
.production-cost-effects dd { margin:0;text-align:right;white-space:nowrap;font-variant-numeric:tabular-nums; }
.production-cost-effects dt { color:var(--text-secondary); }
.production-cost-drivers { display:grid;gap:8px; }
html:root .production-cost-explanation button.production-name { display:inline;width:auto;height:auto;padding:0;min-height:0;min-width:0;border:0;border-radius:0;background:transparent;box-shadow:none;color:var(--theme-accent);text-align:left;white-space:normal;font-size:inherit;line-height:inherit; }
.production-cost-explanation .production-name:is(:hover,:focus-visible) { text-decoration:underline;text-underline-offset:3px; }
.production-cost-chart .production-cost-explanation { gap:6px;font-size:.73rem; }
.production-cost-chart .production-cost-explanation small { font-size:.67rem; }
.production-cost-chart .production-cost-effects { font-size:.7rem; }
html:root .production-cost-more { justify-self:start;padding:5px 10px;min-height:32px;font-size:.75rem; }
.production-cost-day-dialog { width:min(700px,94vw); }
html:root .production-cost-explanation .production-cost-dish { font-weight:600; }
html:root .production-delivery-supplier .production-name { padding:0;min-height:32px;border:0;background:transparent;box-shadow:none;color:var(--theme-accent);text-align:left; }
.production-day-delivery>summary { display:flex;align-items:center;gap:12px; }
.production-day-delivery>summary h3 { flex:1;min-width:0;margin:0;overflow-wrap:anywhere; }
.production-day-delivery>summary>strong { white-space:nowrap;font-variant-numeric:tabular-nums; }
.production-purchases-day-dialog { width:min(960px,var(--window-width-limit)); }
@media(max-width:650px) { .production-day-delivery>summary { flex-wrap:wrap;gap:6px 10px; } .production-day-delivery>summary h3 { flex-basis:100%; } .production-day-delivery>summary>strong { margin-left:auto; } }
@media(pointer:coarse) {
  html:root .production-table .production-name,html:root .production-top-dish { min-height:44px; }
}
