#grubmaster-cash-dialog{box-sizing:border-box;width:min(1080px,calc(100vw - 32px));max-width:none;max-height:calc(100dvh - 32px);padding:0;border:0;border-radius:18px;overflow:hidden}
#grubmaster-cash-dialog [hidden]{display:none!important}
#grubmaster-cash-dialog::backdrop{background:rgb(15 43 70 / 55%)}
#gm-cash-body{box-sizing:border-box;display:grid;gap:20px;max-width:100%;max-height:calc(100dvh - 32px);padding:24px;overflow-x:hidden;overflow-y:auto}
#gm-cash-body > .section-head{position:static;inset:auto;z-index:auto}
#gm-cash-content{display:grid;gap:20px;min-width:0;max-width:100%}
#gm-cash-body section,.gm-saved-card,.gm-purchase-card,.gm-add-person{display:grid;gap:14px;min-width:0;max-width:100%;padding:20px;border:1px solid var(--line);border-radius:12px;background:#fff}
#gm-cash-body h3,#gm-cash-body p{margin:0;overflow-wrap:anywhere}
#gm-cash-body input,#gm-cash-body select{box-sizing:border-box;width:100%;min-width:0;max-width:100%}
.gm-cash-field{display:grid;gap:7px;min-width:0}.gm-cash-field strong{line-height:1.35}
.gm-cash-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px 20px}
.gm-cash-toolbar,.gm-cash-actions,.gm-receipt-links{display:flex;flex-wrap:wrap;gap:10px;align-items:center;min-width:0}
.gm-package-result{display:grid;gap:8px;flex-basis:100%;padding:14px;border:1px solid var(--accent);border-radius:12px;background:#fff}.gm-package-result[hidden]{display:none}.gm-package-result:focus{outline:3px solid color-mix(in srgb,var(--accent) 35%,transparent);outline-offset:2px}
.gm-cash-participant-head,.gm-cash-person{display:grid;grid-template-columns:22px minmax(180px,1fr) minmax(120px,160px) minmax(120px,160px) 96px;column-gap:12px;align-items:center}
.gm-cash-participant-head{padding:8px 0;color:var(--muted);font-size:.82rem;font-weight:800}.gm-cash-participant-head span:first-child{grid-column:2}.gm-cash-person{padding:10px 0;border-top:1px solid var(--line)}
.gm-cash-person input{min-height:40px}.gm-cash-person input[type='checkbox']{width:20px;height:20px;min-height:20px;margin:0}.gm-cash-person .gm-row-label{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}.gm-cash-person button{width:100%}
.gm-add-person,.gm-purchase-form{grid-template-columns:minmax(180px,1fr) minmax(180px,1fr) auto auto;align-items:end;background:var(--soft)}.gm-purchase-form{display:grid;gap:14px;padding:16px;border:1px solid var(--line);border-radius:10px}.gm-purchase-form .gm-purchase-description{grid-column:span 2}
.gm-cash-totals{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.gm-cash-total{display:grid;row-gap:8px;padding:14px;border-radius:9px;background:var(--soft)}.gm-cash-total strong,.gm-cash-total span{display:block}.gm-cash-total span{font-size:1.12rem}
.gm-cash-warning{padding:14px;border-left:4px solid #a24428;background:#fff1eb;color:#6d2a17;font-weight:700}.gm-purchase-card{gap:12px;background:var(--soft)}
.gm-signature-review input[type='checkbox']{width:22px!important;height:22px;min-height:22px;justify-self:start}.gm-signature-review textarea{box-sizing:border-box;width:100%;min-height:96px;resize:vertical}.gm-cash-success{color:#216e45;font-weight:800}
.gm-purchase-head{display:flex;justify-content:space-between;gap:16px;align-items:baseline}.gm-saved-card{gap:12px}.gm-saved-card h3{line-height:1.25}.filter-button.active{outline:3px solid var(--focus);outline-offset:2px}
@media(max-width:760px){
 #grubmaster-cash-dialog{position:fixed;inset:0;width:100vw;max-width:none;height:100dvh;max-height:none;margin:0;padding:0;border-radius:0;background:#f4f0e6}
 #gm-cash-body{height:100dvh;max-height:none;padding:calc(12px + env(safe-area-inset-top)) calc(12px + env(safe-area-inset-right)) calc(12px + env(safe-area-inset-bottom)) calc(12px + env(safe-area-inset-left));gap:16px;overscroll-behavior:contain;scrollbar-gutter:stable}
 #gm-cash-body > .section-head{position:sticky;top:0;z-index:3;margin:-12px -12px 0;padding:12px;background:#f4f0e6;border-bottom:1px solid var(--line)}
 #gm-cash-close{min-height:44px;min-width:72px}
 #gm-cash-body section,.gm-saved-card,.gm-purchase-card,.gm-add-person{padding:16px}
 .gm-cash-grid,.gm-cash-totals,.gm-add-person,.gm-purchase-form{grid-template-columns:minmax(0,1fr)}.gm-purchase-form .gm-purchase-description{grid-column:auto}
 .gm-cash-participant-head{display:none}.gm-cash-person{grid-template-columns:22px minmax(0,1fr);align-items:start}.gm-cash-person .gm-cash-field{grid-column:2}.gm-cash-person .gm-row-label{position:static;width:auto;height:auto;overflow:visible;clip-path:none}.gm-cash-person button{grid-column:2;min-height:44px}
 .gm-cash-toolbar,.gm-cash-actions{display:grid;grid-template-columns:minmax(0,1fr);align-items:stretch}.gm-cash-toolbar>*{min-width:0;width:100%}
 .gm-purchase-head{align-items:flex-start;flex-direction:column;gap:6px}
}
