/* NORTHE Suite — Buchhaltung. Dunkel, NORTHE-Grünwelt (Variablen aus shell.css), Rot nur für Fehler/Überfälliges.
   Alle Klassen mit Präfix bh-. Mobil (< 760 px): einspaltig, Tabellen werden Karten, Eingaben 16 px, Tipp-Ziele >= 40 px. */

.bh-root,.bh-layer{--bh-t2:rgba(244,243,248,.62);--bh-t3:rgba(244,243,248,.44);--bh-line:rgba(255,255,255,.09);--bh-red:#F0726A;
  --bh-nr:var(--northe-rgb,139,226,27);-webkit-tap-highlight-color:transparent;}
.bh-root [hidden],.bh-layer [hidden],.bh-svg [hidden]{display:none !important;}
html.bh-lock,html.bh-lock body{overflow:hidden;}
/* Solange ein Buchhaltungs-Fenster offen ist, steht der bewegte Hintergrund der Suite still. Sonst muss der Weichzeichner hinter dem
   Fenster jedes Bild neu rechnen (gemessen 120 Neuzeichnungen je Sekunde ohne Eingabe) – das flackerte (Gene, 29.10.2026). */
html.bh-lock #ambient .amb,html.bh-lock #ambient .amb *{animation-play-state:paused !important;}
.bh-ic{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;flex:0 0 auto;}
.bh-root button,.bh-layer button{touch-action:manipulation;}
.bh-root .nbtn,.bh-layer .nbtn{white-space:nowrap;justify-content:center;}
.bh-root .nbtn.sm,.bh-layer .nbtn.sm{height:36px;padding:0 14px;font-size:12.5px;}

