/* Hubble Klantsysteem — financiën */

.fin-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 20px; overflow-x: auto; }
.fin-tabs button { padding: 10px 14px; font-weight: 600; font-size: 14px; color: var(--muted); border-bottom: 2.5px solid transparent; margin-bottom: -1px; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.fin-tabs button:hover { color: var(--ink); }
.fin-tabs button.is-on { color: var(--ink); border-color: var(--orange); }
.fin-tabs .badge { font-size: 11px; padding: 3px 6px; }

.fin-period { display: flex; align-items: center; gap: 6px; margin-bottom: 14px; }
.fin-period .period-label { text-transform: capitalize; }
.fin-kpis .key { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.kpi-value.neg, .fin-minis b.neg, .owner strong.neg, .num.neg { color: #B7410E; }
.num.pos { color: var(--ink); }
.link-light { color: var(--orange); font-size: 12.5px; }

.fin-minis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; }
.fin-minis > div { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 12px 16px; display: flex; flex-direction: column; gap: 2px; }
.fin-minis small { color: var(--muted); font-size: 12px; font-weight: 500; }
.fin-minis b { font: 700 20px var(--heading); }
.fin-minis b span { font-size: 13px; color: var(--muted); font-weight: 600; }
.fin-minis em { font-style: normal; font-size: 11.5px; color: var(--muted-2); }
.fin-minis em.late { color: var(--orange-d); font-weight: 600; }

.fin-legend { align-items: center; flex-wrap: wrap; }
.lgd-sq { display: inline-block; width: 12px; height: 12px; border-radius: 3px; }
.lgd-hatch { background: repeating-linear-gradient(45deg, #8A857C 0 2px, #fff 2px 5px); border: 1px solid #8A857C; }
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart .grid { stroke: #EFEAE0; stroke-width: 1; }
.chart .baseline { stroke: #CFC7B7; stroke-width: 1; }
.chart .zero { stroke: #B7410E; stroke-width: 1; stroke-dasharray: 4 4; }
.chart .axis { fill: var(--muted); font: 500 11px var(--body); }
.chart .axis-strong { fill: var(--ink); font-weight: 700; }
.chart .cur-bg { fill: var(--orange-50); }
.chart .hit { cursor: default; outline: none; }
.chart .bar-group:hover path, .chart .bar-group:focus-within path { filter: brightness(1.08); }
.chart .hit:focus-visible { stroke: var(--ink); stroke-width: 1.5; }
.chart .line { fill: none; stroke: #3569A8; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { fill: #3569A8; opacity: .08; }
.chart .dot { fill: #3569A8; stroke: #fff; stroke-width: 2; }
.chart .dot.is-neg { fill: #B7410E; }
.chart-note { margin: 10px 0 0; }
.chart-tip { position: fixed; z-index: 100; pointer-events: none; background: var(--ink); color: #fff; border-radius: 10px; padding: 8px 12px; font-size: 12.5px; box-shadow: var(--shadow-lg); min-width: 170px; }
.chart-tip .tip-title { font-weight: 700; margin-bottom: 4px; text-transform: capitalize; }
.chart-tip div:not(.tip-title) { display: flex; flex-direction: row-reverse; justify-content: space-between; gap: 16px; }
.chart-tip span { color: #B9B4AA; }

.fin-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 18px; align-items: start; margin-top: 18px; }
.fin-grid .card + .card { margin-top: 0; }
.fin-grid > .card { margin-top: 0; }

.cat-bars { display: flex; flex-direction: column; gap: 4px; }
.cat-bar { display: grid; grid-template-columns: 170px minmax(0, 1fr) 80px; align-items: center; gap: 12px; padding: 5px 6px; margin: 0 -6px; border-radius: 8px; font-size: 13.5px; outline: none; }
.cat-bar:hover, .cat-bar:focus-visible { background: var(--paper); }
.cb-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cb-track { height: 10px; background: var(--sand); border-radius: 99px; overflow: hidden; }
.cb-track i { display: block; height: 100%; background: #E0561C; border-radius: 0 4px 4px 0; }
.cat-bar b { text-align: right; font-family: var(--heading); }

.fin-act { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 10px 12px; border-radius: 12px; background: var(--paper); margin-bottom: 8px; }
.fin-act:hover { background: var(--sand); }
.fin-act > .ic:first-child { color: var(--orange-d); }
.fin-act span { flex: 1; display: flex; flex-direction: column; }
.fin-act b { font-size: 13.5px; }
.fin-act small { color: var(--muted); font-size: 12px; }
.fin-act.is-late { background: var(--orange-50); }

.inc-list { padding: 4px 12px; }
.inc-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.inc-row + .inc-row { border-top: 1px solid #F1ECE2; }
.inc-main { flex: 1; min-width: 0; }
.inc-title { font-weight: 600; font-size: 14.5px; text-align: left; }
.inc-title:hover { color: var(--orange-d); }
.inc-amt { text-align: right; display: flex; flex-direction: column; }
.inc-amt b { font: 700 16px var(--heading); white-space: nowrap; }
.inc-amt small { color: var(--muted); font-size: 11.5px; white-space: nowrap; }
.inc-row.is-received .inc-title, .inc-row.is-received .inc-amt b { color: var(--muted-2); }
.inc-row.is-received .check { background: var(--orange); border-color: var(--orange); color: #fff; }
.inc-row.is-late .inc-amt b { color: #B7410E; }
.inc-match { display: flex; align-items: center; gap: 8px; margin-top: 8px; background: var(--orange-50); border-radius: 10px; padding: 6px 6px 6px 10px; font-size: 12.5px; flex-wrap: wrap; }
.inc-match .ic { color: var(--orange-d); width: 15px; }
.inc-match span { flex: 1; min-width: 180px; }
.inc-calc { margin: -4px 0 0; font-size: 13px; color: var(--muted); }
.inc-calc b { color: var(--ink); }
.fin-toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }

.fixed-list { display: flex; flex-direction: column; }
.fixed-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.fixed-row + .fixed-row { border-top: 1px solid #F1ECE2; }
.fixed-row.is-off { opacity: .5; }
.fx-ic { width: 34px; height: 34px; border-radius: 10px; background: var(--sand); display: grid; place-items: center; color: var(--muted); flex: none; }
.fx-ic .ic { width: 16px; }
.fx-main { flex: 1; min-width: 0; display: flex; flex-direction: column; text-align: left; }
.fx-main b { font-size: 14px; }
button.fx-main:hover b { color: var(--orange-d); }
.fx-main small { color: var(--muted); font-size: 12px; }
.fx-amt { text-align: right; display: flex; flex-direction: column; }
.fx-amt b { font: 700 15px var(--heading); white-space: nowrap; }
.fx-amt small { color: var(--muted); font-size: 11.5px; }
.rec-card { border-color: var(--orange-100); background: linear-gradient(180deg, var(--orange-50), #fff 50%); }
.rec-card h2 { display: flex; align-items: center; gap: 8px; }
.rec-card h2 .ic { color: var(--orange-d); }

.fin-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.fin-table th { text-align: left; font-size: 12px; font-weight: 700; color: var(--muted); padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.fin-table td { padding: 9px 12px; border-bottom: 1px solid #F3EEE5; vertical-align: middle; }
.fin-table tr.is-now td { background: #FFF9F5; font-weight: 600; }
.fin-table small { color: var(--muted); font-size: 11.5px; }
.fin-table .num { text-align: right; font-family: var(--heading); font-weight: 600; white-space: nowrap; }
.tx-table td:nth-child(2) { max-width: 360px; }
.tx-table td:nth-child(2) b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tx-table td:nth-child(2) small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tx-table tr.is-todo td { background: #FFFBF7; }
.tx-table tr.is-todo .cat-select { border-color: var(--orange); background: var(--orange-50); }
.nowrap { white-space: nowrap; }
.cat-select { height: 32px; border: 1px solid var(--line); border-radius: 8px; padding: 0 8px; background: var(--paper); font-size: 12.5px; max-width: 190px; }
.rule-tag { margin-left: 6px; background: var(--sand); border-radius: 99px; padding: 1px 6px; }
.tx-sum { margin: -6px 0 10px; }
.load-more { margin: 12px auto 0; display: flex; }
.imports { margin-top: 18px; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 12px 18px; }
.imports summary { cursor: pointer; font-weight: 700; }
.import-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid #F1ECE2; margin-top: 8px; }
.import-row span { display: flex; flex-direction: column; }
.import-row small { color: var(--muted); font-size: 12px; }
.euro-sm input { height: 32px; width: 110px; border: 1px solid var(--line); border-radius: 8px; padding: 0 8px 0 24px; background: var(--paper); }
.euro-sm span { left: 9px; font-size: 12.5px; }
.budget-cell { min-width: 160px; }
.budget-bar { display: block; height: 8px; background: var(--sand); border-radius: 99px; overflow: hidden; margin-bottom: 3px; }
.budget-bar i { display: block; height: 100%; background: #3569A8; border-radius: 99px; }
.budget-bar.is-near i { background: #C9962B; }
.budget-bar.is-over i { background: #B7410E; }

.import-sum { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.import-sum div { background: var(--paper); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; }
.import-sum b { font: 700 26px var(--heading); }
.import-sum small { color: var(--muted); font-size: 12px; }

.owners { display: flex; flex-direction: column; }
.owner { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.owner + .owner { border-top: 1px solid #F1ECE2; }
.owner > span:not(.avatar) { flex: 1; display: flex; flex-direction: column; }
.owner small { color: var(--muted); font-size: 12px; }
.owner strong { font: 700 17px var(--heading); }

.empty-mini { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 24px 12px; color: var(--muted); }
.empty-mini .ic { width: 28px; height: 28px; color: var(--orange); }
.empty-mini p { margin: 0; max-width: 300px; font-size: 13.5px; }

.fin-onboard { background: var(--ink); color: #fff; border-radius: 24px; padding: 32px; display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.4fr); gap: 32px; position: relative; overflow: hidden; }
.fin-onboard::after { content: ''; position: absolute; right: -50px; bottom: -70px; width: 220px; height: 220px; background: url(../assets/bb-oranje.svg) no-repeat center/contain; opacity: .12; }
.fo-text .eyebrow { color: var(--orange); }
.fo-text h2 { font-size: 30px; line-height: 1.1; }
.fo-text p { color: #B9B4AA; }
.fo-steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; position: relative; z-index: 1; }
.fo-steps li { display: flex; gap: 14px; background: #232220; border: 1px solid #2F2D2A; border-radius: 16px; padding: 16px; }
.fo-steps li > b { width: 30px; height: 30px; border-radius: 50%; background: var(--orange); color: var(--ink); display: grid; place-items: center; font: 700 14px var(--heading); flex: none; }
.fo-steps h3 { font-size: 16px; }
.fo-steps p { margin: 4px 0 10px; color: #B9B4AA; font-size: 13px; }
.fo-steps .btn:not(.btn-dark) { background: #2C2B28; border-color: #3A3834; color: #fff; }
.fo-steps .btn-dark { background: #fff; color: var(--ink); border-color: #fff; }

@media (max-width: 1100px) {
  .fin-grid { grid-template-columns: 1fr; }
  .fin-minis { grid-template-columns: 1fr 1fr; }
  .fin-onboard { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .cat-bar { grid-template-columns: 110px minmax(0, 1fr) 70px; }
  .tx-table td:nth-child(2) { max-width: 140px; }
  .import-sum { grid-template-columns: 1fr; }
}

/* ---------- facturen ---------- */
.inv-layout { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.inv-layout .col .card + .card { margin-top: 0; }
.inv-list { padding: 6px 16px; }
.inv-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; flex-wrap: wrap; }
.inv-row + .inv-row { border-top: 1px solid #F1ECE2; }
.inv-dot { width: 10px; height: 10px; border-radius: 50%; background: #B8B0A0; flex: none; }
.st-open .inv-dot { background: #3569A8; }
.st-vervallen .inv-dot { background: #B7410E; }
.st-betaald .inv-dot { background: var(--green); }
.st-concept .inv-dot { background: transparent; border: 2px dashed #B8B0A0; }
.inv-main { flex: 1; min-width: 160px; text-align: left; display: flex; flex-direction: column; }
.inv-main b { font-size: 14.5px; }
.inv-main:hover b { color: var(--orange-d); }
.inv-main small { color: var(--muted); font-size: 12px; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.inv-main small .ic { width: 12px; height: 12px; }
.inv-amt { text-align: right; display: flex; flex-direction: column; min-width: 100px; }
.inv-amt b { font: 700 15.5px var(--heading); white-space: nowrap; }
.inv-amt small { color: var(--muted); font-size: 11.5px; white-space: nowrap; }
.inv-row .inc-match { flex-basis: 100%; margin: 0 0 0 22px; }
.inv-pill { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 99px; background: var(--sand); color: var(--muted); white-space: nowrap; }
.inv-pill .ic { width: 12px; height: 12px; stroke-width: 2.6; }
.inv-open { background: #E7EEF7; color: #2B5588; }
.inv-vervallen { background: #FBE7E0; color: #B7410E; }
.inv-betaald { background: var(--green-50); color: var(--green); }
.inv-tips p { display: flex; gap: 10px; font-size: 13px; color: var(--muted); margin: 0 0 10px; }
.inv-tips .ic { color: var(--orange-d); flex: none; width: 16px; margin-top: 2px; }
.cb-track i.blue { background: #3569A8; }
.inv-mini .inv-row { padding: 9px 0; }

.inv-line { display: grid; grid-template-columns: 1.1fr 1.6fr 70px 84px 110px 70px 96px 34px; gap: 6px; align-items: center; margin-bottom: 6px; }
.inv-line input, .inv-line select { height: 36px; border: 1px solid var(--line); border-radius: 9px; padding: 0 8px; background: var(--paper); font-size: 13px; min-width: 0; width: 100%; }
.inv-line .euro input { padding-left: 22px; }
.inv-line .euro span { left: 8px; font-size: 12.5px; }
.inv-line-head { font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; margin-bottom: 4px; }
.inv-line-tot { text-align: right; font: 700 13.5px var(--heading); white-space: nowrap; }
.inv-line-actions { display: flex; gap: 4px; flex-wrap: wrap; margin: 4px 0 12px; }
.inv-totals { margin-left: auto; max-width: 300px; background: var(--paper); border-radius: 14px; padding: 12px 16px; margin-bottom: 14px; }
.inv-totals div { display: flex; justify-content: space-between; font-size: 13.5px; padding: 3px 0; }
.inv-totals .inv-grand { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 8px; font-size: 16px; }
.inv-totals .inv-grand b { font-family: var(--heading); }
.inv-replace .check-f { margin-bottom: 6px; }
.inv-due { margin: -4px 0 0; }
.f > .seg, .f > .share-row { flex: 1 0 100%; }
.f > span:first-child { font-size: 12.5px; font-weight: 600; }

.inv-preview-pop { position: absolute; inset: 0; background: rgba(250, 248, 243, .98); z-index: 5; overflow: auto; padding: 16px 24px 30px; }
.ipp-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; position: sticky; top: 0; }
.modal { position: relative; }
.invoice-wrap { background: var(--sand); padding: 24px; }
.invoice-doc { background: #fff; max-width: 760px; margin: 0 auto; padding: 48px 52px; border-radius: 6px; box-shadow: var(--shadow); color: var(--ink); font-size: 13.5px; }
.id-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; }
.id-head img { width: 150px; }
.id-company { text-align: right; font-size: 12px; color: var(--muted); line-height: 1.6; }
.invoice-doc h1 { font-size: 44px; margin: 36px 0 22px; }
.invoice-doc h1 span { color: var(--orange); }
.id-meta { display: flex; justify-content: space-between; gap: 24px; margin-bottom: 20px; }
.id-meta small { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--orange-d); }
.id-meta p { margin: 6px 0 0; line-height: 1.55; }
.id-meta dl { margin: 0; display: grid; gap: 4px; }
.id-meta dl div { display: flex; gap: 16px; justify-content: space-between; }
.id-meta dt { color: var(--muted); }
.id-meta dd { margin: 0; font-weight: 600; }
.id-subject { font-weight: 700; font-family: var(--heading); font-size: 16px; }
.id-lines { width: 100%; border-collapse: collapse; margin: 10px 0 18px; }
.id-lines th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); border-bottom: 2px solid var(--ink); padding: 8px 6px; }
.id-lines td { padding: 10px 6px; border-bottom: 1px solid #EDE8DE; }
.id-lines th:not(:first-child), .id-lines td:not(:first-child) { text-align: right; white-space: nowrap; }
.id-totals { margin-left: auto; width: 280px; }
.id-totals div { display: flex; justify-content: space-between; padding: 4px 0; }
.id-grand { border-top: 2px solid var(--ink); margin-top: 6px; padding-top: 10px !important; font-size: 17px; }
.id-grand b { font-family: var(--heading); color: var(--orange-d); }
.id-pay { margin: 26px 0 0; padding: 14px 16px; background: var(--paper); border-radius: 10px; }
.id-foot { display: flex; justify-content: space-between; gap: 12px; margin-top: 36px; padding-top: 14px; border-top: 1px solid #EDE8DE; font-size: 11.5px; color: var(--muted); }
.id-foot span { font-family: var(--heading); font-weight: 700; color: var(--ink); }
.id-foot i { color: var(--orange); font-style: normal; }
@media print {
  body * { visibility: hidden !important; }
  .invoice-doc, .invoice-doc * { visibility: visible !important; }
  .invoice-doc { position: absolute; left: 0; top: 0; width: 100%; max-width: none; box-shadow: none; padding: 0 8mm; }
  .backdrop { background: none; backdrop-filter: none; }
  @page { margin: 14mm; }
}

/* ---------- budgetten ---------- */
.pot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; align-items: start; margin-bottom: 18px; }
.pot { --accent: var(--orange); background: #fff; border: 1px solid var(--line); border-radius: 20px; padding: 18px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 8px; }
.pot header { display: flex; align-items: center; gap: 10px; }
.pot header > div { flex: 1; min-width: 0; }
.pot h3 { font-size: 16.5px; }
.pot header small { color: var(--muted); font-size: 12px; }
.pot-ic { width: 38px; height: 38px; border-radius: 12px; background: var(--accent); color: #fff; display: grid; place-items: center; flex: none; }
.pot-status { font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 99px; background: var(--green-50); color: var(--green); white-space: nowrap; }
.st-bijna .pot-status, .st-tempo .pot-status { background: #FFF4DA; color: #946B00; }
.st-over .pot-status { background: #FBE7E0; color: #B7410E; }
.pot-big { font: 700 30px/1.1 var(--heading); letter-spacing: -.02em; margin-top: 4px; }
.pot-big span { font-size: 15px; color: var(--muted); font-weight: 600; letter-spacing: 0; }
.pot-big.neg { color: #B7410E; }
.pot-track { position: relative; height: 12px; background: var(--sand); border-radius: 99px; }
.pot-track i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--accent); border-radius: 99px; }
.st-over .pot-track i { background: #B7410E; }
.pot-track em { position: absolute; top: -4px; bottom: -4px; width: 3px; margin-left: -1.5px; background: var(--ink); opacity: .5; border-radius: 2px; }
.pot-line { margin: 0; font-size: 12.5px; display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.pot-line .ic { width: 13px; height: 13px; }
.pot-hist { width: 100%; height: 50px; margin-top: 4px; }
.pot-hist rect { fill: #D8D1C3; }
.pot-hist rect.cur { fill: var(--accent); }
.pot-hist rect.over { fill: #B7410E; }
.pot-hist text { font: 500 8.5px var(--body); fill: var(--muted); }
.pot-hist-line { stroke: var(--ink); stroke-width: 1; stroke-dasharray: 3 3; opacity: .5; }
.pot-cats { display: flex; flex-wrap: wrap; gap: 4px; }
.pot-tx summary { cursor: pointer; font-size: 12.5px; font-weight: 600; color: var(--muted); }
.pot-tx div { display: flex; justify-content: space-between; font-size: 12.5px; padding: 4px 0; border-bottom: 1px solid #F3EEE5; }
.pot-add { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 260px; border: 2px dashed var(--sand-2); border-radius: 20px; color: var(--muted); text-align: center; padding: 20px; }
.pot-add .ic { width: 30px; height: 30px; color: var(--orange); }
.pot-add b { color: var(--ink); font-family: var(--heading); font-size: 17px; }
.pot-add span { font-size: 13px; }
.pot-add:hover { border-color: var(--orange); }
.pot-cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 6px 14px; }
.pot-cat-grid .is-used { color: var(--muted); }
.icon-pick { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.icon-pick input { position: absolute; opacity: 0; }
.icon-pick span { width: 38px; height: 38px; border-radius: 10px; background: var(--sand); display: grid; place-items: center; cursor: pointer; }
.icon-pick input:checked + span { background: var(--ink); color: #fff; }
.icon-pick input:focus-visible + span { outline: 2.5px solid var(--orange); }

/* ---------- winst & uitkeren ---------- */
.payout-hero { background: var(--ink); color: #fff; border-radius: 24px; padding: 28px 32px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; align-items: center; margin-bottom: 18px; position: relative; overflow: hidden; }
.payout-hero::after { content: ''; position: absolute; right: -40px; top: -60px; width: 200px; height: 200px; background: url(../assets/bb-oranje.svg) no-repeat center/contain; opacity: .12; }
.payout-hero .eyebrow { color: var(--orange); }
.ph-amount { font: 700 clamp(40px, 5vw, 60px)/1 var(--heading); letter-spacing: -.02em; }
.is-neg .ph-amount { font-size: 38px; }
.ph-sub { color: #B9B4AA; margin: 10px 0 0; }
.ph-split { display: flex; flex-direction: column; gap: 8px; position: relative; z-index: 1; }
.ph-person { display: flex; align-items: center; gap: 12px; background: #232220; border: 1px solid #2F2D2A; border-radius: 14px; padding: 10px 14px; }
.ph-person > span:not(.avatar) { flex: 1; display: flex; flex-direction: column; }
.ph-person small { color: #9D988E; font-size: 12px; }
.ph-person strong { font: 700 20px var(--heading); color: var(--orange); }
.ph-person .avatar { box-shadow: 0 0 0 2px var(--ink); }
.waterfall { display: flex; flex-direction: column; }
.wf-row { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) 96px; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid #F1ECE2; }
.wf-label { display: flex; flex-direction: column; }
.wf-label b { font-size: 13.5px; }
.wf-label small { color: var(--muted); font-size: 11.5px; }
.wf-bar { height: 10px; background: var(--sand); border-radius: 99px; overflow: hidden; }
.wf-bar i { display: block; height: 100%; border-radius: 99px; background: #3569A8; }
.wf-row.minus .wf-bar i { background: #E0561C; }
.wf-val { text-align: right; font-family: var(--heading); white-space: nowrap; }
.wf-row.total { border-bottom: 0; border-top: 2px solid var(--ink); margin-top: 4px; }
.wf-row.total .wf-bar i { background: var(--green); }
.wf-row.total .wf-val { font-size: 18px; }
.wf-row.total.neg .wf-val { color: #B7410E; }
.vat-q { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid #F1ECE2; cursor: pointer; }
.vat-q input { width: 18px; height: 18px; accent-color: var(--green); }
.vat-q span { flex: 1; display: flex; flex-direction: column; }
.vat-q small { color: var(--muted); font-size: 11.5px; }
.vat-q strong { font-family: var(--heading); }
.vat-q.is-paid strong { text-decoration: line-through; color: var(--muted-2); }
.be-meter { height: 14px; border-radius: 99px; background: var(--sand); overflow: hidden; margin: 8px 0; }
.be-meter i { display: block; height: 100%; background: #3569A8; border-radius: 99px; }
.be-line { margin: 0; font-size: 13px; display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.be-line .ic { width: 14px; color: var(--green); }
.profit-table .sum-row td { border-top: 2px solid var(--ink); background: var(--paper); }
.payout-note { display: flex; gap: 10px; align-items: flex-start; margin: 14px 0 0; background: var(--paper); border-radius: 12px; padding: 12px 14px; font-size: 13.5px; }
.payout-note .ic { color: #3569A8; flex: none; margin-top: 2px; }
.payout-settings { margin-bottom: 4px; }
.share-row { display: flex; gap: 14px; flex-wrap: wrap; }
.share-row label { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 500; }
.share-row input { width: 70px; height: 36px; border: 1px solid var(--line); border-radius: 9px; padding: 0 8px; background: var(--paper); }

@media (max-width: 1100px) {
  .inv-layout { grid-template-columns: 1fr; }
  .payout-hero { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .inv-line { grid-template-columns: 1fr 1fr 1fr; background: var(--paper); padding: 8px; border-radius: 12px; }
  .inv-line input, .inv-line select { background: #fff; }
  .inv-line [name=il_d] { grid-column: 1 / -1; }
  .inv-line-head { display: none; }
  .wf-row { grid-template-columns: minmax(0, 1fr) 90px; }
  .wf-bar { display: none; }
  .invoice-doc { padding: 24px; }
  .id-meta { flex-direction: column; }
}

/* ---------- Bunni-koppeling ---------- */
.bunni-btn small { font-weight: 500; color: var(--muted); margin-left: 2px; }
.bunni-btn small:empty { display: none; }
.is-loading { position: relative; pointer-events: none; opacity: .75; }
.is-loading .ic { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.bn-steps { margin: 0 0 16px; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; font-size: 13.5px; color: var(--muted); }
.bn-steps b { color: var(--ink); }
.bn-steps em { font-style: normal; font-weight: 700; color: var(--ink); }
.bn-adv { margin: 12px 0; font-size: 13px; }
.bn-adv summary { cursor: pointer; color: var(--muted); font-weight: 600; }
.bn-parts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 12px; }
.bn-part { display: flex; gap: 10px; align-items: flex-start; background: var(--paper); border-radius: 12px; padding: 10px 12px; }
.bn-part span { display: flex; flex-direction: column; }
.bn-part small { color: var(--muted); font-size: 12px; }
.bn-part.ok > .ic { color: var(--green); }
.bn-part.err > .ic { color: #B7410E; }
.bn-part.err small { color: #B7410E; }
.bn-sum { margin-bottom: 14px; }
.bn-note { margin: 0 24px; }
.bn-error { background: #FBE7E0; color: #B7410E; }
@media (max-width: 600px) { .bn-parts { grid-template-columns: 1fr; } }
