/* =============================================================================
   PsychExpert – Stylesheet
   Zielgruppe: Schießsport-Experten, Behörden-Kontext
   Design: Seriös, professionell, keine verspielten Elemente
   ============================================================================= */

/* -----------------------------------------------------------------------------
   CSS Custom Properties
   ----------------------------------------------------------------------------- */
:root {
    --pe-color-primary:     #1a3a5c;
    --pe-color-primary-lt:  #2a5080;
    --pe-color-accent:      #c8a84b;
    --pe-color-success:     #2e7d32;
    --pe-color-warning:     #e65100;
    --pe-color-info:        #1565c0;
    --pe-color-danger:      #b71c1c;
    --pe-color-neutral:     #546e7a;
    --pe-color-bg:          #f5f6f8;
    --pe-color-bg-card:     #ffffff;
    --pe-color-border:      #d0d5dd;
    --pe-color-text:        #1a1a2e;
    --pe-color-text-muted:  #5a6475;
    --pe-radius:            6px;
    --pe-radius-lg:         10px;

    /* Verrechnungssimulator – Pastellfarben pro Badge-Gruppe */
    --bs-pay-bg:            #dbeafe;   /* Zahlungsort: Blau-Pastell */
    --bs-pay-border:        #93c5fd;
    --bs-pay-text:          #1e40af;
    --bs-pay-bg-online:     #dbeafe;
    --bs-pay-bg-onsite:     #e0e7ff;
    --bs-pay-bg-flexible:   #ede9fe;
    --bs-pay-border-online: #93c5fd;
    --bs-pay-border-onsite: #a5b4fc;
    --bs-pay-border-flex:   #c4b5fd;
    --bs-pay-text-online:   #1e40af;
    --bs-pay-text-onsite:   #3730a3;
    --bs-pay-text-flex:     #5b21b6;

    --bs-book-bg-normal:    #d1fae5;   /* Buchungstyp: Grün-Pastell */
    --bs-book-border-normal:#6ee7b7;
    --bs-book-text-normal:  #065f46;
    --bs-book-bg-within:    #fef9c3;   /* Storno innerhalb: Gelb-Pastell */
    --bs-book-border-within:#fde047;
    --bs-book-text-within:  #713f12;
    --bs-book-bg-outside:   #fee2e2;   /* Storno außerhalb: Rot-Pastell */
    --bs-book-border-outside:#fca5a5;
    --bs-book-text-outside: #7f1d1d;

    --bs-sub-bg:            #f0fdf4;   /* Storno-Untergruppen: Salbei */
    --bs-sub-border:        #bbf7d0;
    --bs-sub-text:          #14532d;
    --pe-shadow:            0 2px 8px rgba(0,0,0,.08);
    --pe-shadow-lg:         0 4px 20px rgba(0,0,0,.12);
    --pe-transition:        .18s ease;
    --pe-font:              -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* -----------------------------------------------------------------------------
   Wrapper
   ----------------------------------------------------------------------------- */
.psychexpert-wrap {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px 40px;
    font-family: var(--pe-font);
    color: var(--pe-color-text);
    font-size: 15px;
    line-height: 1.6;
}

/* -----------------------------------------------------------------------------
   Gutachter-Listing – Liste (Einzeiler)
   ----------------------------------------------------------------------------- */
.psychexpert-listing {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 24px;
}

/* -----------------------------------------------------------------------------
   Gutachter-Einzeiler (.edelweiss-expert-row) – Mobile-first
   ----------------------------------------------------------------------------- */
.edelweiss-expert-row {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    margin-bottom: 8px;
    cursor: pointer;
    background: var(--pe-color-bg-card);
    transition: background var(--pe-transition), box-shadow var(--pe-transition);
    position: relative;
}
.edelweiss-expert-row:hover,
.edelweiss-expert-row:focus {
    background: #f0f4f8;
    box-shadow: var(--pe-shadow);
    outline: 2px solid var(--pe-color-primary);
    outline-offset: 2px;
}

/* Spalten – Mobile: untereinander */
.edelweiss-expert-row__col {
    flex: 1;
    min-width: 0;
}

/* Spalte 1: Bild + Text nebeneinander */
.edelweiss-expert-row__col--info {
    flex: 2;
}
.edelweiss-expert-row__col-inner {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}
.edelweiss-expert-row__text {
    flex: 1;
    min-width: 0;
}

/* Spalte 2: Verfügbarkeit */
.edelweiss-expert-row__col--avail {
    flex: 1;
}

/* Spalte 3: Zahlung + Storno */
.edelweiss-expert-row__col--payment {
    flex: 1;
}

/* Spalte 4: Website – vertikal mittig, etwas größer */
.edelweiss-expert-row__col--website {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.edelweiss-expert-row__image {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid var(--pe-color-border);
}
.edelweiss-expert-row__image--placeholder {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--pe-color-bg);
    border: 1px solid var(--pe-color-border);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.edelweiss-expert-row__name {
    font-weight: 600;
    color: var(--pe-color-primary);
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.edelweiss-expert-row__bio {
    font-size: 0.8125rem;
    color: var(--pe-color-text-muted);
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.edelweiss-expert-row__location {
    font-size: 0.875rem;
    color: var(--pe-color-text-muted);
    margin-top: 4px;
}
.edelweiss-expert-row__price {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    color: #2b2b2b;
    background: #dbde38;
    border-radius: 4px;
    padding: 3px 7px;
    margin-top: 3px;
    margin-bottom: 3px;
}
.edelweiss-expert-row__availability {
    font-size: 0.875rem;
    color: var(--pe-color-success);
}
.edelweiss-expert-row__arrow {
    color: var(--pe-color-text-muted);
    flex-shrink: 0;
    font-size: 1.1rem;
}
.edelweiss-expert-row--no-slots {
}
.edelweiss-expert-row--no-slots:hover,
.edelweiss-expert-row--no-slots:focus {
    background: var(--pe-color-bg-card);
    box-shadow: none;
    outline: none;
}
.edelweiss-expert-row--no-slots .edelweiss-expert-row__availability {
    color: var(--pe-color-success);
}

/* Desktop: 3-Spalten-Layout ab 768px */
@media (min-width: 768px) {
    .edelweiss-expert-row {
        align-items: stretch;
    }
    .edelweiss-expert-row__col {
        display: flex;
        align-items: center;
    }
    .edelweiss-expert-row__col--info {
        flex: 2;
        align-items: flex-start;
    }
    .edelweiss-expert-row__col-inner {
        align-items: flex-start;
    }
    .edelweiss-expert-row__col--avail {
        flex: 1;
        padding: 0 16px;
        border-left: 1px solid var(--pe-color-border);
        flex-direction: column;
        align-items: flex-start;
        justify-content: center;
    }
    .edelweiss-expert-row__col--payment {
        flex: 1;
        padding: 0 16px;
        border-left: 1px solid var(--pe-color-border);
        align-items: flex-start;
        flex-direction: column;
        justify-content: center;
    }
    .edelweiss-expert-row__col--website {
        flex: 0 0 140px;
        padding: 0 8px 0 16px;
        border-left: 1px solid var(--pe-color-border);
        justify-content: center;
    }
}

/* Mobile: Spalten untereinander */
@media (max-width: 767px) {
    .edelweiss-expert-row {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        padding: 10px 12px;
    }
    .edelweiss-expert-row__col--avail,
    .edelweiss-expert-row__col--website {
        border-left: none;
        padding: 0;
    }
    .edelweiss-expert-row__col--website {
        justify-content: flex-start;
    }
    .edelweiss-expert-row__image,
    .edelweiss-expert-row__image--placeholder {
        width: 48px;
        height: 48px;
    }
    .edelweiss-expert-row__name {
        font-size: 0.9375rem;
    }
}

/* -----------------------------------------------------------------------------
   Gutachter-Karte
   ----------------------------------------------------------------------------- */
.psychexpert-card {
    background: var(--pe-color-bg-card);
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius-lg);
    box-shadow: var(--pe-shadow);
    overflow: hidden;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0;
    transition: box-shadow var(--pe-transition), transform var(--pe-transition);
}
.psychexpert-card:hover {
    box-shadow: var(--pe-shadow-lg);
    transform: translateY(-2px);
}

.psychexpert-card__header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 20px 0;
}

.psychexpert-card__avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--pe-color-border);
    flex-shrink: 0;
}
.psychexpert-card__avatar-placeholder {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: var(--pe-color-bg);
    border: 2px solid var(--pe-color-border);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 28px;
    color: var(--pe-color-text-muted);
}

.psychexpert-card__meta {
    flex: 1;
    min-width: 0;
}
.psychexpert-card__name {
    font-size: 15px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin: 0;
    white-space: normal;
    overflow: hidden;
    text-overflow: ellipsis;
}
.psychexpert-card__website {
    font-size: 13px;
    color: var(--pe-color-info);
    text-decoration: none;
    word-break: break-all;
}
.psychexpert-card__website:hover { text-decoration: underline; }

.psychexpert-card__body {
    padding: 12px 16px;
    flex: 1;
    min-width: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 16px;
}
.psychexpert-card__bio {
    display: none;
}

.psychexpert-card__price {
    font-size: 15px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin: 0;
    white-space: nowrap;
}

.psychexpert-card__footer {
    padding: 12px 16px 12px 0;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 16px;
    margin-left: auto;
    flex-shrink: 0;
}

/* Einzeiler-Karte: Profilbild */
.psychexpert-card__image-wrap {
    flex-shrink: 0;
    width: 64px;
    height: 64px;
    overflow: hidden;
}

.psychexpert-card__image {
    width: 64px;
    height: 64px;
    object-fit: cover;
    display: block;
}