/* ---------- Kopf, Titel mit Punkt, Reiter ---------- */
.bh-head .bh-head-acts{display:flex;gap:10px;flex-wrap:wrap;}
.bh-title{display:inline-flex;align-items:center;gap:10px;user-select:none;-webkit-user-select:none;-webkit-touch-callout:none;touch-action:manipulation;cursor:default;}
.bh-dot{display:inline-block;width:9px;height:9px;border-radius:50%;margin-top:.45em;background:var(--northe);box-shadow:0 0 12px rgba(var(--northe-rgb),.9);transition:background .3s,box-shadow .3s;}
.bh-dot.demo{background:#fff;box-shadow:0 0 12px rgba(255,255,255,.75);}
.bh-tabs{display:flex;gap:4px;overflow-x:auto;scrollbar-width:none;padding:4px;margin:0 0 20px;border-radius:15px;background:rgba(255,255,255,.04);border:1px solid rgba(255,255,255,.08);width:fit-content;max-width:100%;-webkit-overflow-scrolling:touch;}
.bh-tabs::-webkit-scrollbar{display:none;}
.bh-tabs button{flex:0 0 auto;height:38px;padding:0 17px;border-radius:11px;border:1px solid transparent;background:transparent;color:var(--bh-t2);font:inherit;font-size:13.5px;font-weight:700;cursor:pointer;white-space:nowrap;transition:color .16s,background .16s,border-color .16s,box-shadow .16s;}
.bh-tabs button:hover{color:#fff;}
.bh-tabs button.on{color:#fff;background:rgba(var(--northe-rgb),.14);border-color:rgba(var(--northe-rgb),.45);box-shadow:0 0 0 1px rgba(var(--northe-rgb),.14),0 0 18px rgba(var(--northe-rgb),.22);}
.bh-body{min-height:240px;}

/* ---------- Gemeinsame Bausteine ---------- */
.bh-card{padding:20px 22px;margin-bottom:14px;}
.bh-main>.bh-card,.bh-lists>.bh-card,.bh-cts>.bh-card,.bh-cus>.bh-card{margin-bottom:0;}
.bh-ch{margin-bottom:14px;}
.bh-ch h2{margin:0;font-size:15px;font-weight:800;color:#fff;}
.bh-ch p{margin:3px 0 0;font-size:12.5px;color:var(--bh-t3);}
.bh-lab{font-size:10.5px;letter-spacing:.16em;text-transform:uppercase;color:var(--bh-t3);font-weight:600;}
.bh-none{padding:18px 4px;font-size:13px;color:var(--bh-t3);line-height:1.6;}
.bh-none a{color:var(--northe);}
.bh-foot-hint{margin:16px 2px 0;font-size:12px;color:var(--bh-t3);line-height:1.6;}
.bh-hint{font-size:12.5px;line-height:1.55;color:var(--bh-t3);margin:6px 0 10px;}
.bh-note{padding:11px 14px;border-radius:12px;border:1px solid rgba(var(--northe-rgb),.28);background:rgba(var(--northe-rgb),.07);font-size:13px;line-height:1.5;color:var(--g-pale);margin:0 0 12px;}
.bh-note.warn{border-color:rgba(var(--g-lime-rgb),.4);background:rgba(var(--g-lime-rgb),.08);color:var(--g-lime);}
.bh-note ul{margin:6px 0 0;padding-left:18px;} .bh-note li{margin:3px 0;} .bh-note b{color:#fff;}
.bh-link{background:none;border:0;color:var(--northe);font:inherit;font-size:12.5px;font-weight:600;cursor:pointer;padding:10px 6px;}
.bh-spin{display:inline-block;width:14px;height:14px;border-radius:50%;border:2px solid rgba(255,255,255,.28);border-top-color:#fff;animation:bhSpin .7s linear infinite;flex:0 0 auto;}
.is-busy{pointer-events:none;opacity:.8;}
.bh-over{font-size:12.5px;font-weight:700;color:var(--bh-red);}
.bh-left{margin-right:auto;}
.bh-msg{font-size:13px;line-height:1.5;}
.bh-msg.ok{color:var(--g-mint);} .bh-msg.err{color:var(--bh-red);}

/* Skeletons */
.bh-skel{height:14px;border-radius:7px;margin:9px 0;background:linear-gradient(90deg,rgba(255,255,255,.05),rgba(255,255,255,.12),rgba(255,255,255,.05));background-size:200% 100%;animation:bhShim 1.3s linear infinite;}
.bh-skel.w40{width:40%;} .bh-skel.w50{width:50%;} .bh-skel.w60{width:60%;} .bh-skel.w70{width:70%;} .bh-skel.w90{width:90%;}
.bh-skel.sm{height:10px;} .bh-skel.big{height:42px;width:72%;} .bh-skel.chart{height:200px;border-radius:12px;} .bh-skel.tall{height:520px;border-radius:14px;}

/* Status-Marken */
.bh-b{display:inline-flex;align-items:center;height:22px;padding:0 9px;border-radius:999px;font-size:11px;font-weight:700;letter-spacing:.03em;border:1px solid transparent;white-space:nowrap;}
.bh-b.draft{color:var(--bh-t2);border-color:rgba(255,255,255,.2);background:rgba(255,255,255,.05);}
.bh-b.open{color:var(--northe);border-color:rgba(var(--northe-rgb),.55);background:rgba(var(--northe-rgb),.06);}
.bh-b.part{color:var(--g-lime);border-color:rgba(var(--g-lime-rgb),.55);background:rgba(var(--g-lime-rgb),.07);}
.bh-b.paid{color:#07110a;background:var(--northe);border-color:var(--northe);box-shadow:0 0 14px rgba(var(--northe-rgb),.35);}
.bh-b.late{color:var(--bh-red);border-color:rgba(240,114,106,.55);background:rgba(240,114,106,.1);}
.bh-b.void{color:var(--bh-t3);border-color:rgba(255,255,255,.14);text-decoration:line-through;}
.bh-b.exp{color:var(--g-pale);opacity:.85;border-color:rgba(var(--g-moss-rgb),.55);background:rgba(var(--g-moss-rgb),.1);}
.bh-b.dec{color:var(--bh-t2);border:1px dashed rgba(255,255,255,.25);}
.bh-b.off{color:var(--g-pale);border-color:rgba(var(--g-moss-rgb),.55);background:rgba(var(--g-moss-rgb),.12);}
.bh-b.live{color:var(--northe);border-color:rgba(var(--northe-rgb),.55);background:rgba(var(--northe-rgb),.08);}
.bh-b.test{color:#F0C94A;border-color:rgba(240,201,74,.55);background:rgba(240,201,74,.09);}
.bh-tag{display:inline-block;margin-left:6px;padding:1px 7px;border-radius:6px;font-size:10.5px;border:1px solid rgba(255,255,255,.2);color:var(--bh-t2);text-transform:uppercase;letter-spacing:.08em;vertical-align:middle;}

/* ---------- Übersicht ---------- */
.bh-tiles{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:14px;}
.bh-tile{padding:20px 22px 18px;display:flex;flex-direction:column;align-items:flex-start;gap:10px;min-height:152px;text-align:left;font:inherit;color:inherit;appearance:none;-webkit-appearance:none;margin:0;}
button.bh-tile{cursor:pointer;transition:transform .16s,border-color .2s,box-shadow .2s;}
button.bh-tile:hover{transform:translateY(-2px);border-color:rgba(var(--northe-rgb),.4);}
button.bh-tile:focus-visible{outline:2px solid var(--northe);outline-offset:2px;}
.bh-tile.t1{background:radial-gradient(120% 90% at 0% 105%,rgba(var(--northe-rgb),.17),transparent 62%),linear-gradient(180deg,rgba(255,255,255,.06),rgba(255,255,255,.018));}
.bh-tile.t2{background:radial-gradient(120% 90% at 0% 105%,rgba(var(--g-mint-rgb),.14),transparent 62%),linear-gradient(180deg,rgba(255,255,255,.06),rgba(255,255,255,.018));}
.bh-tile.t3{background:radial-gradient(120% 90% at 0% 105%,rgba(var(--g-lime-rgb),.12),transparent 62%),linear-gradient(180deg,rgba(255,255,255,.06),rgba(255,255,255,.018));}
.bh-tile.t4{background:radial-gradient(120% 90% at 0% 105%,rgba(255,255,255,.07),transparent 62%),linear-gradient(180deg,rgba(255,255,255,.06),rgba(255,255,255,.018));}
.bh-num{display:block;max-width:100%;white-space:nowrap;font-size:clamp(30px,3.1vw,44px);font-weight:300;letter-spacing:.02em;line-height:1.05;font-variant-numeric:tabular-nums;color:#fff;}
.t1 .bh-num{color:var(--northe);text-shadow:0 0 28px rgba(var(--northe-rgb),.45);}
.t2 .bh-num{color:var(--g-mint);text-shadow:0 0 28px rgba(var(--g-mint-rgb),.4);}
.t3 .bh-num{color:var(--g-lime);text-shadow:0 0 28px rgba(var(--g-lime-rgb),.4);}
.t4 .bh-num{text-shadow:0 0 26px rgba(255,255,255,.22);}
.bh-sub{font-size:12.5px;color:var(--bh-t2);line-height:1.4;}
.bh-delta{display:inline-flex;align-items:center;gap:5px;font-size:12.5px;font-weight:700;color:var(--g-mint);flex-wrap:wrap;}
.bh-delta em{font-style:normal;font-weight:500;color:var(--bh-t3);margin-left:2px;}
.bh-delta.down{color:var(--bh-t2);} .bh-delta.down .bh-tri{transform:rotate(180deg);}
.bh-delta.flat{color:var(--bh-t3);font-weight:500;}
.bh-tri{width:9px;height:9px;fill:currentColor;}
.bh-chips{display:flex;gap:10px;flex-wrap:wrap;margin:0 0 14px;}
.bh-chips span{padding:8px 14px;border-radius:999px;border:1px solid var(--bh-line);background:rgba(255,255,255,.03);font-size:12.5px;color:var(--bh-t2);}
.bh-chips span b{color:#fff;font-weight:700;}
.bh-main{display:grid;grid-template-columns:minmax(0,1.55fr) minmax(0,1fr);gap:14px;margin-bottom:14px;}
.bh-lists{display:grid;grid-template-columns:repeat(auto-fit,minmax(300px,1fr));gap:14px;}
.bh-empty-hero{display:flex;flex-direction:column;align-items:center;text-align:center;padding:48px 24px 44px;
  background:radial-gradient(70% 90% at 50% 0%,rgba(var(--northe-rgb),.14),transparent 70%),linear-gradient(180deg,rgba(255,255,255,.05),rgba(255,255,255,.015));}
.bh-empty-ic{width:64px;height:64px;border-radius:20px;display:flex;align-items:center;justify-content:center;color:var(--northe);background:rgba(var(--northe-rgb),.1);border:1px solid rgba(var(--northe-rgb),.4);box-shadow:0 0 30px rgba(var(--northe-rgb),.3);margin-bottom:18px;}
.bh-empty-ic .bh-ic{width:28px;height:28px;}
.bh-empty-hero h2{margin:0 0 8px;font-size:22px;font-weight:800;color:#fff;}
.bh-empty-hero p{margin:0 0 22px;max-width:520px;font-size:14px;line-height:1.6;color:var(--bh-t2);}
.bh-empty-acts{display:flex;gap:10px;flex-wrap:wrap;justify-content:center;}

/* Diagramme */
.bh-chart{position:relative;min-height:200px;}
.bh-svg{display:block;width:100%;height:auto;touch-action:pan-y;overflow:visible;}
.bh-grid{stroke:rgba(255,255,255,.07);stroke-width:1;shape-rendering:crispEdges;}
.bh-grid.base{stroke:rgba(255,255,255,.18);}
.bh-axis{fill:rgba(244,243,248,.52);font-size:11px;font-family:inherit;font-variant-numeric:tabular-nums;}
.bh-axis.cur{fill:#fff;font-weight:700;}
.bh-val{fill:#fff;font-size:11px;font-weight:700;font-family:inherit;}
.bh-st1{stop-color:var(--northe);stop-opacity:.9;} .bh-st2{stop-color:var(--g-deep);stop-opacity:.5;}
.bh-st3{stop-color:var(--g-lime);stop-opacity:1;} .bh-st4{stop-color:var(--northe);stop-opacity:.34;} .bh-st5{stop-color:var(--northe);stop-opacity:0;}
.bh-bar.grow{transform-box:fill-box;transform-origin:50% 100%;animation:bhGrow .75s cubic-bezier(.2,.8,.2,1) both;}
.bh-hl{fill:rgba(255,255,255,.05);}
.bh-hit{fill:transparent;cursor:crosshair;}
.bh-line{fill:none;stroke:var(--northe);stroke-width:2;stroke-linejoin:round;stroke-linecap:round;filter:drop-shadow(0 0 6px rgba(var(--northe-rgb),.55));}
.bh-line.draw{stroke-dasharray:1;animation:bhDraw 1.2s ease-out both;}
.bh-area.fade{animation:bhFade 1.4s ease-out both;}
.bh-cross{stroke:rgba(255,255,255,.3);stroke-width:1;stroke-dasharray:3 3;}
.bh-dot2,.bh-end{fill:var(--northe);stroke:#05080a;stroke-width:2;}
.bh-end{filter:drop-shadow(0 0 6px rgba(var(--northe-rgb),.9));}
.bh-tip{position:absolute;left:0;top:0;z-index:5;pointer-events:none;min-width:160px;padding:10px 13px;border-radius:12px;background:rgba(9,13,9,.97);border:1px solid rgba(255,255,255,.15);box-shadow:0 14px 40px rgba(0,0,0,.65);font-size:12px;color:#fff;white-space:nowrap;}
.bh-tip-t{display:block;font-size:12.5px;margin-bottom:6px;color:#fff;}
.bh-tip-r{display:flex;justify-content:space-between;gap:18px;color:var(--bh-t2);line-height:1.7;}
.bh-tip-r b{color:#fff;font-weight:700;font-variant-numeric:tabular-nums;}

/* Top-Kunden (horizontale Balken, Werte in Textfarbe) */
.bh-hb{display:grid;grid-template-columns:minmax(0,1fr) minmax(60px,1.1fr) auto;align-items:center;gap:12px;width:100%;min-height:46px;padding:8px 0;background:none;border:0;border-bottom:1px solid var(--bh-line);color:inherit;font:inherit;text-align:left;cursor:pointer;}
.bh-hb:last-child{border-bottom:0;}
.bh-hb-n{font-size:13px;color:#fff;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.bh-hb-t{height:8px;border-radius:4px;background:rgba(255,255,255,.06);overflow:hidden;}
.bh-hb-t i{display:block;height:100%;width:0;border-radius:4px;background:linear-gradient(90deg,var(--g-deep),var(--northe));transition:width .9s cubic-bezier(.2,.8,.2,1);}
.bh-hb-v{font-size:13px;color:#fff;font-weight:600;font-variant-numeric:tabular-nums;text-align:right;}

/* Kurze Listen (Zuletzt / Als Nächstes) */
.bh-li{display:flex;align-items:center;gap:12px;width:100%;min-height:58px;padding:10px 0;background:none;border:0;border-bottom:1px solid var(--bh-line);color:inherit;font:inherit;text-align:left;cursor:pointer;}
.bh-li:last-child{border-bottom:0;}
.bh-li:hover .bh-li-m b{color:var(--northe);}
.bh-li-d{flex:0 0 44px;text-align:center;border:1px solid var(--bh-line);border-radius:11px;padding:5px 0 4px;background:rgba(255,255,255,.03);}
.bh-li-d b{display:block;font-size:15px;color:#fff;line-height:1.1;} .bh-li-d small{font-size:10.5px;letter-spacing:.1em;text-transform:uppercase;color:var(--bh-t3);}
.bh-li-m{flex:1;min-width:0;} .bh-li-m b{display:block;font-size:13.5px;color:#fff;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;transition:color .15s;}
.bh-li-m small{display:block;font-size:12px;color:var(--bh-t3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-top:2px;}
.bh-li-r{display:flex;flex-direction:column;align-items:flex-end;gap:4px;font-size:13px;font-weight:600;color:#fff;font-variant-numeric:tabular-nums;}
.bh-li-r small{font-size:11.5px;color:var(--bh-t3);font-weight:500;}

/* ---------- Belege: Filterzeile und Liste ---------- */
.bh-bar{display:flex;gap:12px 16px;justify-content:space-between;align-items:center;flex-wrap:wrap;margin-bottom:14px;}
.bh-chips-row{display:flex;gap:8px;flex-wrap:wrap;}
.bh-chip{height:36px;padding:0 14px;border-radius:999px;border:1px solid rgba(255,255,255,.12);background:rgba(255,255,255,.03);color:var(--bh-t2);font:inherit;font-size:12.5px;font-weight:700;cursor:pointer;display:inline-flex;align-items:center;gap:7px;transition:color .16s,border-color .16s,background .16s,box-shadow .16s;white-space:nowrap;}
.bh-chip:hover{color:#fff;border-color:rgba(255,255,255,.25);}
.bh-chip b{font-size:11px;color:var(--bh-t3);font-weight:700;}
.bh-chip.on{color:#fff;border-color:rgba(var(--northe-rgb),.55);background:rgba(var(--northe-rgb),.12);box-shadow:0 0 14px rgba(var(--northe-rgb),.22);}
.bh-chip.on b{color:var(--northe);}
.bh-tools{display:flex;gap:10px;align-items:center;flex-wrap:wrap;}
.bh-tools.wide{flex:1;}
.bh-search{position:relative;display:block;}
.bh-search .bh-ic{position:absolute;left:13px;top:50%;transform:translateY(-50%);width:16px;height:16px;color:var(--bh-t3);pointer-events:none;}
.bh-root .bh-tools .bh-search .kin{padding-left:38px;width:270px;}
.bh-root .bh-tools .bh-yearsel{width:140px;}
.bh-list{padding:0;overflow:hidden;margin-bottom:0;}
.bh-row{display:grid;grid-template-columns:112px minmax(0,1.7fr) 112px 118px 140px 118px;align-items:center;gap:14px;padding:13px 22px;min-height:62px;border-bottom:1px solid var(--bh-line);cursor:pointer;transition:background .15s;outline:none;}
.bh-row:hover,.bh-row:focus-visible{background:rgba(255,255,255,.04);}
.bh-row:focus-visible{box-shadow:inset 0 0 0 2px rgba(var(--northe-rgb),.5);}
.bh-row.head{cursor:default;min-height:0;padding-top:11px;padding-bottom:11px;font-size:10.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--bh-t3);font-weight:600;background:rgba(255,255,255,.02);}
.bh-row.head:hover{background:rgba(255,255,255,.02);} .bh-row.head .r{text-align:right;}
.bh-row.skel{display:block;cursor:default;}
.bh-c-no b{display:block;font-size:14px;color:#fff;letter-spacing:.01em;}
.bh-c-cu{min-width:0;} .bh-c-cu b{display:block;font-size:14px;color:#fff;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.bh-c-cu small{display:block;margin-top:2px;font-size:12px;color:var(--bh-t3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.bh-c-dt,.bh-c-du{font-size:13px;color:var(--bh-t2);font-variant-numeric:tabular-nums;}
.bh-c-dt small,.bh-c-du small{display:none;font-size:10.5px;letter-spacing:.1em;text-transform:uppercase;color:var(--bh-t3);}
.bh-c-du.late span{color:var(--bh-red);font-weight:600;}
.bh-c-am{text-align:right;} .bh-c-am b{display:block;font-size:14.5px;color:#fff;font-variant-numeric:tabular-nums;}
.bh-c-am small{display:block;margin-top:2px;font-size:11.5px;color:var(--bh-t3);}
.bh-row.void .bh-c-no b,.bh-row.void .bh-c-am b{text-decoration:line-through;color:var(--bh-t3);}
.bh-list-foot{padding:12px 22px;font-size:12px;color:var(--bh-t3);}
.bh-empty{display:flex;flex-direction:column;align-items:center;text-align:center;padding:48px 24px;gap:10px;}
.bh-empty>.bh-ic{width:38px;height:38px;color:var(--northe);opacity:.75;margin-bottom:4px;}
.bh-empty h3{margin:0;font-size:17px;font-weight:800;color:#fff;}
.bh-empty p{margin:0 0 8px;max-width:440px;font-size:13.5px;line-height:1.6;color:var(--bh-t2);}
.bh-fail{display:flex;flex-direction:column;align-items:center;text-align:center;padding:44px 24px;gap:10px;}
.bh-fail-ic{color:var(--bh-red);} .bh-fail-ic .bh-ic{width:34px;height:34px;}
.bh-fail h2{margin:0;font-size:18px;color:#fff;} .bh-fail p{margin:0 0 8px;max-width:460px;font-size:13.5px;line-height:1.6;color:var(--bh-t2);}

/* ---------- Ebenen: Sheets und Dialoge ---------- */
.bh-layer{position:fixed;inset:0;z-index:40;display:flex;opacity:0;transition:opacity .2s;}
.bh-layer.in{opacity:1;}
.bh-layer .bh-back{position:absolute;inset:0;background:rgba(1,3,1,.74);backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);}
.bh-layer.bh-sheet{align-items:center;justify-content:center;padding:18px;}
.bh-layer.bh-dialog{z-index:44;align-items:center;justify-content:center;padding:20px;}
.bh-panel{position:relative;display:flex;flex-direction:column;max-height:100%;min-width:0;color:#fff;overflow:hidden;border-radius:22px;border:1px solid rgba(255,255,255,.12);outline:none;
  background:radial-gradient(900px 420px at 100% -12%,rgba(var(--northe-rgb),.11),transparent 62%),linear-gradient(180deg,#0b100b,#050705);
  box-shadow:0 30px 90px rgba(0,0,0,.72),0 0 60px rgba(var(--northe-rgb),.07);}
.bh-layer.in .bh-panel{animation:bhPop .26s cubic-bezier(.2,.9,.3,1.08);}
/* Wechsel von einer Ebene in die nächste (Bearbeiten, Zum Original, Duplizieren …): ohne Einblenden und ohne Aufpoppen, die Abdunklung bleibt stehen */
.bh-layer.bh-noanim,.bh-layer.bh-noanim .bh-panel{transition:none !important;animation:none !important;}
.bh-layer.bh-noanim.in .bh-panel{animation:none !important;}
.bh-sheet .bh-panel{width:min(1320px,100%);height:100%;max-height:min(940px,100%);}
.bh-dialog .bh-panel{width:min(480px,100%);max-height:calc(100vh - 40px);max-height:calc(100dvh - 40px);}
.bh-dialog.bh-wide .bh-panel{width:min(760px,100%);}
.bh-dlg{padding:24px 24px 20px;display:flex;flex-direction:column;min-height:0;}
.bh-dlg h3{margin:0 0 8px;font-size:18px;font-weight:800;color:#fff;}
.bh-dlg-t{font-size:14px;line-height:1.6;color:var(--bh-t2);}
.bh-dlg-t b{color:#fff;}
.bh-form{min-height:0;}
.bh-dlg-head{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;margin-bottom:14px;}
.bh-dlg-head p{margin:2px 0 0;font-size:13px;color:var(--bh-t2);line-height:1.5;} .bh-dlg-head p b{color:#fff;}
.bh-dlg-body{flex:1 1 auto;overflow-y:auto;min-height:0;padding:2px 3px 2px 1px;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;}
.bh-dlg-acts{display:flex;gap:10px;justify-content:flex-end;margin-top:18px;flex-wrap:wrap;}
.bh-err{margin-top:12px;padding:10px 13px;border-radius:11px;border:1px solid rgba(240,114,106,.45);background:rgba(240,114,106,.09);color:var(--bh-red);font-size:13px;line-height:1.5;}

.bh-sh-head{display:flex;align-items:center;gap:14px;padding:16px 22px;border-bottom:1px solid var(--bh-line);flex:0 0 auto;}
.bh-x{display:inline-flex;align-items:center;justify-content:center;gap:6px;height:40px;padding:0 13px;border-radius:12px;border:1px solid rgba(255,255,255,.13);background:rgba(255,255,255,.04);color:#fff;font:inherit;font-size:13px;font-weight:700;cursor:pointer;transition:border-color .15s,background .15s;flex:0 0 auto;}
.bh-x:hover{border-color:rgba(255,255,255,.28);background:rgba(255,255,255,.08);}
.bh-x.ico{width:40px;padding:0;} .bh-x:disabled{opacity:.3;cursor:default;}
.bh-sh-title{min-width:0;} .bh-sh-title small{display:block;font-size:10.5px;letter-spacing:.16em;text-transform:uppercase;color:var(--bh-t3);font-weight:600;}
.bh-sh-title h2{margin:2px 0 0;font-size:20px;font-weight:800;color:#fff;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.bh-sh-head>.bh-b{margin-left:auto;}
.bh-dirty{margin-left:auto;font-size:12px;font-weight:700;color:var(--g-lime);}
.bh-sh-body{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;}

/* ---------- Formularfelder ---------- */
.bh-fld{display:flex;flex-direction:column;gap:6px;margin-bottom:12px;min-width:0;}
.bh-fld>label,.bh-it-grid label>span,.bh-it-sum>span{font-size:10.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--bh-t3);font-weight:600;}
.bh-root .kin,.bh-layer .kin{width:100%;height:44px;padding:0 13px;font-size:14px;border-radius:11px;background:rgba(0,0,0,.38);border:1px solid rgba(255,255,255,.14);color:#fff;font-family:inherit;transition:border-color .15s,box-shadow .15s;}
.bh-root .kin:focus,.bh-layer .kin:focus{border-color:rgba(var(--northe-rgb),.65);box-shadow:0 0 0 3px rgba(var(--northe-rgb),.14);}
.bh-root textarea.kin,.bh-layer textarea.kin{height:auto;min-height:84px;padding:11px 13px;line-height:1.5;resize:vertical;}
.bh-root select.kin,.bh-layer select.kin{appearance:none;-webkit-appearance:none;padding-right:38px;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23aab0a4' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 12px center;background-size:16px;}
.bh-root input[type=date].kin,.bh-layer input[type=date].kin,.bh-root input[type=time].kin,.bh-layer input[type=time].kin{color-scheme:dark;-webkit-appearance:none;appearance:none;min-height:44px;}
.bh-root input[type=search].kin{-webkit-appearance:none;appearance:none;}
.bh-grid2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 14px;}
.bh-check{display:flex;align-items:flex-start;gap:12px;min-height:44px;padding:9px 0;cursor:pointer;font-size:13.5px;line-height:1.45;color:var(--bh-t2);}
.bh-check input{width:20px;height:20px;accent-color:var(--northe);margin-top:1px;flex:0 0 auto;}
.bh-fs{border:1px solid var(--bh-line);border-radius:16px;padding:16px 18px 6px;margin-bottom:16px;background:rgba(255,255,255,.02);}
.bh-fs h3{margin:0 0 14px;font-size:11.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--northe);font-weight:700;}
.bh-fs.inner{margin:6px 0 16px;}
.bh-seg{display:inline-flex;flex-wrap:wrap;gap:2px;padding:3px;border-radius:12px;background:rgba(255,255,255,.05);border:1px solid rgba(255,255,255,.08);}
.bh-seg button{height:38px;padding:0 15px;border-radius:9px;border:1px solid transparent;background:transparent;color:var(--bh-t2);font:inherit;font-size:12.5px;font-weight:700;cursor:pointer;}
.bh-seg button.on{color:#fff;background:rgba(var(--northe-rgb),.15);border-color:rgba(var(--northe-rgb),.45);}
.bh-switch{position:relative;display:inline-flex;align-items:center;gap:10px;cursor:pointer;min-height:44px;flex:0 0 auto;}
.bh-switch input{position:absolute;opacity:0;width:1px;height:1px;}
.bh-sw{position:relative;width:52px;height:30px;border-radius:999px;background:rgba(255,255,255,.12);border:1px solid rgba(255,255,255,.2);transition:background .2s,border-color .2s,box-shadow .2s;flex:0 0 auto;}
.bh-sw::after{content:"";position:absolute;top:3px;left:3px;width:22px;height:22px;border-radius:50%;background:#fff;transition:transform .2s,background .2s;}
.bh-switch input:checked+.bh-sw{background:rgba(var(--northe-rgb),.88);border-color:var(--northe);box-shadow:0 0 16px rgba(var(--northe-rgb),.5);}
.bh-switch input:checked+.bh-sw::after{transform:translateX(22px);background:#07110a;}
.bh-switch input:focus-visible+.bh-sw{outline:2px solid #fff;outline-offset:2px;}
.bh-switch b{font-size:13px;color:#fff;min-width:2.2em;}

/* ---------- Beleg-Ansicht ---------- */
.bh-docv{display:grid;grid-template-columns:minmax(0,1fr) 392px;height:100%;}
.bh-docv-pv{grid-column:1;grid-row:1;padding:22px;overflow:auto;min-height:0;overscroll-behavior:contain;}
.bh-docv-side{grid-column:2;grid-row:1;border-left:1px solid var(--bh-line);padding:22px;display:flex;flex-direction:column;gap:18px;overflow:auto;min-height:0;overscroll-behavior:contain;}
.bh-total small{display:block;font-size:10.5px;letter-spacing:.16em;text-transform:uppercase;color:var(--bh-t3);font-weight:600;margin-bottom:4px;}
.bh-total>b{display:block;font-size:34px;font-weight:300;letter-spacing:.015em;line-height:1.1;font-variant-numeric:tabular-nums;color:#fff;text-shadow:0 0 26px rgba(var(--northe-rgb),.35);}
.bh-total>span{display:block;margin-top:6px;font-size:13px;color:var(--bh-t2);} .bh-total em{font-style:normal;color:var(--g-lime);font-weight:700;}
.bh-docv-side .bh-note{margin:0;}
.bh-acts{display:grid;grid-template-columns:1fr 1fr;gap:8px;}
.bh-acts .nbtn{height:auto;min-height:46px;padding:10px 12px;white-space:normal;text-align:left;justify-content:flex-start;line-height:1.25;font-size:13px;}
.bh-acts .nbtn:first-child{grid-column:1/-1;}
.bh-dl{margin:0;display:grid;gap:0;}
.bh-dl>div{display:flex;justify-content:space-between;gap:14px;padding:10px 0;border-bottom:1px solid var(--bh-line);}
.bh-dl dt{font-size:10.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--bh-t3);font-weight:600;padding-top:2px;}
.bh-dl dd{margin:0;font-size:13.5px;color:#fff;text-align:right;line-height:1.4;min-width:0;overflow-wrap:anywhere;}
.bh-dl dd small{color:var(--bh-t3);font-size:12px;} .bh-dl dd a{color:var(--northe);} .bh-dl .late{color:var(--bh-red);font-weight:700;}
.bh-sec h4,.bh-log summary{margin:0 0 6px;font-size:10.5px;letter-spacing:.16em;text-transform:uppercase;color:var(--bh-t3);font-weight:600;cursor:default;}
.bh-log summary{cursor:pointer;padding:6px 0;min-height:36px;display:flex;align-items:center;list-style:none;}
.bh-log summary::-webkit-details-marker{display:none;}
.bh-log summary::after{content:"";width:7px;height:7px;margin:-3px 0 0 10px;border-right:2px solid var(--bh-t3);border-bottom:2px solid var(--bh-t3);transform:rotate(45deg);transition:transform .2s;}
.bh-log[open] summary::after{transform:rotate(-135deg);margin-top:3px;}
.bh-pay{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:9px 0;border-bottom:1px solid var(--bh-line);}
.bh-pay b{display:block;font-size:14px;color:#fff;font-variant-numeric:tabular-nums;} .bh-pay small{display:block;margin-top:2px;font-size:12px;color:var(--bh-t3);line-height:1.4;}
.bh-log ul{margin:6px 0 0;padding:0;list-style:none;}
.bh-log li{display:grid;grid-template-columns:96px 1fr;gap:10px;padding:7px 0;font-size:12.5px;color:var(--bh-t2);line-height:1.45;border-bottom:1px solid var(--bh-line);}
.bh-log time{color:var(--bh-t3);font-variant-numeric:tabular-nums;} .bh-log li b{color:#fff;}

/* Vorschau (A4, skaliert) */
.bh-pv{position:relative;border-radius:12px;overflow:hidden;background:#050505;border:1px solid var(--bh-line);box-shadow:0 20px 50px rgba(0,0,0,.5);min-height:200px;}
.bh-pv-stage{position:relative;width:100%;overflow:hidden;}
.bh-pv-page{position:absolute;left:0;top:0;width:794px;transform-origin:0 0;}
.bh-pv-frame{position:absolute;left:0;top:0;width:794px;height:1123px;border:0;background:#050505;opacity:0;pointer-events:none;}
.bh-pv-frame.ready{opacity:1;}
.bh-pv-frame.fade{transition:opacity .18s;}
.bh-pv-msg{padding:56px 28px;text-align:center;color:var(--bh-t2);font-size:13.5px;line-height:1.65;}
.bh-pv.busy .bh-pv-stage{opacity:.72;}

/* ---------- Editor ---------- */
.bh-ed-switch{display:none;gap:6px;padding:10px 16px 10px;}
.bh-ed-switch button{flex:1;height:42px;border-radius:12px;border:1px solid rgba(255,255,255,.12);background:rgba(255,255,255,.03);color:var(--bh-t2);font:inherit;font-size:13.5px;font-weight:700;cursor:pointer;}
.bh-ed-switch button.on{color:#fff;border-color:rgba(var(--northe-rgb),.55);background:rgba(var(--northe-rgb),.13);}
.bh-sh-body.bh-ed{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);overflow:hidden;}
.bh-ed-form,.bh-ed-pv{overflow:auto;padding:22px;min-height:0;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;}
.bh-ed-form{border-right:1px solid var(--bh-line);}
.bh-pv-head{display:flex;justify-content:space-between;align-items:center;margin-bottom:10px;font-size:12.5px;color:var(--bh-t2);} .bh-pv-head b{color:#fff;font-size:13px;} .bh-pv-head span{color:var(--g-lime);font-size:12px;}
.bh-ed-foot{flex:0 0 auto;display:flex;gap:10px;justify-content:flex-end;flex-wrap:wrap;padding:14px 22px;border-top:1px solid var(--bh-line);background:rgba(0,0,0,.3);}
.bh-ed-loading{padding:26px;}
.bh-item{border:1px solid var(--bh-line);border-radius:14px;padding:12px 14px 14px;margin-bottom:12px;background:rgba(255,255,255,.02);}
.bh-item-h{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px;}
.bh-item-n{font-size:10.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--bh-t3);font-weight:600;}
.bh-item-mv{display:flex;gap:6px;}
.bh-item-mv .bh-x.ico{width:36px;height:36px;border-radius:10px;}
.bh-root .bh-it-desc,.bh-layer .bh-it-desc{min-height:62px;}
.bh-it-grid{display:grid;grid-template-columns:76px 96px minmax(0,1fr) 76px minmax(104px,auto);gap:10px;margin-top:10px;align-items:end;}
.bh-it-grid label{display:flex;flex-direction:column;gap:6px;min-width:0;}
.bh-it-sum{display:flex;flex-direction:column;gap:6px;align-items:flex-end;} .bh-it-sum b{display:flex;align-items:center;height:44px;font-size:15px;color:#fff;font-variant-numeric:tabular-nums;white-space:nowrap;}
.bh-add{width:100%;margin-bottom:6px;}
.bh-totals{margin:14px 0 12px auto;max-width:340px;border:1px solid var(--bh-line);border-radius:14px;padding:12px 16px;background:rgba(255,255,255,.03);}
.bh-totals>div{display:flex;justify-content:space-between;gap:16px;padding:4px 0;font-size:13px;color:var(--bh-t2);font-variant-numeric:tabular-nums;} .bh-totals b{color:#fff;}
.bh-totals .grand{margin-top:8px;padding-top:12px;border-top:1px solid var(--bh-line);font-size:17px;font-weight:800;color:#fff;align-items:baseline;}
.bh-totals .grand b{text-shadow:0 0 18px rgba(var(--northe-rgb),.45);}

/* ---------- Verträge ---------- */
.bh-auto{display:flex;align-items:center;justify-content:space-between;gap:22px;margin-bottom:18px;border-color:rgba(var(--northe-rgb),.28);background:radial-gradient(80% 140% at 0% 0%,rgba(var(--northe-rgb),.1),transparent 65%),linear-gradient(180deg,rgba(255,255,255,.055),rgba(255,255,255,.016));}
.bh-auto-t h2{margin:0 0 6px;font-size:16px;font-weight:800;color:#fff;} .bh-auto-t p{margin:0 0 6px;font-size:13.5px;line-height:1.6;color:var(--bh-t2);max-width:640px;} .bh-auto-t small{font-size:12px;color:var(--bh-t3);}
.bh-sechead{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:6px 2px 14px;} .bh-sechead h2{margin:0;font-size:17px;font-weight:800;color:#fff;}
.bh-cts{display:grid;grid-template-columns:repeat(auto-fill,minmax(340px,1fr));gap:14px;}
.bh-ct{display:flex;flex-direction:column;gap:14px;} .bh-ct.off{opacity:.7;}
.bh-ct header{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;}
.bh-ct header small{display:block;font-size:12px;color:var(--bh-t3);margin-bottom:3px;} .bh-ct h3{margin:0;font-size:16px;font-weight:800;color:#fff;overflow-wrap:anywhere;}
.bh-ct-amt{text-align:right;flex:0 0 auto;} .bh-ct-amt b{display:block;font-size:20px;font-weight:300;color:var(--northe);text-shadow:0 0 18px rgba(var(--northe-rgb),.4);font-variant-numeric:tabular-nums;} .bh-ct-amt span{font-size:12px;color:var(--bh-t3);}
.bh-ct-meta{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;} .bh-ct-meta small{display:block;font-size:10.5px;letter-spacing:.12em;text-transform:uppercase;color:var(--bh-t3);margin-bottom:3px;} .bh-ct-meta b{font-size:13.5px;color:#fff;font-variant-numeric:tabular-nums;}
.bh-ct-tags{display:flex;gap:8px;flex-wrap:wrap;}
.bh-ct footer{display:flex;gap:8px;flex-wrap:wrap;align-items:center;}
a.bh-link{display:inline-flex;align-items:center;min-height:40px;text-decoration:none;}

/* ---------- Geplante Rechnungen (Reiter Verträge) ---------- */
.bh-plan{margin-bottom:18px;scroll-margin-top:84px;}
.bh-pl-warn{margin-bottom:14px;}
.bh-pl-g+.bh-pl-g{margin-top:20px;}
.bh-pl-h{margin:0 2px 4px;font-size:11.5px;letter-spacing:.14em;text-transform:uppercase;color:var(--northe);font-weight:700;}
.bh-pl-row{display:grid;grid-template-columns:64px minmax(0,1fr) auto auto;grid-template-areas:"d m a b" "d x x x";gap:8px 14px;align-items:center;padding:14px 0;border-top:1px solid var(--bh-line);}
.bh-pl-g>.bh-pl-h+.bh-pl-row{border-top:0;}
.bh-pl-row.off .bh-pl-d,.bh-pl-row.off .bh-pl-m,.bh-pl-row.off .bh-pl-a{opacity:.55;}
.bh-pl-d{grid-area:d;display:block;text-align:center;align-self:start;}
.bh-pl-d .bh-li-d{display:block;flex:none;width:52px;margin:0 auto;}
.bh-pl-d s{display:block;margin-top:4px;font-size:10.5px;line-height:1.2;color:var(--bh-t3);white-space:nowrap;}
.bh-pl-m{grid-area:m;min-width:0;}
.bh-pl-m b{display:block;font-size:14px;color:#fff;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.bh-pl-m small{display:block;margin-top:2px;font-size:12px;color:var(--bh-t3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.bh-pl-a{grid-area:a;display:flex;flex-direction:column;align-items:flex-end;gap:2px;}
.bh-pl-a b{font-size:15px;font-weight:600;color:#fff;font-variant-numeric:tabular-nums;white-space:nowrap;}
.bh-pl-a small{font-size:11.5px;color:var(--bh-t3);}
.bh-pl-b{grid-area:b;display:flex;gap:6px;flex-wrap:wrap;justify-content:flex-end;}
.bh-pl-x{grid-area:x;display:flex;align-items:center;gap:8px;flex-wrap:wrap;}
.bh-pl-x .nbtn.sm{height:40px;padding:0 13px;gap:6px;}
.bh-pl-sw{margin-right:6px;}
.bh-pl-has::after{content:"";width:7px;height:7px;border-radius:50%;background:var(--northe);box-shadow:0 0 8px rgba(var(--northe-rgb),.8);margin-left:2px;flex:0 0 auto;}
.bh-pl-more{width:100%;height:44px;margin-top:16px;}
.bh-plan-link{margin-top:6px;padding-left:2px;}
.bh-count{align-self:flex-end;font-size:11.5px;color:var(--bh-t3);font-variant-numeric:tabular-nums;}
.bh-plpv{width:100%;max-width:980px;margin:0 auto;padding:22px;display:flex;flex-direction:column;gap:6px;}
.bh-plpv .bh-seg{align-self:flex-start;}
.bh-plpv .bh-hint{margin:6px 0 12px;}
.bh-mpv{position:relative;border-radius:12px;overflow:hidden;background:#010101;border:1px solid var(--bh-line);min-height:200px;}
.bh-plpv .bh-mpv{max-width:640px;width:100%;margin:0 auto;}
.bh-mpv-frame{display:block;width:100%;height:640px;border:0;background:#010101;}
.bh-mpv-frame:not(.ready){position:absolute;left:0;top:0;opacity:0;pointer-events:none;}
.bh-mpv.busy .bh-mpv-frame.ready{opacity:.7;}
.bh-mpv-msg{padding:56px 24px;text-align:center;color:var(--bh-t2);font-size:13.5px;line-height:1.65;}
.bh-mpv-fs{margin-bottom:6px;}
@container bh (min-width:1280px){
  .bh-pl-row{grid-template-columns:64px minmax(0,1fr) 124px 210px auto;grid-template-areas:"d m a b x";}
  .bh-pl-b{justify-content:flex-start;}
}
@container bh (max-width:680px){
  .bh-pl-row{grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"d b" "m a" "x x";gap:10px 12px;padding:16px 0;}
  .bh-pl-d{display:flex;align-items:center;gap:10px;text-align:left;}
  .bh-pl-d .bh-li-d{margin:0;}
  .bh-pl-d s{margin:0;font-size:11.5px;}
  .bh-pl-x{display:grid;grid-template-columns:minmax(0,1.3fr) minmax(0,1fr) minmax(0,1fr);gap:8px;}
  .bh-pl-sw{grid-column:1/-1;margin:0;}
  .bh-pl-x .nbtn.sm{height:44px;padding:0 6px;font-size:12.5px;}
  .bh-pl-x .nbtn.sm .bh-ic{display:none;}
}
@media (max-width:760px){
  .bh-plpv{padding:16px 14px;}
}

/* Vertrag hineinziehen: Ablagefläche über der Vertragsliste */
.bh-drop{position:relative;display:flex;flex-wrap:wrap;align-items:center;gap:16px;margin:0 0 18px;padding:18px 20px;cursor:pointer;border:1.5px dashed rgba(var(--northe-rgb),.45);
  background:radial-gradient(90% 160% at 0% 0%,rgba(var(--northe-rgb),.10),transparent 62%),linear-gradient(180deg,rgba(255,255,255,.05),rgba(255,255,255,.016));transition:border-color .16s,box-shadow .16s,background .16s;}
.bh-drop input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer;font-size:0;}
.bh-drop:hover,.bh-drop.over,.bh-drop:focus-within{border-color:var(--northe);box-shadow:0 0 0 1px rgba(var(--northe-rgb),.25),0 0 30px rgba(var(--northe-rgb),.2);}
.bh-drop.over{background:radial-gradient(90% 160% at 0% 0%,rgba(var(--northe-rgb),.22),transparent 62%),rgba(var(--northe-rgb),.06);}
.bh-drop.busy{cursor:progress;border-style:solid;} .bh-drop.busy input{pointer-events:none;}
.bh-drop-ic{flex:0 0 auto;width:52px;height:52px;border-radius:16px;display:flex;align-items:center;justify-content:center;color:var(--northe);background:rgba(var(--northe-rgb),.1);border:1px solid rgba(var(--northe-rgb),.4);box-shadow:0 0 24px rgba(var(--northe-rgb),.25);}
.bh-drop-ic .bh-ic{width:24px;height:24px;}
.bh-drop-t{flex:1 1 220px;min-width:0;display:flex;flex-direction:column;gap:3px;}
.bh-drop-t b{font-size:16px;font-weight:800;color:#fff;} .bh-drop-t span{font-size:13px;line-height:1.5;color:var(--bh-t2);}
.bh-drop-btn{flex:0 0 auto;pointer-events:none;}
.bh-drop-err{flex:1 1 100%;order:9;padding:10px 13px;border-radius:11px;border:1px solid rgba(240,114,106,.45);background:rgba(240,114,106,.09);color:var(--bh-red);font-size:13px;line-height:1.5;}
.bh-spin.big{width:26px;height:26px;border-width:3px;border-color:rgba(var(--northe-rgb),.25);border-top-color:var(--northe);}

/* ---------- Kunden ---------- */
.bh-cus{display:grid;grid-template-columns:repeat(auto-fill,minmax(310px,1fr));gap:14px;}
.bh-cu{cursor:pointer;transition:transform .16s,border-color .16s,box-shadow .2s;display:flex;flex-direction:column;gap:16px;outline:none;}
.bh-cu:hover,.bh-cu:focus-visible{transform:translateY(-2px);border-color:rgba(var(--northe-rgb),.42);box-shadow:inset 0 1px 0 rgba(255,255,255,.18),0 18px 50px rgba(0,0,0,.6),0 0 30px rgba(var(--northe-rgb),.14);}
.bh-cu.off{opacity:.65;}
.bh-cu-h{display:flex;align-items:center;gap:13px;min-width:0;} .bh-cu-h>div{flex:1;min-width:0;}
.bh-cu-flag{flex:0 0 46px;width:46px;height:46px;border-radius:14px;display:flex;align-items:center;justify-content:center;font-size:22px;background:rgba(255,255,255,.06);border:1px solid rgba(255,255,255,.12);box-shadow:0 0 18px rgba(var(--northe-rgb),.14);}
.bh-cu-h b{display:block;font-size:15.5px;font-weight:700;color:#fff;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;} .bh-cu-h small{display:block;margin-top:3px;font-size:12px;color:var(--bh-t3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.bh-cu-st{display:flex;justify-content:space-between;gap:12px;} .bh-cu-st small{display:block;white-space:nowrap;font-size:10.5px;letter-spacing:.12em;text-transform:uppercase;color:var(--bh-t3);margin-bottom:3px;} .bh-cu-st b{font-size:15px;font-weight:700;color:#fff;font-variant-numeric:tabular-nums;}
.bh-cu-tags{display:flex;gap:6px;flex-wrap:wrap;} .bh-cu-tags span{padding:3px 10px;border-radius:999px;border:1px solid var(--bh-line);background:rgba(255,255,255,.03);font-size:11.5px;color:var(--bh-t2);}

/* ---------- Einstellungen ---------- */
.bh-card.bh-set{scroll-margin-top:84px;padding:0;margin-bottom:10px;}
.bh-set-s{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:16px 22px;min-height:60px;box-sizing:border-box;cursor:pointer;list-style:none;border-radius:inherit;-webkit-tap-highlight-color:transparent;}
.bh-set-s::-webkit-details-marker{display:none;}
.bh-set-s .bh-ch{margin:0;min-width:0;}
.bh-set-s::after{content:"";flex:0 0 auto;width:9px;height:9px;margin-right:4px;border-right:2px solid var(--bh-t2);border-bottom:2px solid var(--bh-t2);transform:rotate(45deg);transition:transform .16s;}
.bh-set[open]>.bh-set-s::after{transform:rotate(-135deg);}
@media (hover:hover){ .bh-set-s:hover .bh-ch h2{color:var(--g-lime);} }
.bh-set-s:focus-visible{outline:2px solid rgba(var(--northe-rgb),.6);outline-offset:-2px;}
.bh-set[open]>.bh-set-s{border-bottom:1px solid var(--bh-line);border-bottom-left-radius:0;border-bottom-right-radius:0;}
.bh-set>.bh-set-b{padding:18px 22px 0;}
.bh-set>.bh-set-b:last-child{padding-bottom:20px;}
.bh-set>.bh-set-f{padding:0 22px 20px;}
/* Am Handy zeigt die geschlossene Liste nur die Titel, so passen alle Bereiche ohne Scrollen auf einen Bildschirm */
@container bh (max-width:680px){ .bh-set:not([open]) .bh-set-s p{display:none;} .bh-set-s{padding:14px 18px;min-height:54px;} .bh-set>.bh-set-b{padding:16px 18px 0;} .bh-set>.bh-set-b:last-child{padding-bottom:18px;} .bh-set>.bh-set-f{padding:0 18px 18px;} }
.bh-set-f{display:flex;align-items:center;gap:14px;margin-top:12px;flex-wrap:wrap;}
.bh-bank{border:1px solid var(--bh-line);border-radius:14px;padding:14px 14px 12px;margin-bottom:12px;background:rgba(255,255,255,.02);}
.bh-bank-t{margin:0 0 10px;} .bh-adds{display:flex;gap:10px;flex-wrap:wrap;}
.bh-stripe-st{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:0 0 14px;font-size:13.5px;font-weight:600;color:#fff;}
.bh-stripe-st>span:not(.bh-b){color:var(--bh-t2);font-weight:500;}
.bh-set-b .bh-adds{margin-top:6px;}
.bh-pushlist{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px;}
.bh-pushlist li{display:flex;align-items:baseline;justify-content:space-between;gap:6px 14px;flex-wrap:wrap;padding:10px 12px;border:1px solid var(--bh-line);border-radius:12px;background:rgba(255,255,255,.02);}
.bh-pushlist b{font-size:14px;color:#fff;} .bh-pushlist span{font-size:12.5px;color:var(--bh-t2);}
.bh-set-b .bh-msg{margin:12px 0 0;}
.bh-set-b .bh-adds + .bh-fs.inner,.bh-set-b .bh-msg + .bh-fs.inner{margin-top:16px;}
.bh-note.err{border-color:rgba(240,114,106,.45);background:rgba(240,114,106,.09);color:var(--bh-red);}
.bh-root .kin.bh-mono{font-family:ui-monospace,"SF Mono",Menlo,Consolas,monospace;font-size:13px;letter-spacing:.01em;}
.bh-numrow{display:grid;grid-template-columns:104px repeat(3,minmax(0,1fr));gap:0 12px;align-items:end;padding:6px 0 4px;border-bottom:1px solid var(--bh-line);margin-bottom:12px;}
.bh-numrow>b{font-size:14px;color:#fff;padding-bottom:20px;}
.bh-numprev{grid-column:2/-1;margin:-4px 0 8px;font-size:12.5px;color:var(--g-pale);}
.bh-taxrow h4,.bh-mt h4{margin:0 0 8px;font-size:13px;font-weight:700;color:#fff;}
.bh-taxrow{margin-bottom:6px;}
.bh-ph{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-top:6px;} .bh-ph>span{font-size:12px;color:var(--bh-t3);}
.bh-ph .bh-chip{height:34px;font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:12px;}
#mtKind{margin-bottom:14px;}
.bh-testrow{display:flex;gap:10px;flex-wrap:wrap;align-items:center;} .bh-root .bh-testrow .kin{flex:1;min-width:210px;width:auto;}

/* Hinweis (Toast), falls die Suite keins mitbringt */
.bh-toast{position:fixed;left:50%;bottom:calc(24px + env(safe-area-inset-bottom,0px));transform:translate(-50%,14px);z-index:80;max-width:calc(100vw - 28px);padding:12px 18px;border-radius:13px;background:rgba(14,18,14,.97);border:1px solid rgba(var(--northe-rgb),.35);box-shadow:0 14px 44px rgba(0,0,0,.65);color:#fff;font-size:13.5px;line-height:1.45;opacity:0;pointer-events:none;transition:opacity .22s,transform .22s;}
.bh-toast.show{opacity:1;transform:translate(-50%,0);}

/* ---------- Animationen ---------- */
@keyframes bhSpin{to{transform:rotate(360deg);}}
@keyframes bhShim{from{background-position:200% 0;}to{background-position:-200% 0;}}
@keyframes bhGrow{from{transform:scaleY(0);}to{transform:scaleY(1);}}
@keyframes bhDraw{from{stroke-dashoffset:1;}to{stroke-dashoffset:0;}}
@keyframes bhFade{from{opacity:0;}to{opacity:1;}}
@keyframes bhPop{from{transform:translateY(14px) scale(.985);opacity:.2;}to{transform:none;opacity:1;}}
@media (prefers-reduced-motion:reduce){
  .bh-skel,.bh-spin,.bh-bar.grow,.bh-line.draw,.bh-area.fade,.bh-layer.in .bh-panel{animation:none !important;}
  .bh-hb-t i,.bh-layer,.bh-toast,.bh-sw,.bh-sw::after,button.bh-tile,.bh-cu{transition:none !important;}
}

/* ---------- Breite Bildschirme klein → Umschalter im Editor ---------- */
@media (max-width:979px){
  .bh-ed-switch{display:flex;}
  .bh-sh-body.bh-ed{display:block;overflow:auto;}
  .bh-ed-form{border-right:0;overflow:visible;padding:18px 18px 8px;}
  .bh-ed-pv{display:none;overflow:visible;padding:18px;}
  .bh-ed.show-pv .bh-ed-form{display:none;}
  .bh-ed.show-pv .bh-ed-pv{display:block;}
  .bh-docv{grid-template-columns:minmax(0,1fr) 340px;}
  .bh-tiles{grid-template-columns:repeat(2,minmax(0,1fr));}
  .bh-main{grid-template-columns:minmax(0,1fr);}
}

/* ---------- Handy (< 760 px): einspaltig, Karten statt Tabellen, große Tipp-Ziele ---------- */
@media (max-width:900px){
  .bh-root .kin,.bh-layer .kin{font-size:16px;}
}
@media (max-width:760px){
  .bh-root .bh-tools .bh-yearsel{width:128px;}
  .bh-head{margin-bottom:16px !important;}
  .bh-head .bh-head-acts{width:100%;} .bh-head .bh-head-acts .nbtn{flex:1;height:46px;}
  .bh-tabs{width:100%;margin-bottom:16px;border-radius:14px;mask-image:linear-gradient(to right,#000 calc(100% - 22px),transparent);-webkit-mask-image:linear-gradient(to right,#000 calc(100% - 22px),transparent);}
  .bh-tabs button{height:44px;padding:0 15px;}
  .bh-card{padding:16px 16px;}
  .bh-tiles{gap:10px;} .bh-tile{padding:15px 15px 14px;min-height:134px;gap:8px;} .bh-num{font-size:clamp(22px,6.4vw,30px);}
  .bh-lab{font-size:10.5px;letter-spacing:.12em;}
  .bh-chips span{padding:9px 13px;}
  .bh-chip{height:42px;} .bh-bar{align-items:stretch;} .bh-tools{width:100%;} .bh-tools .bh-search{flex:1;min-width:0;}
  .bh-root .bh-tools .bh-search .kin{width:100%;}
  .bh-chips-row{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;margin:0 -2px;padding:2px;width:100%;-webkit-overflow-scrolling:touch;} .bh-chips-row::-webkit-scrollbar{display:none;}
  .bh-hb{min-height:48px;gap:10px;grid-template-columns:minmax(0,1fr) auto;} .bh-hb-t{grid-column:1/-1;grid-row:2;} .bh-hb{row-gap:6px;}
  /* Tabelle wird Karte */
  .bh-list{background:none;border:0;box-shadow:none;overflow:visible;} .bh-list::before,.bh-list::after{display:none;}
  .bh-row.head{display:none;}
  .bh-row{grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"no st" "cu cu" "dt am" "du am";gap:4px 12px;padding:14px 16px;margin-bottom:10px;min-height:76px;border:1px solid rgba(255,255,255,.1);border-radius:16px;background:linear-gradient(180deg,rgba(255,255,255,.055),rgba(255,255,255,.016));}
  .bh-row.skel{padding:14px 16px;}
  .bh-c-no{grid-area:no;} .bh-c-st{grid-area:st;justify-self:end;} .bh-c-cu{grid-area:cu;margin:2px 0 4px;} .bh-c-dt{grid-area:dt;} .bh-c-du{grid-area:du;} .bh-c-am{grid-area:am;align-self:end;}
  .bh-c-dt small,.bh-c-du small{display:inline;margin-right:6px;}
  .bh-c-am b{font-size:17px;}
  .bh-list-foot{padding:4px 4px 12px;}
  .bh-empty{padding:34px 16px;}
  /* Ebenen: Sheets vollflächig, Dialoge als Blatt von unten */
  .bh-layer.bh-sheet{padding:0;}
  .bh-sheet .bh-panel{width:100%;height:100%;max-height:100%;border-radius:0;border:0;}
  .bh-layer.bh-dialog{align-items:flex-end;padding:0;}
  .bh-dialog .bh-panel,.bh-dialog.bh-wide .bh-panel{width:100%;max-height:92vh;max-height:92dvh;border-radius:22px 22px 0 0;border-bottom:0;}
  .bh-dlg{padding:20px 18px calc(18px + env(safe-area-inset-bottom,0px));}
  .bh-dlg-acts{display:grid;grid-template-columns:1fr 1fr;gap:8px;} .bh-dlg-acts .nbtn{width:100%;height:48px;padding:0 8px;} .bh-dlg-acts .nbtn:not(.ghost){grid-column:1/-1;order:-1;} .bh-dlg-acts .bh-left{margin-right:0;}
  .bh-dialog.bh-wide .bh-panel{height:calc(100vh - 28px);height:calc(100dvh - 28px);max-height:none;}
  .bh-dialog.bh-wide .bh-dlg,.bh-dialog.bh-wide .bh-form{flex:1;min-height:0;}
  .bh-sh-head{padding:calc(12px + env(safe-area-inset-top,0px)) 14px 12px;gap:10px;}
  .bh-x{height:44px;} .bh-x.ico{width:44px;} .bh-item-mv .bh-x.ico{width:42px;height:42px;}
  .bh-sh-title h2{font-size:18px;}
  .bh-docv{display:block;height:auto;} .bh-docv-side,.bh-docv-pv{overflow:visible;padding:18px 16px;} .bh-docv-side{border-left:0;border-bottom:1px solid var(--bh-line);}
  .bh-total>b{font-size:30px;}
  .bh-acts .nbtn{min-height:50px;}
  .bh-log li{grid-template-columns:82px 1fr;}
  .bh-ed-foot{display:grid;grid-template-columns:1fr 1fr;gap:8px;padding:12px 14px calc(12px + env(safe-area-inset-bottom,0px));}
  .bh-ed-foot .nbtn{height:48px;padding:0 8px;font-size:12.5px;} .bh-ed-foot .nbtn.primary{grid-column:1/-1;order:-1;font-size:14px;}
  .bh-ed-form{padding:16px 14px 8px;} .bh-ed-pv{padding:14px;}
  .bh-fs{padding:14px 14px 4px;}
  .bh-it-grid{grid-template-columns:1fr 1fr;} .bh-it-sum{grid-column:1/-1;flex-direction:row;justify-content:space-between;align-items:center;} .bh-it-sum b{height:auto;}
  .bh-totals{max-width:none;margin-left:0;}
  .bh-auto{flex-direction:column;align-items:flex-start;gap:12px;}
  .bh-cts,.bh-cus{grid-template-columns:minmax(0,1fr);}
  .bh-ct-meta{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;} .bh-ct-meta b{font-size:12.5px;}
  .bh-ct footer .nbtn{flex:1;height:46px;}
  .bh-sechead .nbtn{height:44px;}
  .bh-adds .nbtn{flex:1 1 100%;height:46px;} .bh-root .kin.bh-mono{font-size:16px;}
  .bh-drop{flex-direction:column;text-align:center;padding:22px 16px;gap:12px;} .bh-drop-t{flex:0 0 auto;align-items:center;width:100%;}
  .bh-drop-btn{width:100%;height:48px;justify-content:center;} .bh-drop-err{flex:0 0 auto;width:100%;text-align:left;}
  .bh-numrow{grid-template-columns:repeat(3,minmax(0,1fr));} .bh-numrow>b{grid-column:1/-1;padding-bottom:8px;} .bh-numprev{grid-column:1/-1;}
  .bh-set-f .nbtn{height:46px;min-width:140px;}
  .bh-testrow .nbtn{width:100%;height:46px;}
  .bh-seg button{height:42px;}
  .bh-toast{bottom:calc(var(--mbh,64px) + var(--safe-b,0px) + 14px);}
  .bh-layer .bh-toast{bottom:calc(20px + env(safe-area-inset-bottom,0px));}
  .bh-tip{min-width:140px;}
}
@media (max-width:480px){
  .bh-grid2{grid-template-columns:minmax(0,1fr);}
  .bh-grid2.keep{grid-template-columns:repeat(2,minmax(0,1fr));}
  .bh-tiles{grid-template-columns:repeat(2,minmax(0,1fr));}
}

/* ---------- Mittlere Breiten: es zählt die Breite des Bereichs (Fenster minus Seitenleiste), nicht die des Fensters ---------- */
.bh-root{container:bh / inline-size;}
@container bh (max-width:1020px){
  .bh-row{grid-template-columns:92px minmax(0,1fr) 96px 128px 104px;gap:12px;padding:12px 18px;}
  .bh-row>.bh-c-du,.bh-row.head>:nth-child(4){display:none;}
}
@container bh (max-width:680px){
  .bh-list{background:none;border:0;box-shadow:none;overflow:visible;} .bh-list::before,.bh-list::after{display:none;}
  .bh-row.head{display:none;}
  .bh-row{grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"no st" "cu cu" "dt am" "du am";gap:4px 12px;padding:14px 16px;margin-bottom:10px;min-height:76px;border:1px solid rgba(255,255,255,.1);border-radius:16px;background:linear-gradient(180deg,rgba(255,255,255,.055),rgba(255,255,255,.016));}
  .bh-row>.bh-c-du{display:block;}
  .bh-c-no{grid-area:no;} .bh-c-st{grid-area:st;justify-self:end;} .bh-c-cu{grid-area:cu;margin:2px 0 4px;} .bh-c-dt{grid-area:dt;} .bh-c-du{grid-area:du;} .bh-c-am{grid-area:am;align-self:end;}
  .bh-c-dt small,.bh-c-du small{display:inline;margin-right:6px;}
  .bh-tiles{grid-template-columns:repeat(2,minmax(0,1fr));}
}

/* Einrichtungs-Hinweis oben in der Übersicht */
.bh-setup{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;padding:16px 20px;margin-bottom:14px;border-color:rgba(var(--g-lime-rgb),.35);
  background:linear-gradient(90deg,rgba(var(--g-lime-rgb),.10),rgba(var(--g-lime-rgb),.02));}
.bh-setup-t{display:flex;flex-direction:column;gap:4px;min-width:0;flex:1 1 320px;}
.bh-setup-t b{font-size:14.5px;color:#fff;} .bh-setup-t span{font-size:12.5px;line-height:1.5;color:var(--bh-t2);}
.bh-setup-acts{display:flex;gap:8px;flex-wrap:wrap;}
@container bh (max-width:680px){ .bh-setup-acts{width:100%;} .bh-setup-acts .nbtn{flex:1;height:44px;justify-content:center;} }

/* Wise: Geldeingänge ohne Zuordnung (oben in der Übersicht) */
.bh-wise{border-color:rgba(var(--g-lime-rgb),.35);background:linear-gradient(90deg,rgba(var(--g-lime-rgb),.09),rgba(var(--g-lime-rgb),.015));}
.bh-wxs{display:flex;flex-direction:column;}
.bh-wx{display:flex;align-items:center;justify-content:space-between;gap:12px 18px;flex-wrap:wrap;padding:14px 0;border-top:1px solid var(--bh-line);}
.bh-wx:first-child{border-top:0;padding-top:2px;} .bh-wx:last-child{padding-bottom:2px;}
.bh-wx-i{display:flex;align-items:center;gap:14px;min-width:0;flex:1 1 300px;}
.bh-wx-m{display:flex;flex-direction:column;gap:2px;min-width:0;}
.bh-wx-am{font-size:18px;color:#fff;font-variant-numeric:tabular-nums;line-height:1.2;}
.bh-wx-s{font-size:13px;color:var(--bh-t2);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.bh-wx-r{display:block;font-size:12px;color:var(--bh-t3);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.bh-wx-old{font-style:normal;font-size:10.5px;letter-spacing:.04em;margin-left:6px;padding:1px 7px;border-radius:999px;border:1px solid rgba(255,255,255,.18);color:var(--bh-t3);}
.bh-wx-a{display:flex;align-items:center;gap:10px;flex:1 1 420px;justify-content:flex-end;flex-wrap:wrap;min-width:0;}
.bh-wx-a select{flex:1 1 240px;min-width:0;max-width:520px;}
.bh-wx-none{font-size:12.5px;color:var(--bh-t3);}
.bh-wx-a .bh-link{padding:10px 8px;}
@container bh (max-width:680px){
  .bh-wx-a{flex-basis:100%;justify-content:stretch;} .bh-wx-a select{flex:1 1 100%;max-width:none;}
  .bh-wx-a .nbtn{flex:1 1 auto;height:44px;} .bh-wx-a .bh-link{margin:0 auto;}
}
.bh-tile-n{display:block;margin-top:6px;font-size:11.5px;color:var(--bh-t3);}
