/* Red Sos popup contract. See docs/POPUP_DESIGN_RULES.md. */
.rs-popup{--popup-red:#8b1515;--popup-ink:#1c1917;--popup-muted:#78716c;--popup-line:#e5dfd5;--popup-paper:#faf8f5;font-family:Outfit,Inter,sans-serif!important;box-sizing:border-box}
.rs-popup:not(dialog){padding:24px!important;background:rgba(28,25,23,.65)!important;backdrop-filter:blur(8px);overflow:hidden!important;align-items:center!important;justify-content:center!important}
.rs-popup *{box-sizing:border-box;font-family:Outfit,Inter,sans-serif!important}
.rs-popup [hidden]{display:none!important}
.rs-popup-card{width:min(var(--rs-popup-width,760px),100%)!important;max-width:min(1200px,calc(100vw - 48px))!important;max-height:calc(100dvh - 48px)!important;min-height:0!important;margin:0!important;border:1px solid var(--popup-line)!important;border-radius:26px!important;box-shadow:0 28px 90px #0004!important;overflow:hidden!important;background:#fff!important;animation:rs-popup-enter .2s ease-out!important}
.rs-popup-card:not(#pcm-dialog):not(.bento-modal-box){display:flex!important;flex-direction:column!important}
.rs-popup h2,.rs-popup h3{font-weight:800!important;letter-spacing:-.5px!important;line-height:1.15!important}
.rs-popup-header{padding:20px 24px!important;margin:0!important;flex-shrink:0!important;border-bottom:1px solid var(--popup-line)!important;background:#fff!important;color:var(--popup-ink)!important}
.rs-popup-header h2,.rs-popup-header h3{font-size:28px!important;color:var(--popup-ink)!important}
.rs-popup-header p,.rs-popup-header span:not([class*=badge]){color:var(--popup-muted)}
.rs-popup-header>div>div:first-child:has(>svg){background:#f8eeee!important;color:var(--popup-red)!important;border-color:#ead4d4!important}
.rs-popup-header svg{color:var(--popup-red)}
.rs-popup-body{min-height:0!important;flex:1 1 auto;overflow:auto;padding:20px 24px!important;gap:14px!important}
.rs-popup-footer{flex-shrink:0!important;padding:16px 24px!important;background:var(--popup-paper)!important;border-top:1px solid var(--popup-line)!important;gap:12px!important}
.rs-popup label{font-size:15px!important;font-weight:700!important;line-height:1.3}
.rs-popup input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=hidden]),.rs-popup select,.rs-popup textarea{font-size:16px!important;font-weight:600!important;color:var(--popup-ink);border-color:var(--popup-line)!important;border-radius:11px!important;min-width:0;max-width:100%;accent-color:var(--popup-red)}
.rs-popup input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=hidden]),.rs-popup select{min-height:40px}
.rs-popup textarea{resize:none}
.rs-popup button{font-size:15px!important;font-weight:700!important;line-height:1.2}
.rs-popup :is(button,input,select,textarea,a):focus-visible{outline:2px solid var(--popup-red)!important;outline-offset:3px}
.rs-popup :is(th,td){font-size:15px!important}
.rs-popup small{font-size:13px!important;line-height:1.35!important}
.rs-popup ::-webkit-scrollbar{width:6px;height:6px}.rs-popup ::-webkit-scrollbar-thumb{background:#bcb5ad;border-radius:8px}
.rs-popup-body.rs-bento-form{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;align-content:start;align-items:start!important;gap:14px 18px!important}
.rs-bento-form>section{min-width:0;background:var(--popup-paper);border:1px solid var(--popup-line);border-radius:18px;padding:18px;display:flex;flex-direction:column;gap:14px}
.rs-bento-form>section>h4{font-size:18px;margin:0;color:var(--popup-red)}
.rs-popup .rs-wide{grid-column:1/-1}
#modal-daily-close .rs-popup-body{display:grid!important;grid-template-columns:minmax(0,1.6fr) minmax(0,1fr)!important;align-items:start;gap:14px 18px!important}
#modal-daily-close .rs-popup-body>div:first-child{grid-column:1/-1}
#modal-daily-close .rs-popup-body>div:nth-child(2){grid-column:1;grid-row:2/4;min-width:0}
#modal-daily-close .rs-popup-body>div:nth-child(3){grid-column:2;grid-row:2}
#modal-daily-close .rs-popup-body>div:nth-child(4){grid-column:2;grid-row:3}
.rs-channel-tabs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin-bottom:12px}
.rs-channel-tabs button{padding:10px 6px;border:1px solid var(--popup-line);border-radius:10px;background:var(--popup-paper);color:var(--popup-ink)}
.rs-channel-tabs button[aria-selected=true]{background:var(--popup-red);border-color:var(--popup-red);color:#fff}
#modal-daily-close .rs-channel-panels{display:block!important}
#modal-daily-close .modal-channel-tile{padding:16px!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px!important;border-top-color:var(--popup-red)!important}
#modal-daily-close .modal-channel-tile[hidden]{display:none!important}
#modal-daily-close .modal-channel-tile>div:first-child,#modal-daily-close .modal-channel-tile>div:nth-child(2),#modal-daily-close .modal-channel-tile>div:nth-child(3),#modal-daily-close .modal-channel-tile>small,#modal-daily-close .modal-channel-tile>div:last-child{grid-column:1/-1}
#modal-daily-close .modal-channel-tile>strong{font-size:20px!important}
#modal-invoice-entry th,#modal-invoice-entry td{padding:10px 8px!important}
#modal-stock-item-detail .rs-popup-body{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;align-content:start;align-items:start;gap:14px!important}
#modal-stock-item-detail .rs-popup-body>div:first-child{grid-column:1/-1}
#quick-price-modal .rs-popup-body,#photo-upload-modal .rs-popup-body{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;align-items:start;gap:18px!important}
#photo-upload-modal #pum-img-box{max-height:300px!important}
#modal-doner-operation form{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;padding:24px!important}
#modal-doner-operation form>div:first-child,#modal-doner-operation form>div:last-of-type,#modal-doner-operation form>p{grid-column:1/-1}
#modal-doner-operation fieldset{grid-template-columns:repeat(2,minmax(0,1fr))!important}
.rs-popup .wo-content{padding:18px 24px;gap:14px;max-height:calc(100dvh - 220px)}
.rs-popup .wo-header,.rs-popup .wo-footer{padding:18px 24px}
.rs-popup .wo-card{padding:16px;border-radius:18px}.rs-popup .wo-preview,.rs-popup .wo-products{max-height:220px}
.rs-popup .wo-preview{font:500 15px/1.5 Outfit,sans-serif!important}
.rs-popup .cat-modal-body{padding:18px 24px!important}.rs-popup .cat-modal-dialog{width:min(1200px,100%)!important}
.rs-popup .rs-popup-header p{font-size:15px!important}
dialog.rs-popup{width:min(var(--rs-popup-width,760px),calc(100vw - 48px));max-height:calc(100dvh - 48px);border:1px solid var(--popup-line);border-radius:24px;padding:24px;background:#fff;color:var(--popup-ink)}
dialog.rs-popup::backdrop{background:#1c1917a6;backdrop-filter:blur(8px)}
@keyframes rs-popup-enter{from{opacity:0;transform:translateY(8px) scale(.99)}to{opacity:1;transform:none}}
@media(max-width:760px){.rs-popup:not(dialog){padding:12px!important}.rs-popup-card{max-width:calc(100vw - 24px)!important;max-height:calc(100dvh - 24px)!important;border-radius:20px!important}.rs-popup-header{padding:16px!important}.rs-popup-header h2,.rs-popup-header h3{font-size:23px!important}.rs-popup-body{padding:16px!important}.rs-popup-body.rs-bento-form,#modal-daily-close .rs-popup-body,#modal-invoice-entry .rs-popup-body,#modal-stock-item-detail .rs-popup-body,#quick-price-modal .rs-popup-body,#photo-upload-modal .rs-popup-body{grid-template-columns:1fr!important}.rs-popup-body>*{grid-column:auto!important;grid-row:auto!important}#modal-invoice-entry .rs-popup-body>div:first-child{grid-template-columns:repeat(2,minmax(0,1fr))!important}#modal-doner-operation form{grid-template-columns:1fr!important}.rs-popup .wo-content{max-height:calc(100dvh - 240px)}}
@media(prefers-reduced-motion:reduce){.rs-popup-card,.rs-popup *{animation:none!important;transition:none!important}}

/* Compact, persistent channel navigation; no vertical finance form. */
@media(min-width:761px){
#modal-daily-close .rs-popup-body{grid-template-columns:minmax(0,1.6fr) minmax(0,1fr)!important}
#modal-daily-close .rs-popup-body>div:first-child{grid-column:2;grid-row:1;padding:12px!important}
#modal-daily-close .rs-popup-body>div:nth-child(2){grid-column:1;grid-row:1/4;display:grid;grid-template-columns:150px minmax(0,1fr);gap:10px;align-items:start}
#modal-daily-close .rs-popup-body>div:nth-child(2)>div:first-child{grid-column:1/-1;margin:0!important}
#modal-daily-close .rs-popup-body>div:nth-child(3){grid-column:2;grid-row:2}
#modal-daily-close .rs-popup-body>div:nth-child(4){grid-column:2;grid-row:3}
#modal-daily-close .rs-channel-tabs{grid-template-columns:1fr;margin:0;gap:8px}
#modal-daily-close .rs-channel-tabs button{min-height:48px;text-align:left;padding:12px}
#modal-daily-close .modal-channel-tile{padding:12px!important;gap:8px!important}
#modal-daily-close .modal-channel-tile>small{font-size:12px!important}
#modal-daily-close .rs-popup-body>div:nth-child(3)>div:nth-child(2){padding:12px!important}
#modal-daily-close .rs-popup-body>div:nth-child(3)>div:nth-child(2)>div:first-child{grid-template-columns:repeat(2,minmax(0,1fr))!important}
#modal-expense-entry .rs-bento-form{align-items:stretch!important}
#modal-expense-entry .rs-bento-form>section:last-child{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-content:start;gap:14px}
#modal-expense-entry .rs-bento-form>section:last-child>h4,#modal-expense-entry .rs-bento-form>section:last-child>label:has(#exp-fixed-plan),#modal-expense-entry .rs-bento-form>section:last-child>div:has(#exp-notes){grid-column:1/-1}
#modal-expense-entry .rs-bento-form>section:last-child>div:has(#exp-is-recurring){padding:12px!important;height:100%;gap:8px;min-height:100px}
#modal-expense-entry .rs-bento-form>section:last-child>div:has(#exp-is-recurring)>div>span:first-child{font-size:15px!important}
#modal-expense-entry .rs-bento-form>section:last-child>div:has(#exp-is-recurring)>div>span:last-child{font-size:13px!important}
#category-management-modal #cat-modal-body{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;align-content:start}
#product-management-modal .rs-product-form{grid-template-columns:repeat(6,minmax(0,1fr))!important;max-height:calc(100dvh - 210px);overflow:auto}
}
.rs-popup-header button:has(svg){width:40px!important;height:40px!important;border:1px solid var(--popup-line)!important;border-radius:12px!important;background:var(--popup-paper)!important;flex-shrink:0}
.rs-popup-header p{color:var(--popup-muted)!important}

#modal-daily-close .rs-channel-tabs>div{margin-top:6px;min-width:0}#modal-daily-close .rs-channel-tabs>div label{font-size:13px!important}#modal-daily-close .rs-channel-tabs>div input{font-size:14px!important}


.rs-popup{--accent-muted:#8b1515;--accent-gold:#8b1515;--color-accent:#8b1515;--color-primary:#1c1917;--text-primary:#1c1917;--text-secondary:#78716c;--bg-main:#faf8f5;--border-color:#e5dfd5}
@media(min-width:761px){
#bulk-action-modal .rs-popup-card{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;padding:24px!important}
#bulk-action-modal .rs-popup-card>h3,#bulk-action-modal .rs-popup-card>p,#bulk-action-modal .rs-popup-card>div:last-child{grid-column:1/-1}
#branch-switcher-modal .branch-modal-body{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
#channel-commission-modal-overlay #comm-modal-body{padding:18px 24px!important;max-height:calc(100dvh - 200px)}
#stats-modal-overlay .rs-popup-card>div:nth-child(2),#click-stats-overlay .rs-popup-card>div:nth-child(2){min-height:0!important;max-height:calc(100dvh - 170px);overflow:auto}
#recent-products-overlay .rs-popup-card{height:min(600px,calc(100dvh - 48px))!important}
#notification-detail-modal .rs-popup-body{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;align-content:start}
}

@media(min-width:761px){
#modal-expense-entry .rs-bento-form>section:has(#exp-monthly-total-wrap:not([hidden]))>div:has(#exp-is-recurring){grid-column:1/-1;min-height:64px!important}
#modal-stock-item-detail .rs-bento-form{align-items:stretch!important}
#modal-stock-item-detail .rs-bento-form>section{padding:14px;gap:12px}
#modal-stock-item-detail .rs-bento-form>section>div{padding:12px!important;border-radius:14px!important}
#modal-stock-item-detail #sim-recipes-list{max-height:150px;overflow:auto}
#modal-stock-item-detail .rs-popup-body>div:first-child>div{padding:10px 14px!important}
#modal-stock-item-detail .rs-popup-body>div:first-child>div>span:first-child{font-size:13px!important}
#modal-stock-item-detail .rs-popup-body>div:first-child strong{font-size:24px!important}
#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse){display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;align-items:start}
#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse)>div:first-child{grid-column:1/-1;margin-bottom:0!important}
#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse)>div:nth-child(2){grid-column:1;grid-row:2;margin-bottom:0!important;padding:16px!important}
#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse)>div:nth-child(3){grid-column:1;grid-row:3;margin-bottom:0!important;padding:14px!important}
#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse)>p{grid-column:1;grid-row:4;margin:0}
#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse)>div:last-child{grid-column:2;grid-row:2/5;max-height:360px;overflow:auto;padding:16px!important}
}

@media(min-width:761px){#modal-stock-item-detail .rs-bento-form>section{padding:0;border:0;background:transparent}#modal-stock-item-detail #sim-recipes-list{max-height:100px}#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse){gap:12px}#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse)>p{font-size:12px!important}#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse)>div:nth-child(3){padding:10px 14px!important}}

/* Product forms: photo beside four compact rows; controls remain intact. */
@media(min-width:761px){
#product-management-modal .rs-popup-card{padding:0!important}
#product-management-modal .rs-product-form{grid-template-columns:repeat(12,minmax(0,1fr))!important;gap:10px!important;margin:0!important;padding:16px 24px!important;align-content:start}
#product-management-modal .rs-product-form>div{padding:10px!important}
#product-management-modal .rs-product-form>div:has(#pm-img-box){grid-column:1/5!important;grid-row:1/5}
#product-management-modal #pm-img-box{height:100%!important;min-height:300px}
#product-management-modal .rs-product-form>div:has(#pm-name){grid-column:5/10!important;grid-row:1}
#product-management-modal .rs-product-form>div:has(#pm-price){grid-column:10/13!important;grid-row:1}
#product-management-modal .rs-product-form>div:has(#pm-parent-cat){grid-column:5/9!important;grid-row:2}
#product-management-modal .rs-product-form>div:has(#pm-cat){grid-column:9/13!important;grid-row:2}
#product-management-modal .rs-product-form>div:has(#pm-allergens){grid-column:5/10!important;grid-row:3}
#product-management-modal .rs-product-form>div:has(#pm-calories){grid-column:10/13!important;grid-row:3}
#product-management-modal .rs-product-form>div:has(#pm-desc){grid-column:5/13!important;grid-row:4}
#product-management-modal .rs-product-form>div:has(#pm-desc)>span{display:none!important}
#product-management-modal #pm-desc{height:56px!important}
#product-management-modal .rs-product-form>div:has(#pm-desc-toggle){grid-column:1/5!important;grid-row:5}
#product-management-modal .rs-product-form>div:has(#pm-status-toggle){grid-column:5/9!important;grid-row:5}
#product-management-modal .rs-product-form>div:has(#pm-stock-toggle){grid-column:9/13!important;grid-row:5}
.rs-recipe-layout{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,2fr);align-items:start;gap:18px}
.rs-recipe-aside{display:flex;flex-direction:column;gap:12px;min-width:0}
.rs-recipe-aside>div{padding:14px!important;margin:0!important;flex-wrap:wrap;gap:10px}
.rs-recipe-aside>div:has(#input-quick-recipe-nlp)>div{flex-wrap:wrap;gap:8px}
.rs-recipe-aside #input-quick-recipe-nlp{width:100%;min-width:0;flex-basis:100%!important}
.rs-recipe-layout>div:has(#recipe-items-tbody){min-width:0;margin:0!important}
.rs-recipe-layout>div:has(#recipe-items-tbody)>div:has(table){max-height:400px;overflow:auto!important}
.rs-recipe-layout th,.rs-recipe-layout td{padding:10px 6px!important}
.rs-calculator-layout{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,2fr);align-items:start}
.rs-calculator-layout>div:first-child{padding:16px!important;min-width:0}
.rs-calculator-layout>div:first-child>div:first-child{flex-wrap:wrap;gap:8px}
#smart-recipe-textarea{height:160px!important}
.rs-calc-workspace{min-width:0;display:flex;flex-direction:column;gap:10px}
.rs-calc-workspace>.rs-channel-tabs{grid-template-columns:1fr 1fr;margin:0}
.rs-channel-tabs button[aria-pressed=true]{background:var(--popup-red);color:#fff;border-color:var(--popup-red)}
.rs-calc-workspace>div{padding:14px!important;max-height:410px;overflow:auto}
#smart-calc-eco-section>div:nth-child(2){grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:10px!important}
#smart-calc-eco-section>div:last-child{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:12px!important;padding:14px!important}
:is(#recipe-ingredient-picker-modal,#recipe-product-picker-modal) .rs-popup-card{display:grid!important;grid-template-columns:1fr 1.5fr;gap:14px;padding:24px!important}
:is(#recipe-ingredient-picker-modal,#recipe-product-picker-modal) .rs-popup-header{font-size:26px!important;padding:0!important;border:0!important;grid-column:1;grid-row:1/3}
:is(#recipe-ingredient-picker-modal,#recipe-product-picker-modal) .rs-popup-footer{grid-column:1/-1;padding:14px 0 0!important;background:transparent!important}
#recipe-ingredient-picker-modal label,#recipe-ingredient-picker-modal select{grid-column:2}
#recipe-product-picker-modal p,#recipe-product-picker-modal select{grid-column:2}
}
.rs-popup-header button{color:var(--popup-ink)!important}
@media(min-width:761px){
#product-management-modal .rs-product-form{padding:14px 24px!important;gap:8px!important}
#product-management-modal .rs-product-form>div{padding:8px!important}
#product-management-modal .rs-product-form input:not([type=file]),#product-management-modal .rs-product-form select{height:40px!important}
#product-management-modal #pm-desc{height:44px!important}
#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse){padding-top:16px!important;padding-bottom:16px!important}
}

.rs-popup-card:has(>.rs-popup-header):has(>.rs-popup-body){padding:0!important}
#category-management-modal .rs-popup-card>p{padding:12px 24px;margin:0!important;font-size:15px!important}
@media(min-width:761px){
#category-management-modal #cat-modal-body{grid-template-columns:repeat(3,minmax(0,1fr));margin:0!important}
#bulk-price-modal .rs-popup-body>div:first-child{max-height:min(390px,calc(100dvh - 254px))!important}
#bulk-price-modal .rs-popup-body{align-items:start;align-content:start}
#comm-settings-backdrop .rs-popup-card{display:grid!important;grid-template-columns:1fr 1fr;padding:20px!important;gap:14px}
#comm-settings-backdrop .rs-popup-header,#comm-settings-backdrop .rs-popup-footer{grid-column:1/-1}
#modal-doner-waste .doner-grid{grid-template-columns:minmax(0,1.8fr) minmax(0,1fr)!important;gap:16px!important}
#modal-doner-waste .doner-grid>div:first-child{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px!important}
#modal-doner-waste .doner-grid>div:first-child>div:first-child,#modal-doner-waste .doner-grid>div:first-child>div:nth-child(2),#modal-doner-waste .doner-grid>div:first-child>small,#modal-doner-waste .doner-grid>div:first-child>div:last-child{grid-column:1/-1}
#modal-doner-waste .doner-grid>div:first-child>div{padding:10px!important}
#modal-doner-waste .doner-preview{max-height:calc(100dvh - 240px);overflow:auto;gap:10px!important}
#modal-doner-waste .doner-preview>div{padding:12px!important}
#modal-doner-waste .rs-popup-header h3{font-size:24px!important}
}
@media(max-width:760px){
#product-management-modal .rs-product-form{grid-template-columns:1fr!important;overflow:auto;margin:0!important}
#product-management-modal .rs-product-form>div{grid-column:1!important;grid-row:auto!important}
.rs-recipe-layout,.rs-calculator-layout{display:flex!important;flex-direction:column;min-width:0}
#modal-doner-waste .doner-grid{grid-template-columns:1fr!important}
#branch-switcher-modal .branch-modal-body{grid-template-columns:1fr!important}
}

@media(min-width:761px){
#modal-doner-waste .doner-grid>div:first-child{display:flex!important;flex-direction:column;gap:10px!important}
#modal-doner-waste .rs-doner-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:start;gap:10px}
#modal-doner-waste .rs-doner-fields>div{padding:10px!important;min-width:0}
#modal-doner-waste .rs-doner-fields>div:has(#input-notes){grid-column:1/-1}
#modal-doner-waste .rs-doner-fields label{display:block}
#modal-doner-waste .rs-channel-tabs{grid-template-columns:1fr 1fr;margin:0}
#modal-doner-waste .doner-preview{max-height:430px}
}

@media(min-width:761px){
#modal-doner-waste .doner-grid>div:first-child>div:first-child{display:none!important}
#modal-doner-waste .doner-grid>div:first-child>div:nth-child(2){padding:0!important}
#modal-doner-waste .doner-grid>div:first-child{gap:8px!important}
#modal-doner-waste .rs-channel-tabs{grid-template-columns:repeat(3,minmax(0,1fr))}
#modal-doner-waste .rs-doner-fields:has(#input-carryover){grid-template-columns:1fr 1fr}
#modal-smart-recipe-calculator #smart-recipe-textarea{height:110px!important}
.rs-calc-workspace>div{max-height:360px!important}
.rs-popup-header h4{font-size:24px!important;color:var(--popup-ink)!important}
}

@media(min-width:761px){
#modal-doner-waste .rs-popup-body{padding-top:18px!important;padding-bottom:18px!important}
#comm-modal-body{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,2fr);gap:14px;align-items:start;align-content:start}
#comm-modal-body>div:first-child{grid-column:1;grid-row:1;grid-template-columns:repeat(2,minmax(0,1fr))!important;margin:0!important}
#comm-modal-body>div:nth-child(2){grid-column:1;grid-row:2;padding:12px!important;margin:0!important}
#comm-modal-body>div:nth-child(2)>div:first-child{flex-wrap:wrap;gap:10px}
#comm-modal-body>div:nth-child(2)>div:first-child>div:first-child>span:last-child{display:none}
#comm-sim-strip{grid-template-columns:repeat(2,minmax(0,1fr))!important}
#comm-modal-body>div:nth-child(3){grid-column:2;grid-row:1/3;grid-template-columns:repeat(3,minmax(0,1fr))!important}
.comm-channel-card{padding:12px!important;gap:10px}
.comm-channel-card>div:first-child>div:first-child{align-items:start!important}
.comm-channel-card>div:first-child>div:first-child>div:first-child>div:last-child>span:last-child{display:none}
.comm-channel-card>div:first-child>div:nth-child(2)>div:first-child{flex-direction:column;align-items:start!important;gap:4px}
.comm-channel-card label{font-size:14px!important}
}

@media(min-width:761px){
#channel-bulk-modal-overlay .rs-popup-body{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px!important;align-items:start;align-content:start}
#channel-bulk-modal-overlay .rs-popup-body>div:nth-child(5),#channel-bulk-modal-overlay #bulk-preview-box{grid-column:1/-1}
#comm-modal-body.rs-commission-layout{grid-template-columns:minmax(0,1fr) minmax(0,2fr)}
#comm-modal-body.rs-commission-layout>.rs-commission-aside{grid-column:1;grid-row:1;display:flex;flex-direction:column;gap:12px;min-width:0}
#comm-modal-body.rs-commission-layout>.rs-commission-cards{grid-column:2;grid-row:1;grid-template-columns:repeat(3,minmax(0,1fr))!important;padding:0!important}
.rs-commission-aside>.rs-channel-tabs{grid-template-columns:1fr 1fr;margin:0}
.rs-commission-aside>div{margin:0!important;min-width:0}
.rs-commission-aside>div:first-of-type{grid-template-columns:repeat(2,minmax(0,1fr))!important}
.rs-commission-aside>div:last-of-type>div:first-child{flex-wrap:wrap;gap:10px}
.rs-commission-aside>div:last-of-type>div:first-child>div:first-child>span:last-child{display:none}
.rs-commission-aside #comm-sim-strip{grid-template-columns:repeat(3,minmax(0,1fr))!important}
.comm-channel-card>div:first-child>div:first-child>span:last-child{display:none!important}
.comm-channel-card>div:first-child>div:nth-child(2)>div:first-child>span{display:none!important}
.comm-channel-card{gap:6px;padding:10px!important}
}
@media(max-width:760px){#comm-modal-body.rs-commission-layout{display:flex!important;flex-direction:column;gap:14px}.rs-commission-aside{width:100%}#comm-modal-body.rs-commission-layout>.rs-commission-cards{display:grid!important;grid-template-columns:1fr!important;width:100%}}
#supplier-whatsapp-modal{display:flex!important}
@media(min-width:761px){
#supplier-whatsapp-modal .wo-content{align-items:start}
#supplier-whatsapp-modal .wo-products{max-height:180px!important}
#supplier-whatsapp-modal .wo-card{padding:14px!important}
#supplier-whatsapp-modal .wo-help{font-size:12px!important}
#supplier-whatsapp-modal .wo-preview{min-height:160px;max-height:180px!important}
}
@media(min-width:761px){
#supplier-whatsapp-modal .wo-left>.wo-card:first-child{display:grid;grid-template-columns:110px minmax(0,1fr);align-items:center;gap:12px}
#supplier-whatsapp-modal .wo-left>.wo-card:first-child h3{margin:0}
#supplier-whatsapp-modal .wo-products{max-height:145px!important}
#supplier-whatsapp-modal .wo-content{padding-top:18px!important;padding-bottom:18px!important}
}

/* Upload-first day-end workspace; the existing reconciliation form stays intact. */
#modal-daily-close.dc-upload-flow .dc-upload-body{padding:24px;display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:24px;min-height:0;overflow:auto;color:var(--popup-ink)}
.dc-upload-flow .dc-document{display:flex;flex-direction:column;gap:12px;min-width:0}
#modal-daily-close .dc-dropzone{position:relative;width:100%;min-height:330px;aspect-ratio:4/3;max-height:390px;overflow:hidden;display:grid;place-items:center;padding:24px;border:2px dashed #d7c8bf;border-radius:20px;background:#faf8f5;color:#1c1917;cursor:pointer;transition:border-color .2s,background .2s,transform .2s}
#modal-daily-close .dc-dropzone:hover,#modal-daily-close .dc-dropzone.is-dragging{border-color:#8b1515;background:#f8eeee}
.dc-dropzone .dc-placeholder,.dc-dropzone .dc-pdf-preview{display:flex;flex-direction:column;align-items:center;gap:12px;text-align:center}
.dc-placeholder strong,.dc-pdf-preview strong{font-size:26px;font-weight:800;letter-spacing:-.4px}
.dc-placeholder>span:not(.dc-upload-icon),.dc-pdf-preview>span{font-size:16px;color:#78716c;font-weight:500}
.dc-placeholder small{color:#78716c;font-weight:500}
.dc-upload-icon{width:76px;height:76px;border-radius:22px;background:#fff;box-shadow:0 5px 20px #1c19170a;border:1px solid #e5dfd5;display:grid;place-items:center;color:#8b1515;margin-bottom:8px}
.dc-upload-icon svg{width:32px;height:32px}.dc-pdf-preview>svg{width:68px;height:68px;color:#8b1515}
#dc-file-preview{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;background:#f4f0eb}
.dc-replace{position:absolute;bottom:16px;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:8px;white-space:nowrap;background:#1c1917;color:white;padding:10px 16px;border-radius:12px;font-weight:700}
.dc-replace svg{width:16px;height:16px}.dc-file-meta{display:flex;align-items:center;gap:12px;border:1px solid #e5dfd5;border-radius:14px;padding:12px;background:#fff;min-width:0}
.dc-file-meta>svg{color:#8b1515;flex-shrink:0}.dc-file-meta>div{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px}.dc-file-meta strong{font-size:16px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dc-file-meta small{color:#78716c}.dc-file-meta button{background:#faf8f5;border:1px solid #e5dfd5;border-radius:10px;width:34px;height:34px;display:grid;place-items:center;cursor:pointer}.dc-file-meta button svg{width:18px;height:18px}
.dc-upload-aside{display:flex;flex-direction:column;gap:16px;min-width:0}.dc-date-box{display:flex;flex-direction:column;gap:8px;padding:16px;border:1px solid #e5dfd5;border-radius:16px;background:#faf8f5}.dc-date-box input{width:100%;height:46px!important}.dc-guide{padding:8px 4px}.dc-step-label{font-size:11px;font-weight:800;letter-spacing:1.2px;color:#8b1515}.dc-guide h4{margin:8px 0 20px;font-size:26px;letter-spacing:-.5px;font-weight:800;line-height:1.15}.dc-guide ol{padding:0;margin:0;list-style:none;display:flex;flex-direction:column;gap:18px}.dc-guide li{display:flex;align-items:center;gap:12px}.dc-guide li>span{width:32px;height:32px;border:1px solid #ead4d4;border-radius:10px;display:grid;place-items:center;background:#f8eeee;color:#8b1515;font-weight:800;flex-shrink:0}.dc-guide li>div{display:flex;flex-direction:column;gap:4px}.dc-guide strong{font-size:18px;font-weight:700}.dc-guide small{color:#78716c}.dc-upload-status{border:1px solid #e5dfd5;border-radius:14px;padding:14px;margin:0;background:#faf8f5;color:#78716c;font-size:14px;font-weight:500;line-height:1.4}
.dc-upload-flow .dc-secondary{padding:12px 18px;border:1px solid #ddd6ce;background:#fff;color:#57534e;border-radius:12px;cursor:pointer}.dc-upload-flow .dc-primary{padding:14px 22px;border:0;background:#8b1515;color:#fff;border-radius:12px;cursor:pointer;box-shadow:0 5px 16px #8b151522;transition:background .2s,opacity .2s}
.dc-upload-flow button:disabled{opacity:.45;cursor:default}.dc-upload-flow .dc-primary:not(:disabled):hover{background:#701010}
@media(max-width:760px){#modal-daily-close.dc-upload-flow .dc-upload-body{grid-template-columns:1fr;padding:16px;gap:16px}#modal-daily-close .dc-dropzone{min-height:220px;max-height:280px;aspect-ratio:4/3}.dc-upload-flow .dc-guide{display:none}.dc-upload-flow .rs-popup-footer{flex-wrap:wrap}.dc-upload-flow .dc-primary{flex:1}.dc-placeholder strong{font-size:23px}}
@media(min-width:761px) and (max-height:760px){#modal-daily-close.dc-upload-flow .dc-upload-body{padding:18px 24px;gap:20px}#modal-daily-close .dc-dropzone{min-height:280px;max-height:330px}.dc-guide h4{font-size:23px;margin-bottom:12px}.dc-guide ol{gap:12px}.dc-upload-aside{gap:12px}.dc-upload-status{padding:10px}}
#modal-daily-close.dc-upload-flow .dc-upload-body[hidden],#modal-daily-close.dc-upload-flow .rs-popup-body[hidden]{display:none!important}
#modal-daily-close.dc-upload-flow .rs-popup-body>div:first-child button{padding:8px 12px;background:#fff;border:1px solid #e5dfd5;border-radius:10px;color:#8b1515;cursor:pointer}

.dc-upload-flow .dc-upload-body,.dc-upload-flow .rs-popup-body{animation:rs-popup-enter .2s ease-out}

/* Stock health dialog follows the management popup contract. */
dialog#stock-health-dialog{position:fixed!important;inset:0!important;margin:auto!important;transform:none!important;width:min(1120px,calc(100vw - 48px))!important;max-width:calc(100vw - 48px)!important;height:fit-content!important;max-height:calc(100dvh - 48px)!important;padding:0!important;border:1px solid #e5dfd5!important;border-radius:26px!important;background:#fff!important;box-sizing:border-box!important;font-family:var(--font-display,Outfit,sans-serif)!important}
#stock-health-dialog *{box-sizing:border-box;font-family:var(--font-display,Outfit,sans-serif)!important}
#stock-health-dialog .sh-header{padding:20px 24px!important;gap:12px!important;align-items:center!important}
#stock-health-dialog .sh-header h2{font-size:28px!important;font-weight:700!important;line-height:1.15!important;letter-spacing:-.5px!important}
#stock-health-dialog .sh-header h2 svg{width:26px!important;height:26px!important;stroke-width:2!important}
#stock-health-dialog .sh-search{height:40px!important;border-radius:999px!important;padding:0 14px!important;background:#fff!important;font-weight:400!important}
#stock-health-dialog .sh-search input{height:36px!important;padding:0!important;font-size:14.5px!important;font-weight:400!important;border:0!important;border-radius:0!important;background:transparent!important}
#stock-health-dialog .sh-close{width:40px!important;height:40px!important;border-radius:12px!important;background:#faf8f5!important;border:1px solid #e5dfd5!important;padding:0!important;display:grid!important;place-items:center!important}
#stock-health-dialog .sh-close svg{width:20px!important;height:20px!important;stroke-width:2!important}
#stock-health-dialog th{font-size:10.5px!important;font-weight:500!important;padding:14px 20px!important;letter-spacing:.7px!important}
#stock-health-dialog td{padding:13px 20px!important;font-size:14px!important;font-weight:400!important}
#stock-health-dialog .sh-name{font-size:15.5px!important;font-weight:600!important;line-height:1.3!important;border-radius:0!important;background:none!important}
#stock-health-dialog .sh-area{font-size:12.5px!important;font-weight:500!important;border-radius:9px!important}
#stock-health-dialog strong{font-weight:600!important}#stock-health-dialog .sh-count{font-size:12px!important;font-weight:500!important}
#stock-health-dialog .sh-table-wrap{max-height:calc(100dvh - 145px)!important;overflow:auto!important}
@media(max-width:768px){dialog#stock-health-dialog{width:calc(100vw - 24px)!important;max-width:calc(100vw - 24px)!important;max-height:calc(100dvh - 24px)!important}#stock-health-dialog .sh-header{padding:16px!important}#stock-health-dialog .sh-header h2{font-size:23px!important}#stock-health-dialog .sh-table-wrap{max-height:calc(100dvh - 200px)!important}}

/* Search focus belongs to the pill wrapper, never to the inner field. */
#stock-health-dialog .sh-search:focus-within{outline:none!important;outline-offset:0!important;border-color:#8b1515!important;box-shadow:0 0 0 2px rgba(139,21,21,.1)!important}
#stock-health-dialog .sh-search input,#stock-health-dialog .sh-search input:focus,#stock-health-dialog .sh-search input:focus-visible{outline:none!important;outline-offset:0!important;border:0!important;box-shadow:none!important;background:transparent!important;min-width:0!important}

/* Category creation belongs to the header, beside its title. */
#category-management-modal .rs-popup-header{gap:16px;flex-wrap:wrap}
#category-management-modal .cat-menu-create{display:flex;align-items:center;gap:8px;margin-left:auto}
#category-management-modal .cat-menu-create input{width:190px;height:40px;padding:0 16px;border:1px solid #e5dfd5;border-radius:999px;background:#faf8f5;color:#1c1917;font-family:var(--font-display);font-size:14px;font-weight:400;outline:none}
#category-management-modal .cat-menu-create input:focus{border-color:#8b1515}
#category-management-modal .cat-menu-create button{display:flex;align-items:center;justify-content:center;gap:7px;height:40px;padding:0 18px;border:0;border-radius:999px;background:#111;color:white;font-family:var(--font-display);font-size:14px;font-weight:600;white-space:nowrap;cursor:pointer}
#category-management-modal .cat-menu-create button svg{width:17px;height:17px}
#category-management-modal h3{font-weight:700!important}
#category-management-modal .cat-group>div:first-child>span{font-weight:600!important}
#category-management-modal .cat-group>div:first-child>div>span{font-weight:400!important}
@media(max-width:700px){#category-management-modal .cat-menu-create{order:3;width:100%;margin-left:0}#category-management-modal .cat-menu-create input{flex:1;min-width:0;width:auto}}

/* Final audit: keep the product card header/actions visible on small screens. */
#product-card-modal #btn-close-card-modal{width:40px!important;height:40px!important;min-width:40px!important;flex-shrink:0!important}
#product-card-modal #pcm-right-panel>div:first-child>div{flex:1;min-width:0}
#product-card-modal #pcm-title-name{max-width:100%;min-width:0}
@media(max-width:768px){
 #product-card-modal #pcm-dialog{height:calc(100dvh - 24px)!important;max-height:calc(100dvh - 24px)!important;padding:0!important;overflow:hidden!important;flex-direction:column!important}
 #product-card-modal #pcm-left-hero{height:150px!important;min-height:150px!important;flex-shrink:0!important}
 #product-card-modal #pcm-right-panel{height:auto!important;flex:1;min-height:0;overflow:hidden}
 #product-card-modal #pcm-right-panel>div:first-child{padding:12px 16px!important;gap:10px}
 #product-card-modal #pcm-tabs-container{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));width:100%;max-width:100%;border-radius:14px!important;gap:4px}
 #product-card-modal #pcm-tab-glider{display:none}
 #product-card-modal .pcm-tab-btn{min-width:0;justify-content:center;padding:7px 4px!important;font-size:12px!important}
 #product-card-modal .pcm-tab-btn.active{background:#fff}
 #product-card-modal #pcm-view-section{min-width:0;overflow:hidden}
 #product-card-modal #pcm-view-section>div:first-child{padding:10px 12px!important;flex-shrink:0}
 #product-card-modal #pcm-slide-track>div{overflow-y:auto!important;min-height:0;padding:12px!important}
 #product-card-modal #pcm-right-panel>div:last-child{padding:10px 12px!important;flex-wrap:wrap;gap:8px}
 #product-card-modal #pcm-right-panel>div:last-child>div:first-child{width:100%;font-size:11px!important}
 #product-card-modal #pcm-footer-actions{width:100%;justify-content:flex-end;flex-wrap:wrap}
 #product-card-modal #pcm-delete-confirm-box{width:100%;flex-wrap:wrap}
 #product-card-modal #pcm-delete-confirm-box>span{width:100%}
 #product-card-modal .pcm-ingredient{grid-template-columns:minmax(0,1.4fr) 1fr .5fr 1fr;gap:5px}
 #channel-commission-modal-overlay .rs-commission-aside{min-width:0;max-width:100%}
 #channel-commission-modal-overlay .rs-commission-aside>div:first-of-type{grid-template-columns:repeat(2,minmax(0,1fr))!important}
 #channel-commission-modal-overlay #comm-sim-strip{grid-template-columns:repeat(3,minmax(0,1fr))!important}
 #channel-commission-modal-overlay .rs-commission-aside>div:last-of-type>div:first-child{flex-wrap:wrap!important;gap:8px}
}

/* Legacy recipe/calculator overlays must be fixed before their card is measured. */
.rs-popup:not(dialog){position:fixed!important;inset:0!important;z-index:100000}
.rs-popup:not(dialog):not([hidden]):not([style*="display: none"]):not([style*="display:none"]){display:flex!important}
.rs-popup .rs-popup:not(dialog){z-index:100001}
.rs-popup-header h4{font-size:28px!important;font-weight:800!important;line-height:1.15;margin:0;color:var(--popup-ink)}
.rs-popup :is(button[aria-label="Kapat"],#btn-modal-close,#btn-smart-calc-close,#picker-close-btn){min-width:40px!important;width:40px!important;height:40px!important;flex-shrink:0!important}
#recipe-product-picker-modal .rs-popup-card,#recipe-ingredient-picker-modal .rs-popup-card{width:min(760px,100%)!important}
@media(max-width:760px){
 .rs-popup-header h4{font-size:23px!important}
 #channel-commission-modal-overlay .rs-popup-header{display:grid!important;grid-template-columns:minmax(0,1fr) 40px!important;gap:12px!important;padding:16px!important}
 #channel-commission-modal-overlay .rs-popup-header>div{min-width:0;flex-wrap:wrap!important}
 #channel-commission-modal-overlay .rs-popup-header>div:first-child>div{min-width:0}
 #channel-commission-modal-overlay .rs-popup-header h2{font-size:23px!important}
 #channel-commission-modal-overlay .rs-popup-footer{display:flex!important;flex-wrap:wrap!important;gap:10px!important;padding:12px!important}
 #channel-commission-modal-overlay .rs-popup-footer>div{display:flex!important;flex-wrap:wrap!important;gap:8px!important;min-width:0;max-width:100%}
 #channel-commission-modal-overlay .rs-popup-footer>div:first-child>span{width:100%;min-width:0;max-width:100%}
 #channel-commission-modal-overlay .rs-commission-aside>div{min-width:0;max-width:100%}
 #channel-commission-modal-overlay .rs-commission-aside>div:first-of-type{display:grid!important;grid-template-columns:1fr!important}
 #channel-commission-modal-overlay .rs-commission-cards{min-width:0}
 #channel-commission-modal-overlay #comm-sim-strip{min-width:0}
 #stock-audit-modal-root .rs-popup-body>div:first-child{flex-wrap:wrap!important}
 #stock-audit-modal-root .rs-popup-body>div:first-child>*{min-width:0;max-width:100%;flex:1 1 180px}
 #stock-audit-modal-root table{min-width:0!important;width:100%!important}
}

.rs-popup-card>*,.rs-popup-body{min-width:0!important}
#notification-detail-modal .rs-popup-body{width:100%;max-width:100%;overflow-x:hidden}
#notification-detail-modal .rs-popup-body>div{min-width:0;max-width:100%}
#notification-detail-modal .rs-popup-body>div>div:first-child{min-width:0;flex:1;overflow-wrap:anywhere}
#notification-detail-modal .rs-popup-body>div>div:last-child{flex-shrink:0}

@media(max-width:760px){
 #channel-commission-modal-overlay .rs-popup-header{display:block!important;position:relative}
 #channel-commission-modal-overlay .rs-popup-header>div:first-child{padding-right:40px;margin-bottom:10px;align-items:flex-start!important}
 #channel-commission-modal-overlay .rs-popup-header>div:last-child{display:flex!important;justify-content:flex-start!important;max-width:100%}
 #channel-commission-modal-overlay .rs-popup-header button[aria-label="Kapat"]{position:absolute;top:16px;right:16px}
 #stock-audit-modal-root .rs-popup-card>div:has(#audit-cat-filters){flex-direction:column!important;align-items:stretch!important;gap:10px!important}
 #stock-audit-modal-root .rs-popup-card>div:has(#audit-cat-filters)>div{min-width:0!important;max-width:100%;flex-wrap:wrap!important}
 #stock-audit-modal-root #audit-cat-filters{min-width:0;max-width:100%;flex-wrap:wrap!important;overflow-x:visible!important}
}

.rs-popup:not(dialog) button[aria-label="Kapat"]{color:var(--popup-red)!important;background:var(--popup-paper)!important;border:1px solid var(--popup-line)!important;border-radius:12px!important}

/* Native cash dialogs use the browser top layer and keep its centering. */
dialog.rs-popup{position:fixed!important;inset:0!important;margin:auto!important;transform:none!important}
dialog#cash-entry-dialog{width:min(780px,calc(100vw - 48px))!important;height:fit-content!important}
@media(max-width:760px){dialog#cash-entry-dialog{width:calc(100vw - 24px)!important;padding:16px}}
.rs-popup input[type="checkbox"],.rs-popup input[type="radio"]{accent-color:var(--popup-red)!important}

/* Keep long invoice sections in natural document flow on small screens. */
@media(max-width:760px){
 #modal-invoice-entry .rs-popup-body{display:flex!important;flex-direction:column!important;align-items:stretch!important}
 #modal-invoice-entry .rs-popup-body>div{flex:0 0 auto!important;width:100%;min-height:auto!important}
 #modal-invoice-entry .rs-popup-body>div:nth-child(3){max-height:none!important;overflow:auto}
 #modal-invoice-entry .rs-popup-body>div:nth-child(3)>div:first-child{flex-wrap:wrap;gap:8px}
 #product-recipe-detail-modal .rs-popup-header>div:last-child{align-items:flex-start!important;gap:10px!important}
 #product-recipe-detail-modal .rs-popup-header>div:last-child>div:first-child{width:64px!important;height:48px!important}
 #product-recipe-detail-modal .rs-popup-header>div:last-child>div:last-child{padding-right:44px!important}
 #product-recipe-detail-modal .rs-popup-header h2{white-space:normal!important;overflow:visible!important;overflow-wrap:anywhere}
}

/* Text actions must not inherit the header's square icon-only close-button size. */
#category-management-modal .cat-menu-create button[data-rs-action="category-add"]{width:auto!important;min-width:120px!important;flex:0 0 auto!important;padding:0 16px!important;border:1px solid #111!important;background:#111!important;color:#fff!important}
#category-management-modal .cat-menu-create button[data-rs-action="category-add"] svg{flex:none;color:#fff}
#category-management-modal .cat-menu-create{min-width:0;gap:10px}

.sh-status-filters{display:flex;gap:8px;flex-wrap:wrap;padding:12px 24px;border-bottom:1px solid #e5dfd5}
.sh-status-filters button{border:1px solid #e5dfd5;border-radius:999px;background:#fff;color:#57534e;padding:7px 12px;font:600 12px var(--font-display);cursor:pointer}
.sh-status-filters button[aria-pressed="true"]{background:#1c1917;border-color:#1c1917;color:#fff}
#stock-health-dialog .sh-table-wrap{max-height:min(470px,calc(100dvh - 240px))}
@media(max-width:700px){.sh-status-filters{padding:12px 16px;gap:6px}#stock-health-dialog .sh-table-wrap{max-height:calc(100dvh - 310px)}}

#stock-health-dialog[open]{display:flex;flex-direction:column}
#stock-health-dialog .sh-header,#stock-health-dialog .sh-status-filters{flex-shrink:0}
#stock-health-dialog .sh-table-wrap{flex:1 1 auto;min-height:0;max-height:none!important;overflow:auto}

/* Quick pricing is a compact vertical form, with restrained text weights. */
#quick-price-modal .rs-popup-card{width:min(460px,100%)!important;max-width:min(460px,calc(100vw - 32px))!important;border-radius:24px!important}
#quick-price-modal .rs-popup-header{padding:14px 16px!important}
#quick-price-modal .rs-popup-header>div{gap:10px!important}
#quick-price-modal .rs-popup-header>div>div:first-child:has(>svg){width:40px!important;height:40px!important;border-radius:12px!important;flex:0 0 40px}
#quick-price-modal .rs-popup-header>div>div:first-child svg{width:22px!important;height:22px!important}
#quick-price-modal .rs-popup-header h3{font-size:25px!important;letter-spacing:-.4px!important}
#quick-price-modal .rs-popup-header p{font-size:12px!important;font-weight:400!important;line-height:1.4;margin:4px 0 0!important}

#quick-price-modal .rs-popup-body{display:grid!important;grid-template-columns:1fr!important;padding:12px 16px!important;gap:10px!important}
#quick-price-modal .rs-popup-body>div{padding:9px 11px!important;border-radius:12px!important;background:#faf8f5!important;box-shadow:none!important}
#quick-price-modal .rs-popup-body label{font-size:12px!important;font-weight:500!important;text-transform:none!important;letter-spacing:0!important;margin-bottom:3px!important;color:#78716c!important}
#quick-price-modal .rs-popup-body input:not([type=hidden]){height:34px!important;min-height:34px!important;border:0!important;background:transparent!important;border-radius:0!important;box-shadow:none!important;padding-left:0!important;padding-right:28px!important;font-size:15px!important;font-weight:500!important}
#quick-price-modal #qpm-price-input{font-size:22px!important;font-weight:700!important}
#quick-price-modal #qpm-price-box>div:last-child{margin-top:5px!important;font-size:12px!important;font-weight:400!important}
#quick-price-modal #qpm-current-price{font-weight:600!important}
#quick-price-modal #qpm-dropdown-list{position:absolute!important;top:calc(100% + 6px)!important;width:100%!important;max-height:120px!important;box-sizing:border-box;margin-top:0;padding:4px!important;box-shadow:0 6px 16px #1c191714!important}
#quick-price-modal .rs-popup-footer{padding:10px 16px!important;background:#fff!important}
#quick-price-modal #btn-save-qpm{min-height:40px!important;padding:10px!important;border-radius:999px!important;box-shadow:none!important;font-size:14px!important;font-weight:650!important;transform:none!important}
@media(max-width:600px){#quick-price-modal .rs-popup-card{max-width:calc(100vw - 24px)!important}#quick-price-modal .rs-popup-body input:not([type=hidden]){min-height:38px!important}#quick-price-modal #btn-save-qpm{min-height:44px!important}}

/* Filtered lists have stable centered frames; their bodies handle result changes. */
.rs-filter-stable{height:var(--rs-filter-height)!important}
#stock-audit-modal-root .rs-popup-card{width:min(980px,100%)!important;max-width:min(980px,calc(100vw - 32px))!important;height:min(620px,calc(100dvh - 32px))!important;max-height:calc(100dvh - 32px)!important;border-radius:24px!important}
#stock-audit-modal-root .rs-popup-header{padding:12px 16px!important}
#stock-audit-modal-root .rs-popup-header h2{font-size:23px!important;line-height:1.15!important}
#stock-audit-modal-root .rs-popup-header span{font-size:12px!important;font-weight:400!important}
#stock-audit-modal-root .rs-popup-header>div{gap:10px!important}
#stock-audit-modal-root .rs-popup-header>div>div:first-child:has(>svg){width:36px!important;height:36px!important;flex:0 0 36px}
#stock-audit-modal-root .rs-popup-card>div:has(#audit-cat-filters){padding:8px 16px!important;gap:8px!important;background:#faf8f5!important;flex:none}
#stock-audit-modal-root .rs-popup-card>div:has(#audit-cat-filters)>div{gap:8px!important}
#stock-audit-modal-root #audit-search-input{min-height:34px!important;height:34px!important;font-size:13px!important;font-weight:400!important}
#stock-audit-modal-root #audit-cat-filters{gap:4px!important;flex-wrap:wrap;overflow:visible!important}
#stock-audit-modal-root #audit-cat-filters button{font-size:12px!important;font-weight:550!important;padding:6px 8px!important;border-radius:999px!important}
#stock-audit-modal-root #audit-cat-filters button svg{width:13px!important;height:13px!important}
#stock-audit-modal-root #btn-audit-fill-all{font-size:12px!important;padding:8px 10px!important;white-space:nowrap}
#stock-audit-modal-root .rs-popup-body{padding:0 16px!important;max-height:none!important;min-height:0!important;flex:1 1 auto;overflow:auto}
#stock-audit-modal-root table{table-layout:fixed;min-width:740px!important;width:100%!important}
#stock-audit-modal-root th{padding:9px 8px!important;font-size:11px!important;font-weight:550!important;letter-spacing:0!important;text-transform:none!important;background:#f7f5f2!important}
#stock-audit-modal-root th:nth-child(1){width:31%!important}#stock-audit-modal-root th:nth-child(2){width:25%!important}#stock-audit-modal-root th:nth-child(3){width:14%!important}#stock-audit-modal-root th:nth-child(4){width:18%!important}#stock-audit-modal-root th:nth-child(5){width:12%!important}
#stock-audit-modal-root td{padding:6px 8px!important;height:40px;font-size:13px!important;font-weight:500!important}
#stock-audit-modal-root td strong{font-size:13px!important;font-weight:600!important}
#stock-audit-modal-root td:nth-child(2)>span{background:#faf8f5!important;border-color:#e5dfd5!important;color:#57534e!important;font-size:11px!important;font-weight:500!important;padding:3px 6px!important;white-space:nowrap}
#stock-audit-modal-root td:nth-child(2)>span svg{color:#8b1515!important;width:12px!important;height:12px!important}
#stock-audit-modal-root .audit-input{width:64px!important;height:28px!important;min-height:28px!important;font-size:14px!important;font-weight:600!important;border-width:1px!important;border-radius:9px!important}
#stock-audit-modal-root td:last-child span{font-size:11px!important;font-weight:600!important;white-space:nowrap}
#stock-audit-modal-root .rs-popup-footer{padding:10px 16px!important;background:#fff!important;gap:8px!important}
#stock-audit-modal-root .rs-popup-footer button{min-height:38px!important;padding:8px 14px!important;border-radius:999px!important;font-size:13px!important}
#stock-audit-modal-root #audit-changed-count{font-size:12px!important;font-weight:500!important}
@media(max-width:600px){#stock-audit-modal-root .rs-popup-card{max-width:calc(100vw - 24px)!important;height:calc(100dvh - 24px)!important;max-height:calc(100dvh - 24px)!important}#stock-audit-modal-root .rs-popup-header{padding:12px!important}#stock-audit-modal-root .rs-popup-header h2{font-size:21px!important}#stock-audit-modal-root .rs-popup-card>div:has(#audit-cat-filters){padding:8px 12px!important}#stock-audit-modal-root .rs-popup-card>div:has(#audit-cat-filters)>div{flex-direction:column!important;align-items:stretch!important}#stock-audit-modal-root .rs-popup-card>div:has(#audit-cat-filters)>div>div{width:100%!important}#stock-audit-modal-root .rs-popup-body{padding:0 12px!important}#stock-audit-modal-root .rs-popup-footer{flex-wrap:wrap;padding:10px 12px!important}#stock-audit-modal-root .rs-popup-footer>div:last-child{width:100%;display:flex}#stock-audit-modal-root .rs-popup-footer button{flex:1;min-height:44px!important}}

/* Recipe details: preserve readable ingredients before channel economics on phones. */
#recipe-mobile-channel{display:none}
#product-recipe-detail-modal .recipe-detail-ingredients{min-width:0}
@media(max-width:760px){
 #product-recipe-detail-modal{padding:8px!important}
 #product-recipe-detail-modal .recipe-detail-card{width:100%!important;max-width:100%!important;height:calc(100dvh - 16px)!important;max-height:calc(100dvh - 16px)!important;border-radius:16px!important;padding:0!important;overflow:hidden!important}
 #product-recipe-detail-modal .recipe-detail-header{padding:12px!important;flex:0 0 auto!important}
 #product-recipe-detail-modal .recipe-detail-identity{display:grid!important;grid-template-columns:48px minmax(0,1fr);gap:4px 10px!important;align-items:center!important}
 #product-recipe-detail-modal .recipe-detail-header .recipe-detail-identity>div:first-child{width:48px!important;height:48px!important;grid-column:1;grid-row:1/3}
 #product-recipe-detail-modal .recipe-detail-heading{display:contents!important}
 #product-recipe-detail-modal .recipe-detail-heading h2{grid-column:2;grid-row:1;font-size:19px!important;line-height:1.2!important;padding-right:38px;overflow-wrap:break-word!important}
 #product-recipe-detail-modal .recipe-detail-heading>div:not(.recipe-detail-channels){grid-column:2;grid-row:2;font-size:12px!important;line-height:1.3!important;flex-wrap:wrap;padding-right:32px}
 #product-recipe-detail-modal .recipe-detail-heading>div:not(.recipe-detail-channels)>span{font-size:12px!important}
 #product-recipe-detail-modal .recipe-detail-channels{grid-column:1/-1;grid-row:3;min-width:0;display:flex!important;flex-wrap:nowrap!important;gap:8px!important;margin-top:8px!important}
 #product-recipe-detail-modal .channel-filter-pill{display:none!important}
 #product-recipe-detail-modal #recipe-mobile-channel{display:block!important;min-width:0!important;flex:1;width:0!important;height:40px!important;padding:0 10px!important;font-size:16px!important;border:1px solid #e5dfd5;border-radius:8px;background:#faf8f5;color:#1c1917}
 #product-recipe-detail-modal #btn-open-comm-settings{width:auto!important;min-width:0!important;height:40px!important;padding:0 9px!important;font-size:11px!important;flex:0 0 auto!important}
 #product-recipe-detail-modal #btn-open-comm-settings span{font-size:11px!important}
 #product-recipe-detail-modal #btn-popup-close{top:10px!important;right:10px!important;width:34px!important;height:34px!important;min-width:34px!important}
 #product-recipe-detail-modal .recipe-detail-body{display:block!important;flex:1 1 auto!important;min-height:0!important;overflow-y:auto!important;overflow-x:hidden!important;padding:10px!important;overscroll-behavior:contain}
 #product-recipe-detail-modal .recipe-detail-ingredients{width:100%!important;overflow:visible!important;min-height:0!important;margin:0 0 12px!important;flex:none!important}
 #product-recipe-detail-modal .recipe-detail-rows{overflow:visible!important;max-height:none!important;flex:none!important;padding:4px 8px!important}
 #product-recipe-detail-modal .recipe-detail-columns{display:none!important}
 #product-recipe-detail-modal .recipe-detail-ingredients h3{font-size:14px!important;line-height:1.3!important}
 #product-recipe-detail-modal .recipe-group-header{padding:8px 4px!important;gap:6px!important}
 #product-recipe-detail-modal .recipe-group-header strong{font-size:11px!important}
 #product-recipe-detail-modal .recipe-group-header span{font-size:10px!important}
 #product-recipe-detail-modal table,#product-recipe-detail-modal tbody{display:block!important;width:100%!important;min-width:0!important}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;height:auto!important;max-height:none!important;padding:7px 0!important;gap:3px 8px}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td{display:block!important;min-width:0!important;height:auto!important;padding:0!important;line-height:1.35!important;width:auto!important}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:first-child>div{white-space:normal!important;max-width:none!important;font-size:14px!important;line-height:1.35!important;overflow-wrap:anywhere}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(2){text-align:right!important;white-space:nowrap}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(2) :is(span,strong){font-size:14px!important}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(4){display:none!important}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(3){font-size:11px!important;color:#78716c}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(3)::before{content:'Fire: ';font-size:11px}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(5){text-align:right!important}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(5)::before{content:'Maliyet: ';font-size:11px;color:#78716c}
 #product-recipe-detail-modal .recipe-detail-card:not(.recipe-editing) tr.recipe-item-row td:nth-child(6){display:none!important}
 #product-recipe-detail-modal .recipe-editing tr.recipe-item-row td:nth-child(6){grid-column:1/-1;text-align:right!important}
 #product-recipe-detail-modal .recipe-editing input{height:38px!important;min-height:38px!important;font-size:16px!important;width:76px!important}
 #product-recipe-detail-modal [data-recipe-summary]{overflow:visible!important;max-height:none!important;min-width:0!important;gap:8px!important}
 #product-recipe-detail-modal [data-recipe-summary]>div{flex-shrink:0!important;padding:12px!important}
}

@media(max-width:760px){
 #product-recipe-detail-modal .recipe-detail-header .recipe-detail-identity>div:first-child{min-width:0!important;max-width:48px!important;min-height:0!important;max-height:48px!important}
 #product-recipe-detail-modal .recipe-detail-header .recipe-detail-identity img{width:100%!important;height:100%!important;max-width:48px!important;max-height:48px!important;min-width:0!important;object-fit:cover}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(1){grid-column:1;grid-row:1}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(2){grid-column:2;grid-row:1}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(3){grid-column:1;grid-row:2}
 #product-recipe-detail-modal .recipe-detail-card tr.recipe-item-row td:nth-child(5){grid-column:2;grid-row:2}
}

#stock-transfer-modal-root .trf-dialog{width:min(880px,calc(100vw - 24px))!important;max-width:880px!important;max-height:calc(100dvh - 32px)!important;border-radius:16px!important}
#stock-transfer-modal-root .trf-header{padding:14px 18px!important;gap:12px!important;flex-wrap:wrap}
#stock-transfer-modal-root .trf-header h2{font-size:22px!important}
#stock-transfer-modal-root .trf-body{padding:16px!important;min-height:0!important}
#stock-transfer-modal-root .trf-dialog>div:last-child{padding:12px 18px!important;gap:10px;flex-wrap:wrap}
#stock-transfer-modal-root .trf-dialog[data-transfer-tab="history"]{max-width:720px!important}
#stock-transfer-modal-root .trf-history-empty{padding:20px!important;border-radius:10px!important}
#stock-transfer-modal-root .trf-tab-btn.active{background:#8b1515!important;color:#fff!important;border-color:#8b1515!important}
@media(max-width:760px){#stock-transfer-modal-root .rs-popup-body:has(#trf-dest-warehouse){display:block!important}#stock-transfer-modal-root .trf-header-actions{flex-wrap:wrap}#stock-transfer-modal-root .trf-item-row{flex-wrap:wrap}}

#stock-transfer-modal-root #btn-close-trf-modal-2{width:auto!important;min-width:88px!important;height:38px!important;padding:8px 18px!important;flex-shrink:0!important;box-sizing:border-box}
#stock-transfer-modal-root .trf-dialog>div:last-child{box-sizing:border-box!important;max-width:100%!important}

/* Direct manual intake form: compact even after shared dialog normalization. */
dialog#manual-stock-entry.manual-stock-picker{width:min(520px,calc(100vw - 24px))!important;max-width:520px!important;min-width:0!important;height:auto!important;max-height:calc(100dvh - 24px)!important;padding:0!important;border-radius:16px!important;overflow:auto!important;box-sizing:border-box!important}
#manual-stock-entry form{display:block!important;margin:0!important;padding:0!important}
#manual-stock-entry header{padding:16px 18px!important;border-bottom:1px solid #eee9e2}
#manual-stock-entry h2{font-size:22px!important;line-height:1.2!important}
#manual-stock-entry .manual-branch{display:block;margin-top:5px;font-size:12px;color:#78716c}
#manual-stock-entry .manual-fields{padding:16px 18px;display:grid;gap:14px}
#manual-stock-entry label{display:grid;gap:7px;margin:0!important;font-size:13px!important;font-weight:500!important}
#manual-stock-entry label small{display:inline;font-weight:400;color:#78716c}
#manual-stock-entry :is(select,input){width:100%;min-width:0;height:42px!important;box-sizing:border-box;border:1px solid #e5dfd5!important;border-radius:8px!important;padding:0 10px;font:400 16px var(--font-display);background:#fff}
#manual-stock-entry .manual-quantity-row{display:grid;grid-template-columns:1fr 1fr;gap:12px;align-items:end}
#manual-stock-entry .manual-amount{position:relative}
#manual-stock-entry .manual-amount input{padding-right:64px}
#manual-stock-entry .manual-amount span{position:absolute;right:12px;top:13px;font-size:12px;color:#78716c}
#manual-stock-entry .manual-preview{padding:10px 12px;background:#f7f5f2;border-radius:8px;min-width:0}
#manual-stock-entry .manual-preview span{display:block;font-size:11px;color:#78716c}
#manual-stock-entry .manual-preview strong{display:block;margin-top:5px;font-size:16px;font-weight:600}
#manual-stock-entry footer{padding:12px 18px!important;border-top:1px solid #eee9e2;justify-content:flex-end!important;gap:8px!important}
#manual-stock-entry button{border-radius:8px!important;min-height:38px!important}
#manual-stock-entry #manual-stock-save{background:#8b1515;color:#fff;border-color:#8b1515}
#manual-stock-entry #manual-stock-error{margin:0;font-size:13px;color:#8b1515;background:#f9eded;padding:10px;border-radius:8px}
#manual-stock-entry #manual-stock-error[hidden]{display:none}

dialog#cash-entry-dialog{width:min(560px,calc(100vw - 24px))!important;max-width:560px!important;padding:20px!important;border-radius:16px!important;box-sizing:border-box!important;max-height:calc(100dvh - 24px)!important;overflow:auto!important}
#cash-entry-dialog .cash-entry-fields{gap:12px;margin:18px 0 10px}#cash-entry-dialog .cash-entry-fields:has(>label:only-child){grid-template-columns:1fr}
#cash-entry-dialog h2{font-size:23px!important}#cash-entry-dialog label{font-size:14px!important}#cash-entry-dialog input{height:44px!important;padding:8px 12px!important;border-radius:8px!important;font-size:16px!important}#cash-entry-dialog footer button{border-radius:8px!important;padding:10px 18px!important}#cash-entry-dialog .cash-entry-note{line-height:1.5}

dialog#manual-stock-entry.manual-stock-picker,dialog#cash-entry-dialog{height:fit-content!important;min-height:0!important;margin:auto!important}

/* Quick Price: only the close control is square; text actions keep their label width. */
#quick-price-modal.rs-popup .rs-popup-card{width:min(620px,100%)!important;max-width:min(620px,calc(100vw - 32px))!important}
#quick-price-modal.rs-popup .rs-popup-header{gap:12px!important;align-items:center!important}
#quick-price-modal.rs-popup .rs-popup-header>div:first-child{min-width:0;flex:1 1 220px}
#quick-price-modal.rs-popup .rs-popup-header h3{font-weight:600!important;letter-spacing:0!important;line-height:1.2!important}
#quick-price-modal.rs-popup .rs-popup-header p{white-space:normal;line-height:1.45!important}
#quick-price-modal.rs-popup .rs-popup-header-actions{flex:0 0 auto!important;gap:8px!important;max-width:100%}
#quick-price-modal.rs-popup #btn-cancel-qpm,#quick-price-modal.rs-popup #btn-save-qpm{width:auto!important;min-width:90px!important;height:40px!important;min-height:40px!important;flex:0 0 auto!important;padding:0 18px!important;border-radius:999px!important;font-size:15px!important;font-weight:500!important;letter-spacing:0!important;white-space:nowrap!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:7px!important;box-shadow:none!important;transform:none!important}
#quick-price-modal.rs-popup #btn-cancel-qpm{background:#faf8f5!important;color:#44403c!important;border:1px solid #e5dfd5!important}
#quick-price-modal.rs-popup #btn-save-qpm{background:#8b1515!important;color:white!important;border:1px solid #8b1515!important}
#quick-price-modal.rs-popup #btn-close-qpm{width:34px!important;min-width:34px!important;height:34px!important;padding:0!important;flex:none!important}
#quick-price-modal.rs-popup #qpm-price-input{padding-left:12px!important;font-weight:500!important}
@media(max-width:768px){#quick-price-modal.rs-popup .rs-popup-card{max-width:calc(100vw - 24px)!important}#quick-price-modal.rs-popup .rs-popup-footer{gap:8px!important;justify-content:flex-end!important}#quick-price-modal.rs-popup #btn-cancel-qpm,#quick-price-modal.rs-popup #btn-save-qpm{height:44px!important;min-height:44px!important}#quick-price-modal.rs-popup #btn-save-qpm{flex:1 1 auto!important}}

/* Rebuilding content inside an open popup must not replay its entrance. */
.rs-popup-card.rs-popup-content-update{animation:none!important}
.dc-upload-flow .dc-upload-body,.dc-upload-flow .rs-popup-body{animation:none!important}

/* Header tabs leave the entire view height for product content. */
body.admin-brand #product-card-modal .pcm-packed-header{display:flex!important;gap:12px!important;padding:12px 18px!important;min-height:68px;box-sizing:border-box}
body.admin-brand #product-card-modal .pcm-packed-header>div:first-child{flex:1;min-width:140px}
body.admin-brand #product-card-modal #pcm-title-name{font-size:20px!important;white-space:normal!important;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;max-width:100%!important}
body.admin-brand #product-card-modal #pcm-tabs-container{flex:0 0 auto!important;width:auto!important;display:inline-flex!important;max-width:100%;gap:0!important}
body.admin-brand #product-card-modal #pcm-tabs-container[hidden]{display:none!important}
body.admin-brand #product-card-modal .pcm-tab-btn{font-size:11px!important;padding:7px 9px!important;gap:4px!important}
body.admin-brand #product-card-modal #pcm-view-section>div:first-child{padding:0!important;flex:1!important;min-height:0}
@media(max-width:1050px){body.admin-brand #product-card-modal .pcm-packed-header{flex-wrap:wrap}body.admin-brand #product-card-modal #pcm-tabs-container{order:3;flex:1 1 100%!important;justify-content:space-between}body.admin-brand #product-card-modal .pcm-tab-btn{flex:1;justify-content:center}}

@media(max-width:600px){body.admin-brand #product-card-modal #pcm-tabs-container{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));border-radius:14px!important}body.admin-brand #product-card-modal .pcm-tab-btn{white-space:normal;min-width:0}body.admin-brand #product-card-modal .pcm-tab-btn svg{flex-shrink:0}}

/* Stock popup filters use the shared continuous capsule bar. */
body.admin-brand #stock-health-dialog .sh-status-filters{display:flex!important;align-items:center;flex-wrap:nowrap!important;gap:2px!important;margin:10px 20px!important;padding:4px!important;border:1px solid #e5dfd5!important;border-radius:999px!important;background:#f0ece5!important;overflow-x:auto;min-height:42px;box-sizing:border-box}
body.admin-brand #stock-health-dialog .sh-status-filters button{flex:0 0 auto;height:32px;padding:0 12px!important;border:0!important;border-radius:999px!important;background:transparent!important;color:#57534e!important;font:500 13px/1.2 Outfit,sans-serif!important;white-space:nowrap;box-shadow:none!important}
body.admin-brand #stock-health-dialog .sh-status-filters button[aria-pressed=true]{background:#1c1917!important;color:#fff!important}
body.admin-brand #stock-health-dialog .sh-status-filters button:focus-visible{outline:2px solid #8b1515;outline-offset:1px}
@media(max-width:700px){body.admin-brand #stock-health-dialog .sh-status-filters{margin:8px 12px!important}}

/* Planned payments: short readable summaries and the shared period capsule. */
body.admin-brand .planned-payments-popup>header{padding:14px 20px!important;min-height:64px;gap:12px;align-items:center}
body.admin-brand .planned-payments-popup>header h2{font:600 24px/1.2 Outfit,sans-serif!important;margin:0}
body.admin-brand .planned-payments-popup>header p{display:none}
body.admin-brand .planned-payments-popup>header [data-close]{height:36px!important;min-height:36px!important;padding:0 15px!important;border:1px solid #e5dfd5!important;border-radius:999px!important;background:#faf8f5!important;color:#57534e!important;font:500 13px Outfit,sans-serif!important;width:auto!important}
body.admin-brand .planned-payments-popup .eops-period{display:flex!important;align-items:center!important;gap:8px!important;background:#faf8f5;border:1px solid #e5dfd5;border-radius:999px;padding:3px 10px!important;min-height:40px;box-sizing:border-box}
body.admin-brand .planned-payments-popup .eops-period>span{display:none!important}
body.admin-brand .planned-payments-popup .eops-period input[type=month]{height:32px!important;min-height:32px!important;width:150px!important;border:0!important;background:transparent!important;border-radius:999px!important;font:500 13px Outfit,sans-serif!important;padding:0 5px!important;color:#292524}
body.admin-brand .planned-payments-popup .eops-metrics small:empty{display:none!important}
body.admin-brand .planned-payments-popup .eops-footnote{display:none!important}

body.admin-brand .planned-payments-popup .eops-period-rail{display:flex;align-items:center;gap:2px;height:40px;padding:3px 5px;border:1px solid #e5dfd5;border-radius:999px;background:#faf8f5;box-sizing:border-box;flex:none}
body.admin-brand .planned-payments-popup .eops-period-rail>button{display:grid;place-items:center;width:30px;height:30px;min-height:30px;border:0;border-radius:999px;background:transparent;color:#8b1515;padding:0!important}
body.admin-brand .planned-payments-popup .eops-period-rail svg{width:17px;height:17px;flex:none;color:#8b1515}
body.admin-brand .planned-payments-popup .eops-period-center{position:relative;display:flex;align-items:center;justify-content:center;gap:9px;height:32px;min-width:136px;padding:0 9px;font:500 13px/1.2 Outfit,sans-serif;color:#292524;border-radius:999px}
body.admin-brand .planned-payments-popup .eops-period-center input[type=month]{position:absolute;inset:0;width:100%!important;height:100%!important;min-height:0!important;opacity:0;cursor:pointer;margin:0;padding:0!important;border:0!important}
body.admin-brand .planned-payments-popup .eops-period-center input::-webkit-calendar-picker-indicator{position:absolute;inset:0;width:auto;height:auto;cursor:pointer}
body.admin-brand .planned-payments-popup .eops-period-center:focus-within{outline:2px solid #8b1515;outline-offset:2px}
body.admin-brand .planned-payments-popup .eops-period-rail>button:hover{background:#eee8e2}

/* Operational tables: readable compact rows, matching header/cell axes. */
body.admin-brand .planned-payments-popup .eops-table{width:100%!important;min-width:0!important;table-layout:fixed!important}
body.admin-brand .planned-payments-popup .eops-table :is(th,td){padding:10px 6px!important;text-align:center!important;vertical-align:middle;font:400 14px/1.35 Outfit,sans-serif!important;overflow-wrap:anywhere}
body.admin-brand .planned-payments-popup .eops-table th{font-size:12px!important;font-weight:500!important;white-space:normal!important}
body.admin-brand .planned-payments-popup .eops-table :is(th,td):first-child{width:17%;text-align:left!important;padding-left:12px!important}
body.admin-brand .planned-payments-popup .eops-table :is(th,td):last-child{width:150px;padding-right:10px!important}
body.admin-brand .planned-payments-popup .eops-table .eops-money{font:600 14px/1.35 Outfit,sans-serif!important;text-align:center!important;white-space:nowrap}
body.admin-brand .planned-payments-popup .eops-table :is(.eops-name,td>strong){font:600 15px/1.35 Outfit,sans-serif!important}
body.admin-brand .planned-payments-popup .eops-table td small{font-size:11px!important;margin-top:3px}
body.admin-brand .planned-payments-popup .eops-row-actions{display:flex;justify-content:center;align-items:center;gap:5px;flex-wrap:nowrap}
body.admin-brand .planned-payments-popup .eops-compact-row-tools{display:flex;gap:4px;flex:none}
body.admin-brand .planned-payments-popup .eops-compact-row-tools .eops-table-button{width:28px;height:30px;min-width:28px!important;min-height:30px;padding:0!important;border-radius:9px;display:grid;place-items:center}
body.admin-brand .planned-payments-popup .eops-compact-row-tools .eops-table-button>span{display:none}
body.admin-brand .planned-payments-popup .eops-table-button{font:500 12px/1.2 Outfit,sans-serif!important;min-height:30px;padding:6px 8px;border-radius:10px;gap:4px}
body.admin-brand .planned-payments-popup .eops-subtabs{min-width:0;max-width:100%;background:#f0ece5;border:1px solid #e5dfd5;border-radius:999px;padding:4px;gap:2px;flex-wrap:nowrap;overflow:auto}
body.admin-brand .planned-payments-popup .eops-subtabs button{flex:0 0 auto!important;word-break:normal;overflow-wrap:normal;background:transparent;border-radius:999px;padding:7px 11px;font:500 12px/1.3 Outfit,sans-serif;white-space:nowrap!important}
body.admin-brand .planned-payments-popup .eops-subtabs button.active{background:#1c1917;color:#fff}
body.admin-brand .planned-payments-popup .eops-panel>.eops-intro{display:none}
body.admin-brand .planned-payments-popup .eops-panel-heading{margin-bottom:12px}
@media(max-width:900px){body.admin-brand .planned-payments-popup .eops-table{min-width:860px!important}}

/* Personnel entry: compact real controls, no clipped card-style fields. */
body.admin-brand dialog.eops-personnel-entry.rs-popup{width:min(760px,calc(100vw - 32px))!important;max-width:min(760px,calc(100vw - 32px))!important;height:auto!important;max-height:calc(100dvh - 32px)!important;border-radius:24px!important}
body.admin-brand dialog.eops-personnel-entry .eops-dialog-frame{display:flex;flex-direction:column;min-height:0;max-height:calc(100dvh - 34px)}
body.admin-brand dialog.eops-personnel-entry header{padding:14px 18px!important;min-height:64px;gap:12px;align-items:center}
body.admin-brand dialog.eops-personnel-entry header>div{padding:0!important;border:0!important;background:transparent!important;border-radius:0!important}
body.admin-brand dialog.eops-personnel-entry header .eops-eyebrow{display:none}
body.admin-brand dialog.eops-personnel-entry header h2{font:600 23px/1.2 Outfit,sans-serif!important;display:flex;align-items:center;gap:10px;margin:0!important}
body.admin-brand dialog.eops-personnel-entry header h2 svg{width:24px;height:24px;color:#8b1515}
body.admin-brand dialog.eops-personnel-entry .eops-dialog-body{padding:14px 18px!important;overflow:auto;min-height:0}
body.admin-brand dialog.eops-personnel-entry .eops-form-content{display:flex!important;flex-direction:column;gap:12px!important}
body.admin-brand dialog.eops-personnel-entry .eops-entry-section{padding:0!important;border:0!important;background:transparent!important;display:flex;flex-direction:column;gap:12px}
body.admin-brand dialog.eops-personnel-entry .eops-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px!important}
body.admin-brand dialog.eops-personnel-entry .eops-entry-schedule{display:grid;grid-template-columns:.65fr 1fr 1.2fr;gap:12px!important;margin:0!important}
body.admin-brand dialog.eops-personnel-entry .eops-field{display:flex;flex-direction:column;gap:5px!important;padding:0!important;border:0!important;border-radius:0!important;background:transparent!important;overflow:visible!important;box-shadow:none!important;min-height:0!important}
body.admin-brand dialog.eops-personnel-entry .eops-field>span{font:500 12px/1.3 Outfit,sans-serif!important;color:#78716c}
body.admin-brand dialog.eops-personnel-entry .eops-field :is(input,select){height:38px!important;min-height:38px!important;line-height:20px!important;padding:8px 10px!important;border:1px solid #e5dfd5!important;border-radius:10px!important;background:#faf8f5!important;color:#292524;font:400 14px/20px Outfit,sans-serif!important;width:100%;box-sizing:border-box}
body.admin-brand dialog.eops-personnel-entry .eops-entry-options{padding:10px 12px!important;border-radius:12px!important;margin:0!important}
body.admin-brand dialog.eops-personnel-entry .eops-entry-options summary{font:500 13px/1.3 Outfit,sans-serif!important}
body.admin-brand dialog.eops-personnel-entry .rs-popup-header-actions button{height:36px!important;min-height:36px!important;font-size:13px!important;padding:0 13px!important}
@media(max-width:600px){body.admin-brand dialog.eops-personnel-entry header{flex-wrap:wrap}body.admin-brand dialog.eops-personnel-entry .eops-entry-schedule{grid-template-columns:repeat(2,minmax(0,1fr))}body.admin-brand dialog.eops-personnel-entry .eops-entry-schedule>.eops-field:last-child{grid-column:1/-1}}

body.admin-brand .planned-payments-popup [data-ops-view=personnel]>.eops-panel>.eops-panel-heading>.eops-subtabs,body.admin-brand .planned-payments-popup [data-ops-view=personnel] .eops-popup-bento>.eops-panel>.eops-panel-heading>.eops-subtabs{display:none!important}
body.admin-brand .planned-payments-popup [data-ops-view=personnel] .eops-panel-heading>.eops-inline-actions{margin-left:auto}

body.admin-brand .planned-payments-popup [data-ops-view=personnel] .eops-panel-heading>.eops-subtabs{display:none!important}

/* Content-sized operations popup instead of a full-screen empty canvas. */
body.admin-brand dialog.planned-payments-popup.rs-popup{width:min(1120px,calc(100vw - 40px))!important;max-width:min(1120px,calc(100vw - 40px))!important;height:auto!important;min-height:0!important;max-height:calc(100dvh - 40px)!important}
body.admin-brand .planned-payments-popup .ae-detail-body{display:block!important;flex:0 1 auto!important;min-height:0!important;height:auto!important;max-height:calc(100dvh - 130px)!important;overflow:auto!important;padding:12px 16px!important}
body.admin-brand .planned-payments-popup .eops-popup-bento,body.admin-brand .planned-payments-popup .eops-popup-bento.eops-nav-in-header{height:auto!important;min-height:0!important;grid-template-rows:auto!important;gap:12px!important}
body.admin-brand .planned-payments-popup .eops-panel{height:auto!important;min-height:0!important;padding:12px!important;flex:none!important}
body.admin-brand .planned-payments-popup .eops-table-scroll{height:auto!important;min-height:0!important;flex:0 1 auto!important;max-height:380px!important}
body.admin-brand .planned-payments-popup .eops-metrics{gap:10px!important}
body.admin-brand .planned-payments-popup .eops-metric{min-height:74px!important;padding:12px!important;gap:10px!important;border-radius:16px!important}
body.admin-brand .planned-payments-popup .eops-metric strong{font:600 22px/1.2 Outfit,sans-serif!important}
body.admin-brand .planned-payments-popup .eops-metric span{font:400 12px/1.3 Outfit,sans-serif!important}
body.admin-brand .planned-payments-popup .planned-popup-heading h2{font-size:21px!important;white-space:nowrap}
body.admin-brand .planned-payments-popup .planned-popup-icon{width:36px!important;height:36px!important;border-radius:11px!important}
body.admin-brand .planned-payments-popup .planned-popup-heading{gap:10px!important}
body.admin-brand .planned-payments-popup .planned-header-navigation nav button{font-size:11px!important;padding:7px 9px!important}
@media(max-width:700px){body.admin-brand dialog.planned-payments-popup.rs-popup{width:calc(100vw - 24px)!important;max-width:calc(100vw - 24px)!important}.planned-payments-popup .eops-metrics{grid-template-columns:repeat(2,minmax(0,1fr))!important}}

body.admin-brand .planned-payments-popup>header{grid-template-columns:auto minmax(0,1fr)!important}
body.admin-brand .planned-payments-popup .eops-month-toggle{display:flex;align-items:center;justify-content:center;gap:9px;height:32px;padding:0!important;border:0;background:transparent;color:#292524;font:500 13px Outfit,sans-serif!important;width:100%;border-radius:999px}
body.admin-brand .eops-month-picker{position:fixed;inset:auto;margin:0;width:240px;padding:12px;border:1px solid #e5dfd5;border-radius:18px;background:#fff;color:#292524;box-shadow:0 12px 36px #0002;box-sizing:border-box;font-family:Outfit,sans-serif}
body.admin-brand .eops-month-picker-heading{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px}
body.admin-brand .eops-month-picker-heading button{width:30px;height:30px;border:0;border-radius:999px;background:#faf8f5;color:#8b1515;font-size:20px}
body.admin-brand .eops-month-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}
body.admin-brand .eops-month-grid button{height:32px;border:0;border-radius:9px;background:#faf8f5;color:#57534e;font:400 13px Outfit,sans-serif}
body.admin-brand .eops-month-grid button.active{background:#1c1917;color:#fff}
body.admin-brand .eops-month-grid button:hover{background:#8b1515;color:#fff}

/* Quick price: readable product list and a compact high-contrast price bento. */
body.admin-brand #quick-price-modal.rs-popup .rs-popup-card{width:min(760px,calc(100vw - 32px))!important;max-width:min(760px,calc(100vw - 32px))!important;height:auto!important}
body.admin-brand #quick-price-modal .qpm-fields{display:grid!important;grid-template-columns:1.1fr 1fr!important;gap:12px!important;padding:12px 16px!important;align-items:stretch}
body.admin-brand #quick-price-modal .qpm-selection{padding:10px!important;border-radius:16px!important;background:#f0ece5!important;min-height:0}
body.admin-brand #quick-price-modal .qpm-search{height:38px!important;min-height:38px!important;margin-bottom:8px;border-radius:10px!important;background:white!important}
body.admin-brand #quick-price-modal #qpm-search-input{height:38px!important;min-height:38px!important;font-size:14px!important;padding:0 34px 0 12px!important}
body.admin-brand #quick-price-modal #qpm-dropdown-list{position:static!important;max-height:232px!important;height:auto!important;padding:0!important;box-shadow:none!important;display:flex;flex-direction:column;gap:5px!important}
body.admin-brand #quick-price-modal .qpm-product-option{min-height:43px!important;padding:9px 10px!important;gap:10px;border-radius:10px!important;background:#fff!important;font:500 15px/1.3 Outfit,sans-serif!important;text-align:left}
body.admin-brand #quick-price-modal .qpm-product-option>span:first-child{font:500 15px/1.3 Outfit,sans-serif!important}
body.admin-brand #quick-price-modal .qpm-product-option>span:last-child{font:600 14px/1.3 Outfit,sans-serif!important;white-space:nowrap;color:#8b1515!important}
body.admin-brand #quick-price-modal .qpm-product-option:hover{background:#fbeceb!important}
body.admin-brand #quick-price-modal #qpm-price-box{display:flex;flex-direction:column;gap:10px;padding:14px!important;border-radius:16px!important;background:#1c1917!important;border:1px solid #1c1917!important;color:white!important}
body.admin-brand #quick-price-modal .qpm-price-heading>span,body.admin-brand #quick-price-modal #qpm-price-box>label{font:400 12px/1.3 Outfit,sans-serif!important;color:#d6d3d1!important;margin:0!important}
body.admin-brand #quick-price-modal #qpm-selected-name{font:600 18px/1.3 Outfit,sans-serif!important;color:#fff!important}
body.admin-brand #quick-price-modal .qpm-amount{height:62px!important;min-height:62px!important;padding:8px 12px!important;border-radius:12px!important;background:#fff!important;border:0!important;display:flex;align-items:center}
body.admin-brand #quick-price-modal #qpm-price-input{height:46px!important;min-height:46px!important;padding:0!important;font:600 28px/1.2 Outfit,sans-serif!important;background:transparent!important;color:#1c1917!important}
body.admin-brand #quick-price-modal .qpm-amount>span{color:#8b1515!important;font-size:22px!important}
body.admin-brand #quick-price-modal .qpm-price-stats{display:grid;grid-template-columns:1fr 1fr;gap:8px!important;margin-top:auto!important}
body.admin-brand #quick-price-modal .qpm-price-stats>div{padding:10px!important;min-height:64px!important;background:#302b27!important;border:1px solid #49413a!important;border-radius:11px!important}
body.admin-brand #quick-price-modal .qpm-price-stats span{font:400 11px/1.3 Outfit,sans-serif!important;color:#d6d3d1!important}
body.admin-brand #quick-price-modal .qpm-price-stats strong{font:600 18px/1.3 Outfit,sans-serif!important;color:#fff!important}
@media(max-width:600px){body.admin-brand #quick-price-modal .qpm-fields{grid-template-columns:1fr!important}body.admin-brand #quick-price-modal #qpm-dropdown-list{max-height:172px!important}}

/* Menu interactions: small working surface instead of stretched cards. */
body.admin-brand #stats-modal-overlay.rs-popup .rs-popup-card{width:min(740px,calc(100vw - 32px))!important;max-width:min(740px,calc(100vw - 32px))!important;height:min(490px,calc(100dvh - 32px))!important;max-height:calc(100dvh - 32px)!important}
body.admin-brand #stats-modal-overlay .stats-packed-header{padding:14px 18px!important;min-height:64px!important;gap:12px!important}
body.admin-brand #stats-modal-overlay .stats-packed-header h2{font-size:23px!important}
body.admin-brand #stats-modal-overlay .stats-tabs button{font:500 12px/1.3 Outfit,sans-serif!important;padding:7px 10px!important;min-height:30px!important}
body.admin-brand #stats-modal-overlay .stats-packed-body{padding:12px 16px!important;gap:10px!important;min-height:0!important;overflow:hidden!important}
body.admin-brand #stats-modal-overlay .stats-kpis{gap:8px!important}
body.admin-brand #stats-modal-overlay .stats-kpis>div{padding:12px!important;min-height:74px!important;border-radius:14px!important;gap:6px!important}
body.admin-brand #stats-modal-overlay .stats-kpis span{font:400 12px/1.3 Outfit,sans-serif!important}
body.admin-brand #stats-modal-overlay .stats-kpis strong{font:600 24px/1.2 Outfit,sans-serif!important}
body.admin-brand #stats-modal-overlay .stats-panel{min-height:0!important;flex:1;display:flex;flex-direction:column;gap:8px!important}
body.admin-brand #stats-modal-overlay .stats-panel[hidden]{display:none!important}
body.admin-brand #stats-modal-overlay .stats-table-wrap{min-height:0!important;flex:1;overflow:auto!important}
body.admin-brand #stats-modal-overlay .stats-results-table :is(th,td){padding:8px 10px!important;font:400 14px/1.3 Outfit,sans-serif!important}
body.admin-brand #stats-modal-overlay .stats-results-table th{font-size:12px!important;font-weight:500!important}
body.admin-brand #stats-modal-overlay .stats-results-table :is(th,td):first-child{width:36px;text-align:center}
body.admin-brand #stats-modal-overlay .stats-results-table :is(th,td):last-child{width:85px;text-align:center}
body.admin-brand #stats-modal-overlay .stats-results-table strong{font-weight:600!important}
body.admin-brand #stats-modal-overlay .stats-panel-switch{display:flex;justify-content:flex-end;flex:none}
body.admin-brand #stats-modal-overlay [data-stats-graph]{width:auto!important;min-height:32px!important;padding:7px 13px!important;font:500 12px Outfit,sans-serif!important}

body.admin-brand #stats-modal-overlay .stats-kpis>div:nth-child(1){background:#711d24!important;border:1px solid #8b343b!important}
body.admin-brand #stats-modal-overlay .stats-kpis>div:nth-child(2){background:#292725!important;border:1px solid #46413d!important}
body.admin-brand #stats-modal-overlay .stats-kpis>div:nth-child(3){background:#30483c!important;border:1px solid #4a6556!important}
body.admin-brand #stats-modal-overlay .stats-kpis>div span{color:#eee7df!important}
body.admin-brand #stats-modal-overlay .stats-kpis>div strong{color:#fff!important}

body.admin-brand #stats-modal-overlay .stats-tabs{position:relative;isolation:isolate}
body.admin-brand #stats-modal-overlay .stats-tabs .stats-slide-pill{position:absolute;z-index:0;pointer-events:none;background:#8b1515;border-radius:999px}
body.admin-brand #stats-modal-overlay .stats-tabs button{position:relative;z-index:1;background:transparent!important;box-shadow:none!important;transition:color .25s ease}
body.admin-brand #stats-modal-overlay .stats-tabs button[aria-selected=true]{color:#fff!important}

body.admin-brand #click-stats-overlay .cs-section-title{font:600 18px/1.3 Outfit,sans-serif!important}

/* The desktop personnel list fills the fixed popup frame; only the table scrolls. */
@media(min-width:1051px){
 body.admin-brand .planned-payments-popup.planned-payments-popup .ae-detail-body{display:flex!important;flex:1 1 auto!important;min-height:0!important;height:auto!important;max-height:none!important;overflow:hidden!important}
 body.admin-brand .planned-payments-popup.planned-payments-popup .eops-popup-bento.eops-nav-in-header{width:100%;height:100%!important;min-height:0!important;grid-template-rows:auto auto minmax(0,1fr) auto!important;align-items:stretch!important}
 body.admin-brand .planned-payments-popup.planned-payments-popup .eops-panel{height:100%!important;min-height:0!important;display:flex!important;flex-direction:column!important;align-self:stretch!important;overflow:hidden!important}
 body.admin-brand .planned-payments-popup.planned-payments-popup .eops-table-scroll{height:auto!important;min-height:0!important;flex:1 1 auto!important;max-height:none!important;overflow:auto!important}
 body.admin-brand .planned-payments-popup.planned-payments-popup .eops-panel:has(.eops-staff-controls){display:grid!important}
}

/* Compact expense record details and editor; isolated from operation dialogs. */
body.admin-brand .exp-dialog.exp-record-dialog{display:flex!important;align-items:center!important;justify-content:center!important;padding:16px!important}
body.admin-brand .exp-record-dialog .exp-dialog-card{width:min(540px,100%)!important;max-width:540px!important;min-width:0!important;max-height:calc(100dvh - 32px)!important;height:auto!important;display:flex!important;flex-direction:column!important;border:1px solid #e5dfd5!important;border-radius:24px!important;overflow:hidden!important;background:#fff!important}
body.admin-brand .exp-record-dialog .exp-dialog-card>header{padding:20px 24px!important;display:flex!important;align-items:center!important;justify-content:space-between!important;border-bottom:1px solid #e5dfd5!important}
body.admin-brand .exp-record-dialog .exp-dialog-card>header h2{font-size:26px!important;margin:0!important}
body.admin-brand .exp-record-dialog .exp-dialog-body{padding:24px!important;min-height:0!important;overflow:auto!important}
body.admin-brand .exp-record-dialog .exp-record-summary{display:flex!important;flex-direction:column!important;gap:12px!important}
body.admin-brand .exp-record-dialog .exp-record-summary h3{margin:0!important;font-size:22px!important;overflow-wrap:anywhere!important}
body.admin-brand .exp-record-dialog .exp-record-summary p{margin:0!important;color:#78716c!important;overflow-wrap:anywhere!important}
body.admin-brand .exp-record-dialog .exp-record-summary>strong{position:static!important;font-size:36px!important;align-self:flex-start!important;font-variant-numeric:tabular-nums!important}
body.admin-brand .exp-record-dialog footer{padding:16px 24px!important;display:flex!important;justify-content:flex-end!important;flex-wrap:wrap!important;gap:10px!important;border-top:1px solid #e5dfd5!important;background:#faf8f5!important}
body.admin-brand .exp-record-dialog footer button{min-height:44px!important;padding:10px 20px!important;border:1px solid #e5dfd5!important;border-radius:999px!important;background:#fff!important;color:#1c1917!important;font:600 15px var(--font-display,Outfit,sans-serif)!important;cursor:pointer!important}
body.admin-brand .exp-record-dialog footer button.save{background:#8b1515!important;border-color:#8b1515!important;color:#fff!important}
body.admin-brand .exp-record-dialog footer button.exp-delete-action{margin-right:auto!important;color:#8b1515!important;background:transparent!important;border-color:transparent!important}
body.admin-brand .exp-record-dialog .exp-delete-error:empty{display:none!important}
body.admin-brand .exp-record-dialog .expense-edit-fields{display:flex!important;flex-direction:column!important;gap:16px!important}
body.admin-brand .exp-record-dialog .expense-edit-fields>div{display:grid!important;grid-template-columns:1fr 1fr!important;gap:12px!important}
body.admin-brand .exp-record-dialog .expense-edit-fields label{display:flex!important;flex-direction:column!important;gap:7px!important;min-width:0!important}
body.admin-brand .exp-record-dialog .expense-edit-fields :is(input,textarea){width:100%!important;box-sizing:border-box!important;min-height:44px!important;padding:12px!important;border:1px solid #e5dfd5!important;border-radius:14px!important;font:inherit!important}
@media(max-width:600px){body.admin-brand .exp-record-dialog .exp-dialog-card>header,body.admin-brand .exp-record-dialog .exp-dialog-body,body.admin-brand .exp-record-dialog footer{padding:16px!important}body.admin-brand .exp-record-dialog .expense-edit-fields>div{grid-template-columns:1fr!important}}

/* Product detail keeps content and both actions reachable on narrow phones. */
@media(max-width:600px){
 body.admin-brand #product-card-modal #pcm-left-hero{height:110px!important;min-height:110px!important}
 body.admin-brand #product-card-modal .pcm-packed-header{padding:10px 12px!important;gap:8px!important}
 body.admin-brand #product-card-modal .pcm-packed-header>div:first-child{min-width:0!important;flex:1!important}
 body.admin-brand #product-card-modal #pcm-title-name{font-size:18px!important}
 body.admin-brand #product-card-modal #pcm-tabs-container{display:flex!important;flex-wrap:nowrap!important;justify-content:flex-start!important;overflow-x:auto!important;min-width:0!important;gap:4px!important}
 body.admin-brand #product-card-modal .pcm-tab-btn{flex:0 0 auto!important;white-space:nowrap!important;font-size:12px!important;padding:8px!important}
 body.admin-brand #product-card-modal #pcm-footer-actions{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px!important;min-width:0!important}
 body.admin-brand #product-card-modal #pcm-footer-actions>button{min-width:0!important;max-width:100%!important;padding:8px 6px!important;font-size:12px!important;justify-content:center!important}
 body.admin-brand #product-card-modal #pcm-footer-actions>button span{white-space:normal}
}
@media(max-width:600px){
 body.admin-brand #product-card-modal #pcm-slide-track{position:absolute!important;inset:0!important;height:100%!important}
 body.admin-brand #product-card-modal #pcm-slide-track>div{height:100%!important;flex:0 0 100%!important}
}

/* Content-sized expense and payroll detail dialogs (no global modal changes). */
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-dialog-card{width:min(560px,100%)!important;max-width:560px!important;height:auto!important;min-height:0!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-dialog-card>header{padding:16px 20px!important;min-height:0!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-dialog-card>header h2{font:600 24px/1.2 Outfit,sans-serif!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-dialog-body{padding:18px 20px!important;text-align:left!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-record-summary{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;gap:8px 16px!important;align-items:start!important;text-align:left!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-record-summary h3{font:600 20px/1.3 Outfit,sans-serif!important;text-align:left!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-record-summary p{font:400 14px/1.5 Outfit,sans-serif!important;text-align:left!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-record-summary>strong{grid-column:2!important;grid-row:1/3!important;font:600 28px/1.2 Outfit,sans-serif!important;white-space:nowrap!important;align-self:center!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-record-summary p:nth-of-type(n+2){grid-column:1/-1!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-record-guidance{margin:14px 0 0!important;padding:12px 14px!important;background:#faf8f5;border:1px solid #e5dfd5;border-radius:12px;font:400 13px/1.6 Outfit,sans-serif!important;text-align:left!important}
body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog footer{padding:12px 20px!important;min-height:0!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail{width:min(640px,calc(100vw - 32px))!important;max-width:640px!important;padding:0!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-dialog-frame>header{padding:16px 20px!important;min-height:0!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail header h2{font:600 24px/1.2 Outfit,sans-serif!important;margin:4px 0 0!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail header :is(p,small){font:400 12px/1.4 Outfit,sans-serif!important;margin:0!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-dialog-body{padding:18px 20px!important;text-align:left!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-person-heading{gap:12px!important;margin:0 0 16px!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-avatar{width:44px!important;height:44px!important;border-radius:12px!important;font-size:22px!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-person-heading h3{font:600 20px/1.3 Outfit,sans-serif!important;margin:0!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-person-heading p{font:400 13px/1.4 Outfit,sans-serif!important;margin:3px 0 0!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-review-list{margin:0!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-review-list>div{display:flex!important;flex-direction:column!important;align-items:flex-start!important;gap:8px!important;padding:12px!important;border:1px solid #e5dfd5!important;border-radius:12px!important;background:#faf8f5}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-review-list dt{font:400 13px/1.4 Outfit,sans-serif!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-review-list dd{font:600 23px/1.2 Outfit,sans-serif!important;max-width:100%!important;margin:0!important;text-align:left!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-subheading{font:600 17px/1.3 Outfit,sans-serif!important;margin:20px 0 10px!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-deduction-records{margin:0!important;border-radius:12px!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-deduction-record{padding:12px 14px!important;gap:12px!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-deduction-record strong{font:600 15px/1.4 Outfit,sans-serif!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-deduction-record small{font:400 12px/1.5 Outfit,sans-serif!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-deduction-record>b{font:600 19px/1.3 Outfit,sans-serif!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-deduction-records>.eops-intro{margin:0!important;padding:16px 14px!important;font:400 13px/1.5 Outfit,sans-serif!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail footer{padding:12px 20px!important;min-height:0!important;gap:12px!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-dialog-note{font:400 12px/1.4 Outfit,sans-serif!important}
body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail footer button{min-height:44px!important;font:500 14px/1.2 Outfit,sans-serif!important;padding:10px 18px!important;border-radius:999px!important}
@media(max-width:480px){
 body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-record-summary{grid-template-columns:minmax(0,1fr)!important}
 body.admin-brand .exp-record-dialog.exp-record-dialog.exp-record-dialog .exp-record-summary>strong{grid-column:1!important;grid-row:auto!important;font-size:26px!important}
 body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail .eops-review-list{grid-template-columns:minmax(0,1fr)!important}
 body.admin-brand dialog.eops-deduction-detail.eops-deduction-detail footer{flex-wrap:wrap!important}
}

/* Linked payroll information stays inside the expense record. */
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail{margin-top:18px;border-top:1px solid #e5dfd5;padding-top:16px;text-align:left}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail h4{font:600 17px/1.3 Outfit,sans-serif;margin:0 0 10px}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-basis{font:400 13px/1.5 Outfit,sans-serif;color:#78716c;margin:8px 0 12px}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail dl{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:12px 0}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail dl>div{padding:10px 12px;background:#faf8f5;border:1px solid #e5dfd5;border-radius:12px;min-width:0}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail dt{font:400 12px/1.4 Outfit,sans-serif;color:#78716c}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail dd{font:600 21px/1.3 Outfit,sans-serif;margin:5px 0 0;overflow-wrap:anywhere}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail summary{cursor:pointer;font:500 14px/1.4 Outfit,sans-serif;padding:10px 0}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail ul{list-style:none;padding:0;margin:0}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail li{display:flex;justify-content:space-between;gap:12px;padding:10px 0;border-top:1px solid #eee9e2;font:400 13px/1.5 Outfit,sans-serif}
body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail li small{display:block;color:#78716c}
@media(max-width:380px){body.admin-brand .exp-record-dialog.exp-record-dialog .exp-payroll-detail dl{grid-template-columns:minmax(0,1fr)}}