/* Mobile-first: auf kleinen Screens gestapelt */
@media (max-width: 599px) {
    .psychexpert-card {
        flex-direction: column;
        align-items: stretch;
    }

    .psychexpert-card__image-wrap {
        width: 100%;
        height: 160px;
    }

    .psychexpert-card__image {
        width: 100%;
        height: 160px;
    }

    .psychexpert-card__body {
        padding: 12px;
    }

    .psychexpert-card__footer {
        padding: 0 12px 12px;
        margin-left: 0;
    }

    .edelweiss-expert-map-section__header {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* -----------------------------------------------------------------------------
   Zahlungsort-Badges
   ----------------------------------------------------------------------------- */
.pe-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .02em;
    white-space: nowrap;
}
.pe-badge--platform {
    background: #e8f5e9;
    color: var(--pe-color-success);
    border: 1px solid #a5d6a7;
}
.pe-badge--onsite {
    background: #fff3e0;
    color: var(--pe-color-warning);
    border: 1px solid #ffcc80;
}
.pe-badge--flexible {
    background: #e3f2fd;
    color: var(--pe-color-info);
    border: 1px solid #90caf9;
}

/* Status-Badges (allgemein) */
.pe-badge--booked    { background: #e3f2fd; color: #1565c0; border: 1px solid #90caf9; }
.pe-badge--paid      { background: #e8f5e9; color: #2e7d32; border: 1px solid #a5d6a7; }
.pe-badge--cancelled { background: #fce4ec; color: #b71c1c; border: 1px solid #ef9a9a; }
.pe-badge--refunded  { background: #f3e5f5; color: #6a1b9a; border: 1px solid #ce93d8; }
.pe-badge--pending   { background: #fff8e1; color: #f57f17; border: 1px solid #ffe082; }
.pe-badge--active    { background: #e8f5e9; color: #2e7d32; border: 1px solid #a5d6a7; }
.pe-badge--suspended { background: #fce4ec; color: #b71c1c; border: 1px solid #ef9a9a; }
.pe-badge--open      { background: #f5f6f8; color: #546e7a; border: 1px solid #cfd8dc; }
.pe-badge--settled   { background: #e8f5e9; color: #2e7d32; border: 1px solid #a5d6a7; }
.pe-badge--invoiced  { background: #e3f2fd; color: #1565c0; border: 1px solid #90caf9; }

/* -----------------------------------------------------------------------------
   Buttons
   ----------------------------------------------------------------------------- */
.pe-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 9px 18px;
    border-radius: var(--pe-radius);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: background var(--pe-transition), box-shadow var(--pe-transition), opacity var(--pe-transition);
    text-decoration: none;
    line-height: 1.4;
    white-space: nowrap;
}
.pe-btn:disabled { opacity: .55; cursor: not-allowed; }

.pe-btn--primary {
    background: var(--pe-color-primary);
    color: #fff;
}
.pe-btn--primary:hover:not(:disabled) { background: var(--pe-color-primary-lt); }

.pe-btn--secondary {
    background: #fff;
    color: var(--pe-color-primary);
    border: 1px solid var(--pe-color-primary);
}
.pe-btn--secondary:hover:not(:disabled) { background: var(--pe-color-bg); }

.pe-btn--success {
    background: var(--pe-color-success);
    color: #fff;
}
.pe-btn--success:hover:not(:disabled) { background: #1b5e20; }

.pe-btn--danger {
    background: var(--pe-color-danger);
    color: #fff;
}
.pe-btn--danger:hover:not(:disabled) { background: #7f0000; }

.pe-btn--sm {
    padding: 5px 12px;
    font-size: 13px;
}
.pe-btn--lg {
    padding: 12px 28px;
    font-size: 16px;
}
.pe-btn--full { width: 100%; }

/* Badge-Button "Als Gutachter registrieren" */
.pe-btn--register-badge {
    background: transparent;
    color: var(--pe-color-text-muted);
    border: 1px solid var(--pe-color-border);
    font-size: 12px;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: 20px;
    opacity: .8;
}
.pe-btn--register-badge:hover { opacity: 1; background: var(--pe-color-bg); }

/* Warteliste-Button */
.pe-btn--waitlist {
    background: #fff8e1;
    color: #f57f17;
    border: 1px solid #ffe082;
    font-size: 13px;
}
.pe-btn--waitlist:hover:not(:disabled) { background: #fff3cd; }

/* -----------------------------------------------------------------------------
   Buchungsformular-Wrapper
   ----------------------------------------------------------------------------- */
.psychexpert-booking-wrap {
    margin-top: 16px;
    border-top: 1px solid var(--pe-color-border);
    padding-top: 16px;
}
.psychexpert-booking-wrap .bookacti-form-wrapper,
.psychexpert-booking-wrap .bookacti_booking_system {
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
}

/* -----------------------------------------------------------------------------
   Teilnehmerdaten-Step (Accordion nach Terminauswahl)
   ----------------------------------------------------------------------------- */
.psychexpert-participants-step {
    display: none;
    margin-top: 16px;
    background: var(--pe-color-bg);
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    padding: 20px;
}
.psychexpert-participants-step.is-visible { display: block; }

.psychexpert-participants-step__title {
    font-size: 15px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin: 0 0 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--pe-color-border);
}

.psychexpert-count-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}
.psychexpert-count-row label {
    font-size: 14px;
    font-weight: 600;
    color: var(--pe-color-text);
}
.psychexpert-count-row select {
    padding: 6px 10px;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    font-size: 14px;
    background: #fff;
}

.psychexpert-participant-block {
    background: #fff;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    padding: 16px;
    margin-bottom: 12px;
}
.psychexpert-participant-block__heading {
    font-size: 13px;
    font-weight: 700;
    color: var(--pe-color-primary);
    text-transform: uppercase;
    letter-spacing: .04em;
    margin: 0 0 12px;
}

/* -----------------------------------------------------------------------------
   Formular-Felder (allgemein)
   ----------------------------------------------------------------------------- */
.pe-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 10px;
}
.pe-form-row--full { grid-template-columns: 1fr; }

.pe-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.pe-field label {
    font-size: 13px;
    font-weight: 600;
    color: var(--pe-color-text);
}
.pe-field label .required { color: var(--pe-color-danger); margin-left: 2px; }

.pe-field input,
.pe-field select,
.pe-field textarea {
    padding: 8px 10px;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    font-size: 14px;
    font-family: var(--pe-font);
    color: var(--pe-color-text);
    background: #fff;
    transition: border-color var(--pe-transition), box-shadow var(--pe-transition);
    width: 100%;
    box-sizing: border-box;
}
.pe-field input:focus,
.pe-field select:focus,
.pe-field textarea:focus {
    outline: none;
    border-color: var(--pe-color-primary);
    box-shadow: 0 0 0 3px rgba(26,58,92,.12);
}
.pe-field textarea { resize: vertical; min-height: 90px; }

.pe-field--error input,
.pe-field--error select,
.pe-field--error textarea { border-color: var(--pe-color-danger); }
.pe-field__error-msg {
    font-size: 12px;
    color: var(--pe-color-danger);
}

/* -----------------------------------------------------------------------------
   Registrierung (Badge + Modal-Form)
   ----------------------------------------------------------------------------- */
.psychexpert-register-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border: 1px solid var(--pe-color-primary);
    border-radius: 999px;
    background: #fff;
    color: var(--pe-color-primary);
    font-family: var(--pe-font);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    transition: all var(--pe-transition);
}

.psychexpert-register-badge:hover,
.psychexpert-register-badge:focus-visible {
    background: var(--pe-color-primary);
    color: #fff;
}

.psychexpert-register-badge:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(26,58,92,.18);
}

.psychexpert-register-badge__icon {
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid currentColor;
    font-size: 14px;
    line-height: 1;
}

.psychexpert-modal[hidden] { display: none !important; }

.psychexpert-modal__intro {
    margin: 0;
    padding: 0 20px 16px;
    font-size: 14px;
    color: var(--pe-color-text-muted);
    line-height: 1.55;
}

.psychexpert-modal__form {
    padding: 0 20px 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.psychexpert-modal__row {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.psychexpert-modal__label {
    font-size: 13px;
    font-weight: 600;
    color: var(--pe-color-text);
}

.psychexpert-modal__label span {
    color: var(--pe-color-danger);
    margin-left: 3px;
}

.psychexpert-modal__input {
    width: 100%;
    height: 32px;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 0 6px;
    font-family: var(--pe-font);
    font-size: 0.8rem;
    color: #333;
    background: #fff;
    box-sizing: border-box;
}

.psychexpert-modal__input:focus {
    outline: none;
    border-color: #aaa;
}

.psychexpert-modal__notice {
    padding: 10px 14px;
    border-radius: var(--pe-radius);
    font-size: 13px;
    margin: 0;
}

.psychexpert-modal__notice--success {
    background: #e8f5e9;
    color: var(--pe-color-success);
    border: 1px solid #a5d6a7;
}

.psychexpert-modal__notice--error {
    background: #fce4ec;
    color: var(--pe-color-danger);
    border: 1px solid #ef9a9a;
}

.psychexpert-modal__actions {
    display: flex;
    justify-content: flex-end;
}

.psychexpert-modal__actions .psychexpert-btn {
    width: 100%;
    justify-content: center;
}

.psychexpert-modal__required-note {
    margin: 0;
    font-size: 12px;
    color: var(--pe-color-text-muted);
}

.psychexpert-modal__required-note span {
    color: var(--pe-color-danger);
}

/* -----------------------------------------------------------------------------
   Tabs (Dashboard + Admin)
   ----------------------------------------------------------------------------- */
.pe-tabs {
    margin-top: 24px;
}
.pe-tabs__nav {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--pe-color-border);
    overflow-x: auto;
    scrollbar-width: none;
}
.pe-tabs__nav::-webkit-scrollbar { display: none; }

.pe-tabs__tab {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    color: var(--pe-color-text-muted);
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    white-space: nowrap;
    transition: color var(--pe-transition), border-color var(--pe-transition);
}
.pe-tabs__tab:hover { color: var(--pe-color-primary); }
.pe-tabs__tab.is-active {
    color: var(--pe-color-primary);
    border-bottom-color: var(--pe-color-primary);
}

.pe-tabs__panel {
    display: none;
    padding: 24px 0;
}
.pe-tabs__panel.is-active { display: block; }

/* -----------------------------------------------------------------------------
   Tabellen
   ----------------------------------------------------------------------------- */
.pe-table-wrap {
    overflow-x: auto;
    border-radius: var(--pe-radius);
    border: 1px solid var(--pe-color-border);
}
.pe-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    background: #fff;
}
.pe-table th {
    background: var(--pe-color-bg);
    color: var(--pe-color-text);
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .04em;
    padding: 10px 14px;
    text-align: left;
    border-bottom: 1px solid var(--pe-color-border);
    white-space: nowrap;
}
.pe-table td {
    padding: 10px 14px;
    border-bottom: 1px solid #f0f2f5;
    vertical-align: middle;
    color: var(--pe-color-text);
}
.pe-table tr:last-child td { border-bottom: none; }
.pe-table tr:hover td { background: #fafbfc; }

.pe-table__actions {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

/* Aufklappbare Teilnehmerdetails */
.pe-table__details-row { display: none; }
.pe-table__details-row.is-open { display: table-row; }
.pe-table__details-cell {
    padding: 12px 14px !important;
    background: #f9fafb;
}
.pe-participants-detail {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 8px;
}
.pe-participant-item {
    background: #fff;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    padding: 10px 12px;
    font-size: 13px;
}
.pe-participant-item strong { display: block; color: var(--pe-color-primary); margin-bottom: 4px; }

/* -----------------------------------------------------------------------------
   Filter-Leiste
   ----------------------------------------------------------------------------- */
.pe-filter-bar {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: flex-end;
    margin-bottom: 16px;
    padding: 14px 16px;
    background: var(--pe-color-bg);
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
}
.pe-filter-bar .pe-field { min-width: 160px; }
.pe-filter-bar .pe-field label { font-size: 12px; }

/* -----------------------------------------------------------------------------
   Karten (Dashboard-Sektionen)
   ----------------------------------------------------------------------------- */
.pe-card {
    background: #fff;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius-lg);
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: var(--pe-shadow);
}
.pe-card__title {
    font-size: 16px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin: 0 0 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--pe-color-border);
}

/* -----------------------------------------------------------------------------
   Toggle-Switch
   ----------------------------------------------------------------------------- */
.pe-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
}
.pe-toggle input[type="checkbox"] { display: none; }
.pe-toggle__track {
    width: 40px;
    height: 22px;
    background: #cfd8dc;
    border-radius: 11px;
    position: relative;
    transition: background var(--pe-transition);
    flex-shrink: 0;
}
.pe-toggle__track::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    background: #fff;
    border-radius: 50%;
    transition: transform var(--pe-transition);
    box-shadow: 0 1px 3px rgba(0,0,0,.2);
}
.pe-toggle input:checked + .pe-toggle__track { background: var(--pe-color-success); }
.pe-toggle input:checked + .pe-toggle__track::after { transform: translateX(18px); }
.pe-toggle__label { font-size: 14px; color: var(--pe-color-text); }

/* -----------------------------------------------------------------------------
   Profilbild-Upload
   ----------------------------------------------------------------------------- */
.pe-avatar-upload {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}
.pe-avatar-upload__preview {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--pe-color-border);
    background: var(--pe-color-bg);
}
.pe-avatar-upload__actions { display: flex; flex-direction: column; gap: 6px; }

/* -----------------------------------------------------------------------------
   Verrechnungsmodul
   ----------------------------------------------------------------------------- */
.pe-provision-row {
    background: #fff;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    padding: 16px;
    margin-bottom: 12px;
}
.pe-provision-row__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}
.pe-provision-row__amount {
    font-size: 18px;
    font-weight: 700;
    color: var(--pe-color-primary);
}
.pe-provision-row__fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 12px;
}
.pe-provision-row__actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.pe-provision-confirmation {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 13px;
    color: var(--pe-color-text-muted);
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid #f0f2f5;
}
.pe-provision-confirmation span { display: flex; align-items: center; gap: 4px; }
.pe-provision-confirmation .confirmed { color: var(--pe-color-success); font-weight: 600; }

/* -----------------------------------------------------------------------------
   E-Mail-Template-Editor
   ----------------------------------------------------------------------------- */
.pe-email-editor {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 20px;
    align-items: start;
}
.pe-email-editor__list {
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    overflow: hidden;
}
.pe-email-editor__list-item {
    display: block;
    width: 100%;
    text-align: left;
    padding: 10px 14px;
    font-size: 13px;
    font-weight: 500;
    color: var(--pe-color-text);
    background: none;
    border: none;
    border-bottom: 1px solid var(--pe-color-border);
    cursor: pointer;
    transition: background var(--pe-transition);
}
.pe-email-editor__list-item:last-child { border-bottom: none; }
.pe-email-editor__list-item:hover { background: var(--pe-color-bg); }
.pe-email-editor__list-item.is-active {
    background: var(--pe-color-primary);
    color: #fff;
}

.pe-email-editor__panel { display: none; }
.pe-email-editor__panel.is-active { display: block; }

.pe-email-editor__panel-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin: 0 0 14px;
}
.pe-email-editor__params {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
}
.pe-param-badge {
    background: #e3f2fd;
    color: #1565c0;
    border: 1px solid #90caf9;
    border-radius: 4px;
    padding: 2px 8px;
    font-size: 12px;
    font-family: monospace;
    cursor: pointer;
    transition: background var(--pe-transition);
}
.pe-param-badge:hover { background: #bbdefb; }

.pe-email-editor__actions {
    display: flex;
    gap: 8px;
    margin-top: 14px;
    flex-wrap: wrap;
}

/* Vorschau-Modal */
.pe-preview-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.6);
    z-index: 99999;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.pe-preview-modal.is-open { display: flex; }
.pe-preview-modal__inner {
    background: #fff;
    border-radius: var(--pe-radius-lg);
    width: 100%;
    max-width: 680px;
    max-height: 85vh;
    overflow-y: auto;
    padding: 24px;
    position: relative;
}
.pe-preview-modal__close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
    color: var(--pe-color-text-muted);
}
.pe-preview-modal__subject {
    font-size: 13px;
    font-weight: 700;
    color: var(--pe-color-text-muted);
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--pe-color-border);
}
.pe-preview-modal__body { font-size: 14px; line-height: 1.7; }

/* -----------------------------------------------------------------------------
   Export-Karten
   ----------------------------------------------------------------------------- */
.pe-export-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
.pe-export-card {
    background: var(--pe-color-bg);
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    padding: 20px;
    text-align: center;
}
.pe-export-card__icon {
    font-size: 36px;
    margin-bottom: 10px;
    display: block;
}
.pe-export-card__title {
    font-size: 15px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin-bottom: 6px;
}
.pe-export-card__desc {
    font-size: 13px;
    color: var(--pe-color-text-muted);
    margin-bottom: 14px;
}

/* -----------------------------------------------------------------------------
   Globale Einstellungen (Admin)
   ----------------------------------------------------------------------------- */
.pe-settings-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
.pe-settings-grid .pe-field input { max-width: 200px; }

/* -----------------------------------------------------------------------------
   Gutachter-Verwaltung (Admin) – Aktions-Spalte
   ----------------------------------------------------------------------------- */
.pe-expert-actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* Inline-Edit-Felder in Tabellen */
.pe-inline-input {
    padding: 5px 8px;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    font-size: 13px;
    width: 90px;
    background: #fff;
}
.pe-inline-input:focus {
    outline: none;
    border-color: var(--pe-color-primary);
    box-shadow: 0 0 0 2px rgba(26,58,92,.1);
}

/* -----------------------------------------------------------------------------
   Feedback / Notices
   ----------------------------------------------------------------------------- */
.pe-notice {
    padding: 10px 14px;
    border-radius: var(--pe-radius);
    font-size: 13px;
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}
.pe-notice--success { background: #e8f5e9; color: var(--pe-color-success); border: 1px solid #a5d6a7; }
.pe-notice--error   { background: #fce4ec; color: var(--pe-color-danger);  border: 1px solid #ef9a9a; }
.pe-notice--info    { background: #e3f2fd; color: var(--pe-color-info);    border: 1px solid #90caf9; }
.pe-notice--warning { background: #fff8e1; color: #f57f17;                 border: 1px solid #ffe082; }

/* Loading-Spinner */
.pe-loading {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(26,58,92,.2);
    border-top-color: var(--pe-color-primary);
    border-radius: 50%;
    animation: pe-spin .7s linear infinite;
    vertical-align: middle;
}
@keyframes pe-spin { to { transform: rotate(360deg); } }

/* -----------------------------------------------------------------------------
   Bewertungen
   ----------------------------------------------------------------------------- */
.psychexpert-card__reviews {
    padding: 14px 20px;
    border-top: 1px solid var(--pe-color-border);
}
.psychexpert-card__reviews-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--pe-color-text-muted);
    text-transform: uppercase;
    letter-spacing: .04em;
    margin-bottom: 8px;
}

/* -----------------------------------------------------------------------------
   Warteliste-Formular
   ----------------------------------------------------------------------------- */
.psychexpert-waitlist-form {
    margin-top: 10px;
    padding: 14px;
    background: #fff8e1;
    border: 1px solid #ffe082;
    border-radius: var(--pe-radius);
}
.psychexpert-waitlist-form__title {
    font-size: 13px;
    font-weight: 700;
    color: #f57f17;
    margin-bottom: 10px;
}

/* =============================================================================
   PsychExpert Admin – BEM-Komponenten (psychexpert-admin__*)
   Zielgruppe: WordPress-Admin-Bereich, manage_options
   ============================================================================= */

/* -----------------------------------------------------------------------------
   Admin-Wrapper & Header
   ----------------------------------------------------------------------------- */
.psychexpert-admin {
    font-family: var(--pe-font);
    color: var(--pe-color-text);
    font-size: 14px;
    line-height: 1.6;
    max-width: 1400px;
}

.psychexpert-admin__header {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--pe-color-border);
}

.psychexpert-admin__title {
    font-size: 22px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin: 0;
}

/* -----------------------------------------------------------------------------
   Tab-Navigation
   ----------------------------------------------------------------------------- */
.psychexpert-admin__tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--pe-color-border);
    margin-bottom: 24px;
    overflow-x: auto;
    scrollbar-width: none;
    flex-wrap: nowrap;
}
.psychexpert-admin__tabs::-webkit-scrollbar { display: none; }

.psychexpert-admin__tab {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    color: var(--pe-color-text-muted);
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    white-space: nowrap;
    transition: color var(--pe-transition), border-color var(--pe-transition);
}
.psychexpert-admin__tab:hover {
    color: var(--pe-color-primary);
}
.psychexpert-admin__tab--active {
    color: var(--pe-color-primary);
    border-bottom-color: var(--pe-color-primary);
}

/* -----------------------------------------------------------------------------
   Tab-Panels
   ----------------------------------------------------------------------------- */
.psychexpert-admin__panel {
    display: none;
}
.psychexpert-admin__panel--active {
    display: block;
}

/* -----------------------------------------------------------------------------
   Toolbar & Filter-Gruppe
   ----------------------------------------------------------------------------- */
.psychexpert-admin__toolbar {
    margin-bottom: 16px;
    padding: 14px 16px;
    background: var(--pe-color-bg);
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
}

.psychexpert-admin__filter-group {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 10px;
}

.psychexpert-admin__filter-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--pe-color-text);
    white-space: nowrap;
}

/* -----------------------------------------------------------------------------
   Dezente Filterleiste (Buchungsübersicht)
   ----------------------------------------------------------------------------- */
.psychexpert-admin__filter-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 12px;
    background: #f9f9f9;
    border-bottom: 1px solid #eee;
    flex-wrap: wrap;
    margin-bottom: 12px;
}

.psychexpert-admin__filter-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.psychexpert-admin__filter-label {
    font-size: 0.78rem;
    color: #888;
    white-space: nowrap;
}

.psychexpert-admin__filter-select,
.psychexpert-admin__filter-input {
    height: 32px;
    font-size: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 0 6px;
    background: #fff;
    color: #333;
    font-family: var(--pe-font);
    box-sizing: border-box;
}

.psychexpert-admin__filter-input[type="date"] {
    width: 150px;
}
.psychexpert-admin__filter-select:focus,
.psychexpert-admin__filter-input:focus {
    outline: none;
    border-color: #aaa;
}

.psychexpert-admin__filter-btn {
    height: 32px;
    font-size: 0.78rem;
    padding: 0 12px;
    border: 1px solid #bbb;
    border-radius: 4px;
    background: #fff;
    color: #555;
    cursor: pointer;
    font-family: var(--pe-font);
    white-space: nowrap;
}
.psychexpert-admin__filter-btn:hover {
    background: #f0f0f0;
}

.psychexpert-admin__btn--primary {
    background: var(--pe-color-primary);
    color: #fff;
    border-color: var(--pe-color-primary);
}
.psychexpert-admin__btn--primary:hover {
    background: var(--pe-color-primary-lt);
    color: #fff;
}

.psychexpert-admin__search-wrap {
    flex-shrink: 0;
}

.psychexpert-admin__search-input {
    height: 32px;
    width: 220px;
    font-size: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 0 8px;
    background: #fff;
    color: #333;
    font-family: var(--pe-font);
    box-sizing: border-box;
}
.psychexpert-admin__search-input:focus {
    border-color: #aaa;
    outline: none;
}

/* -----------------------------------------------------------------------------
   Formular-Elemente
   ----------------------------------------------------------------------------- */
.psychexpert-admin__select,
.psychexpert-admin__input {
    height: 32px;
    padding: 0 6px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.8rem;
    font-family: var(--pe-font);
    color: #333;
    background: #fff;
    box-sizing: border-box;
}
.psychexpert-admin__select:focus,
.psychexpert-admin__input:focus {
    outline: none;
    border-color: #aaa;
}

.psychexpert-admin__input--date {
    min-width: 140px;
}

.psychexpert-admin__textarea {
    min-height: 72px;
    height: auto;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.8rem;
    font-family: var(--pe-font);
    color: #333;
    background: #fff;
    resize: vertical;
    width: 100%;
    box-sizing: border-box;
}
.psychexpert-admin__textarea:focus {
    outline: none;
    border-color: #aaa;
}

/* -----------------------------------------------------------------------------
   Buttons
   ----------------------------------------------------------------------------- */
.psychexpert-admin__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 7px 14px;
    border-radius: var(--pe-radius);
    font-size: 13px;
    font-weight: 600;
    font-family: var(--pe-font);
    cursor: pointer;
    border: 1px solid transparent;
    transition: background var(--pe-transition), border-color var(--pe-transition), opacity var(--pe-transition);
    text-decoration: none;
    line-height: 1.4;
    white-space: nowrap;
}
.psychexpert-admin__btn:disabled { opacity: .5; cursor: not-allowed; }

.psychexpert-admin__btn--primary {
    background: var(--pe-color-primary);
    color: #fff;
    border-color: var(--pe-color-primary);
}
.psychexpert-admin__btn--primary:hover:not(:disabled) {
    background: var(--pe-color-primary-lt);
    border-color: var(--pe-color-primary-lt);
}

.psychexpert-admin__btn--secondary {
    background: #fff;
    color: var(--pe-color-primary);
    border-color: var(--pe-color-primary);
}
.psychexpert-admin__btn--secondary:hover:not(:disabled) {
    background: var(--pe-color-bg);
}

