/* Hosting-Fuchs.de: Design-Token und Komponenten auf Bootstrap 5.3. Schriften liegen lokal unter /fonts. */

@font-face {
    font-family: 'Plus Jakarta Sans';
    font-style: normal;
    font-weight: 300 800;
    font-display: swap;
    src: url('../fonts/plus-jakarta-sans-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'Plus Jakarta Sans';
    font-style: normal;
    font-weight: 300 800;
    font-display: swap;
    src: url('../fonts/plus-jakarta-sans-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: 'Rubik';
    font-style: normal;
    font-weight: 400 900;
    font-display: swap;
    src: url('../fonts/rubik-latin-ext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'Rubik';
    font-style: normal;
    font-weight: 400 900;
    font-display: swap;
    src: url('../fonts/rubik-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Token: Panel (Kundenbereich, Admin, Anmeldung) ---------- */
:root,
[data-bs-theme="light"] {
    --bs-font-sans-serif: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --bs-body-font-family: var(--bs-font-sans-serif);
    --bs-body-font-size: 0.925rem;
    --bs-body-font-weight: 500;
    --bs-body-line-height: 1.5;
    --bs-body-bg: #f7f8fb;
    --bs-body-color: #1a2233;
    --bs-body-color-rgb: 26, 34, 51;
    --bs-secondary-color: #566074;
    --bs-secondary-color-rgb: 86, 96, 116;
    --bs-secondary-bg: #F1F5F3;
    --bs-tertiary-bg: #F8FAF9;
    --bs-emphasis-color: #031D5B;
    --bs-heading-color: #031D5B;
    --bs-border-color: #e4e8ef;
    --bs-border-color-translucent: rgba(11, 19, 15, 0.12);
    --bs-link-color: #c4540a;
    --bs-link-color-rgb: 196, 84, 10;
    --bs-link-hover-color: #031D5B;
    --bs-link-hover-color-rgb: 3, 29, 91;
    --bs-link-decoration: none;
    --bs-border-radius: 10px;
    --bs-border-radius-sm: 6px;
    --bs-border-radius-lg: 14px;
    --bs-border-radius-xl: 18px;
    --bs-border-radius-xxl: 24px;
    --bs-focus-ring-color: rgba(227, 99, 2, 0.25);

    --rm-primary: #031D5B;
    --rm-primary-dim: rgba(3, 29, 91, 0.06);
    --rm-accent: #E36302;
    --rm-accent-dark: #c4540a;
    --tab-active: var(--rm-accent-dark);
    --rm-accent-strong: #c4540a;
    --rm-accent-dim: rgba(227, 99, 2, 0.09);
    --rm-accent-tint: rgba(227, 99, 2, 0.12);
    --brand-deep: #031D5B;
    --brand-deep-2: #24448f;
    --chart-c: #6c8ebf;
    --chart-d: #b9c4d6;
    --text-main: #1a2233;
    --text-muted: #566074;
    --border-light: #e4e8ef;
    --surface: #fff;
    --surface-2: #F8FAF9;
    --surface-hover: #F1F5F3;
    --card-background: var(--surface);
    --input-border: rgb(11 19 15 / 0.42);
    --focus-ring: #a34500;
    --ink: 11 19 15;
    --sys-green: #1d9e75;
    --sys-green-bg: rgba(29, 158, 117, 0.10);
    --sys-red: #d64545;
    --sys-red-hover: #b83232;
    --sys-red-bg: rgba(214, 69, 69, 0.10);
    --sys-warning: #b45309;
    --sys-warning-bg: rgba(180, 83, 9, 0.10);
    --sys-blue: #0284C7;
    --sys-blue-bg: rgba(2, 132, 199, 0.12);
    --btn-primary-bg: #c4540a;
    --btn-primary-hover: #a34500;
    --btn-success-bg: #1d9e75;
    --btn-success-hover: #157a5c;
    --btn-light-bg: var(--surface-2);
    --btn-light-border: rgba(11, 19, 15, 0.08);
    --alert-success-bg: #f0fdf4;
    --alert-success-border: #bbf7d0;
    --alert-success-text: #166534;
    --alert-danger-bg: #fef2f2;
    --alert-danger-border: #fecaca;
    --alert-danger-text: #991b1b;
    --alert-warning-bg: #FFF8E6;
    --alert-warning-border: #fef3c7;
    --alert-warning-text: #92400e;
    --alert-info-bg: #f0f9ff;
    --alert-info-border: #bae6fd;
    --alert-info-text: #075985;
    --navbar-bg: rgba(244, 246, 245, 0.85);
    --navbar-border: rgba(0, 0, 0, 0.05);
    --backdrop: rgba(3, 29, 91, 0.45);
    --shadow-sm: 0 1px 2px rgba(3, 29, 91, 0.06), 0 1px 3px rgba(3, 29, 91, 0.04);
    --shadow-md: 0 2px 10px rgba(3, 29, 91, 0.08), 0 1px 3px rgba(3, 29, 91, 0.05);
    --shadow-lg: 0 12px 34px rgba(3, 29, 91, 0.12), 0 2px 8px rgba(3, 29, 91, 0.06);
    --radius-xxl: 24px;
    --radius-xl: 18px;
    --radius-lg: 14px;
    --radius-md: 10px;
    --radius-sm: 6px;
    --sidebar-width: 280px;
    --navbar-height: 80px;
    --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
    --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
    --select-chevron: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23031D5B' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}

[data-bs-theme="dark"] {
    color-scheme: dark;
    --bs-body-bg: #0b1322;
    --bs-body-color: #e6eaf4;
    --bs-body-color-rgb: 230, 234, 244;
    --bs-secondary-color: #9aa7c0;
    --bs-secondary-color-rgb: 154, 167, 192;
    --bs-secondary-bg: #1a2744;
    --bs-tertiary-bg: #101a2e;
    --bs-emphasis-color: #ffffff;
    --bs-heading-color: #dbe4fa;
    --bs-border-color: #25324f;
    --bs-border-color-translucent: rgba(255, 255, 255, 0.15);
    --bs-link-color: #ff8a3d;
    --bs-link-color-rgb: 255, 138, 61;
    --bs-link-hover-color: #dbe4fa;
    --bs-link-hover-color-rgb: 219, 228, 250;

    --rm-primary: #dbe4fa;
    --rm-primary-dim: rgba(219, 228, 250, 0.08);
    --rm-accent-dark: #ff8a3d;
    --tab-active: #c4540a;
    --rm-accent-dim: rgba(227, 99, 2, 0.18);
    --brand-deep: #0b1322;
    --text-main: #e6eaf4;
    --text-muted: #9aa7c0;
    --border-light: #25324f;
    --surface: #131e36;
    --surface-2: #0f1a2f;
    --surface-hover: #1b2a49;
    --input-border: rgb(255 255 255 / 0.32);
    --focus-ring: #ff8a3d;
    --ink: 255 255 255;
    --sys-green: #34d399;
    --sys-green-bg: rgba(52, 211, 153, 0.14);
    --sys-red: #f87171;
    --sys-red-hover: #ef4444;
    --sys-red-bg: rgba(248, 113, 113, 0.14);
    --sys-warning: #fbbf24;
    --sys-warning-bg: rgba(251, 191, 36, 0.14);
    --sys-blue: #38bdf8;
    --sys-blue-bg: rgba(56, 189, 248, 0.14);
    --btn-primary-bg: #c4540a;
    --btn-primary-hover: #e36302;
    --btn-light-bg: #1c2b4a;
    --btn-light-border: rgba(255, 255, 255, 0.14);
    --alert-success-bg: rgba(52, 211, 153, 0.12);
    --alert-success-border: rgba(52, 211, 153, 0.3);
    --alert-success-text: #6ee7b7;
    --alert-danger-bg: rgba(248, 113, 113, 0.12);
    --alert-danger-border: rgba(248, 113, 113, 0.3);
    --alert-danger-text: #fca5a5;
    --alert-warning-bg: #3a2b0d;
    --alert-warning-border: rgba(255, 138, 61, 0.4);
    --alert-warning-text: #fdba74;
    --alert-info-bg: rgba(56, 189, 248, 0.1);
    --alert-info-border: rgba(56, 189, 248, 0.3);
    --alert-info-text: #7dd3fc;
    --navbar-bg: rgba(11, 19, 34, 0.85);
    --navbar-border: rgba(255, 255, 255, 0.06);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 2px 10px rgba(0, 0, 0, 0.45);
    --shadow-lg: 0 0 0 1px rgba(255, 255, 255, 0.07), 0 12px 34px rgba(0, 0, 0, 0.5);
    --select-chevron: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23dbe4fa' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
}

/* ---------- Grundlagen ---------- */
html { scrollbar-gutter: stable; }
body {
    letter-spacing: -0.01em;
    word-spacing: 0.08em;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 { font-weight: 700; letter-spacing: -0.025em; text-wrap: balance; }
p { text-wrap: pretty; }
a { text-decoration: none; transition: color 160ms var(--ease-out), background-color 160ms var(--ease-out), border-color 160ms var(--ease-out), box-shadow 160ms var(--ease-out), transform 160ms var(--ease-out), opacity 160ms var(--ease-out); }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.min-w-0 { min-width: 0; }
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 3000; padding: 0.5rem 1rem; border-radius: 0 0 var(--radius-md) 0; background: var(--rm-accent); color: #fff; }
.skip-link:focus { left: 0; }
.brand-tag { display: inline-block; margin-left: 0.35rem; padding: 0.1rem 0.45rem; border-radius: 999px; background: var(--rm-accent-dim); color: var(--rm-accent-dark); font-size: 0.65rem; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; vertical-align: 0.15rem; }
:where(a, button, summary, [tabindex]):focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
:root img.logo-for-dark { display: none; }
:root[data-bs-theme="dark"] img.logo-for-light { display: none; }
:root[data-bs-theme="dark"] img.logo-for-dark { display: block; }
/* Absende-Schutz: Spinner im gedrückten Knopf */
.spinner { display: inline-block; width: 0.9em; height: 0.9em; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; vertical-align: -0.1em; animation: spin 700ms linear infinite; }
.is-busy { opacity: 0.85; cursor: progress; }
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
}

/* ---------- Bootstrap-Komponenten im Design der Vorlage ---------- */
.btn {
    --bs-btn-padding-x: 1.25rem;
    --bs-btn-padding-y: 0.6rem;
    --bs-btn-font-size: 0.875rem;
    --bs-btn-font-weight: 600;
    --bs-btn-border-radius: var(--radius-lg);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: color 160ms var(--ease-out), background-color 160ms var(--ease-out), border-color 160ms var(--ease-out), box-shadow 160ms var(--ease-out), transform 160ms var(--ease-out);
}
.btn:active { transform: scale(0.97); }
.btn-sm { --bs-btn-padding-x: 0.75rem; --bs-btn-padding-y: 0.35rem; --bs-btn-font-size: 0.75rem; --bs-btn-border-radius: var(--radius-md); }
.btn-lg { --bs-btn-padding-x: 1.75rem; --bs-btn-padding-y: 0.75rem; --bs-btn-font-size: 1rem; --bs-btn-border-radius: var(--radius-xl); }
.btn .bi-arrow-right { transition: transform 0.25s ease; }
.btn-primary {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--btn-primary-bg);
    --bs-btn-border-color: var(--btn-primary-bg);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--btn-primary-hover);
    --bs-btn-hover-border-color: var(--btn-primary-hover);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--btn-primary-hover);
    --bs-btn-active-border-color: var(--btn-primary-hover);
    --bs-btn-disabled-color: #fff;
    --bs-btn-disabled-bg: var(--btn-primary-bg);
    --bs-btn-disabled-border-color: var(--btn-primary-bg);
    --bs-btn-focus-shadow-rgb: 227, 99, 2;
}
.btn-light {
    --bs-btn-color: var(--rm-primary);
    --bs-btn-bg: var(--btn-light-bg);
    --bs-btn-border-color: var(--btn-light-border);
    --bs-btn-hover-color: var(--rm-primary);
    --bs-btn-hover-bg: var(--surface-hover);
    --bs-btn-hover-border-color: var(--btn-light-border);
    --bs-btn-active-color: var(--rm-primary);
    --bs-btn-active-bg: var(--surface-hover);
    --bs-btn-active-border-color: var(--btn-light-border);
    --bs-btn-disabled-color: var(--rm-primary);
    --bs-btn-disabled-bg: var(--btn-light-bg);
    --bs-btn-disabled-border-color: var(--btn-light-border);
    --bs-btn-focus-shadow-rgb: 3, 29, 91;
}
.btn-danger {
    --bs-btn-bg: var(--sys-red);
    --bs-btn-border-color: var(--sys-red);
    --bs-btn-hover-bg: var(--sys-red-hover);
    --bs-btn-hover-border-color: var(--sys-red-hover);
    --bs-btn-active-bg: var(--sys-red-hover);
    --bs-btn-active-border-color: var(--sys-red-hover);
}
.btn-outline-danger {
    --bs-btn-color: var(--sys-red);
    --bs-btn-border-color: var(--sys-red);
    --bs-btn-hover-bg: var(--sys-red);
    --bs-btn-hover-border-color: var(--sys-red);
    --bs-btn-active-bg: var(--sys-red);
    --bs-btn-active-border-color: var(--sys-red);
}
.btn-link { --bs-btn-font-weight: 600; }
.btn-nav { --bs-btn-padding-x: 1.15rem; --bs-btn-padding-y: 0.5rem; --bs-btn-font-size: 0.825rem; --bs-btn-font-weight: 700; --bs-btn-border-radius: var(--radius-lg); }
.btn-nav.btn-light { --bs-btn-bg: var(--surface); --bs-btn-border-color: var(--border-light); --bs-btn-hover-border-color: var(--border-light); }
@media (hover: hover) and (pointer: fine) {
    .btn.w-100:hover .bi-arrow-right { transform: translateX(3px); }
}

.form-label { font-size: 0.85rem; font-weight: 700; color: var(--text-main); margin-bottom: 0.5rem; }
.form-control, .form-select {
    padding: 0.6rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-main);
    background-color: var(--surface);
    border: 1px solid var(--input-border);
    border-radius: var(--radius-lg);
    transition: border-color 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}
.form-select { padding-right: 2.25rem; background-image: var(--select-chevron); background-size: 12px 10px; background-position: right 1rem center; }
.form-control:focus, .form-select:focus { color: var(--text-main); background-color: var(--surface); border-color: var(--rm-accent); box-shadow: 0 0 0 3px var(--rm-accent-tint); }
.form-control::placeholder { color: var(--text-muted); opacity: 0.5; }
.form-control:disabled, .form-control[readonly], .form-select:disabled { background-color: var(--surface-2); border-color: rgb(var(--ink) / 0.06); color: var(--text-muted); opacity: 0.8; }
.form-control.is-invalid, .form-select.is-invalid, .was-validated .form-control:invalid { border-color: var(--sys-red); }
.form-control.is-invalid:focus, .form-select.is-invalid:focus { box-shadow: 0 0 0 3px var(--sys-red-bg); }
.invalid-feedback { color: var(--sys-red); font-size: 0.8rem; margin-top: 0.4rem; }
.form-legend { margin: 0.6rem 0 -0.2rem; padding-top: 1.1rem; border-top: 1px solid var(--border-light); color: var(--text-muted); font-size: 0.72rem; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase; }
.form-legend:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-text { color: var(--text-muted); font-size: 0.8rem; }
.form-check-input { width: 18px; height: 18px; margin-top: 0; border: 2px solid var(--text-muted); border-radius: var(--radius-sm); background-color: transparent; }
.form-check-input:checked { background-color: var(--rm-accent); border-color: var(--rm-accent); }
.form-check-input:focus { border-color: var(--rm-accent); box-shadow: 0 0 0 3px var(--rm-accent-tint); }
.form-check-label { font-weight: 600; color: var(--text-muted); }
/* Kästchen mittig auf der ersten Textzeile, mit gleichem Abstand zum Text in allen Bereichen */
.form-check { padding-left: calc(18px + 0.6rem); }
.form-check > .form-check-input { margin-left: calc(-18px - 0.6rem); margin-top: calc(0.75em - 9px); margin-top: calc((1lh - 18px) / 2); }
/* Dateiauswahl: das unsichtbare Feld liegt über der ganzen Fläche, damit Tastatur, Klick und Ablegen wie gewohnt funktionieren */
.file-pick { position: relative; display: flex; align-items: center; gap: 0.75rem; padding: 0.3rem 0.5rem; }
.file-pick-input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.file-pick-input::file-selector-button { cursor: pointer; }
.file-pick-button { display: inline-flex; flex: none; align-items: center; gap: 0.4rem; padding: 0.25rem 0.75rem; border: 1px solid var(--border-light); border-radius: var(--radius-sm); background: var(--surface-2); color: var(--text-main); font-weight: 600; white-space: nowrap; }
.file-pick-names { min-width: 0; overflow: hidden; color: var(--text-muted); text-overflow: ellipsis; white-space: nowrap; }
.file-pick:focus-within { border-color: var(--rm-accent); box-shadow: 0 0 0 3px var(--rm-accent-tint); }
.file-pick.is-invalid:focus-within { border-color: var(--sys-red); box-shadow: 0 0 0 3px var(--sys-red-bg); }
@media (hover: hover) and (pointer: fine) {
    .file-pick:hover .file-pick-button { border-color: var(--input-border); }
}

.alert {
    --bs-alert-padding-x: 1.25rem;
    --bs-alert-padding-y: 1rem;
    --bs-alert-border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.875rem;
    font-weight: 500;
}
.alert-icon { font-size: 1.15rem; flex-shrink: 0; }
.alert-content { flex-grow: 1; min-width: 0; overflow-wrap: anywhere; }
.alert-dismissible { padding-right: var(--bs-alert-padding-x); }
.alert-dismissible .btn-close { position: static; padding: 0.25rem; margin-left: auto; font-size: 0.75rem; }
.alert-primary { --bs-alert-bg: rgb(var(--ink) / 0.04); --bs-alert-border-color: rgb(var(--ink) / 0.08); --bs-alert-color: var(--rm-primary); --bs-alert-link-color: var(--rm-primary); }
.alert-success { --bs-alert-bg: var(--alert-success-bg); --bs-alert-border-color: var(--alert-success-border); --bs-alert-color: var(--alert-success-text); --bs-alert-link-color: var(--alert-success-text); }
.alert-danger { --bs-alert-bg: var(--alert-danger-bg); --bs-alert-border-color: var(--alert-danger-border); --bs-alert-color: var(--alert-danger-text); --bs-alert-link-color: var(--alert-danger-text); }
.alert-warning { --bs-alert-bg: var(--alert-warning-bg); --bs-alert-border-color: var(--alert-warning-border); --bs-alert-color: var(--alert-warning-text); --bs-alert-link-color: var(--alert-warning-text); }
.alert-info { --bs-alert-bg: var(--alert-info-bg); --bs-alert-border-color: var(--alert-info-border); --bs-alert-color: var(--alert-info-text); --bs-alert-link-color: var(--alert-info-text); }
.alert .btn-link { color: inherit; text-decoration: underline; font-size: inherit; }

.card {
    --bs-card-bg: var(--card-background);
    --bs-card-border-color: var(--border-light);
    --bs-card-border-radius: var(--radius-xxl);
    --bs-card-inner-border-radius: calc(var(--radius-xxl) - 1px);
    --bs-card-spacer-y: 1.5rem;
    --bs-card-spacer-x: 1.5rem;
    --bs-card-title-color: var(--rm-primary);
    box-shadow: var(--shadow-sm);
    margin-bottom: 1.5rem;
}
.card-title { font-size: 1.1rem; font-weight: 700; margin-bottom: 0.75rem; }
@media (max-width: 575.98px) { .card { --bs-card-spacer-y: 1.25rem; --bs-card-spacer-x: 1.25rem; } }

.dropdown-menu {
    --bs-dropdown-bg: var(--surface);
    --bs-dropdown-color: var(--text-main);
    --bs-dropdown-border-color: var(--border-light);
    --bs-dropdown-border-radius: var(--radius-xl);
    --bs-dropdown-link-color: var(--text-main);
    --bs-dropdown-link-hover-color: var(--rm-accent);
    --bs-dropdown-link-hover-bg: var(--bs-body-bg);
    --bs-dropdown-link-active-color: var(--rm-accent);
    --bs-dropdown-link-active-bg: var(--bs-body-bg);
    --bs-dropdown-divider-bg: var(--border-light);
    box-shadow: var(--shadow-lg);
}
.modal-content { --bs-modal-bg: var(--surface); --bs-modal-border-color: var(--border-light); --bs-modal-border-radius: var(--radius-xxl); box-shadow: var(--shadow-lg); }
.modal-header, .modal-footer { border-color: var(--border-light); }
.modal-title { color: var(--rm-primary); }
.modal-backdrop { --bs-backdrop-bg: var(--backdrop); --bs-backdrop-opacity: 1; }

.badge-state { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.25rem 0.65rem; border-radius: 999px; font-size: 0.75rem; font-weight: 700; vertical-align: middle; }
.badge-state::before { content: ''; display: inline-block; width: 6px; height: 6px; border-radius: 999px; background: currentColor; }
/* Ein Icon ersetzt den Punkt */
.badge-state:has(> .bi)::before { content: none; }
.badge-state.success { background: var(--sys-green-bg); color: var(--sys-green); }
.badge-state.pending { background: var(--sys-warning-bg); color: var(--sys-warning); }
.badge-state.failed { background: var(--sys-red-bg); color: var(--sys-red); }
.badge-state.info { background: var(--sys-blue-bg); color: var(--sys-blue); }

/* ---------- Anmeldeseiten ---------- */
.auth-page {
    background-color: var(--bs-body-bg);
    background-image:
        linear-gradient(to right, rgb(var(--ink) / 0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgb(var(--ink) / 0.05) 1px, transparent 1px),
        radial-gradient(circle at 15% 30%, rgba(79, 128, 255, 0.16), transparent 45%),
        radial-gradient(circle at 95% 0, var(--rm-accent-tint), transparent 38%);
    background-size: 42px 42px, 42px 42px, auto, auto;
}
.auth-wrapper { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1.5rem; position: relative; background-color: var(--bs-body-bg); overflow-x: hidden; overflow-y: auto; }
.auth-card { position: relative; z-index: 1; width: 100%; max-width: 450px; padding: 2.5rem; border: 1px solid var(--border-light); border-radius: var(--radius-xxl); background-color: var(--card-background); box-shadow: var(--shadow-lg); }
.auth-card-wide { max-width: 720px; }
.auth-logo { display: flex; align-items: center; justify-content: center; gap: 0.5rem; margin-bottom: 1.5rem; }
.auth-logo img { display: block; height: 64px; width: auto; }
.auth-title { margin: 0 0 0.35rem; font-size: 1.45rem; font-weight: 800; text-align: center; color: var(--rm-primary); }
.auth-subtitle { margin-bottom: 2rem; font-size: 0.875rem; color: var(--text-muted); text-align: center; }
.error-art { display: block; width: min(100%, 300px); height: auto; margin: 1rem auto 0; }
.error-code { margin: 1rem 0 0.25rem; color: var(--rm-accent); font-size: 4.5rem; font-weight: 800; line-height: 1; letter-spacing: -0.04em; }
.error-title { font-size: 1.5rem; font-weight: 800; }
.maintenance-text { overflow-wrap: anywhere; }
.error-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.35rem 1.25rem; margin-top: 1.25rem; font-size: 0.9rem; }
.auth-form-group { position: relative; margin-bottom: 1.25rem; }
.auth-form-label { display: block; margin-bottom: 0.5rem; font-size: 0.8rem; font-weight: 700; color: var(--text-main); }
.auth-input-group { position: relative; display: flex; align-items: center; }
.auth-input-group .input-icon { position: absolute; left: 1.25rem; color: var(--text-muted); font-size: 1.1rem; pointer-events: none; transition: color 0.25s ease; }
.auth-input {
    width: 100%;
    padding: 0.8rem 1.25rem 0.8rem 2.85rem;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    background-color: var(--bs-body-bg);
    color: var(--text-main);
    font-size: 0.9rem;
    font-weight: 600;
    outline: none;
    transition: color 160ms var(--ease-out), background-color 160ms var(--ease-out), border-color 160ms var(--ease-out), box-shadow 160ms var(--ease-out);
}
.auth-input-password { padding-right: 2.85rem; }
.auth-input:focus { background-color: var(--surface); border-color: var(--rm-accent); box-shadow: 0 0 0 3px var(--rm-accent-tint); }
.auth-input:focus + .input-icon { color: var(--rm-accent); }
.auth-input.is-invalid { border-color: var(--sys-red); }
.auth-grid { margin-bottom: 1.5rem; text-align: left; }
.auth-grid .form-label { display: block; font-size: 0.8rem; }
.auth-card .form-control, .auth-card .form-select { padding-top: 0.8rem; padding-bottom: 0.8rem; font-size: 0.9rem; font-weight: 600; background-color: var(--bs-body-bg); border-color: var(--border-light); }
.auth-card .form-control.is-invalid, .auth-card .form-select.is-invalid { border-color: var(--sys-red); }
.password-toggle-btn { position: absolute; right: 1.25rem; display: flex; align-items: center; padding: 0; border: 0; background: none; color: var(--text-muted); font-size: 1.1rem; cursor: pointer; transition: color 0.2s; }
.auth-options { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.75rem; font-size: 0.825rem; }
.forgot-password-link { color: var(--rm-accent); font-weight: 600; }
.auth-divider { display: flex; align-items: center; margin: 1.75rem 0; color: var(--text-muted); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; text-align: center; opacity: 0.6; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; border-bottom: 1px solid var(--border-light); }
.auth-divider:not(:empty)::before { margin-right: 0.75rem; }
.auth-divider:not(:empty)::after { margin-left: 0.75rem; }
.auth-footer-text { margin-bottom: 0; text-align: center; font-size: 0.85rem; font-weight: 600; color: var(--text-muted); }
.auth-footer-text a { color: var(--rm-accent); font-weight: 700; }
.auth-card .btn.w-100 { border-radius: var(--radius-lg); font-weight: 700; box-shadow: var(--shadow-sm); }
.auth-card .btn-primary.w-100 { padding: 0.85rem; border: 0; font-size: 0.95rem; }
.auth-card .btn-light.w-100 { padding: 0.7rem; font-size: 0.85rem; font-weight: 600; --bs-btn-bg: var(--surface); --bs-btn-border-color: var(--border-light); --bs-btn-color: var(--text-main); --bs-btn-hover-bg: var(--bs-body-bg); --bs-btn-hover-color: var(--text-main); }
.auth-card .btn-light.w-100 i { font-size: 1.1rem; }
.auth-card details summary { cursor: pointer; list-style: none; }
.auth-card details summary::-webkit-details-marker { display: none; }
@media (hover: hover) and (pointer: fine) {
    .password-toggle-btn:hover { color: var(--rm-accent); }
    .forgot-password-link:hover, .auth-footer-text a:hover { color: var(--rm-accent-strong); text-decoration: underline; }
    .auth-card .btn-primary.w-100:hover { transform: translateY(-1px); box-shadow: 0 4px 12px var(--rm-accent-tint); }
}

/* ---------- Passwortregeln ---------- */
.pw-rules { display: flex; flex-wrap: wrap; gap: 0.25rem 1rem; margin: 0.5rem 0 0; padding: 0; list-style: none; color: var(--text-muted); font-size: 0.85rem; }
.pw-rules li { display: inline-flex; align-items: center; gap: 0.35rem; }
.pw-rules li.ok { color: var(--sys-green); }
.pw-rules[hidden] { display: none; }
.pw-tools { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.5rem; }
.pw-tools[hidden] { display: none; }

/* ---------- Seitenleiste und Kopfzeile (Kundenbereich, Admin) ---------- */
.sidebar-wrapper {
    --sidebar-pad: 1.5rem;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1030;
    display: flex;
    flex-direction: column;
    width: var(--sidebar-width);
    height: 100vh;
    padding: 2rem var(--sidebar-pad);
    background-color: var(--surface);
    border-right: 1px solid var(--border-light);
    transition: transform 300ms var(--ease-drawer), width 300ms var(--ease-drawer), padding 300ms var(--ease-drawer);
}
.sidebar-wrapper > .flex-grow-1 { flex: 1 1 0; min-height: 0; margin-inline-start: calc(-1 * var(--sidebar-pad)); padding-inline-start: var(--sidebar-pad); }
.sidebar-brand { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 2.5rem; padding-left: 0.25rem; color: var(--rm-primary); font-size: 1.35rem; font-weight: 700; transition: color 0.25s ease; }
.brand-mark { display: block; height: 2.5rem; width: auto; flex-shrink: 0; object-fit: contain; }
.sidebar-brand .brand-mark { height: 2.6rem; width: auto; }
.sidebar-brand span { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.15; font-size: 1.2rem; white-space: nowrap; }
.sidebar-brand .brand-tag { margin: 0.2rem 0 0; }
.sidebar-menu-section { margin-bottom: 1.75rem; }
.sidebar-menu-title { margin-bottom: 0.75rem; padding-left: 0.75rem; color: var(--text-muted); font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.6; }
.sidebar-menu-list { margin: 0; padding: 0; list-style: none; }
.sidebar-menu-item { margin-bottom: 0.35rem; }
.sidebar-menu-link { position: relative; display: flex; align-items: center; gap: 0.85rem; padding: 0.75rem 0.85rem; border-radius: var(--radius-md); color: var(--text-muted); font-size: 0.95rem; font-weight: 500; transition: color 160ms var(--ease-out), background-color 160ms var(--ease-out); }
.sidebar-menu-link i { font-size: 1.15rem; transition: color 0.2s ease; }
.sidebar-menu-link.active { font-weight: 600; color: var(--rm-accent-dark); background-color: var(--rm-accent-dim); }
.sidebar-menu-link.active i { color: var(--rm-accent); }
.sidebar-menu-link.active::before { content: ''; position: absolute; left: calc(-1 * var(--sidebar-pad)); top: 15%; width: 4px; height: 70%; border-radius: 0 4px 4px 0; background-color: var(--rm-accent); }
.sidebar-menu-badge { margin-left: auto; padding: 0.15rem 0.5rem; border-radius: 999px; background-color: var(--rm-accent); color: #fff; font-size: 0.75rem; font-weight: 700; }
.sidebar-profile { display: flex; align-items: center; gap: 0.75rem; margin-top: auto; padding: 0.85rem; border: 1px solid var(--border-light); border-radius: var(--radius-xl); background-color: var(--rm-primary-dim); color: var(--rm-primary); }
.sidebar-profile-icon { display: flex; align-items: center; justify-content: center; flex-shrink: 0; width: 42px; height: 42px; border-radius: var(--radius-lg); background-color: var(--rm-accent-dim); color: var(--rm-accent); font-size: 1.35rem; }
.sidebar-profile-info { flex-grow: 1; min-width: 0; }
.sidebar-profile-name { margin-bottom: 0.1rem; font-size: 0.875rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-profile-email { font-size: 0.75rem; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; opacity: 0.8; }
.sidebar-footer { margin-top: 0.75rem; padding-top: 0.75rem; border-top: 1px solid var(--border-light); color: var(--text-muted); text-align: center; font-size: 0.8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-dense { --sidebar-pad: 1.25rem; padding: 1.5rem var(--sidebar-pad); }
.sidebar-dense .sidebar-brand { margin-bottom: 1rem; }
.sidebar-dense .sidebar-menu-section { margin-bottom: 0.75rem; }
.sidebar-dense .sidebar-menu-title { margin-bottom: 0.4rem; }
.sidebar-dense .sidebar-menu-item { margin-bottom: 0.1rem; }
.sidebar-dense .sidebar-menu-link { padding-top: 0.42rem; padding-bottom: 0.42rem; }
.sidebar-section-toggle { display: flex; align-items: center; justify-content: space-between; width: 100%; padding-right: 0; padding-left: 0; border: 0; background: none; text-align: left; cursor: pointer; }
.sidebar-section-toggle .bi { font-size: 0.65rem; transition: transform 200ms var(--ease-out); }
.sidebar-menu-section.collapsed .sidebar-section-toggle .bi { transform: rotate(-90deg); }
.sidebar-section-body { display: grid; grid-template-rows: 1fr; }
.sidebar-ready .sidebar-section-body { transition: grid-template-rows 200ms var(--ease-out); }
.sidebar-section-body > ul { overflow: hidden; min-height: 0; }
.sidebar-menu-section.collapsed .sidebar-section-body { grid-template-rows: 0fr; }
body.sidebar-minimized { --sidebar-width: 80px; }
body.sidebar-minimized .sidebar-wrapper { --sidebar-pad: 0.75rem; padding: 2rem var(--sidebar-pad); align-items: center; }
body.sidebar-minimized .sidebar-brand span,
body.sidebar-minimized .sidebar-menu-title,
body.sidebar-minimized .sidebar-menu-link span,
body.sidebar-minimized .sidebar-menu-badge,
body.sidebar-minimized .sidebar-profile-info,
body.sidebar-minimized .sidebar-footer { display: none; }
body.sidebar-minimized .sidebar-brand { width: 100%; justify-content: center; padding-left: 0; }
body.sidebar-minimized .sidebar-menu-link { justify-content: center; padding: 0.75rem; }
body.sidebar-minimized .sidebar-menu-link i { font-size: 1.35rem; }
body.sidebar-minimized .sidebar-profile { justify-content: center; padding: 0.5rem; border: 0; background-color: transparent; }
.sidebar-overlay { position: fixed; top: 0; left: 0; z-index: 1025; width: 100vw; height: 100vh; background-color: rgb(var(--ink) / 0.4); backdrop-filter: blur(4px); opacity: 0; visibility: hidden; transition: opacity 0.25s ease, visibility 0.25s ease; }
.sidebar-overlay.show { opacity: 1; visibility: visible; }

.main-wrapper { display: flex; flex-direction: column; min-height: 100vh; margin-left: var(--sidebar-width); padding: 2rem 2.5rem; transition: margin-left 300ms var(--ease-drawer); }
.main-wrapper > .page-header, .main-wrapper > main { width: 100%; max-width: 1480px; }
.navbar-custom {
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    margin: -2rem -2.5rem 2rem;
    padding: 1.25rem 2.5rem;
    border-bottom: 1px solid var(--navbar-border);
    background-color: var(--navbar-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}
.navbar-left { display: flex; align-items: center; gap: 0.75rem; min-width: 0; }
.navbar-actions { display: flex; align-items: center; justify-content: flex-end; gap: 0.75rem; flex-shrink: 0; }
.navbar-actions .dropdown-toggle::after { display: none; }
.navbar-actions form { margin: 0; }
.btn-desktop-toggle, .sidebar-toggle-btn { width: 42px; height: 42px; border: 1px solid var(--border-light); border-radius: var(--radius-lg); background-color: var(--surface); color: var(--text-main); box-shadow: var(--shadow-sm); cursor: pointer; transition: color 160ms var(--ease-out), background-color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.btn-desktop-toggle:active, .sidebar-toggle-btn:active { transform: scale(0.97); }
.sidebar-toggle-btn { display: none; align-items: center; justify-content: center; font-size: 1.2rem; }
.crumbs { display: flex; align-items: center; gap: 0.5rem; min-width: 0; margin-left: 0.5rem; color: var(--text-muted); font-size: 0.85rem; }
.crumbs a { color: inherit; }
.crumbs .sep { font-size: 0.7rem; opacity: 0.6; }
.crumbs .current { color: var(--text-main); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.navbar-profile-btn { display: flex; align-items: center; gap: 0.65rem; padding: 0.25rem 0; border: 0; border-radius: var(--radius-lg); background: transparent; cursor: pointer; transition: background-color 160ms var(--ease-out); }
.navbar-profile-btn:focus { outline: none; }
.navbar-profile-btn.dropdown-toggle::after { display: none; }
.navbar-profile-img { width: 38px; height: 38px; border-radius: var(--radius-lg); object-fit: cover; transition: border-color 0.2s; }
.navbar-profile-name { font-size: 0.875rem; font-weight: 700; color: var(--text-main); transition: color 0.2s; }
.navbar-profile-caret { font-size: 0.75rem; color: var(--text-muted); transition: transform 0.2s, color 0.2s; }
.navbar-profile-btn[aria-expanded="true"] .navbar-profile-caret { transform: rotate(180deg); }
.avatar-initial { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--brand-deep), var(--brand-deep-2)); color: #fff; font-size: 0.95rem; font-weight: 700; }
@keyframes dropdownFadeIn { from { opacity: 0; } to { opacity: 1; } }
.admin-search { position: relative; flex: 1 1 18rem; max-width: 34rem; margin: 0 1rem; }
.admin-search > .bi { position: absolute; left: 0.9rem; top: 50%; transform: translateY(-50%); color: var(--text-muted); pointer-events: none; }
.admin-search-input { width: 100%; padding: 0.55rem 0.9rem 0.55rem 2.4rem; border: 1px solid var(--border-light); border-radius: 999px; background: var(--card-background); color: var(--text-main); font: inherit; font-size: 0.9rem; transition: border-color 160ms var(--ease-out), box-shadow 160ms var(--ease-out); }
.admin-search-input:focus { outline: none; border-color: var(--rm-accent); box-shadow: 0 0 0 3px var(--rm-accent-tint); }
.admin-search-results { position: absolute; left: 0; right: 0; top: calc(100% + 0.4rem); z-index: 1050; max-height: 70vh; overflow: auto; padding: 0.35rem; border: 1px solid var(--border-light); border-radius: var(--radius-xl); background: var(--card-background); box-shadow: var(--shadow-lg); transform-origin: top center; animation: dropdownFadeIn 160ms var(--ease-out); }
.admin-search-group { padding: 0.5rem 0.75rem 0.2rem; color: var(--text-muted); font-size: 0.7rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.admin-search-results a { display: flex; flex-direction: column; padding: 0.45rem 0.75rem; border-radius: var(--radius-md); color: inherit; text-decoration: none; }
.admin-search-results a small { color: var(--text-muted); }
.admin-search-results a.active { background: var(--rm-accent-dim); }
@media (hover: hover) and (pointer: fine) { .admin-search-results a:hover { background: var(--rm-primary-dim); } }
.admin-search-empty { padding: 0.75rem; color: var(--text-muted); }
@media (max-width: 767.98px) { .admin-search { display: none; } }
.dropdown-menu-profile { width: 248px; margin-top: 0.5rem !important; padding: 0.5rem 0; border: 0; animation: dropdownFadeIn 180ms var(--ease-out); }
.dropdown-menu-profile .dropdown-item { display: flex; align-items: center; gap: 0.75rem; padding: 0.65rem 1.25rem; font-size: 0.85rem; font-weight: 600; }
.dropdown-menu-profile .dropdown-item i { font-size: 1.05rem; color: var(--text-muted); transition: color 0.2s; }
.dropdown-menu-profile .dropdown-divider { margin: 0.4rem 0; }
.dropdown-profile-head { display: flex; flex-direction: column; gap: 0.2rem; padding: 0.6rem 1.25rem 0.5rem; }
.dropdown-profile-name { font-size: 0.9rem; color: var(--text-main); overflow-wrap: anywhere; }
.dropdown-profile-line { font-size: 0.8rem; color: var(--text-muted); overflow-wrap: anywhere; }
.btn-copy { padding: 0 0.3rem; border: 0; background: none; color: var(--text-muted); font-size: 0.95em; cursor: pointer; transition: color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.btn-copy:active { transform: scale(0.92); }
@media (hover: hover) and (pointer: fine) { .btn-copy:hover { color: var(--rm-accent-dark); } }
.alert-bell { position: relative; margin-right: 0.5rem; }
.alert-bell-button { position: relative; }
.alert-bell-menu { width: 22rem; max-width: 92vw; margin-top: 0.5rem; padding: 0.25rem 0; }
.alert-bell-head { display: flex; align-items: center; justify-content: space-between; padding: 0.5rem 1rem; border-bottom: 1px solid var(--border-light); }
.alert-bell-empty { padding: 1rem; color: var(--text-muted); }
@media (hover: hover) and (pointer: fine) {
    .btn-desktop-toggle:hover { background-color: var(--border-light); color: var(--rm-accent); }
    .crumbs a:hover { color: var(--text-main); }
    .navbar-profile-btn:hover { background-color: var(--bs-body-bg); }
    .navbar-profile-btn:hover .navbar-profile-name, .navbar-profile-btn:hover .navbar-profile-caret { color: var(--rm-accent); }
    .dropdown-menu-profile .dropdown-item:hover i { color: var(--rm-accent); }
    .sidebar-menu-link:not(.active):hover { color: var(--text-main); background-color: var(--rm-primary-dim); }
    .sidebar-brand:hover { color: var(--rm-primary); }
    .page-back:hover { color: var(--text-main); }
    .footer-link:hover { color: var(--rm-primary); }
}
@media (prefers-reduced-transparency: reduce) { .navbar-custom { backdrop-filter: none; -webkit-backdrop-filter: none; background-color: var(--bs-body-bg); } }

.page-header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; }
.page-title { margin-bottom: 0.25rem; font-size: 1.75rem; color: var(--rm-primary); }
.page-subtitle { margin-bottom: 0; font-size: 0.875rem; color: var(--text-muted); text-wrap: pretty; }
.page-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.page-back { display: inline-flex; align-items: center; gap: 0.4rem; margin-bottom: 0.4rem; color: var(--text-muted); font-size: 0.82rem; font-weight: 600; }

.footer-custom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; margin-top: auto; padding-top: 1.25rem; border-top: 1px solid rgb(var(--ink) / 0.06); color: var(--text-muted); font-size: 0.85rem; }
.footer-left { display: flex; flex-wrap: wrap; align-items: center; gap: 0.25rem 1rem; }
.footer-copy { display: flex; align-items: center; gap: 0.35rem; }
.footer-heart { display: inline-block; color: var(--rm-accent); font-size: 0.75rem; animation: heartBeat 1.5s ease infinite; }
.footer-right { display: flex; align-items: center; }
.footer-links { display: flex; align-items: center; gap: 1.5rem; margin: 0; padding: 0; list-style: none; }
.footer-link { color: var(--text-muted); font-weight: 600; transition: color 0.25s ease-in-out; }
@keyframes heartBeat { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.2); } }

@media (max-width: 1199.98px) {
    .sidebar-wrapper { transform: translateX(-100%); }
    .sidebar-wrapper.show { transform: translateX(0); box-shadow: var(--shadow-lg); }
    .main-wrapper { margin-left: 0; padding: 1.5rem; }
    .sidebar-toggle-btn { display: flex; }
    .navbar-custom { flex-wrap: wrap; gap: 0.75rem; margin: -1.5rem -1.5rem 1.5rem; padding: 1rem 1.5rem; }
}
@media (max-width: 767.98px) {
    .page-header { flex-direction: column; align-items: stretch; gap: 1rem; }
    .footer-custom { flex-direction: column; align-items: center; margin-top: 1.5rem; gap: 1rem; text-align: center; }
    .footer-left { flex-direction: column; align-items: center; justify-content: center; gap: 0.5rem; }
    .footer-links { flex-wrap: wrap; justify-content: center; gap: 1rem; }
}

/* ---------- Abschnitte und Formularraster ---------- */
.section { margin-bottom: 1.5rem; border: 1px solid var(--border-light); border-radius: var(--radius-xxl); background: var(--surface); box-shadow: var(--shadow-sm); }
.set-row { display: grid; grid-template-columns: minmax(0, 280px) minmax(0, 1fr); gap: 1rem 3rem; padding: 1.6rem 1.5rem; border-bottom: 1px solid var(--border-light); }
.set-row:last-child { border-bottom: 0; }
.set-info h3 { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin: 0 0 0.35rem; font-size: 0.98rem; font-weight: 700; color: var(--rm-primary); }
.set-info p { margin: 0 0 0.5rem; color: var(--text-muted); font-size: 0.84rem; line-height: 1.5; }
.set-info p:last-child { margin-bottom: 0; }
.set-body { min-width: 0; max-width: 680px; }
.section-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem 1.5rem; padding: 1.15rem 1.5rem; border-bottom: 1px solid var(--border-light); }
.section-head > div:first-child { flex: 1 1 320px; min-width: 0; }
.section-head h2, .section-head h3 { margin: 0; font-size: 1.05rem; font-weight: 700; }
.section-head p { margin: 0.2rem 0 0; color: var(--text-muted); font-size: 0.85rem; font-weight: 500; }
.page-header, .section-head { text-align: start; }
.section-head h2, .section-head h3, .section-head p, .modal-header .modal-title, .modal-header p, .set-info h3, .set-info p { text-align: start; text-wrap: wrap; }
.section-body.c-stack:not(:has(*)) { display: none; }
.section-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 0.75rem; padding: 1rem 1.5rem; border-top: 1px solid var(--border-light); border-radius: 0 0 var(--radius-xxl) var(--radius-xxl); background: var(--surface-2); }
.section-foot-stack { flex-direction: column; align-items: stretch; }
.section-foot-stack .btn { justify-content: center; width: 100%; }
.set-row:has(+ .section-foot) { border-bottom: 0; }
.vps-tabs { display: flex; flex-wrap: wrap; gap: 0.25rem; margin: 1.5rem 0 0; padding: 1rem 0 0; list-style: none; border-top: 1px solid var(--border-light); }
.vps-tabs a { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.5rem 1rem; border-radius: 999px; color: var(--text-muted); font-size: 0.875rem; font-weight: 600; text-decoration: none; }
.vps-tabs a.active { background: var(--tab-active); color: #fff; }
.profile-tabs { margin: 0 0 1.5rem; padding: 0; border-top: 0; }
@media (hover: hover) and (pointer: fine) { .vps-tabs a:not(.active):hover { background: var(--surface-hover); color: var(--text-main); } }
/* Auf dem Handy eine Zeile zum Wischen statt mehrerer Zeilen; app.js holt den aktiven Reiter ins Bild */
@media (max-width: 767.98px) {
    .vps-tabs { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 0.25rem; scrollbar-width: thin; }
    .vps-tabs li { flex: none; }
    .vps-tabs a { white-space: nowrap; }
}
.section-body { padding: 1.5rem; }
.section-danger { border-color: var(--alert-danger-border); }
.set-row-danger .set-info h3 { color: var(--sys-red); }
/* Unsichtbare Spaltentitel (visually-hidden) bleiben im seitlich scrollenden Rahmen, statt die Seite zu verbreitern */
.table-responsive { position: relative; }
.section > .table-responsive:last-child { border-radius: 0 0 var(--radius-xxl) var(--radius-xxl); }
.section > .table-responsive:first-child { border-radius: var(--radius-xxl); }
.section > .section-head:last-child { border-bottom: 0; }
.section > .pager { margin: 0; padding: 1rem 1.5rem; border-top: 1px solid var(--border-light); }
.section .table-custom th:first-child, .section .table-custom td:first-child { padding-left: 1.5rem; }
.section .table-custom th:last-child, .section .table-custom td:last-child { padding-right: 1.5rem; }

/* ---------- Admin: Werkzeugleiste, Filter, Tabellen, Seitenumbruch ---------- */
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem; margin-bottom: 1rem; }
/* Mindestbreite für Suchfeld und Knopf nebeneinander; reicht der Platz nicht, rückt das Formular als Ganzes in die nächste Zeile */
.table-tools { display: flex; flex-wrap: wrap; gap: 0.5rem; flex: 1 1 400px; margin-bottom: 1rem; }
.toolbar .table-tools { margin-bottom: 0; }
.table-tools .list-search { flex: 1 1 260px; max-width: 420px; }
.filter-bar { display: flex; flex-wrap: wrap; gap: 0.75rem 2rem; padding: 0.85rem 1.5rem; border-bottom: 1px solid var(--border-light); }
.filter-tabs { display: inline-flex; flex-wrap: wrap; gap: 0.2rem; padding: 0.25rem; border: 1px solid var(--border-light); border-radius: 999px; background: var(--surface); }
.filter-tabs a { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.35rem 0.9rem; border-radius: 999px; color: var(--text-muted); font-size: 0.82rem; font-weight: 600; text-decoration: none; transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out); }
.filter-tabs a.active { background: var(--tab-active); color: #fff; }
.table-custom { width: 100%; margin-bottom: 0; border-collapse: collapse; vertical-align: middle; }
.table-custom th, .table-custom td { padding: 1rem 0.85rem; border-bottom: 1px solid rgb(var(--ink) / 0.05); white-space: nowrap; }
.table-custom th { background-color: var(--surface-2); color: var(--text-muted); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; border-bottom: 1px solid rgb(var(--ink) / 0.08); }
.table-custom td { font-variant-numeric: tabular-nums; }
.table-custom tbody tr { transition: background-color 0.2s ease-in-out; }
.table-custom tbody tr:last-child td { border-bottom: 0; }
.table-custom tbody tr.row-link { cursor: pointer; }
.table-order-id { font-weight: 700; color: var(--text-main); }
.table-product-name { font-weight: 600; color: var(--text-main); }
.table-amount { font-weight: 700; color: var(--text-main); }
.cell-sub { display: block; color: var(--text-muted); font-size: 0.8rem; font-weight: 500; }
.empty-row td { padding: 2.5rem 1rem; text-align: center; color: var(--text-muted); white-space: normal; }
.sort-link { color: inherit; text-decoration: none; white-space: nowrap; }
.sort-link i { font-size: 0.7rem; opacity: 0.4; transition: opacity 160ms var(--ease-out); }
.sort-link.active i { opacity: 1; color: var(--rm-accent); }
.pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0.4rem; margin: 1rem 0 1.5rem; }
.pager-info { margin-right: 0.75rem; color: var(--text-muted); font-size: 0.85rem; }
.pager-gap { padding: 0 0.15rem; color: var(--text-muted); }
@media (hover: hover) and (pointer: fine) {
    .table-custom tbody tr:hover { background-color: rgb(var(--ink) / 0.03); }
    .table-custom tbody tr.row-link:hover { background-color: rgb(var(--ink) / 0.04); }
    .filter-tabs a:not(.active):hover { background: var(--surface-hover); color: var(--text-main); }
    .sort-link:hover i { opacity: 1; }
    .icon-btn:hover { background: var(--surface-hover); color: var(--text-main); }
    .option-advanced summary:hover { color: var(--text-main); }
}

/* ---------- Admin: Akte mit Kopf, zwei Spalten, Notizen ---------- */
.vps-head { margin-bottom: 1.5rem; }
.vps-title { margin: 0; font-size: 1.5rem; word-break: break-word; }
.head-main { flex: 1 1 320px; }
.spec-line { display: flex; flex-wrap: wrap; gap: 1.25rem; margin-top: 0.5rem; color: var(--text-muted); font-size: 0.875rem; }
.spec-line + .spec-line { margin-top: 0.35rem; }
.spec-line i { margin-right: 0.35rem; }
.layout-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 380px); gap: 1.5rem; align-items: start; margin-bottom: 1.5rem; }
.layout-split > * { min-width: 0; }
.layout-split > .section { margin-bottom: 0; }
.layout-split > * > :last-child { margin-bottom: 0; }
.layout-aside-first > :first-child { grid-column: 2; grid-row: 1; }
.layout-aside-first > :last-child { grid-column: 1; grid-row: 1; }
@media (min-width: 1200px) {
    .layout-split:not(.layout-split-even) .set-row { grid-template-columns: minmax(0, 230px) minmax(0, 1fr); gap: 1rem 2rem; }
}
/* In halber Breite steht die Beschreibung über dem Feld */
.layout-split-even .set-row { grid-template-columns: minmax(0, 1fr); gap: 1rem; }
.btn-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1rem; }
.inline-form { display: inline; }
.admin-note { padding: 0.85rem 0; border-top: 1px solid var(--border-light); }
.admin-note:first-child { padding-top: 0; border-top: 0; }
.admin-note-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; margin-bottom: 0.25rem; color: var(--text-muted); font-size: 0.82rem; }
.admin-note-body { white-space: pre-wrap; word-break: break-word; }
.note-form { margin-top: 0.5rem; padding-top: 1.25rem; border-top: 1px solid var(--border-light); }
.note-form-foot { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 0.75rem; }
.modal-lg { --bs-modal-width: 720px; }

