.draft{color:#68758d;background:#eef1f6}.sent{color:#39778d;background:#e8f3f7}.void{color:#858b92;background:#eef0f1;text-decoration:line-through}
.invoice-stage-banner{padding:11px 20px;background:#f0f2f7;color:#69758b;text-align:center;font-size:11px;font-weight:700;letter-spacing:1.2px}
.email-recipient-options{display:grid;gap:9px;margin-bottom:18px;padding:15px;border:1px solid #dde7ed;border-radius:10px;background:#f7fafb}
.email-recipient-options>div small,.email-recipient-options label small{display:block;margin-top:3px;color:#82939e;font-size:10px}
.email-recipient-options label{display:flex;align-items:center;gap:10px;padding:10px;border-radius:8px;background:#fff;color:#314b5c;font-size:12px;cursor:pointer}
.email-recipient-options label>span{min-width:0;flex:1}.email-recipient-options select{width:auto;min-width:112px;padding:7px 30px 7px 10px}
.email-recipient-options input{accent-color:#087e8b}
.email-recipient-options details{margin-top:4px;color:#748894;font-size:11px}
.email-recipient-options details p{margin:8px 0 0}
.email-recipient-options>p{margin:0;color:#748894;font-size:11px}
html[data-theme=dark] .draft{color:#b8c2d5;background:#263448}
html[data-theme=dark] .sent{color:#9bcbd5;background:#173744}
html[data-theme=dark] .void{color:#aeb5bc;background:#29333d}
html[data-theme=dark] .invoice-stage-banner{background:#263448;color:#c2ccdc}
html[data-theme=dark] .email-recipient-options{border-color:#365064;background:#0d1d2b}
html[data-theme=dark] .email-recipient-options label{background:#142839;color:#deebf1}
.email-template-section{grid-column:1/-1}.email-template-help{display:flex;flex-wrap:wrap;align-items:center;gap:7px;margin-bottom:18px;padding:12px 14px;border-radius:9px;background:#f3f8f8;color:#587188;font-size:11px}.email-template-help strong{margin-right:4px;color:#17344b}.email-template-help code{padding:4px 7px;border-radius:5px;background:#fff;color:#087e8b}.email-template-field>span{display:flex;align-items:center;justify-content:space-between;gap:12px}.email-template-field textarea{margin-top:7px;line-height:1.55;resize:vertical}.email-template-field .text-button{font-size:11px}
html[data-theme=dark] .email-template-help{background:#0d1d2b;color:#9bb0bd}html[data-theme=dark] .email-template-help strong{color:#deebf1}html[data-theme=dark] .email-template-help code{background:#142839;color:#65d4dc}
.notification-test-section{grid-column:1/-1}.notification-test-card{display:flex;align-items:center;justify-content:space-between;gap:20px;padding:18px;border:1px solid #dce7ea;border-radius:10px;background:#f7fafb}.notification-test-card strong{display:block;color:#17344b;font-size:13px}.notification-test-card p{margin:6px 0 0;color:#71848e;font-size:11px}.notification-test-card .button{margin:0;flex:0 0 auto}html[data-theme=dark] .notification-test-card{border-color:#365064;background:#0d1d2b}html[data-theme=dark] .notification-test-card strong{color:#dce9ef}html[data-theme=dark] .notification-test-card p{color:#94aab6}@media(max-width:650px){.notification-test-card{align-items:stretch;flex-direction:column}.notification-test-card .button{width:100%}}
.notification-test-actions{display:flex;align-items:center;justify-content:flex-end;gap:9px;flex-wrap:wrap}@media(max-width:650px){.notification-test-actions{align-items:stretch;flex-direction:column}.notification-test-actions .button{width:100%}}
/* Shared workspace geometry: every top-level section follows the invoice dashboard. */
main{width:100%;max-width:1600px}.analytics-page{width:100%;max-width:none;margin:0}.settings-panel.settings-layout{width:100%;max-width:none}.retainers-page .page-head{margin-bottom:30px}.retainer-summary{gap:18px;margin-bottom:28px}.retainers-page>.panel+.panel{margin-top:28px}.quote-summary,.report-metrics{margin-bottom:28px}.report-controls{margin-bottom:28px}@media(max-width:1100px){main{padding:30px 25px}}@media(max-width:760px){main{width:100%;padding:27px 18px}.retainers-page .page-head{margin-bottom:22px}.retainer-summary,.quote-summary,.report-metrics,.report-controls{margin-bottom:22px}}
/* Retainer layout and optional advanced schedule */
main.retainers-page{max-width:1600px}.retainer-setup[hidden]{display:none}.advanced-retainer-options{margin-top:6px;border:1px solid #dce7ea;border-radius:10px;background:#f7fafb;overflow:hidden}.advanced-retainer-options summary{display:flex;justify-content:space-between;gap:18px;padding:15px 17px;color:#24485b;font-size:12px;font-weight:700;cursor:pointer;list-style:none}.advanced-retainer-options summary::-webkit-details-marker{display:none}.advanced-retainer-options summary:after{content:'+';font-size:18px;line-height:12px}.advanced-retainer-options[open] summary:after{content:'−'}.advanced-retainer-options summary span{color:#71848e;font-size:11px;font-weight:400}.advanced-retainer-grid{display:grid;grid-template-columns:1fr 1fr;gap:17px;padding:17px;border-top:1px solid #dce7ea}.prorata-option{align-items:flex-start;padding:13px;border-radius:8px;background:#edf7f6}.prorata-option span,.prorata-option strong,.prorata-option small{display:block}.prorata-option small{margin-top:5px;color:#71848e;line-height:1.5}html[data-theme=dark] .advanced-retainer-options{border-color:#365064;background:#0d1d2b}html[data-theme=dark] .advanced-retainer-options summary{color:#dce9ef}html[data-theme=dark] .advanced-retainer-grid{border-color:#365064}html[data-theme=dark] .prorata-option{background:#153438}@media(max-width:650px){.advanced-retainer-options summary{align-items:flex-start;flex-direction:column}.advanced-retainer-grid{grid-template-columns:1fr}}
/* Accounting workflow */
.report-table .panel-top{padding-bottom:18px}@media(max-width:760px){.report-table .panel-top{padding-bottom:15px}}
.credit-help{margin:18px 0 0;padding:12px 14px;border-radius:8px;background:#f4f8fa;color:#667d89;font-size:11px}.credit-reason{margin:25px 0;padding:16px;background:#f5f8f8;border-radius:8px}.credit-legal{margin-top:30px;padding-top:15px;border-top:1px solid #dce5e1;color:#65777d}.retainer-forecast{margin-top:22px}.report-controls{display:flex;align-items:end;gap:20px;margin-bottom:20px;padding:18px 20px;background:#fff;border:1px solid #dce7ea;border-radius:10px}.report-controls .field{width:180px}.report-controls p{margin:0 0 9px;color:#71848e;font-size:11px}.report-metrics{display:grid;grid-template-columns:repeat(5,1fr);gap:12px;margin-bottom:24px}.report-metrics article{padding:18px;background:#fff;border:1px solid #dce7ea;border-radius:9px}.report-metrics small{display:block;color:#71848e;font-size:10px;text-transform:uppercase}.report-metrics strong{display:block;margin-top:8px;color:#17344b;font-size:17px}.report-print-summary{display:grid;grid-template-columns:repeat(5,1fr);gap:8px;margin:25px 0}.report-print-summary div{padding:10px;background:#f3f7f7}.report-print-summary span,.report-print-summary strong{display:block;font-size:9px}.report-print-summary strong{margin-top:5px;font-size:12px}html[data-theme=dark] .report-controls,html[data-theme=dark] .report-metrics article{background:#102535;border-color:#304d60}html[data-theme=dark] .report-metrics strong{color:#dce9ef}@media(max-width:900px){.report-metrics{grid-template-columns:repeat(2,1fr)}}@media(max-width:650px){.report-controls{align-items:stretch;flex-direction:column}.report-controls .field{width:100%}.report-metrics{grid-template-columns:1fr}}
.report-preview{width:min(1220px,96vw)}.report-preview .report-paper{max-width:1123px}.report-ledger-wrap{width:100%;overflow:visible}.report-paper .accounting-ledger{width:100%;min-width:0;table-layout:fixed;white-space:normal}.accounting-ledger .report-date{width:12%}.accounting-ledger .report-reference{width:20%}.accounting-ledger .report-client{width:18%}.accounting-ledger .report-money{width:10%}.report-paper .accounting-ledger th,.report-paper .accounting-ledger td{padding:10px 7px;font-size:9px;line-height:1.35;overflow-wrap:anywhere}.report-paper .accounting-ledger th{font-size:8px}.report-paper .accounting-ledger th:nth-child(n+4),.report-paper .accounting-ledger td:nth-child(n+4){text-align:right;white-space:nowrap}.report-print-footer{display:flex;justify-content:space-between;gap:20px;margin-top:18px;padding-top:10px;border-top:1px solid #dce5e1;color:#65777d;font-size:9px}.report-print-footer span:last-child{text-align:right}@media print{.report-paper{page:accounting-report}.report-paper .invoice-header,.report-print-summary{break-inside:avoid}.report-paper .accounting-ledger{min-width:0!important}.report-paper .accounting-ledger thead{display:table-header-group}.report-paper .accounting-ledger tr{break-inside:avoid;page-break-inside:avoid}.report-paper .accounting-ledger th,.report-paper .accounting-ledger td{padding:2.5mm 1.8mm;font-size:8pt}.report-paper .accounting-ledger th{font-size:7pt}.report-print-footer{break-inside:avoid}@page accounting-report{size:A4 landscape;margin:10mm}}
.accounting-ledger .report-period th{padding:0;background:linear-gradient(110deg,#f4f8f8,#f8fafb);color:#526d79;text-align:left;border-top:1px solid #dfe9e9;border-bottom:1px solid #dfe9e9;text-transform:none;letter-spacing:0}.report-period th>div{display:flex;align-items:center;justify-content:space-between;gap:24px;padding:15px 16px}.report-period-title{display:grid;gap:6px;min-width:170px}.report-period-title>span{display:flex;align-items:center;gap:8px}.report-period-title small,.report-period-money small{color:#849392;font-size:9px;font-weight:500;line-height:1;letter-spacing:.9px;text-transform:uppercase}.report-period-title em{color:#91a09e;font-size:10px;font-style:normal;font-weight:400}.report-period-title em:before{content:'·';margin-right:8px;color:#aab6b5}.report-period-title>strong{color:#526d79;font-size:12px;font-weight:400;line-height:1.3;letter-spacing:0}.report-period-money{display:flex;align-items:center;justify-content:flex-end;gap:20px}.report-period-money>span{display:grid;gap:5px;text-align:right}.report-period-money strong{color:#526d79;font-size:11px;font-weight:500;font-variant-numeric:tabular-nums;letter-spacing:0}.report-period-money .received strong{color:#267d66}.report-period-money .outstanding strong{color:#ba654b}.accounting-ledger .report-credit-row td{color:#855f55}html[data-theme=dark] .accounting-ledger .report-period th{border-color:#30495a;background:linear-gradient(110deg,#142b3b,#112636)}html[data-theme=dark] .report-period-title>strong,html[data-theme=dark] .report-period-money strong{color:#dce9ef}html[data-theme=dark] .report-period-title small,html[data-theme=dark] .report-period-title em,html[data-theme=dark] .report-period-money small{color:#8fa5b1}html[data-theme=dark] .report-period-money .received strong{color:#77ceb1}html[data-theme=dark] .report-period-money .outstanding strong{color:#ef9b82}@media(max-width:900px){.report-period th>div{align-items:flex-start;flex-direction:column;gap:12px}.report-period-money{width:100%;justify-content:space-between}}@media print{.accounting-ledger .report-period{break-after:avoid;page-break-after:avoid}.accounting-ledger .report-period th{padding:0}.report-period th>div{padding:3mm 1.8mm}.report-period-title{gap:1.4mm}.report-period-title small,.report-period-money small{font-size:7pt}.report-period-title em{font-size:7.5pt}.report-period-title>strong,.report-period-money strong{font-size:8.5pt}.report-period-money{gap:5mm}}
/* Quotes */
.quote-summary{display:grid;grid-template-columns:repeat(3,1fr);gap:18px;margin-bottom:28px}.quote-summary article{padding:20px 22px;background:#fff;border:1px solid #dce7ea;border-radius:10px}.quote-summary small{display:block;color:#71848e;font-size:11px}.quote-summary strong{display:block;margin-top:8px;color:#17344b;font-size:25px}.badge.quote-accepted,.badge.quote-converted{color:#327a67;background:#e9f5ef}.badge.quote-rejected,.badge.quote-expired{color:#a94343;background:#ffeded}.badge.quote-pending{color:#8b681f;background:#fff5db}.button.compact{padding:7px 10px;font-size:11px}.button.accept{color:#246b58;background:#e9f5ef;border-color:#cce4da}html[data-theme=dark] .quote-summary article{background:#102535;border-color:#304d60}html[data-theme=dark] .quote-summary strong{color:#dce9ef}@media(max-width:650px){.quote-summary{grid-template-columns:1fr}}
.quote-summary+.panel .panel-top{padding-bottom:18px}
#quote-dialog{width:min(980px,96vw);overflow:hidden;background:#f5f8fa}#quote-form{display:flex;flex-direction:column;max-height:93vh}#quote-dialog .dialog-head{flex:0 0 auto;background:#fff;padding:22px 30px}#quote-body{overflow-y:auto;padding:24px 30px;scrollbar-gutter:stable}#quote-dialog .dialog-actions{flex:0 0 auto;padding:15px 30px;background:#fff;box-shadow:0 -8px 22px #18364d0b}@media(max-width:760px){#quote-dialog .dialog-head,#quote-body,#quote-dialog .dialog-actions{padding-left:18px;padding-right:18px}}@media(max-width:430px){#quote-dialog{width:100vw;max-width:100vw;height:100vh;max-height:100vh;border:0;border-radius:0}#quote-form{max-height:100vh}}
html[data-theme=dark] #quote-dialog{background:#0e1e2d}html[data-theme=dark] #quote-dialog .dialog-head,html[data-theme=dark] #quote-dialog .dialog-actions{border-color:#2b4355;background:#142839}
.quote-actions{display:flex;align-items:center;justify-content:flex-end;width:auto;gap:6px}.quote-action-main{display:flex;align-items:center;gap:6px;min-width:0}.quote-action-main small{margin:0 4px;text-align:center;white-space:nowrap}
.badge.credited{color:#327a67;background:#e9f5ef}.an-tooltip-key.an-key-credited{fill:#e6a16b}
.credit-notes-panel .panel-top{padding-bottom:18px}.an-line.an-credited-line{stroke:#e6a16b;stroke-width:2.5}.an-legend span.credited:before{background:#e6a16b}.credit-statement-summary{display:flex;gap:12px;margin:24px 0}.credit-statement-summary>div{flex:1;padding:14px 16px;background:#f4f7f6;border:1px solid #dce5e1;border-radius:8px}.credit-statement-summary span{display:block;color:#65777d;font-size:10px;text-transform:uppercase;letter-spacing:.6px}.credit-statement-summary strong{display:block;margin-top:7px;font-size:16px}.credit-statement-table{font-size:10px}.credit-statement-table th,.credit-statement-table td{padding:10px 7px}.credit-statement-table th:nth-child(5),.credit-statement-table td:nth-child(5){white-space:normal;min-width:160px}.credit-statement-table td:nth-child(n+6){white-space:nowrap;text-align:right}@media(max-width:760px){.credit-statement-summary{flex-direction:column}}
/* Payment tracking */
.badge.partial{color:#39798a;background:#e9f4f6}.payment-content{display:grid;gap:20px}.payment-overview{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}.payment-overview>div{padding:15px;border:1px solid #dce7ea;border-radius:9px;background:#f7fafb}.payment-overview small{display:block;margin-bottom:7px;color:#71848e;font-size:10px;text-transform:uppercase;letter-spacing:.6px}.payment-overview strong{color:#17344b;font-size:15px}.payment-overview .balance{background:#edf7f6;border-color:#cce4e1}.payment-history,.payment-entry{padding-top:18px;border-top:1px solid #e2eaed}.payment-history h3,.payment-entry h3{margin:0 0 13px;color:#294657;font-size:13px}.payment-record{display:flex;align-items:center;justify-content:space-between;gap:15px;padding:10px 12px;border-radius:8px;background:#f6f9fa}.payment-record+.payment-record{margin-top:7px}.payment-record span{min-width:0}.payment-record strong{display:block;color:#17344b;font-size:13px}.payment-record small{display:block;margin-top:4px;color:#748791;font-size:11px;overflow-wrap:anywhere}.payment-empty,.payment-legacy{margin:0;padding:13px 15px;border-radius:8px;background:#f5f8f9;color:#71838c;font-size:11px;line-height:1.55}.payment-legacy{background:#fff8e9;color:#806c46}.payment-received{margin-top:4px;padding-top:9px;border-top:1px solid #dce5e1;color:#26715f}.payment-entry input:disabled{background:#f1f4f5}.payment-entry h3+*{margin-top:0}
html[data-theme=dark] .payment-overview>div,html[data-theme=dark] .payment-record,html[data-theme=dark] .payment-empty{border-color:#304d60;background:#102535}html[data-theme=dark] .payment-overview .balance{border-color:#315c5d;background:#153438}html[data-theme=dark] .payment-overview strong,html[data-theme=dark] .payment-history h3,html[data-theme=dark] .payment-entry h3,html[data-theme=dark] .payment-record strong{color:#dce9ef}html[data-theme=dark] .payment-overview small,html[data-theme=dark] .payment-record small,html[data-theme=dark] .payment-empty{color:#94aab6}html[data-theme=dark] .payment-history,html[data-theme=dark] .payment-entry{border-color:#30495a}
@media(max-width:650px){.payment-overview{grid-template-columns:1fr 1fr}}
/* Invoice list grouped by billing period, with payment progress for each period. */
.invoice-list td{padding-top:16px;padding-bottom:16px;font-weight:400;color:#536b78}.invoice-list td strong,.invoice-list .row-link{font-weight:500;letter-spacing:-.08px}.invoice-list td>strong{color:#294657}.invoice-list .client-cell .row-link{font-size:12px}.invoice-list thead th{font-weight:500;letter-spacing:1px}.invoice-list .badge{font-weight:500}.invoice-period th{padding:0;border-top:1px solid #dfe9e9;border-bottom:1px solid #dfe9e9;background:linear-gradient(110deg,#f4f8f8,#f8fafb);text-transform:none;letter-spacing:0}.invoice-period th>div{display:flex;align-items:center;justify-content:space-between;gap:22px;padding:16px 24px}.invoice-period-title{display:grid;gap:7px;min-width:0}.invoice-period-title>span{display:flex;align-items:center;gap:8px}.invoice-period-title>span em:before{content:'·';margin-right:8px;color:#aab6b5}.invoice-period th small{color:#849392;font-size:9px;font-weight:500;line-height:1;letter-spacing:1.15px;text-transform:uppercase}.invoice-period th strong{color:#526d79;font-size:12px;font-weight:400;line-height:1.25;letter-spacing:0}.invoice-period th em{color:#91a09e;font-size:10px;font-style:normal;font-weight:400;line-height:1}.invoice-period-money{display:flex;align-items:center;justify-content:flex-end;gap:26px}.invoice-period-money span{display:grid;gap:5px;text-align:right}.invoice-period-money strong{font-size:13px;font-weight:500;font-variant-numeric:tabular-nums;letter-spacing:.05px}.invoice-period-empty{color:#91a09e;font-size:12px;font-weight:400}.invoice-period-money .received strong{color:#267d66}.invoice-period-money .outstanding strong{color:#ba654b}.invoice-period+tr td{border-top:0}
html[data-theme=dark] .invoice-list td{color:#a9bac4}html[data-theme=dark] .invoice-list td>strong,html[data-theme=dark] .invoice-list .row-link{color:#d7e3e9}html[data-theme=dark] .invoice-period th{border-color:#30495a;background:linear-gradient(110deg,#142b3b,#112636)}html[data-theme=dark] .invoice-period th strong{color:#dce9ef}html[data-theme=dark] .invoice-period th small,html[data-theme=dark] .invoice-period th em,html[data-theme=dark] .invoice-period-empty{color:#8fa5b1}html[data-theme=dark] .invoice-period-money .received strong{color:#77ceb1}html[data-theme=dark] .invoice-period-money .outstanding strong{color:#ef9b82}
@media(max-width:760px){.invoice-period th>div{align-items:flex-start;flex-direction:column;gap:13px;padding:16px 17px}.invoice-period-money{width:100%;justify-content:space-between;gap:12px}.invoice-period-money span{text-align:left}}
.invoice-toolbar-fields{display:flex;align-items:center;gap:12px;margin-left:auto}.period-filter{display:flex;align-items:center;gap:8px;color:#71848e;font-size:11px}.period-filter select{min-width:190px;height:40px;padding:0 34px 0 12px;border:1px solid #dce7ea;border-radius:7px;background:#fff;color:#526a78;font-size:12px;cursor:pointer}html[data-theme=dark] .period-filter{color:#94aab6}html[data-theme=dark] .period-filter select{border-color:#2d4659;background:#0f2030;color:#d7e3e9}@media(max-width:1100px){.invoice-toolbar-fields{width:100%;margin-left:0}.invoice-toolbar-fields .search{flex:1}}@media(max-width:650px){.invoice-toolbar-fields{align-items:stretch;flex-direction:column}.period-filter{justify-content:space-between}.period-filter select{flex:1;min-width:0}.invoice-toolbar-fields .search{width:100%}}
.reminder-panel{margin:0 0 28px;background:#fff;border:1px solid #dce7ea;border-radius:10px;overflow:hidden}.reminder-head{padding:20px 24px;border-bottom:1px solid #e5ecef}.reminder-head h2{margin:7px 0 5px;font-size:16px}.reminder-head p{margin:0;color:#71848e;font-size:12px}.reminder-list article{display:flex;align-items:center;gap:15px;padding:14px 24px;border-bottom:1px solid #edf1f3}.reminder-list article:last-child{border-bottom:0}.reminder-list article>div{min-width:0;flex:1}.reminder-list strong{display:block;color:#17344b;font-size:13px}.reminder-list small{display:block;margin-top:5px;color:#71848e;font-size:11px}.reminder-status{min-width:78px;padding:6px 8px;border-radius:6px;text-align:center;font-size:10px;font-weight:700}.reminder-status.due-soon{color:#8b681f;background:#fff5db}.reminder-status.overdue{color:#a94343;background:#ffeded}html[data-theme=dark] .reminder-panel{background:#102535;border-color:#304d60}html[data-theme=dark] .reminder-head,html[data-theme=dark] .reminder-list article{border-color:#30495a}html[data-theme=dark] .reminder-list strong{color:#dce9ef}html[data-theme=dark] .reminder-head p,html[data-theme=dark] .reminder-list small{color:#94aab6}@media(max-width:720px){.reminder-list article{align-items:flex-start;flex-wrap:wrap}.reminder-list article .button{width:100%}}

/* Collapsible invoice billing periods */
.invoice-period-gap td{height:12px;padding:0;border:0;background:#fff}html[data-theme=dark] .invoice-period-gap td{background:#122435}@media(max-width:760px){.invoice-period-gap td{height:9px}}
.invoice-list .invoice-period th{padding:0 10px;border:0;background:transparent}.invoice-period .invoice-period-toggle{border:1px solid #d8e5e8;border-radius:10px;background:linear-gradient(110deg,#f4f8f8,#f8fafb);box-shadow:0 3px 10px rgba(18,52,70,.035);transition:border-color .2s ease,box-shadow .2s ease,transform .2s ease}.invoice-period .invoice-period-toggle[aria-expanded=true]{border-radius:10px 10px 4px 4px}.invoice-period .invoice-period-toggle:hover{border-color:#bfd6d9;background:linear-gradient(110deg,#f1f7f7,#f6f9fa);box-shadow:0 6px 16px rgba(18,52,70,.08);transform:translateY(-1px)}.invoice-period .invoice-period-toggle:active{transform:translateY(0) scale(.998)}html[data-theme=dark] .invoice-list .invoice-period th{border:0;background:transparent}html[data-theme=dark] .invoice-period .invoice-period-toggle{border-color:#385368;background:linear-gradient(110deg,#142b3b,#112636);box-shadow:0 5px 16px rgba(0,0,0,.16)}html[data-theme=dark] .invoice-period .invoice-period-toggle:hover{border-color:#4b6c80;background:linear-gradient(110deg,#173041,#142a3b);box-shadow:0 8px 22px rgba(0,0,0,.24)}
.invoice-period-toggle{display:flex;width:100%;align-items:center;justify-content:space-between;gap:22px;padding:16px 24px;border:0;background:transparent;color:inherit;font:inherit;text-align:left;cursor:pointer}.invoice-period-toggle:hover{background:rgba(22,150,157,.045)}.invoice-period-toggle:focus-visible{position:relative;z-index:1;outline:2px solid #16969d;outline-offset:-2px}.invoice-period-summary{display:flex;align-items:center;gap:22px}.invoice-period-chevron{width:9px;height:9px;border-right:1.5px solid #78909b;border-bottom:1.5px solid #78909b;transform:rotate(45deg);transition:transform .18s ease;flex:0 0 auto}.invoice-period-toggle[aria-expanded=true] .invoice-period-chevron{transform:rotate(225deg)}
.invoice-period-toggle{position:relative;isolation:isolate;overflow:hidden}.invoice-period-toggle>.invoice-period-title,.invoice-period-toggle>.invoice-period-summary{position:relative;z-index:1}.period-colour-bar{display:none;position:absolute;z-index:0;inset:-20px -28px;opacity:.56;filter:blur(20px) saturate(.72);transform:scaleX(1.035);transition:opacity .22s ease,filter .22s ease}.invoice-period-toggle[aria-expanded=false]>.period-colour-bar{display:flex}.invoice-period-toggle[aria-expanded=false]:hover>.period-colour-bar{opacity:.66;filter:blur(18px) saturate(.78)}.period-colour-bar i{display:block;flex:1;box-shadow:0 0 30px currentColor}.period-colour-bar .paid{color:#55ad91;background:rgba(70,156,130,.34)}.period-colour-bar .overdue{color:#c76864;background:rgba(184,79,76,.32)}.period-colour-bar .issued{color:#c29a4e;background:rgba(184,139,57,.30)}html[data-theme=dark] .period-colour-bar .paid{color:#286b5d;background:rgba(31,92,79,.58)}html[data-theme=dark] .period-colour-bar .overdue{color:#753d42;background:rgba(105,48,54,.54)}html[data-theme=dark] .period-colour-bar .issued{color:#715b2e;background:rgba(100,78,35,.50)}
@media(max-width:760px){.invoice-period-toggle{align-items:flex-start;flex-direction:column;gap:13px;padding:16px 17px}.invoice-period-summary{width:100%;justify-content:space-between;gap:12px}.invoice-period-summary .invoice-period-money{flex:1;width:auto}}
.invoice-row.invoice-focus td{animation:invoice-focus-pulse 1.8s ease-out}@keyframes invoice-focus-pulse{0%,22%{box-shadow:inset 0 0 0 999px rgba(111,207,187,.16),inset 4px 0 #6fcfbb}100%{box-shadow:inset 0 0 0 999px transparent}}
/* Keep expanded invoice rows inside the billing-period card. */
.invoice-list table{border-collapse:separate;border-spacing:0}.invoice-list .invoice-period th{padding-left:0;padding-right:0}.invoice-period .invoice-period-toggle[aria-expanded=true]{border-bottom-color:transparent;border-radius:10px 10px 0 0;box-shadow:none}.invoice-period+tr td:first-child{border-left:1px solid #d8e5e8}.invoice-period+tr td:last-child{border-right:1px solid #d8e5e8}.invoice-row[data-invoice-period-row] td:first-child{border-left:1px solid #d8e5e8}.invoice-row[data-invoice-period-row] td:last-child{border-right:1px solid #d8e5e8}.invoice-row:has(+.invoice-period-gap) td:first-child,.invoice-list tbody>.invoice-row:last-child td:first-child{border-bottom-left-radius:10px}.invoice-row:has(+.invoice-period-gap) td:last-child,.invoice-list tbody>.invoice-row:last-child td:last-child{border-bottom-right-radius:10px}html[data-theme=dark] .invoice-period+tr td:first-child,html[data-theme=dark] .invoice-period+tr td:last-child,html[data-theme=dark] .invoice-row[data-invoice-period-row] td:first-child,html[data-theme=dark] .invoice-row[data-invoice-period-row] td:last-child{border-color:#385368}
/* Inset the complete ledger and visually attach its first period to the column header. */
.invoice-list table{width:calc(100% - 24px);margin:0 12px}.invoice-list tbody>.invoice-period:first-child .invoice-period-toggle{border-top-left-radius:0;border-top-right-radius:0}.invoice-list tbody>.invoice-period:first-child .invoice-period-toggle[aria-expanded=true]{border-radius:0}@media(max-width:760px){.invoice-list table{width:calc(100% - 16px);margin:0 8px}}

/* Branded confirmations replace the browser's native alert UI. */
.confirm-dialog{width:min(460px,calc(100vw - 32px));max-width:none;padding:0;overflow:hidden;border:1px solid #d7e4e7;border-radius:16px;background:#fff;box-shadow:0 26px 80px rgba(9,31,45,.28)}.confirm-dialog[open]{animation:confirm-in .18s cubic-bezier(.2,.8,.3,1)}.confirm-dialog::backdrop{background:rgba(5,20,30,.67);backdrop-filter:blur(5px)}.confirm-content{display:grid;grid-template-columns:48px 1fr;gap:17px;padding:28px 28px 24px}.confirm-symbol{display:grid;width:46px;height:46px;place-items:center;border-radius:14px;background:#fff0ed;color:#bc4c43;font-size:22px;font-weight:800}.confirm-content .eyebrow{display:block;margin:1px 0 8px;color:#16969d;font-size:9px;font-weight:800;letter-spacing:2px}.confirm-content h2{margin:0;color:#17344b;font-size:21px;line-height:1.25}.confirm-content p{margin:9px 0 0;color:#667d89;font-size:13px;line-height:1.6}.confirm-dialog .dialog-actions{padding:16px 28px;border-top:1px solid #e2eaed;background:#f8fafb}.confirm-dialog .danger-button{color:#fff;background:#bd4d45;border-color:#bd4d45}.confirm-dialog .danger-button:hover{background:#a9413a;border-color:#a9413a}.confirm-dialog .confirm-safe{color:#fff;background:#128c94;border-color:#128c94}@keyframes confirm-in{from{opacity:0;transform:translateY(10px) scale(.975)}to{opacity:1;transform:none}}html[data-theme=dark] .confirm-dialog{border-color:#365064;background:#12293a;box-shadow:0 30px 90px rgba(0,0,0,.55)}html[data-theme=dark] .confirm-content h2{color:#e3edf2}html[data-theme=dark] .confirm-content p{color:#9bb0bb}html[data-theme=dark] .confirm-symbol{background:#482d30;color:#ff9c91}html[data-theme=dark] .confirm-dialog .dialog-actions{border-color:#30495a;background:#102333}@media(max-width:520px){.confirm-content{grid-template-columns:40px 1fr;padding:23px 20px 20px}.confirm-symbol{width:40px;height:40px;border-radius:12px}.confirm-dialog .dialog-actions{padding:14px 20px}.confirm-dialog .dialog-actions .button{flex:1}}