.psychexpert-admin__btn--success {
    background: var(--pe-color-success);
    color: #fff;
    border-color: var(--pe-color-success);
}
.psychexpert-admin__btn--success:hover:not(:disabled) { background: #1b5e20; border-color: #1b5e20; }

.psychexpert-admin__btn--danger {
    background: var(--pe-color-danger);
    color: #fff;
    border-color: var(--pe-color-danger);
}
.psychexpert-admin__btn--danger:hover:not(:disabled) { background: #7f0000; border-color: #7f0000; }

/* -----------------------------------------------------------------------------
   Tabellen
   ----------------------------------------------------------------------------- */
.psychexpert-admin__table-wrap {
    overflow-x: auto;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    margin-bottom: 20px;
}

.psychexpert-admin__table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    background: #fff;
}

.psychexpert-admin__table th {
    background: var(--pe-color-bg);
    color: var(--pe-color-text);
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .04em;
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid var(--pe-color-border);
    white-space: nowrap;
}

.psychexpert-admin__table td {
    padding: 9px 12px;
    border-bottom: 1px solid #f0f2f5;
    vertical-align: middle;
    color: var(--pe-color-text);
}

.psychexpert-admin__table tr:last-child td { border-bottom: none; }
.psychexpert-admin__table tr:hover td { background: #fafbfc; }

.psychexpert-admin__loading {
    text-align: center;
    color: var(--pe-color-text-muted);
    font-style: italic;
    padding: 20px !important;
}

.psychexpert-admin__actions {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.psychexpert-admin__details {
    margin-top: 8px;
    padding: 10px;
    background: var(--pe-color-bg);
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    font-size: 13px;
}

.psychexpert-admin__participant {
    padding: 6px 0;
    border-bottom: 1px solid #f0f2f5;
    color: var(--pe-color-text);
}
.psychexpert-admin__participant:last-child { border-bottom: none; }

/* -----------------------------------------------------------------------------
   Feedback-Meldungen
   ----------------------------------------------------------------------------- */
.psychexpert-admin__feedback {
    padding: 10px 14px;
    border-radius: var(--pe-radius);
    font-size: 13px;
    margin-bottom: 12px;
    border: 1px solid transparent;
}
.psychexpert-admin__feedback--success {
    background: #e8f5e9;
    color: var(--pe-color-success);
    border-color: #a5d6a7;
}
.psychexpert-admin__feedback--error {
    background: #fce4ec;
    color: var(--pe-color-danger);
    border-color: #ef9a9a;
}

/* -----------------------------------------------------------------------------
   Einstellungen-Karte
   ----------------------------------------------------------------------------- */
.psychexpert-admin__settings-card {
    background: #fff;
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius-lg);
    padding: 24px;
    box-shadow: var(--pe-shadow);
}
.psychexpert-admin__settings-card h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin: 0 0 6px;
}

.psychexpert-admin__hint {
    font-size: 13px;
    color: var(--pe-color-text-muted);
    margin-bottom: 16px;
    display: block;
}
.psychexpert-admin__hint-inline {
    font-size: 12px;
    color: var(--pe-color-text-muted);
    font-weight: 400;
}

/* -----------------------------------------------------------------------------
   Formular (Settings & Modal)
   ----------------------------------------------------------------------------- */
.psychexpert-admin__form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.psychexpert-admin__form-row {
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.psychexpert-admin__form-row label {
    font-size: 13px;
    font-weight: 600;
    color: var(--pe-color-text);
}
.psychexpert-admin__form-row .psychexpert-admin__input {
    max-width: 280px;
}

.psychexpert-admin__form-row--inline {
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

.psychexpert-admin__form-row--pair {
    flex-direction: row;
    align-items: flex-start;
    gap: 16px;
    flex-wrap: wrap;
}
.psychexpert-admin__form-row--pair .psychexpert-admin__pair-field {
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.psychexpert-admin__form-row--pair .psychexpert-admin__pair-field label {
    font-size: 13px;
    font-weight: 600;
    color: var(--pe-color-text);
    white-space: nowrap;
}
.psychexpert-admin__form-row--pair .psychexpert-admin__pair-field .psychexpert-admin__input {
    max-width: 110px;
    width: 110px;
}

.psychexpert-amount-tax {
    display: block;
    font-size: 0.75em;
    color: #888;
    margin-top: 2px;
}

.psychexpert-invoice-nr {
    display: inline-block;
    font-size: 11px;
    color: #555;
    margin-left: 6px;
    font-weight: 600;
}
.psychexpert-invoice-nr--draft {
    color: #999;
    font-style: italic;
    font-weight: 400;
}

.psychexpert-admin__form-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 4px;
}

.psychexpert-admin__save-status {
    font-size: 13px;
    color: var(--pe-color-success);
    font-weight: 600;
}

.psychexpert-admin__toggle-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--pe-color-text);
    cursor: pointer;
}

/* -----------------------------------------------------------------------------
   Status-Badges (psychexpert-badge)
   ----------------------------------------------------------------------------- */
.psychexpert-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 9px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .02em;
    white-space: nowrap;
    border: 1px solid transparent;
}
.psychexpert-badge.badge--success  { background: #e8f5e9; color: var(--pe-color-success); border-color: #a5d6a7; }
.psychexpert-badge.badge--warning  { background: #fff8e1; color: #f57f17;                 border-color: #ffe082; }
.psychexpert-badge.badge--danger   { background: #fce4ec; color: var(--pe-color-danger);  border-color: #ef9a9a; }
.psychexpert-badge.badge--info     { background: #e3f2fd; color: var(--pe-color-info);    border-color: #90caf9; }
.psychexpert-badge.badge--secondary{ background: #f5f6f8; color: var(--pe-color-neutral); border-color: #cfd8dc; }

/* -----------------------------------------------------------------------------
   Modal (Preis/Provision bearbeiten)
   ----------------------------------------------------------------------------- */
.psychexpert-admin__modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.psychexpert-admin__modal[style*="display: block"],
.psychexpert-admin__modal[style*="display:block"] {
    display: flex !important;
}

.psychexpert-admin__modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.55);
}

.psychexpert-admin__modal-box {
    position: relative;
    background: #fff;
    border-radius: var(--pe-radius-lg);
    box-shadow: var(--pe-shadow-lg);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 28px;
    z-index: 1;
}
.psychexpert-admin__modal-box h3 {
    font-size: 17px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin: 0 0 4px;
}

.psychexpert-admin__modal-subtitle {
    font-size: 13px;
    color: var(--pe-color-text-muted);
    margin: 0 0 20px;
}

.psychexpert-admin__modal-close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    font-size: 22px;
    cursor: pointer;
    color: var(--pe-color-text-muted);
    line-height: 1;
    padding: 4px;
}
.psychexpert-admin__modal-close:hover { color: var(--pe-color-text); }

/* -----------------------------------------------------------------------------
   E-Mail-Template-Editor (Admin)
   ----------------------------------------------------------------------------- */
.psychexpert-admin__email-editor {
    padding: 4px 0;
}

.psychexpert-admin__email-layout {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 20px;
    align-items: start;
    margin-top: 16px;
}

.psychexpert-admin__email-list {
    border: 1px solid var(--pe-color-border);
    border-radius: var(--pe-radius);
    overflow: hidden;
}
.psychexpert-admin__email-list h3 {
    font-size: 13px;
    font-weight: 700;
    color: var(--pe-color-text-muted);
    text-transform: uppercase;
    letter-spacing: .04em;
    padding: 10px 12px;
    margin: 0;
    background: var(--pe-color-bg);
    border-bottom: 1px solid var(--pe-color-border);
}
.psychexpert-admin__email-list .psychexpert-admin__btn {
    display: block;
    width: 100%;
    text-align: left;
    border-radius: 0;
    border: none;
    border-bottom: 1px solid var(--pe-color-border);
    padding: 9px 12px;
    font-size: 13px;
}
.psychexpert-admin__email-list .psychexpert-admin__btn:last-child { border-bottom: none; }
.psychexpert-admin__email-list .psychexpert-admin__btn--primary {
    background: var(--pe-color-primary);
    color: #fff;
}

.psychexpert-admin__email-editors {
    min-width: 0;
}

.psychexpert-email-editor-panel h3 {
    font-size: 15px;
    font-weight: 700;
    color: var(--pe-color-primary);
    margin: 0 0 12px;
}

.psychexpert-admin__email-params {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    margin-bottom: 14px;
    font-size: 13px;
    color: var(--pe-color-text-muted);
}

.psychexpert-admin__param-badge {
    background: #e3f2fd;
    color: #1565c0;
    border: 1px solid #90caf9;
    border-radius: 4px;
    padding: 2px 8px;
    font-size: 12px;
    font-family: monospace;
    cursor: pointer;
    transition: background var(--pe-transition);
}
.psychexpert-admin__param-badge:hover { background: #bbdefb; }

/* -----------------------------------------------------------------------------
   E-Mail-Vorschau-Modal
   ----------------------------------------------------------------------------- */
#psychexpert-email-preview-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
#psychexpert-email-preview-modal[style*="display: block"],
#psychexpert-email-preview-modal[style*="display:block"] {
    display: flex !important;
}

.psychexpert-email-preview__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.6);
}

.psychexpert-email-preview__box {
    position: relative;
    background: #fff;
    border-radius: var(--pe-radius-lg);
    box-shadow: var(--pe-shadow-lg);
    width: 100%;
    max-width: 680px;
    max-height: 85vh;
    overflow-y: auto;
    padding: 24px;
    z-index: 1;
}

.psychexpert-email-preview__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--pe-color-border);
    font-size: 15px;
}

.psychexpert-email-preview__subject-wrap {
    margin-bottom: 12px;
    font-size: 13px;
    color: var(--pe-color-text-muted);
    display: flex;
    gap: 6px;
    align-items: baseline;
}

.psychexpert-email-preview__subject {
    color: var(--pe-color-text);
    font-size: 14px;
}

/* ============================================================
   DASHBOARD – [edelweiss_psychexpert_dashboard]
   ============================================================ */

.psychexpert-dashboard {
    max-width: 1100px;
    margin: 0 auto;
    padding: 24px 16px;
    font-family: inherit;
}

.psychexpert-dashboard__header {
    margin-bottom: 24px;
}

.psychexpert-dashboard__title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--pe-color-dark, #1a1a2e);
    margin: 0 0 4px;
}

.psychexpert-dashboard__welcome {
    font-size: 0.95rem;
    color: var(--pe-color-muted, #6b7280);
}

.psychexpert-dashboard__feedback {
    padding: 12px 16px;
    border-radius: var(--pe-radius, 8px);
    margin-bottom: 16px;
    font-size: 0.9rem;
    background: #fef3c7;
    border: 1px solid #f59e0b;
    color: #92400e;
}

#psychexpert-feedback {
    position: sticky;
    top: 0;
    z-index: 100;
}

.psychexpert-dashboard__feedback.is-success {
    background: #d1fae5;
    border-color: #10b981;
    color: #065f46;
}

.psychexpert-dashboard__feedback.is-error {
    background: #fee2e2;
    border-color: #ef4444;
    color: #991b1b;
}

/* Tabs */
.psychexpert-dashboard__tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    border-bottom: 2px solid #e5e7eb;
    margin-bottom: 24px;
}

.psychexpert-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 16px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--pe-color-muted, #6b7280);
    transition: color 0.2s, border-color 0.2s;
}

