.bill-page { --bill-olive:#426047; --bill-gold:#79580c; }
.bill-page h2 { margin:0; font:680 1.28rem/1.2 var(--display); letter-spacing:-.035em; }
.bill-page .op-page-heading p, .bill-section-title h2, .bill-summary h2 { display:flex; align-items:center; gap:8px; }
.bill-page .op-page-heading p .op-icon { width:16px; height:16px; }
.bill-section-title h2 .op-icon, .bill-summary h2 .op-icon { color:#756b57; }
.bill-back { display:inline-block; margin-bottom:.6rem; font-size:.84rem; color:var(--muted); text-underline-offset:3px; }
.bill-actions,.bill-filter,.bill-shortcuts { display:flex; gap:8px; flex-wrap:wrap; }
.bill-filter { width:fit-content; max-width:100%; margin:4px 0 18px; gap:3px; padding:3px; border:1px solid var(--line); border-radius:10px; background:#fff; }
.bill-filter button { display:flex; align-items:center; gap:8px; min-height:38px; border:1px solid transparent; color:var(--muted); background:transparent; padding:6px 12px; border-radius:7px; font:570 .875rem/1.25 var(--body); }
.bill-filter button:hover { background:var(--soft); }
.bill-filter button[aria-pressed=true] { background:var(--dark); color:white; border-color:var(--dark); }
.bill-filter b { padding:2px 6px; border-radius:5px; background:#817b6918; font:640 .76rem/1.3 var(--body); font-variant-numeric:tabular-nums; }
.bill-filter button[aria-pressed=true] b { background:#ffffff22; }
.bill-tables { display:grid; gap:14px; grid-template-columns:repeat(auto-fill,minmax(min(203px,100%),1fr)); }
.bill-table-card { display:block; font:inherit; text-decoration:none; text-align:left; min-width:0; color:var(--ink); background:#fff; padding:clamp(13px,1.5vw,20px); border:1px solid var(--line); border-radius:12px; }
.bill-table-card:hover { background:#fcfbf8; border-color:#ac9f83; box-shadow:0 2px 8px #2921110d; }
.bill-card-top>.op-icon { width:33px; height:33px; padding:7px; border:1px solid #e5e0d6; border-radius:8px; background:#f7f5ef; }
.bill-card-top,.bill-card-bottom,.bill-section-title,.bill-receipts button,.bill-history a,.bill-pay-total,.bill-change,.bill-totals div { display:flex; align-items:center; justify-content:space-between; gap:10px; }
.bill-card-top { margin-bottom:16px; color:var(--muted); }
.bill-card-bottom { border-top:1px solid #e9e6de; margin-top:13px; padding-top:11px; font-size:.88rem; font-weight:630; }
.bill-table-card>small,.bill-lines small,.bill-history small,.bill-receipts small,.bill-picks small { display:block; color:var(--muted); font-size:.81rem; font-weight:400; margin-top:3px; line-height:1.42; }
.bill-card-bottom svg { width:25px; height:25px; padding:4px; color:var(--ink); border:1px solid #e0dbd1; border-radius:6px; }
.bill-state { display:inline-flex; align-items:center; gap:5px; background:#f1f0ed; border-radius:20px; padding:4px 8px; font-size:.75rem; font-weight:620; color:#68645b; }
.bill-state::before { content:""; border-radius:100%; height:6px; width:6px; background:currentColor; }
.bill-state[data-state=open] { background:#e7f1e8; color:var(--bill-olive); }
.bill-state[data-state=requested] { background:#fae9bd; color:var(--bill-gold); }
.bill-detail { display:grid; grid-template-columns:minmax(0,1.55fr) minmax(260px,1fr); align-items:start; gap:18px; }
.bill-column { display:grid; min-width:0; gap:18px; }
.bill-panel { min-width:0; padding:clamp(16px,2.2vw,26px); background:white; border:1px solid var(--line); border-radius:14px; }
.bill-section-title { margin-bottom:16px; }
.bill-lines { list-style:none; margin:0; padding:0; }
.bill-lines li { display:flex; align-items:flex-start; justify-content:space-between; gap:12px; padding:12px 0; font-size:.9rem; border-top:1px solid #e8e5dc; }
.bill-lines li>div,.bill-picks label>span { min-width:0; overflow-wrap:anywhere; }
.bill-lines li:last-child { padding-bottom:0; }
.bill-lines strong,.bill-lines b,.bill-receipts b,.bill-history b { font-weight:630; }
.bill-lines .bill-paid-note { color:var(--bill-olive); }
.bill-summary h2 { margin-bottom:1rem; }
.bill-totals { margin:12px 0; font-size:.88rem; }
.bill-totals div { padding:5px 0; }
.bill-totals dt { color:var(--muted); }
.bill-totals dd { margin:0; font-weight:610; text-align:right; }
.bill-totals .bill-highlight { border-top:1px solid var(--line); padding-top:12px; margin-top:7px; font-size:1rem; }
.bill-totals .bill-highlight dd { font-size:1.2rem; }
.bill-side-actions,.bill-dialog-body,.bill-form,.bill-cash { display:grid; gap:12px; }
.bill-side-actions { margin-top:20px; }
.bill-dialog-body { padding:18px 24px 24px; }
.bill-form { gap:16px; }
.bill-form label,.op-cashbox label { display:grid; gap:5px; font-size:.82rem; font-weight:620; }
.bill-form .op-field,.op-cashbox .op-field { width:100%; min-width:0; font-weight:430; }
.bill-mixed { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; }
.bill-picks { border:0; margin:0; padding:0; }
.bill-picks legend { margin-bottom:8px; font-weight:660; }
.bill-picks label { display:grid; grid-template-columns:minmax(0,1fr) 65px; align-items:center; gap:14px; padding:9px 0; border-top:1px solid var(--line); }
.bill-picks input { text-align:center; }
.bill-shortcuts button { background:#f8f6ef; border:1px solid #e0d8c4; border-radius:8px; padding:6px 10px; color:#655432; font-size:.76rem; }
.bill-pay-total { background:#f5f1e6; padding:12px 14px; border-radius:10px; font-size:.85rem; }
.bill-pay-total strong { font-size:1.1rem; }
.bill-hint:empty { display:none; }
.bill-hint,.bill-muted,.bill-placeholder,.bill-change { color:var(--muted); font-size:.84rem; line-height:1.45; }
.bill-change { color:#485e42; }
.bill-receipts button,.bill-history a { width:100%; font:inherit; text-align:left; background:none; border:0; border-top:1px solid var(--line); padding:12px 0; color:inherit; text-decoration:none; }
.bill-receipts button>span,.bill-history a>span { flex:1; min-width:0; }
.bill-receipts button:hover b,.bill-history a:hover b { text-decoration:underline; }
.bill-history a:first-child { border-top:0; }
.bill-center { padding-top:18px; text-align:center; }
.bill-placeholder { padding:16px 0; }
.bill-error { margin:10px 0 16px !important; }
.op-pay .op-cashbox { display:grid; gap:8px; align-items:stretch; width:100%; }
.op-cashbox .bill-shortcuts { margin:0; }
@media(max-width:820px) { .bill-detail { grid-template-columns:1fr; } .bill-summary { grid-row:1; } }
@media(max-width:500px) { .bill-tables { grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; } .bill-table-card { padding:11px; } .bill-card-top { gap:4px; flex-wrap:wrap; } .bill-card-top>.op-icon { width:26px; height:26px; padding:4px; } .bill-filter { width:100%; flex-wrap:nowrap; overflow-x:auto; scrollbar-width:thin; } .bill-filter button { flex-shrink:0; padding-inline:8px; white-space:nowrap; } .bill-card-bottom { font-size:.79rem; } .bill-dialog-body { padding:16px; } .bill-mixed { grid-template-columns:1fr; } }
@media print { .bill-totals { margin:3mm 0; font-size:10pt; } .bill-totals div { display:flex; justify-content:space-between; gap:2mm; padding:1mm 0; } .bill-totals dd { margin:0; } }

.op-history-limit { display:flex; align-items:center; justify-content:space-between; gap:10px; flex-wrap:wrap; }
