/* FDO-Neu: Oberfläche. Hell/Dunkel automatisch, Farben als Variablen. */
:root { --bg:#f3f4f9; --surface:#fff; --surface2:#f7f8fc; --txt:#1b1f33; --muted:#6a7090; --line:#e3e5ef; --brand:#3f4fd8; --brand-ink:#fff; --danger:#c0392b; --ok:#1e8e3e; --warn:#b7791f; --info:#2563eb;
    --side:#161a38; --side-txt:#b9bedc; --side-hi:#fff; --side-line:#262b52; --r:12px; --shadow:0 1px 2px rgba(20,24,60,.06), 0 6px 20px -12px rgba(20,24,60,.18); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --bg:#0f111c; --surface:#181b2b; --surface2:#1d2033; --txt:#e8eaf6; --muted:#9aa0c0; --line:#2a2e45; --brand:#7c8cff; --brand-ink:#0d1020; --danger:#ff7b6b; --ok:#5fd38a; --warn:#e8b64a; --info:#6ea8ff;
    --side:#0b0d18; --side-txt:#9aa0c0; --side-hi:#fff; --side-line:#1d2036; --shadow:0 1px 2px rgba(0,0,0,.4), 0 8px 24px -12px rgba(0,0,0,.6); } }
:root[data-theme="dark"] { --bg:#0f111c; --surface:#181b2b; --surface2:#1d2033; --txt:#e8eaf6; --muted:#9aa0c0; --line:#2a2e45; --brand:#7c8cff; --brand-ink:#0d1020; --danger:#ff7b6b; --ok:#5fd38a; --warn:#e8b64a; --info:#6ea8ff;
    --side:#0b0d18; --side-txt:#9aa0c0; --side-hi:#fff; --side-line:#1d2036; --shadow:0 1px 2px rgba(0,0,0,.4), 0 8px 24px -12px rgba(0,0,0,.6); }
:root[data-theme="light"] { color-scheme: light; } :root[data-theme="dark"] { color-scheme: dark; }
* { box-sizing:border-box; } html { -webkit-text-size-adjust:100%; }
body { margin:0; font:13.5px/1.45 system-ui,-apple-system,"Segoe UI",Roboto,sans-serif; background:var(--bg); color:var(--txt); }
a { color:var(--brand); text-decoration:none; } .muted { color:var(--muted); } .block { display:block; } .sr { position:absolute; left:-9999px; } .grow { flex:1; }
svg.i { flex:none; }

/* ---------- Gerüst: Seitenleiste + Inhalt ---------- */
body.has-side { display:flex; min-height:100vh; }
.side { width:220px; flex:none; background:var(--side); color:var(--side-txt); display:flex; flex-direction:column; position:sticky; top:0; height:100vh; overflow-y:auto; z-index:40; }
.brand { display:flex; align-items:center; gap:10px; padding:11px 14px; color:var(--side-hi); border-bottom:1px solid var(--side-line); }
.logo { background:var(--brand); color:var(--brand-ink); font-weight:800; letter-spacing:.5px; padding:6px 9px; border-radius:9px; font-size:13.5px; }
.bn { display:grid; font-weight:700; line-height:1.15; } .bn small { font-weight:600; color:var(--side-txt); font-size:11.5px; letter-spacing:.6px; }
.menu { padding:8px 8px 14px; display:grid; gap:1px; flex:1; align-content:start; }
.menu a, .menu .off, .menu summary { display:flex; align-items:center; gap:10px; padding:6px 10px; border-radius:8px; color:var(--side-txt); font-weight:600; cursor:pointer; list-style:none; }
.menu summary::-webkit-details-marker { display:none; } .menu summary .chev { margin-left:auto; transition:transform .15s; } .menu details[open] > summary .chev { transform:rotate(180deg); }
.menu a:hover, .menu summary:hover { background:rgba(255,255,255,.06); color:var(--side-hi); }
.menu a.on, .menu a.top-item.on { background:var(--brand); color:var(--brand-ink); }
.menu .off { opacity:.4; cursor:not-allowed; }
.sub { display:grid; gap:1px; margin:1px 0 4px 16px; padding-left:10px; border-left:1px solid var(--side-line); }
.sub a, .sub .off { padding:5px 9px; font-weight:500; font-size:13.5px; }
.side-foot { padding:8px 14px; border-top:1px solid var(--side-line); font-size:12.5px; opacity:.7; }
.shell { flex:1; min-width:0; display:flex; flex-direction:column; }
.top { display:flex; align-items:center; gap:10px; padding:5px 14px; background:var(--surface); border-bottom:1px solid var(--line); position:sticky; top:0; z-index:20; min-height:42px; }
.today { color:var(--muted); font-size:13.5px; } .burger { display:inline-flex; background:none; border:0; color:var(--txt); cursor:pointer; padding:6px; }
.umenu { position:relative; } .umenu summary { display:flex; align-items:center; gap:10px; cursor:pointer; list-style:none; padding:4px 8px; border-radius:10px; } .umenu summary::-webkit-details-marker { display:none; } .umenu summary:hover { background:var(--surface2); }
.avatar { width:28px; height:28px; border-radius:50%; background:color-mix(in srgb, var(--brand) 18%, transparent); color:var(--brand); display:grid; place-items:center; font-weight:700; }
.uname { display:grid; line-height:1.2; font-weight:600; } .uname small { font-weight:500; color:var(--muted); font-size:12.5px; }
.pop { position:absolute; right:0; top:calc(100% + 6px); min-width:210px; background:var(--surface); border:1px solid var(--line); border-radius:12px; box-shadow:var(--shadow); padding:6px; z-index:50; }
.pop a, .pop button { display:flex; align-items:center; gap:10px; width:100%; padding:9px 12px; border:0; background:none; font:inherit; color:var(--txt); border-radius:8px; cursor:pointer; text-align:left; } .pop a:hover, .pop button:hover { background:var(--surface2); }
main { padding:12px 16px 16px; width:100%; margin:0; } body:not(.has-side):not(.embed) main { max-width:1100px; margin:0 auto; } body.embed main { padding:10px 14px 14px; }
.scrim { position:fixed; inset:0; background:rgba(8,10,25,.5); z-index:35; } .scrim[hidden] { display:none; }

/* ---------- Bausteine ---------- */
.card { background:var(--surface); border:1px solid var(--line); border-radius:var(--r); padding:14px 16px; margin-bottom:12px; box-shadow:var(--shadow); } .card h2 { margin:0 0 8px; font-size:15px; } .card.flush { padding:0; overflow:hidden; } .card.narrow { max-width:460px; } .card.slim { padding:7px 12px; }
.card h2 small { font-size:12.5px; font-weight:500; }
.btn { display:inline-flex; align-items:center; gap:7px; font:inherit; font-weight:600; border:1px solid transparent; border-radius:8px; padding:6px 12px; cursor:pointer; background:var(--brand); color:var(--brand-ink); text-decoration:none; white-space:nowrap; }
.btn:hover { filter:brightness(1.07); } .btn.ghost { background:transparent; border-color:var(--line); color:var(--txt); } .btn.ghost:hover { background:var(--surface2); filter:none; } .btn.sm { padding:4px 9px; font-size:12.5px; } .btn.disabled { opacity:.45; cursor:not-allowed; }
label { display:block; font-weight:600; font-size:12.5px; margin:8px 0 3px; }
input[type=text], input[type=email], input[type=password], input[type=search], input[type=date], input[type=time], input[type=number], select, textarea { font:inherit; padding:5px 8px; border-radius:8px; border:1px solid var(--line); background:var(--bg); color:var(--txt); max-width:100%; }
input:focus, select:focus, textarea:focus { outline:2px solid color-mix(in srgb, var(--brand) 55%, transparent); outline-offset:1px; }
.err { color:var(--danger); font-size:13.5px; margin-top:5px; } .actions { display:flex; gap:8px; margin-top:12px; } .narrow input[type=password] { width:100%; }
.flash { background:color-mix(in srgb, var(--ok) 14%, transparent); border:1px solid color-mix(in srgb, var(--ok) 40%, transparent); color:var(--ok); padding:7px 12px; border-radius:8px; margin-bottom:10px; font-weight:600; }
.notice { background:color-mix(in srgb, var(--warn) 16%, transparent); border:1px solid color-mix(in srgb, var(--warn) 45%, transparent); padding:10px 12px; border-radius:10px; margin-bottom:14px; }
.pill { display:inline-block; padding:2px 10px; border-radius:999px; background:color-mix(in srgb, var(--brand) 15%, transparent); color:var(--brand); font-size:12.5px; font-weight:600; }
.tag { display:inline-flex; align-items:center; gap:5px; padding:2px 10px; border-radius:999px; font-size:12.5px; font-weight:600; line-height:1.6; background:color-mix(in srgb, var(--c) 16%, transparent); color:color-mix(in srgb, var(--c) 72%, var(--txt)); border:1px solid color-mix(in srgb, var(--c) 38%, transparent); }
.warn { color:var(--danger); font-weight:600; } .yes { color:var(--ok); font-weight:700; } .no { color:var(--muted); }
table { width:100%; border-collapse:collapse; } th, td { text-align:left; padding:5px 8px; border-bottom:1px solid var(--line); } th { color:var(--muted); font-weight:600; font-size:13.5px; }
.page-head { display:flex; align-items:center; gap:10px; margin-bottom:10px; flex-wrap:wrap; } .page-head h1 { font-size:19px; margin:0; flex:1; letter-spacing:-.2px; } .page-head small { font-size:14px; font-weight:500; margin-left:6px; }

/* Anmeldung */
.login-wrap { min-height:100vh; display:grid; place-items:center; padding:16px; } .login { width:100%; max-width:380px; } .login h1 { font-size:22px; margin:0 0 4px; } .login p.sub { margin:0 0 18px; color:var(--muted); }
.login input[type=text], .login input[type=password] { width:100%; } .login .btn { width:100%; justify-content:center; margin-top:18px; }

/* ---------- Kennzahlen ---------- */
.kpis { display:grid; grid-template-columns:repeat(auto-fit, minmax(150px, 1fr)); gap:8px; margin-bottom:10px; }
.kpi { background:var(--surface); border:1px solid var(--line); border-radius:var(--r); padding:8px 12px; box-shadow:var(--shadow); display:grid; gap:1px; color:var(--txt); } a.kpi:hover { border-color:var(--brand); }
.kpi small { color:var(--muted); font-weight:600; font-size:12.5px; } .kpi b { font-size:21px; line-height:1.1; letter-spacing:-.5px; } .kpi.alert b { color:var(--danger); } .kpi em { font-style:normal; color:var(--muted); font-size:12.5px; }

/* ---------- Listen ---------- */
.filters { display:flex; gap:8px; align-items:center; flex-wrap:wrap; padding:9px 12px; border-bottom:1px solid var(--line); }
.search { position:relative; flex:1; min-width:200px; margin:0; } .search svg { position:absolute; left:11px; top:50%; transform:translateY(-50%); color:var(--muted); } .search input { width:100%; padding-left:36px; }
.chips { display:flex; gap:6px; flex-wrap:wrap; padding:8px 12px 0; } .chip { padding:3px 10px; border-radius:999px; background:var(--surface2); color:var(--muted); font-weight:600; font-size:13.5px; border:1px solid var(--line); } .chip:hover { color:var(--txt); } .chip.on { background:var(--brand); color:var(--brand-ink); border-color:var(--brand); }
.table-wrap { overflow-x:auto; } table.grid { min-width:900px; } table.grid thead th { position:sticky; top:0; background:var(--surface); z-index:1; padding:7px 10px; border-bottom:1px solid var(--line); white-space:nowrap; } table.grid th a { color:var(--muted); } table.grid th a:hover { color:var(--txt); }
table.grid td { vertical-align:middle; padding:6px 10px; } table.grid tbody tr { cursor:pointer; transition:background .08s; } table.grid tbody tr:hover { background:var(--surface2); } table.grid tbody tr:last-child td { border-bottom:0; }
table.grid small { font-size:12.5px; } tr.past td { opacity:.62; } tr.today td:first-child { box-shadow:inset 3px 0 0 var(--brand); } tr.cancelled .nr, tr.cancelled .who { text-decoration:line-through; }
td.nr { font-variant-numeric:tabular-nums; font-weight:700; white-space:nowrap; } td.nr a { color:var(--txt); } td.r, th.r { text-align:right; white-space:nowrap; }
.when { display:flex; align-items:center; gap:12px; } .daybox { width:42px; flex:none; text-align:center; background:var(--surface2); border:1px solid var(--line); border-radius:10px; padding:3px 0 4px; line-height:1.1; }
.daybox b { display:block; font-size:16px; } .daybox small { text-transform:uppercase; letter-spacing:.5px; color:var(--muted); font-size:10.5px; font-weight:700; } .when .t { font-weight:700; font-size:15px; font-variant-numeric:tabular-nums; }
.route { min-width:240px; } .route .who { font-weight:600; } .route .path { color:var(--muted); font-size:13.5px; } .route .arrow { color:var(--brand); }
.empty { text-align:center; color:var(--muted); padding:36px; } .grp-mark { color:var(--muted); font-size:12.5px; font-weight:600; margin-left:5px; }
.pager { display:flex; align-items:center; gap:10px; padding:8px 12px; border-top:1px solid var(--line); flex-wrap:wrap; } .pager .pgs { display:flex; gap:4px; flex:1; justify-content:center; }
.pager .pgs a { min-width:34px; text-align:center; padding:5px 8px; border-radius:8px; border:1px solid var(--line); color:var(--txt); } .pager .pgs a.on { background:var(--brand); color:var(--brand-ink); border-color:var(--brand); }

/* ---------- Auftragsformular ---------- */
.fgrid { display:grid; grid-template-columns:repeat(auto-fit, minmax(170px, 1fr)); gap:2px 12px; align-items:start; } .fgrid + .fgrid { margin-top:6px; } .fgrid .wide { grid-column:span 2; }
.f label { margin-top:5px; } .f input[type=text], .f input[type=search], .f input[type=date], .f input[type=time], .f input[type=number], .f select, .f textarea, .stop input { width:100%; } .f textarea { resize:vertical; }
.ac { position:relative; } .ac-list { position:absolute; z-index:30; left:0; right:0; top:100%; margin:4px 0 0; padding:4px; list-style:none; background:var(--surface); border:1px solid var(--line); border-radius:10px; box-shadow:var(--shadow); max-height:320px; overflow:auto; }
.ac-list li { padding:8px 10px; border-radius:7px; cursor:pointer; } .ac-list li:hover, .ac-list li:focus { background:color-mix(in srgb, var(--brand) 14%, transparent); outline:none; } .ac-list li.none { color:var(--muted); cursor:default; } .ac-list small { color:var(--muted); }
.stop { display:grid; grid-template-columns:2fr 1.4fr 1fr 110px 40px; gap:8px; margin-bottom:8px; }
.checks { display:grid; gap:4px; padding-top:22px; } label.chk { display:flex; align-items:center; gap:8px; font-weight:500; margin:2px 0; } label.chk input { width:auto; }
.f.total .sum { padding-top:10px; font-size:20px; } .f.total small { display:block; font-size:12.5px; }
.savebar { position:sticky; bottom:0; display:flex; gap:8px; padding:8px 0; background:linear-gradient(to top, var(--bg) 70%, transparent); } .timeline { list-style:none; margin:0; padding:0; display:grid; gap:6px; }

/* ---------- Schmale Bildschirme ---------- */
@media (max-width:980px) {
    html.side-off .side { display:flex; }
    .side { position:fixed; left:0; top:0; transform:translateX(-100%); transition:transform .18s; box-shadow:var(--shadow); } .side.open { transform:none; }
    main { padding:10px 12px; } .top { padding:5px 10px; } .today, .uname small { display:none; }
}
@media (max-width:760px) {
    .fgrid .wide { grid-column:auto; } .stop { grid-template-columns:1fr 1fr; } .stop input:first-child { grid-column:1 / -1; } .uname { display:none; }
    table.grid { min-width:0; } table.grid thead { display:none; }
    table.grid tbody tr { display:grid; grid-template-columns:1fr auto; gap:2px 10px; padding:12px 14px; border-bottom:1px solid var(--line); } table.grid td { display:block; border:0; padding:2px 0; }
    table.grid td.nr { grid-column:2; grid-row:1; text-align:right; } table.grid td.c-when { grid-column:1; grid-row:1; } table.grid td.c-route, table.grid td.c-cust, table.grid td.c-drv, table.grid td.c-status, table.grid td.r { grid-column:1 / -1; }
    tr.today td:first-child { box-shadow:none; }
}
/* Dialog (AB senden) */
.dlg { border:1px solid var(--line); border-radius:14px; padding:0; width:min(720px, 94vw); background:var(--surface); color:var(--txt); box-shadow:0 30px 80px -20px rgba(0,0,0,.55); } .dlg::backdrop { background:rgba(8,10,25,.55); }
.dlg-body { padding:14px 18px; } .dlg-head { display:flex; align-items:center; justify-content:space-between; margin-bottom:10px; } .dlg-head h2 { margin:0; font-size:18px; }
.dlg .f input, .dlg .f select { width:100%; } .dlg-prev { margin-top:12px; } .dlg-prev .row { display:flex; gap:8px; align-items:center; margin-bottom:8px; } .dlg-prev iframe { width:100%; height:420px; border:1px solid var(--line); border-radius:10px; background:#fff; }

/* Sammelaktionen */
.grid th.sel, .grid td.sel { width: 34px; text-align: center; padding-left: 10px; padding-right: 4px; }
.grid tr.picked td { background: color-mix(in srgb, var(--accent, #2563eb) 9%, transparent); }
.bulkbar { position: sticky; top: 0; z-index: 5; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 14px; background: var(--surface, #fff); border-bottom: 1px solid var(--line, #d8dbe6); box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.bulkbar[hidden] { display: none; }
.bulkbar select { min-width: 140px; max-width: 200px; }
.bulkbar .sep { width: 1px; height: 22px; background: var(--line, #d8dbe6); margin: 0 4px; }
.bulkbar .chk { display: inline-flex; align-items: center; gap: 4px; font-size: .85rem; }
.bulk-result { margin: 8px 12px; max-height: 220px; overflow: auto; border: 1px solid var(--line, #d8dbe6); border-radius: 8px; }
.btn.danger { color: var(--danger); border-color: var(--danger); }
.colpick { position: relative; } .colpick summary { list-style: none; cursor: pointer; } .colpick summary::-webkit-details-marker { display: none; }
.colpick .pop { position: absolute; right: 0; top: 110%; z-index: 20; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; box-shadow: 0 6px 20px rgba(0,0,0,.15); display: grid; gap: 6px; min-width: 190px; }
.colpick .pop label { display: flex; gap: 6px; align-items: center; font-size:13.5px; }

/* Kundenseite */
.ctabs { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 16px; border-bottom: 1px solid var(--line); margin-bottom: 10px; padding-bottom: 6px; }
.ctabs nav { display: flex; flex-wrap: wrap; gap: 4px; }
.ctabs nav a, .ctabs nav span { padding: 5px 11px; border-radius: 8px; font-weight: 500; color: var(--brand); text-decoration: none; }
.ctabs nav a.on { background: var(--brand); color: var(--brand-ink); } .ctabs nav span.off { color: var(--muted); opacity: .55; cursor: not-allowed; }
.ctabs .cname { display: flex; align-items: center; gap: 8px; } .ctabs .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--muted); } .ctabs .dot.on { background: var(--ok); }
.subtabs { display: flex; gap: 4px; margin-top: 6px; flex-wrap: wrap; } .subtabs button { padding: 8px 16px; border: 1px solid var(--line); border-bottom: 0; border-radius: 8px 8px 0 0; background: var(--surface2); color: var(--muted); font-weight: 600; cursor: pointer; }
.subtabs button.on { background: var(--surface); color: var(--txt); } .tabpanel { border-top-left-radius: 0; margin-top: -1px; }
.statgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; margin-bottom: 10px; }
.statgrid h3 { margin: 0; padding: 8px 12px; background: var(--surface2); font-size:13.5px; letter-spacing: .04em; text-transform: uppercase; border-bottom: 1px solid var(--line); }
ul.stat { list-style: none; margin: 0; padding: 0; } ul.stat li { padding: 6px 12px; border-bottom: 1px solid var(--line); } ul.stat li:last-child { border-bottom: 0; } ul.stat li a { color: inherit; text-decoration: none; }
ul.stat li.c-blue, ul.stat li.c-blue a { color: #0a8fd8; } ul.stat li.c-orange { color: var(--warn); } ul.stat li.c-red { color: var(--danger); }
.charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 16px; } .charts h3 { margin: 0 0 8px; font-size: 14px; }
svg.bars { width: 100%; height: auto; } svg.bars .bar { fill: #0a8fd8; } svg.bars .bl { font-size: 10px; fill: var(--muted); } svg.bars .bn { font-size: 9px; fill: var(--ok); font-weight: 700; } svg.bars .axis { stroke: var(--line); }
.note { margin-bottom: 8px; }
.themebtn { border: 1px solid var(--line); background: var(--surface); color: var(--txt); border-radius: 8px; padding: 3px 8px; cursor: pointer; font: inherit; display: inline-flex; gap: 6px; align-items: center; }
.themebtn:hover { border-color: var(--brand); }
fieldset { min-width: 0; }

/* ---------- Seitenleiste ein-/ausklappen, Tabs ---------- */
/* eingeklappt: schmale Leiste nur mit Symbolen; beim Darüberfahren klappt sie über den Inhalt auf */
@media (min-width:981px) {
    html.side-off .side { width:56px; overflow:hidden; transition:width .14s; }
    html.side-off .side .bn, html.side-off .side .menu span, html.side-off .side .chev, html.side-off .side .sub, html.side-off .side-foot span, html.side-off .side-online .olist { display:none; }
    html.side-off .side .menu a, html.side-off .side .menu summary { padding:7px 11px; }
    html.side-off .side:hover, html.side-off .side:focus-within { width:220px; margin-right:-164px; overflow-y:auto; box-shadow:var(--shadow); }
    html.side-off .side:hover .bn, html.side-off .side:hover .menu span, html.side-off .side:hover .chev, html.side-off .side:hover .sub, html.side-off .side:focus-within .bn, html.side-off .side:focus-within .menu span, html.side-off .side:focus-within .chev, html.side-off .side:focus-within .sub, html.side-off .side:hover .side-foot span, html.side-off .side:hover .side-online .olist { display:revert; }
    html.side-off .side:hover .menu span, html.side-off .side:hover .bn { display:inline; } html.side-off .side:hover .bn { display:grid; } html.side-off .side:hover .sub, html.side-off .side:focus-within .sub { display:grid; }
    html.side-off .side .brand { padding:11px 9px; }
}
@media (max-width:980px) { html.side-off .side { display:flex; } }
.burger { border-radius:8px; } .burger:hover { background:var(--surface2); }
body.is-shell { height:100vh; overflow:hidden; } body.is-shell .shell { height:100vh; } body.is-shell main { flex:1; min-height:0; padding:0; display:flex; flex-direction:column; }
body.is-shell .side { height:100vh; }
.tabbar { display:flex; align-items:flex-end; gap:2px; padding:6px 12px 0; background:var(--bg); border-bottom:1px solid var(--line); overflow-x:auto; flex:none; scrollbar-width:thin; }
.tab { display:flex; align-items:center; max-width:210px; min-width:90px; background:var(--surface2); border:1px solid var(--line); border-bottom:0; border-radius:8px 8px 0 0; color:var(--muted); flex:none; margin-bottom:-1px; }
.tab:hover { color:var(--txt); } .tab.on { background:var(--surface); color:var(--txt); border-bottom:1px solid var(--surface); box-shadow:inset 0 2px 0 var(--brand); }
.tab .tl { flex:1; min-width:0; background:none; border:0; font:inherit; font-weight:600; color:inherit; padding:5px 4px 5px 10px; text-align:left; cursor:pointer; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.tab .tx { background:none; border:0; color:var(--muted); font-size:16px; line-height:1; width:22px; height:22px; margin-right:3px; border-radius:6px; cursor:pointer; } .tab .tx:hover { background:color-mix(in srgb, var(--danger) 16%, transparent); color:var(--danger); }
.tabmenu { position:fixed; z-index:200; min-width:230px; background:var(--surface); border:1px solid var(--line); border-radius:10px; box-shadow:0 8px 28px rgba(20,24,50,.2); padding:4px; display:flex; flex-direction:column; }
.tabmenu button { background:none; border:0; font:inherit; font-size:12.5px; color:var(--txt); text-align:left; padding:7px 10px; border-radius:6px; cursor:pointer; } .tabmenu button:hover:not(:disabled) { background:var(--surface2); } .tabmenu button:disabled { color:var(--muted); cursor:default; opacity:.6; }
.treload { background:none; border:0; color:var(--muted); cursor:pointer; font-size:15px; padding:3px 8px; margin-left:auto; align-self:center; } .treload:hover { color:var(--txt); }
.frames { flex:1; min-height:0; position:relative; background:var(--bg); }
.tabframe { position:absolute; inset:0; width:100%; height:100%; border:0; display:none; background:var(--bg); } .tabframe.on { display:block; }

/* ---------- Faktura (Layout wie Faktura V2) ---------- */
.av { --h: 220; width: 30px; height: 30px; border-radius: 50%; flex: none; display: inline-grid; place-items: center; font-size: 11.5px; font-weight: 700; letter-spacing: .2px; background: hsl(var(--h) 70% 55% / .2); color: hsl(var(--h) 55% 44%); }
.av.lg { width: 38px; height: 38px; font-size:13.5px; } .av.sm { width: 26px; height: 26px; font-size: 10.5px; }
.who2 { display: flex; align-items: center; gap: 9px; min-width: 0; } .who2 > div { min-width: 0; line-height: 1.25; } .who2 b { font-weight: 600; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 280px; } .who2 small { color: var(--muted); font-size:12.5px; }
.fhead { display: flex; align-items: flex-start; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; } .fhead h1 { margin: 0; font-size: 19px; letter-spacing: -.2px; line-height: 1.2; } .fhead .sub { color: var(--muted); font-size: 12.5px; margin-top: 2px; } .fhead .grow { min-width: 20px; }
.kts { display: flex; gap: 8px; flex-wrap: wrap; } .kt { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 7px 14px 7px 8px; box-shadow: var(--shadow); color: var(--txt); min-width: 170px; } a.kt:hover { border-color: var(--brand); }
.kt .ic { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; font-size: 15px; background: color-mix(in srgb, var(--c, var(--brand)) 16%, transparent); color: var(--c, var(--brand)); } .kt small { display: block; color: var(--muted); font-size: 11.5px; font-weight: 600; } .kt b { display: block; font-size: 17px; line-height: 1.15; } .kt em { font-style: normal; color: var(--muted); font-size: 11.5px; }
.bdg { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 600; line-height: 1.6; padding: 2px 10px; border-radius: 999px; white-space: nowrap; background: color-mix(in srgb, var(--c) 16%, transparent); color: color-mix(in srgb, var(--c) 72%, var(--txt)); border: 1px solid color-mix(in srgb, var(--c) 38%, transparent); } .bdg.solid { background: color-mix(in srgb, var(--c) 24%, var(--surface)); color: color-mix(in srgb, var(--c) 40%, var(--txt)); border-color: color-mix(in srgb, var(--c) 70%, transparent); font-weight: 700; }
.art { display: inline-block; font-size: 10px; font-weight: 800; letter-spacing: .4px; padding: 1px 6px; border-radius: 4px; color: #fff; background: var(--c, #6a7090); } .art.NR { --c: #2b2f3d; } .art.ER { --c: #17a2b8; } .art.SR { --c: #e8a13a; }
.numcell b { display: block; font-size: 14.5px; letter-spacing: .2px; } .numcell small { color: var(--muted); font-size: 11.5px; } .numcell .art { margin-right: 4px; }
.late { color: var(--danger); font-weight: 700; } .sum2 { text-align: right; font-weight: 700; white-space: nowrap; } .sum2 small { display: block; font-weight: 500; color: var(--muted); font-size: 11.5px; }
.chips.in { padding: 0; } .tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.cols2 { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 12px; align-items: start; } .cols2 > div > .card:last-child { margin-bottom: 0; } @media (max-width: 1100px) { .cols2 { grid-template-columns: 1fr; } }
.card .ttl { font-size: 12.5px; font-weight: 700; margin: 0 0 8px; } .kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 8px 14px; } .kv small { display: block; color: var(--muted); font-size: 11.5px; font-weight: 600; margin-bottom: 1px; } .kv div b { font-weight: 600; }
.sumrow { display: flex; justify-content: space-between; padding: 3px 0; font-size:13.5px; } .sumrow span:first-child { color: var(--muted); }
.total { margin-top: 8px; padding: 10px 12px; border-radius: 10px; display: flex; justify-content: space-between; align-items: center; color: var(--brand-ink); font-weight: 700; background: linear-gradient(135deg, color-mix(in srgb, var(--brand) 78%, #6d28d9), var(--brand)); } .total b { font-size: 19px; }
.bar2 { display: flex; gap: 6px; align-items: stretch; } .bar2 .sidebar-mark { width: 4px; border-radius: 2px; background: var(--m, transparent); }
tr.paired td:first-child { box-shadow: inset 4px 0 0 var(--m); } .pairtag { display: inline-flex; align-items: center; gap: 4px; border: 1px solid var(--m); color: var(--m); border-radius: 999px; padding: 0 7px; font-size:11.5px; font-weight: 700; margin-left: 4px; }
.nopr { color: var(--danger); } .nopr small { color: var(--danger); font-weight: 700; display: block; }
.btn[disabled], .btn:disabled { opacity: .45; cursor: not-allowed; }

/* ---------- Buttons/Drawer wie Faktura V2 ---------- */
:root { --brand-soft: #eef0ff; } @media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --brand-soft: #232a55; } } :root[data-theme="dark"] { --brand-soft: #232a55; }
.btn.primary { box-shadow: 0 4px 14px -4px color-mix(in srgb, var(--brand) 60%, transparent); }
.btn.soft { background: var(--brand-soft); color: var(--brand); border-color: transparent; } .btn.soft:hover { filter: brightness(.97); }
.btn svg.i { width: 16px; height: 16px; } .btn.sm svg.i { width: 15px; height: 15px; }
.icon-btn { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; border: 0; background: none; color: var(--muted); cursor: pointer; } .icon-btn:hover { background: var(--surface2); color: var(--txt); }
.icon-btn.back { width: 36px; height: 36px; flex: none; background: var(--brand-soft); color: var(--brand); border: 1px solid color-mix(in srgb, var(--brand) 30%, transparent); border-radius: 10px; } .icon-btn.back:hover { background: var(--brand); color: var(--brand-ink); } .icon-btn.back svg { width: 20px; height: 20px; stroke-width: 2.4; }
.fhead .actions2 { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; } .fhead .actions2 .btn { padding: 6px 11px; font-size:13.5px; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(720px, 100%); background: var(--surface); z-index: 60; box-shadow: -20px 0 60px -20px rgba(20, 24, 50, .45); display: flex; flex-direction: column; animation: slide .22s ease; } .drawer[hidden] { display: none; }
.drawer-h { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-bottom: 1px solid var(--line); } .drawer iframe { flex: 1; border: 0; background: #525659; }
@keyframes slide { from { transform: translateX(40px); opacity: 0; } }
@media (max-width: 1250px) { .fhead .actions2 .btn.ghost.ic { font-size: 0; gap: 0; } .fhead .actions2 .btn.ghost.ic svg { margin: 0; } }

/* ---------- Rechnungsmaske (aus Faktura V2: public_v2/assets/app.css) ---------- */
:root { --red: var(--danger); --green: var(--ok); --amber: var(--warn); --blue: var(--info); --red-bg: color-mix(in srgb, var(--danger) 13%, transparent); --green-bg: color-mix(in srgb, var(--ok) 13%, transparent); --amber-bg: color-mix(in srgb, var(--warn) 15%, transparent); --blue-bg: color-mix(in srgb, #2563eb 12%, transparent); }
.page-h.sticky { position: sticky; top: 0; z-index: 15; background: var(--bg); display: flex; flex-wrap: nowrap; align-items: center; justify-content: space-between; padding: 6px 0; margin: 0 0 8px; gap: 10px; }
.page-h.sticky .title { display: flex; align-items: center; gap: 10px; flex: 1 1 auto; min-width: 0; flex-wrap: nowrap; }
.page-h.sticky .title > div { min-width: 0; flex: 0 1 auto; } .page-h.sticky .title h1 { font-size: 19px; margin: 0; flex: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.2px; } .page-h.sticky .title .sub { font-size:12.5px; margin: 2px 0 0; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.page-h.sticky .actions { display: flex; flex: none; flex-wrap: nowrap; gap: 6px; padding-left: 12px; margin-left: 4px; border-left: 1px solid var(--line); margin-top: 0; } .page-h.sticky .actions .btn { white-space: nowrap; padding: 6px 11px; font-size:13.5px; }
.title .icon-btn.back { width: 36px; height: 36px; }
.banner { display: flex; gap: 12px; align-items: center; background: var(--blue-bg); color: var(--blue); padding: 8px 12px; border-radius: 12px; margin-bottom: 8px; font-size:13.5px; } .banner a { color: inherit; text-decoration: underline; } .banner.warn { background: var(--amber-bg); color: var(--amber); }
.layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 10px; align-items: start; } .col-side { position: sticky; top: 56px; }
.card.pad { padding: 12px 14px; margin-bottom: 10px; } .card.pad h2 { font-size: 13.5px; margin: 0 0 8px; font-weight: 650; } .card-t { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; } .card-t h2 { margin: 0 !important; }
.fields { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px 12px; } .f.w2 { grid-column: span 2; } .f label { display: block; font-size: 11.5px; font-weight: 600; color: var(--muted); margin: 0 0 2px; } .f label small { font-weight: 500; } .fields select, .f select, .fields input, .fields textarea { width: 100%; } .col-side .f { margin-bottom: 6px; }
.fields input, .fields select, .fields textarea, .col-side input, .col-side select, .col-side textarea, .pos input, .pos select, .pos textarea { padding: 5px 9px; border-radius: 8px; font-size:13.5px; } textarea { min-height: 32px; }
input:disabled, select:disabled, textarea:disabled { background: var(--surface2); color: var(--muted); } .num { text-align: right; font-variant-numeric: tabular-nums; }
.static.cust { display: flex; align-items: center; gap: 9px; } .cust small { display: block; font-size: 11.5px; line-height: 1.25; color: var(--muted); } .late em, em.late { font-style: normal; background: var(--red-bg); color: var(--red); padding: 1px 7px; border-radius: 99px; font-size:11.5px; margin-left: 6px; }
.poslist { display: grid; gap: 8px; } .pos { display: flex; gap: 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); align-items: flex-start; } .pos:hover { border-color: color-mix(in srgb, var(--brand) 35%, var(--line)); }
.pos-n { width: 22px; height: 22px; border-radius: 8px; background: var(--surface2); display: grid; place-items: center; font-weight: 700; font-size:11.5px; color: var(--muted); flex: none; }
.pos-body { flex: 1; min-width: 0; display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; } .pos-body textarea { flex: 1 1 280px; min-width: 220px; height: 58px; }
.pos-f { display: flex; gap: 6px; align-items: flex-end; flex: 2 1 420px; flex-wrap: nowrap; } .pos-f label { font-size:11.5px; color: var(--muted); font-weight: 600; flex: 1 1 70px; min-width: 64px; margin: 0; } .pos-f label input, .pos-f label select { margin-top: 2px; color: var(--txt); font-weight: 400; width: 100%; }
.pos-sum { margin-left: auto; text-align: right; min-width: 96px; } .pos-sum output { display: block; font-weight: 700; font-size: 14px; font-variant-numeric: tabular-nums; } .pos-sum small { font-size:11.5px; color: var(--muted); }
.sum .row { display: flex; justify-content: space-between; align-items: center; padding: 2px 0; color: var(--muted); font-size:13.5px; } .sum .row output { color: var(--txt); font-variant-numeric: tabular-nums; } .sum .row input { width: 110px; } .sum .row.sub { border-top: 1px dashed var(--line); margin-top: 2px; padding-top: 6px; }
.total { display: flex; justify-content: space-between; align-items: center; margin-top: 6px; padding: 9px 12px; border-radius: 12px; background: linear-gradient(135deg, #4f46e5, #7c3aed); color: #fff; font-weight: 600; } .total output { font-size: 19px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.autorab { font-size:12.5px; color: var(--muted); justify-content: flex-end; margin: -4px 0 6px; cursor: pointer; display: flex; } .autorab input { margin-right: 4px; vertical-align: -2px; width: auto; } #rabatt[readonly] { background: var(--surface2); } .autorab span { display: flex; align-items: center; gap: 6px; white-space: nowrap; margin-left: auto; }
.payrow { display: grid; grid-template-columns: 72px 1fr auto 24px; gap: 6px; align-items: center; font-size: 12.5px; padding: 3px 0; border-bottom: 1px solid var(--line); } .payrow span:nth-child(2) { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.payadd { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 8px; } .payadd input[name=pay_bem] { grid-column: 1 / -1; } .payadd .btn { grid-column: 1 / -1; justify-content: center; }
.hnote { font-size: 12.5px; color: var(--muted); margin-top: 10px; line-height: 1.5; } .files { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 8px; } .mrow { font-size:12.5px; color: var(--muted); padding: 2px 0; }
.timeline { list-style: none; margin: 0; padding: 0; } .timeline li { display: flex; gap: 12px; padding-bottom: 8px; position: relative; } .timeline li::before { content: ""; position: absolute; left: 4px; top: 14px; bottom: 0; width: 1px; background: var(--line); } .timeline li:last-child::before { display: none; }
.timeline i { width: 9px; height: 9px; border-radius: 50%; background: var(--green); margin-top: 6px; flex: none; } .timeline li.bad i { background: var(--red); } .timeline b { font-weight: 600; } .timeline small { display: block; color: var(--muted); }
.btn.danger-link { background: none; color: var(--red); width: 100%; justify-content: center; padding: 5px; font-size:13.5px; border-color: transparent; } .btn.danger-link:hover { background: var(--red-bg); filter: none; }
.cfm-o { position: fixed; inset: 0; z-index: 200; background: rgba(15, 18, 40, .5); backdrop-filter: blur(2px); display: grid; place-items: center; padding: 16px; } .cfm-o[hidden] { display: none; }
.cfm { background: var(--surface); border: 1px solid var(--line); border-top: 4px solid var(--brand); border-radius: 14px; box-shadow: 0 20px 50px -12px rgba(0, 0, 0, .45); max-width: 440px; width: 100%; padding: 22px 24px 18px; }
.cfm-i { width: 46px; height: 46px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; margin-bottom: 10px; } .cfm h3 { font-size: 17px; margin: 0 0 6px; } .cfm p { font-size: 13.5px; color: var(--muted); line-height: 1.5; white-space: pre-line; margin: 0; }
.cfm-a { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; } .cfm.warn { border-top-color: var(--amber); } .cfm.warn .cfm-i { background: var(--amber-bg); color: var(--amber); }
.cfm-note { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; padding: 10px 12px; border-radius: 10px; background: var(--amber-bg); color: var(--amber); border: 1px solid color-mix(in srgb, var(--amber) 45%, transparent); font-size: 13.5px; font-weight: 600; line-height: 1.45; } .cfm-note svg { flex: none; margin-top: 1px; }
@media (max-width: 1200px) { .fields { grid-template-columns: repeat(2, minmax(0, 1fr)); } .pos-f { flex-wrap: wrap; } }
@media (max-width: 980px) { .layout { grid-template-columns: 1fr; } .col-side { position: static; } .page-h.sticky { flex-wrap: wrap; } }
@media (max-width: 1250px) { .page-h.sticky .actions .btn.ghost { font-size: 0; gap: 0; } .page-h.sticky .actions .btn.ghost svg { margin: 0; } }
.fields input:not([type=checkbox]):not([type=hidden]), .col-side input:not([type=checkbox]):not([type=hidden]), .pos input:not([type=hidden]):not([type=checkbox]), .pos select, .col-side select { font: inherit; font-size:13.5px; background: var(--bg); color: var(--txt); border: 1px solid var(--line); max-width: 100%; }
.fields input:focus, .col-side input:focus, .pos input:focus, .pos select:focus, .pos textarea:focus { outline: 2px solid color-mix(in srgb, var(--brand) 55%, transparent); outline-offset: 1px; }
.pos textarea, .fields textarea { background: var(--bg); color: var(--txt); border: 1px solid var(--line); font: inherit; font-size:13.5px; }
/* Korrektur: Seitenleisten-Klasse .sub darf die Summenzeile nicht beeinflussen; Zahlungsfelder passen in die Spalte */
.sum .row.sub { display: flex; margin: 2px 0 0; padding: 6px 0 0; border-left: 0; gap: 0; border-top: 1px dashed var(--line); }
.payadd input, .payadd select { width: 100%; min-width: 0; box-sizing: border-box; }
.payadd { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }

/* ---------- E-Rechnung / Versand (aus Faktura V2) ---------- */
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; font-size:12.5px; font-weight: 600; line-height: 1.6; white-space: nowrap; }
.pill.amber { background: var(--amber-bg); color: var(--amber); } .pill.green { background: var(--green-bg); color: var(--green); } .pill.red { background: var(--red-bg); color: var(--red); } .pill.blue { background: var(--blue-bg); color: var(--blue); }
.pill.slate { background: color-mix(in srgb, var(--muted) 16%, transparent); color: var(--muted); } .pill.ghost { background: none; color: var(--muted); border: 1px dashed var(--line); font-weight: 500; }
.stepper { display: inline-flex; gap: 2px; margin: 0 0 0 8px; align-items: center; flex-wrap: nowrap; }
.step { display: flex; align-items: center; gap: 5px; padding: 2px 8px 2px 3px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--muted); font-weight: 500; font-size: 11.5px; }
.step span { width: 16px; height: 16px; border-radius: 50%; display: grid; place-items: center; background: var(--surface2); font-size: 10px; } .step span .i { width: 10px; height: 10px; } .step.on { color: var(--txt); } .step.on span { background: var(--green); color: #fff; } .step.bad span { background: var(--red); }
.page-h.sticky .title .pill, .page-h.sticky .title .stepper { flex: none; }
@media (max-width: 1500px) { .page-h.sticky .stepper { display: none; } }
.menu { position: relative; } .menu summary { list-style: none; cursor: pointer; } .menu summary::-webkit-details-marker { display: none; }
.menu-p { position: absolute; right: 0; top: calc(100% + 6px); width: 290px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 40px -8px rgba(20, 24, 50, .3); padding: 6px; z-index: 30; }
.mi { display: block; width: 100%; text-align: left; font: inherit; background: none; border: 0; border-radius: 8px; padding: 9px 12px; cursor: pointer; color: var(--txt); } .mi:hover:not(:disabled) { background: var(--surface2); } .mi small { display: block; color: var(--muted); } .mi:disabled { opacity: .4; cursor: not-allowed; }
.check { margin-top: 8px; padding: 8px 12px; border-radius: 12px; } .check.ok { background: var(--green-bg); color: var(--green); } .check.bad { background: var(--red-bg); color: var(--red); } .check-h { display: flex; align-items: center; gap: 8px; margin-bottom: 2px; }
.msg { display: flex; gap: 8px; align-items: flex-start; margin-top: 3px; font-size: 12.5px; } .msg.e { color: var(--red); } .msg.w { color: var(--amber); } .msg .i { margin-top: 3px; }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 2px 18px; margin: 6px 0 0; font-size: 12.5px; color: var(--txt); } .facts dt { color: var(--muted); } .facts dd { margin: 0; }
code { background: var(--surface2); padding: 1px 6px; border-radius: 6px; font-size:12.5px; }
.cfm.oth { max-width: 560px; }
.oth-r { display: grid; grid-template-columns: 70px 1fr 34px; align-items: center; gap: 8px; margin-top: 8px; } .oth-r label { font-size:13.5px; color: var(--muted); margin: 0; } .oth-r input, .oth-r select { width: 100%; padding: 6px 9px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg); color: var(--txt); font: inherit; }
.oth-list { border: 1px solid var(--line); border-radius: 10px; margin-top: 10px; max-height: 200px; overflow: auto; } .oth-list[hidden] { display: none; }
.oth-list button { display: flex; justify-content: space-between; gap: 10px; width: 100%; text-align: left; padding: 8px 12px; background: none; border: 0; border-bottom: 1px solid var(--line); cursor: pointer; font: inherit; font-size:13.5px; color: var(--txt); } .oth-list button:hover { background: var(--brand-soft); } .oth-list small { color: var(--muted); }

/* ---------- Infoseite E-Rechnung (aus Faktura V2 help.php) ---------- */
.hg2 { display: flex; align-items: stretch; gap: 12px; flex-wrap: wrap; } .harr { align-self: center; font-size: 26px; color: var(--muted); }
.hbox { flex: 1; min-width: 220px; border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 4px; border: 1px solid var(--line); }
.hbox.no { background: var(--red-bg); color: var(--red); } .hbox.yes { background: var(--green-bg); color: var(--green); }
.hbox .hi { font-size: 22px; font-weight: 800; letter-spacing: .5px; } .hbox small, .hfmt small, .ht small, .hs small, .hl small { color: var(--muted); font-size:12.5px; line-height: 1.4; display: block; } .hbox small { color: inherit; opacity: .85; }
.hfmt { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; margin-top: 12px; } .hfmt > div { background: var(--surface2); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 2px; }
.htl { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0; position: relative; } .htl::before { content: ""; position: absolute; left: 0; right: 0; top: 11px; height: 3px; background: var(--line); }
.ht { position: relative; padding: 22px 10px 0 0; display: flex; flex-direction: column; gap: 2px; } .ht span { position: absolute; top: 0; left: 0; background: var(--surface); border: 3px solid var(--line); border-radius: 12px; font-size:11.5px; font-weight: 700; padding: 0 7px; line-height: 17px; color: var(--muted); }
.ht.done span { border-color: var(--green); color: var(--green); } .ht.now span { border-color: var(--brand); color: var(--brand); } .ht b { font-size:13.5px; }
.hflow { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; } .hs { background: var(--surface2); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 3px; position: relative; }
.hs i { font-style: normal; width: 22px; height: 22px; border-radius: 50%; background: var(--brand); color: var(--brand-ink); font-size:12.5px; font-weight: 700; display: grid; place-items: center; } .hs b { font-size:13.5px; }
.hlock { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 10px; } .hl { border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; gap: 3px; } .hl.open { background: var(--green-bg); } .hl.shut { background: var(--red-bg); } .hl.open b { color: var(--green); } .hl.shut b { color: var(--red); } .hl small { color: var(--txt); }
.hcols { display: grid; grid-template-columns: 2fr 1fr; gap: 12px; } @media (max-width: 800px) { .hcols { grid-template-columns: 1fr; } }
.hlist { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size:13.5px; line-height: 1.45; } .hlist a { color: var(--brand); }
.h8 { display: flex; align-items: baseline; gap: 8px; } .h8 b { font-size: 54px; line-height: 1; color: var(--brand); } .h8 span { font-size: 16px; color: var(--muted); }
.hstat { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; } .hstat small { color: var(--muted); margin-right: 8px; }
.helpbtn { width: 30px; height: 30px; font-weight: 700; font-size: 15px; text-decoration: none; color: var(--brand); background: var(--brand-soft); }

/* ---------- Stammdaten → Texte ---------- */
.txt-layout { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 12px; align-items: start; } @media (max-width: 900px) { .txt-layout { grid-template-columns: 1fr; } }
.txt-nav { padding: 6px; position: sticky; top: 8px; } .txt-grp { font-size:11.5px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; color: var(--muted); padding: 10px 10px 4px; }
.txt-nav a { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 6px 10px; border-radius: 8px; color: var(--txt); font-size:13.5px; } .txt-nav a:hover { background: var(--surface2); } .txt-nav a.on { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.txt-nav small { display: inline-flex; gap: 3px; } .txt-nav i { font-style: normal; font-size: 10px; font-weight: 700; padding: 0 5px; border-radius: 5px; border: 1px dashed var(--line); color: var(--muted); } .txt-nav i.f { border-style: solid; border-color: var(--ok); color: var(--ok); }
.txt-tools { display: flex; gap: 4px; flex-wrap: wrap; padding: 6px; border: 1px solid var(--line); border-bottom: 0; border-radius: 8px 8px 0 0; background: var(--surface2); } .txt-tools button { min-width: 30px; padding: 3px 9px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--txt); cursor: pointer; font: inherit; font-size:13.5px; } .txt-tools button:hover { border-color: var(--brand); }
.txt-ed { min-height: 220px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 0 0 8px 8px; background: var(--bg); color: var(--txt); line-height: 1.5; font-size: 13.5px; overflow: auto; } .txt-ed:focus { outline: 2px solid color-mix(in srgb, var(--brand) 55%, transparent); outline-offset: 1px; } .txt-ed[contenteditable=false] { background: var(--surface2); }
.txt-src { width: 100%; min-height: 220px; font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 0 0 8px 8px; background: var(--bg); color: var(--txt); } .txt-src[hidden], .txt-ed[hidden], .txt-pane[hidden] { display: none; }
.txt-ph { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 10px; } .txt-ph .chip { cursor: pointer; font-family: ui-monospace, Consolas, monospace; font-size:12.5px; } .txt-ph .chip small { font-family: system-ui, sans-serif; color: var(--muted); margin-left: 4px; }
.txt-edit .subtabs { display: flex; gap: 4px; margin-bottom: 8px; } .txt-edit .subtabs button { padding: 5px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface2); color: var(--muted); font-weight: 600; cursor: pointer; font: inherit; } .txt-edit .subtabs button.on { background: var(--brand-soft); color: var(--brand); border-color: var(--brand); }
.txt-tools .sep { width: 1px; align-self: stretch; background: var(--line); margin: 0 3px; } .txt-tools select { padding: 3px 6px; font-size: 12.5px; border-radius: 6px; border: 1px solid var(--line); background: var(--surface); color: var(--txt); max-width: 130px; }
.txt-tools .clr { position: relative; display: inline-grid; place-items: center; min-width: 30px; padding: 3px 8px; margin: 0; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); cursor: pointer; font-size:13.5px; font-weight: 700; } .txt-tools .clr input { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; cursor: pointer; padding: 0; border: 0; }
.txt-ed h1 { font-size: 1.6em; margin: .4em 0; } .txt-ed h2 { font-size: 1.3em; margin: .4em 0; } .txt-ed h3 { font-size: 1.1em; margin: .4em 0; } .txt-ed p { margin: 0 0 .6em; } .txt-ed a { color: var(--brand); text-decoration: underline; }

/* ---------- Branding je Mandant ---------- */
.hdr-logo { max-height: 30px; max-width: 160px; object-fit: contain; margin-right: 6px; }
body.login-bg { background-size: cover; background-position: center; background-repeat: no-repeat; background-attachment: fixed; }
body.login-bg .login { background: color-mix(in srgb, var(--surface) 93%, transparent); backdrop-filter: blur(6px); box-shadow: 0 20px 60px -20px rgba(0, 0, 0, .55); }
.login-logo { display: block; max-width: 100%; max-height: 90px; margin: 0 auto 10px; object-fit: contain; }
.brandimg { background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 6px; display: grid; place-items: center; min-height: 90px; } .brandimg img { max-width: 100%; max-height: 160px; object-fit: contain; }
.brandimg.letter img { max-height: 200px; } .brandimg.bgimg img { max-height: 120px; }
.upl { display: grid; gap: 6px; } .upl input[type=file] { font-size: 12.5px; max-width: 100%; } .upl label.chk { display: flex; gap: 6px; align-items: center; font-weight: 500; font-size: 12.5px; margin: 0; } .upl label.chk input { width: auto; }
.subnav { display: flex; gap: 4px; flex-wrap: wrap; margin: 0 0 10px; } .subnav a { padding: 5px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface2); color: var(--muted); font-weight: 600; } .subnav a.on { background: var(--brand-soft); color: var(--brand); border-color: var(--brand); }

/* ---------- Auftragsmaske (Bearbeiten/Neu): Kopf mit Aktionen, Hauptspalte + Seitenspalte ---------- */
.oh { position:sticky; top:0; z-index:15; display:flex; align-items:center; gap:12px; flex-wrap:wrap; padding:10px 14px; margin:0 0 12px; background:var(--surface); border:1px solid var(--line); border-radius:var(--r); box-shadow:var(--shadow); }
.oh-back { display:grid; place-items:center; width:34px; height:34px; border-radius:9px; border:1px solid var(--line); color:var(--txt); } .oh-back:hover { background:var(--surface2); }
.oh-title { flex:1 1 280px; min-width:0; } .oh-title h1 { margin:0; font-size:19px; letter-spacing:-.2px; display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.oh-sub { display:flex; flex-wrap:wrap; gap:4px 14px; margin-top:3px; color:var(--muted); font-size:13.5px; } .oh-sub > span { display:inline-flex; align-items:center; gap:5px; }
.oh-actions { display:flex; align-items:center; gap:6px; flex-wrap:wrap; margin-left:auto; } .oh-sep { width:1px; height:24px; background:var(--line); margin:0 4px; }
.ogrid { display:grid; grid-template-columns:minmax(0, 1fr) 340px; gap:14px; align-items:start; } .omain, .oside { min-width:0; } .oside { position:sticky; top:84px; max-height:calc(100vh - 100px); overflow-y:auto; padding-bottom:4px; }
.card.sec { padding:14px 16px 12px; margin-bottom:14px; } .card.sec h2 { display:flex; align-items:center; gap:8px; font-size:14.5px; padding-bottom:8px; margin:0 0 10px; border-bottom:1px solid var(--line); }
.card.sec h2 .i { color:var(--brand); flex:none; } .card.sec h2 small { margin-left:2px; font-weight:500; }
.ogrid .f label { display:block; margin:0 0 3px; font-size:12.5px; font-weight:600; letter-spacing:.2px; color:var(--muted); } .ogrid .f { margin-bottom:8px; }
.ogrid .fgrid { grid-template-columns:repeat(auto-fit, minmax(150px, 1fr)); gap:2px 12px; } .ogrid .fgrid .wide { grid-column:span 2; } .ogrid .fgrid.two { grid-template-columns:repeat(auto-fit, minmax(260px, 1fr)); }
.ogrid .fgrid + .fgrid { margin-top:0; }
.subbox { margin-top:6px; padding:10px 12px 4px; background:var(--surface2); border:1px solid var(--line); border-radius:10px; } .subbox[hidden] { display:none; } .subbox + .subbox { margin-top:10px; }
.subbox.airport { background:color-mix(in srgb, var(--brand) 7%, var(--surface)); border-color:color-mix(in srgb, var(--brand) 30%, var(--line)); }
.subt { display:flex; align-items:center; gap:6px; font-size:12.5px; font-weight:700; letter-spacing:.4px; text-transform:uppercase; color:var(--muted); margin-bottom:6px; }
.stop-head { margin-bottom:4px; } .stop-head span { font-size:11.5px; font-weight:700; letter-spacing:.3px; text-transform:uppercase; color:var(--muted); }
.omain .stop { align-items:center; padding:6px; margin-bottom:6px; background:var(--surface2); border:1px solid var(--line); border-radius:10px; } .omain .stop.stop-head { background:none; border:0; padding:0 6px; margin-bottom:2px; }
.omain .stop input { background:var(--surface); }
.pgrid { display:grid; grid-template-columns:1fr 1fr; gap:0 10px; } .pgrid + .prow { margin-top:4px; }
.prow { display:grid; grid-template-columns:1fr 130px; align-items:center; gap:8px; padding:3px 0; } .prow label { margin:0; font-size:13.5px; font-weight:500; color:var(--txt); }
.money { position:relative; display:block; } .money input { width:100%; text-align:right; padding-right:26px; font-variant-numeric:tabular-nums; } .money i { position:absolute; right:9px; top:50%; transform:translateY(-50%); font-style:normal; color:var(--muted); }
.ptotal { display:flex; align-items:baseline; justify-content:space-between; margin-top:8px; padding:10px 12px; border-radius:10px; background:color-mix(in srgb, var(--brand) 10%, var(--surface)); border:1px solid color-mix(in srgb, var(--brand) 28%, var(--line)); }
.ptotal span { font-weight:600; } .ptotal b { font-size:22px; letter-spacing:-.4px; font-variant-numeric:tabular-nums; }
.checks2 { display:grid; gap:2px; margin-top:2px; }
.oside .timeline li { padding:6px 0; border-bottom:1px dashed var(--line); } .oside .timeline li:last-child { border-bottom:0; }
@media (max-width: 1100px) { .ogrid { grid-template-columns:1fr; } .oside { position:static; max-height:none; overflow:visible; } .oh { position:static; } }
@media (max-width: 640px) { .oh-actions { margin-left:0; width:100%; } .oh-actions .btn { flex:1 1 auto; justify-content:center; } .oh-sep { display:none; } .ogrid .fgrid .wide { grid-column:auto; } .omain .stop.stop-head { display:none; } }

/* SMS-Liste und Preisblock in der Auftragsmaske */
.smslist { list-style:none; margin:0; padding:0; display:grid; gap:8px; }
.smslist li { padding:8px 10px; background:var(--surface2); border:1px solid var(--line); border-radius:10px; display:block; }
.sl-top { display:flex; justify-content:space-between; gap:8px; align-items:baseline; font-size:13.5px; } .sl-top .muted { font-size:12.5px; white-space:nowrap; }
.sl-to { margin-top:1px; font-size:13.5px; word-break:break-all; } .sl-st { margin-top:5px; } .sl-st .bdg { white-space:normal; }
.sl-msg { margin-top:5px; font-size:12.5px; color:var(--muted); line-height:1.35; border-top:1px dashed var(--line); padding-top:5px; }
.oside, .oside .card { overflow-x:hidden; } .oside .timeline li { display:block; }
.card.sec.price { border-color:color-mix(in srgb, #1e8e3e 35%, var(--line)); background:linear-gradient(180deg, color-mix(in srgb, #1e8e3e 7%, var(--surface)), var(--surface) 55%); }
.card.sec.price h2 .i { color:#1e8e3e; }
.card.sec.price .ptotal { margin-top:10px; padding:12px 14px; color:#fff; border:0; background:linear-gradient(135deg, #1e8e3e, #2fb457); box-shadow:0 6px 16px -8px rgba(30,142,62,.7); }
.card.sec.price .ptotal span { color:rgba(255,255,255,.9); letter-spacing:.3px; text-transform:uppercase; font-size:12.5px; } .card.sec.price .ptotal b { font-size:26px; color:#fff; }
.card.sec.price #sumVat { margin-top:5px; }
/* Vorschläge in den Adresszeilen */
.sg { position:relative; } .sg input { padding-right:32px; }
.lens { position:absolute; right:4px; top:50%; transform:translateY(-50%); width:26px; height:26px; display:grid; place-items:center; border:0; border-radius:7px; background:transparent; color:var(--muted); cursor:pointer; }
.lens:hover { background:color-mix(in srgb, var(--brand) 14%, transparent); color:var(--brand); }
.sg .ac-list { min-width:300px; } .sg .ac-list li { display:grid; gap:1px; } .sg .ac-list li b { font-weight:600; } .sg .ac-list li small { color:var(--muted); font-size:12.5px; }
/* Reiter der Auftragsmaske, Route, Anhang */
.otabs { display:flex; gap:4px; margin:0 0 12px; border-bottom:1px solid var(--line); }
.otabs button { display:inline-flex; align-items:center; gap:6px; font:inherit; font-weight:600; padding:8px 14px; border:1px solid transparent; border-bottom:0; border-radius:9px 9px 0 0; background:transparent; color:var(--muted); cursor:pointer; margin-bottom:-1px; }
.otabs button:hover:not(:disabled) { color:var(--txt); background:var(--surface2); } .otabs button.on { color:var(--brand); background:var(--surface); border-color:var(--line); border-bottom:1px solid var(--surface); } .otabs button:disabled { opacity:.45; cursor:not-allowed; }
.otabs .cnt { min-width:18px; padding:0 6px; border-radius:999px; background:var(--brand); color:var(--brand-ink); font-size:11.5px; line-height:18px; text-align:center; }
.ogrid[hidden], .otab[hidden] { display:none; }
#routeMap { width:100%; height:520px; border:1px solid var(--line); border-radius:12px; margin-top:10px; background:var(--surface2); }
.route-list { margin:0 0 8px; padding-left:22px; display:grid; gap:2px; } .route-actions { display:flex; gap:8px; flex-wrap:wrap; margin-bottom:6px; }
.upl-form { display:flex; gap:10px; align-items:stretch; flex-wrap:wrap; margin-bottom:12px; } .drop { flex:1 1 320px; display:flex; align-items:center; gap:10px; padding:14px 16px; border:2px dashed var(--line); border-radius:12px; background:var(--surface2); color:var(--muted); cursor:pointer; }
.drop:hover, .drop.over { border-color:var(--brand); background:color-mix(in srgb, var(--brand) 8%, var(--surface)); color:var(--txt); } .drop input { position:absolute; width:1px; height:1px; opacity:0; }
.upl-sel { flex-basis:100%; font-size:12.5px; color:var(--muted); } .inl { display:inline; } .btn.danger-link { color:var(--danger); }

.inl .btn.danger-link { width:auto; padding:3px 8px; color:var(--danger); border:1px solid var(--line); background:transparent; }
/* Auswertungen */
.rfilter { display:flex; flex-wrap:wrap; align-items:center; gap:8px 16px; } .rfilter .chips { flex:1 1 auto; } .rrange { display:flex; gap:8px; align-items:center; flex-wrap:wrap; } .rrange label { display:flex; align-items:center; gap:6px; font-weight:500; margin:0; }
.chip.on { background:var(--brand); color:var(--brand-ink); }
.rk { margin-bottom:12px; display:grid; grid-template-columns:repeat(auto-fit, minmax(190px, 1fr)); gap:10px; }
.rchart { display:flex; align-items:flex-end; gap:3px; height:190px; overflow-x:auto; padding:4px 2px 0; } .rcol { flex:1 0 20px; max-width:56px; display:flex; flex-direction:column; align-items:center; height:100%; }
.rbars { flex:1; width:100%; display:flex; align-items:flex-end; justify-content:center; gap:2px; } .rbars i { display:block; width:42%; border-radius:4px 4px 0 0; } .rbars .b1 { background:var(--brand); } .rbars .b2 { background:#1e8e3e; }
.rcol span { font-size:10.5px; color:var(--muted); margin-top:4px; white-space:nowrap; }
tr.rsub td { background:var(--surface2); }
.stars { color:#e8a317; letter-spacing:1px; } .rdist { display:grid; grid-template-columns:78px 1fr 34px; align-items:center; gap:8px; margin:5px 0; } .rbar { height:12px; background:var(--surface2); border-radius:6px; overflow:hidden; } .rbar i { display:block; height:100%; background:#e8a317; border-radius:6px; } .rdist b { text-align:right; }
.rstars { display:inline-flex; flex-direction:row-reverse; gap:2px; font-size:26px; } .rstars input { position:absolute; opacity:0; width:1px; height:1px; } .rstars label { cursor:pointer; color:var(--line); margin:0; font-size:26px; line-height:1; } .rstars input:checked ~ label, .rstars label:hover, .rstars label:hover ~ label { color:#e8a317; }
.stop { grid-template-columns:2fr 1.4fr 1fr 1.3fr 110px 40px; } .omain .stop input[type=email] { width:100%; }
@media (max-width: 640px) { .stop { grid-template-columns:1fr 1fr; } .stop .sg:first-child { grid-column:1 / -1; } }
/* Fahrtenbuch */
.lbtype { display:flex; gap:8px; flex-wrap:wrap; margin:2px 0 10px; } .lbtype label { display:inline-flex; align-items:center; gap:8px; padding:7px 14px; border:1px solid var(--line); border-radius:999px; cursor:pointer; font-weight:600; background:var(--surface2); margin:0; }
.lbtype label:has(input:checked) { border-color:var(--brand); background:color-mix(in srgb, var(--brand) 12%, var(--surface)); color:var(--brand); } .lbtype input { width:auto; margin:0; }
.req { color:var(--danger); } .lbgap { margin:4px 0 8px; padding:8px 12px; border:1px solid color-mix(in srgb, var(--warn) 45%, transparent); background:color-mix(in srgb, var(--warn) 10%, transparent); border-radius:10px; } .lbgap[hidden] { display:none; }

/* ---------- Rückmeldungen: Toasts, Fortschrittsbalken, Arbeitszustand ---------- */
.fdo-toasts { position:fixed; top:14px; right:14px; z-index:9999; display:flex; flex-direction:column; gap:8px; width:min(380px, calc(100vw - 28px)); pointer-events:none; }
.fdo-toast { pointer-events:auto; position:relative; display:grid; grid-template-columns:auto 1fr auto; align-items:center; gap:10px; padding:11px 12px 13px 14px; border-radius:12px; background:var(--surface, #fff); color:var(--txt, #1b1f33); border:1px solid var(--line, #e3e5ef); border-left:5px solid var(--c, #3f4fd8);
    box-shadow:0 14px 34px -14px rgba(20,24,60,.45); font-size:14px; line-height:1.35; animation:fdo-tin .22s ease-out both; overflow:hidden; }
.fdo-toast .ti { color:var(--c); display:grid; place-items:center; } .fdo-toast .tt { word-break:break-word; font-weight:600; } .fdo-toast .tx { border:0; background:none; color:var(--muted, #6a7090); cursor:pointer; font-size:14px; padding:2px 4px; border-radius:6px; } .fdo-toast .tx:hover { background:var(--surface2, #f7f8fc); }
.fdo-toast.success { --c:#1e8e3e; } .fdo-toast.error { --c:#c0392b; } .fdo-toast.info { --c:#3f4fd8; } .fdo-toast.loading { --c:#3f4fd8; }
.fdo-toast .tbar { position:absolute; left:0; bottom:0; height:3px; width:100%; background:var(--c); opacity:.35; transform-origin:left; } .fdo-toast.out { animation:fdo-tout .2s ease-in both; }
@keyframes fdo-tin { from { transform:translateX(24px); opacity:0; } to { transform:none; opacity:1; } } @keyframes fdo-tout { to { transform:translateX(24px); opacity:0; } } @keyframes fdo-tbar { from { transform:scaleX(1); } to { transform:scaleX(0); } }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .fdo-toast { background:var(--surface); } }
@media (max-width: 640px) { .fdo-toasts { left:14px; right:14px; width:auto; } }
.fdo-spin { width:18px; height:18px; border-radius:50%; border:2.5px solid color-mix(in srgb, var(--c, #3f4fd8) 25%, transparent); border-top-color:var(--c, #3f4fd8); animation:fdo-rot .7s linear infinite; display:inline-block; }
@keyframes fdo-rot { to { transform:rotate(360deg); } }
.fdo-progress { position:fixed; left:0; top:0; right:0; height:3px; z-index:10000; pointer-events:none; opacity:0; transition:opacity .15s; } .fdo-progress.on { opacity:1; }
.fdo-progress i { display:block; height:100%; width:40%; background:linear-gradient(90deg, transparent, var(--brand, #3f4fd8), transparent); animation:fdo-prog 1.1s ease-in-out infinite; }
@keyframes fdo-prog { from { transform:translateX(-100%); } to { transform:translateX(260%); } }
/* Schaltfläche im Arbeitszustand: Kreisel, nicht mehr klickbar (Wert wird trotzdem gesendet) */
button.is-busy, input.is-busy, .btn.is-busy { position:relative; pointer-events:none; opacity:.85; cursor:progress; padding-left:34px; }
button.is-busy::before, .btn.is-busy::before { content:""; position:absolute; left:11px; top:50%; width:15px; height:15px; margin-top:-7.5px; border-radius:50%; border:2.3px solid currentColor; border-right-color:transparent; opacity:.9; animation:fdo-rot .7s linear infinite; }
.is-wait { pointer-events:none; opacity:.55; cursor:progress; } form.is-busy { cursor:progress; }
/* Suchfeld: „sucht“ */
.ac.ac-busy::after { content:""; position:absolute; right:38px; top:50%; width:14px; height:14px; margin-top:-7px; border-radius:50%; border:2px solid var(--brand, #3f4fd8); border-right-color:transparent; animation:fdo-rot .7s linear infinite; pointer-events:none; }
.ac.ac-busy input[type=search] { background-image:none; }
@media (prefers-reduced-motion: reduce) { .fdo-toast, .fdo-spin, .fdo-progress i, button.is-busy::before, .ac.ac-busy::after { animation-duration:2.5s; } }
/* Hin-/Rückfahrt: Paare in der Auftragsliste und in der Maske */
table.grid tr.paired td { background:color-mix(in srgb, var(--m) 5%, transparent); } table.grid tr.paired td:first-child { box-shadow:inset 4px 0 0 var(--m); }
table.grid tr.pair-1 td { border-bottom-style:dashed; border-bottom-color:color-mix(in srgb, var(--m) 45%, var(--line)); } table.grid tr.pair-2 td { border-top:0; }
table.grid a.pairtag { text-decoration:none; } table.grid a.pairtag:hover { background:color-mix(in srgb, var(--m) 14%, transparent); }
.pairbar { display:flex; flex-wrap:wrap; align-items:center; gap:8px; margin:0 0 12px; padding:8px 12px; border:1px solid color-mix(in srgb, var(--m) 40%, var(--line)); border-left:5px solid var(--m); border-radius:12px; background:color-mix(in srgb, var(--m) 6%, var(--surface)); }
.pb-l { font-weight:700; color:var(--m); margin-right:6px; } .pb { display:inline-flex; align-items:center; gap:6px; padding:6px 12px; border-radius:9px; border:1px solid var(--line); background:var(--surface); color:var(--txt); font-size:13.5px; }
.pb.on { border-color:var(--m); box-shadow:inset 0 0 0 1px var(--m); font-weight:600; } a.pb:hover { border-color:var(--m); background:color-mix(in srgb, var(--m) 10%, var(--surface)); } .pb-go { color:var(--m); font-weight:700; margin-left:4px; }
/* Auftragsliste: Abholzeit vergangen = hellrot, kommend = grün; Tagestrenner und "Jetzt"-Linie */
:root { --tp:#e57373; --tf:#1e8e3e; } @media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --tp:#ff8f8f; --tf:#5fd38a; } } :root[data-theme="dark"] { --tp:#ff8f8f; --tf:#5fd38a; }
.when .t.t-past { color:var(--tp); } .when .t.t-future { color:var(--tf); }
tr.dayrow td { background:var(--surface2); color:var(--muted); font-weight:700; font-size:12.5px; letter-spacing:.3px; padding:5px 12px; border-top:1px solid var(--line); }
tr.nowrow td { padding:0; height:0; border:0; border-top:2px solid #e53935; position:relative; } tr.nowrow td span { position:absolute; left:10px; top:-10px; background:#e53935; color:#fff; font-size:11.5px; font-weight:700; padding:1px 9px; border-radius:999px; letter-spacing:.3px; }
tr.nowrow + tr td { padding-top:12px; }
/* Auftragsliste: kompakt + erweiterte Filter */
.kstrip { display:flex; gap:6px; flex-wrap:wrap; } .kstrip a { display:inline-flex; align-items:baseline; gap:6px; padding:3px 11px; border-radius:999px; background:var(--surface); border:1px solid var(--line); color:var(--txt); font-size:13.5px; } .kstrip a:hover { border-color:var(--brand); }
.kstrip small { color:var(--muted); font-weight:600; font-size:12.5px; } .kstrip b { font-size:15px; } .kstrip a.alert { border-color:color-mix(in srgb, var(--danger) 55%, var(--line)); } .kstrip a.alert b { color:var(--danger); }
.chipsep { width:1px; height:20px; background:var(--line); margin:0 4px; align-self:center; } .chip.fchip.on { background:#e8590c; color:#fff; }
.advf { flex-basis:100%; display:flex; flex-wrap:wrap; gap:8px 12px; align-items:flex-end; padding:10px 12px; margin-top:2px; background:var(--surface2); border:1px solid var(--line); border-radius:10px; } .advf[hidden] { display:none; }
.advf label { display:grid; gap:2px; font-size:12.5px; font-weight:600; color:var(--muted); margin:0; } .advf select, .advf input[type=time] { min-width:130px; } .advchk { display:flex; gap:12px; flex-wrap:wrap; align-items:center; padding-bottom:6px; }
.filters .cnt, #advBtn .cnt { min-width:18px; padding:0 6px; border-radius:999px; background:var(--brand); color:var(--brand-ink); font-size:11.5px; line-height:18px; text-align:center; }
.actf { display:flex; flex-wrap:wrap; gap:6px; align-items:center; padding:6px 12px 8px; } .afchip { display:inline-flex; gap:6px; align-items:center; padding:1px 9px; border-radius:999px; background:color-mix(in srgb, var(--brand) 12%, var(--surface)); border:1px solid color-mix(in srgb, var(--brand) 35%, var(--line)); color:var(--brand); font-size:12.5px; font-weight:600; } .afchip b { font-size:11.5px; opacity:.7; } .afchip:hover b { opacity:1; }
.dshort { display:none; }
@media (min-width: 641px) {
    .cz table.grid td { padding:3px 8px; font-size:13.5px; line-height:1.3; } .cz table.grid thead th { padding:5px 8px; }
    .cz .daybox { display:none; } .cz .dshort { display:inline; font-weight:600; color:var(--muted); min-width:64px; margin-right:2px; } .cz .when { gap:8px; } .cz .when .t { font-size:14px; }
    .cz .when small.block { display:inline; margin-left:4px; } .cz td.nr small, .cz .x-sec, .cz td.c-route small { display:none; }
    .cz td.c-route { max-width:440px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; } .cz .route .who, .cz .route .path.block { display:inline; } .cz .route .path { margin-left:8px; }
    .cz td.c-cust small.block, .cz td.c-drv small.block, .cz td.c-status small.block { display:inline; margin-left:6px; } .cz td.c-cust { white-space:nowrap; max-width:260px; overflow:hidden; text-overflow:ellipsis; }
    .cz .tag { padding:0 8px; font-size:12.5px; line-height:1.55; white-space:nowrap; } .cz td .who2 { gap:6px; } .cz .avatar, .cz .av { width:22px; height:22px; font-size:11.5px; }
    .cz tr.dayrow td { padding:3px 10px; } .cz td.sel { width:28px; }
}

@media (min-width: 641px) { .cz td.c-when { white-space:nowrap; } .cz td.nr { white-space:nowrap; } .cz td.c-drv, .cz td.c-status { white-space:nowrap; } }
/* Ansichten + Spaltenreihenfolge */
.colord ul { list-style:none; margin:6px 0; padding:0; display:grid; gap:3px; min-width:250px; } .colord li { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:3px 6px; border:1px solid var(--line); border-radius:8px; background:var(--surface2); } .colord li label { margin:0; display:flex; gap:6px; align-items:center; font-weight:500; } .colord .mv { display:inline-flex; gap:2px; } .colord .mv .btn { padding:0 6px; line-height:20px; }
.vpop { min-width:300px; } .vrow { display:flex; align-items:center; gap:6px; padding:4px 6px; border-radius:8px; color:var(--txt); } .vrow.on { background:color-mix(in srgb, var(--brand) 12%, var(--surface)); } .vrow .vname, a.vrow > span { flex:1; color:var(--txt); font-weight:600; } a.vrow { text-decoration:none; justify-content:space-between; } .vrow .btn { padding:0 7px; line-height:22px; } .vdef { color:#e8a317; }
.vsave { display:grid; gap:6px; margin-top:8px; padding-top:8px; border-top:1px solid var(--line); } .vsave small { font-size:11.5px; line-height:1.35; } .viewpick .pop { right:auto; left:0; }

.viewpick .pop.vpop { width:330px; max-width:92vw; } .colpick .pop.colord { width:310px; max-width:92vw; } .vrow a.vname { text-decoration:none; }

/* Suchfeld kürzer; Seitenleiste rechts für Ansichten und Spalten */
.filters .search { flex:0 1 270px; min-width:170px; max-width:270px; }
.sdr-scrim { position:fixed; inset:0; background:rgba(15,18,40,.38); z-index:70; opacity:0; transition:opacity .18s; } .sdr-scrim.on { opacity:1; } .sdr-scrim[hidden] { display:none; }
.sdr { position:fixed; top:0; right:0; bottom:0; width:min(400px, 94vw); z-index:71; display:flex; flex-direction:column; background:var(--surface); color:var(--txt); border-left:1px solid var(--line); box-shadow:-18px 0 44px -18px rgba(0,0,0,.45); transform:translateX(104%); transition:transform .2s ease; outline:0; }
.sdr.open { transform:none; }
.sdr-head { display:flex; align-items:center; justify-content:space-between; gap:8px; padding:10px 12px; border-bottom:1px solid var(--line); } .sdr-tabs { display:flex; gap:4px; }
.sdr-tabs button { font:inherit; font-weight:700; padding:6px 14px; border:1px solid transparent; border-radius:999px; background:transparent; color:var(--muted); cursor:pointer; } .sdr-tabs button.on { background:color-mix(in srgb, var(--brand) 14%, var(--surface)); color:var(--brand); border-color:color-mix(in srgb, var(--brand) 35%, var(--line)); }
.sdr-body { flex:1; overflow-y:auto; padding:12px 14px; } .sdr-body[hidden], .sdr-foot[hidden] { display:none; } .sdr-foot { display:flex; gap:8px; padding:10px 14px; border-top:1px solid var(--line); background:var(--surface2); }
.sdr .vpop, .sdr .colord { width:auto; min-width:0; position:static; box-shadow:none; border:0; padding:0; } .sdr .colord ul { min-width:0; } .sdr .colord li { padding:6px 8px; } .sdr .vrow { padding:7px 8px; } .sdr .vsave input[type=text] { width:100%; }
/* Status in der Auftragsliste: Farbpunkt an der Nummer, kräftiges Kennzeichen */
.sdot { display:inline-block; width:10px; height:10px; border-radius:50%; background:var(--c); margin-right:7px; vertical-align:middle; box-shadow:0 0 0 3px color-mix(in srgb, var(--c) 22%, transparent); }
.tag.hasbg { background:var(--tbg); color:var(--c); border-color:color-mix(in srgb, var(--c) 38%, var(--tbg)); }  /* eigene Hintergrundfarbe (Fahrt-Art/-Richtung) */
.tag.st { background:color-mix(in srgb, var(--c) 24%, var(--surface)); color:color-mix(in srgb, var(--c) 40%, var(--txt)); border:1px solid color-mix(in srgb, var(--c) 70%, transparent); font-weight:700; }

.cz .dshort { min-width:84px; }

/* Rechnung je Fahrgast */
.splitchk { display:flex; gap:8px; align-items:flex-start; font-weight:500; margin:2px 0 10px; } .splitchk input { width:auto; margin-top:3px; }
.spay { display:none; grid-column:1 / -1; align-items:center; gap:10px; flex-wrap:wrap; padding-top:6px; border-top:1px dashed var(--line); }
#stops.split .spay { display:flex; } .spay label { display:flex; align-items:center; gap:6px; font-size:12.5px; font-weight:600; color:var(--muted); margin:0; }
.spay .sp-price { width:100px; text-align:right; } .spay .sp-pers { width:62px; } .spay .sp-msg { flex:1 1 180px; }
.spay input[readonly] { opacity:.65; }

.spay .sp-bill { flex:1 1 100%; } .spay .sp-bill input { flex:1; width:100%; font-weight:400; }

.splittag { display:inline-flex; align-items:center; gap:4px; margin-left:4px; padding:1px 8px 1px 6px; border-radius:999px; font-size:11.5px; font-weight:800; letter-spacing:.2px; color:#fff; background:#7c3aed; vertical-align:middle; white-space:nowrap; } .splittag svg { flex:none; }

.led { display:inline-block; width:12px; height:12px; border-radius:50%; vertical-align:middle; } .led.on { background:#22c55e; box-shadow:0 0 0 2px rgba(34,197,94,.25), 0 0 6px 1px rgba(34,197,94,.55); } .led.off { background:#ef4444; box-shadow:0 0 0 2px rgba(239,68,68,.22), 0 0 6px 1px rgba(239,68,68,.45); }
td.c, th.c { text-align:center; }
.ctabs .back { margin-right:6px; }


/* Fahrgast-Zeilen verschieben */
.omain .stop { position:relative; } .stop .dnd { position:absolute; left:-15px; top:50%; transform:translateY(-50%); width:14px; height:28px; padding:0; border:0; background:none; color:var(--muted); cursor:grab; font-size:16px; line-height:1; } .stop .dnd:hover, .stop .dnd:focus-visible { color:var(--text); }
.stop.dragging { opacity:.45; outline:2px dashed var(--primary, #4f6bed); }
@media (max-width: 640px) { .stop .dnd { display:none; } }

/* Auftragsformular: kompakte Ansicht */
.ocompact .ogrid { gap:8px; grid-template-columns:minmax(0, 1fr) 300px; } .ocompact .oh { padding-top:6px; padding-bottom:6px; }
.ocompact .card.sec { padding:7px 10px 6px; margin-bottom:7px; border-radius:8px; }
.ocompact .card.sec h2 { font-size:13.5px; padding-bottom:4px; margin:0 0 6px; } .ocompact .card.sec h2 small { display:none; }
.ocompact .ogrid .f { margin-bottom:3px; } .ocompact .ogrid .f label { font-size:11.5px; margin:0 0 1px; }
.ocompact .ogrid .fgrid { gap:0 8px; grid-template-columns:repeat(auto-fit, minmax(130px, 1fr)); }
.ocompact .ogrid input:not([type=checkbox]):not([type=radio]), .ocompact .ogrid select { padding-top:3px; padding-bottom:3px; min-height:28px; font-size:13.5px; }
.ocompact .ogrid textarea { min-height:44px; font-size:13.5px; padding:4px 7px; }
.ocompact .omain .stop { padding:3px 4px; margin-bottom:3px; gap:5px; border-radius:7px; } .ocompact .stop-head { display:none; } .ocompact .spay { padding-top:3px; }
.ocompact .prow { padding:1px 0; } .ocompact .card.sec.price .ptotal { margin-top:6px; padding:6px 10px; } .ocompact .card.sec.price .ptotal b { font-size:20px; }
.ocompact .hnote, .ocompact .card.sec .muted.block:not(.sp-msg) { display:none; }
#compactBtn.on { background:var(--brand-soft, rgba(79,107,237,.14)); border-color:var(--brand); }
@media (max-width: 1100px) { .ocompact .ogrid { grid-template-columns:1fr; } }

.side-online { display:flex; align-items:center; gap:8px; padding:7px 16px; border-top:1px solid var(--side-line); font-size:12.5px; color:var(--side-hi); } .side-online[hidden] { display:none; } .side-online .od { flex:none; width:9px; height:9px; border-radius:50%; background:#22c55e; box-shadow:0 0 6px 1px rgba(34,197,94,.6); } .side-online .olist { white-space:normal; line-height:1.25; }
.side-online .ocust { display:block; margin-top:3px; padding-top:3px; border-top:1px dashed var(--side-line); opacity:.75; } .side-online .ocust[hidden] { display:none; }
html.side-off .side-online::after { content:attr(data-n); }

html.side-off .side:hover .side-online::after, html.side-off .side:focus-within .side-online::after { content:none; }

@media (min-width:981px) { html.side-off .side:not(:hover):not(:focus-within) .menu summary > svg:last-child { display:none; } }

/* Auftragsliste: Kontrolle/AB/Rechnung als kleine Marken, Fahrart farbig, Stopp-Liste */
.ctl { display:inline-block; font-size:12.5px; font-weight:600; line-height:1.6; padding:0 9px; border-radius:999px; white-space:nowrap; border:1px solid transparent; --c: var(--muted); background:color-mix(in srgb, var(--c) 14%, transparent); color:var(--c); border-color:color-mix(in srgb, var(--c) 38%, transparent); }
.ctl-app { --c: var(--ok); } .ctl-mail { --c: var(--info); } .ctl-paper { --c: var(--warn); } .ctl-none { --c: var(--danger); }
.kindtag { display:inline-block; margin-top:3px; font-size:11.5px; opacity:.95; }
.remtext { max-width:240px; font-size:12.5px; line-height:1.35; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; overflow-wrap:anywhere; }
table.otbl.dense .remtext { -webkit-line-clamp:1; }
.stoplist { margin:0; padding-left:16px; font-size:12.5px; line-height:1.35; max-width:300px; } .stoplist li { white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }

/* Fahrerauftrag-Schublade im Auftragsformular */
.fa-send { padding:10px 14px; border-bottom:1px solid var(--line); display:grid; gap:8px; } .fa-state { display:flex; flex-wrap:wrap; gap:6px; }
.fa-row { display:grid; grid-template-columns:auto 1fr auto; gap:8px; align-items:center; } .fa-row input { min-width:0; width:100%; }
@media (max-width:640px) { .fa-row { grid-template-columns:1fr; } }

/* Auftragsliste: Richtung/Fahrtart/Status als schmale, einzeilige Marken (statt mehrzeiliger „Ballons“) */
table.otbl td .tag { display: inline-block; max-width: 100%; vertical-align: middle; padding: 0 8px; border-radius: 7px; font-size: 12.5px; line-height: 1.6; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
table.otbl td .tag.st { font-weight: 700; }
table.otbl td:has(> .tag) { max-width: 190px; }

/* Kopfzeile: offene Kundenmitteilungen (immer sichtbar, auffällig solange etwas offen ist) */
.msgbell { position: relative; }
.msgbell .mb-btn { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); border-radius: 999px; padding: 3px 11px; cursor: pointer; font: inherit; font-weight: 600; }
.msgbell .mb-btn b { min-width: 20px; height: 20px; border-radius: 999px; display: inline-grid; place-items: center; background: var(--muted); color: var(--bg); font-size: 12px; padding: 0 5px; }
.msgbell.has .mb-btn { background: var(--danger); border-color: var(--danger); color: #fff; animation: mbpulse 2s ease-in-out infinite; }
.msgbell.has .mb-btn b { background: #fff; color: var(--danger); }
@keyframes mbpulse { 0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--danger) 55%, transparent); } 50% { box-shadow: 0 0 0 7px transparent; } }
@media (prefers-reduced-motion: reduce) { .msgbell.has .mb-btn { animation: none; } }
.msgbell .mb-pop { position: absolute; right: 0; top: calc(100% + 8px); width: min(460px, 92vw); max-height: 70vh; overflow: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 12px 34px rgba(0,0,0,.28); z-index: 60; }
.mb-pop .mb-i { padding: 10px 12px; border-top: 1px solid var(--line); } .mb-pop .mb-i:first-child { border-top: 0; }
.mb-pop .mb-h { display: flex; gap: 8px; align-items: baseline; justify-content: space-between; } .mb-pop .mb-t { margin: 3px 0 6px; white-space: pre-line; word-break: break-word; }
.mb-pop .mb-a { display: flex; gap: 6px; } .mb-pop .mb-f { padding: 8px 12px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; }
.mb-pop .mb-e { padding: 18px 12px; text-align: center; color: var(--muted); }
@media (max-width: 760px) { .msgbell #msgTxt { display: none; } }

/* Auftragsliste: aufgeraeumter Kopf */
.chip .cn { margin-left:4px; font-size:12.5px; } .qflags { flex-basis:100%; display:flex; flex-wrap:wrap; gap:6px; align-items:center; padding-bottom:2px; }
.btn.ico { padding-inline:10px; }
.exm { position:relative; } .exm > summary { list-style:none; cursor:pointer; } .exm > summary::-webkit-details-marker { display:none; }
.exm-p { position:absolute; right:0; top:calc(100% + 4px); z-index:30; min-width:110px; display:grid; background:var(--surface); border:1px solid var(--line); border-radius:10px; box-shadow:0 8px 24px rgba(0,0,0,.14); overflow:hidden; }
.exm-p a { padding:8px 14px; color:var(--txt); font-size:13.5px; } .exm-p a:hover { background:var(--surface2); }

/* Kopfzeile: neue Portal-Buchung = eigene grüne Marke */
.bookbell .mb-btn { background: #1e8e3e; border-color: #1e8e3e; color: #fff; animation: mbpulseg 2s ease-in-out infinite; } .bookbell .mb-btn b { background: #fff; color: #1e8e3e; }
@keyframes mbpulseg { 0%, 100% { box-shadow: 0 0 0 0 rgba(30,142,62,.5); } 50% { box-shadow: 0 0 0 7px transparent; } }
@media (prefers-reduced-motion: reduce) { .bookbell .mb-btn { animation: none; } } @media (max-width: 760px) { .bookbell #bookTxt { display: none; } }
/* Zeiterfassung: Stempeln in der Kopfzeile */
.clock { display:flex; align-items:center; gap:6px; margin-right:10px; }
.clock .ck-s { font-size:12.5px; color:var(--muted); white-space:nowrap; } .clock[data-mode="in"] .ck-s { color:var(--ok); font-weight:600; } .clock[data-mode="break"] .ck-s { color:var(--warn); font-weight:600; }
.clock button { font:inherit; font-size:12.5px; font-weight:600; background:var(--surface2); color:var(--txt); border:1px solid var(--line); border-radius:8px; padding:4px 10px; cursor:pointer; } .clock button:hover:not(:disabled) { border-color:var(--brand); color:var(--brand); } .clock button:disabled { opacity:.55; cursor:default; }
.clock button[data-a="start"] { background:var(--brand); border-color:var(--brand); color:#fff; } .clock button[data-a="start"]:hover:not(:disabled) { color:#fff; opacity:.9; }
@media (max-width: 900px) { .clock .ck-s { display:none; } }
/* Seite „Zeiten“: links Mitarbeiter (durchsuchbar, scrollt für sich), rechts Monatsblatt */
.tm-grid { display:grid; grid-template-columns:300px minmax(0, 1fr); gap:12px; align-items:start; }
.tm-side { position:sticky; top:8px; display:flex; flex-direction:column; max-height:calc(100vh - 190px); padding:0; overflow:hidden; }
.tm-search { display:flex; align-items:center; gap:6px; padding:8px 10px; border-bottom:1px solid var(--line); color:var(--muted); } .tm-search input { flex:1; border:0; background:none; font:inherit; color:var(--txt); outline:none; min-width:0; }
.tm-chips { display:flex; gap:4px; padding:6px 10px; border-bottom:1px solid var(--line); } .tm-chips button { font:inherit; font-size:12px; font-weight:600; background:var(--surface2); color:var(--muted); border:1px solid var(--line); border-radius:999px; padding:2px 10px; cursor:pointer; } .tm-chips button.on { background:var(--brand); border-color:var(--brand); color:#fff; }
.tm-list { list-style:none; margin:0; padding:4px; overflow:auto; flex:1; } .tm-list li[hidden] { display:none; }
.tm-it { display:flex; align-items:center; gap:9px; padding:6px 8px; border-radius:8px; color:var(--txt); text-decoration:none; } .tm-it:hover { background:var(--surface2); } .tm-it.on { background:color-mix(in srgb, var(--brand) 14%, transparent); }
.tm-nm { flex:1; min-width:0; display:grid; gap:1px; line-height:1.25; } .tm-nm b { font-weight:600; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; } .tm-nm .bdg { justify-self:start; } .tm-h { font-variant-numeric:tabular-nums; color:var(--muted); font-size:12.5px; }
.tm-main { display:grid; gap:10px; min-width:0; } .tm-main > .card, .tm-main > .kpis { margin:0; }
.tm-head { display:flex; align-items:center; gap:6px; padding:10px 14px; flex-wrap:wrap; } .tm-head .grow { flex:1; }
.tm-tab { min-width:0 !important; } .tm-tab td, .tm-tab th { white-space:nowrap; } .tm-tab td:nth-child(6), .tm-tab td:nth-child(7) { white-space:normal; } .tm-tab tfoot th { background:var(--surface2); }
.tm-plan { display:flex; flex-wrap:wrap; gap:6px; margin-top:8px; }
dialog.tm-dlg { border:1px solid var(--line); border-radius:12px; background:var(--surface); color:var(--txt); padding:16px 18px; width:min(560px, 94vw); box-shadow:0 16px 48px rgba(20,24,50,.3); } dialog.tm-dlg::backdrop { background:rgba(20,24,50,.45); }
dialog.tm-dlg h2 { margin:0 0 10px; } dialog.tm-dlg .actions { display:flex; gap:8px; margin-top:12px; align-items:center; } dialog.tm-dlg .actions .grow { flex:1; }
@media (max-width: 900px) { .tm-grid { grid-template-columns:1fr; } .tm-side { position:static; max-height:260px; } }
.tm-grid.tm-one { grid-template-columns:minmax(0, 1fr); }
/* Web Booking: Verwaltung */
.wb-card { border:1px solid var(--line); border-radius:10px; padding:10px 12px; margin-bottom:10px; background:var(--surface2); } .wb-card > summary { cursor:pointer; font-size:14px; }
.wb-vsel > summary { cursor:pointer; font-size:12.5px; white-space:nowrap; } .wb-vsel > div { display:grid; gap:2px; padding:6px 0; }
.wb-rate-tbl td { vertical-align:middle; } .wb-rate-tbl select { min-width:120px; } .wb-tiers td { background:rgba(120,130,160,.07); } .wb-tgrid { display:flex; gap:6px; align-items:flex-end; flex-wrap:wrap; margin:4px 0; } .wb-tgrid span { width:62px; font-size:12px; color:var(--muted); } .wb-tgrid label { font-size:11.5px; display:block; } .wb-tgrid input { width:72px; display:block; } .wb-tiers.hide { display:none; }
.wb-rows input[type=text], .wb-rows select, .wb-rows textarea { width:100%; min-width:90px; } .wb-days { white-space:nowrap; } .wb-days .chk { margin-right:6px; }
@media (max-width: 800px) { .wb-body { grid-template-columns:1fr; } }

/* Web Booking: Konfiguration (übersichtlich gruppiert) */
.wbx-bar { display:flex; align-items:center; gap:12px; flex-wrap:wrap; margin-bottom:12px; } .wbx-bar h2 { margin:0; font-size:17px; } .wbx-bar .sub { color:var(--muted); font-size:12.5px; flex:1; min-width:200px; } .wbx-bar.sticky { position:sticky; top:0; z-index:5; background:var(--bg); padding:8px 0; }
.wbx-sec { border:1px solid var(--line); border-radius:12px; background:var(--surface); margin-bottom:14px; overflow:hidden; } .wbx-sec > header { padding:11px 16px; border-bottom:1px solid var(--line); background:var(--surface2); } .wbx-sec > header h3 { margin:0; font-size:14.5px; } .wbx-sec > header p { margin:2px 0 0; color:var(--muted); font-size:12.5px; } .wbx-sec > .body { padding:14px 16px; }
.wbx-g2 { display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:12px 18px; } .wbx-g3 { display:grid; grid-template-columns:repeat(3, minmax(0,1fr)); gap:12px 18px; } .wbx-g4 { display:grid; grid-template-columns:repeat(4, minmax(0,1fr)); gap:12px 14px; } .wbx-g2 .full, .wbx-g3 .full, .wbx-g4 .full { grid-column:1 / -1; } @media (max-width:900px) { .wbx-g3, .wbx-g4 { grid-template-columns:repeat(2, minmax(0,1fr)); } } @media (max-width:620px) { .wbx-g2, .wbx-g3, .wbx-g4 { grid-template-columns:1fr; } }
.wbx-f > label, .wbx-f > .lb { display:block; font-size:12px; font-weight:600; color:var(--muted); margin-bottom:4px; } .wbx-f input[type=text], .wbx-f input[type=number], .wbx-f input[type=time], .wbx-f select, .wbx-f textarea { width:100%; } .wbx-f .hint { font-size:11.5px; color:var(--muted); margin-top:3px; }
.wbx-in { display:flex; align-items:stretch; } .wbx-in input { border-top-right-radius:0 !important; border-bottom-right-radius:0 !important; min-width:0; } .wbx-in .u { display:grid; place-items:center; padding:0 10px; border:1px solid var(--line); border-left:0; border-radius:0 8px 8px 0; background:var(--surface2); color:var(--muted); font-size:12.5px; white-space:nowrap; }
.wbx-sw { display:inline-flex; align-items:center; gap:8px; cursor:pointer; font-size:13px; font-weight:500; user-select:none; } .wbx-sw input { position:absolute; opacity:0; width:0; height:0; } .wbx-sw i { position:relative; width:36px; height:20px; border-radius:999px; background:var(--line); transition:background .15s; flex:none; } .wbx-sw i::after { content:''; position:absolute; top:2px; left:2px; width:16px; height:16px; border-radius:50%; background:#fff; box-shadow:0 1px 2px rgba(0,0,0,.3); transition:transform .15s; } .wbx-sw input:checked + i { background:var(--ok); } .wbx-sw input:checked + i::after { transform:translateX(16px); } .wbx-sw input:focus-visible + i { outline:2px solid var(--brand); outline-offset:2px; } .wbx-sw input:disabled + i { opacity:.5; }
.wbx-seg { display:inline-flex; border:1px solid var(--line); border-radius:9px; overflow:hidden; } .wbx-seg label { margin:0 !important; } .wbx-seg input { position:absolute; opacity:0; width:0; height:0; } .wbx-seg span { display:block; padding:7px 14px; font-size:13px; font-weight:600; cursor:pointer; color:var(--muted); background:var(--surface); } .wbx-seg input:checked + span { background:var(--brand); color:var(--brand-ink); }
.wbx-chip { display:inline-flex; align-items:center; gap:4px; padding:2px 9px; border-radius:999px; background:var(--surface2); border:1px solid var(--line); font-size:12px; color:var(--txt); white-space:nowrap; } .wbx-chip.b { background:color-mix(in srgb, var(--brand) 14%, transparent); border-color:transparent; color:var(--brand); font-weight:600; } .wbx-chip.off { background:color-mix(in srgb, var(--danger) 12%, transparent); border-color:transparent; color:var(--danger); }
/* Fahrzeugkarte */
.wbx-veh { border:1px solid var(--line); border-radius:12px; background:var(--surface); margin-bottom:10px; } .wbx-veh > summary { display:flex; align-items:center; gap:12px; padding:10px 14px; cursor:pointer; list-style:none; } .wbx-veh > summary::-webkit-details-marker { display:none; } .wbx-veh > summary::after { content:'▾'; color:var(--muted); margin-left:6px; transition:transform .15s; } .wbx-veh[open] > summary::after { transform:rotate(180deg); } .wbx-veh[open] > summary { border-bottom:1px solid var(--line); }
.wbx-veh .th { width:64px; height:42px; border-radius:8px; background:var(--surface2) center/cover no-repeat; border:1px solid var(--line); flex:none; display:grid; place-items:center; color:var(--muted); font-size:18px; } .wbx-veh .ti { flex:1; min-width:0; } .wbx-veh .ti b { display:block; font-size:14.5px; } .wbx-veh .chips { display:flex; flex-wrap:wrap; gap:5px; margin-top:3px; }
.wbx-veh .cols { display:grid; grid-template-columns:1fr 1fr; gap:0; } .wbx-veh .col { padding:14px 16px; } .wbx-veh .col + .col { border-left:1px solid var(--line); } .wbx-veh .col:nth-child(n+3) { border-top:1px solid var(--line); } .wbx-veh .col:nth-child(3) { border-left:0; } .wbx-veh .col h4 { margin:0 0 10px; font-size:12px; text-transform:uppercase; letter-spacing:.04em; color:var(--muted); } .wbx-veh .foot { display:flex; gap:18px; align-items:center; padding:10px 16px; border-top:1px solid var(--line); background:var(--surface2); border-radius:0 0 12px 12px; } @media (max-width:900px) { .wbx-veh .cols { grid-template-columns:1fr; } .wbx-veh .col + .col, .wbx-veh .col:nth-child(3) { border-left:0; border-top:1px solid var(--line); } }
.wbx-ex { margin-top:10px; padding:8px 10px; border-radius:8px; background:var(--surface2); font-size:12.5px; color:var(--muted); }
/* Festpreise */
.wbx-filter { display:flex; gap:10px; align-items:center; flex-wrap:wrap; margin-bottom:10px; } .wbx-filter input[type=search], .wbx-filter select { min-width:180px; }
.wbx-rt { width:100%; border-collapse:separate; border-spacing:0; } .wbx-rt > thead th { text-align:left; font-size:11.5px; text-transform:uppercase; letter-spacing:.04em; color:var(--muted); padding:6px 10px; border-bottom:1px solid var(--line); font-weight:700; } .wbx-rt tbody.wb-rate > tr:first-child > td { padding:9px 10px; border-bottom:1px solid var(--line); vertical-align:middle; } .wbx-rt tbody.wb-rate:nth-of-type(odd) > tr:first-child > td { background:var(--surface2); } .wbx-rt tbody.off > tr:first-child > td { opacity:.5; } .wbx-rt tbody.flt > tr { display:none; }
.wbx-route { display:grid; grid-template-columns:1fr auto 1fr; gap:6px; align-items:center; min-width:340px; } .wbx-route select { width:100%; } .wbx-route .ar { color:var(--muted); text-align:center; font-size:16px; line-height:1; } .wbx-route label.chk { margin:0; justify-content:center; } .wbx-route label.chk span { font-size:12px; color:var(--muted); }
.wbx-px { display:flex; gap:8px; } .wbx-px > div { width:92px; } .wbx-px label { display:block; font-size:11px; color:var(--muted); margin-bottom:2px; } .wbx-px input { width:100%; }
.wbx-rt .tools { white-space:nowrap; text-align:right; } .wbx-rt .tiers > td { padding:10px 14px !important; background:color-mix(in srgb, var(--brand) 5%, var(--surface)) !important; border-bottom:1px solid var(--line); }
/* Zuschläge */
.wbx-sur { display:grid; grid-template-columns:minmax(140px,1.1fr) minmax(250px,2fr) auto 120px auto auto auto; gap:10px 14px; align-items:end; padding:12px 14px; border:1px solid var(--line); border-radius:12px; background:var(--surface); margin-bottom:10px; } .wbx-sur.off { opacity:.55; } .wbx-sur .sum { grid-column:1 / -1; font-size:12.5px; color:var(--muted); border-top:1px dashed var(--line); padding-top:6px; } @media (max-width:1100px) { .wbx-sur { grid-template-columns:1fr 1fr; } .wbx-sur .wd { grid-column:1 / -1; } }
.wbx-days { display:flex; gap:4px; flex-wrap:wrap; } .wbx-days label { margin:0 !important; } .wbx-days input { position:absolute; opacity:0; width:0; height:0; } .wbx-days span { display:grid; place-items:center; width:34px; height:30px; border-radius:8px; border:1px solid var(--line); font-size:12px; font-weight:600; cursor:pointer; color:var(--muted); background:var(--surface); } .wbx-days input:checked + span { background:var(--brand); border-color:var(--brand); color:var(--brand-ink); } .wbx-days input:focus-visible + span { outline:2px solid var(--brand); outline-offset:1px; }
.wbx-presets { display:flex; gap:6px; margin-top:5px; } .wbx-presets button { font-size:11.5px; padding:1px 8px; border-radius:999px; border:1px solid var(--line); background:var(--surface2); color:var(--muted); cursor:pointer; } .wbx-presets button:hover { color:var(--brand); border-color:var(--brand); }
.wbx-tm { display:flex; align-items:center; gap:6px; } .wbx-tm input { width:96px !important; }
/* Einstellungen */
.wbx-nav { display:flex; gap:8px; margin-bottom:12px; flex-wrap:wrap; } .wbx-nav a { padding:4px 12px; border-radius:999px; border:1px solid var(--line); background:var(--surface); color:var(--txt); font-size:13px; font-weight:600; } .wbx-nav a:hover { border-color:var(--brand); color:var(--brand); }
.wbx-opt { display:flex; gap:10px; align-items:flex-start; padding:10px 12px; border:1px solid var(--line); border-radius:10px; cursor:pointer; margin:0 !important; background:var(--surface); } .wbx-opt:has(input:checked) { border-color:var(--brand); background:color-mix(in srgb, var(--brand) 7%, var(--surface)); } .wbx-opt input { margin-top:3px; width:auto; } .wbx-opt b { display:block; font-size:13.5px; } .wbx-opt small { color:var(--muted); font-size:12px; }
.wbx-sw-list { display:grid; gap:10px; } .wbx-pays { display:flex; gap:8px; flex-wrap:wrap; } .wbx-pays label { margin:0 !important; } .wbx-pays input { position:absolute; opacity:0; width:0; height:0; } .wbx-pays span { display:block; padding:5px 12px; border-radius:999px; border:1px solid var(--line); font-size:13px; cursor:pointer; background:var(--surface); } .wbx-pays input:checked + span { background:var(--brand); border-color:var(--brand); color:var(--brand-ink); font-weight:600; }
.wbx-color { display:flex; gap:8px; align-items:center; } .wbx-color input[type=color] { width:40px; height:34px; padding:2px; border:1px solid var(--line); border-radius:8px; background:var(--surface); flex:none; }

.wbx-g5 { display:grid; grid-template-columns:repeat(5, minmax(0,1fr)); gap:12px 14px; } @media (max-width:900px) { .wbx-g5 { grid-template-columns:repeat(2, minmax(0,1fr)); } }

/* Web Booking: Listen und Dialoge (wie Vorbild: klare Liste, Details im Dialog) */
.wbx-head { display:flex; align-items:flex-start; gap:16px; margin:6px 0 16px; } .wbx-head > div { flex:1; min-width:0; } .wbx-head h1 { margin:0; font-size:26px; font-weight:800; letter-spacing:-.01em; } .wbx-head p { margin:4px 0 0; color:var(--muted); max-width:760px; }
.wbx-list { border:1px solid var(--line); border-radius:12px; background:var(--surface); overflow:auto; margin-bottom:12px; } .wbx-list table { width:100%; border-collapse:collapse; } .wbx-list th { text-align:left; font-size:11.5px; text-transform:uppercase; letter-spacing:.05em; color:var(--muted); font-weight:700; padding:11px 12px; background:var(--surface2); border-bottom:1px solid var(--line); white-space:nowrap; } .wbx-list td { padding:11px 12px; border-bottom:1px solid var(--line); vertical-align:middle; } .wbx-list tr:last-child td { border-bottom:0; } .wbx-list th.r, .wbx-list td.r { text-align:right; } .wbx-list tr.off td:not(:nth-last-child(-n+2)) { opacity:.5; } .wbx-list td.wrap { max-width:300px; color:var(--muted); font-size:13px; } .wbx-list td.empty { text-align:center; color:var(--muted); padding:28px; }
.wbx-list .nm { display:flex; align-items:center; gap:10px; } .wbx-list .th { width:56px; height:38px; border-radius:7px; background:var(--surface2) center/cover no-repeat; border:1px solid var(--line); flex:none; }
.wbx-act { display:inline-flex; gap:2px; align-items:center; } .wbx-ic { display:inline-grid; place-items:center; width:32px; height:32px; border:0; border-radius:8px; background:transparent; color:var(--txt); cursor:pointer; } .wbx-ic:hover { background:var(--surface2); color:var(--brand); } .wbx-ic svg { width:16px; height:16px; }
dialog.wbx-dlg { border:0; border-radius:16px; padding:0; width:min(640px, calc(100vw - 24px)); max-height:calc(100vh - 32px); background:var(--surface); color:var(--txt); box-shadow:0 24px 70px rgba(0,0,0,.4); overflow:hidden; } dialog.wbx-dlg::backdrop { background:rgba(10,14,30,.55); } dialog.wbx-dlg[open] { display:flex; flex-direction:column; } dialog.wbx-dlg form { display:flex; flex-direction:column; min-height:0; max-height:calc(100vh - 32px); }
.wbx-dlg header { display:flex; gap:12px; padding:20px 24px 8px; } .wbx-dlg header > div { flex:1; } .wbx-dlg header h2 { margin:0; font-size:19px; } .wbx-dlg header p { margin:6px 0 0; color:var(--muted); font-size:13px; line-height:1.45; } .wbx-dlg header .x { border:0; background:none; color:var(--muted); font-size:16px; cursor:pointer; align-self:flex-start; width:28px; height:28px; border-radius:6px; } .wbx-dlg header .x:hover { background:var(--surface2); }
.wbx-dlg .bd { padding:10px 24px 8px; overflow:auto; display:grid; gap:14px; } .wbx-dlg footer { display:flex; justify-content:flex-end; gap:10px; padding:14px 24px 20px; }
.wbx-fold { border:1px solid var(--line); border-radius:12px; } .wbx-fold > summary { cursor:pointer; padding:12px 14px; font-weight:600; list-style:none; display:flex; align-items:center; } .wbx-fold > summary::-webkit-details-marker { display:none; } .wbx-fold > summary::after { content:'▾'; margin-left:auto; color:var(--muted); } .wbx-fold[open] > summary::after { transform:rotate(180deg); } .wbx-fold .in { padding:0 14px 14px; display:grid; gap:12px; }
.wbx-img { display:flex; gap:12px; align-items:center; } .wbx-img .pv { width:110px; height:72px; border-radius:10px; border:1px dashed var(--line); background:var(--surface2) center/cover no-repeat; flex:none; } .wbx-img input { flex:1; }
.wbx-vsel { border:1px solid var(--line); border-radius:8px; padding:0; } .wbx-vsel > summary { padding:8px 11px; cursor:pointer; font-size:13.5px; } .wbx-vsel > div { padding:2px 11px 10px; display:grid; gap:3px; }
.wbx-dlg .wbx-g3 { grid-template-columns:repeat(3, minmax(0,1fr)); } @media (max-width:560px) { .wbx-dlg .wbx-g2, .wbx-dlg .wbx-g3 { grid-template-columns:1fr; } }

.wbx-list .nm b { white-space:nowrap; } .wbx-list .th { display:grid; place-items:center; font-size:18px; } .wbx-list td { white-space:nowrap; } .wbx-list td.wrap { white-space:normal; min-width:160px; }

dialog.wbx-dlg.big { width:calc(100vw - 24px); max-width:none; } .wbx-dlg.big .wbx-map { height:max(320px, calc(100vh - 290px)); }
.wbx-map { height:320px; border-radius:10px; border:1px solid var(--line); isolation:isolate; margin-top:2px; } .wbx-mapbar { display:flex; gap:8px; margin-top:6px; } .wbx-mapbar input { flex:1; } .wbx-img .err-t, .wbx-f .err-t { color:var(--danger); font-size:12.5px; margin-top:4px; } .wbx-img .hint { margin-top:6px; }

.wbx-cols { display:grid; grid-template-columns:repeat(2, minmax(0,1fr)); gap:14px; align-items:start; max-width:1180px; } .wbx-cols .wbx-sec { margin-bottom:0; } .wbx-cols .wbx-sec > header { padding:8px 14px; } .wbx-cols .wbx-sec > .body { padding:12px 14px; } .wbx-cols .wbx-g2 { gap:10px 12px; } .wbx-cols textarea { min-height:0; } @media (max-width:1000px) { .wbx-cols { grid-template-columns:1fr; } }

/* Neuer Auftrag: frühere Fahrten des Kunden */
.hist { margin-top:10px; padding:10px 12px; background:var(--surface2); border:1px solid var(--line); border-radius:10px; } .hist[hidden] { display:none; }
.hist-head { display:flex; flex-wrap:wrap; align-items:center; gap:6px 8px; } .hist-head b { display:flex; align-items:center; gap:6px; font-size:13.5px; } .hist-head small { font-size:12.5px; }
.hist-head input { margin-left:auto; flex:0 1 280px; min-width:0; } .hist-head input[hidden] { display:none; }
.hist .notice { margin:8px 0 0; font-size:13.5px; }
.hist-list { max-height:420px; overflow:auto; margin-top:8px; padding:2px; display:grid; gap:10px; } .hist-list:empty { display:none; }
.hist-g { --dir:var(--brand); background:var(--surface); border:1px solid var(--line); border-left:5px solid var(--dir); border-radius:8px; } .hist-g.back { --dir:var(--ok); }
.hist-g:nth-child(even) { background:color-mix(in srgb, var(--muted) 12%, var(--surface)); }
.hist-g.open { border-color:var(--dir); box-shadow:0 0 0 1px var(--dir); background:color-mix(in srgb, var(--dir) 14%, var(--surface)); }
.hist-row { display:flex; align-items:center; gap:10px; padding:8px 10px; }
.hist-t { flex:1; min-width:0; display:grid; gap:5px; padding:0; border:0; background:none; color:inherit; font:inherit; text-align:left; cursor:pointer; }
.hist-t::after { content:'Fahrgäste und Details ▾'; font-size:11.5px; color:var(--muted); } .hist-t[aria-expanded=true]::after { content:'Details schließen ▴'; }
.hist-sub { display:flex; flex-wrap:wrap; align-items:center; gap:3px 12px; font-size:12.5px; color:var(--muted); } .hist-sub b, .hist-price { color:var(--txt); font-weight:600; }
.hist-way { display:grid; gap:2px; font-size:13.5px; font-weight:600; } .hist-way > span { display:flex; gap:8px; align-items:baseline; } .hist-way > span > span { min-width:0; overflow-wrap:anywhere; }
.hist-way i { flex:0 0 52px; font-style:normal; font-size:11.5px; font-weight:700; text-transform:uppercase; color:var(--muted); } .hist-way .via { font-weight:400; font-size:12.5px; }
.hist-a { display:flex; flex-wrap:wrap; justify-content:flex-end; gap:6px; }
.hist-b { padding:0 8px 8px; display:grid; gap:6px; } .hist-b[hidden] { display:none; } .hist-b > small { padding:0 2px; font-size:11.5px; }
.hist-trip { background:var(--surface); border:1px solid var(--line); border-radius:7px; } .hist-info { flex:1; min-width:0; display:grid; gap:3px; font-size:12.5px; }
.hist-stops { margin:3px 0 0; padding:0; list-style:none; } .hist-stops label.chk { margin:2px 0; font-weight:400; font-size:12.5px; overflow-wrap:anywhere; } .ogrid .hist-stops input[type=checkbox] { flex:none; }
@media (max-width: 640px) { .hist-row { flex-wrap:wrap; } .hist-t, .hist-info { flex-basis:100%; } .hist-head input { margin-left:0; flex-basis:100%; } }
.hist-skip { display:none; margin-top:10px; justify-content:flex-start; } .hist-head .btn[hidden] { display:none; } .hist.closed .hist-list, .hist.closed #histMore, .hist.closed #histQ { display:none; } .hist-head #histQ + .btn { margin-left:auto; } .hist-head #histQ:not([hidden]) + .btn { margin-left:0; } .hist.closed .hist-head .btn { margin-left:auto; }
/* Neuer Auftrag, erster Schritt: nur das Kundenfeld (und die früheren Fahrten) */
.ogate .ogrid { grid-template-columns:minmax(0, 1fr); } .ogate .oside, .ogate .otabs, .ogate .oh-actions button, .ogate .oh-sep, .ogate .omain > .sec:not(:first-child), .ogate .omain > .sec:first-child .fgrid > .f:not(.wide) { display:none; }
.ogate .hist-skip { display:flex; } .ogate .hist-list { max-height:60vh; }

/* ---------- Rechnung: Aufbau und Aussehen wie die Auftragsmaske ---------- */
.inv .card.sec h2 .grow { flex:1; } .inv .card.sec h2 .btn { font-weight:600; }
.inv .f label { margin:0 0 3px; font-size:12.5px; letter-spacing:.2px; }
.inv .oh-sub { align-items:center; } .inv .oh-sub .stepper { display:inline-flex; margin:0; }
.inv .oh-actions details.menu { padding:0; display:block; flex:0 0 auto; } .inv .oh-actions details.menu > summary.btn { list-style:none; gap:7px; padding:6px 12px; color:var(--txt); } .inv .oh-actions details.menu > summary.btn:hover { background:var(--surface2); color:var(--txt); }
.inv .ptotal output { font:inherit; }
@media (min-width:981px) { .inv .layout { grid-template-columns:minmax(0, 1fr) 340px; gap:14px; } .inv .col-side { top:84px; } }
@media (max-width:1100px) { .inv .oh { position:static; } .inv .col-side { top:10px; } }