.psychexpert-tab:hover {
    color: var(--pe-color-primary, #2563eb);
}

.psychexpert-tab--active {
    color: var(--pe-color-primary, #2563eb);
    border-bottom-color: var(--pe-color-primary, #2563eb);
}

.psychexpert-tab--teaser > a {
    position: relative;
}

.psychexpert-tab-content {
    position: relative;
}

.psychexpert-access-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(4px);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    pointer-events: all;
}

.psychexpert-access-overlay__inner {
    text-align: center;
    padding: 32px;
    max-width: 400px;
}

.psychexpert-access-overlay__inner .dashicons {
    font-size: 48px;
    width: 48px;
    height: 48px;
    color: #999;
    margin-bottom: 16px;
}

.psychexpert-access-overlay__hint {
    font-size: 13px;
    color: #888;
    margin-top: 8px;
}

.psychexpert-access-overlay__back {
    display: inline-grid;
    grid-auto-flow: column;
    grid-template-columns: 14px auto 14px;
    align-items: center;
    column-gap: 4px;
    justify-items: center;
    margin-top: 12px;
    padding: 3px 10px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid #d7dde5;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.2;
    color: #5f6773;
    text-decoration: none;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.psychexpert-access-overlay__back::after {
    content: '';
    width: 14px;
    height: 14px;
}

.psychexpert-access-overlay__back .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    margin: 0;
}

.psychexpert-access-overlay__back:hover {
    background: rgba(255, 255, 255, 1);
    border-color: #bcc6d3;
    color: #404854;
    text-decoration: none;
}

.psychexpert-upgrade-teaser {
    padding: 24px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.psychexpert-upgrade-teaser hr {
    margin: 24px 0;
    border: none;
    border-top: 1px solid #dee2e6;
}

.psychexpert-upgrade-teaser .upgrade-requested-notice {
    color: #6c757d;
    font-style: italic;
}

.psychexpert-upgrade-teaser .psychexpert-upgrade-request-btn {
    border-radius: 999px;
    padding: 7px 16px;
    line-height: 1.2;
}

/* Panels */
.psychexpert-dashboard__panel {
    display: none;
}

/* ============================================================
   PROFIL – Sub-Tabs
   ============================================================ */

.psychexpert-profile-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    border-bottom: 2px solid #e5e7eb;
    margin-bottom: 24px;
}

.psychexpert-profile-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--pe-color-muted, #6b7280);
    transition: color 0.2s, border-color 0.2s;
}

.psychexpert-profile-tab:hover {
    color: var(--pe-color-primary, #2563eb);
}

.psychexpert-profile-tab--active {
    color: var(--pe-color-primary, #2563eb);
    border-bottom-color: var(--pe-color-primary, #2563eb);
}

.psychexpert-profile-panel {
    display: none;
}

.psychexpert-profile-panel--active {
    display: block;
}

.psychexpert-dashboard__panel--active {
    display: block;
}

/* Panel Header */
.psychexpert-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
}

.psychexpert-panel-header__title {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--pe-color-dark, #1a1a2e);
    margin: 0;
}

.psychexpert-panel-header__desc {
    font-size: 0.88rem;
    color: var(--pe-color-muted, #6b7280);
    margin: 4px 0 0;
}

.psychexpert-panel-header__actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

/* ============================================================
   BUTTONS – gemeinsam für Dashboard + Public
   ============================================================ */

.psychexpert-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    border-radius: var(--pe-radius, 8px);
    border: none;
    cursor: pointer;
    font-size: 0.88rem;
    font-weight: 600;
    line-height: 1.4;
    transition: background 0.2s, opacity 0.2s;
    text-decoration: none;
}

.psychexpert-btn--primary {
    background: var(--pe-color-primary, #2563eb);
    color: #fff;
}

.psychexpert-btn--primary:hover {
    background: var(--pe-color-primary-dark, #1d4ed8);
    color: #fff;
}

.psychexpert-btn--secondary {
    background: #f3f4f6;
    color: var(--pe-color-dark, #1a1a2e);
    border: 1px solid #d1d5db;
}

.psychexpert-btn--secondary:hover {
    background: #e5e7eb;
}

.psychexpert-btn--danger {
    background: #ef4444;
    color: #fff;
}

.psychexpert-btn--danger:hover {
    background: #dc2626;
}

.psychexpert-btn--success {
    background-color: #2e7d32 !important;
    border-color: #2e7d32 !important;
    color: #fff !important;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.psychexpert-btn--success:hover {
    background-color: #1b5e20 !important;
    border-color: #1b5e20 !important;
}

.psychexpert-btn--sm {
    padding: 5px 12px;
    font-size: 0.8rem;
}

.psychexpert-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ============================================================
   FORMULARE – gemeinsam für Dashboard + Public
   ============================================================ */

.psychexpert-form {
    width: 100%;
}

.psychexpert-form--compact .psychexpert-form__group {
    margin-bottom: 12px;
}

.psychexpert-form__group {
    margin-bottom: 18px;
}

.psychexpert-form__group--inline {
    display: flex;
    align-items: center;
    gap: 12px;
}

.psychexpert-form__group--grow {
    flex: 1;
}

.psychexpert-form__row {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.psychexpert-form__row .psychexpert-form__group {
    flex: 1;
    min-width: 180px;
}

.psychexpert-form__label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--pe-color-dark, #1a1a2e);
    margin-bottom: 5px;
}

.psychexpert-form__label--inline {
    display: inline;
    margin-bottom: 0;
}

.psychexpert-form__input,
.psychexpert-form__select,
.psychexpert-form__textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: var(--pe-radius, 8px);
    font-size: 0.9rem;
    color: var(--pe-color-dark, #1a1a2e);
    background: #fff;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.psychexpert-form__input:focus,
.psychexpert-form__select:focus,
.psychexpert-form__textarea:focus {
    outline: none;
    border-color: var(--pe-color-primary, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.psychexpert-form__input--sm,
.psychexpert-form__select--sm {
    width: auto;
    min-width: 80px;
}

.psychexpert-form__textarea {
    min-height: 100px;
    resize: vertical;
}

.psychexpert-form__hint {
    font-size: 0.78rem;
    color: var(--pe-color-muted, #6b7280);
    margin: 4px 0 0;
}

.psychexpert-form__hint--muted {
    opacity: 0.65;
    font-style: italic;
}
.psychexpert-form__hint--intro {
    font-size: 0.95rem;
    color: #4b5563;
    margin-bottom: 1rem;
    line-height: 1.6;
}
.psychexpert-form__hint--box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-left: 4px solid #94a3b8;
    border-radius: 6px;
    padding: 12px 16px;
    margin-bottom: 1.25rem;
    font-size: 0.9rem;
    color: #374151;
    line-height: 1.6;
}

.psychexpert-form__input-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.psychexpert-form__input-wrap .psychexpert-form__input {
    flex: 1;
}

.psychexpert-form__char-counter {
    font-size: 0.78rem;
    color: var(--pe-color-muted, #6b7280);
    white-space: nowrap;
    flex-shrink: 0;
}

/* Admin: Color-Picker */
.psychexpert-admin__color-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.psychexpert-admin__input-color {
    width: 48px;
    height: 36px;
    padding: 2px;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    cursor: pointer;
    background: none;
}

.psychexpert-admin__color-hint {
    font-size: 0.78rem;
    color: var(--pe-color-muted, #6b7280);
}

.psychexpert-form__subtitle {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 14px;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-form__actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 20px;
}

.psychexpert-form__radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.psychexpert-form__radio-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.88rem;
    cursor: pointer;
}

/* Toggle */
.psychexpert-form__toggle {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.psychexpert-form__toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.psychexpert-form__toggle-slider {
    position: absolute;
    inset: 0;
    background: #d1d5db;
    border-radius: 24px;
    cursor: pointer;
    transition: background 0.2s;
}

.psychexpert-form__toggle-slider::before {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    left: 3px;
    top: 3px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.2s;
}

.psychexpert-form__toggle input:checked + .psychexpert-form__toggle-slider {
    background: var(--pe-color-primary, #2563eb);
}

.psychexpert-form__toggle input:checked + .psychexpert-form__toggle-slider::before {
    transform: translateX(20px);
}

/* Profil-Bild */
.psychexpert-profile-image {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.psychexpert-profile-image__preview {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #e5e7eb;
}

#psychexpert-logo-preview {
    width: auto;
    height: auto;
    border-radius: 0;
    object-fit: contain;
    border: none;
}

.psychexpert-upload-label {
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.psychexpert-upload-status {
    font-size: 0.82rem;
    color: var(--pe-color-muted, #6b7280);
}

.psychexpert-upload-status--error {
    color: #dc2626;
}

.psychexpert-hidden {
    display: none !important;
}

/* ============================================================
   FORMULAR-SEKTIONEN (Profil-Tab Blöcke)
   ============================================================ */

.psychexpert-form__section {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: var(--pe-radius, 8px);
    padding: 24px 28px;
    margin-bottom: 24px;
}

.psychexpert-form__section-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--pe-color-dark, #1a1a2e);
    margin: 0 0 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f0f0f5;
    display: flex;
    align-items: center;
    gap: 8px;
}

.psychexpert-form__section-title .dashicons {
    color: var(--pe-color-primary, #2563eb);
    font-size: 1.1rem;
    width: 1.1rem;
    height: 1.1rem;
}

.psychexpert-form__group--row {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    align-items: flex-end;
}

.psychexpert-form__col {
    flex: 1;
    min-width: 140px;
}

.psychexpert-form__col--sm {
    flex: 0 0 120px;
    min-width: 100px;
}

.psychexpert-form__subsection-title {
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--pe-color-muted, #6b7280);
    margin: 24px 0 12px;
    padding-bottom: 6px;
    border-bottom: 1px solid #f0f0f5;
}

/* ── Settings Anker-Navigation ── */
.psychexpert-settings-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 12px 0 20px;
}

.psychexpert-settings-nav__badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 14px;
    font-size: 0.78rem;
    font-weight: 600;
    color: #4b5563;
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    text-decoration: none;
    transition: all 0.15s ease;
    cursor: pointer;
}

.psychexpert-settings-nav__badge:hover {
    background: #e0e7ff;
    border-color: #a5b4fc;
    color: #3730a3;
}

.psychexpert-settings-nav__badge .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    line-height: 14px;
}

/* ── Settings Section Cards ── */
.psychexpert-settings-card {
    border-radius: 10px;
    padding: 20px 20px 12px;
    margin-bottom: 16px;
    border: 1px solid transparent;
}

.psychexpert-settings-card--darstellung {
    background: #f8faff;
    border-color: #e0e7f5;
}

.psychexpert-settings-card--checkout {
    background: #f6fdf8;
    border-color: #d5edd9;
}

.psychexpert-settings-card--planung {
    background: #faf8ff;
    border-color: #e4dff0;
}

.psychexpert-settings-card--backlink {
    background: #fff8f3;
    border-color: #f5d9c4;
}

.psychexpert-settings-card .psychexpert-form__subsection-title {
    margin-top: 0;
    border-bottom: none;
    padding-bottom: 0;
    margin-bottom: 16px;
}

.psychexpert-settings-card[id] {
    scroll-margin-top: 80px;
}

.psychexpert-settings-card__actions {
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid rgba(0, 0, 0, 0.06);
    text-align: right;
}

.psychexpert-btn--save-section {
    font-size: 0.82rem;
    padding: 6px 16px;
}

.psychexpert-form__group--highlight {
    background: #f0f7ff;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 8px;
}

.psychexpert-form__info-box {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    border-radius: 8px;
    padding: 12px 16px;
    margin-top: 10px;
    font-size: 0.85rem;
    line-height: 1.55;
}

.psychexpert-form__info-box--geo {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    color: #334155;
}

.psychexpert-form__info-box--geo.psychexpert-form__info-box--neutral {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #334155;
}

.psychexpert-form__info-box--geo.psychexpert-form__info-box--success {
    background: #ecfdf5;
    border-color: #6ee7b7;
    color: #065f46;
}

.psychexpert-form__info-box--geo.psychexpert-form__info-box--warning {
    background: #fffbeb;
    border-color: #fcd34d;
    color: #78350f;
}

.psychexpert-form__info-box--geo.psychexpert-form__info-box--error {
    background: #fef2f2;
    border-color: #fca5a5;
    color: #991b1b;
}

.psychexpert-form__info-box-icon {
    flex-shrink: 0;
    font-size: 1.2rem;
    width: 1.2rem;
    height: 1.2rem;
    margin-top: 1px;
    color: currentColor;
}

.psychexpert-form__info-box-text strong {
    font-size: 0.88rem;
}

.psychexpert-form__info-box-meta {
    font-size: 0.78rem;
    opacity: 0.9;
}

.psychexpert-form__group--actions {
    margin-top: 12px;
}

/* ============================================================
   STATUS BADGES
   ============================================================ */

.psychexpert-status-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.psychexpert-status-badge--active { background: #d1fae5; color: #065f46; }
.psychexpert-status-badge--pending { background: #fef3c7; color: #92400e; }
.psychexpert-status-badge--suspended { background: #fee2e2; color: #991b1b; }
.psychexpert-status-badge--cancelled { background: #f3f4f6; color: #6b7280; }
.psychexpert-status-badge--paid { background: #dbeafe; color: #1e40af; }
.psychexpert-status-badge--confirmed { background: #d1fae5; color: #065f46; }
.psychexpert-status-badge--submitted { background: #fef3c7; color: #92400e; }
.psychexpert-status-badge--billed { background: #ede9fe; color: #5b21b6; }

.psychexpert-meta-badge {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    padding: 6px 10px;
    border-radius: 14px;
    line-height: 1.1;
    font-weight: 600;
}

.psychexpert-meta-badge__main {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.psychexpert-meta-badge__sub {
    font-size: 0.64rem;
    opacity: 0.75;
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0;
}

.psychexpert-meta-badge--submitted {
    background: #fef3c7;
    color: #92400e;
}

.psychexpert-facts-status-badges {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
}

/* Billing-Group confirmed row (Gutachter-Dashboard + Admin) */
.psychexpert-billing-group-row--confirmed > td {
    background-color: #f0fdf4;
}

/* Overlay-Modal */
.psychexpert-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.psychexpert-modal-content {
    background: #fff;
    border-radius: 8px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.psychexpert-modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

/* Zweizeilige Subrow (Admin-Verrechnungstabelle) */
.psychexpert-billing-group-subrow td {
    padding-top: 0;
    border-top: none;
    color: #666;
}

.psychexpert-billing-group-subrow + .psychexpert-billing-group-row {
    border-top: 2px solid #e0e0e0;
}

/* Payment-Badges (Vor-Ort-Zahlung) */
.psychexpert-payment-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    margin-left: 6px;
    vertical-align: middle;
}
.psychexpert-payment-badge--open { background: #fef3c7; color: #92400e; }
.psychexpert-payment-badge--paid { background: #d1fae5; color: #065f46; }

/* ============================================================
   TABELLEN
   ============================================================ */

.psychexpert-table-wrap {
    overflow-x: auto;
    margin-bottom: 16px;
}

.psychexpert-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}

.psychexpert-table th {
    text-align: left;
    padding: 10px 12px;
    background: #f9fafb;
    border-bottom: 2px solid #e5e7eb;
    font-weight: 600;
    color: var(--pe-color-dark, #1a1a2e);
    white-space: nowrap;
}

.psychexpert-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #f3f4f6;
    vertical-align: middle;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-table tr:hover td {
    background: #f9fafb;
}

.psychexpert-table__empty,
.psychexpert-table__loading {
    text-align: center;
    color: var(--pe-color-muted, #6b7280);
    padding: 24px;
    font-style: italic;
}

.psychexpert-table__check {
    width: 36px;
}

/* Spalten Status + Aktion in "Offene Buchungen" ausblenden */
.psychexpert-table--billing thead th:nth-child(5),
.psychexpert-table--billing thead th:nth-child(6),
.psychexpert-table--billing tbody td:nth-child(5),
.psychexpert-table--billing tbody td:nth-child(6) {
    display: none !important;
}

.psychexpert-row--saved td {
    background-color: #d1fae5 !important;
    transition: background-color 0.3s ease;
}

.psychexpert-row--billed td {
    background-color: #fef9c3;
}

.psychexpert-table-legend {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    font-size: 0.85em;
    color: #6b7280;
}

.psychexpert-table-legend__item {
    display: inline-block;
    width: 16px;
    height: 16px;
    border-radius: 3px;
    flex-shrink: 0;
}

.psychexpert-table-legend__item--billed {
    background-color: #fef9c3;
    border: 1px solid #fde047;
}

.psychexpert-table__actions {
    white-space: nowrap;
    display: flex;
    gap: 6px;
    align-items: center;
}

/* ============================================================
   BILLING-DETAIL TABELLE (aufgeklappte Zeile im Verrechnungstab)
   ============================================================ */

.psychexpert-table--billing-detail {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    margin-top: 6px;
}

.psychexpert-table--billing-detail th {
    text-align: left;
    padding: 6px 10px;
    background: #f1f5f9;
    border-bottom: 2px solid #e2e8f0;
    font-weight: 600;
    color: #374151;
    white-space: nowrap;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.psychexpert-table--billing-detail td {
    padding: 6px 10px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
    font-size: 13px;
    color: #1d2327;
}

.psychexpert-table--billing-detail tr:last-child td {
    border-bottom: none;
}

/* ============================================================
   CANCEL-DETAIL (Storno-Aufschlüsselung pro Buchung)
   ============================================================ */

.psychexpert-cancel-detail {
    margin-top: 8px;
}

.psychexpert-cancel-detail__row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    padding: 4px 0;
    border-bottom: 1px solid #f1f5f9;
    font-size: 13px;
}

.psychexpert-cancel-detail__row:last-child {
    border-bottom: none;
}

.psychexpert-cancel-detail__row--deduction .psychexpert-cancel-detail__value {
    color: #dc2626;
}

.psychexpert-cancel-detail__row--total {
    border-top: 2px solid #e2e8f0;
    margin-top: 4px;
    padding-top: 6px;
}

.psychexpert-cancel-detail__label {
    flex: 1 1 auto;
    color: #555;
    line-height: 1.4;
}

.psychexpert-cancel-detail__value {
    flex: 0 0 auto;
    text-align: right;
    font-weight: 600;
    white-space: nowrap;
    color: #1d2327;
}

/* ============================================================
   TERMINE / APPOINTMENTS
   ============================================================ */

.psychexpert-appointments {
    width: 100%;
}

.psychexpert-appointments__toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
}

.psychexpert-appointments__title {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-event-form-wrap {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: var(--pe-radius, 8px);
    padding: 20px;
    margin-bottom: 20px;
}

.psychexpert-events-list {
    width: 100%;
}

.psychexpert-events-list__loading {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 20px;
    color: var(--pe-color-muted, #6b7280);
    font-size: 0.9rem;
}

.psychexpert-events-list__empty {
    text-align: center;
    color: var(--pe-color-muted, #6b7280);
    padding: 24px;
    font-style: italic;
}

/* Spinner */
.psychexpert-spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid #e5e7eb;
    border-top-color: var(--pe-color-primary, #2563eb);
    border-radius: 50%;
    animation: psychexpert-spin 0.7s linear infinite;
    flex-shrink: 0;
}

@keyframes psychexpert-spin {
    to { transform: rotate(360deg); }
}

/* ============================================================
   VERRECHNUNG / BILLING
   ============================================================ */

.psychexpert-billing-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 16px;
}

.psychexpert-billing-check {
    cursor: pointer;
    width: 16px;
    height: 16px;
}

.psychexpert-billing-check:checked {
    accent-color: var(--pe-color-primary, #2563eb);
}

/* Auswahl-Highlight: Zeile hervorheben wenn Checkbox aktiv */
.psychexpert-billing-check:checked ~ td,
tr:has(.psychexpert-billing-check:checked) td {
    background-color: #eff6ff;
}

/* Eingereichte Verrechnungen – Gruppenzeile */
.psychexpert-billing-group-row {
    cursor: pointer;
    background-color: #f9fafb;
    transition: background-color 0.15s ease;
}

.psychexpert-billing-group-row:hover {
    background-color: #f3f4f6;
}

.psychexpert-billing-group-toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
    padding: 2px 6px;
    border-radius: 4px;
    color: var(--pe-color-primary, #2563eb);
    transition: background-color 0.15s ease;
}

.psychexpert-billing-group-toggle:hover {
    background-color: #e0e7ff;
}

/* Aufklappbare Detail-Zeile */
.psychexpert-billing-group-detail {
    display: none;
}

.psychexpert-billing-group-detail.is-open {
    display: table-row;
}

.psychexpert-billing-group-detail td {
    padding: 0 12px 12px;
    background-color: #fafbfc;
    border-top: none;
}

.psychexpert-billing-group-detail table {
    width: 100%;
    font-size: 0.85em;
    border-collapse: collapse;
    margin-top: 4px;
}

.psychexpert-billing-group-detail table th {
    background-color: #f3f4f6;
    font-weight: 600;
    text-align: left;
    padding: 6px 10px;
    font-size: 0.85em;
}

/* Admin-Badges (Verrechnungsmodul) */
.psychexpert-admin__badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.03em;
}
.psychexpert-admin__badge--success { background: #d1fae5; color: #065f46; }
.psychexpert-admin__badge--warning { background: #fef3c7; color: #92400e; }

/* Nested detail table in admin billing */
.psychexpert-admin__table--nested {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    background: #fafbfc;
}
.psychexpert-admin__table--nested th {
    padding: 6px 10px;
    background: #f1f5f9;
    border-bottom: 1px solid #e2e8f0;
    font-weight: 600;
    font-size: 0.8rem;
}
.psychexpert-admin__table--nested td {
    padding: 6px 10px;
    border-bottom: 1px solid #f1f5f9;
}

.psychexpert-billing-group-detail table td {
    padding: 6px 10px;
    border-bottom: 1px solid #e5e7eb;
    background-color: transparent;
}

/* Bestätigungsdialog-Warnung */
.psychexpert-billing-warning {
    background-color: #fef3c7;
    border: 1px solid #f59e0b;
    border-radius: var(--pe-radius, 8px);
    padding: 12px 16px;
    color: #92400e;
    font-size: 0.9rem;
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.psychexpert-billing-warning::before {
    content: "⚠";
    font-size: 1.1rem;
    flex-shrink: 0;
}

/* ============================================================
   EXPORT
   ============================================================ */

.psychexpert-export-options {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 16px;
}

.psychexpert-export-card {
    flex: 1;
    min-width: 220px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: var(--pe-radius, 8px);
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
}

.psychexpert-export-card__icon {
    font-size: 2rem;
    color: var(--pe-color-primary, #2563eb);
}

.psychexpert-export-card__title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-export-card__desc {
    font-size: 0.85rem;
    color: var(--pe-color-muted, #6b7280);
    margin: 0;
}

/* ============================================================
   MODAL – Dashboard (Stornierung)
   ============================================================ */

.psychexpert-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.psychexpert-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
}

.psychexpert-modal__dialog {
    position: relative;
    background: #fff;
    border-radius: var(--pe-radius, 8px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    max-width: 480px;
    width: 90%;
    z-index: 1;
}

.psychexpert-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #e5e7eb;
}

.psychexpert-modal__title {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-modal__close {
    background: none;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    color: var(--pe-color-muted, #6b7280);
    line-height: 1;
    padding: 0 4px;
}

.psychexpert-modal__close:hover {
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-modal__body {
    padding: 20px;
    font-size: 0.9rem;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-modal__footer {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    padding: 14px 20px;
    border-top: 1px solid #e5e7eb;
}

/* ============================================================
   NOTICE
   ============================================================ */

.psychexpert-notice {
    padding: 12px 16px;
    border-radius: var(--pe-radius, 8px);
    font-size: 0.88rem;
    margin-bottom: 16px;
    border-left: 4px solid transparent;
}

.psychexpert-notice--warning {
    background: #fef3c7;
    border-color: #f59e0b;
    color: #92400e;
}

.psychexpert-notice--info {
    background: #dbeafe;
    border-color: #3b82f6;
    color: #1e40af;
}

.psychexpert-notice--error {
    background: #fee2e2;
    border-color: #ef4444;
    color: #991b1b;
}

/* ============================================================
   TEILNEHMER-LISTE
   ============================================================ */

.psychexpert-participant-list {
    margin: 0;
    padding: 0 0 0 16px;
    font-size: 0.82rem;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-participant-list li {
    margin-bottom: 2px;
}

.psychexpert-muted {
    color: var(--pe-color-muted, #6b7280);
    font-style: italic;
    font-size: 0.85rem;
}

/* ============================================================
   PUBLIC LISTING – [edelweiss_psychexpert]
   ============================================================ */

.psychexpert-listing__header {
    text-align: center;
    margin-bottom: 32px;
}

.psychexpert-listing__title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--pe-color-dark, #1a1a2e);
    margin: 0 0 8px;
}

.psychexpert-listing__subtitle {
    font-size: 1rem;
    color: var(--pe-color-muted, #6b7280);
    margin: 0;
}

.psychexpert-listing__register-wrap {
    margin-bottom: 24px;
    text-align: center;
}

.psychexpert-listing__empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--pe-color-muted, #6b7280);
    font-size: 0.95rem;
}

.psychexpert-listing__hint,
.psychexpert-listing__zoom-hint {
    padding: 32px 20px;
    text-align: center;
    color: var(--pe-color-text-muted, #5a6475);
    font-size: 0.95rem;
}

.psychexpert-listing__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

/* Card-Kalender */
.psychexpert-card__calendar {
    margin-top: 16px;
    border-top: 1px solid #f3f4f6;
    padding-top: 14px;
}

.psychexpert-card__calendar-title {
    font-size: 0.9rem;
    font-weight: 600;
    margin: 0 0 10px;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-card__reviews {
    margin-top: 12px;
    font-size: 0.82rem;
    color: var(--pe-color-muted, #6b7280);
}

/* ============================================================
   TEILNEHMER-SCHRITT (Public Booking)
   ============================================================ */

.psychexpert-participants-step {
    margin-top: 16px;
    border-top: 1px solid #e5e7eb;
    padding-top: 16px;
}

.psychexpert-participants-step__inner {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: var(--pe-radius, 8px);
    padding: 20px;
}

.psychexpert-participants-step__title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 14px;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-participants-step__count-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.psychexpert-participants-step__error {
    color: #ef4444;
    font-size: 0.85rem;
    margin-top: 8px;
}

.psychexpert-participants-step__actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 16px;
}

.psychexpert-participants-count {
    width: 70px;
    padding: 7px 10px;
    border: 1px solid #d1d5db;
    border-radius: var(--pe-radius, 8px);
    font-size: 0.9rem;
    text-align: center;
}

.psychexpert-participants-fields {
    margin-top: 12px;
}

/* ============================================================
   WARTELISTE (Public)
   ============================================================ */

.psychexpert-waitlist {
    margin-top: 16px;
    border-top: 1px solid #e5e7eb;
    padding-top: 16px;
}

.psychexpert-waitlist__inner {
    background: #fef3c7;
    border: 1px solid #f59e0b;
    border-radius: var(--pe-radius, 8px);
    padding: 20px;
}

.psychexpert-waitlist__title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 8px;
    color: #92400e;
}

.psychexpert-waitlist__info {
    font-size: 0.85rem;
    color: #92400e;
    margin: 0 0 14px;
}

.psychexpert-waitlist__form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.psychexpert-waitlist__error {
    color: #ef4444;
    font-size: 0.82rem;
    margin-top: 4px;
}

.psychexpert-waitlist__success {
    color: #065f46;
    font-size: 0.82rem;
    margin-top: 4px;
    background: #d1fae5;
    padding: 8px 12px;
    border-radius: var(--pe-radius, 8px);
}

/* ============================================================
   FORMULAR-ELEMENTE (Public – einfache Variante)
   ============================================================ */

.psychexpert-form-row {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.psychexpert-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--pe-color-dark, #1a1a2e);
}

.psychexpert-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #d1d5db;
    border-radius: var(--pe-radius, 8px);
    font-size: 0.9rem;
    color: var(--pe-color-dark, #1a1a2e);
    background: #fff;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.psychexpert-input:focus {
    outline: none;
    border-color: var(--pe-color-primary, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.psychexpert-required {
    color: #ef4444;
    margin-left: 2px;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 640px) {
    .psychexpert-dashboard__tabs {
        gap: 2px;
    }
    .psychexpert-tab {
        padding: 8px 10px;
        font-size: 0.82rem;
    }
    .psychexpert-listing__grid {
        grid-template-columns: 1fr;
    }
    .psychexpert-form__row {
        flex-direction: column;
    }
    .psychexpert-export-options {
        flex-direction: column;
    }
    .psychexpert-panel-header {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 599px) {
     .psychexpert-dashboard {
         padding: 12px 4px;
     }

     .psychexpert-panel {
         padding: 12px 8px;
     }

     .psychexpert-form__section {
         padding: 12px 0;
         border-left: none;
         border-right: none;
         border-radius: 0;
     }

     .psychexpert-dashboard__header {
         display: flex;
         flex-direction: column;
         align-items: flex-start;
         gap: 4px;
     }

    .psychexpert-dashboard__title {
        font-size: 16px;
    }

    .psychexpert-dashboard__welcome {
        font-size: 18px;
        font-weight: 600;
    }

    .psychexpert-status-badge {
        align-self: flex-start;
    }

    .psychexpert-form input,
    .psychexpert-form select,
    .psychexpert-form textarea {
        font-size: 16px !important;
        min-height: 44px;
    }

    .psychexpert-form__group--row {
        flex-direction: column;
        gap: 12px;
    }

    .psychexpert-form__col {
        width: 100% !important;
    }

    .psychexpert-form__col--sm {
        width: 48% !important;
    }

    .psychexpert-form__group--row:has(.psychexpert-form__col--sm) {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .psychexpert-form__group--row--name-mobile {
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: flex-start;
        gap: 3px;
    }

    .psychexpert-form__group--row--name-mobile .psychexpert-form__col,
    .psychexpert-form__group--row--name-mobile .psychexpert-form__col--sm {
        min-width: 0;
        width: auto !important;
    }

    .psychexpert-form__group--row--name-mobile .psychexpert-form__col {
        flex: 0 1 34%;
    }

    .psychexpert-form__group--row--name-mobile .psychexpert-form__col--sm {
        flex: 0 1 12%;
    }

    .psychexpert-form__group--row--name-mobile .psychexpert-form__label {
        display: block;
        margin-bottom: 2px;
        font-size: 9px;
        line-height: 1.05;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .psychexpert-form__group--row--name-mobile .psychexpert-form__input {
        box-sizing: border-box;
        width: 100%;
        min-width: 0;
        min-height: 32px;
        padding: 3px 4px;
        font-size: 11px !important;
        line-height: 1.1;
    }

    .psychexpert-btn {
        min-height: 44px;
        min-width: 44px;
    }

    .psychexpert-btn--primary {
        width: 100%;
        justify-content: center;
    }

    .psychexpert-form__actions {
        flex-direction: column;
        gap: 8px;
    }
}

/* Spalte "Eigene Ref." schmäler */
.psychexpert-table--billing-groups th:nth-child(3),
.psychexpert-table--billing-groups td:nth-child(3) {
    width: 8%;
    max-width: 100px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 767px) {
    /* Classic-Rows auf Mobile ausblenden – Accordion-Rows übernehmen */
    .psychexpert-row-classic {
        display: none;
    }

    .psychexpert-dashboard__tabs {
        display: flex;
        flex-wrap: nowrap;
        overflow: hidden;
        gap: 6px;
        padding: 8px 0;
        border-bottom: none;
        scrollbar-width: none;
    }

    .psychexpert-tab {
        flex: 1 1 25%;
        min-width: 0;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        padding: 10px 6px;
        font-size: 11px;
        line-height: 1.2;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        background: #f8f6f1;
        border: 1px solid #d9d4c7;
        border-radius: 10px;
        margin-bottom: 0;
        cursor: pointer;
        text-align: center;
        color: #4b5563;
        box-shadow: none;
        transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
    }

    .psychexpert-tab:hover {
        background: #f1ede4;
        border-color: #cfc7b6;
        color: #2f3a45;
    }

    .psychexpert-tab:focus,
    .psychexpert-tab:focus-visible {
        outline: 2px solid #b8be2e;
        outline-offset: 1px;
        box-shadow: none;
    }

    .psychexpert-tab .dashicons {
        font-size: 18px;
        width: 18px;
        height: 18px;
    }

    .psychexpert-tab--active {
        background: #dbde38;
        border-color: #c7cb2d;
        border-bottom-color: #c7cb2d;
        color: #1f2937;
        font-weight: 600;
        box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
    }

    .psychexpert-tab--active:hover {
        background: #d4d72f;
        border-color: #bfc327;
        color: #1f2937;
    }

    .psychexpert-profile-tabs {
        display: flex;
        overflow-x: auto;
        gap: 6px;
        padding: 10px 12px;
        background: #f8fafc;
        border-radius: 8px;
        margin-bottom: 16px;
        scrollbar-width: none;
    }

    .psychexpert-profile-tabs::-webkit-scrollbar {
        display: none;
    }

    .psychexpert-profile-tab {
        flex: 0 0 auto;
        padding: 6px 12px;
        border-radius: 20px;
        font-size: 12px;
        background: #fff;
        border: 1px solid #e2e8f0;
        color: #64748b;
    }

    .psychexpert-profile-tab--active {
        background: var(--edelweiss-primary, #2563eb);
        color: #fff;
        border-color: transparent;
    }

    .psychexpert-table--bookings thead,
    .psychexpert-table--billing thead,
    .psychexpert-table--billing-groups thead {
        display: none;
    }

    .psychexpert-bookings-table tbody tr,
    .psychexpert-billing-table tbody tr,
    .psychexpert-cancellation-table tbody tr {
        display: block;
        background: #fff;
        border: 1px solid #e2e8f0;
        border-radius: 10px;
        padding: 14px;
        margin-bottom: 12px;
        box-shadow: 0 1px 3px rgba(0,0,0,.06);
    }

    .psychexpert-table--bookings tbody tr.psychexpert-row-slim,
    .psychexpert-table--billing tbody tr.psychexpert-row-slim,
    .psychexpert-table--billing-groups tbody tr.psychexpert-row-slim {
        background: transparent;
        border: none;
        border-radius: 0;
        padding: 0;
        box-shadow: none;
    }

    .psychexpert-bookings-table td,
    .psychexpert-billing-table td,
    .psychexpert-cancellation-table td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 4px 0;
        border: none;
        font-size: 13px;
    }

    .psychexpert-bookings-table td::before,
    .psychexpert-billing-table td::before,
    .psychexpert-cancellation-table td::before {
        content: attr(data-label);
        font-weight: 600;
        color: #64748b;
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: .04em;
        flex: 0 0 40%;
    }

    .psychexpert-bookings-table td:last-child,
    .psychexpert-billing-table td:last-child,
    .psychexpert-cancellation-table td:last-child {
        flex-direction: column;
        gap: 6px;
        align-items: stretch;
    }

    .psychexpert-bookings-table td:last-child .psychexpert-btn,
    .psychexpert-billing-table td:last-child .psychexpert-btn,
    .psychexpert-cancellation-table td:last-child .psychexpert-btn {
        width: 100%;
        justify-content: center;
    }

    /* ── Accordion: Slim-Row ── */
    .psychexpert-row-slim__cell {
        display: block;
        width: 100%;
        max-width: 100%;
        padding: 0;
        border: none !important;
        box-sizing: border-box;
    }

    .psychexpert-row-slim {
        cursor: pointer;
        user-select: none;
        display: block;
        margin-bottom: 4px;
        font-size: 13px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .psychexpert-card-shell {
        background: #fff;
        border: 1px solid #e2e8f0;
        border-radius: 10px;
        padding: 12px 14px;
        box-shadow: 0 1px 3px rgba(0, 0, 0, .06);
        transition: background-color .15s ease;
        box-sizing: border-box;
    }

    .psychexpert-row-slim:active .psychexpert-card-shell {
        background: #f8fafc;
    }

    .psychexpert-row-slim__primary {
        display: flex;
        align-items: center;
        gap: 10px;
        flex: 1 1 auto;
        min-width: 0;
        flex-wrap: wrap;
    }

    .psychexpert-row-slim__date {
        font-weight: 600;
        white-space: nowrap;
        color: #1e293b;
    }

    .psychexpert-row-slim__name {
        color: #475569;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        max-width: 120px;
    }

    .psychexpert-row-slim__status {
        flex: 0 0 auto;
    }

    .psychexpert-row-toggle {
        flex: 0 0 auto;
        color: #94a3b8;
        font-size: 16px;
        transition: transform 0.2s ease;
        line-height: 1;
    }

    .psychexpert-row-toggle.is-open {
        transform: rotate(180deg);
    }

    /* ── Overflow-Schutz: kein horizontales Scrollen auf Mobile ── */
    .psychexpert-table--billing-groups {
        width: 100% !important;
        max-width: 100% !important;
        table-layout: fixed;
    }

    /* ── Accordion: Detail-Block ── */
    .psychexpert-row-detail {
        display: none;
        margin-bottom: 8px;
        width: 100%;
        box-sizing: border-box;
    }

    .psychexpert-row-detail > td {
        display: block;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 0;
        border: none;
    }

    .psychexpert-row-detail.is-open {
        display: block;
    }

    .psychexpert-row-detail__inner {
        background: #f8fafc;
        border: 1px solid #e2e8f0;
        border-top: none;
        border-radius: 0 0 10px 10px;
        padding: 12px 14px;
        margin-top: -4px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    /* ── Billing-Detail Tabelle: Card-Layout auf Mobile ── */
    .psychexpert-table--billing-detail thead {
        display: none;
    }

    .psychexpert-table--billing-detail tbody tr {
        display: block;
        background: #fff;
        border: 1px solid #e2e8f0;
        border-radius: 8px;
        padding: 10px 12px;
        margin-bottom: 8px;
    }

    .psychexpert-table--billing-detail td {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 3px 0;
        border: none;
        font-size: 13px;
    }

    .psychexpert-table--billing-detail td::before {
        content: attr(data-label);
        font-weight: 600;
        color: #64748b;
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: .04em;
        flex: 0 0 40%;
    }

    /* ── Cancel-Detail: zwei Zeilen auf Mobile, volle Breite ── */
    .psychexpert-cancel-detail__row {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
        font-size: 12px;
        width: 100%;
        box-sizing: border-box;
    }

    .psychexpert-cancel-detail__label {
        font-size: 12px;
        flex: 1 1 100%;
        width: 100%;
    }

    .psychexpert-cancel-detail__value {
        font-size: 12px;
        text-align: left;
        width: 100%;
    }

    /* ── Cancel-Group-Item: volle Breite, kein overflow ── */
    .psychexpert-cancel-group-item {
        padding: 8px 10px !important;
        font-size: 13px;
        box-sizing: border-box;
        width: 100%;
    }

    /* ── Slim-Row-Cell: overflow verhindern ── */
    .psychexpert-row-slim__cell {
        overflow-x: hidden;
        max-width: 100%;
        box-sizing: border-box;
    }

    .psychexpert-row-detail__field {
        display: grid;
        grid-template-columns: minmax(136px, 46%) minmax(0, 1fr);
        align-items: start;
        column-gap: 12px;
        row-gap: 4px;
        padding: 8px 0;
        font-size: 13px;
        border-bottom: 1px solid #f1f5f9;
    }

    .psychexpert-row-detail__field:last-of-type {
        border-bottom: none;
    }

    .psychexpert-table--billing .psychexpert-row-slim__cell {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .psychexpert-billing-card,
    .psychexpert-billing-group-card {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .psychexpert-table--billing .psychexpert-billing-card__top {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
    }

    .psychexpert-table--billing .psychexpert-billing-card__customer-wrap {
        display: flex;
        flex-direction: column;
        gap: 6px;
        min-width: 0;
        flex: 1 1 auto;
    }

    .psychexpert-table--billing .psychexpert-billing-card__customer {
        font-size: 15px;
        font-weight: 700;
        line-height: 1.35;
        color: #0f172a;
        overflow-wrap: anywhere;
    }

    .psychexpert-table--billing .psychexpert-billing-card__type {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        align-self: flex-start;
        padding: 3px 8px;
        border-radius: 999px;
        background: #fef2f2;
        color: #b91c1c;
        font-size: 11px;
        font-weight: 700;
        line-height: 1.2;
        text-transform: uppercase;
        letter-spacing: .04em;
    }

    .psychexpert-table--billing .psychexpert-billing-card__badges {
        display: flex;
        flex-direction: column;
        align-items: flex-end;
        gap: 8px;
        flex: 0 0 auto;
    }

    .psychexpert-table--billing .psychexpert-billing-card__status {
        display: flex;
        justify-content: flex-end;
    }

    .psychexpert-table--billing .psychexpert-billing-card__meta {
        display: flex;
        flex-wrap: wrap;
        gap: 6px 10px;
        font-size: 12px;
        color: #64748b;
    }

    .psychexpert-table--billing .psychexpert-billing-card__date,
    .psychexpert-table--billing .psychexpert-billing-card__order {
        display: inline-flex;
        align-items: center;
        gap: 4px;
        min-width: 0;
    }

    .psychexpert-table--billing .psychexpert-billing-card__amount {
        padding: 10px 12px;
        border-radius: 12px;
        background: #f8fafc;
        border: 1px solid #e2e8f0;
        color: #0f172a;
        font-size: 13px;
        font-weight: 600;
        line-height: 1.45;
        overflow-wrap: anywhere;
    }

    .psychexpert-table--billing .psychexpert-billing-card__hint {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
        padding-top: 2px;
        color: #475569;
        font-size: 12px;
    }

    .psychexpert-table--billing .psychexpert-billing-card__hint-main {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        min-width: 0;
        flex: 1 1 auto;
    }

    .psychexpert-table--billing .psychexpert-billing-card__hint-text {
        min-width: 0;
        line-height: 1.4;
        overflow-wrap: anywhere;
    }

    .psychexpert-table--billing .psychexpert-billing-card__hint-main .psychexpert-billing-check {
        flex: 0 0 auto;
        margin: 0;
    }

    .psychexpert-table--billing .psychexpert-row-detail__inner {
        padding: 12px 14px;
    }

    .psychexpert-table--billing .psychexpert-row-detail__field {
        grid-template-columns: minmax(140px, 46%) minmax(0, 1fr);
    }

    .psychexpert-table--billing .psychexpert-row-detail__field--selection .psychexpert-row-detail__value {
        display: flex;
        align-items: center;
        justify-content: flex-start;
    }

    .psychexpert-table--billing .psychexpert-row-detail__value {
        overflow-wrap: anywhere;
    }

    /* ── Billing Card – Mobile ───────────────────────────────────────────── */
    .psychexpert-card__top {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 8px;
        margin-bottom: 6px;
        flex-wrap: nowrap;
    }

    .psychexpert-card__title-wrap {
        display: flex;
        align-items: center;
        flex-wrap: wrap;
        gap: 8px;
        min-width: 0;
        flex: 1 1 auto;
    }

    .psychexpert-card__billing-nr {
        font-weight: 700;
        font-size: 14px;
        color: #1e293b;
        min-width: 0;
        overflow-wrap: anywhere;
    }

    .psychexpert-card__amount {
        text-align: center;
        font-size: 20px;
        font-weight: 700;
        color: #0f172a;
        padding: 8px 0 6px;
        border-top: 1px solid #e2e8f0;
        border-bottom: 1px solid #e2e8f0;
        margin-bottom: 6px;
    }

    .psychexpert-card__meta {
        display: flex;
        align-items: center;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 8px;
        font-size: 12px;
        color: #64748b;
    }

    .psychexpert-card__status {
        flex: 0 0 auto;
    }

    .psychexpert-card__date {
        flex: 1 1 auto;
        color: #94a3b8;
        font-size: 11px;
        min-width: 0;
    }

    .psychexpert-row-detail__label {
        font-weight: 600;
        color: #64748b;
        font-size: 11px;
        text-transform: uppercase;
        letter-spacing: .04em;
        min-width: 0;
    }

    .psychexpert-row-detail__value {
        color: #1e293b;
        font-size: 13px;
        text-align: right;
        min-width: 0;
        overflow-wrap: anywhere;
    }

    .psychexpert-row-detail__field--documents {
        align-items: center;
    }

    .psychexpert-row-detail__field--documents .psychexpert-row-detail__value {
        overflow-wrap: normal;
    }

    .psychexpert-row-detail__field--documents .psychexpert-pdf-actions {
        display: inline-grid;
        grid-template-columns: repeat(2, 40px);
        gap: 8px;
        justify-content: end;
        align-items: center;
    }

    .psychexpert-row-detail__field--documents .psychexpert-pdf-btn {
        width: 40px;
        min-width: 40px;
        height: 40px;
        padding: 0;
        justify-content: center;
        border-radius: 8px;
    }

    .psychexpert-row-detail__field--documents .psychexpert-pdf-btn__icon {
        width: 18px;
        height: 18px;
        object-fit: contain;
    }

    .psychexpert-row-detail__field--documents .psychexpert-pdf-btn__send-icon {
        font-size: 16px;
        line-height: 1;
    }

    /* ── Booking Card – Mobile ──────────────────────────────────────────── */
    .psychexpert-booking-card {
        display: grid;
        gap: 10px;
    }

    .psychexpert-booking-card__top {
        display: flex;
        align-items: flex-start;
        justify-content: space-between;
        gap: 10px;
    }

    .psychexpert-booking-card__event-date {
        font-size: 14px;
        font-weight: 700;
        line-height: 1.35;
        color: #0f172a;
        min-width: 0;
    }

    .psychexpert-booking-card__status {
        flex: 0 0 auto;
    }

    .psychexpert-booking-card__participant {
        font-size: 15px;
        font-weight: 600;
        line-height: 1.4;
        color: #1e293b;
    }

    .psychexpert-booking-card__participant .psychexpert-link-btn {
        font-size: inherit;
        font-weight: inherit;
        line-height: inherit;
        color: inherit;
        text-align: left;
    }

    .psychexpert-booking-card__bottom {
        display: flex;
        align-items: flex-start;
        gap: 10px;
    }

    .psychexpert-booking-card__meta {
        display: flex;
        flex: 1 1 auto;
        flex-wrap: wrap;
        gap: 6px;
        min-width: 0;
    }

    .psychexpert-booking-card__quickfact {
        display: inline-flex;
        align-items: center;
        min-height: 28px;
        padding: 4px 10px;
        border-radius: 999px;
        background: #f1f5f9;
        color: #475569;
        font-size: 12px;
        line-height: 1.25;
    }

    .psychexpert-booking-card__service.is-done {
        background: #dcfce7;
        color: #166534;
    }

    .psychexpert-booking-card__service.is-open {
        background: #fef3c7;
        color: #92400e;
    }

    .psychexpert-booking-card__note-state.has-note {
        background: #dbeafe;
        color: #1d4ed8;
    }

    .psychexpert-booking-card__bottom .psychexpert-row-toggle {
        margin-top: 6px;
    }

    .psychexpert-bookings-table .psychexpert-row-detail__field {
        grid-template-columns: minmax(112px, 42%) minmax(0, 1fr);
    }

    .psychexpert-bookings-table .psychexpert-row-detail__value {
        text-align: right;
    }

    .psychexpert-bookings-table .psychexpert-row-detail__field--documents {
        align-items: center;
    }

    .psychexpert-bookings-table .psychexpert-row-detail__field--documents .psychexpert-row-detail__value {
        display: flex;
        justify-content: flex-end;
    }

    .psychexpert-bookings-table .psychexpert-row-detail__field--documents .psychexpert-pdf-actions {
        display: inline-grid;
        grid-template-columns: repeat(2, minmax(44px, 44px));
        gap: 8px;
        justify-content: end;
        align-items: center;
    }

    .psychexpert-bookings-table .psychexpert-row-detail__field--documents .psychexpert-pdf-btn {
        width: 44px;
        min-width: 44px;
        height: 44px;
        padding: 0;
        justify-content: center;
        border-radius: 10px;
    }

    .psychexpert-bookings-table .psychexpert-row-detail__actions {
        gap: 8px;
    }

    .psychexpert-row-detail__value .psychexpert-amount-tax {
        display: block;
        margin-top: 2px;
    }

    .psychexpert-row-toggle {
        flex: 0 0 auto;
        margin-top: 2px;
    }

    .psychexpert-row-detail__actions {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(44px, 44px));
        justify-content: start;
        gap: 8px;
        margin-top: 10px;
        padding-top: 10px;
        border-top: 1px solid #e2e8f0;
        overflow-x: auto;
    }

    .psychexpert-row-detail__actions .psychexpert-btn,
    .psychexpert-row-detail__actions .psychexpert-badge--btn,
    .psychexpert-row-detail__actions .psychexpert-badge--cancel {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 44px;
        min-width: 44px;
        height: 44px;
        min-height: 44px;
        padding: 0;
        border-radius: 10px;
        box-sizing: border-box;
        line-height: 1;
        white-space: nowrap;
    }

    .psychexpert-row-detail__actions .psychexpert-btn {
        font-size: 0;
    }

    .psychexpert-row-detail__actions .psychexpert-btn::before {
        font-size: 18px;
        line-height: 1;
    }

    .psychexpert-row-detail__actions .psychexpert-badge--btn {
        font-size: 18px;
    }

    .psychexpert-row-detail__actions .psychexpert-badge--note {
        border-radius: 50%;
        font-size: 18px;
    }

    .psychexpert-row-detail__actions .psychexpert-badge--cancel {
        border-radius: 50%;
        font-size: 16px;
    }

     /* Status-Button: nahtlos rechts in der Slim-Row */
     .psychexpert-status-btn--slim {
         align-self: stretch;
         display: flex;
         align-items: center;
         justify-content: center;
         min-width: 48px;
         margin: -12px -14px -12px 8px;
         padding: 0 14px;
         background: #f1f5f9;
         border: none;
         border-left: 1px solid #e2e8f0;
         border-radius: 0 10px 10px 0;
         color: #475569;
         cursor: pointer;
         transition: background 0.15s ease;
         flex-shrink: 0;
     }

     .psychexpert-status-btn--slim:hover,
     .psychexpert-status-btn--slim:active {
         background: #e2e8f0;
         color: #1e293b;
     }

     .psychexpert-status-btn--slim .psychexpert-status-btn__icon {
        font-size: 18px;
        line-height: 1;
        color: #2563eb;
        font-style: normal;
        font-weight: 700;
        font-family: serif;
    }

    /* ── Storno-Positionen: volle Grid-Breite ── */
    .psychexpert-row-detail__actions > h5 {
        grid-column: 1 / -1;
        width: 100%;
        margin: 0 0 4px 0;
        font-size: 13px;
        font-weight: 600;
        color: #374151;
    }

    .psychexpert-row-detail__actions > .psychexpert-cancel-group-item {
        grid-column: 1 / -1;
        width: 100%;
        box-sizing: border-box;
        padding: 10px !important;
    }

    /* ── Cancel-Detail-Rows: untereinander, volle Breite ── */
    .psychexpert-cancel-detail__row {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
        width: 100%;
        box-sizing: border-box;
        font-size: 12px;
    }

    .psychexpert-cancel-detail__label,
    .psychexpert-cancel-detail__value {
        width: 100%;
        box-sizing: border-box;
        white-space: normal;
        font-size: 12px;
        flex: none;
    }

    .psychexpert-cancel-detail__value {
        text-align: left;
        font-weight: 600;
    }
}

@media (min-width: 768px) {
    .psychexpert-dashboard__tabs {
        flex-wrap: wrap;
        overflow-x: visible;
    }

    .psychexpert-tab {
        flex-direction: row;
    }

    .psychexpert-profile-tabs {
        flex-wrap: wrap;
        overflow-x: visible;
    }

    /* Accordion-Rows auf Desktop ausblenden – Classic-Rows übernehmen */
    .psychexpert-row-slim,
    .psychexpert-row-detail {
        display: none !important;
    }

    .psychexpert-row-classic {
        display: table-row;
    }
}

/* ============================================================
   EMAIL PREVIEW (Ende der Datei – bestehend)
   ============================================================ */

.psychexpert-email-preview__body {
    font-size: 14px;
    line-height: 1.7;
    color: var(--pe-color-text);
}

/* -----------------------------------------------------------------------------
   Responsive – Mobile First
   ----------------------------------------------------------------------------- */
@media (max-width: 768px) {
    .psychexpert-listing {
        grid-template-columns: 1fr;
    }
    .pe-form-row {
        grid-template-columns: 1fr;
    }
    .pe-tabs__tab {
        padding: 8px 14px;
        font-size: 13px;
    }
    .pe-email-editor {
        grid-template-columns: 1fr;
    }
    .pe-email-editor__list {
        display: flex;
        overflow-x: auto;
    }
    .pe-email-editor__list-item {
        border-bottom: none;
        border-right: 1px solid var(--pe-color-border);
        white-space: nowrap;
    }
    .pe-export-grid {
        grid-template-columns: 1fr;
    }
    .pe-settings-grid {
        grid-template-columns: 1fr;
    }
    .pe-provision-row__fields {
        grid-template-columns: 1fr;
    }
    .pe-filter-bar {
        flex-direction: column;
        align-items: stretch;
    }
    .pe-filter-bar .pe-field { min-width: unset; }
    .psychexpert-modal {
        padding: 16px;
    }
    .psychexpert-modal__dialog {
        width: 100%;
        max-width: 100%;
    }
    .pe-card { padding: 16px; }
    .pe-table th,
    .pe-table td { padding: 8px 10px; font-size: 13px; }
}

@media (max-width: 480px) {
    .psychexpert-card__header { flex-direction: column; align-items: flex-start; }
    .pe-tabs__nav { gap: 0; }
    .pe-tabs__tab { padding: 8px 10px; font-size: 12px; }
    .pe-btn { font-size: 13px; padding: 8px 14px; }
    .pe-btn--lg { font-size: 14px; padding: 10px 20px; }
}

/* =============================================================================
   Gutachter-Modal – Backdrop, Modal, Buchungs-Overlay, Spinner
   Mobile-first
   ============================================================================= */

/* --- Backdrop --- */
#edelweiss-expert-modal-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99998;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none;
}
#edelweiss-expert-modal-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
}

/* --- Modal --- */
#edelweiss-expert-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 99999;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
    width: min(640px, 95vw);
    max-height: 90vh;
    overflow-y: auto;
    opacity: 0;
    transition: opacity 0.2s ease;
    display: flex;
    flex-direction: column;
    pointer-events: none;
}
#edelweiss-expert-modal.is-open {
    opacity: 1;
    pointer-events: auto;
}

/* --- Schließen-Button --- */
#edelweiss-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: none;
    border: none;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    color: var(--pe-color-text-muted, #5a6475);
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.15s;
}
#edelweiss-modal-close:hover {
    background: var(--pe-color-bg, #f5f6f8);
}

/* --- Modal-Header Wrapper --- */
.edelweiss-expert-modal__header {
    background: #f0f4f8;
    border-bottom: 1px solid var(--pe-color-border, #d0d5dd);
    position: relative;
    flex-shrink: 0;
}

/* --- Header-Content --- */
#edelweiss-modal-header-content {
    padding: 20px 52px 18px 20px;
}

/* --- Inner: Bild + Info nebeneinander --- */
.edelweiss-modal-header__inner {
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

/* --- Profilbild --- */
.edelweiss-modal-header__image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
}
.edelweiss-modal-header__image--placeholder {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #dce3ec;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* --- Info-Block --- */
.edelweiss-modal-header__info {
    min-width: 0;
    padding-top: 4px;
}

/* --- Name --- */
.edelweiss-modal-header__name {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--pe-color-primary, #1a3a5c);
    margin: 0 0 3px;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- Praxisname --- */
.edelweiss-modal-header__practice {
    font-size: 0.875rem;
    color: var(--pe-color-text-muted, #5a6475);
    margin: 0 0 8px;
    line-height: 1.4;
}

/* --- Adress-Badge --- */
.edelweiss-modal-header__address {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.8rem;
    color: var(--pe-color-primary, #1a3a5c);
    background: rgba(26, 58, 92, 0.08);
    border-radius: 20px;
    padding: 3px 10px 3px 7px;
    margin: 0;
    line-height: 1.4;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.edelweiss-modal-header__address svg {
    flex-shrink: 0;
    opacity: 0.7;
}

/* --- Modal-Body (Kalender-Container) --- */
#edelweiss-modal-calendar-container {
    padding: 16px 20px;
    flex: 1;
    position: relative;
}

/* --- Teilnehmer-Step im Modal --- */
#edelweiss-modal-participants-step {
    padding: 24px 24px 16px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

#edelweiss-modal-participants-step[hidden] {
    display: none;
}

#edelweiss-modal-participants-fields {
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* Fieldset-Gruppe (eine Person) */
#edelweiss-modal-participants-fields .psychexpert-participant-group {
    border: none;
    margin: 0;
    padding: 0;
}

#edelweiss-modal-participants-fields .psychexpert-participant-group__legend {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--pe-color-dark, #1a1a2e);
    margin-bottom: 16px;
    padding: 0;
    letter-spacing: 0.01em;
}

/* Formularzeilen */
#edelweiss-modal-participants-fields .psychexpert-form-row {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 14px;
}

#edelweiss-modal-participants-fields .psychexpert-label {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--pe-color-text, #374151);
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

#edelweiss-modal-participants-fields .psychexpert-required {
    color: var(--pe-color-danger, #b71c1c);
    margin-left: 2px;
}

#edelweiss-modal-participants-fields .psychexpert-input {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #d1d5db;
    border-radius: 8px;
    font-size: 0.95rem;
    color: var(--pe-color-text, #1a1a2e);
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
    box-sizing: border-box;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

#edelweiss-modal-participants-fields .psychexpert-input:focus {
    border-color: var(--pe-color-primary, #1a3a5c);
    box-shadow: 0 0 0 3px rgba(26, 58, 92, 0.12);
}

#edelweiss-modal-participants-fields .psychexpert-input::placeholder {
    color: #9ca3af;
}

/* Fehler-Hinweis */
#edelweiss-modal-participants-error {
    margin: 4px 0 12px;
    padding: 10px 14px;
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 8px;
    color: var(--pe-color-danger, #b71c1c);
    font-size: 0.875rem;
}

#edelweiss-modal-participants-error[hidden] {
    display: none;
}

/* Aktions-Buttons */
.edelweiss-modal-participants__actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #e5e7eb;
}

.edelweiss-modal-participants__actions .psychexpert-btn {
    flex: 1;
    min-width: 120px;
    justify-content: center;
}

/* Mobile */
@media (max-width: 599px) {
    #edelweiss-modal-participants-step {
        padding: 16px 16px 12px;
    }

    .edelweiss-modal-participants__actions {
        flex-direction: column;
    }

    .edelweiss-modal-participants__actions .psychexpert-btn {
        width: 100%;
    }
}

#edelweiss-modal-error {
    padding: 8px 20px;
    color: var(--pe-color-danger, #b71c1c);
    font-size: 0.875rem;
}

/* =============================================================================
   BUCHUNGS-TAB – Badges, Link-Buttons, Info-Modals
   ============================================================================= */

/* Neue Badge-Varianten für Buchungsstatus */
.psychexpert-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 0.78rem;
    font-weight: 600;
    line-height: 1.6;
    white-space: nowrap;
    border: 1px solid transparent;
}
.psychexpert-badge--booked    { background: #e3f2fd; color: #1565c0; border-color: #bbdefb; }
.psychexpert-badge--paid      { background: #e8f5e9; color: #2e7d32; border-color: #c8e6c9; }
.psychexpert-badge--cancelled { background: #fce4ec; color: #b71c1c; border-color: #f8bbd0; }
.psychexpert-badge--refunded  { background: #f3e5f5; color: #6a1b9a; border-color: #e1bee7; }
.psychexpert-badge--grey      { background: #f5f6f8; color: #546e7a; border-color: #cfd8dc; }
.psychexpert-badge--blue      { background: #e3f2fd; color: #1565c0; border-color: #bbdefb; }
.psychexpert-badge--teal      { background: #e0f2f1; color: #00695c; border-color: #b2dfdb; }
.psychexpert-badge--green     { background: #e8f5e9; color: #2e7d32; border-color: #c8e6c9; }
.psychexpert-badge--orange    { background: #fff3e0; color: #e65100; border-color: #ffe0b2; }
.psychexpert-badge--default   { background: #f5f6f8; color: #374151; border-color: #e5e7eb; }

/* Badge als klickbarer Button (Zahlungsstatus) */
.psychexpert-badge--btn {
    cursor: pointer;
    background-color: inherit;
    font-family: inherit;
    transition: filter 0.15s;
}
.psychexpert-badge--btn:hover { filter: brightness(0.92); }
.psychexpert-badge--btn:focus-visible {
    outline: 2px solid var(--pe-color-primary, #1a3a5c);
    outline-offset: 2px;
}

.psychexpert-badge--note {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #fff;
    color: var(--pe-color-primary, #1a3a5c);
    border: 1px solid currentColor;
    padding: 0;
    line-height: 1;
    font-size: 14px;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    vertical-align: middle;
}

.psychexpert-badge--note:hover {
    background: #eff6ff;
    color: #1d4ed8;
}

.psychexpert-badge--note.psychexpert-badge--note--active {
    background: #eff6ff;
    color: #1d4ed8;
    border-color: #1d4ed8;
}

.psychexpert-badge--note:focus-visible {
    outline: 2px solid var(--pe-color-primary, #1a3a5c);
    outline-offset: 2px;
}

/* Storno-Badge-Button (roter Kreis mit weißem S) */
.psychexpert-badge--cancel {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #dc2626;
    color: #fff;
    font-weight: 700;
    font-size: 14px;
    border: none;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    transition: background 0.15s;
    vertical-align: middle;
}
.psychexpert-badge--cancel:hover { background: #b91c1c; }
.psychexpert-badge--cancel:focus-visible {
    outline: 2px solid #dc2626;
    outline-offset: 2px;
}

/* Link-Button (Teilnehmername, Kursdatum) */
.psychexpert-link-btn {
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    font: inherit;
    color: var(--pe-color-primary, #1a3a5c);
    text-decoration: underline;
    text-underline-offset: 2px;
    cursor: pointer;
    font-size: 0.9rem;
}
.psychexpert-link-btn:hover { color: var(--pe-color-accent, #2563eb); }
.psychexpert-link-btn:focus-visible {
    outline: 2px solid var(--pe-color-primary, #1a3a5c);
    outline-offset: 2px;
    border-radius: 2px;
}

/* Verschieben-Button (Terminverschiebung) */
.psychexpert-link-btn--reschedule {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: 1px solid var(--pe-color-primary, #1a3a5c);
    border-radius: 4px;
    color: var(--pe-color-primary, #1a3a5c);
    font-size: 1rem;
    line-height: 1;
    padding: 2px 6px;
    margin-left: 6px;
    text-decoration: none;
    cursor: pointer;
    opacity: 0.75;
    transition: opacity 0.15s, background 0.15s, color 0.15s;
    vertical-align: middle;
}
.psychexpert-link-btn--reschedule:hover {
    background: var(--pe-color-primary, #1a3a5c);
    color: #fff;
    opacity: 1;
}
.psychexpert-link-btn--reschedule:focus-visible {
    outline: 2px solid var(--pe-color-primary, #1a3a5c);
    outline-offset: 2px;
    border-radius: 4px;
    opacity: 1;
}

/* Info-Modal (Teilnehmer / Kurstermin / Zahlung) */
.psychexpert-info-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}
.psychexpert-info-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    cursor: pointer;
}
.psychexpert-info-modal__box {
    position: relative;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
    padding: 28px 32px 24px;
    min-width: 300px;
    max-width: 480px;
    width: 90%;
    z-index: 1;
}
.psychexpert-info-modal__title {
    margin: 0 0 16px;
    font-size: 1rem;
    font-weight: 700;
    color: var(--pe-color-text, #1a1a2e);
    padding-right: 28px;
}
.psychexpert-info-modal__close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    font-size: 1.1rem;
    cursor: pointer;
    color: #6b7280;
    line-height: 1;
    padding: 4px;
    border-radius: 4px;
}
.psychexpert-info-modal__close:hover { color: var(--pe-color-text, #1a1a2e); }

/* Definition List im Modal */
.psychexpert-info-modal__dl {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 6px 16px;
    margin: 0 0 12px;
    font-size: 0.9rem;
}
.psychexpert-info-modal__dl + .psychexpert-info-modal__dl {
    border-top: 1px solid #e5e7eb;
    padding-top: 12px;
}
.psychexpert-info-modal__dl dt {
    font-weight: 600;
    color: #6b7280;
    white-space: nowrap;
}
.psychexpert-info-modal__dl dd {
    margin: 0;
    color: var(--pe-color-text, #1a1a2e);
    word-break: break-word;
}

/* Body-Scroll sperren wenn Modal offen */
body.psychexpert-modal-open { overflow: hidden; }

.psychexpert-info-modal__actions {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 8px;
    margin-top: 16px;
}
.psychexpert-info-modal__actions .psychexpert-btn {
    flex: 1 1 auto;
    justify-content: center;
    width: auto;
    min-width: 0;
}

@media (max-width: 599px) {
    .psychexpert-info-modal__box {
        padding: 20px 18px 18px;
    }
}

/* --- Buchungs-Overlay (innerhalb des Modals) --- */
#edelweiss-booking-overlay[hidden] {
    display: none;
}
#edelweiss-booking-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.85);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    border-radius: 8px;
}
.edelweiss-booking-overlay__spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #e0e0e0;
    border-top-color: var(--pe-color-primary, #1a3a5c);
    border-radius: 50%;
    animation: edelweiss-spin 0.8s linear infinite;
}
@keyframes edelweiss-spin {
    to { transform: rotate(360deg); }
}
#edelweiss-booking-overlay p {
    font-size: 0.9rem;
    color: var(--pe-color-text, #1a1a2e);
    margin: 0;
}

/* --- Lade-Spinner im Kalender-Container --- */
#edelweiss-modal-spinner {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 32px;
}
.edelweiss-modal-spinner__icon {
    width: 36px;
    height: 36px;
    border: 4px solid #e0e0e0;
    border-top-color: var(--pe-color-primary, #1a3a5c);
    border-radius: 50%;
    animation: edelweiss-spin 0.8s linear infinite;
}

/* --- Mobile Anpassungen für Modal --- */
@media (max-width: 599px) {
    .psychexpert-modal {
        width: 100%;
        max-width: 100%;
        margin: 0;
        border-radius: 16px 16px 0 0;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
    }

    .psychexpert-modal-overlay {
        backdrop-filter: blur(2px);
    }

    #edelweiss-expert-modal {
        width: 100vw;
        height: 100dvh;
        max-height: 100dvh;
        border-radius: 0;
        top: 0;
        left: 0;
        transform: none;
        overflow-y: auto;
    }

    /* Backdrop auf Mobile ausblenden – Modal ist bereits Vollbild */
    #edelweiss-expert-modal-backdrop {
        display: none;
    }

    /* Schließen-Button auf Mobile besser erreichbar */
    #edelweiss-modal-close {
        top: 10px;
        right: 10px;
        font-size: 1.75rem;
        padding: 6px 10px;
        background: rgba(0, 0, 0, 0.06);
        border-radius: 50%;
    }

    #edelweiss-modal-header-content {
        padding: 14px 48px 14px 14px;
    }
    #edelweiss-modal-calendar-container {
        padding: 12px 16px;
    }
    .edelweiss-modal-header__image,
    .edelweiss-modal-header__image--placeholder {
        width: 60px;
        height: 60px;
    }
    .edelweiss-modal-header__name {
        font-size: 1rem;
    }
    .edelweiss-modal-header__address {
        font-size: 0.75rem;
    }
}


/* Login-Hinweis im Teilnehmerdaten-Formular */
.psychexpert-login-hint {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
    padding: 10px 14px;
    background: #f0f6ff;
    border: 1px solid #b3d0f5;
    border-radius: 6px;
    font-size: 13px;
    line-height: 1.5;
    color: #1a3a5c;
}

.psychexpert-login-hint[hidden] {
    display: none;
}

.psychexpert-hint-icon {
    font-size: 16px;
    flex-shrink: 0;
}

.psychexpert-hint-login-link {
    background: none;
    border: none;
    padding: 0;
    font: inherit;
    color: #1a6bbf;
    font-weight: 600;
    text-decoration: underline;
    white-space: nowrap;
    cursor: pointer;
}

.psychexpert-hint-login-link:hover {
    color: #0d4a8a;
}

.psychexpert-hint-sep {
    color: #999;
}

.psychexpert-hint-skip-btn {
    background: none;
    border: none;
    padding: 0;
    font-size: 13px;
    color: #666;
    cursor: pointer;
    text-decoration: underline;
    text-decoration-style: dotted;
}

.psychexpert-hint-skip-btn:hover {
    color: #333;
}


/* =============================================================================
   LOGIN-OVERLAY (innerhalb des Buchungs-Modals)
   ============================================================================= */

#edelweiss-login-overlay {
    position: absolute;
    inset: 0;
    z-index: 10;
    background: rgba(255, 255, 255, 0.97);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: inherit;
    padding: 24px;
}

#edelweiss-login-overlay[hidden] {
    display: none;
}

.edelweiss-login-overlay__inner {
    width: 100%;
    max-width: 380px;
}

.edelweiss-login-overlay__title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--pe-color-primary, #1a3a5c);
    margin: 0 0 20px 0;
    line-height: 1.3;
}

.edelweiss-login-overlay__field {
    margin-bottom: 14px;
}

.edelweiss-login-overlay__label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 5px;
}

.edelweiss-login-overlay__input {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #c8d6e5;
    border-radius: 6px;
    font-size: 14px;
    color: #1a3a5c;
    background: #fff;
    box-sizing: border-box;
    transition: border-color 0.15s;
}

.edelweiss-login-overlay__input:focus {
    outline: none;
    border-color: #1a6bbf;
    box-shadow: 0 0 0 3px rgba(26, 107, 191, 0.12);
}

.edelweiss-login-overlay__error {
    margin-bottom: 12px;
    padding: 9px 12px;
    background: #fff0f0;
    border: 1px solid #f5c6c6;
    border-radius: 6px;
    font-size: 13px;
    color: #c0392b;
}

.edelweiss-login-overlay__error[hidden] {
    display: none;
}

.edelweiss-login-overlay__actions {
    display: flex;
    gap: 10px;
    margin-top: 18px;
}

.edelweiss-login-overlay__actions .psychexpert-btn {
    flex: 1;
}

.edelweiss-login-overlay__spinner {
    margin-top: 12px;
    height: 3px;
    background: linear-gradient(90deg, #1a6bbf 0%, #5ba3f5 50%, #1a6bbf 100%);
    background-size: 200% 100%;
    border-radius: 2px;
    animation: edelweiss-login-progress 1.2s linear infinite;
}

.edelweiss-login-overlay__spinner[hidden] {
    display: none;
}

@keyframes edelweiss-login-progress {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}


/* =============================================================================
   KARTEN-POPUP
   ============================================================================= */

.edelweiss-map-popup {
    min-width: 200px;
    font-size: 0.875rem;
    line-height: 1.5;
}
.edelweiss-map-popup__name {
    display: block;
    font-size: 1rem;
    font-weight: 700;
    color: var(--pe-color-primary, #1a3a5c);
    margin-bottom: 2px;
}
.edelweiss-map-popup__practice {
    display: block;
    color: var(--pe-color-text-muted, #5a6475);
    font-size: 0.8rem;
    margin-bottom: 2px;
}
.edelweiss-map-popup__price {
    display: block;
    font-size: 0.8rem;
    font-weight: 700;
    color: #2b2b2b;
    background: #dbde38;
    border-radius: 4px;
    padding: 3px 7px;
    margin-bottom: 5px;
    text-align: center;
}
.edelweiss-map-popup__address {
    display: block;
    color: #444;
    margin-bottom: 8px;
    font-size: 0.8rem;
}
.edelweiss-map-popup__availability {
    display: block;
    font-size: 0.78rem;
    color: var(--pe-color-primary, #1a3a5c);
    background: rgba(26, 58, 92, 0.07);
    border-radius: 12px;
    padding: 3px 8px;
    margin-bottom: 10px;
}
.edelweiss-map-popup__availability--none {
    color: #888;
    background: rgba(0, 0, 0, 0.05);
}
.edelweiss-map-popup__btn {
    display: block;
    width: 100%;
    padding: 7px 12px;
    background: var(--pe-color-primary, #1a3a5c);
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    transition: background 0.15s;
}
.edelweiss-map-popup__btn:hover {
    background: var(--pe-color-primary-dark, #122840);
}
.edelweiss-map-popup__website {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 8px;
    font-size: 0.8rem;
    color: var(--pe-color-primary, #1a3a5c);
    text-decoration: none;
    border-bottom: 1px solid rgba(26, 58, 92, 0.3);
    transition: color 0.15s, border-color 0.15s;
}
.edelweiss-map-popup__website:hover {
    color: var(--pe-color-primary-dark, #122840);
    border-bottom-color: var(--pe-color-primary-dark, #122840);
}
.edelweiss-map-popup__website svg {
    flex-shrink: 0;
    opacity: 0.75;
}

/* Website-Link in der Gutachterzeile */
.edelweiss-expert-row__website {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--pe-color-primary, #1a3a5c);
    text-decoration: none;
    border-bottom: 1px solid rgba(26, 58, 92, 0.3);
    transition: color 0.15s, border-color 0.15s;
    position: relative;
    z-index: 1;
    white-space: nowrap;
}
.edelweiss-expert-row__website:hover {
    color: var(--pe-color-primary-dark, #122840);
    border-bottom-color: var(--pe-color-primary-dark, #122840);
}
.edelweiss-expert-row__website svg {
    flex-shrink: 0;
    opacity: 0.75;
}

/* =============================================================================
   ZAHLUNGSMETHODEN-ICONS & STORNO-BADGE
   ============================================================================= */

.psychexpert-pay-icons {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
    flex-wrap: wrap;
}

.psychexpert-pay-icon {
    height: 20px;
    width: auto;
    object-fit: contain;
    border-radius: 3px;
    opacity: 0.85;
    transition: opacity 0.15s;
}

.psychexpert-pay-icon:hover {
    opacity: 1;
}

/* Popup: Zahlungszeile */
.edelweiss-map-popup__payment {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    margin-top: 6px;
    margin-bottom: 4px;
}

/* Popup: Terminverfügbarkeits-Block */
.edelweiss-map-popup__avail-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: 6px;
    margin-bottom: 4px;
}

.edelweiss-map-popup__avail-label {
    font-size: 10px;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.edelweiss-map-popup__payment-label {
    font-size: 10px;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.edelweiss-map-popup__payment-icons {
    display: flex;
    align-items: center;
    gap: 6px;
}

/* Popup: Kontaktblock (Profil-Zugang ohne Buchung) */
.edelweiss-map-popup__contact-block {
    display: flex;
    flex-direction: column;
    gap: 3px;
    margin-top: 6px;
    margin-bottom: 4px;
}

.edelweiss-map-popup__contact-text {
    font-size: 12px;
    color: #444;
}

.edelweiss-map-popup__phone {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    color: #555;
}

/* Popup: Storno-Block */
.edelweiss-map-popup__cancel {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
    margin-bottom: 8px;
    font-size: 12px;
    color: #555;
}

.edelweiss-map-popup__cancel-label {
    font-size: 11px;
    color: #888;
    white-space: nowrap;
}

/* Storno-Badge */
.psychexpert-cancel-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 5px;
    font-size: 11px;
    color: #666;
    background: #f5f5f5;
    border-radius: 4px;
    padding: 2px 7px 2px 5px;
    border: 1px solid #e0e0e0;
    white-space: nowrap;
}

.psychexpert-cancel-badge svg {
    flex-shrink: 0;
    color: #999;
}

/* Listenzeile: Zahlungs- und Storno-Block */
/* Listenzeile: Terminverfügbarkeits-Label */
.edelweiss-expert-row__avail-label {
    display: block;
    font-size: 10px;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 4px;
}

.edelweiss-expert-row__payment-label {
    display: block;
    font-size: 10px;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 4px;
}

.edelweiss-expert-row__payment {
    margin-top: 0;
}

.edelweiss-expert-row__cancel {
    margin-top: 4px;
}

/* Listenzeile: Kontaktblock (Profil-Zugang ohne Buchung) */
.edelweiss-expert-row__contact-text {
    display: block;
    font-size: 13px;
    color: #444;
}

.edelweiss-expert-row__phone {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
    color: #555;
    margin-top: 3px;
}

/* Icon im Zahlungsmethoden-Modal (Buchungs-Tab) */
.psychexpert-payment-icon {
    height: 1em;
    width: auto;
    object-fit: contain;
    vertical-align: middle;
    margin-right: 4px;
}

/* Status-Button (einzelner Button ersetzt drei Status-Icons) */
.psychexpert-status-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 10px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    cursor: pointer;
    color: #475569;
    font-size: 13px;
    transition: background 0.15s ease, color 0.15s ease;
    min-height: 36px;
    min-width: 36px;
}
.psychexpert-status-btn:hover {
    background: #e2e8f0;
    color: #1e293b;
}
.psychexpert-status-btn__icon {
    font-size: 18px;
    line-height: 1;
    color: #2563eb;
    font-style: normal;
    font-weight: 700;
    font-family: serif;
}

/* ==========================================================================
   Facts & Figures – Cards & Summary
   ========================================================================== */

.psychexpert-info-box {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .75rem 1rem;
    border-radius: 6px;
    font-size: .9rem;
    line-height: 1.4;
}
.psychexpert-info-box--success {
    background: #edf7ed;
    border: 1px solid #4caf50;
    color: #2e7d32;
}
.psychexpert-info-box--neutral {
    background: #f5f5f5;
    border: 1px solid #bdbdbd;
    color: #616161;
}
.psychexpert-info-box--warning {
    background: #fff8e1;
    border: 1px solid #f9a825;
    color: #7a5800;
}

.psychexpert-facts-summary__title {
    display: flex;
    align-items: center;
    gap: .4rem;
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 .75rem;
}

.psychexpert-facts-summary__loading {
    display: flex;
    align-items: center;
    gap: .5rem;
    color: #757575;
    font-size: .9rem;
}

.psychexpert-facts-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
}

.psychexpert-facts-card {
    display: flex;
    flex-direction: column;
    gap: .25rem;
    padding: 1rem;
    background: #fafafa;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
}
.psychexpert-facts-card--total {
    background: #e8f5e9;
    border-color: #4caf50;
}

.psychexpert-facts-card__label {
    font-size: .8rem;
    color: #757575;
    text-transform: uppercase;
    letter-spacing: .03em;
}
.psychexpert-facts-card__value {
    font-size: .9rem;
    color: #424242;
}
.psychexpert-facts-card__amount {
    font-size: 1.25rem;
    font-weight: 700;
    color: #212121;
}
.psychexpert-facts-card--total .psychexpert-facts-card__amount {
    color: #2e7d32;
}
.psychexpert-facts-card--fees .psychexpert-facts-card__amount {
    color: #c0392b;
}
.psychexpert-facts-card--cancellation {
    border-left: 3px solid #e67e22;
}
.psychexpert-facts-card--cancellation .psychexpert-facts-card__amount {
    color: #e67e22;
}

.psychexpert-text--muted {
    color: #9e9e9e;
    font-size: .9rem;
}

.psychexpert-spin {
    animation: pe-spin .7s linear infinite;
}

/* ==========================================================================
   RNR Pos – Badge-Button & Modal
   ========================================================================== */

.edelweiss-rnr-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 12px;
    padding: 2px 10px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.6;
    white-space: nowrap;
    transition: background 0.15s;
    user-select: none;
}

.edelweiss-rnr-badge:hover {
    background: #005a87;
}

.edelweiss-rnr-modal-overlay {
    display: none !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 999999 !important;
    background: rgba(0, 0, 0, 0.45) !important;
    align-items: center;
    justify-content: center;
    margin: 0 !important;
    padding: 0 !important;
    transform: none !important;
}

.edelweiss-rnr-modal-overlay.is-open {
    display: flex !important;
}

.edelweiss-rnr-modal {
    background: #fff !important;
    border-radius: 10px !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.22) !important;
    padding: 24px 28px 20px !important;
    min-width: 280px !important;
    max-width: 380px !important;
    width: 100% !important;
    position: relative !important;
    margin: auto !important;
    animation: edelweiss-rnr-fadein 0.15s ease;
}

@keyframes edelweiss-rnr-fadein {
    from { opacity: 0; transform: translateY(-10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.edelweiss-rnr-modal__title {
    font-size: 15px;
    font-weight: 700;
    color: #1d2327;
    margin: 0 0 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e0e0e0;
}

.edelweiss-rnr-modal__row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
    font-size: 13px;
}

.edelweiss-rnr-modal__row:last-child {
    border-bottom: none;
}

.edelweiss-rnr-modal__label {
    color: #555;
    flex: 0 0 auto;
    max-width: 50%;
    line-height: 1.4;
    padding-top: 1px;
    text-align: left;
}

.edelweiss-rnr-modal__value-block {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 3px;
    flex: 1 1 auto;
    min-width: 0;
    text-align: right;
}

.edelweiss-rnr-modal__value {
    font-weight: 600;
    color: #1d2327;
    white-space: nowrap;
    text-align: right;
}

.edelweiss-rnr-modal__sub {
    display: flex;
    justify-content: flex-end;
}

.edelweiss-rnr-modal__tax-info {
    font-size: 11px;
    color: #6b7280;
    font-weight: 400;
    white-space: nowrap;
}

.edelweiss-rnr-modal__close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    color: #888;
    padding: 0;
}

.edelweiss-rnr-modal__close:hover {
    color: #1d2327;
}

.edelweiss-rnr-bearer {
    display: inline-block;
    font-size: 0.75em;
    font-weight: 600;
    padding: 1px 6px;
    border-radius: 3px;
    white-space: nowrap;
}
.edelweiss-rnr-bearer--deduct {
    background: #fee2e2;
    color: #dc2626;
}
.edelweiss-rnr-bearer--credit {
    background: #dcfce7;
    color: #16a34a;
}
.edelweiss-rnr-bearer--platform {
    background: #f1f5f9;
    color: #64748b;
}
.edelweiss-rnr-modal__row--header {
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 8px;
    margin-bottom: 4px;
    font-weight: 600;
}

/* Referenzzeile: originaler Buchungspreis bei Storno */
.edelweiss-rnr-modal__row--reference {
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 8px;
    margin-bottom: 4px;
    opacity: 0.65;
    font-style: italic;
}

.edelweiss-rnr-modal__row--reference .edelweiss-rnr-modal__label {
    color: #6b7280;
    font-weight: 400;
}

.edelweiss-rnr-modal__row--reference .edelweiss-rnr-modal__value {
    color: #6b7280;
    font-weight: 400;
}

@media (max-width: 600px) {
    .edelweiss-rnr-modal-overlay {
        align-items: flex-end !important;
    }

    .edelweiss-rnr-modal {
        max-width: 100% !important;
        width: 100% !important;
        border-radius: 16px 16px 0 0 !important;
        padding: 20px 20px 32px !important;
        margin: 0 !important;
        max-height: 85vh;
        overflow-y: auto;
    }

    .edelweiss-rnr-modal__close {
        top: 14px;
        right: 16px;
        font-size: 24px;
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: #f3f4f6;
        border-radius: 50%;
        color: #374151;
    }

    .edelweiss-rnr-modal__title {
        font-size: 16px;
        padding-right: 40px;
    }

    .edelweiss-rnr-modal__label {
        max-width: 55%;
    }
}
.psychexpert-badge--cart {
    display: inline-block;
    font-size: 1.1em;
    cursor: default;
    opacity: 0.85;
}
/* Status-Badges im Verrechnungstab – saubere vertikale Liste ohne Überlappung */
.psychexpert-facts-status-badges {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
}

/* Grundverhalten für alle Badges im Container */
.psychexpert-facts-status-badges > .psychexpert-meta-badge {
    position: relative;
    white-space: nowrap;
}

/* Zweiter Badge: kein negativer Margin – saubere Liste */
.psychexpert-facts-status-badges > .psychexpert-meta-badge:nth-child(2) {
    margin-top: 0;
    margin-left: 0;
    z-index: auto;
    box-shadow: none;
}

/* =========================================================
   PDF-Aktionen Widget – Verrechnungstab
   ========================================================= */

.psychexpert-pdf-actions {
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: flex-start;
}

.psychexpert-pdf-actions__group {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: nowrap;
}

.psychexpert-pdf-actions__label {
    font-size: 11px;
    font-weight: 600;
    color: #374151;
    white-space: nowrap;
    margin-right: 4px;
    line-height: 1.2;
}

.psychexpert-pdf-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    background: #f9fafb;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
    flex-shrink: 0;
}

.psychexpert-pdf-btn:hover {
    background: #e5e7eb;
    border-color: #9ca3af;
}

.psychexpert-pdf-btn__icon {
    width: 16px;
    height: 16px;
    object-fit: contain;
    display: block;
}

.psychexpert-pdf-btn__send-icon {
    font-size: 14px;
    line-height: 1;
}
/* =========================================================
   PE Pagination
   ========================================================= */

.pe-pagination {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
    margin: 16px 0;
    font-size: 13px;
}

.pe-pagination__per-page {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-right: 12px;
}

.pe-pagination__per-page label {
    color: #555;
    white-space: nowrap;
}

.pe-pagination__per-page select {
    padding: 4px 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 13px;
    cursor: pointer;
    background: #fff;
}

.pe-pagination__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    color: #333;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
    line-height: 1;
}

.pe-pagination__btn:hover:not(:disabled) {
    background: #f0f0f0;
    border-color: #999;
}

.pe-pagination__btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.pe-pagination__btn.is-active {
    background: #2271b1;
    border-color: #2271b1;
    color: #fff;
    font-weight: 600;
    pointer-events: none;
}

.pe-pagination__btn--edge {
    background: #f6f7f7;
    border-color: #aaa;
    font-weight: 600;
    font-size: 11px;
    letter-spacing: 0.5px;
}

.pe-pagination__btn--edge:hover:not(:disabled) {
    background: #e0e0e0;
}

.pe-pagination__ellipsis {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    color: #888;
    font-size: 14px;
    user-select: none;
}

.pe-pagination__info {
    margin-left: 8px;
    color: #666;
    white-space: nowrap;
}

/* ── PE Pagination – Mobile ─────────────────────────────────────────────── */
@media (max-width: 600px) {
    .pe-pagination {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .pe-pagination__nav {
        display: flex;
        align-items: center;
        justify-content: center;
        flex-wrap: wrap;
        gap: 6px;
        order: 1;
    }

    .pe-pagination__meta {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
        order: 2;
        padding-top: 4px;
        border-top: 1px solid #eee;
    }

    .pe-pagination__per-page {
        margin-right: 0;
        flex-shrink: 0;
    }

    .pe-pagination__info {
        margin-left: 0;
        font-size: 12px;
        color: #888;
    }

    .pe-pagination__btn--edge {
        display: none;
    }

    .pe-pagination__btn {
        min-width: 40px;
        height: 40px;
        font-size: 14px;
    }

    .pe-pagination__ellipsis {
        height: 40px;
        min-width: 24px;
    }
}

/* ==========================================================================
   Verrechnungssimulator – billing-sim-*
   ========================================================================== */

/* ── Badge-Buttons ────────────────────────────────────────────────────────── */
.billing-sim__badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 16px;
    border: 1.5px solid var(--pe-color-border);
    border-radius: 999px;
    background: var(--pe-color-bg-card);
    color: var(--pe-color-text-muted);
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.4;
    letter-spacing: 0.01em;
    transition: background 0.18s, border-color 0.18s, color 0.18s, box-shadow 0.18s;
    user-select: none;
    box-shadow: 0 1px 3px rgba(0,0,0,.06);
}
.billing-sim__badge:hover:not(:disabled) {
    box-shadow: 0 2px 6px rgba(0,0,0,.10);
    border-color: var(--pe-color-primary);
    color: var(--pe-color-primary);
}

/* Zahlungsort-Gruppe: Blau-Pastell-Nuancen */
.billing-sim__badge[data-group="payment-mode"][data-value="platform"] {
    background: var(--bs-pay-bg-online);
    border-color: var(--bs-pay-border-online);
    color: var(--bs-pay-text-online);
}
.billing-sim__badge[data-group="payment-mode"][data-value="onsite"] {
    background: var(--bs-pay-bg-onsite);
    border-color: var(--bs-pay-border-onsite);
    color: var(--bs-pay-text-onsite);
}
.billing-sim__badge[data-group="payment-mode"][data-value="flexible"] {
    background: var(--bs-pay-bg-flexible);
    border-color: var(--bs-pay-border-flex);
    color: var(--bs-pay-text-flex);
}
.billing-sim__badge[data-group="payment-mode"].billing-sim__badge--active {
    filter: brightness(0.88) saturate(1.2);
    box-shadow: 0 2px 8px rgba(30,64,175,.18);
    font-weight: 700;
    border-width: 2px;
}

/* Buchungstyp-Gruppe: Grün/Gelb/Rot-Pastell-Nuancen */
.billing-sim__badge[data-group="booking-type"][data-value="normal"] {
    background: var(--bs-book-bg-normal);
    border-color: var(--bs-book-border-normal);
    color: var(--bs-book-text-normal);
}
.billing-sim__badge[data-group="booking-type"][data-value="cancel_within"] {
    background: var(--bs-book-bg-within);
    border-color: var(--bs-book-border-within);
    color: var(--bs-book-text-within);
}
.billing-sim__badge[data-group="booking-type"][data-value="cancel_outside"] {
    background: var(--bs-book-bg-outside);
    border-color: var(--bs-book-border-outside);
    color: var(--bs-book-text-outside);
}
.billing-sim__badge[data-group="booking-type"].billing-sim__badge--active {
    filter: brightness(0.86) saturate(1.3);
    box-shadow: 0 2px 8px rgba(0,0,0,.13);
    font-weight: 700;
    border-width: 2px;
}

/* Storno-Untergruppen: Salbei-Pastell */
.billing-sim__badge[data-group="cancel-refund"],
.billing-sim__badge[data-group="cancel-handler"] {
    background: var(--bs-sub-bg);
    border-color: var(--bs-sub-border);
    color: var(--bs-sub-text);
    font-size: 0.82rem;
    padding: 5px 13px;
}
.billing-sim__badge[data-group="cancel-refund"].billing-sim__badge--active,
.billing-sim__badge[data-group="cancel-handler"].billing-sim__badge--active {
    filter: brightness(0.84) saturate(1.3);
    box-shadow: 0 2px 6px rgba(0,0,0,.10);
    font-weight: 700;
    border-width: 2px;
}

/* Fallback: aktiver Zustand ohne Gruppenfarbe */
.billing-sim__badge--active {
    font-weight: 700;
    border-width: 2px;
}
.billing-sim__badge--disabled {
    opacity: 0.40;
    cursor: not-allowed;
    pointer-events: none;
    filter: grayscale(0.4);
}

/* Rückwärtskompatibilität: alte Klasse billing-sim-badge */
.billing-sim-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 16px;
    border: 1.5px solid var(--pe-color-border);
    border-radius: 999px;
    background: var(--pe-color-bg-card);
    color: var(--pe-color-text-muted);
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.4;
    transition: background 0.18s, border-color 0.18s, color 0.18s;
    user-select: none;
}
.billing-sim-badge--active {
    background: var(--pe-color-primary);
    border-color: var(--pe-color-primary);
    color: #fff;
    font-weight: 700;
}
.billing-sim-badge--disabled {
    opacity: 0.40;
    cursor: not-allowed;
    pointer-events: none;
}

/* ── Badge-Gruppen ────────────────────────────────────────────────────────── */
.billing-sim__group {
    margin-bottom: 24px;
}
.billing-sim__badge-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

/* Buchungstyp-Gruppe: kein extra Abstand nötig, da .billing-sim__group bereits 24px hat */
#billing-sim-group-booking-type {
    margin-bottom: 24px;
}
.billing-sim__group-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--pe-color-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 6px;
}

/* ── Gateway-Checkboxen ───────────────────────────────────────────────────── */
.billing-sim__gateway-group {
    margin-bottom: 12px;
}
.billing-sim__gateway-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    margin-right: 16px;
}

/* ── Storno-Einstellungen (aufklappbar) ───────────────────────────────────── */
.billing-sim-storno {
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.25s ease;
}
.billing-sim-storno--open {
    max-height: 600px;
    opacity: 1;
    margin-bottom: 24px;
}
.billing-sim-storno__inner {
    border: 1px solid var(--pe-color-border);
    border-radius: 6px;
    padding: 14px 16px;
    background: var(--pe-color-bg);
    margin-bottom: 14px;
}
.billing-sim-storno__row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}
.billing-sim-storno__row:last-child {
    margin-bottom: 0;
}
.billing-sim-storno__row label {
    min-width: 160px;
    font-size: 0.875rem;
    color: var(--pe-color-text-muted);
}
.billing-sim-storno__input {
    width: 80px;
    padding: 4px 8px;
    border: 1px solid var(--pe-color-border);
    border-radius: 4px;
    font-size: 0.875rem;
}

/* ── Hinweis-Text (Intro-Bereich) ────────────────────────────────────────── */
.billing-sim__notice {
    font-size: 0.875rem;
    color: var(--pe-color-text-muted);
    border-left: 3px solid var(--pe-color-border);
    padding: 6px 12px;
    background: var(--pe-color-bg);
    border-radius: 0 4px 4px 0;
    line-height: 1.5;
}

/* ── Gruppen-Hinweistext (unterhalb Gruppen-Label) ───────────────────────── */
.billing-sim__group-hint {
    font-size: 0.8rem;
    color: var(--pe-color-text-muted);
    margin: 2px 0 8px;
    line-height: 1.45;
}

/* ── Read-only Admin-Hinweise ─────────────────────────────────────────────── */
.billing-sim__readonly-info {
    border: 1px solid var(--pe-color-border);
    border-radius: 6px;
    padding: 10px 14px;
    background: var(--pe-color-bg);
    margin-top: 24px;
    margin-bottom: 14px;
    font-size: 0.85rem;
    color: var(--pe-color-text-muted);
}
.billing-sim__readonly-info dl {
    margin: 0;
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 2px 12px;
}
.billing-sim__readonly-info dt {
    font-weight: 600;
    white-space: nowrap;
}
.billing-sim__readonly-info dd {
    margin: 0;
}
.billing-sim__readonly-hint {
    font-size: 0.78rem;
    color: var(--pe-color-neutral);
    margin-top: 6px;
}

/* ── Aktions-Buttons ──────────────────────────────────────────────────────── */
.billing-sim__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
    margin-bottom: 4px;
}
.billing-sim-save {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    background: var(--pe-color-primary);
    color: #fff;
    border: 1px solid var(--pe-color-primary);
    border-radius: 5px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}
.billing-sim-save:hover:not(:disabled) {
    background: var(--pe-color-primary-lt);
    border-color: var(--pe-color-primary-lt);
}
.billing-sim-save:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}
.billing-sim-reset {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    background: var(--pe-color-bg-card);
    color: var(--pe-color-text);
    border: 1px solid var(--pe-color-border);
    border-radius: 5px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
}
.billing-sim-reset:hover {
    background: var(--pe-color-bg);
    border-color: var(--pe-color-primary);
}

/* ── Feedback-Meldung ─────────────────────────────────────────────────────── */
.billing-sim__feedback {
    min-height: 1.4em;
    font-size: 0.875rem;
    margin: 6px 0 0;
    padding: 0;
}
.billing-sim__feedback--success {
    color: var(--pe-color-success);
}
.billing-sim__feedback--error {
    color: var(--pe-color-danger);
}

/* ── Erklärungstext ───────────────────────────────────────────────────────── */
.billing-sim-explanation {
    border-left: 3px solid var(--pe-color-accent);
    background: var(--pe-color-bg);
    padding: 10px 14px;
    border-radius: 0 5px 5px 0;
    font-size: 0.9rem;
    line-height: 1.55;
    margin-bottom: 18px;
    color: var(--pe-color-text);
}
.billing-sim-explanation:empty {
    display: none;
}

/* ── Akkordeon ────────────────────────────────────────────────────────────── */
.billing-sim__accordion {
    margin-bottom: 16px;
}
.billing-sim__accordion-item {
    border: 1px solid var(--pe-color-border);
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 8px;
    background: var(--pe-color-bg-card);
}
.billing-sim__accordion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    background: var(--pe-color-primary);
    color: #fff;
    font-weight: 700;
    font-size: 0.875rem;
    padding: 10px 14px;
    border: none;
    cursor: pointer;
    text-align: left;
    gap: 12px;
    letter-spacing: 0.02em;
    transition: background 0.15s;
}
.billing-sim__accordion-header:hover {
    background: var(--pe-color-primary-dark, #2a5a8a);
}
.billing-sim__accordion-title {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.billing-sim__accordion-summary {
    flex: 0 0 auto;
    font-size: 0.85rem;
    font-weight: 400;
    white-space: nowrap;
    opacity: 0.92;
}
.billing-sim__accordion-summary strong {
    font-weight: 700;
}
.billing-sim__accordion-icon {
    flex: 0 0 auto;
    font-style: normal;
    font-size: 0.75rem;
    transition: transform 0.25s;
}
.billing-sim__accordion-icon::before {
    content: '\25B6';
}
.billing-sim__accordion-header[aria-expanded="true"] .billing-sim__accordion-icon {
    transform: rotate(90deg);
}
.billing-sim__accordion-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}
.billing-sim__accordion-body[aria-hidden="false"] {
    max-height: 2000px;
}

/* ── Dokumentvorschau ─────────────────────────────────────────────────────── */
.billing-sim-doc {
    background: var(--pe-color-bg-card);
}
.billing-sim-doc__table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}
.billing-sim-doc__row td {
    padding: 6px 14px;
    border-bottom: 1px solid var(--pe-color-bg);
}
.billing-sim-doc__row:last-child td {
    border-bottom: none;
}
.billing-sim-doc__label {
    color: var(--pe-color-text);
    width: 65%;
}
.billing-sim-doc__value {
    text-align: right;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}
.billing-sim-doc__row--sub td {
    padding-left: 28px;
    font-size: 0.82rem;
    color: var(--pe-color-text-muted);
}
.billing-sim-doc__row--total td {
    border-top: 2px solid var(--pe-color-border);
    font-weight: 700;
    padding-top: 8px;
    padding-bottom: 8px;
}
.billing-sim-doc__row--hint td {
    padding: 2px 14px 4px 28px;
}
.billing-sim-doc__hint {
    font-size: 0.78rem;
    color: var(--pe-color-neutral);
    font-style: italic;
}
.billing-sim-doc__tax {
    font-size: 0.78rem;
    color: var(--pe-color-text-muted);
}

/* ── Zwei-Spalten-Vergleich ───────────────────────────────────────────────── */
.billing-sim-compare {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}
.billing-sim-compare__col {
    flex: 1 1 0;
    min-width: 0;
}
.billing-sim-compare__savings {
    font-size: 0.82rem;
    color: var(--pe-color-success);
    font-weight: 600;
    padding: 6px 14px 8px;
}

/* ── Hilfklassen ─────────────────────────────────────────────────────────── */
.billing-sim__group--hidden {
    display: none;
}

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    .billing-sim-compare {
        flex-direction: column;
    }
    .billing-sim-compare__col {
        width: 100%;
    }
    .billing-sim-storno__row {
        flex-direction: column;
        align-items: flex-start;
    }
    .billing-sim-storno__row label {
        min-width: unset;
    }
}