/* ---------- Support-Zugang ---------- */
.impersonation-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0.5rem 0.75rem; margin: -2rem -2.5rem 0; padding: 0.6rem 2.5rem; background: var(--sys-warning); color: #fff; font-size: 0.9rem; font-weight: 600; }
.impersonation-bar + .navbar-custom { margin-top: 0; }
.impersonation-bar form { margin: 0; }

/* ---------- Admin: Einstellungen ---------- */
.settings-group { margin: 0; padding: 1.25rem 1.5rem 0.5rem; color: var(--text-muted); font-size: 0.78rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }
.settings-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 0.25rem; padding: 0 1rem 0.75rem; }
.settings-grid:last-child { padding-bottom: 1.25rem; }
.settings-tile { display: flex; align-items: center; gap: 0.9rem; padding: 0.7rem 0.6rem; border-radius: var(--radius-md); color: var(--text-main); text-decoration: none; }
.settings-tile > i { flex: 0 0 2rem; color: var(--text-muted); font-size: 1.25rem; text-align: center; }
.settings-tile > span { display: flex; flex-direction: column; min-width: 0; }
.settings-tile small { color: var(--text-muted); }
a.settings-tile:hover, a.settings-tile:focus-visible { background: var(--bs-body-bg); color: var(--text-main); }
.options-form .set-row { border-bottom: 0; }
.options-head { margin-bottom: 1.25rem; }
.set-body-wide { max-width: none; }
.option-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 1.1rem 1.25rem; }
.option-field { grid-column: span 12; min-width: 0; }
.option-field.w-4 { grid-column: span 4; }
.option-field.w-6 { grid-column: span 6; }
.option-label { margin-bottom: 0.35rem; }
.option-label-row { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.35rem; }
.option-label-row .option-label { margin-bottom: 0; }
.option-help { margin: 0.35rem 0 0; color: var(--text-muted); font-size: 0.78rem; line-height: 1.45; }
.secret-row { display: flex; align-items: stretch; gap: 0.5rem; }
.secret-row .form-control { flex: 1; min-width: 0; }
.icon-btn { flex: none; display: inline-grid; place-items: center; width: 2.6rem; border: 1px solid var(--input-border); border-radius: var(--radius-md); background: var(--surface); color: var(--text-muted); transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.icon-btn:active { transform: scale(0.97); }
.icon-btn[aria-pressed="true"] { color: var(--rm-accent-dark); background: var(--surface-hover); }
.option-clear { display: inline-flex; align-items: center; gap: 0.45rem; margin-top: 0.45rem; color: var(--text-muted); font-size: 0.78rem; cursor: pointer; }
.option-advanced { margin-top: 1.25rem; padding-top: 0.9rem; border-top: 1px dashed var(--border-light); }
.option-advanced summary { display: inline-flex; align-items: center; gap: 0.4rem; margin-bottom: 0.9rem; color: var(--text-muted); font-size: 0.85rem; font-weight: 600; cursor: pointer; list-style: none; }
.option-advanced summary::-webkit-details-marker { display: none; }
.option-advanced summary i { font-size: 0.7rem; transition: transform 160ms var(--ease-out); }
.option-advanced[open] summary i { transform: rotate(90deg); }
.options-foot { display: flex; align-items: center; justify-content: flex-end; gap: 1rem; padding: 1rem 1.5rem; border-top: 1px solid var(--border-light); }
.options-form .options-foot { margin: 0; background: var(--surface-2); border-radius: 0 0 var(--radius-xxl) var(--radius-xxl); }
.options-form .btn-primary:disabled { opacity: 0.45; cursor: default; }
.options-form:target { scroll-margin-top: calc(var(--navbar-height) + 1rem); }
.option-field :target { scroll-margin-top: calc(var(--navbar-height) + 3rem); }
.options-dirty { display: inline-flex; align-items: center; gap: 0.45rem; margin-right: auto; color: var(--text-muted); font-size: 0.8rem; opacity: 0; transform: translateY(2px); transition: opacity 160ms var(--ease-out), transform 160ms var(--ease-out); pointer-events: none; }
.options-dirty i { color: var(--sys-warning); font-size: 0.4rem; }
.options-form[data-dirty] .options-dirty { opacity: 1; transform: none; }
.c-intro { max-width: 860px; margin-bottom: 1.25rem; }
.c-split-status .options-form .set-row { grid-template-columns: 1fr; gap: 1rem; }
.c-stack { display: grid; gap: 1.1rem; }
.c-facts { display: grid; gap: 0.75rem; margin: 0; }
.c-facts dt { color: var(--text-muted); font-size: 0.75rem; font-weight: 600; }
.c-facts dd { margin: 0.1rem 0 0; font-size: 0.875rem; }
.c-btn-stack { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.c-btn-stack form { margin: 0; }
.c-flush { margin: 0; }
.c-block { padding-top: 1.1rem; border-top: 1px solid var(--border-light); }
.c-block-title { margin: 0 0 0.5rem; color: var(--text-muted); font-size: 0.72rem; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase; }
.c-detail { min-width: 180px; overflow-wrap: anywhere; line-height: 1.5; }
.c-detail-narrow { min-width: 150px; }
.c-job-detail { min-width: 220px; max-width: 460px; }
.c-job-detail summary { cursor: pointer; color: var(--text-muted); font-size: 0.82rem; font-weight: 600; }
.c-job-detail .log-box { word-break: normal; overflow-wrap: anywhere; }
.cause { overflow-wrap: anywhere; }
/* Tabellen mit mehreren Knöpfen je Zeile: bei wenig Platz stehen sie untereinander, so passt die Tabelle ab 1280 px ohne seitliches Scrollen */
.table-wrap-actions .row-actions { flex-wrap: wrap; }
.c-head-text { flex: 1 1 420px; max-width: 760px; }
.field-hint { margin: 0.4rem 0 0; color: var(--text-muted); font-size: 0.8rem; line-height: 1.45; }
.section-head-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.section-head-actions form { margin: 0; }
.row-actions { display: flex; align-items: center; justify-content: flex-end; gap: 0.35rem; }
.row-actions form { margin: 0; }
.row-actions-start { justify-content: flex-start; flex-wrap: wrap; margin-top: 0.5rem; }
.table-custom td.wrap { white-space: normal; overflow-wrap: anywhere; }
:where(.table-custom td.wrap) { min-width: 11rem; }

/* ---------- Admin: Angebot und Infrastruktur ---------- */
.modal-xl { --bs-modal-width: 960px; }
.btn-reason { color: var(--text-muted); font-size: 0.85rem; }
.plans-table .badge-state { margin-left: 0.25rem; }
.table-form td { vertical-align: middle; white-space: normal; }
.table-form td > .form-control, .table-form .input-unit .form-control { min-width: 6.5rem; }
.table-form output { display: inline-block; min-width: 2rem; font-variant-numeric: tabular-nums; }
.input-unit { display: flex; align-items: center; gap: 0.5rem; }
.input-unit .form-control { min-width: 5rem; }
.input-unit small { white-space: nowrap; }
.os-name { display: inline-flex; align-items: center; gap: 0.5rem; }
.os-name img { flex: none; padding: 0.15rem; border-radius: var(--radius-md); background: #fff; }
.term-prices { display: grid; grid-template-columns: auto 1fr; gap: 0.25rem 0.75rem; margin: 0.75rem 0 0; font-size: 0.84rem; }
.term-prices dt { color: var(--text-muted); font-weight: 600; }
.term-prices dd { margin: 0; color: var(--text-main); font-weight: 600; font-variant-numeric: tabular-nums; }
.term-prices small { color: var(--text-muted); font-weight: 500; }
.modal-body .form-grid .form-check .invalid-feedback { display: block; }

/* ---------- Admin: Nodes, IP-Pools, Bestandsabgleich ---------- */
.badge-state { white-space: nowrap; }
.badge-state:not(.success, .pending, .failed, .info) { background-color: var(--surface-hover); color: var(--text-muted); }
.cell-badges { display: grid; justify-items: start; gap: 0.35rem; }
.cell-meter { min-width: 9rem; }
.cell-meter > span { display: block; margin-bottom: 0.35rem; font-size: 0.82rem; }
.progress { --bs-progress-height: 10px; --bs-progress-bg: var(--bs-body-bg); --bs-progress-border-radius: 999px; }
.progress .progress-bar { width: 0; border-radius: 999px; background: var(--rm-accent); transition: width 0.6s ease; }
.progress .progress-bar.warn { background: var(--sys-warning); }
.progress .progress-bar.crit { background: var(--sys-red); }
.channel-links { display: flex; flex-wrap: wrap; gap: 0.4rem 1.25rem; margin-bottom: 1rem; font-size: 0.85rem; }
.channel-links a { color: var(--text-main); text-decoration: underline; text-decoration-style: dotted; text-underline-offset: 3px; }
.channel-links a.active { font-weight: 700; text-decoration: none; }
.channel-links a:hover { text-decoration-style: solid; }
.stat-label { margin-bottom: 0.75rem; color: var(--text-muted); font-size: 0.875rem; font-weight: 500; }
.stat-label i { margin-right: 0.35rem; color: var(--rm-accent); }
.stat-value { margin-bottom: 0.75rem; color: var(--rm-primary); font-size: clamp(1.4rem, 1.2vw + 0.9rem, 2rem); font-weight: 800; line-height: 1.1; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pool-summary { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.25rem 2rem; }
.pool-stats { display: flex; flex-wrap: wrap; gap: 1rem 3rem; }
.pool-meta { justify-content: flex-start; gap: 0.5rem 1.75rem; color: var(--text-muted); font-size: 0.85rem; }
.pool-meta strong { margin-left: 0.25rem; color: var(--text-main); font-weight: 600; }
.bulk-bar { align-items: center; gap: 0.5rem 0.75rem; }
.bulk-bar[hidden] { display: none; }
.bulk-bar .form-control { flex: 0 1 16rem; }
.c-check { width: 1%; }
.list-select { flex: 0 1 12rem; width: auto; max-width: 14rem; }
.toolbar-end { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin-left: auto; }
/* Der Hinweis bricht um, bevor die Knöpfe einzeln umbrechen */
.section-foot .foot-note { flex: 1 1 15rem; margin-right: auto; color: var(--text-muted); font-size: 0.82rem; }
.section-foot .c-foot-start { margin-right: auto; }
/* Auswahlkästchen im Fuß eines Formulars, etwa „Nur interne Notiz“: Kästchen und Text nebeneinander wie in der Vorlage */
.section-foot .form-check.foot-note { display: flex; align-items: center; gap: 0.5rem; min-height: 1.5rem; margin-bottom: 0; padding-left: 0; }
.section-foot .form-check.foot-note .form-check-input { flex: none; float: none; margin: 0; }
.finding + .finding { border-top: 1px solid var(--border-light); }
.finding > .section-head { border-bottom: 0; }
.finding > .table-responsive { border-top: 1px solid var(--border-light); }
.finding:last-child > .table-responsive:last-child { border-radius: 0 0 var(--radius-xxl) var(--radius-xxl); }
.finding-note { margin: 0; padding: 0.9rem 1.5rem; border-top: 1px solid var(--border-light); color: var(--text-muted); font-size: 0.82rem; }
.modal-body > .alert { margin-bottom: 1.25rem; }

/* ---------- Guthaben und Zahlungen ---------- */
.layout-split-deposit { grid-template-columns: minmax(0, 440px) minmax(0, 1fr); }
.balance-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.4rem 1.5rem; border-bottom: 1px solid var(--border-light); border-radius: var(--radius-xxl) var(--radius-xxl) 0 0; background: var(--surface-2); }
.balance-head .stat-label { margin-bottom: 0.35rem; }
.balance-head .stat-value { margin-bottom: 0; }
.balance-icon { display: grid; place-items: center; flex: none; width: 3rem; height: 3rem; border-radius: var(--radius-lg); background: var(--rm-accent-dim); color: var(--rm-accent); font-size: 1.35rem; }
.flow-step + .flow-step { margin-top: 1.5rem; padding-top: 1.5rem; border-top: 1px solid var(--border-light); }
.flow-step h3 { display: flex; align-items: center; margin: 0 0 0.9rem; font-size: 0.98rem; font-weight: 700; }
.step-num { display: inline-grid; place-items: center; flex: none; width: 1.6rem; height: 1.6rem; margin-right: 0.35rem; border-radius: 50%; background: var(--rm-accent-dim); color: var(--rm-accent); font-size: 0.8rem; font-weight: 800; vertical-align: 0.08em; }
.quick-amounts { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.75rem; }
.quick-amounts a { padding: 0.35rem 0.9rem; border: 1px solid var(--border-light); border-radius: 999px; background: var(--surface); color: var(--text-main); font-size: 0.82rem; font-weight: 600; transition: background-color 160ms var(--ease-out), border-color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.quick-amounts a.active { border-color: var(--tab-active); background: var(--rm-accent-dim); color: var(--tab-active); }
.quick-amounts a:active { transform: scale(0.97); }
.choice-list > :last-child { margin-bottom: 0; }
.gateway-option { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 0.5rem; padding: 0.75rem 1rem; border: 2px solid var(--border-light); border-radius: var(--radius-xl); font-weight: 600; cursor: pointer; }
.gateway-option:has(input:checked) { border-color: var(--rm-accent); background: var(--rm-accent-tint); }
.gateway-option .form-check-input { flex: none; border-radius: 50%; }
.term-row { display: flex; align-items: center; gap: 1rem; margin-bottom: 0.75rem; padding: 1rem 1.25rem; border: 2px solid var(--border-light); border-radius: var(--radius-xl); cursor: pointer; }
.term-row:has(input:checked) { border-color: var(--rm-accent); background: var(--rm-accent-tint); }
.term-row .form-check-input { flex: none; margin: 0; border-radius: 50%; }
.term-row .term-price { margin-left: auto; text-align: right; font-weight: 700; white-space: nowrap; }
.term-row .term-price small { display: block; color: var(--text-muted); font-weight: 400; }
.term-row .term-price small.checkout-saving { color: var(--alert-success-text); white-space: normal; }
.term-row.term-disabled { opacity: 0.55; cursor: not-allowed; }
.amount-in { color: var(--sys-green); font-weight: 600; }
.amount-out { color: var(--sys-red); font-weight: 600; }
.section-note { padding: 1rem 1.5rem; border-bottom: 1px solid var(--border-light); }
.section-note > :last-child { margin-bottom: 0; }
.section-note .table-tools { margin-bottom: 0; }
.cell-action { margin-top: 0.5rem; }
.table-custom th.th-wrap { white-space: normal; }
.btn-wrap { white-space: normal; text-align: start; }
.table-tight th, .table-tight td { padding-left: 0.6rem; padding-right: 0.6rem; }
.table-custom td.cell-mail, .table-custom td.cell-name { min-width: 0; white-space: normal; }
/* Lange Adressen ohne Bindestrich brechen notfalls im Wort um, statt die Tabelle zu verbreitern */
.table-custom td.cell-mail { min-width: 6rem; overflow-wrap: anywhere; }
.cell-action form { margin: 0; }
.head-figure { text-align: right; }
.head-figure .stat-value { margin-bottom: 0; line-height: 1.1; }
.stat-link { display: block; height: 100%; color: inherit; }
.stat-link .card { height: 100%; margin-bottom: 0; transition: transform 160ms var(--ease-out), box-shadow 160ms var(--ease-out); }
.stat-link:active .card { transform: scale(0.99); }
.stat-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.stat-head i { color: var(--rm-accent); font-size: 1.15rem; }
.method-list { display: grid; gap: 0.6rem; margin: 0; padding: 0; list-style: none; }
.method-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 0.9rem; padding: 0.75rem 1rem; border: 1px solid var(--border-light); border-radius: var(--radius-xl); background: var(--surface); transition: border-color 160ms var(--ease-out), background-color 160ms var(--ease-out), opacity 160ms var(--ease-out); }
.method-row.is-off { opacity: 0.6; }
.method-row .method-icon { flex: none; display: grid; place-items: center; width: 2.2rem; height: 2.2rem; border-radius: var(--radius-md); background: var(--surface-2); color: var(--rm-accent-dark); font-size: 1.05rem; }
.method-row .method-body { flex: 1 1 10rem; min-width: 0; }
.method-row .method-name { font-size: 0.9rem; font-weight: 700; }
.method-row .method-hint { color: var(--text-muted); font-size: 0.78rem; }
.method-move { display: flex; gap: 0.25rem; margin-left: auto; }
.method-row.is-moved { animation: method-settle 260ms var(--ease-out); }
@keyframes method-settle { from { background-color: var(--surface-hover); transform: translateY(-3px); } to { background-color: var(--surface); transform: none; } }
.option-switch { display: inline-flex; align-items: center; gap: 0.75rem; font-size: 0.9rem; font-weight: 600; cursor: pointer; user-select: none; transition: transform 160ms var(--ease-out); }
.option-switch:active { transform: scale(0.98); }
.option-switch input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.option-switch-track { position: relative; flex: none; width: 2.5rem; height: 1.45rem; border-radius: 999px; background: var(--border-light); box-shadow: inset 0 0 0 1px rgb(var(--ink) / 0.08); transition: background-color 180ms var(--ease-out); }
.option-switch-track::after { content: ''; position: absolute; top: 0.2rem; left: 0.2rem; width: 1.05rem; height: 1.05rem; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgb(0 0 0 / 0.25); transition: transform 180ms var(--ease-out); }
.option-switch input:checked + .option-switch-track { background: var(--rm-accent); }
.option-switch input:checked + .option-switch-track::after { transform: translateX(1.05rem); }
.option-switch input:focus-visible + .option-switch-track { outline: 2px solid var(--rm-accent); outline-offset: 2px; }
.copy-field { display: flex; align-items: stretch; gap: 0.4rem; }
.copy-field input { flex: 1; min-width: 0; font-size: 0.78rem; }
.input-unit { position: relative; }
.input-unit .form-control { padding-right: 2.25rem; }
.input-unit > span { position: absolute; top: 50%; right: 0.9rem; transform: translateY(-50%); color: var(--text-muted); font-size: 0.85rem; pointer-events: none; }
@media (hover: hover) and (pointer: fine) {
    .quick-amounts a:not(.active):hover { border-color: var(--rm-accent); background: var(--surface-hover); }
    .stat-link:hover .card { transform: translateY(-2px); box-shadow: var(--shadow-md); }
    .method-row:hover { border-color: rgb(var(--ink) / 0.18); }
}
@media (max-width: 1399.98px) {
    .layout-split-deposit { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 767.98px) {
    .head-figure { text-align: left; }
    .section-note, .balance-head { padding-left: 1.1rem; padding-right: 1.1rem; }
}
@media (prefers-reduced-motion: reduce) {
    .quick-amounts a, .method-row, .option-switch, .option-switch-track, .option-switch-track::after, .stat-link .card { transition: none; }
    .method-row.is-moved { animation: none; }
}

/* ---------- Admin: Glocke und Benachrichtigungen ---------- */
.alert-bell-count { position: absolute; top: -0.45rem; right: -0.45rem; display: grid; place-items: center; min-width: 1.2rem; height: 1.2rem; padding: 0 0.3rem; border-radius: 999px; background: var(--rm-accent); color: #fff; font-size: 0.68rem; font-weight: 700; }
.alert-bell-item { margin: 0; }
.alert-bell-item button { display: grid; grid-template-columns: auto 1fr auto; gap: 0.5rem; align-items: baseline; width: 100%; padding: 0.55rem 1rem; border: 0; background: none; color: inherit; text-align: left; cursor: pointer; transition: background-color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.alert-bell-item button:active { transform: scale(0.99); }
.alert-bell-item.unread button { font-weight: 600; }
.alert-bell-item small { color: var(--text-muted); font-weight: 400; }
.alert-bell-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.alert-dot { display: inline-block; width: 0.6rem; height: 0.6rem; border-radius: 50%; background: var(--text-muted); }
.alert-dot-info { background: var(--sys-blue); }
.alert-dot-warning { background: var(--sys-warning); }
.alert-dot-danger { background: var(--sys-red); }
.alert-row-unread td:first-child { box-shadow: inset 3px 0 0 var(--rm-accent); }
.alert-body { margin-top: 0.2rem; }
@media (hover: hover) and (pointer: fine) { .alert-bell-item button:hover { background: var(--rm-primary-dim); } }
.form-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1rem 1.25rem; align-items: start; }
.form-grid > * { grid-column: span 6; min-width: 0; }
.form-grid > .f-1 { grid-column: span 1; }
.form-grid > .f-2 { grid-column: span 2; }
.form-grid > .f-3 { grid-column: span 3; }
.form-grid > .f-4 { grid-column: span 4; }
/* Felder nebeneinander, solange jedes mindestens 10rem breit ist, sonst untereinander */
.form-grid.form-grid-auto { grid-template-columns: repeat(auto-fit, minmax(min(10rem, 100%), 1fr)); }
.form-grid.form-grid-auto > * { grid-column: auto; }
.form-grid > .pw-rules, .form-grid > .pw-tools { margin-top: -0.5rem; }
.field-inline { display: flex; align-items: flex-start; gap: 0.5rem; }
.field-inline > :first-child { flex: 1 1 auto; min-width: 0; }
.field-inline > .btn { flex-shrink: 0; }
/* Wird das Feld neben dem Knopf schmaler als 12rem, rückt der Knopf darunter */
.field-inline:has(> .btn) { flex-wrap: wrap; }
.field-inline:has(> .btn) > :first-child { flex-basis: 12rem; }
.field-inline-narrow { max-width: 340px; }
.action-list { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.action-list > li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem 1.5rem; padding: 1rem 0; border-bottom: 1px solid var(--border-light); }
.action-list > li:first-child { padding-top: 0; }
.action-list > li:last-child { padding-bottom: 0; border-bottom: 0; }
.action-list strong { display: block; }
.action-list small { display: block; color: var(--text-muted); font-size: 0.82rem; line-height: 1.45; }
.action-list .action-text { flex: 1 1 260px; min-width: 0; }
.action-list form { margin: 0; }
.action-form { display: flex; flex: 1 1 320px; flex-wrap: wrap; align-items: flex-end; justify-content: flex-end; gap: 0.5rem; margin: 0; }
.action-form > div:not(.action-text) { flex: 1 1 150px; min-width: 0; }
.action-form-wide { flex-basis: 100%; align-items: center; justify-content: space-between; gap: 0.75rem 1.5rem; }
.action-form-wide:has(.form-label) { align-items: flex-end; }
.action-form .form-check-label { font-weight: 600; }
@media (max-width: 767.98px) { .action-form { justify-content: flex-start; } }
@media (max-width: 575.98px) {
    .action-form > div:not(.action-text), .field-inline:has(> .btn) > :first-child { flex-basis: 100%; }
}
.kv { display: grid; grid-template-columns: minmax(min-content, 40%) minmax(0, 1fr); margin: 0; }
.kv dt, .kv dd { margin: 0; padding: 0.65rem 0; border-bottom: 1px solid var(--border-light); }
.kv dt { padding-right: 1rem; color: var(--text-muted); font-weight: 500; }
.kv dd { font-weight: 600; overflow-wrap: anywhere; }
.kv > :nth-last-child(-n+2) { border-bottom: 0; }
.twofa-steps { display: grid; gap: 1.5rem; margin: 0; padding: 0; list-style: none; counter-reset: twofa; }
.twofa-steps > li { position: relative; padding-left: 2.4rem; counter-increment: twofa; }
.twofa-steps > li::before { content: counter(twofa); position: absolute; top: -0.1rem; left: 0; display: grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--rm-accent-dim); color: var(--rm-accent); font-size: 0.8rem; font-weight: 800; }
.twofa-steps p { margin: 0 0 0.9rem; }
.twofa-secret { display: flex; flex-wrap: wrap; align-items: center; gap: 1.5rem; }
.twofa-account { margin-top: 0.6rem; font-size: 0.85rem; }
.twofa-account dt, .twofa-account dd { padding: 0.35rem 0; }
.qr-box { width: 180px; height: 180px; padding: 4px; border: 1px solid var(--border-light); border-radius: var(--radius-md); background: #fff; }
.qr-box svg { display: block; width: 100%; height: 100%; }
.recovery-codes { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 0.25rem 1rem; margin-top: 0.75rem; font-size: 0.9rem; }
@media (max-width: 1199.98px) {
    .set-row { grid-template-columns: 1fr; gap: 1rem; }
    .layout-split { grid-template-columns: minmax(0, 1fr); }
    .layout-aside-first > :first-child, .layout-aside-first > :last-child { grid-column: 1; grid-row: auto; }
    .impersonation-bar { margin: -1.5rem -1.5rem 0; padding-inline: 1.5rem; }
}
@media (max-width: 767.98px) {
    .form-grid > .f-1, .form-grid > .f-2, .form-grid > .f-3, .form-grid > .f-4 { grid-column: span 6; }
    .toolbar-end { margin-left: 0; }
    .section-head, .section-foot, .section-body, .set-row { padding-left: 1.1rem; padding-right: 1.1rem; }
    .option-field.w-4, .option-field.w-6 { grid-column: span 12; }
}

/* Rechtstexte: Anzeige, Scrollkasten im Kundenbereich, Editor im Admin */
.legal-text { overflow-wrap: anywhere; }
.legal-text > :first-child { margin-top: 0; }
.legal-text p { margin-bottom: 0.9rem; line-height: 1.65; }
.legal-text h2, .legal-text h3 { margin: 1.5rem 0 0.6rem; font-size: 1.05rem; font-weight: 800; }
.legal-text ul, .legal-text ol { margin-bottom: 0.9rem; padding-left: 1.25rem; line-height: 1.65; }
.legal-scroll { max-height: 26rem; overflow-y: auto; border: 1px solid var(--border-light); border-radius: var(--radius-lg); padding: 1rem 1.25rem; background: var(--bs-body-bg); }
.legal-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.5rem 1rem; margin-bottom: 1rem; }
.legal-head h2 { margin: 0; font-size: 1.05rem; font-weight: 700; }
.legal-editor { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.85rem; line-height: 1.5; }
.auth-consent { margin-top: 0.25rem; }

/* Cookie-Hinweis und Einstellungsdialog; der Hinweis reserviert unten Platz, damit er nichts verdeckt, und bleibt unter Modalen (Bootstrap 1050) */
.footer-button { padding: 0; border: 0; background: none; font: inherit; cursor: pointer; }
.footer-button:active { transform: scale(0.97); }
.main-wrapper, .auth-wrapper { margin-bottom: var(--cookie-space, 0px); }
.cookie-banner { position: fixed; left: 1rem; right: 1rem; bottom: 1rem; z-index: 1040; display: flex; flex-wrap: wrap; align-items: center; gap: 1.25rem; max-width: 820px; margin: 0 auto; padding: 1.25rem 1.5rem; border: 1px solid var(--border-light); border-radius: var(--radius-xl); background: var(--surface); box-shadow: var(--shadow-lg); color: var(--text-main); font-size: 0.925rem; transition: opacity 240ms var(--ease-out), transform 240ms var(--ease-out); }
.cookie-banner[hidden] { display: none; }
.cookie-banner > div:first-child { flex: 1 1 320px; min-width: 0; }
.cookie-banner strong { color: var(--rm-primary); }
.cookie-banner strong i { color: var(--rm-accent); }
.cookie-banner p { margin: 0.35rem 0 0; color: var(--text-muted); font-size: 0.85rem; }
.cookie-banner p a { color: var(--rm-accent-dark); font-weight: 600; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-left: auto; }
@starting-style {
    .cookie-banner { opacity: 0; transform: translateY(1rem); }
}
.cookie-dialog .modal-body { color: var(--text-main); font-size: 0.925rem; }
.cookie-category { margin-bottom: 1rem; padding: 1rem 1.25rem; border: 1px solid var(--border-light); border-radius: var(--radius-lg); }
.cookie-category:last-child { margin-bottom: 0; }
.cookie-category-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.cookie-category h3 { margin: 0 0 0.25rem; font-size: 1rem; }
.cookie-category p { margin: 0; color: var(--text-muted); font-size: 0.83rem; }
.cookie-switch { display: inline-flex; align-items: center; gap: 0.5rem; font-weight: 600; white-space: nowrap; cursor: pointer; }
.cookie-switch .form-check-input { margin: 0; cursor: pointer; }
.cookie-always { display: inline-flex; align-items: center; padding: 0.2rem 0.65rem; border-radius: 999px; background: var(--sys-green-bg); color: var(--sys-green); font-size: 0.72rem; font-weight: 700; white-space: nowrap; }
.cookie-table { width: 100%; margin-top: 0.75rem; font-size: 0.78rem; }
.cookie-table th { padding: 0.3rem 0.5rem 0.3rem 0; color: var(--text-muted); font-size: 0.68rem; font-weight: 700; text-align: left; text-transform: uppercase; }
.cookie-table td { padding: 0.4rem 0.5rem 0.4rem 0; border-top: 1px solid var(--border-light); vertical-align: top; }
.cookie-dialog-actions { justify-content: flex-end; gap: 0.5rem; }
.auth-wrapper { flex-direction: column; gap: 1rem; }
.auth-foot { position: relative; z-index: 1; color: var(--text-muted); font-size: 0.85rem; text-align: center; }
.auth-foot .footer-button { color: var(--text-muted); font-weight: 600; }
.sidebar-footer .footer-button { color: var(--text-muted); font-size: 0.78rem; }
@media (max-width: 575.98px) {
    /* Auf dem Telefon nur der Kern: der Hinweis soll die Seite nicht zudecken. Der volle Text steht unter „Einstellungen“. */
    .cookie-banner { left: 0.5rem; right: 0.5rem; bottom: 0.5rem; gap: 0.6rem; padding: 0.75rem 0.9rem; }
    .cookie-banner p { margin-top: 0.15rem; font-size: 0.78rem; line-height: 1.35; }
    .cookie-more { display: none; }
    .cookie-actions { flex-wrap: nowrap; gap: 0.4rem; width: 100%; margin-left: 0; }
    .cookie-actions .btn { flex: 1 1 0; justify-content: center; padding-left: 0.4rem; padding-right: 0.4rem; font-size: 0.74rem; white-space: nowrap; }
}

/* Darstellung umschalten: drei Schalter im Profilmenü und in der Admin-Kopfzeile, im Fuß der Webseite als Aufklappmenü */
.theme-switch { display: flex; gap: 0.25rem; margin: 0.35rem 0.5rem; padding: 0.25rem; border: 1px solid var(--border-light); border-radius: 999px; background: var(--surface-2); }
.theme-switch-bar { margin: 0; }
.theme-option { display: inline-flex; flex: 1; align-items: center; justify-content: center; gap: 0.35rem; padding: 0.35rem 0.5rem; border: 0; border-radius: 999px; background: transparent; color: var(--text-muted); font-size: 0.78rem; font-weight: 600; transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.theme-option span { display: none; }
.theme-option:active { transform: scale(0.97); }
.theme-option.active { background: var(--surface); color: var(--rm-accent-dark); box-shadow: var(--shadow-sm); }
.lang-menu { position: absolute; top: calc(100% + 0.35rem); right: 0; z-index: 30; display: grid; min-width: 8.5rem; padding: 0.3rem; border: 1px solid var(--border-light); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow-lg); }
.lang-menu button { display: block; width: 100%; padding: 0.4rem 0.7rem; border: 0; border-radius: var(--radius-sm); background: none; color: var(--text-main); font: inherit; text-align: left; cursor: pointer; }
.lang-menu button.active { background: var(--rm-primary-dim); font-weight: 700; }

/* Versionshinweis im Fuß des Kundenbereichs */
.footer-version-link { color: inherit; }
.footer-made { display: inline-flex; align-items: center; gap: 0.35rem; white-space: nowrap; color: var(--text-muted); font-size: 0.85rem; }
.footer-gear { display: inline-block; line-height: 1; animation: spin 6s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (hover: hover) and (pointer: fine) {
    .theme-option:hover:not(.active) { color: var(--text-main); }
    .footer-button:hover, .footer-version-link:hover { color: var(--text-main); }
    .footer-version-link:hover { text-decoration: underline; }
}
@media (prefers-reduced-motion: reduce) {
    .theme-option, .cookie-banner { transition: none; }
    .footer-gear { animation: none; }
}

/* ---------- Bestellung: Konfigurator, Kasse und Bestellseiten ---------- */
.stepper { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 1.5rem; padding: 0; list-style: none; }
.stepper li[hidden] { display: none; }
.stepper button { display: inline-flex; align-items: center; gap: 0.6rem; padding: 0.4rem 1rem 0.4rem 0.4rem; border: 1px solid var(--border-light); border-radius: 999px; background: var(--surface); color: var(--text-muted); font-size: 0.875rem; font-weight: 600; transition: background-color 160ms var(--ease-out), border-color 160ms var(--ease-out), color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.stepper button:disabled { opacity: 0.55; cursor: default; }
.stepper button:not(:disabled):active { transform: scale(0.97); }
.stepper-number { display: grid; place-items: center; width: 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--surface-hover); color: var(--text-main); font-size: 0.8rem; transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out); }
.stepper .is-current { border-color: var(--tab-active); color: var(--rm-primary); }
.stepper .is-current .stepper-number { background: var(--tab-active); color: #fff; }
.stepper .is-done .stepper-number { background: var(--sys-green-bg); color: var(--sys-green); }
.cfg-step.section { margin-bottom: 1.5rem; }
.cfg-step.is-active { opacity: 1; transform: translateY(0); transition: opacity 200ms var(--ease-out), transform 200ms var(--ease-out); }
@starting-style { .cfg-step.is-active { opacity: 0; transform: translateY(8px); } }
.cfg-nav { display: flex; justify-content: space-between; gap: 0.75rem; margin-top: 0.5rem; }
.cfg-nav [data-next], .cfg-nav [data-submit] { margin-left: auto; }
.plan-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1.25rem; }
.plan-option { position: relative; display: block; margin: 0; }
.plan-option input { position: absolute; opacity: 0; }
.plan-option-card { display: block; height: 100%; padding: 1.25rem; border: 2px solid var(--border-light); border-radius: var(--radius-xl); cursor: pointer; }
.plan-option input:checked + .plan-option-card { border-color: var(--rm-accent); background: var(--rm-accent-tint); }
.plan-option input:focus-visible + .plan-option-card { outline: 2px solid var(--rm-accent); outline-offset: 2px; }
.plan-option input:disabled + .plan-option-card { opacity: 0.5; cursor: not-allowed; }
.cfg-spec { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.75rem 2.25rem; margin-top: 1.5rem; padding-top: 1.5rem; border-top: 1px solid var(--border-light); }
.cfg-spec[hidden] { display: none; }
.cfg-spec:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.cfg-spec-intro { grid-column: 1 / -1; margin: 0 0 -0.75rem; color: var(--text-muted); font-size: 0.85rem; }
.cfg-field { min-width: 0; }
.cfg-field-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: 0.5rem; cursor: pointer; }
.cfg-name { font-weight: 600; color: var(--text-main); }
.cfg-value { color: var(--rm-primary); font-size: 1.15rem; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cfg-range-text { display: grid; grid-template-columns: auto 1fr auto; align-items: start; gap: 0.75rem; margin-top: 0.35rem; color: var(--text-muted); font-size: 0.75rem; }
.cfg-field.has-steps .cfg-range-text { padding-inline: 2.75rem; }
.cfg-price { color: var(--text-muted); text-align: center; }
.cfg-field > .cfg-price { margin-top: 0.3rem; font-size: 0.8rem; text-align: left; }
.cfg-range { --fill: 0%; display: block; width: 100%; height: 1.5rem; appearance: none; background: transparent; cursor: pointer; }
.cfg-range::-webkit-slider-runnable-track { height: 0.4rem; border-radius: 999px; background: linear-gradient(to right, var(--rm-accent) var(--fill, 0%), var(--border-light) var(--fill, 0%)); }
.cfg-range::-moz-range-track { height: 0.4rem; border-radius: 999px; background: linear-gradient(to right, var(--rm-accent) var(--fill, 0%), var(--border-light) var(--fill, 0%)); }
.cfg-range::-webkit-slider-thumb { -webkit-appearance: none; width: 1.3rem; height: 1.3rem; margin-top: -0.45rem; border: 3px solid var(--rm-accent); border-radius: 50%; background: var(--surface); box-shadow: var(--shadow-sm); transition: transform 160ms var(--ease-out); }
.cfg-range::-moz-range-thumb { width: 1rem; height: 1rem; border: 3px solid var(--rm-accent); border-radius: 50%; background: var(--surface); box-shadow: var(--shadow-sm); transition: transform 160ms var(--ease-out); }
.cfg-range:active::-webkit-slider-thumb { transform: scale(1.12); }
.cfg-range:active::-moz-range-thumb { transform: scale(1.12); }
.cfg-slider { display: flex; align-items: center; gap: 0.5rem; }
.cfg-slider .cfg-range { flex: 1 1 auto; min-width: 0; }
.cfg-step-btn { display: grid; flex: 0 0 auto; place-items: center; width: 2.25rem; height: 2.25rem; border: 1px solid var(--border-light); border-radius: var(--radius-md); background: var(--surface); color: var(--text-main); cursor: pointer; transition: border-color 160ms var(--ease-out), color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.cfg-step-btn[hidden] { display: none; }
.cfg-step-btn:disabled { opacity: 0.45; cursor: not-allowed; }
.cfg-step-btn:not(:disabled):active { transform: scale(0.97); }
.cfg-summary-name { margin-bottom: 0.25rem; color: var(--rm-primary); font-size: 1.1rem; font-weight: 700; }
.side-sticky { position: sticky; top: calc(var(--navbar-height) + 1rem); }
.site .side-sticky { top: 1rem; }
.detail-list { margin: 0; padding: 0; list-style: none; }
.detail-list li { display: flex; justify-content: space-between; gap: 1rem; padding: 0.6rem 0; border-bottom: 1px solid var(--border-light); }
.detail-list li:last-child { border-bottom: 0; }
.detail-list li > span:first-child { color: var(--text-muted); }
.detail-list li > span:last-child { text-align: end; overflow-wrap: anywhere; }
.sum-total { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border-light); }
.sum-total span { color: var(--text-muted); font-size: 0.85rem; font-weight: 600; }
.sum-total strong { color: var(--rm-primary); font-size: 1.6rem; font-weight: 800; line-height: 1.1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.sum-note { margin: 1rem 0; color: var(--text-muted); font-size: 0.85rem; line-height: 1.5; }
.sum-note:last-child { margin-bottom: 0; }
.os-tiles { min-width: 0; margin: 1.25rem 0 0; padding: 0; border: 0; }
.os-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: 0.6rem; }
.os-tile { min-width: 0; margin: 0; padding: 0.8rem; border: 1px solid var(--border-light); border-radius: var(--radius-xl); background: var(--surface); transition: border-color 160ms var(--ease-out), opacity 160ms var(--ease-out); }
.os-tile:has(input:checked) { border-color: var(--rm-accent); background: var(--rm-accent-tint); }
.os-tile.is-off { opacity: 0.6; }
.os-tile-head { display: flex; align-items: center; gap: 0.6rem; float: none; width: auto; margin: 0 0 0.55rem; padding: 0; font-size: 0.95rem; }
.os-tile-head img { flex: none; width: 2rem; height: 2rem; padding: 0.15rem; border-radius: var(--radius-md); background: #fff; }
.os-versions { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.os-version { position: relative; display: inline-flex; flex-direction: column; margin: 0; padding: 0.3rem 0.65rem; border: 1px solid var(--border-light); border-radius: var(--radius-md); font-size: 0.85rem; font-weight: 600; cursor: pointer; transition: border-color 160ms var(--ease-out), background-color 160ms var(--ease-out), color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.os-version input { position: absolute; opacity: 0; pointer-events: none; }
.os-version:has(input:checked) { border-color: var(--rm-accent); background: var(--rm-accent); color: #fff; }
.os-version:has(input:focus-visible) { outline: 2px solid var(--rm-accent); outline-offset: 2px; }
.os-version:has(input:disabled) { border-style: dashed; color: var(--text-muted); cursor: not-allowed; }
.os-version:not(:has(input:disabled)):active { transform: scale(0.97); }
.os-min { font-size: 0.72rem; font-weight: 400; }
.os-min[hidden] { display: none; }
.access-modes { display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: 0.6rem; margin-bottom: 1rem; }
.access-modes .gateway-option { margin-bottom: 0; }
.access-panel[hidden] { display: none; }
.access-panel .field-hint:last-child { margin-bottom: 0; }
.pw-repeat-label { margin-top: 0.9rem; }
.pw-field [data-pw-note] { margin: 0.5rem 0 0; }
.layout-split-even { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.checkout-top { align-items: stretch; }
.checkout-top.layout-split-even { grid-template-columns: minmax(0, 3fr) minmax(0, 5fr); }
.checkout-top .section-head { min-height: 4.3rem; flex-wrap: nowrap; }
.checkout-top .section-head h2 i { margin-right: 0.4rem; color: var(--text-muted); }
.checkout-top .choice-list .gateway-option:last-child { margin-bottom: 0; }
.checkout-top .sum-note { margin-top: 0.9rem; }
.choice-divider { margin: 0.9rem 0 0.6rem; padding-top: 0.9rem; border-top: 1px solid var(--border-light); color: var(--text-muted); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; }
.pay-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: 0.5rem; }
.pay-grid .gateway-option { position: relative; min-width: 0; margin-bottom: 0; padding: 0.55rem 0.6rem; gap: 0.5rem; font-size: 0.86rem; white-space: nowrap; overflow: hidden; }
.pay-grid .gateway-option span { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
/* In den Kacheln trägt der Rahmen die Auswahl; der Knopf bleibt für Tastatur und Vorlesehilfen erhalten, nur unsichtbar */
.pay-grid .gateway-option input { position: absolute; opacity: 0; pointer-events: none; }
.pay-grid .gateway-option:has(input:focus-visible) { outline: 2px solid var(--rm-accent); outline-offset: 2px; }
.pay-grid .gateway-option:has(input:disabled) { opacity: 0.45; }
.checkout-saving { color: var(--alert-success-text); white-space: normal; }
.checkout-term .form-select { min-width: 11rem; }
/* Aktionen untereinander und umbrechende Preiszeilen, damit die Tabelle neben dem Menü ohne seitliches Scrollen Platz hat */
.checkout-table .row-actions { flex-direction: column; align-items: stretch; }
/* Tabellen in der schmalen Spalte neben einer Seitenleiste: umbrechende Zellen dürfen schmaler werden; zweispaltig erst ab 1400 px */
.table-fit td.wrap { min-width: 6rem; }
.table-fit td.c-job-detail { min-width: 220px; }
@media (max-width: 1399.98px) {
    .layout-split-tables { grid-template-columns: minmax(0, 1fr); }
    .layout-split-tables.layout-aside-first > :first-child, .layout-split-tables.layout-aside-first > :last-child { grid-column: 1; grid-row: auto; }
}
.checkout-table .table-amount small { white-space: normal; }
.checkout-sums { margin: 0; padding: 1rem 1.5rem 0; border-top: 1px solid var(--border-light); }
.checkout-sums div { display: flex; justify-content: space-between; gap: 1rem; padding: 0.15rem 0; }
.checkout-sums dt { color: var(--text-muted); font-weight: 400; }
.checkout-sums dd { margin: 0; font-variant-numeric: tabular-nums; }
.checkout-total { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.1rem 1.5rem; border-top: 1px solid var(--border-light); }
.checkout-sums + .checkout-total { border-top: 0; }
.checkout-total small { display: block; margin-top: 0.15rem; color: var(--text-muted); font-weight: 400; }
.checkout-total-sum { font-size: 1.5rem; white-space: nowrap; }
.checkout-submit { justify-content: center; width: 100%; margin-top: 0.5rem; }
.summary-checks { margin-top: 1rem; }
.summary-checks .form-check { display: flex; align-items: flex-start; gap: 0.6rem; padding-left: 0; font-size: 0.85rem; line-height: 1.45; }
.summary-checks .form-check-input { flex: none; float: none; margin: 0.1rem 0 0; }
.summary-checks .form-check-label { font-weight: 500; color: var(--text-main); }
.summary-checks .form-check-label a { color: var(--rm-accent-dark); font-weight: 600; text-decoration: underline; }
.empty-state { padding: 2rem 1rem; color: var(--text-muted); text-align: center; }
.empty-state > i { display: block; margin-bottom: 0.75rem; font-size: 2rem; }
.section > .empty-state { padding: 3rem 1.5rem; }
.order-card { max-width: 44rem; margin: 0 auto 1.5rem; }
.order-card-head { padding: 2rem 1.5rem 1.5rem; border-bottom: 1px solid var(--border-light); text-align: center; }
.order-card-head > i { display: block; margin-bottom: 0.6rem; color: var(--sys-green); font-size: 2.6rem; line-height: 1; }
.order-card-head h2 { margin: 0; font-size: 1.35rem; font-weight: 700; }
.order-card .section-body > p { margin-bottom: 1.2rem; }
.order-card .btn-lg { justify-content: center; width: 100%; margin-top: 1.4rem; }
.order-card .spinner-border { width: 2.4rem; height: 2.4rem; margin-bottom: 0.9rem; color: var(--rm-accent); }
.site .section h2, .site .section h3 { font-family: inherit; line-height: 1.3; }
.site .section-head h2 { font-size: 1.05rem; font-weight: 700; }
.site .cfg-step p, .site .order-card p { color: var(--text-muted); }
@media (hover: hover) and (pointer: fine) {
    .stepper button:not(:disabled):hover { border-color: var(--rm-accent); color: var(--rm-primary); }
    .cfg-step-btn:not(:disabled):hover { border-color: var(--rm-accent); color: var(--rm-primary); }
    .os-version:not(:has(input:disabled)):hover { border-color: var(--rm-accent); }
}
@media (max-width: 1199.98px) {
    .side-sticky { position: static; }
    .layout-split-even, .checkout-top.layout-split-even { grid-template-columns: 1fr; }
}
@media (max-width: 767.98px) {
    .cfg-spec { grid-template-columns: minmax(0, 1fr); }
    .sum-total strong { font-size: 1.35rem; }
}
/* Unter 992 px reicht die Breite nicht für fünf Spalten: die Position steht dann zweispaltig wie in der Vorlage für schmale Bildschirme */
@media (max-width: 991.98px) {
    .checkout-table thead { display: none; }
    .table-custom.checkout-table tbody tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0.15rem 0.75rem; align-items: center; padding: 0.9rem 1.1rem; border-bottom: 1px solid var(--border-light); }
    .table-custom.checkout-table tbody tr:last-child { border-bottom: 0; }
    .section .table-custom.checkout-table tbody td, .section .table-custom.checkout-table tbody td:first-child, .section .table-custom.checkout-table tbody td:last-child { display: block; padding: 0; border: 0; white-space: normal; }
    .table-custom.checkout-table tbody td:nth-child(1) { grid-column: 1; grid-row: 1; margin-bottom: 0.35rem; }
    .table-custom.checkout-table tbody td:nth-child(5) { grid-column: 2; grid-row: 1; align-self: start; }
    .table-custom.checkout-table tbody td:nth-child(2), .table-custom.checkout-table tbody td:nth-child(3) { grid-column: 1; color: var(--text-muted); font-size: 0.85rem; }
    .table-custom.checkout-table tbody td:nth-child(4) { grid-column: 2; grid-row: 2 / span 2; text-align: right; }
}
@media (max-width: 767.98px) {
    /* Schmal untereinander: zweispaltig schieben sich Aktionen und Preis über die Beschreibung */
    .table-custom.checkout-table tbody tr { grid-template-columns: minmax(0, 1fr); }
    .table-custom.checkout-table tbody td:nth-child(n) { grid-column: 1; grid-row: auto; }
    .checkout-table .row-actions { flex-direction: row; flex-wrap: wrap; justify-content: flex-start; margin-top: 0.5rem; }
}
@media (max-width: 575.98px) {
    .checkout-total, .checkout-sums { padding-left: 1.1rem; padding-right: 1.1rem; }
}
@media (prefers-reduced-motion: reduce) {
    .stepper button, .stepper-number, .cfg-step.is-active, .cfg-range::-webkit-slider-thumb, .cfg-range::-moz-range-thumb, .cfg-step-btn, .os-tile, .os-version { transition: none; }
}

/* ---------- Serververwaltung: Kopf, Live-Anzeige, Restlaufzeit ---------- */
.vps-head .spec-line { gap: 0.4rem 1rem; }
.btn-renew {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--btn-success-bg);
    --bs-btn-border-color: var(--btn-success-bg);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--btn-success-hover);
    --bs-btn-hover-border-color: var(--btn-success-hover);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--btn-success-hover);
    --bs-btn-active-border-color: var(--btn-success-hover);
}
.vps-rename { font-size: 1rem; }
.vps-power { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 0.5rem; }
/* Stromknöpfe auf dem Handy als Raster mit zwei Spalten; ein einzelner sichtbarer Knopf nimmt die ganze Breite */
@media (max-width: 575.98px) {
    .vps-actions { flex: 1 1 100%; }
    .vps-power { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-self: stretch; }
    .vps-power .btn { width: 100%; }
    .vps-power:not(:has(> form:not([hidden]) ~ form:not([hidden]))) > form { grid-column: 1 / -1; }
}
.vps-meters > [class*="col"] > .card { margin-bottom: 0; padding: 1.25rem 1.5rem; }
.progress-label-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.15rem 0.75rem; margin-bottom: 0.5rem; font-size: 0.8rem; font-weight: 700; }
.progress-label { color: var(--text-main); white-space: nowrap; }
.progress-value { color: var(--text-muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.vps-meters .progress + .small { display: block; margin-top: 0.6rem; }
.live-state::before { content: ''; display: inline-block; width: 6px; height: 6px; margin-right: 0.35rem; border-radius: 999px; vertical-align: middle; background-color: var(--text-muted); }
.live-state.running::before { background-color: var(--sys-green); }
.live-state.stopped::before { background-color: var(--sys-red); }
.cell-host { max-width: 18rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Unter 1400 px kürzer, damit die Serverlisten ab 1280 px ohne seitliches Scrollen passen; der volle Name steht im Titel */
@media (max-width: 1399.98px) { .cell-host { max-width: 10rem; } }
/* Ausstattung bricht bei wenig Platz nur zwischen den Werten um */
.table-custom td.cell-specs { white-space: normal; }
.cell-specs > span { white-space: nowrap; }
.log-box { margin: 0.5rem 0 0; padding: 0.75rem; max-height: 320px; overflow: auto; border-radius: var(--radius-md); background: var(--surface-2); font-size: 0.75rem; white-space: pre-wrap; word-break: break-all; }
.copy-line { display: flex; align-items: center; gap: 0.5rem; }
.copy-line .log-box { flex: 1; min-width: 0; }
.app-log { max-height: 70vh; font-size: 0.78rem; line-height: 1.5; white-space: pre; word-break: normal; }
.countdown { font-variant-numeric: tabular-nums; white-space: nowrap; }
.table-custom .countdown { white-space: normal; }
.countdown-over { color: var(--sys-red); font-weight: 700; }

/* ---------- VNC-Konsole: Bildschirm, Werkzeugleiste, Tastenmenü ---------- */
.vnc-screen { position: relative; height: 68vh; min-height: 360px; background: #000; border-radius: var(--radius-md); overflow: hidden; }
.vnc-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem 1rem; margin-bottom: 0.75rem; }
.vnc-toolbar-group { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.vnc-toolbar [aria-pressed="true"] { background: var(--rm-accent-tint); border-color: var(--rm-accent); }
.vnc-menu { position: relative; }
.vnc-menu summary { list-style: none; }
.vnc-menu summary::-webkit-details-marker { display: none; }
.vnc-menu-list { position: absolute; z-index: 30; top: calc(100% + 0.35rem); left: 0; display: grid; min-width: 11rem; padding: 0.3rem; border-radius: var(--radius-lg); background: var(--surface); border: 1px solid var(--border-light); box-shadow: var(--shadow-lg); transform-origin: top left; transition: opacity 150ms var(--ease-out), transform 150ms var(--ease-out); }
@starting-style { .vnc-menu[open] .vnc-menu-list { opacity: 0; transform: scale(0.97); } }
.vnc-menu-list button { display: block; width: 100%; padding: 0.4rem 0.7rem; border: 0; border-radius: var(--radius-md); background: none; color: var(--text-main); font: inherit; font-size: 0.85rem; text-align: left; cursor: pointer; }
.vnc-menu-list button:disabled { opacity: 0.5; cursor: not-allowed; }
@media (hover: hover) and (pointer: fine) { .vnc-menu-list button:not(:disabled):hover { background: var(--surface-hover); } }
.vnc-touch-only { display: none; }
@media (hover: none) and (pointer: coarse) { .vnc-touch-only { display: inline-flex; } }
.vnc-keyboard-input { position: fixed; left: 0; bottom: 0; width: 1px; height: 1px; padding: 0; border: 0; opacity: 0; font-size: 16px; pointer-events: none; }
@media (prefers-reduced-motion: reduce) { .vnc-menu-list { transition: none; } }

/* ---------- Tickets: Verlauf, Hilfe beim Erstellen, Liste ---------- */
.ticket-thread { display: flex; flex-direction: column; gap: 1rem; margin-bottom: 1.5rem; }
.ticket-bubble { display: flex; gap: 0.75rem; align-items: flex-start; max-width: min(46rem, 100%); }
.ticket-bubble-mine { flex-direction: row-reverse; align-self: flex-end; }
.ticket-avatar { flex: none; display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 50%; background: var(--rm-primary-dim); color: var(--rm-primary); font-size: 0.78rem; font-weight: 700; }
.ticket-avatar-staff { background: var(--rm-accent-dim); color: var(--rm-accent-dark); }
.ticket-bubble-main { min-width: 0; padding: 0.85rem 1.1rem; border: 1px solid var(--border-light); border-radius: var(--radius-xl); background: var(--card-background); }
.ticket-bubble-mine .ticket-bubble-main { border-color: transparent; background: var(--rm-accent-dim); }
.ticket-bubble-internal .ticket-bubble-main { border: 1px dashed var(--sys-warning); background: var(--alert-warning-bg); }
.ticket-bubble-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 0.6rem; margin-bottom: 0.3rem; font-size: 0.9rem; }
.ticket-role { color: var(--text-muted); font-size: 0.72rem; letter-spacing: 0.04em; text-transform: uppercase; }
.ticket-role-internal { color: var(--sys-warning); font-weight: 700; }
.ticket-when { margin-left: auto; color: var(--text-muted); font-size: 0.78rem; }
.ticket-bubble-text { word-break: break-word; }
.ticket-attachment { display: inline-flex; align-items: center; gap: 0.4rem; margin: 0.6rem 0.5rem 0 0; font-size: 0.85rem; }
.ticket-attachment-image { flex-direction: column; align-items: flex-start; }
.ticket-thumb { display: block; max-width: 240px; max-height: 240px; border: 1px solid var(--border-light); border-radius: var(--radius-md); background: var(--surface); }
.ticket-hint { color: var(--text-muted); font-size: 0.85rem; }
/* Neues Ticket neben Systemstatus und Häufigen Fragen: unter 1400 px steht die Erklärung über den Feldern, sonst werden die Auswahlfelder zu schmal */
@media (max-width: 1399.98px) {
    .layout-split .ticket-form .set-row { grid-template-columns: 1fr; gap: 1rem; }
}
.mail-plain { margin: 0; max-height: 22rem; padding: 1rem; overflow: auto; border: 1px solid var(--border-light); border-radius: var(--radius-xl); background: var(--bs-body-bg); font-family: inherit; font-size: 0.82rem; line-height: 1.55; white-space: pre-wrap; word-break: break-word; }
/* Mail-Vorlagen: Platzhalter zum Einfügen und Vorschau der HTML-Fassung */
.mail-preview { display: block; width: 100%; height: 34rem; border: 1px solid var(--border-light); border-radius: var(--radius-xl); background: #dbe5ea; }
.chip-row { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.placeholder-chip { padding: 0.3rem 0.65rem; border: 1px solid var(--border-light); border-radius: 999px; background: var(--card-background); color: var(--rm-primary); font: 0.78rem/1.2 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; cursor: pointer; transition: background-color 160ms var(--ease-out), border-color 160ms var(--ease-out), transform 160ms var(--ease-out); }
.placeholder-chip:active { transform: scale(0.97); }
.placeholder-chip-action { border-color: var(--rm-accent); color: var(--rm-accent-dark); font-family: var(--bs-body-font-family); }
@media (hover: hover) and (pointer: fine) {
    .placeholder-chip:hover { border-color: var(--rm-accent); background: var(--rm-accent-dim); }
}
.placeholder-group { margin: 0 0 0.5rem; color: var(--text-muted); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.placeholder-list { margin: 0 0 1rem; }
.placeholder-list > div { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 0.6rem; padding: 0.3rem 0; }
.placeholder-list dt { flex: 0 0 auto; }
.placeholder-list dd { flex: 1 1 10rem; margin: 0; color: var(--text-muted); font-size: 0.8rem; }
.c-hint-gap { margin-top: 1rem; }
/* Rundmail: Empfängergruppen; die gewählte Gruppe ist hervorgehoben und zeigt ihre Auswahl */
.c-audiences { display: grid; gap: 0.75rem; }
.c-audience { border: 2px solid var(--border-light); border-radius: var(--radius-xl); transition: border-color 160ms var(--ease-out), background-color 160ms var(--ease-out); }
.c-audience:has(> .c-audience-head input:checked) { border-color: var(--rm-accent); background: var(--rm-accent-tint); }
.c-audience-head { display: flex; align-items: center; gap: 0.85rem; margin: 0; padding: 0.9rem 1.1rem; cursor: pointer; }
.c-audience-head input { flex-shrink: 0; margin-top: 0; }
.c-audience-count { margin-left: auto; color: var(--text-muted); font-size: 0.8rem; white-space: nowrap; }
.c-audience-body { display: none; gap: 0.5rem; padding: 0 1.1rem 1rem; }
.c-audience:has(> .c-audience-head input:checked) > .c-audience-body { display: grid; }
.c-audience-hint { margin: 0; color: var(--text-muted); font-size: 0.8rem; }
.c-audience-node { display: flex; align-items: center; gap: 0.7rem; margin: 0; padding: 0.6rem 0.8rem; border: 1px solid var(--border-light); border-radius: var(--radius-md); background: var(--card-background); cursor: pointer; }
.c-audience-node input { flex-shrink: 0; margin-top: 0; }
.c-audience-node > span:first-of-type { display: flex; flex-direction: column; font-weight: 600; line-height: 1.25; }
.c-audience-node small { color: var(--text-muted); font-weight: 400; }
.ticket-response { display: flex; align-items: center; gap: 0.5rem; margin: 0 0 1rem; color: var(--text-muted); font-size: 0.85rem; }
.ticket-faq { max-width: 30rem; margin: 0 auto 1.25rem; text-align: left; font-size: 0.88rem; }
.ticket-faq p { margin: 0 0 0.4rem; color: var(--text-muted); }
.ticket-faq ul { margin: 0 0 0.5rem; padding-left: 1.1rem; }
.ticket-faq li + li { margin-top: 0.2rem; }
.ticket-faq-all { font-weight: 600; }
.empty-state .ticket-faq-all i { display: inline; margin: 0; font-size: inherit; }
.ticket-help .section-body > .status-notice { flex-wrap: wrap; margin-bottom: 0.75rem; padding: 0.85rem 1rem; }
.ticket-help .section-body > .status-notice:last-child { margin-bottom: 0; }
.ticket-help .status-notice .alert-content { flex: 1 1 0; }
.ticket-help .status-notice-link { flex-basis: 100%; padding-left: 1.9rem; }
.ticket-help-ok { display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem 0.5rem; margin: 0; font-weight: 600; }
.ticket-help-ok > .bi { color: var(--sys-green); }
.ticket-help-ok a { margin-left: auto; font-size: 0.85rem; }
.ticket-help-links { margin: 0; padding: 0; list-style: none; }
.ticket-help-links li + li { border-top: 1px solid var(--border-light); }
.ticket-help-links a { display: flex; align-items: center; gap: 0.75rem; padding: 0.7rem 1.5rem; color: var(--text-main); font-size: 0.88rem; text-decoration: none; transition: background-color 160ms var(--ease-out); }
.ticket-help-links a > span { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.ticket-help-links a > .bi { flex: none; color: var(--text-muted); font-size: 0.8rem; }
.ticket-help-links li:last-child a { border-radius: 0 0 var(--radius-xxl) var(--radius-xxl); }
@media (max-width: 767.98px) {
    .ticket-help .section-head, .ticket-help .section-body { padding-top: 0.85rem; padding-bottom: 0.85rem; }
    .ticket-help .section-head p { display: none; }
}
@media (max-width: 575.98px) {
    .ticket-bubble, .ticket-bubble-mine { max-width: 100%; }
    .ticket-avatar { width: 2rem; height: 2rem; font-size: 0.7rem; }
}

/* Zähler in Reitern und Filtern, Filter nach Art und Abteilung */
.filter-tabs .count, .filter-chips .count { padding: 0 0.4rem; border-radius: 999px; background: rgb(var(--ink) / 0.08); font-size: 0.72rem; font-variant-numeric: tabular-nums; }
.filter-tabs a.active .count { background: rgba(255, 255, 255, 0.25); }
.filter-chips .count { margin-left: 0.35rem; }
.filter-tabs .count-urgent, .filter-chips .count-urgent { background: var(--sys-red); color: #fff; }
.filter-group { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.75rem; }
.filter-label { color: var(--text-muted); font-size: 0.72rem; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase; }
.filter-chips { display: flex; flex-wrap: wrap; gap: 0.3rem; }
.filter-chips a { padding: 0.25rem 0.7rem; border: 1px solid var(--border-light); border-radius: 999px; color: var(--text-muted); font-size: 0.8rem; font-weight: 600; text-decoration: none; transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out), border-color 160ms var(--ease-out); }
.filter-chips a.active { border-color: var(--tab-active); background: var(--rm-accent-dim); color: var(--tab-active); }
.filter-chips a:active { transform: scale(0.97); }

/* Hinweise im Kundenbereich: Glocke, Karten im Dashboard, Statusmeldungen */
.alert-bell-link { display: flex; align-items: flex-start; gap: 0.6rem; padding: 0.6rem 1rem; color: inherit; font-size: 0.88rem; text-decoration: none; transition: background-color 160ms var(--ease-out); }
.alert-bell-link .bi { margin-top: 0.15rem; color: var(--rm-accent); }
.notice-card { color: inherit; text-decoration: none; transition: transform 160ms var(--ease-out); }
.notice-card:active { transform: scale(0.99); }
.status-notice { align-items: flex-start; }
.status-notice .alert-content { display: flex; flex-direction: column; gap: 0.15rem; }
.status-notice-meta { font-size: 0.8rem; opacity: 0.85; }
.status-notice-affected { font-size: 0.8rem; font-weight: 700; }
.status-notice-link { flex: none; color: inherit; font-weight: 600; white-space: nowrap; text-decoration: underline; text-underline-offset: 3px; }
@media (hover: hover) and (pointer: fine) {
    .ticket-help-links a:hover { background: var(--surface-hover); }
    .filter-chips a:not(.active):hover { background: var(--surface-hover); color: var(--text-main); }
    .alert-bell-link:hover { background: var(--rm-primary-dim); }
}
@media (prefers-reduced-motion: reduce) {
    .filter-chips a, .notice-card, .placeholder-chip, .c-audience { transition: none; }
}

/* ---------- Admin-Übersicht: Einrichtung, Listen, Server-Bestand, Einzahlungen; Verlauf der Kundenakte ---------- */
.setup-card { border-left: 4px solid var(--rm-accent); }
.setup-card .card-title i { margin-right: 0.4rem; color: var(--rm-accent); }
.setup-list { margin: 0; padding: 0; list-style: none; }
.setup-list li { display: flex; align-items: center; gap: 1rem; padding: 0.85rem 0; border-top: 1px solid var(--border-light); }
.setup-list li > div { flex: 1; min-width: 0; }
.setup-list small { display: block; margin-top: 0.15rem; color: var(--text-muted); font-size: 0.82rem; }
.setup-dot { flex: none; width: 0.6rem; height: 0.6rem; border: 2px solid var(--rm-accent); border-radius: 50%; }
.list-rows { margin: 0; padding: 0; list-style: none; }
.list-rows li { border-top: 1px solid var(--border-light); }
.list-rows li:first-child { border-top: 0; }
.list-rows a { display: flex; align-items: center; gap: 0.85rem; padding: 0.7rem 0.25rem; border-radius: var(--radius-md); color: inherit; text-decoration: none; transition: background-color 160ms var(--ease-out); }
.list-icon { flex: none; display: grid; place-items: center; width: 2.1rem; height: 2.1rem; border-radius: var(--radius-md); background: var(--surface-hover); color: var(--text-muted); }
.list-icon-warn { background: var(--rm-accent-tint); color: var(--rm-accent-dark); }
.list-icon-alert { background: var(--rm-primary-dim); color: var(--rm-primary); }
.list-label { flex: 1; min-width: 0; overflow: hidden; font-weight: 500; text-overflow: ellipsis; }
.list-label small { display: block; overflow: hidden; color: var(--text-muted); font-size: 0.78rem; font-weight: 400; text-overflow: ellipsis; white-space: nowrap; }
.list-empty { padding: 0.9rem 0.25rem; color: var(--text-muted); font-size: 0.9rem; }
.count-pill { flex: none; min-width: 1.9rem; padding: 0.15rem 0.6rem; border-radius: 999px; background: var(--border-light); color: var(--text-muted); font-size: 0.78rem; font-weight: 700; text-align: center; font-variant-numeric: tabular-nums; }
.count-pill-warn { background: var(--rm-accent); color: #fff; }
.donut-wrap { display: flex; flex-direction: column; align-items: center; gap: 1.25rem; }
.donut { width: 9.5rem; height: 9.5rem; }
.donut-track, .donut-part { fill: none; stroke-width: 14; }
.donut-track { stroke: var(--border-light); }
.donut-part-a { stroke: var(--rm-primary); }
.donut-part-b { stroke: var(--rm-accent); }
.donut-part-c { stroke: var(--chart-c); }
.donut-part-d { stroke: var(--chart-d); }
.donut-part-e { stroke: var(--sys-red); }
.donut-part-f { stroke: var(--sys-warning); }
.donut-total { fill: var(--rm-primary); font-family: inherit; font-size: 22px; font-weight: 800; }
.donut-legend { display: grid; gap: 0.45rem; width: 100%; margin: 0; padding: 0; font-size: 0.875rem; list-style: none; }
.donut-legend li { display: flex; align-items: center; gap: 0.5rem; }
.donut-legend b { margin-left: auto; font-variant-numeric: tabular-nums; }
.chart-swatch { display: inline-block; flex: none; width: 0.75rem; height: 0.75rem; border-radius: 3px; }
.donut-swatch-a { background: var(--rm-primary); }
.donut-swatch-b { background: var(--rm-accent); }
.donut-swatch-c { background: var(--chart-c); }
.donut-swatch-d { background: var(--chart-d); }
.donut-swatch-e { background: var(--sys-red); }
.donut-swatch-f { background: var(--sys-warning); }
.spark { flex: none; width: 7.5rem; height: 2rem; }
.spark-line { fill: none; stroke: var(--rm-accent); stroke-width: 2; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.spark-area { fill: var(--rm-accent); fill-opacity: 0.12; }
.traffic-days { margin-top: 1.5rem; }
.traffic-days .form-legend { margin: 0 0 0.9rem; }
.traffic-chart { display: block; width: 100%; height: 80px; }
.traffic-chart .chart-bar { fill: var(--rm-accent); }
.package-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 0.75rem; }
.package-box { padding: 1rem; border: 1px solid var(--border-light); border-radius: var(--radius-xl); text-align: center; }
.package-size { font-size: 1.25rem; font-weight: 800; }
.package-price { margin-bottom: 0.75rem; color: var(--text-muted); font-weight: 600; }
.set-row-top { border-top: 1px solid var(--border-light); }
.metric-chart { display: block; width: 100%; height: auto; }
.metric-chart .chart-grid { stroke: var(--border-light); stroke-width: 1; }
.metric-chart .chart-label { fill: var(--text-muted); font-family: inherit; font-size: 11px; }
.metric-chart .chart-line { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.metric-chart .chart-line-a { stroke: var(--rm-primary); }
.metric-chart .chart-line-b { stroke: var(--rm-accent); }
.metric-chart .chart-area-a { fill: var(--rm-primary); fill-opacity: 0.1; }
.metric-chart .chart-area-b { fill: var(--rm-accent); fill-opacity: 0.08; }
.metric-chart .chart-dot-a { fill: var(--rm-primary); }
.metric-chart .chart-dot-b { fill: var(--rm-accent); }
.chart-body { overflow-x: auto; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 0.4rem 1.25rem; margin-top: 0.5rem; color: var(--text-muted); font-size: 0.8rem; }
.chart-legend .chart-swatch { margin-right: 0.4rem; vertical-align: -0.05rem; }
.chart-swatch-a { background: var(--rm-primary); }
.chart-swatch-b { background: var(--rm-accent); }
.chart-swatch-c { background: var(--sys-green); }
.metric-chart .chart-bar-a { fill: var(--rm-primary); }
.metric-chart .chart-bar-b { fill: var(--rm-accent); }
.metric-chart .chart-bar-c { fill: var(--sys-green); }
.range-pills { display: inline-flex; flex-wrap: wrap; gap: 0.25rem; padding: 0.25rem; border-radius: var(--radius-lg); background: var(--bs-body-bg); }
.range-pills a { padding: 0.35rem 0.9rem; border-radius: var(--radius-md); color: var(--text-muted); font-size: 0.85rem; font-weight: 600; text-decoration: none; }
.range-pills a.active { background: var(--tab-active); color: #fff; }
.toolbar-count { color: var(--text-muted); font-size: 0.85rem; font-weight: 500; }
@media (max-width: 767.98px) {
    .chart-body > .metric-chart { min-width: 560px; }
}
.trend-badge { display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.785rem; font-weight: 600; white-space: nowrap; }
.trend-up { color: var(--sys-green); }
.trend-down { color: var(--sys-red); }
.timeline-list { margin: 0; padding: 0; list-style: none; }
.timeline-list li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 0.75rem; padding: 0.55rem 0; border-top: 1px solid var(--border-light); }
.timeline-list li:first-child { border-top: 0; }
.timeline-list .bi { color: var(--rm-accent); }
.timeline-when { min-width: 9rem; color: var(--text-muted); font-size: 0.82rem; }
.timeline-text { flex: 1 1 16rem; min-width: 0; word-break: break-word; }
@media (hover: hover) and (pointer: fine) {
    .list-rows a:hover { background: var(--surface-hover); }
}
@media (prefers-reduced-motion: reduce) {
    .list-rows a { transition: none; }
}
