/*==========================================================================
   1. CSS-Variablen / Design Tokens
==========================================================================*/

/* Farbpalette */
:root
{
  /* Primärfarben (Haupt-Akzente) */
  --color-background: #dadcdd;
  --color-font-main: #454545;
  --color-font-label:#039ee6;

  /* Layout 
  --color-header-background: #001d3b;
  --color-header-font: #ffffff;
  --color-navbar-background: #2076b4;
  --color-navbar-font: #ffffff;
  --color-navbar-link-background: #2076b4;
  --color-navbar-link-font: #ffffff;
  --color-navbar-link-hover-background: #0056b3;
  --color-navbar-link-hover-font: #cce5ff;



  /* Flash-Messages */
  --color-flashmsg-info:     darkgrey;
  --color-flashmsg-success:   green;
  --color-flashmsg-warning:  darkorange;
  --color-flashmsg-error:    red;
  
  /*
  --size-sidebar-width: 220px;
  --size-header-height: 80px;
  --size-navbar-height: 50px;

  /* Tabellen 
  --color-table-outline: #0056b3;
  --color-table-head-background :#2076b4;
  --color-table-head-color :#ffffff;
  --color-table-rows-alternate-odd: white;
  --color-table-rows-alternate-even: #cce5ff;
*/

}


/*==========================================================================
   1. html,body
==========================================================================*/


body
{
  background-color: var(--color-background);
  font-family: 'Inter', sans-serif;
  margin: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  box-sizing: border-box;
}




/* Labels: Über dem Feld */
.flat-label {
    display: block;
    font-size: 14px;
    color: var(--color-font-label);
    margin-bottom: 4px;
}

/* Inputs: Text */
.flat-text {
    width: 100%;
    padding: 8px;
    box-sizing: border-box;
    margin-bottom: 12px;
    border: 1px solid #ccc;
    border-radius: 2px;
}





/* ======================================================================= 
   Flash Messages
   ======================================================================= */

.flashmsg {
    padding: 5px 5px 0 5px; /* OU LR */
    font-size: 14px;
}

.flashmsg-info { color: var(--color-flashmsg-info); }
.flashmsg-success { color: var(--color-flashmsg-success); }
.flashmsg-warning { color: var(--color-flashmsg-warning); }
.flashmsg-error { color: var(--color-flashmsg-error); }



/* =======================================================================
  Login-Formular
========================================================================== */

/* Wrapper: Zentrieren des Formulars auf der Seite (div)*/
#login-wrapper {
    display: flex;
    padding: 0 10%;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

/* Gesamte Box (div)*/
#login-box {
    width: 360px;
    border: 2px solid darkgrey;
    background-color: #fff;
    border-radius: 2px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2),
                0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 20px;
    box-sizing: border-box;
}

/* Logo-Bild (img) */
#login-logo {
  width: 100%;
  height: auto;
  display: block;
  margin: 0 auto 10px auto;
}

/* Titel-Zeile (div) */
#login-main {
    font-size: 24px;
    text-align: center;
    margin-top: 20px;
    color: var(--color-font-main);
}

/* Status-Zeile (div) */
#login-status {
    text-align: center;
    margin: 10px 0;
}

/* Wrapper eigentliches Formular (div) */
.login-form
{
    padding: 15px;
}

/* Flex-Zeile für Passwort-Label + Link */
.input-label-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-top: 10px;
}




/* Passwort vergessen */
.login-reset-password-link {
    font-size: 12px;
    color: var(--color-font-label);
    text-decoration: none;
}

.login-reset-password-link:hover {
    text-decoration: underline;
}


/* Login-Button */
.login-button {
    width: 100%;
    padding: 10px;
}


/* =======================================================================
   Gemeinsamer Passwortwechsel für Backoffice und Kundenbereich
========================================================================== */

.password-change-wrapper {
    min-height: 100vh;
    height: auto;
    padding: 24px;
}

#login-box.password-change-box {
    width: min(100%, 520px);
    padding: 28px;
    border-color: #b6c5cf;
}

#login-box.password-change-box #login-logo {
    max-width: 280px;
}

.password-change-eyebrow {
    margin: 22px 0 5px;
    color: var(--admin-navbar, #247caf);
    font-size: .75rem;
    font-weight: 800;
    letter-spacing: .11em;
    text-align: center;
    text-transform: uppercase;
}

.password-change-box h1 {
    margin: 0;
    color: #183b53;
    font-size: clamp(1.55rem, 5vw, 2rem);
    line-height: 1.15;
    text-align: center;
}

.password-change-introduction {
    margin: 14px 0;
    color: #4c616f;
    line-height: 1.55;
    text-align: center;
}

.password-change-account {
    margin: 18px 0 22px;
    padding: 11px 13px;
    overflow-wrap: anywhere;
    border: 1px solid #d5e0e7;
    border-radius: 4px;
    color: #36566b;
    background: #f4f8fa;
    font-size: .9rem;
    text-align: center;
}

.password-change-feedback {
    margin: 0 0 18px;
    padding: 10px 12px;
    border: 1px solid #d7e1e7;
    border-radius: 4px;
    background: #f8fafb;
}

.password-change-feedback .flashmsg {
    padding: 0;
    line-height: 1.45;
}

.password-change-field + .password-change-field {
    margin-top: 4px;
}

.password-change-form .flat-text {
    min-height: 42px;
    margin-bottom: 14px;
}

.password-change-form .flat-text:focus {
    border-color: var(--admin-navbar, #247caf);
    outline: 3px solid rgba(36, 124, 175, .16);
}

.password-change-policy {
    margin: 3px 0 18px;
    padding: 13px 15px;
    border-left: 4px solid var(--admin-navbar, #247caf);
    color: #4b626f;
    background: #edf5f9;
    font-size: .84rem;
    line-height: 1.45;
}

.password-change-policy strong {
    color: #234b64;
}

.password-change-policy ul {
    margin: 7px 0 0;
    padding-left: 19px;
}

.password-change-submit,
.password-change-back,
.password-change-logout {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 16px;
    border-radius: 3px;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
}

.password-change-submit {
    width: 100%;
    border: 1px solid #17618e;
    color: #fff;
    background: var(--admin-navbar, #247caf);
    cursor: pointer;
}

.password-change-submit:hover,
.password-change-submit:focus-visible {
    background: #176a9c;
}

.password-change-secondary-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid #dbe3e8;
}

.password-change-secondary-actions form {
    margin: 0;
}

.password-change-back,
.password-change-logout {
    border: 1px solid #aebdc7;
    color: #36566b;
    background: #fff;
    cursor: pointer;
}

.password-change-back:hover,
.password-change-back:focus-visible,
.password-change-logout:hover,
.password-change-logout:focus-visible {
    background: #edf2f5;
}

@media (max-width: 520px) {
    .password-change-wrapper {
        padding: 12px;
    }

    #login-box.password-change-box {
        padding: 22px 18px;
    }

    .password-change-secondary-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .password-change-secondary-actions form,
    .password-change-back,
    .password-change-logout {
        width: 100%;
    }
}


/* =======================================================================
   Responsive Admin-Layout
========================================================================== */

:root {
    --admin-header: #002342;
    --admin-navbar: #247caf;
    --admin-navbar-dark: #155b89;
    --admin-sidebar: #ffffff;
    --admin-sidebar-active: #dfeaf2;
    --admin-text: #164f79;
    --admin-header-height: 82px;
    --admin-toolbar-height: 58px;
    --admin-sidebar-wide: 250px;
    --admin-sidebar-compact: 76px;
}

*, *::before, *::after {
    box-sizing: border-box;
}

button, input {
    font: inherit;
}

.admin-shell {
    min-height: 100vh;
    color: #24323c;
    display: grid;
    grid-template:
        "header header" var(--admin-header-height)
        "toolbar toolbar" var(--admin-toolbar-height)
        "sidebar content" 1fr
        / var(--admin-sidebar-wide) minmax(0, 1fr);
    transition: grid-template-columns 180ms ease;
}

.admin-header {
    grid-area: header;
    position: relative;
    z-index: 40;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 24px;
    color: #fff;
    background: var(--admin-header);
}

.admin-logo {
    position: absolute;
    left: 50%;
    top: 50%;
    max-width: 150px;
    max-height: 58px;
    object-fit: contain;
    transform: translate(-50%, -50%);
}

.header-button,
.menu-button {
    border: 0;
    color: #fff;
    cursor: pointer;
}

.header-button {
    width: 52px;
    height: 52px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #315878;
    box-shadow: 0 2px 4px rgba(0, 0, 0, .25);
}

.header-button:hover,
.header-button:focus-visible {
    background: #47708f;
}

.admin-clock {
    margin-left: auto;
    text-align: right;
    line-height: 1.05;
}

.admin-clock time {
    display: block;
    font-size: clamp(1.75rem, 3vw, 2.7rem);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.admin-clock span {
    display: block;
    margin-top: 4px;
    font-size: .95rem;
}

.admin-toolbar {
    grid-area: toolbar;
    z-index: 30;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 0 18px 0 0;
    color: #fff;
    background: var(--admin-navbar);
    box-shadow: 0 2px 4px rgba(0, 0, 0, .12);
}

.admin-toolbar h1 {
    min-width: 0;
    overflow: hidden;
    margin: 0;
    font-size: 1.25rem;
    font-weight: 500;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.toolbar-context {
    color: rgba(255, 255, 255, .72);
}

/*
 * Kontomenü in der Navigationsleiste. Es ist ein gemeinsamer Layoutbaustein
 * für Backoffice und Kundenportal; die enthaltenen Links werden serverseitig
 * passend zur Rolle ausgewählt.
 */
.toolbar-user-menu {
    position: relative;
    min-width: 0;
    align-self: stretch;
    display: flex;
    margin-left: auto;
}

.toolbar-user-toggle {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 0 12px;
    border: 0;
    color: #fff;
    background: transparent;
    cursor: pointer;
}

.toolbar-user-toggle:hover,
.toolbar-user-toggle:focus-visible,
.toolbar-user-menu.is-expanded .toolbar-user-toggle {
    background: rgba(255, 255, 255, .16);
}

.toolbar-user-toggle .admin-icon {
    width: 22px;
    height: 22px;
    flex-basis: 22px;
    filter: brightness(0) invert(1);
}

.toolbar-user-label {
    overflow: hidden;
    max-width: 240px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.toolbar-user-chevron {
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: translateY(-2px) rotate(45deg);
    transition: transform 160ms ease;
}

.toolbar-user-menu.is-expanded .toolbar-user-chevron {
    transform: translateY(2px) rotate(225deg);
}

.toolbar-user-dropdown {
    position: absolute;
    z-index: 80;
    top: calc(100% + 8px);
    right: 0;
    width: min(310px, calc(100vw - 24px));
    overflow: hidden;
    border: 1px solid #c2d0d8;
    border-radius: 5px;
    color: #183b54;
    background: #fff;
    box-shadow: 0 10px 28px rgba(15, 42, 59, .24);
}

.toolbar-user-dropdown[hidden] {
    display: none;
}

.toolbar-user-identity {
    padding: 13px 15px;
    border-bottom: 1px solid #dce4e8;
    background: #f3f7f9;
}

.toolbar-user-identity small,
.toolbar-user-identity strong {
    display: block;
}

.toolbar-user-identity small {
    margin-bottom: 3px;
    color: #657985;
    font-size: .7rem;
    text-transform: uppercase;
}

.toolbar-user-identity strong {
    overflow-wrap: anywhere;
    font-size: .88rem;
}

.toolbar-user-dropdown a,
.toolbar-user-dropdown button {
    width: 100%;
    min-height: 48px;
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 10px 15px;
    border: 0;
    color: #183b54;
    background: #fff;
    font: inherit;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
}

.toolbar-user-dropdown a:hover,
.toolbar-user-dropdown a:focus-visible,
.toolbar-user-dropdown button:hover,
.toolbar-user-dropdown button:focus-visible {
    background: #e6f0f6;
}

.toolbar-user-dropdown form {
    margin: 0;
    border-top: 1px solid #e1e7ea;
}

.toolbar-user-dropdown .admin-icon {
    width: 20px;
    height: 20px;
    flex-basis: 20px;
}

.menu-button {
    width: var(--admin-sidebar-compact);
    align-self: stretch;
    display: flex;
    flex: 0 0 var(--admin-sidebar-compact);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
    margin: 0;
    background: var(--admin-navbar-dark);
    font-size: .72rem;
}

.menu-button:hover,
.menu-button:focus-visible {
    background: rgba(255, 255, 255, .22);
}

.admin-icon {
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
}

.admin-sidebar {
    grid-area: sidebar;
    z-index: 35;
    min-width: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    color: var(--admin-text);
    background: var(--admin-sidebar);
    border-right: 1px solid #cad4db;
    box-shadow: 2px 0 5px rgba(0, 0, 0, .08);
}

.sidebar-link {
    width: 100%;
    min-height: 64px;
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 0 24px;
    border: 0;
    color: inherit;
    background: transparent;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
}

.sidebar-link:hover,
.sidebar-link:focus-visible,
.sidebar-link.is-active {
    background: var(--admin-sidebar-active);
}

.sidebar-link .admin-icon {
    color: #126296;
}

/* Der Navigationsbereich darf bei vielen Menüeinträgen scrollen. */
.admin-sidebar > nav {
    min-height: 0;
    flex: 1 1 auto;
    overflow-y: auto;
}

/* Eine aufklappbare Gruppe belegt wie ein normaler Menüpunkt die volle Breite. */
.sidebar-group {
    width: 100%;
}

/*
 * Der Gruppenname ist ein Button und kein Link, weil er keine neue Seite
 * öffnet. Er steuert ausschließlich das zugehörige Untermenü.
 */
.sidebar-group-toggle {
    text-align: left;
}

/*
 * Der kleine Pfeil wird nur mit CSS gezeichnet. Seine Drehung zeigt an,
 * ob die Gruppe geschlossen oder geöffnet ist.
 */
.submenu-chevron {
    width: 9px;
    height: 9px;
    flex: 0 0 9px;
    display: block;
    margin-left: auto;
    border-right: 2px solid #126296;
    border-bottom: 2px solid #126296;
    transform: rotate(45deg);
    transition: transform 160ms ease;
}

.sidebar-group.is-expanded .submenu-chevron {
    transform: rotate(225deg);
}

/*
 * Das hidden-Attribut wird durch JavaScript gesetzt und entfernt.
 * Diese Regel stellt sicher, dass ein geschlossenes Untermenü unabhängig
 * von anderen Display-Regeln unsichtbar bleibt.
 */
.sidebar-submenu[hidden] {
    display: none;
}

/*
 * Unterpunkte sind etwas niedriger und weiter eingerückt als Einträge der
 * ersten Ebene. Der dezente Hintergrund verdeutlicht die Gruppierung.
 */
.sidebar-sublink {
    min-height: 52px;
    gap: 16px;
    padding-left: 56px;
    background: #f7f9fa;
    font-size: .92rem;
}

.sidebar-sublink .admin-icon {
    width: 20px;
    height: 20px;
    flex-basis: 20px;
}

.admin-content {
    grid-area: content;
    min-width: 0;
    padding: clamp(20px, 4vw, 48px);
    background: #eef1f3;
}

.admin-welcome {
    max-width: 850px;
    padding: clamp(24px, 4vw, 42px);
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(26, 48, 63, .12);
}

.admin-welcome h2 {
    margin: 4px 0 18px;
    color: #183b54;
    font-size: clamp(1.5rem, 3vw, 2.1rem);
}

.admin-welcome p {
    line-height: 1.6;
}

.eyebrow {
    margin: 0;
    color: var(--admin-navbar);
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
}

/*
 * ==========================================================================
 * Eigenes Rechteprofil
 * ==========================================================================
 */

/*
 * Die Rechteübersicht benötigt etwas mehr Breite als das normale Dashboard,
 * bleibt auf sehr großen Bildschirmen aber weiterhin gut lesbar.
 */
.rights-page {
    max-width: 1050px;
}

.rights-introduction {
    margin-bottom: 24px;
}

/*
 * Die aktuell zugewiesene Rolle und die Gesamtzahl der wirksamen Rechte
 * bilden den Kopf der Übersicht.
 */
.rights-role-summary {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 24px;
    padding: 20px;
    border: 1px solid #b9cfdd;
    border-left: 4px solid var(--admin-navbar);
    border-radius: 4px;
    background: #f6fafc;
}

.rights-role-details {
    min-width: 0;
}

.rights-role-details > span {
    display: block;
    color: var(--admin-navbar);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.rights-role-details > strong {
    display: inline-block;
    margin: 5px 8px 0 0;
    color: #183b54;
    font-size: 1.25rem;
}

.rights-role-details > code {
    color: #29698f;
    font-size: .78rem;
}

.rights-role-details > p {
    margin: 8px 0 0;
    color: #425968;
}

.rights-total {
    min-width: 130px;
    display: flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 14px;
    border-radius: 4px;
    color: #fff;
    background: #123c5a;
    text-align: center;
}

.rights-total strong {
    font-size: 1.45rem;
    font-variant-numeric: tabular-nums;
}

.rights-total span {
    color: #cce4f3;
    font-size: .76rem;
}

.rights-groups {
    display: grid;
    gap: 22px;
    margin-top: 28px;
}

.rights-group {
    overflow: hidden;
    border: 1px solid #d2dde4;
    border-radius: 4px;
}

.rights-group-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 20px;
    background: #eaf2f7;
}

.rights-group-heading h3 {
    margin: 0;
    color: #183b54;
    font-size: 1.05rem;
}

.rights-group-heading p {
    margin: 4px 0 0;
    color: #4f6879;
    font-size: .88rem;
    line-height: 1.45;
}

.rights-group-count {
    flex: 0 0 auto;
    padding: 5px 8px;
    border-radius: 3px;
    color: #164f79;
    background: #d5e8f3;
    font-size: .76rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.rights-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.rights-item {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 24px;
    padding: 18px 20px;
    border-top: 1px solid #e1e8ec;
}

.rights-item:first-child {
    border-top: 0;
}

.rights-item.is-denied {
    background: #fafbfc;
}

.rights-permission-title {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.rights-permission-title strong {
    color: #183b54;
}

.rights-technical-badge {
    padding: 3px 6px;
    border-radius: 3px;
    color: #795300;
    background: #fff0c5;
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.rights-permission-details p {
    margin: 5px 0 7px;
    color: #506674;
    font-size: .88rem;
    line-height: 1.45;
}

.rights-permission-details code {
    color: #29698f;
    font-size: .78rem;
}

/*
 * Der Schalter zeigt nur den Zustand an. Er ist absichtlich kein Button und
 * besitzt deshalb auch keine Hover- oder Fokusdarstellung.
 */
.rights-state {
    display: flex;
    align-items: center;
    gap: 10px;
}

.rights-state-label {
    min-width: 84px;
    color: #697985;
    font-size: .82rem;
    text-align: right;
}

.rights-item.is-allowed .rights-state-label {
    color: #24713e;
    font-weight: 700;
}

.rights-switch {
    position: relative;
    width: 44px;
    height: 24px;
    flex: 0 0 44px;
    border-radius: 999px;
    background: #aeb9c0;
    box-shadow: inset 0 0 0 1px rgba(24, 59, 84, .16);
}

.rights-switch::after {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(24, 59, 84, .28);
    content: "";
    transition: transform 160ms ease;
}

.rights-switch.is-on {
    background: #2d8a50;
}

.rights-switch.is-on::after {
    transform: translateX(20px);
}

/*
 * ==========================================================================
 * Kundenliste
 * ==========================================================================
 */

.customer-list-page {
    max-width: 1280px;
}

.customer-list-title-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
}

.customer-list-title-row .eyebrow {
    margin-top: 0;
}

.customer-list-create,
.customer-list-search button,
.customer-list-empty a,
.customer-list-mobile-sort button {
    min-height: 42px;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 16px;
    border: 1px solid #17618e;
    border-radius: 3px;
    color: #fff;
    background: var(--admin-navbar);
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.customer-list-create:hover,
.customer-list-create:focus,
.customer-list-search button:hover,
.customer-list-search button:focus,
.customer-list-empty a:hover,
.customer-list-empty a:focus,
.customer-list-mobile-sort button:hover,
.customer-list-mobile-sort button:focus {
    background: #176a9c;
}

.customer-list-introduction {
    max-width: 800px;
    color: #425968;
}

.customer-list-search {
    margin: 24px 0 20px;
    padding: 18px;
    border: 1px solid #c8d7e0;
    border-radius: 4px;
    background: #f5f9fb;
}

.customer-list-search > label,
.customer-list-mobile-sort label {
    display: block;
    margin-bottom: 7px;
    color: #284b62;
    font-size: .86rem;
    font-weight: 700;
}

.customer-list-search-row {
    display: flex;
    align-items: stretch;
    gap: 10px;
}

.customer-list-search input[type="search"] {
    min-width: 220px;
    min-height: 42px;
    flex: 1 1 520px;
    box-sizing: border-box;
    padding: 9px 11px;
    border: 1px solid #aebdc7;
    border-radius: 3px;
    color: #263f4f;
    background: #fff;
    font: inherit;
}

.customer-list-search input[type="search"]:focus,
.customer-list-mobile-sort select:focus {
    border-color: var(--admin-navbar);
    outline: 3px solid rgba(40, 125, 170, .18);
}

.customer-list-search-reset {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    padding: 0 8px;
    color: #2b668c;
    font-weight: 700;
}

.customer-list-search > small {
    display: block;
    margin-top: 8px;
    color: #647681;
    font-size: .76rem;
}

.customer-list-result-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin: 0 0 10px;
    color: #506875;
    font-size: .84rem;
}

.customer-list-result-heading p {
    margin: 0;
}

.customer-list-result-heading strong {
    color: #183b54;
}

.customer-list-table-wrapper {
    overflow: hidden;
    border: 1px solid #c5d2da;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(24, 59, 84, .08);
}

.customer-list-table {
    width: 100%;
    border-collapse: collapse;
    color: #314d5f;
}

.customer-list-table th,
.customer-list-table td {
    padding: 13px 15px;
    border-bottom: 1px solid #dbe4e9;
    text-align: left;
    vertical-align: middle;
}

.customer-list-table th {
    color: #fff;
    background: #1f6f9f;
    font-size: .78rem;
    letter-spacing: .02em;
}

.customer-list-table th:nth-child(3),
.customer-list-table td:nth-child(3) {
    width: 130px;
}

.customer-list-table th:nth-child(4),
.customer-list-table td:nth-child(4) {
    width: 170px;
}

.customer-list-table th:last-child,
.customer-list-table td:last-child {
    width: 90px;
    text-align: right;
}

.customer-list-table tbody tr:last-child td {
    border-bottom: 0;
}

.customer-list-table tbody tr:nth-child(even) {
    background: #f5f9fb;
}

.customer-list-table tbody tr:hover {
    background: #eaf3f8;
}

.customer-list-table td:first-child strong {
    color: #183b54;
}

.customer-name-summary {
    min-width: 0;
}

.customer-official-name {
    display: block;
    margin-top: 4px;
    color: #607480;
    line-height: 1.35;
}

.customer-list-sort {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    color: inherit;
    text-decoration: none;
}

.customer-list-sort:hover,
.customer-list-sort:focus {
    color: #fff;
    text-decoration: underline;
}

.customer-list-sort [aria-hidden="true"] {
    color: #cae5f4;
    font-size: 1rem;
}

.customer-access-count {
    display: flex;
    align-items: baseline;
    gap: 7px;
    border-radius: 3px;
    color: inherit;
    text-decoration: none;
}

.customer-access-count:hover strong,
.customer-access-count:focus strong {
    color: #fff;
    background: #1c6f9f;
}

.customer-access-count:focus-visible {
    outline: 3px solid rgba(40, 125, 170, .24);
    outline-offset: 3px;
}

.customer-access-count strong {
    min-width: 28px;
    display: inline-flex;
    justify-content: center;
    padding: 3px 7px;
    border-radius: 999px;
    color: #155a82;
    background: #dceef8;
}

.customer-access-count small {
    color: #647681;
    font-size: .72rem;
}

.customer-detail-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 11px;
    border: 1px solid #8eb1c6;
    border-radius: 3px;
    color: #1c628c;
    background: #fff;
    font-size: .8rem;
    font-weight: 700;
    text-decoration: none;
}

.customer-detail-link:hover,
.customer-detail-link:focus {
    border-color: #1c628c;
    background: #e9f3f8;
}

.customer-list-empty {
    padding: 34px 24px;
    border: 1px dashed #b8cbd6;
    border-radius: 4px;
    text-align: center;
    background: #f8fafb;
}

.customer-list-empty strong {
    display: block;
    color: #244a63;
    font-size: 1.05rem;
}

.customer-list-empty p {
    margin: 8px auto 18px;
    color: #5a707d;
}

.customer-list-pagination {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
    margin-top: 18px;
    font-size: .84rem;
}

.customer-list-pagination a,
.customer-list-pagination span {
    color: #23678e;
    font-weight: 700;
}

.customer-list-pagination a:last-child,
.customer-list-pagination span:last-child {
    text-align: right;
}

.customer-list-pagination span[aria-disabled="true"] {
    color: #8797a0;
}

.customer-list-pagination strong {
    color: #3e596a;
    text-align: center;
}

.customer-list-mobile-sort {
    display: none;
}

/*
 * ==========================================================================
 * Kundenformular
 * ==========================================================================
 */

.customer-form-page {
    max-width: 1080px;
}

.customer-form-introduction {
    max-width: 780px;
    margin-bottom: 24px;
    color: #425968;
}

.customer-form-help {
    max-width: 780px;
    margin: 0 0 24px;
    border: 1px solid #c8d9e3;
    border-radius: 4px;
    color: #36566b;
    background: #f3f8fb;
}

.customer-form-help summary {
    padding: 13px 16px;
    color: #1f587b;
    font-weight: 700;
    cursor: pointer;
}

.customer-form-help-content {
    padding: 0 16px 15px;
    font-size: .88rem;
    line-height: 1.55;
}

.customer-form-help-content p {
    margin: 0 0 10px;
}

.customer-form-help-content ul {
    margin: 0;
    padding-left: 20px;
}

.customer-form-feedback {
    margin: 0 0 22px;
    padding: 14px 16px;
    border: 1px solid #b8d7c1;
    border-left: 4px solid #2d8a50;
    border-radius: 4px;
    color: #1f6439;
    background: #f0f8f2;
}

.customer-form-feedback.is-error {
    border-color: #e3b9b9;
    border-left-color: #b93f3f;
    color: #842d2d;
    background: #fff5f5;
}

.customer-form-feedback strong {
    display: block;
    margin-bottom: 6px;
}

.customer-form-feedback ul {
    margin: 0;
    padding-left: 20px;
}

.customer-form-feedback .flashmsg {
    padding: 0;
}

.customer-form {
    display: grid;
    gap: 24px;
}

.customer-form-section {
    min-width: 0;
    margin: 0;
    padding: 22px;
    border: 1px solid #d2dde4;
    border-radius: 4px;
    background: #fbfcfd;
}

.customer-form-section legend {
    padding: 0 8px;
    color: #183b54;
    font-size: 1rem;
    font-weight: 700;
}

.customer-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px 20px;
}

.customer-field {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.customer-field-wide {
    grid-column: 1 / -1;
}

.customer-field label {
    color: #284b62;
    font-size: .84rem;
    font-weight: 700;
}

.customer-field label span {
    color: #a62f2f;
}

.customer-field input,
.customer-field select,
.customer-field textarea {
    width: 100%;
    min-height: 42px;
    box-sizing: border-box;
    padding: 9px 11px;
    border: 1px solid #aebdc7;
    border-radius: 3px;
    color: #263f4f;
    background: #fff;
    font: inherit;
}

.customer-field input:focus,
.customer-field select:focus,
.customer-field textarea:focus {
    border-color: var(--admin-navbar);
    outline: 3px solid rgba(40, 125, 170, .18);
    outline-offset: 0;
}

.customer-field textarea {
    min-height: 84px;
    line-height: 1.45;
    resize: vertical;
}

.customer-field-help,
.customer-template-status {
    color: #647681;
    font-size: .76rem;
    line-height: 1.4;
}

.customer-template-status {
    color: #286b91;
    font-weight: 600;
}

.customer-autocomplete {
    position: relative;
}

.customer-autocomplete-results {
    position: absolute;
    z-index: 60;
    top: calc(100% + 4px);
    right: 0;
    left: 0;
    max-height: 320px;
    overflow-y: auto;
    border: 1px solid #9eb4c2;
    border-radius: 3px;
    background: #fff;
    box-shadow: 0 8px 20px rgba(24, 59, 84, .22);
}

.customer-autocomplete-option {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 11px 13px;
    border: 0;
    border-top: 1px solid #e2e9ed;
    color: #24465c;
    background: #fff;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.customer-autocomplete-option:first-child {
    border-top: 0;
}

.customer-autocomplete-option:hover,
.customer-autocomplete-option:focus,
.customer-autocomplete-option.is-active {
    outline: 0;
    background: #e6f1f7;
}

.customer-autocomplete-option strong {
    color: #164f79;
    font-size: .88rem;
}

.customer-autocomplete-option small {
    color: #617684;
    font-size: .76rem;
}

.customer-autocomplete-message {
    padding: 13px;
    color: #617684;
    font-size: .84rem;
}

.customer-form-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
}

.customer-form-cancel,
.customer-form-submit {
    min-height: 42px;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 16px;
    border-radius: 3px;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
}

.customer-form-cancel {
    border: 1px solid #aebdc7;
    color: #36566b;
    background: #fff;
}

.customer-form-submit {
    border: 1px solid #17618e;
    color: #fff;
    background: var(--admin-navbar);
    cursor: pointer;
}

.customer-form-cancel:hover,
.customer-form-cancel:focus {
    background: #edf2f5;
}

.customer-form-submit:hover,
.customer-form-submit:focus {
    background: #176a9c;
}

/*
 * ==========================================================================
 * Kundendetail und EBA-Abgleich
 * ==========================================================================
 */

.customer-detail-title-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
}

.customer-detail-title-row .eyebrow {
    margin-top: 0;
}

.customer-detail-title-row h2 {
    overflow-wrap: anywhere;
}

.customer-detail-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 9px;
}

.customer-detail-actions a {
    min-height: 40px;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 13px;
    border: 1px solid #8eb1c6;
    border-radius: 3px;
    color: #1c628c;
    background: #fff;
    font-size: .82rem;
    font-weight: 700;
    text-decoration: none;
}

.customer-detail-actions a:hover,
.customer-detail-actions a:focus {
    border-color: #1c628c;
    background: #e9f3f8;
}

.customer-detail-readonly {
    margin: 0 0 22px;
    padding: 13px 16px;
    border: 1px solid #c5d3dc;
    border-left: 4px solid #688294;
    border-radius: 4px;
    color: #3f596a;
    background: #f4f7f9;
}

.customer-detail-readonly code,
.customer-form-introduction code {
    color: #174f73;
    font-size: .9em;
}

.customer-eba-status {
    margin: 0 0 26px;
    padding: 19px 20px;
    border: 1px solid #c8d7e0;
    border-left-width: 5px;
    border-radius: 4px;
    color: #365264;
    background: #f5f8fa;
}

.customer-eba-status.is-manual {
    border-left-color: #758997;
}

.customer-eba-status.is-current {
    border-color: #b9d8c2;
    border-left-color: #2d8a50;
    color: #295d3d;
    background: #f2f9f4;
}

.customer-eba-status.is-update {
    border-color: #e1ca93;
    border-left-color: #bc7c13;
    color: #664b1b;
    background: #fffaf0;
}

.customer-eba-status h3 {
    margin: 2px 0 0;
    color: inherit;
    font-size: 1.05rem;
}

.customer-eba-status > p {
    max-width: 820px;
    margin: 12px 0 0;
    line-height: 1.5;
}

.customer-eba-status > small {
    display: block;
    margin-top: 9px;
    color: inherit;
    font-size: .76rem;
    opacity: .82;
}

.customer-eba-kicker {
    margin: 0;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.customer-eba-already-matching {
    padding: 12px 14px;
    border-radius: 3px;
    background: rgba(255, 255, 255, .68);
}

.customer-eba-comparison-wrapper {
    margin-top: 18px;
    overflow-x: auto;
    border: 1px solid #dbc68f;
    border-radius: 4px;
    background: #fff;
}

.customer-eba-comparison {
    width: 100%;
    min-width: 760px;
    border-collapse: collapse;
    color: #3b5260;
    font-size: .82rem;
}

.customer-eba-comparison th,
.customer-eba-comparison td {
    padding: 12px 13px;
    border-bottom: 1px solid #e6ddd0;
    text-align: left;
    vertical-align: middle;
}

.customer-eba-comparison thead th {
    color: #fff;
    background: #846323;
    font-size: .75rem;
    letter-spacing: .02em;
}

.customer-eba-comparison tbody th {
    width: 22%;
    color: #3a5363;
    background: #fffdf8;
}

.customer-eba-comparison tbody tr:last-child th,
.customer-eba-comparison tbody tr:last-child td {
    border-bottom: 0;
}

.customer-eba-comparison td:nth-child(2),
.customer-eba-comparison td:nth-child(3) {
    max-width: 260px;
    overflow-wrap: anywhere;
}

.customer-eba-adopt-button {
    min-height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 11px;
    border: 1px solid #8f681a;
    border-radius: 3px;
    color: #fff;
    background: #9e7016;
    font: inherit;
    font-size: .76rem;
    font-weight: 700;
    cursor: pointer;
}

.customer-eba-adopt-button:hover,
.customer-eba-adopt-button:focus {
    background: #7e5810;
}

.customer-eba-readonly {
    color: #786f60;
    font-size: .75rem;
}

.customer-detail-form .customer-form-section:disabled {
    opacity: .78;
}

.customer-detail-form .customer-form-section:disabled input,
.customer-detail-form .customer-form-section:disabled select,
.customer-detail-form .customer-form-section:disabled textarea {
    color: #3f5664;
    background: #edf2f4;
    -webkit-text-fill-color: #3f5664;
}

/*
 * ==========================================================================
 * Kundenzugänge
 * ==========================================================================
 */

.customer-accounts-page {
    max-width: 1120px;
}

.customer-account-credentials {
    margin: 0 0 24px;
    padding: 18px 20px;
    border: 1px solid #e0bd68;
    border-left: 5px solid #b87908;
    border-radius: 4px;
    color: #5d461b;
    background: #fff9e9;
}

.customer-account-credentials-kicker {
    margin: 0;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.customer-account-credentials h3 {
    margin: 4px 0 8px;
    color: #604718;
}

.customer-account-credentials > p:not(.customer-account-credentials-kicker) {
    margin: 0 0 14px;
}

.customer-account-credentials dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 0;
}

.customer-account-credentials dl > div {
    min-width: 0;
    padding: 11px 13px;
    border: 1px solid rgba(151, 104, 16, .28);
    border-radius: 3px;
    background: #fff;
}

.customer-account-credentials dt,
.customer-account-meta dt {
    color: #697b86;
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.customer-account-credentials dd,
.customer-account-meta dd {
    margin: 4px 0 0;
}

.customer-account-credentials code {
    color: #47330e;
    font-size: .96rem;
    font-weight: 700;
    overflow-wrap: anywhere;
    user-select: all;
}

.customer-account-create {
    margin: 0 0 28px;
    padding: 20px;
    border: 1px solid #c8d9e3;
    border-radius: 4px;
    background: #f3f8fb;
}

.customer-account-create h3,
.customer-account-list h3 {
    margin: 0 0 14px;
    color: #183b54;
}

.customer-account-create-form > label,
.customer-account-email-form > label {
    display: block;
    margin-bottom: 7px;
    color: #284b62;
    font-size: .82rem;
    font-weight: 700;
}

.customer-account-create-form > label span {
    color: #a62f2f;
}

.customer-account-create-form > div,
.customer-account-email-form > div {
    display: flex;
    align-items: stretch;
    gap: 10px;
}

.customer-account-create-form input,
.customer-account-email-form input[type="email"] {
    min-width: 0;
    min-height: 42px;
    flex: 1 1 auto;
    padding: 9px 11px;
    border: 1px solid #aebdc7;
    border-radius: 3px;
    color: #263f4f;
    background: #fff;
}

.customer-account-create-form input:focus,
.customer-account-email-form input[type="email"]:focus {
    border-color: var(--admin-navbar);
    outline: 3px solid rgba(40, 125, 170, .18);
}

.customer-account-create-form button,
.customer-account-email-form button,
.customer-account-button-row button,
.customer-account-delete button {
    min-height: 42px;
    padding: 8px 14px;
    border: 1px solid #17618e;
    border-radius: 3px;
    color: #fff;
    background: var(--admin-navbar);
    font: inherit;
    font-size: .82rem;
    font-weight: 700;
    cursor: pointer;
}

.customer-account-create-form button:hover,
.customer-account-create-form button:focus-visible,
.customer-account-email-form button:hover,
.customer-account-email-form button:focus-visible,
.customer-account-button-row button:hover,
.customer-account-button-row button:focus-visible {
    background: #176a9c;
}

.customer-account-list-heading {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 12px;
}

.customer-account-list-heading h3 {
    margin: 0;
}

.customer-account-list-heading span {
    color: #607480;
    font-size: .82rem;
    font-weight: 700;
}

.customer-account-cards {
    display: grid;
    gap: 16px;
}

.customer-account-card {
    overflow: hidden;
    border: 1px solid #c5d2da;
    border-left: 5px solid #2d8a50;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(24, 59, 84, .08);
}

.customer-account-card.is-disabled {
    border-left-color: #a64a4a;
}

.customer-account-card-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding: 18px 20px;
    border-bottom: 1px solid #dbe4e9;
    background: #f8fafb;
}

.customer-account-card-heading h4 {
    margin: 0 0 8px;
    color: #183b54;
    overflow-wrap: anywhere;
}

.customer-account-status {
    display: inline-flex;
    padding: 4px 9px;
    border-radius: 999px;
    font-size: .72rem;
    font-weight: 800;
}

.customer-account-status.is-active {
    color: #21663b;
    background: #dff2e5;
}

.customer-account-status.is-disabled {
    color: #8c3030;
    background: #fae1e1;
}

.customer-account-meta {
    min-width: min(100%, 430px);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 18px;
    margin: 0;
}

.customer-account-meta dd {
    color: #344f60;
    font-size: .8rem;
}

.customer-account-actions {
    display: grid;
    gap: 14px;
    padding: 18px 20px;
}

.customer-account-button-row {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.customer-account-button-row form {
    margin: 0;
}

.customer-account-button-row .customer-account-warning-button {
    border-color: #9a6811;
    background: #a97518;
}

.customer-account-button-row .customer-account-warning-button:hover,
.customer-account-button-row .customer-account-warning-button:focus-visible {
    background: #875b0d;
}

.customer-account-delete {
    border-top: 1px solid #e0e7eb;
    padding-top: 12px;
}

.customer-account-delete summary {
    width: fit-content;
    color: #9a3838;
    font-size: .8rem;
    font-weight: 700;
    cursor: pointer;
}

.customer-account-delete form {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-top: 12px;
    padding: 13px;
    border: 1px solid #e4bdbd;
    border-radius: 3px;
    background: #fff5f5;
}

.customer-account-delete label {
    flex: 1 1 auto;
    color: #733737;
    font-size: .8rem;
    line-height: 1.4;
}

.customer-account-delete input {
    margin-right: 6px;
}

.customer-account-delete .customer-account-danger-button {
    border-color: #8f2f2f;
    background: #a83b3b;
}

.customer-account-delete .customer-account-danger-button:hover,
.customer-account-delete .customer-account-danger-button:focus-visible {
    background: #872828;
}

/*
 * ==========================================================================
 * Einstellungen der Terminbuchung
 * ==========================================================================
 */

.booking-settings-page {
    max-width: 980px;
}

.booking-setting-combined-field > div {
    display: grid;
    grid-template-columns: minmax(100px, .55fr) minmax(160px, 1fr);
    gap: 9px;
}

.booking-settings-updated {
    margin-right: auto;
    color: #647681;
    font-size: .76rem;
}

/*
 * ==========================================================================
 * Gemeinsamer Terminkalender für Backoffice und Kundenportal
 * ==========================================================================
 */

.booking-dashboard-page {
    max-width: 1180px;
}

.booking-dashboard-introduction {
    max-width: 760px;
    color: #425968;
}

.booking-calendar-summary {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin: 22px 0;
}

.booking-calendar-summary > div {
    padding: 13px 15px;
    border: 1px solid #cad9e2;
    border-radius: 4px;
    background: #f5f9fb;
}

.booking-calendar-summary span,
.booking-calendar-summary strong {
    display: block;
}

.booking-calendar-summary span {
    margin-bottom: 4px;
    color: #687b87;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.booking-calendar-summary strong {
    color: #183b54;
}

.booking-calendar {
    overflow: hidden;
    border: 1px solid #c5d2da;
    border-radius: 5px;
    background: #fff;
    box-shadow: 0 5px 16px rgba(24, 59, 84, .1);
}

.booking-calendar-toolbar {
    min-height: 62px;
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) 52px;
    align-items: center;
    color: #fff;
    background: #1f6f9f;
}

.booking-calendar-toolbar h3 {
    margin: 0;
    text-align: center;
    font-size: 1.18rem;
}

.booking-calendar-toolbar a,
.booking-calendar-toolbar > span {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    justify-self: center;
}

.booking-calendar-toolbar a {
    border-radius: 50%;
    color: #fff;
    font-size: 2rem;
    line-height: 1;
    text-decoration: none;
}

.booking-calendar-toolbar a:hover,
.booking-calendar-toolbar a:focus-visible {
    background: rgba(255, 255, 255, .2);
}

.booking-calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
}

.booking-calendar-weekdays {
    border-bottom: 1px solid #d5dfe5;
    color: #4c6878;
    background: #edf3f6;
}

.booking-calendar-weekdays span {
    padding: 9px 4px;
    text-align: center;
    font-size: .76rem;
    font-weight: 800;
}

.booking-calendar-day {
    min-width: 0;
    min-height: 92px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 8px;
    padding: 10px;
    border-right: 1px solid #dfe6ea;
    border-bottom: 1px solid #dfe6ea;
    color: #264b62;
    background: #fff;
    text-decoration: none;
}

.booking-calendar-day:nth-child(7n) {
    border-right: 0;
}

.booking-calendar-day strong {
    align-self: flex-start;
    min-width: 27px;
    height: 27px;
    display: inline-grid;
    place-items: center;
    border-radius: 50%;
}

.booking-calendar-day small {
    color: #2a7750;
    font-size: .72rem;
    font-weight: 700;
}

a.booking-calendar-day:hover,
a.booking-calendar-day:focus-visible {
    position: relative;
    z-index: 1;
    outline: 3px solid rgba(36, 124, 175, .28);
    outline-offset: -3px;
    background: #eef8fd;
}

.booking-calendar-day.is-today strong {
    color: #fff;
    background: #1f6f9f;
}

.booking-calendar-day.is-selected {
    box-shadow: inset 0 0 0 3px #1973a7;
    background: #e7f4fb;
}

.booking-calendar-day.is-full,
.booking-calendar-day.is-outside-range {
    color: #8a989f;
    background: #f1f3f4;
}

.booking-calendar-day.is-outside-range {
    opacity: .68;
}

.booking-calendar-day.is-full small,
.booking-calendar-day.is-outside-range small {
    color: #909da4;
}

.booking-calendar-day.is-empty {
    background: #f8f9fa;
}

.booking-calendar-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 22px;
    padding: 13px 16px;
    color: #607480;
    background: #f7f9fa;
    font-size: .74rem;
}

.booking-calendar-legend span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.booking-calendar-legend i {
    width: 13px;
    height: 13px;
    display: inline-block;
    border: 1px solid #aebdc7;
    border-radius: 2px;
    background: #fff;
}

.booking-calendar-legend i.is-full {
    background: #e6e9eb;
}

.booking-calendar-legend i.is-selected {
    border: 3px solid #1973a7;
    background: #e7f4fb;
}

.booking-calendar-legend i.is-free {
    border-color: #80b795;
    background: #e7f5ec;
}

.booking-slots {
    margin-top: 24px;
}

.booking-slots-placeholder {
    padding: 28px 22px;
    border: 1px dashed #b8cbd6;
    border-radius: 4px;
    color: #5a707d;
    text-align: center;
    background: #f8fafb;
}

.booking-slots-placeholder h3 {
    margin: 0 0 7px;
    color: #244a63;
}

.booking-slots-placeholder p {
    margin: 0;
}

.booking-slots-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 13px;
}

.booking-slots-heading .eyebrow,
.booking-slots-heading h3 {
    margin: 0;
}

.booking-slots-heading span {
    color: #2a7750;
    font-size: .82rem;
    font-weight: 800;
}

.booking-slot-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.booking-slot-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 15px 16px;
    border: 1px solid #c7d7e0;
    border-left: 4px solid #3a9660;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 3px 10px rgba(24, 59, 84, .06);
}

.booking-slot-card time,
.booking-slot-card small {
    display: block;
}

.booking-slot-card time {
    color: #183b54;
    font-weight: 800;
}

.booking-slot-card small {
    margin-top: 4px;
    color: #687b87;
    font-size: .72rem;
}

.booking-slot-card button {
    min-height: 40px;
    padding: 8px 13px;
    border: 1px solid #9bb2bf;
    border-radius: 3px;
    color: #6f7d85;
    background: #edf1f3;
    font-weight: 700;
    cursor: not-allowed;
}

.booking-reservation-note {
    margin: 13px 0 0;
    color: #687b87;
    font-size: .78rem;
}

/*
 * Inhalt bleibt für Screenreader verfügbar, nimmt visuell aber keinen Platz
 * ein. Die Klasse wird für Statusmeldungen des Autocomplete verwendet.
 */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
}

/*
 * ==========================================================================
 * EVU-Datamanager
 * ==========================================================================
 */

.evu-update-status {
    margin-top: 28px;
    padding: 20px;
    border: 1px solid #b9cfdd;
    border-left: 4px solid var(--admin-navbar);
    border-radius: 4px;
    background: #f6fafc;
}

.evu-update-status-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.evu-update-status-heading h3 {
    margin: 0;
    color: #183b54;
    font-size: 1.05rem;
}

.evu-status-kicker {
    margin: 0 0 4px;
    color: var(--admin-navbar);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.evu-audit-badge {
    flex: 0 0 auto;
    padding: 5px 8px;
    border-radius: 3px;
    color: #17622f;
    background: #dff1e4;
    font-size: .76rem;
    font-weight: 700;
}

.evu-update-facts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: 18px 0 0;
}

.evu-update-facts > div {
    min-width: 0;
    padding: 12px;
    border: 1px solid #d3dfe6;
    border-radius: 4px;
    background: #fff;
}

.evu-update-facts dt {
    color: #647681;
    font-size: .75rem;
    line-height: 1.35;
}

.evu-update-facts dd {
    margin: 5px 0 2px;
    color: #183b54;
    font-size: 1rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    line-height: 1.35;
}

.evu-update-facts small {
    color: #647681;
    font-size: .72rem;
    line-height: 1.35;
}

.evu-last-result,
.evu-audit-note {
    margin: 14px 0 0;
    color: #425968;
    font-size: .84rem;
}

.evu-audit-note {
    padding-top: 12px;
    border-top: 1px solid #d3dfe6;
}

.evu-read-only-note {
    margin-top: 28px;
    padding: 14px 16px;
    border: 1px solid #a9ccdf;
    border-left: 4px solid var(--admin-navbar);
    border-radius: 4px;
    color: #164f79;
    background: #eef7fc;
}

.evu-read-only-note > strong {
    display: block;
    margin-bottom: 4px;
}

.evu-read-only-note p {
    margin: 0;
}

.evu-read-only-note code {
    font-size: .82em;
}

.evu-source,
.evu-url-import,
.evu-import-preview {
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid #d7e0e6;
}

.evu-source h3,
.evu-url-import h3,
.evu-import-preview h3 {
    margin: 0 0 8px;
    color: #183b54;
    font-size: 1.05rem;
}

.evu-source > p,
.evu-url-import > p {
    margin: 0 0 16px;
}

/*
 * Das gesamte EBA-Element ist ein externer Link. Logo und Beschriftung
 * können dadurch gemeinsam angeklickt werden.
 */
.eba-source-link {
    width: fit-content;
    max-width: 100%;
    display: inline-flex;
    align-items: center;
    gap: 18px;
    padding: 14px 18px;
    border: 1px solid #c7d6df;
    border-radius: 4px;
    color: #164f79;
    background: #f7fafc;
    text-decoration: none;
    transition:
        border-color 160ms ease,
        background-color 160ms ease,
        box-shadow 160ms ease;
}

.eba-source-link:hover,
.eba-source-link:focus-visible {
    border-color: var(--admin-navbar);
    background: #eef7fc;
    box-shadow: 0 2px 8px rgba(26, 48, 63, .12);
}

.eba-source-link:focus-visible {
    outline: 3px solid rgba(36, 124, 175, .28);
    outline-offset: 2px;
}

.eba-source-logo {
    width: 150px;
    max-width: 35%;
    height: auto;
    display: block;
}

.eba-source-text {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.eba-source-text strong {
    line-height: 1.35;
}

.eba-source-text small {
    color: #647681;
    line-height: 1.35;
}

.evu-url-form label {
    display: block;
    margin-bottom: 7px;
    color: #183b54;
    font-size: .9rem;
    font-weight: 700;
}

.evu-url-form-row {
    display: flex;
    align-items: stretch;
    gap: 10px;
}

/*
 * min-width: 0 verhindert, dass eine lange URL den Inhaltsbereich über
 * seine verfügbare Breite hinausschiebt.
 */
.evu-url-input {
    min-width: 0;
    flex: 1 1 auto;
    padding: 11px 12px;
    border: 1px solid #b9c8d2;
    border-radius: 4px;
    color: #24323c;
    background: #fff;
}

.evu-url-input:hover {
    border-color: #829aaa;
}

.evu-url-input:focus {
    border-color: var(--admin-navbar);
    outline: 3px solid rgba(36, 124, 175, .2);
    outline-offset: 1px;
}

.evu-url-submit,
.evu-confirm-button,
.evu-cancel-button {
    border-radius: 4px;
    cursor: pointer;
}

.evu-url-submit,
.evu-confirm-button {
    border: 1px solid var(--admin-navbar-dark);
    color: #fff;
    background: var(--admin-navbar);
}

.evu-url-submit {
    flex: 0 0 auto;
    padding: 11px 20px;
}

.evu-url-submit:hover,
.evu-url-submit:focus-visible,
.evu-confirm-button:hover,
.evu-confirm-button:focus-visible {
    background: var(--admin-navbar-dark);
}

.evu-url-submit:focus-visible,
.evu-confirm-button:focus-visible,
.evu-cancel-button:focus-visible {
    outline: 3px solid rgba(36, 124, 175, .28);
    outline-offset: 2px;
}

.evu-url-help {
    display: block;
    margin-top: 8px;
    color: #647681;
    line-height: 1.45;
}

/*
 * Rückmeldungen stehen direkt am betroffenen URL-Feld. Die bestehenden
 * globalen Flashmessage-Klassen werden nur innerhalb dieser Seite optisch
 * als kompakte Hinweisboxen dargestellt.
 */
.evu-form-feedback {
    margin-top: 10px;
}

.evu-form-feedback .flashmsg {
    display: grid;
    gap: 6px;
    padding: 0;
}

.evu-form-feedback .flashmsg > div {
    padding: 9px 11px;
    border: 1px solid transparent;
    border-radius: 4px;
    line-height: 1.45;
}

.evu-form-feedback .flashmsg-success {
    border-color: #a9d6b6;
    color: #17622f;
    background: #edf8f0;
}

.evu-form-feedback .flashmsg-error {
    border-color: #e2aaaa;
    color: #8b1e1e;
    background: #fff0f0;
}

.evu-form-feedback .flashmsg-info {
    border-color: #a9ccdf;
    color: #164f79;
    background: #eef7fc;
}

.evu-form-feedback .flashmsg-warning {
    border-color: #e4c88e;
    color: #76540b;
    background: #fff8e8;
}

/*
 * Vorschau vor dem tatsächlichen Datenbankimport.
 */
.evu-import-preview {
    padding: 22px;
    border: 1px solid #b9cfdd;
    border-radius: 4px;
    background: #f6fafc;
}

.evu-preview-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.evu-preview-heading h3 {
    margin-bottom: 0;
}

.evu-preview-kicker {
    margin: 0 0 4px;
    color: var(--admin-navbar);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.evu-preview-status {
    flex: 0 0 auto;
    padding: 5px 8px;
    border-radius: 3px;
    color: #76540b;
    background: #fff0c9;
    font-size: .76rem;
    font-weight: 700;
}

.evu-preview-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin: 20px 0;
}

.evu-preview-stats > div {
    min-width: 0;
    padding: 12px;
    border: 1px solid #d3dfe6;
    border-radius: 4px;
    background: #fff;
}

.evu-preview-stats dt {
    color: #647681;
    font-size: .75rem;
}

.evu-preview-stats dd {
    margin: 4px 0 0;
    color: #183b54;
    font-size: 1.4rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.evu-preview-stats .is-new {
    border-top: 3px solid #2f9660;
}

.evu-preview-stats .is-changed {
    border-top: 3px solid #d89a28;
}

.evu-preview-stats .is-unchanged {
    border-top: 3px solid #8d9aa3;
}

.evu-preview-file,
.evu-preview-url,
.evu-preview-note {
    margin: 10px 0 0;
}

.evu-preview-url {
    overflow-wrap: anywhere;
}

.evu-preview-url code {
    color: #425968;
    font-size: .78rem;
}

.evu-preview-note {
    padding: 10px 12px;
    border-left: 3px solid var(--admin-navbar);
    background: #eaf4fa;
}

.evu-confirm-form {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.evu-confirm-button,
.evu-cancel-button {
    padding: 10px 16px;
}

.evu-cancel-button {
    border: 1px solid #aebdc7;
    color: #334c5d;
    background: #fff;
}

.evu-cancel-button:hover,
.evu-cancel-button:focus-visible {
    border-color: #768c9a;
    background: #eef2f4;
}

@media (max-width: 680px) {
    .evu-update-status-heading {
        flex-direction: column;
    }

    .evu-update-facts {
        grid-template-columns: 1fr;
    }

    .eba-source-link {
        width: 100%;
        align-items: flex-start;
        flex-direction: column;
    }

    .eba-source-logo {
        width: 140px;
        max-width: 70%;
    }

    .evu-url-form-row {
        align-items: stretch;
        flex-direction: column;
    }

    .evu-url-submit {
        width: 100%;
    }

    .evu-preview-heading {
        flex-direction: column;
    }

    .evu-preview-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .evu-confirm-form {
        flex-direction: column;
    }

    .evu-confirm-button,
    .evu-cancel-button {
        width: 100%;
    }
}

.sidebar-scrim {
    display: none;
}

.viewport-debug {
    position: fixed;
    z-index: 25;
    right: 14px;
    bottom: 14px;
    min-width: 156px;
    display: grid;
    gap: 2px;
    padding: 9px 12px;
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 4px;
    color: #fff;
    background: rgba(0, 35, 66, .92);
    box-shadow: 0 3px 10px rgba(0, 0, 0, .22);
    font-variant-numeric: tabular-nums;
    pointer-events: none;
}

.viewport-debug span {
    color: #8fc6e8;
    font-size: .68rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.viewport-debug strong {
    font-size: .95rem;
}

.viewport-debug small {
    color: #cce4f3;
    font-size: .72rem;
}

/* Desktop: Seitenleiste breit oder kompakt */
@media (min-width: 1220px) {
    .admin-shell.is-compact {
        grid-template-columns: var(--admin-sidebar-compact) minmax(0, 1fr);
    }

    .admin-shell.is-compact .sidebar-link span {
        display: none;
    }

    .admin-shell.is-compact .sidebar-link {
        justify-content: center;
        gap: 0;
        padding: 0;
    }

    .admin-shell.is-compact .sidebar-link .admin-icon {
        margin: 0;
    }
}

/* Tablet: kompakte Leiste; geöffnet als Drawer */
@media (min-width: 870px) and (max-width: 1219px) {
    .admin-shell {
        grid-template:
            "header header" var(--admin-header-height)
            "toolbar toolbar" var(--admin-toolbar-height)
            "sidebar content" 1fr
            / var(--admin-sidebar-compact) minmax(0, 1fr);
    }

    .admin-sidebar {
        position: fixed;
        top: calc(var(--admin-header-height) + var(--admin-toolbar-height));
        bottom: 0;
        left: 0;
        width: var(--admin-sidebar-compact);
        transition: width 180ms ease;
    }

    .admin-sidebar .sidebar-link span {
        display: none;
    }

    .admin-sidebar .sidebar-link {
        justify-content: center;
        gap: 0;
        padding: 0;
    }

    .admin-sidebar .sidebar-link .admin-icon {
        margin: 0;
    }

    .admin-shell.is-open .admin-sidebar {
        width: var(--admin-sidebar-wide);
    }

    .admin-shell.is-open .sidebar-link span {
        display: inline;
    }

    .admin-shell.is-open .sidebar-link {
        justify-content: flex-start;
        gap: 20px;
        padding: 0 24px;
    }

    /*
     * Die allgemeine Tablet-Regel setzt ausgeblendete Beschriftungen beim
     * Öffnen auf inline. Der Pfeil benötigt display:block, damit seine
     * Größe und Drehung zuverlässig erhalten bleiben.
     */
    .admin-shell.is-open .sidebar-group-toggle .submenu-chevron {
        display: block;
    }

    .admin-shell.is-open .sidebar-sublink {
        gap: 16px;
        padding-left: 56px;
    }

    .admin-shell.is-open .sidebar-scrim {
        position: fixed;
        z-index: 34;
        inset: calc(var(--admin-header-height) + var(--admin-toolbar-height)) 0 0 var(--admin-sidebar-compact);
        display: block;
        border: 0;
        background: rgba(0, 0, 0, .48);
    }
}

/* Smartphone: Menü verborgen; geöffnet als Drawer */
@media (max-width: 869px) {
    :root {
        --admin-header-height: 74px;
        --admin-toolbar-height: 56px;
    }

    .admin-shell {
        display: grid;
        grid-template:
            "header" var(--admin-header-height)
            "toolbar" var(--admin-toolbar-height)
            "content" 1fr
            / minmax(0, 1fr);
    }

    .admin-header {
        padding: 0 14px;
    }

    .header-button {
        width: 46px;
        height: 46px;
    }

    .admin-logo {
        display: none;
    }

    .admin-clock time {
        font-size: 1.75rem;
    }

    .admin-clock span {
        font-size: .78rem;
    }

    .admin-toolbar {
        padding-right: 12px;
        gap: 14px;
    }

    .admin-toolbar h1 {
        font-size: 1.1rem;
    }

    .toolbar-context {
        display: none;
    }

    .toolbar-user-label {
        display: none;
    }

    .toolbar-user-toggle {
        padding: 0 10px;
    }

    .admin-sidebar {
        position: fixed;
        z-index: 50;
        top: calc(var(--admin-header-height) + var(--admin-toolbar-height));
        bottom: 0;
        left: 0;
        width: min(82vw, 340px);
        transform: translateX(-105%);
        transition: transform 200ms ease;
    }

    .admin-shell.is-open .admin-sidebar {
        transform: translateX(0);
    }

    .admin-shell.is-open .sidebar-scrim {
        position: fixed;
        z-index: 45;
        inset: calc(var(--admin-header-height) + var(--admin-toolbar-height)) 0 0 0;
        display: block;
        border: 0;
        background: rgba(0, 0, 0, .55);
    }

    .admin-content {
        padding: 18px 14px;
    }

    .rights-role-summary,
    .rights-group-heading {
        flex-direction: column;
    }

    .rights-total {
        width: auto;
        min-width: 0;
    }

    .rights-item {
        grid-template-columns: minmax(0, 1fr);
        gap: 14px;
    }

    .rights-state {
        justify-content: space-between;
    }

    .rights-state-label {
        min-width: 0;
        text-align: left;
    }

    .customer-form-section {
        padding: 18px 14px;
    }

    .customer-list-title-row,
    .customer-list-result-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .customer-list-create {
        width: 100%;
    }

    .customer-list-search {
        padding: 15px;
    }

    .customer-list-search-row {
        flex-direction: column;
    }

    .customer-list-search input[type="search"] {
        min-width: 0;
        flex-basis: auto;
    }

    .customer-list-search button,
    .customer-list-search-reset {
        width: 100%;
        justify-content: center;
    }

    .customer-list-mobile-sort {
        display: grid;
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 9px;
        margin: 0 0 14px;
        padding: 14px;
        border: 1px solid #c8d7e0;
        border-radius: 4px;
        background: #f5f9fb;
    }

    .customer-list-mobile-sort label {
        grid-column: 1 / -1;
        margin: 0;
    }

    .customer-list-mobile-sort select {
        width: 100%;
        min-height: 42px;
        box-sizing: border-box;
        padding: 8px 10px;
        border: 1px solid #aebdc7;
        border-radius: 3px;
        color: #263f4f;
        background: #fff;
        font: inherit;
    }

    .customer-list-mobile-sort button {
        grid-column: 1 / -1;
        width: 100%;
    }

    .customer-list-table-wrapper {
        overflow: visible;
        border: 0;
        background: transparent;
        box-shadow: none;
    }

    .customer-list-table,
    .customer-list-table tbody,
    .customer-list-table tr,
    .customer-list-table td {
        display: block;
    }

    .customer-list-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        clip-path: inset(50%);
        white-space: nowrap;
    }

    .customer-list-table tbody {
        display: grid;
        gap: 12px;
    }

    .customer-list-table tr {
        overflow: hidden;
        border: 1px solid #c5d2da;
        border-radius: 4px;
        background: #fff;
        box-shadow: 0 3px 10px rgba(24, 59, 84, .08);
    }

    .customer-list-table tbody tr:nth-child(even),
    .customer-list-table tbody tr:hover {
        background: #fff;
    }

    .customer-list-table td,
    .customer-list-table td:nth-child(3),
    .customer-list-table td:nth-child(4),
    .customer-list-table td:last-child {
        width: auto;
        display: grid;
        grid-template-columns: minmax(92px, .42fr) minmax(0, 1fr);
        gap: 12px;
        padding: 11px 13px;
        border-bottom: 1px solid #e0e7eb;
        text-align: left;
    }

    .customer-list-table td::before {
        color: #607480;
        font-size: .72rem;
        font-weight: 700;
        letter-spacing: .04em;
        text-transform: uppercase;
        content: attr(data-label);
    }

    .customer-list-table td:last-child {
        border-bottom: 0;
    }

    .customer-access-count {
        flex-wrap: wrap;
    }

    .customer-detail-link {
        justify-self: start;
    }

    .customer-list-pagination {
        grid-template-columns: 1fr 1fr;
    }

    .customer-list-pagination strong {
        grid-column: 1 / -1;
        grid-row: 1;
    }

    .customer-form-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .customer-field-wide {
        grid-column: auto;
    }

    .customer-form-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .customer-account-credentials dl,
    .customer-account-meta {
        grid-template-columns: minmax(0, 1fr);
    }

    .customer-account-create,
    .customer-account-card-heading,
    .customer-account-actions {
        padding: 16px 14px;
    }

    .customer-account-create-form > div,
    .customer-account-email-form > div,
    .customer-account-card-heading,
    .customer-account-delete form {
        align-items: stretch;
        flex-direction: column;
    }

    .customer-account-create-form button,
    .customer-account-email-form button,
    .customer-account-button-row form,
    .customer-account-button-row button,
    .customer-account-delete button {
        width: 100%;
    }

    .booking-setting-combined-field > div,
    .booking-calendar-summary,
    .booking-slot-list {
        grid-template-columns: minmax(0, 1fr);
    }

    .booking-settings-updated {
        margin-right: 0;
        text-align: center;
    }

    .booking-calendar-toolbar {
        grid-template-columns: 46px minmax(0, 1fr) 46px;
    }

    .booking-calendar-toolbar h3 {
        font-size: 1rem;
    }

    .booking-calendar-day {
        min-height: 70px;
        gap: 5px;
        padding: 7px 5px;
    }

    .booking-calendar-day strong {
        min-width: 23px;
        height: 23px;
        font-size: .78rem;
    }

    .booking-calendar-day small {
        font-size: .6rem;
    }

    .booking-calendar-legend,
    .booking-slots-heading,
    .booking-slot-card {
        align-items: stretch;
        flex-direction: column;
    }

    .booking-slot-card button {
        width: 100%;
    }

    .customer-detail-title-row {
        align-items: stretch;
        flex-direction: column;
    }

    .customer-detail-actions {
        justify-content: stretch;
    }

    .customer-detail-actions a {
        flex: 1 1 150px;
    }

    .customer-eba-status {
        padding: 16px 14px;
    }

    .customer-eba-comparison-wrapper {
        overflow: visible;
        border: 0;
        background: transparent;
    }

    .customer-eba-comparison,
    .customer-eba-comparison tbody,
    .customer-eba-comparison tr,
    .customer-eba-comparison th,
    .customer-eba-comparison td {
        display: block;
    }

    .customer-eba-comparison {
        min-width: 0;
    }

    .customer-eba-comparison thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        clip-path: inset(50%);
        white-space: nowrap;
    }

    .customer-eba-comparison tbody {
        display: grid;
        gap: 12px;
    }

    .customer-eba-comparison tr {
        overflow: hidden;
        border: 1px solid #dbc68f;
        border-radius: 4px;
        background: #fff;
    }

    .customer-eba-comparison tbody th,
    .customer-eba-comparison td,
    .customer-eba-comparison td:nth-child(2),
    .customer-eba-comparison td:nth-child(3) {
        width: auto;
        max-width: none;
        display: grid;
        grid-template-columns: minmax(105px, .42fr) minmax(0, 1fr);
        gap: 10px;
        box-sizing: border-box;
        padding: 11px 12px;
        border-bottom: 1px solid #ece2d4;
    }

    .customer-eba-comparison th::before,
    .customer-eba-comparison td::before {
        color: #7b673e;
        font-size: .69rem;
        font-weight: 800;
        letter-spacing: .04em;
        text-transform: uppercase;
        content: attr(data-label);
    }

    .customer-eba-comparison td:last-child {
        border-bottom: 0;
    }

    .customer-eba-adopt-button {
        width: 100%;
    }

    .customer-form-cancel,
    .customer-form-submit {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .admin-shell,
    .admin-sidebar,
    .submenu-chevron,
    .rights-switch::after {
        transition: none;
    }
}

/* =======================================================================
   LEK-Portal: Ergänzungen für 2FA und das reduzierte Dashboard
========================================================================== */

.login-form form,
.login-form {
    margin: 0;
}

.login-button {
    border: 1px solid #17618e;
    border-radius: 3px;
    color: #fff;
    background: var(--admin-navbar, #247caf);
    cursor: pointer;
    font-weight: 700;
}

.login-button:hover,
.login-button:focus-visible {
    background: #176a9c;
}

.code-input {
    text-align: center;
    letter-spacing: .3em;
    font-size: 1.2rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.login-secondary-form {
    margin: 0 15px 10px;
    text-align: center;
}

.text-button {
    border: 0;
    color: var(--admin-navbar, #247caf);
    background: transparent;
    cursor: pointer;
    font: inherit;
    text-decoration: underline;
}

.text-button:hover,
.text-button:focus-visible {
    color: var(--admin-navbar-dark, #155b89);
}

.account-summary {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 24px 0 0;
}

.account-summary > div {
    min-width: 0;
    display: grid;
    gap: 5px;
    padding: 15px 17px;
    border: 1px solid #d5e0e7;
    border-radius: 4px;
    background: #f4f8fa;
}

.account-summary span {
    color: #657985;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.account-summary strong {
    overflow-wrap: anywhere;
    color: #183b54;
}

.dashboard-note {
    margin-bottom: 0;
    color: #4c616f;
}

@media (max-width: 680px) {
    .account-summary {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* =======================================================================
   Fragen-Datenbank / Frageneditor
========================================================================== */

.questions-page,
.question-editor-page {
    width: min(100%, 1500px);
    margin: 0 auto;
}

.page-heading-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 22px;
}

.page-heading-row h2 {
    margin: 4px 0 8px;
    color: #183b54;
    font-size: clamp(1.55rem, 3vw, 2.15rem);
}

.page-introduction {
    max-width: 820px;
    margin: 0;
    color: #536b7a;
    line-height: 1.55;
}

.heading-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.primary-action,
.secondary-action,
.block-toolbar button,
.inline-add,
.metadata-add-form button,
.metadata-row-form button {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 14px;
    border-radius: 4px;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.primary-action {
    border: 1px solid #16699c;
    color: #fff;
    background: var(--admin-navbar);
}

.primary-action:hover,
.primary-action:focus-visible {
    background: #176a9c;
}

.secondary-action {
    border: 1px solid #aebec8;
    color: #234f6c;
    background: #fff;
}

.secondary-action:hover,
.secondary-action:focus-visible {
    background: #eaf2f7;
}

.page-flash,
.form-error {
    margin: 0 0 18px;
    padding: 12px 14px;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(31, 54, 68, .08);
}

.form-error {
    border-left: 4px solid #b42318;
    color: #842015;
    background: #fff5f4;
}

.editor-inline-message {
    margin: 0 0 18px;
    padding: 12px 14px;
    border-radius: 4px;
    background: #f4f8fb;
    color: #234f6c;
    border-left: 4px solid #2c6f9e;
    box-shadow: 0 2px 8px rgba(31, 54, 68, .08);
    line-height: 1.45;
}

.editor-inline-message[hidden] {
    display: none;
}

.editor-inline-message.is-error {
    border-left-color: #b42318;
    color: #842015;
    background: #fff5f4;
}

.editor-inline-message.is-warning {
    border-left-color: #c48800;
    color: #5d4400;
    background: #fff8df;
}

.editor-inline-message.is-success {
    border-left-color: #2f7d4a;
    color: #245f39;
    background: #f1faf4;
}

.editor-inline-message.is-info {
    border-left-color: #2c6f9e;
    color: #234f6c;
    background: #f4f8fb;
}

.question-list-card,
.editor-panel,
.preview-meta-card,
.exam-question-sheet,
.metadata-admin-card {
    border: 1px solid #d3dde3;
    border-radius: 5px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(26, 48, 63, .08);
}

.responsive-table-wrap {
    overflow-x: auto;
}

.question-table {
    width: 100%;
    border-collapse: collapse;
    font-size: .9rem;
}

.question-table th,
.question-table td {
    padding: 13px 14px;
    border-bottom: 1px solid #e0e7eb;
    vertical-align: top;
    text-align: left;
}

.question-table th {
    color: #315b75;
    background: #eef5f8;
    font-size: .76rem;
    letter-spacing: .03em;
    text-transform: uppercase;
}

.question-table tbody tr:hover {
    background: #f8fbfc;
}

.question-table td small,
.table-meta-line {
    display: block;
}

.question-table td small {
    margin-top: 4px;
    color: #677b87;
}

.question-actions {
    white-space: nowrap;
}

.question-actions a {
    display: block;
    margin: 0 0 5px;
    color: #176d9f;
    font-weight: 700;
    text-decoration: none;
}

.status-badge {
    display: inline-block;
    padding: 4px 7px;
    border-radius: 999px;
    background: #e8eef2;
    font-size: .72rem;
    font-weight: 800;
}

.status-approved { color: #176b37; background: #e5f5eb; }
.status-reviewed { color: #68520e; background: #fff5cf; }
.status-clarification { color: #8a3c11; background: #fff0e6; }
.status-archived { color: #69747a; background: #edf0f2; }
.status-draft { color: #245d80; background: #e4f1f8; }

.empty-state {
    padding: 50px 28px;
    color: #536b7a;
    text-align: center;
}

.empty-state strong {
    display: block;
    margin-bottom: 6px;
    color: #244b64;
    font-size: 1.15rem;
}

.question-editor-form {
    display: grid;
    gap: 22px;
}

.editor-panel {
    padding: clamp(18px, 3vw, 30px);
}

.editor-panel-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
    padding-bottom: 17px;
    border-bottom: 1px solid #dce5e9;
}

.editor-panel-heading > div:first-child {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.editor-panel-heading h3 {
    margin: 0;
    color: #183b54;
    font-size: 1.15rem;
}

.editor-panel-heading p {
    margin: 4px 0 0;
    color: #667a86;
    line-height: 1.45;
}

.editor-panel-heading.compact {
    margin-bottom: 18px;
}

.editor-step {
    width: 30px;
    height: 30px;
    display: grid;
    flex: 0 0 30px;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    background: var(--admin-navbar);
    font-weight: 800;
}

.points-summary {
    min-width: 115px;
    padding: 9px 12px;
    border-radius: 4px;
    color: #fff;
    background: #183b54;
    text-align: center;
}

.points-summary small,
.points-summary strong {
    display: block;
}

.points-summary small {
    color: #cfe1eb;
    font-size: .72rem;
}

.points-summary strong {
    margin-top: 2px;
    font-size: 1.3rem;
}

.form-grid {
    display: grid;
    gap: 15px 18px;
}

.form-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.field-span-2 { grid-column: span 2; }
.compact-grid { gap: 10px 14px; }

.field {
    min-width: 0;
    display: block;
}

.field > span,
.field > label > span {
    display: block;
    margin-bottom: 5px;
    color: #315b75;
    font-size: .82rem;
    font-weight: 700;
}

.field > span small {
    color: #82919a;
    font-weight: 500;
}

.field input[type="text"],
.field input[type="number"],
.field input[type="file"],
.field textarea,
.field select,
.metadata-add-form input,
.metadata-row-form input[type="text"] {
    width: 100%;
    min-height: 40px;
    padding: 8px 10px;
    border: 1px solid #b9c7d0;
    border-radius: 3px;
    color: #283b47;
    background: #fff;
    font: inherit;
}

.field textarea {
    resize: vertical;
    line-height: 1.45;
}

.field input:focus,
.field textarea:focus,
.field select:focus,
.metadata-add-form input:focus,
.metadata-row-form input:focus {
    border-color: var(--admin-navbar);
    outline: 3px solid rgba(36, 124, 175, .14);
}

.input-suffix {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: stretch;
}

.input-suffix input {
    border-radius: 3px 0 0 3px !important;
}

.input-suffix > span {
    display: flex;
    align-items: center;
    padding: 0 10px;
    border: 1px solid #b9c7d0;
    border-left: 0;
    border-radius: 0 3px 3px 0;
    color: #617682;
    background: #f1f5f7;
    font-size: .82rem;
}

.metadata-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-top: 20px;
}

.metadata-choice-group {
    min-width: 0;
    margin: 0;
    padding: 13px;
    border: 1px solid #d0dce3;
    border-radius: 4px;
}

.metadata-choice-group legend {
    padding: 0 5px;
    color: #315b75;
    font-size: .8rem;
    font-weight: 800;
}

.check-list {
    max-height: 180px;
    overflow: auto;
}

.check-list label,
.block-rulebooks label {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 5px 3px;
    color: #384e5c;
    font-size: .86rem;
    line-height: 1.3;
}

.check-list input,
.block-rulebooks input {
    margin-top: 2px;
}

.metadata-hint {
    margin: 14px 0 0;
    color: #637885;
    font-size: .82rem;
}

.metadata-hint a {
    color: #176d9f;
}

.block-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
}

.block-toolbar button,
.inline-add {
    min-height: 36px;
    border: 1px solid #abc0cd;
    color: #245975;
    background: #f5f9fb;
}

.block-toolbar button:hover,
.inline-add:hover {
    background: #e3eff5;
}

.block-toolbar .signal-add-button {
    border-color: #779ab0;
    color: #fff;
    background: #315f7b;
}

.block-toolbar .signal-add-button:hover {
    background: #244e68;
}

.question-block-list {
    display: grid;
    gap: 18px;
}

.question-block {
    position: relative;
    padding: 18px;
    border: 1px solid #cbd8df;
    border-left: 4px solid #7fa9c1;
    border-radius: 4px;
    background: #fbfcfd;
}

.question-block-signal_single,
.question-block-signal_block {
    border-left-color: #315f7b;
    background: #f8fbfd;
}

.question-block-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
    margin: -18px -18px 17px;
    padding: 11px 14px;
    border-bottom: 1px solid #d9e3e8;
    background: #eef4f7;
}

.block-type-label {
    color: #214b65;
    font-size: .83rem;
    font-weight: 800;
    letter-spacing: .03em;
    text-transform: uppercase;
}

.block-actions {
    display: flex;
    gap: 5px;
}

.block-actions button,
.danger-ghost {
    min-height: 30px;
    padding: 4px 8px;
    border: 1px solid #b8c6ce;
    border-radius: 3px;
    color: #405965;
    background: #fff;
    font: inherit;
    cursor: pointer;
}

.danger-ghost {
    color: #8c2e24 !important;
}

.block-rulebooks {
    display: flex;
    flex-wrap: wrap;
    gap: 3px 12px;
    padding: 5px 8px;
    border: 1px solid #d7e0e5;
    border-radius: 3px;
    background: #fff;
}

.block-rulebook-empty {
    margin: 8px 0;
    color: #82919a;
    font-size: .8rem;
}

.image-editor {
    margin: 10px 0;
}

.existing-image {
    width: min(100%, 360px);
    margin-top: 8px;
    padding: 8px;
    border: 1px solid #d4dfe5;
    border-radius: 3px;
    background: #fff;
}

.existing-image img {
    max-width: 100%;
    max-height: 220px;
    display: block;
    margin: 0 auto 7px;
    object-fit: contain;
}

.existing-image label {
    color: #774b45;
    font-size: .78rem;
}

.answer-layout-grid {
    display: grid;
    grid-template-columns: minmax(230px, .8fr) minmax(260px, 1.2fr);
    gap: 18px;
}

.subeditor-heading,
.signal-row-topline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 13px 0 8px;
    color: #315b75;
}

.subeditor-heading small {
    color: #87959c;
    font-weight: 500;
}

.choice-option-row,
.criterion-row {
    display: grid;
    align-items: center;
    gap: 8px;
    margin-bottom: 7px;
}

.choice-option-row {
    grid-template-columns: auto minmax(0, 1fr) auto;
}

.criterion-row {
    grid-template-columns: minmax(0, 1fr) 105px auto;
}

.choice-option-row > input,
.criterion-row > input,
.criterion-row label input {
    width: 100%;
    min-height: 38px;
    padding: 7px 9px;
    border: 1px solid #bdcbd3;
    border-radius: 3px;
    font: inherit;
}

.choice-correct {
    min-width: 76px;
    display: flex;
    align-items: center;
    gap: 5px;
    color: #386277;
    font-size: .78rem;
}

.criterion-row label {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #536b79;
    font-size: .8rem;
}

.signal-single-editor,
.signal-editor-row {
    display: grid;
    grid-template-columns: minmax(180px, 32%) minmax(0, 68%);
    gap: 18px;
    align-items: stretch;
}

.signal-single-editor {
    margin-top: 12px;
    padding: 14px;
    border: 1px solid #bcced9;
    background: #fff;
}

.signal-editor-rows {
    display: grid;
    gap: 12px;
    margin: 12px 0;
}

.signal-editor-row {
    padding: 12px;
    border: 1px solid #c5d4dc;
    border-radius: 3px;
    background: #fff;
}

.signal-editor-image {
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 8px;
    border-right: 1px solid #dae3e8;
}

.signal-editor-answer {
    min-width: 0;
}

.signal-block-note {
    margin: 10px 0;
    padding: 10px 12px;
    border-left: 3px solid #315f7b;
    color: #4a6676;
    background: #eaf3f7;
    font-size: .82rem;
    line-height: 1.45;
}

.history-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 24px;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid #dde5e9;
    color: #667984;
    font-size: .8rem;
}

.sticky-savebar {
    position: sticky;
    z-index: 20;
    bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 12px 14px;
    border: 1px solid #aebfca;
    border-radius: 5px;
    color: #264b62;
    background: rgba(255,255,255,.96);
    box-shadow: 0 8px 24px rgba(19, 43, 57, .18);
    backdrop-filter: blur(6px);
}

.dashboard-feature-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: 24px;
}

.dashboard-feature-card {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 4px 12px;
    padding: 16px;
    border: 1px solid #cad8e0;
    border-radius: 4px;
    color: #345363;
    background: #f7fafb;
    text-decoration: none;
}

.dashboard-feature-card:hover {
    border-color: #8fb2c5;
    background: #edf5f8;
}

.dashboard-feature-card .feature-icon {
    grid-row: 1 / span 2;
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 4px;
    background: #dcecf4;
}

.dashboard-feature-card strong {
    color: #214d67;
}

.dashboard-feature-card > span:last-child {
    font-size: .84rem;
    line-height: 1.4;
}

/* Stammdaten */
.metadata-admin-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.metadata-admin-card {
    padding: 18px;
}

.metadata-admin-card h3 {
    margin: 0 0 14px;
    color: #214d67;
}

.metadata-add-form,
.metadata-row-form {
    display: grid;
    gap: 7px;
}

.metadata-add-form {
    grid-template-columns: minmax(0, 1fr) auto;
    margin-bottom: 14px;
}

.metadata-add-form button,
.metadata-row-form button {
    min-height: 38px;
    border: 1px solid #8da9ba;
    color: #245975;
    background: #eef5f8;
}

.metadata-admin-list {
    display: grid;
    gap: 7px;
}

.metadata-row-form {
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    padding-top: 7px;
    border-top: 1px solid #e1e7eb;
}

.active-toggle {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #526a78;
    font-size: .78rem;
}

/* Fragenvorschau – an das Word-Prüfungsbild angelehnt */
.preview-meta-card {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 24px;
    margin-bottom: 18px;
    padding: 13px 16px;
    color: #4e6572;
}

.preview-meta-card strong {
    margin-right: auto;
    color: #203f53;
}

.exam-question-sheet {
    width: min(100%, 900px);
    margin: 0 auto;
    padding: 26px 28px 36px;
    color: #111;
    background: #fff;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 15px;
}

.exam-question-titlebar {
    margin-bottom: 8px;
    padding: 5px 8px;
    background: #e6e6e6;
    font-weight: 700;
    text-decoration: underline;
}

.preview-text-block,
.preview-part,
.preview-standalone-image {
    margin: 12px 0 22px;
}

.preview-part-label,
.preview-prompt strong {
    margin-right: 7px;
}

.preview-prompt {
    margin-bottom: 8px;
    line-height: 1.35;
}

.preview-standalone-image {
    width: 70%;
    margin-right: auto;
    margin-left: auto;
    text-align: center;
}

.preview-standalone-image.preview-width-20 { width: 20%; }
.preview-standalone-image.preview-width-21 { width: 21%; }
.preview-standalone-image.preview-width-22 { width: 22%; }
.preview-standalone-image.preview-width-23 { width: 23%; }
.preview-standalone-image.preview-width-24 { width: 24%; }
.preview-standalone-image.preview-width-25 { width: 25%; }
.preview-standalone-image.preview-width-26 { width: 26%; }
.preview-standalone-image.preview-width-27 { width: 27%; }
.preview-standalone-image.preview-width-28 { width: 28%; }
.preview-standalone-image.preview-width-29 { width: 29%; }
.preview-standalone-image.preview-width-30 { width: 30%; }
.preview-standalone-image.preview-width-31 { width: 31%; }
.preview-standalone-image.preview-width-32 { width: 32%; }
.preview-standalone-image.preview-width-33 { width: 33%; }
.preview-standalone-image.preview-width-34 { width: 34%; }
.preview-standalone-image.preview-width-35 { width: 35%; }
.preview-standalone-image.preview-width-36 { width: 36%; }
.preview-standalone-image.preview-width-37 { width: 37%; }
.preview-standalone-image.preview-width-38 { width: 38%; }
.preview-standalone-image.preview-width-39 { width: 39%; }
.preview-standalone-image.preview-width-40 { width: 40%; }
.preview-standalone-image.preview-width-41 { width: 41%; }
.preview-standalone-image.preview-width-42 { width: 42%; }
.preview-standalone-image.preview-width-43 { width: 43%; }
.preview-standalone-image.preview-width-44 { width: 44%; }
.preview-standalone-image.preview-width-45 { width: 45%; }
.preview-standalone-image.preview-width-46 { width: 46%; }
.preview-standalone-image.preview-width-47 { width: 47%; }
.preview-standalone-image.preview-width-48 { width: 48%; }
.preview-standalone-image.preview-width-49 { width: 49%; }
.preview-standalone-image.preview-width-50 { width: 50%; }
.preview-standalone-image.preview-width-51 { width: 51%; }
.preview-standalone-image.preview-width-52 { width: 52%; }
.preview-standalone-image.preview-width-53 { width: 53%; }
.preview-standalone-image.preview-width-54 { width: 54%; }
.preview-standalone-image.preview-width-55 { width: 55%; }
.preview-standalone-image.preview-width-56 { width: 56%; }
.preview-standalone-image.preview-width-57 { width: 57%; }
.preview-standalone-image.preview-width-58 { width: 58%; }
.preview-standalone-image.preview-width-59 { width: 59%; }
.preview-standalone-image.preview-width-60 { width: 60%; }
.preview-standalone-image.preview-width-61 { width: 61%; }
.preview-standalone-image.preview-width-62 { width: 62%; }
.preview-standalone-image.preview-width-63 { width: 63%; }
.preview-standalone-image.preview-width-64 { width: 64%; }
.preview-standalone-image.preview-width-65 { width: 65%; }
.preview-standalone-image.preview-width-66 { width: 66%; }
.preview-standalone-image.preview-width-67 { width: 67%; }
.preview-standalone-image.preview-width-68 { width: 68%; }
.preview-standalone-image.preview-width-69 { width: 69%; }
.preview-standalone-image.preview-width-70 { width: 70%; }
.preview-standalone-image.preview-width-71 { width: 71%; }
.preview-standalone-image.preview-width-72 { width: 72%; }
.preview-standalone-image.preview-width-73 { width: 73%; }
.preview-standalone-image.preview-width-74 { width: 74%; }
.preview-standalone-image.preview-width-75 { width: 75%; }
.preview-standalone-image.preview-width-76 { width: 76%; }
.preview-standalone-image.preview-width-77 { width: 77%; }
.preview-standalone-image.preview-width-78 { width: 78%; }
.preview-standalone-image.preview-width-79 { width: 79%; }
.preview-standalone-image.preview-width-80 { width: 80%; }
.preview-standalone-image.preview-width-81 { width: 81%; }
.preview-standalone-image.preview-width-82 { width: 82%; }
.preview-standalone-image.preview-width-83 { width: 83%; }
.preview-standalone-image.preview-width-84 { width: 84%; }
.preview-standalone-image.preview-width-85 { width: 85%; }
.preview-standalone-image.preview-width-86 { width: 86%; }
.preview-standalone-image.preview-width-87 { width: 87%; }
.preview-standalone-image.preview-width-88 { width: 88%; }
.preview-standalone-image.preview-width-89 { width: 89%; }
.preview-standalone-image.preview-width-90 { width: 90%; }
.preview-standalone-image.preview-width-91 { width: 91%; }
.preview-standalone-image.preview-width-92 { width: 92%; }
.preview-standalone-image.preview-width-93 { width: 93%; }
.preview-standalone-image.preview-width-94 { width: 94%; }
.preview-standalone-image.preview-width-95 { width: 95%; }
.preview-standalone-image.preview-width-96 { width: 96%; }
.preview-standalone-image.preview-width-97 { width: 97%; }
.preview-standalone-image.preview-width-98 { width: 98%; }
.preview-standalone-image.preview-width-99 { width: 99%; }
.preview-standalone-image.preview-width-100 { width: 100%; }

.preview-standalone-image img,
.preview-inline-image img,
.signal-question-image img,
.signal-table-image img {
    max-width: 100%;
    max-height: 430px;
    object-fit: contain;
}

.preview-image-placeholder {
    min-height: 110px;
    display: grid;
    place-items: center;
    border: 1px dashed #999;
    color: #777;
    background: #fafafa;
    font-size: .8rem;
}

.preview-answer-with-image {
    display: grid;
    gap: 16px;
}

.preview-answer-with-image.image-left {
    grid-template-columns: minmax(150px, 34%) minmax(0, 66%);
}

.preview-answer-with-image.image-right {
    grid-template-columns: minmax(0, 66%) minmax(150px, 34%);
}

.preview-answer-with-image.image-right .preview-inline-image {
    grid-column: 2;
    grid-row: 1;
}

.preview-answer-with-image.image-right .preview-answer-content {
    grid-column: 1;
    grid-row: 1;
}

.preview-answer-with-image.image-top {
    grid-template-columns: 1fr;
}

.preview-inline-image {
    text-align: center;
}

.answer-lines {
    display: grid;
    gap: 11px;
    margin-top: 9px;
}

.answer-lines span {
    display: block;
    height: 17px;
    border-bottom: 1px solid #333;
}

.preview-choice-list {
    display: grid;
    gap: 8px;
    margin: 10px 0;
}

.preview-choice {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    gap: 9px;
    align-items: start;
}

.choice-box {
    width: 13px;
    height: 13px;
    display: inline-grid;
    place-items: center;
    margin-top: 2px;
    border: 1px solid #333;
    line-height: 1;
}

.exam-question-sheet.is-solution .preview-choice.is-correct,
.solution-answer,
.solution-criteria,
.exam-question-sheet.is-solution .signal-question-answer,
.exam-question-sheet.is-solution .signal-table-answer {
    color: #d71920;
}

.preview-points {
    margin-top: 8px;
    text-align: right;
    font-family: Georgia, serif;
}

.preview-total {
    margin-top: 36px;
    font-weight: 700;
    text-align: right;
}

.signal-question-layout,
.signal-table-row {
    display: grid;
    grid-template-columns: minmax(150px, 30%) minmax(0, 70%);
    border: 1px solid #999;
}

.signal-question-image,
.signal-table-image {
    min-height: 150px;
    display: grid;
    place-items: center;
    padding: 12px;
    border-right: 1px solid #999;
}

.signal-question-answer,
.signal-table-answer {
    min-height: 150px;
    padding: 10px 14px;
}

.signal-question-answer > div,
.signal-table-answer > div {
    margin-bottom: 10px;
    line-height: 1.4;
}

.signal-table-preview {
    border-top: 1px solid #999;
}

.signal-table-row {
    border-top: 0;
}

.signal-table-row + .signal-table-row {
    border-top: 0;
}

.signal-table-answer .answer-lines {
    margin-top: 0;
}

.row-points {
    margin-top: 4px !important;
}

@media (max-width: 980px) {
    .form-grid-3,
    .metadata-grid,
    .metadata-admin-grid {
        grid-template-columns: 1fr 1fr;
    }

    .metadata-grid > :last-child,
    .metadata-admin-grid > :last-child {
        grid-column: 1 / -1;
    }

    .signal-single-editor,
    .signal-editor-row,
    .answer-layout-grid {
        grid-template-columns: 1fr;
    }

    .signal-editor-image {
        border-right: 0;
        border-bottom: 1px solid #dae3e8;
    }
}

@media (max-width: 680px) {
    .page-heading-row,
    .editor-panel-heading,
    .sticky-savebar {
        align-items: stretch;
        flex-direction: column;
    }

    .heading-actions,
    .heading-actions a {
        width: 100%;
    }

    .form-grid-2,
    .form-grid-3,
    .metadata-grid,
    .metadata-admin-grid,
    .dashboard-feature-grid,
    .preview-answer-with-image.image-left,
    .preview-answer-with-image.image-right,
    .signal-question-layout,
    .signal-table-row {
        grid-template-columns: 1fr;
    }

    .field-span-2,
    .metadata-grid > :last-child,
    .metadata-admin-grid > :last-child {
        grid-column: auto;
    }

    .signal-question-image,
    .signal-table-image {
        border-right: 0;
        border-bottom: 1px solid #999;
    }

    .preview-answer-with-image.image-right .preview-inline-image,
    .preview-answer-with-image.image-right .preview-answer-content {
        grid-column: auto;
        grid-row: auto;
    }

    .metadata-row-form {
        grid-template-columns: 1fr auto;
    }

    .metadata-row-form input[type="text"] {
        grid-column: 1 / -1;
    }

    .exam-question-sheet {
        padding: 18px 14px 28px;
    }
}

.signal-question-layout.signal-position-right .signal-question-image {
    grid-column: 2;
    grid-row: 1;
    border-right: 0;
    border-left: 1px solid #999;
}

.signal-question-layout.signal-position-right .signal-question-answer {
    grid-column: 1;
    grid-row: 1;
}

.signal-answer-lines-only {
    display: flex;
    align-items: center;
    min-height: 100%;
}

.signal-answer-lines-only .answer-lines {
    width: 100%;
    margin: 0;
}

@media (max-width: 680px) {
    .signal-question-layout.signal-position-right .signal-question-image,
    .signal-question-layout.signal-position-right .signal-question-answer {
        grid-column: auto;
        grid-row: auto;
        border-left: 0;
    }

    .signal-question-layout.signal-position-right .signal-question-image {
        border-bottom: 1px solid #999;
    }
}

.history-list {
    display: grid;
}

.history-entry {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 18px;
    padding: 17px 20px;
    border-bottom: 1px solid #e0e7eb;
}

.history-entry:last-child {
    border-bottom: 0;
}

.history-version {
    color: #245d80;
    font-weight: 800;
}

.history-entry strong,
.history-entry span {
    display: block;
}

.history-entry span {
    margin-top: 3px;
    color: #6b7e89;
    font-size: .82rem;
}

.history-entry p {
    margin: 8px 0 0;
    color: #425966;
}

@media (max-width: 520px) {
    .history-entry {
        grid-template-columns: 1fr;
        gap: 5px;
    }
}

/* =======================================================================
   Visueller Frageneditor v2
   Reduziert die technische Bausteinmaske auf eine prüfungsblattartige
   Schritt-für-Schritt-Oberfläche.
========================================================================== */

.visual-question-editor {
    --visual-paper: #ffffff;
    --visual-border: #d7e0e5;
    --visual-soft: #f4f7f9;
    --visual-muted: #657986;
    --visual-text: #1f3645;
    --visual-accent: #196d9f;
    --visual-accent-soft: #e9f4fa;
}

.visual-editor-heading {
    margin-bottom: 16px;
}

.visual-question-form {
    gap: 14px;
}

.visual-editor-tabs {
    display: flex;
    gap: 4px;
    padding: 5px;
    border: 1px solid #d4dee4;
    border-radius: 7px;
    background: #eef3f6;
}

.visual-editor-tabs button {
    min-height: 42px;
    padding: 9px 18px;
    border: 0;
    border-radius: 5px;
    color: #4d6675;
    background: transparent;
    font: inherit;
    font-weight: 750;
    cursor: pointer;
}

.visual-editor-tabs button.is-active {
    color: #173f59;
    background: #fff;
    box-shadow: 0 1px 5px rgba(27, 49, 63, .12);
}

.visual-tab-panel[hidden] {
    display: none !important;
}

.visual-editor-summarybar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin: 4px 0 12px;
    padding: 8px 4px;
    color: #536b79;
}

.visual-editor-summarybar > div:first-child {
    display: grid;
    gap: 2px;
}

.visual-editor-summarybar strong {
    color: #244c65;
}

.visual-editor-summarybar span {
    font-size: .86rem;
}

.visual-summary-values {
    display: flex;
    gap: 14px;
    white-space: nowrap;
}

.visual-question-sheet {
    width: min(100%, 940px);
    min-height: 620px;
    margin: 0 auto;
    padding: 34px 34px 44px;
    border: 1px solid #cbd6dd;
    border-radius: 4px;
    background: var(--visual-paper);
    box-shadow: 0 8px 28px rgba(29, 49, 61, .12);
}

.visual-question-titlebar {
    margin: -8px 0 8px;
    padding: 7px 10px;
    color: #1f2f39;
    background: #e4e4e4;
    font-weight: 800;
    text-decoration: underline;
}

.visual-question-help {
    margin-bottom: 22px;
    padding: 10px 12px;
    border-left: 3px solid #8fb8cf;
    color: #5b707d;
    background: #f7fafb;
    font-size: .83rem;
    line-height: 1.45;
}

.visual-block-list {
    display: block;
}

.visual-editor-block {
    position: relative;
    padding: 12px 10px 14px;
    border: 1px solid transparent;
    border-radius: 5px;
    background: #fff;
    transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.visual-editor-block:hover,
.visual-editor-block:focus-within {
    border-color: #c7d7e1;
    box-shadow: 0 2px 9px rgba(34, 59, 74, .07);
}

.visual-editor-block.is-dragging {
    opacity: .55;
    border-color: #7aaac5;
}

.visual-editor-block.is-task {
    padding: 2px 4px 8px;
    border-color: transparent;
    box-shadow: none;
}

.visual-editor-block.is-task:hover,
.visual-editor-block.is-task:focus-within {
    border-color: transparent;
    box-shadow: none;
}

.visual-editor-block.is-task .visual-text-row textarea {
    padding-left: 4px;
    padding-right: 4px;
}

.visual-block-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 28px;
    margin-bottom: 7px;
    color: #6b7c86;
    opacity: .4;
    transition: opacity .15s ease;
}

.visual-editor-block:hover .visual-block-topbar,
.visual-editor-block:focus-within .visual-block-topbar {
    opacity: 1;
}

.visual-block-kind {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .02em;
    text-transform: uppercase;
}

.visual-drag-handle {
    font-size: 1rem;
    cursor: grab;
    user-select: none;
}

.is-task .visual-drag-handle {
    display: none;
}

.visual-required-badge {
    font-size: .7rem;
    font-weight: 700;
}

.visual-block-actions {
    display: flex;
    gap: 4px;
}

.visual-block-actions button,
.visual-image-toolbar button,
.visual-inline-controls button,
.visual-row-remove,
.visual-menu-close {
    min-width: 30px;
    min-height: 30px;
    padding: 3px 7px;
    border: 1px solid #cdd8df;
    border-radius: 4px;
    color: #3f5c6d;
    background: #fff;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.visual-block-actions button:hover,
.visual-image-toolbar button:hover,
.visual-inline-controls button:hover {
    background: #eef5f8;
}

.visual-text-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 10px;
}

.visual-text-row.has-part-label {
    grid-template-columns: 32px minmax(0, 1fr);
}

.visual-part-label {
    padding-top: 10px;
    color: #1f2f39;
    font-size: 1rem;
}

.visual-editor-block textarea,
.visual-editor-block input[type="text"] {
    font: inherit;
}

.visual-text-row textarea,
.visual-optional-prompt {
    width: 100%;
    min-height: 44px;
    padding: 8px 7px;
    overflow: hidden;
    resize: none;
    border: 1px solid transparent;
    border-radius: 3px;
    color: #172b37;
    background: transparent;
    line-height: 1.43;
}

.visual-text-row textarea {
    font-size: 1rem;
}

.visual-text-row textarea:hover,
.visual-optional-prompt:hover {
    border-color: #e1e8ec;
}

.visual-text-row textarea:focus,
.visual-optional-prompt:focus {
    outline: none;
    border-color: #77a9c6;
    background: #fbfdfe;
    box-shadow: 0 0 0 2px rgba(37, 118, 166, .09);
}

.visual-text-row textarea::placeholder,
.visual-optional-prompt::placeholder {
    color: #8a9ba5;
}

.visual-legacy-label {
    margin: 0 0 5px 7px;
    font-weight: 800;
}

.visual-add-zone {
    display: flex;
    justify-content: center;
    min-height: 26px;
    margin: 0;
}

.visual-add-zone-between {
    height: 32px;
    align-items: center;
}

.visual-add-zone-last {
    margin-top: 12px;
    padding: 14px 0;
    border-top: 1px dashed #ccd8df;
}

.visual-add-button {
    min-height: 30px;
    padding: 5px 13px;
    border: 1px dashed #a9bfcc;
    border-radius: 999px;
    color: #42677e;
    background: #fff;
    font: inherit;
    font-size: .78rem;
    font-weight: 800;
    cursor: pointer;
    opacity: .56;
    transition: opacity .15s ease, background .15s ease, border-color .15s ease;
}

.visual-add-zone:hover .visual-add-button,
.visual-add-button:focus-visible,
.visual-add-zone-last .visual-add-button {
    opacity: 1;
}

.visual-add-button:hover {
    border-color: #6d9db8;
    background: #f0f7fa;
}

.visual-block-menu[hidden] {
    display: none;
}

.visual-block-menu {
    position: fixed;
    inset: 0;
    z-index: 5000;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(24, 42, 53, .48);
}

.visual-menu-open {
    overflow: hidden;
}

.visual-block-menu-card {
    width: min(720px, 100%);
    max-height: min(760px, calc(100vh - 40px));
    overflow: auto;
    padding: 20px;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 24px 70px rgba(9, 26, 37, .32);
}

.visual-block-menu-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.visual-block-menu-head > div {
    display: grid;
    gap: 4px;
}

.visual-block-menu-head strong {
    color: #1d435b;
    font-size: 1.15rem;
}

.visual-block-menu-head span {
    color: #657986;
    font-size: .84rem;
}

.visual-menu-close {
    font-size: 1.2rem;
}

.visual-block-menu-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.visual-block-menu-grid > button {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    grid-template-rows: auto auto;
    gap: 2px 12px;
    min-height: 78px;
    padding: 12px;
    border: 1px solid #d5e0e6;
    border-radius: 6px;
    text-align: left;
    color: #24495f;
    background: #fff;
    font: inherit;
    cursor: pointer;
}

.visual-block-menu-grid > button:hover,
.visual-block-menu-grid > button:focus-visible {
    outline: none;
    border-color: #75a9c5;
    background: #f3f9fc;
}

.visual-block-icon {
    grid-row: 1 / 3;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 6px;
    color: #286c94;
    background: #e9f4fa;
    font-size: 1.05rem;
    font-weight: 900;
}

.visual-block-menu-grid strong {
    align-self: end;
}

.visual-block-menu-grid small {
    align-self: start;
    color: #6a7e89;
}

.visual-image-control {
    margin: 3px 0 10px;
}

.visual-image-stage {
    display: flex;
    justify-content: center;
    width: 100%;
    min-height: 150px;
    padding: 10px;
    border: 1px dashed #c7d4dc;
    border-radius: 4px;
    background: #fafcfd;
}

.visual-image-control[data-align="left"] .visual-image-stage {
    justify-content: flex-start;
}

.visual-image-control[data-align="right"] .visual-image-stage {
    justify-content: flex-end;
}

.visual-image-stage img {
    display: block;
    width: 70%;
    max-height: 520px;
    object-fit: contain;
}


.visual-image-width-20 .visual-image-stage img { width: 20%; }
.visual-image-width-21 .visual-image-stage img { width: 21%; }
.visual-image-width-22 .visual-image-stage img { width: 22%; }
.visual-image-width-23 .visual-image-stage img { width: 23%; }
.visual-image-width-24 .visual-image-stage img { width: 24%; }
.visual-image-width-25 .visual-image-stage img { width: 25%; }
.visual-image-width-26 .visual-image-stage img { width: 26%; }
.visual-image-width-27 .visual-image-stage img { width: 27%; }
.visual-image-width-28 .visual-image-stage img { width: 28%; }
.visual-image-width-29 .visual-image-stage img { width: 29%; }
.visual-image-width-30 .visual-image-stage img { width: 30%; }
.visual-image-width-31 .visual-image-stage img { width: 31%; }
.visual-image-width-32 .visual-image-stage img { width: 32%; }
.visual-image-width-33 .visual-image-stage img { width: 33%; }
.visual-image-width-34 .visual-image-stage img { width: 34%; }
.visual-image-width-35 .visual-image-stage img { width: 35%; }
.visual-image-width-36 .visual-image-stage img { width: 36%; }
.visual-image-width-37 .visual-image-stage img { width: 37%; }
.visual-image-width-38 .visual-image-stage img { width: 38%; }
.visual-image-width-39 .visual-image-stage img { width: 39%; }
.visual-image-width-40 .visual-image-stage img { width: 40%; }
.visual-image-width-41 .visual-image-stage img { width: 41%; }
.visual-image-width-42 .visual-image-stage img { width: 42%; }
.visual-image-width-43 .visual-image-stage img { width: 43%; }
.visual-image-width-44 .visual-image-stage img { width: 44%; }
.visual-image-width-45 .visual-image-stage img { width: 45%; }
.visual-image-width-46 .visual-image-stage img { width: 46%; }
.visual-image-width-47 .visual-image-stage img { width: 47%; }
.visual-image-width-48 .visual-image-stage img { width: 48%; }
.visual-image-width-49 .visual-image-stage img { width: 49%; }
.visual-image-width-50 .visual-image-stage img { width: 50%; }
.visual-image-width-51 .visual-image-stage img { width: 51%; }
.visual-image-width-52 .visual-image-stage img { width: 52%; }
.visual-image-width-53 .visual-image-stage img { width: 53%; }
.visual-image-width-54 .visual-image-stage img { width: 54%; }
.visual-image-width-55 .visual-image-stage img { width: 55%; }
.visual-image-width-56 .visual-image-stage img { width: 56%; }
.visual-image-width-57 .visual-image-stage img { width: 57%; }
.visual-image-width-58 .visual-image-stage img { width: 58%; }
.visual-image-width-59 .visual-image-stage img { width: 59%; }
.visual-image-width-60 .visual-image-stage img { width: 60%; }
.visual-image-width-61 .visual-image-stage img { width: 61%; }
.visual-image-width-62 .visual-image-stage img { width: 62%; }
.visual-image-width-63 .visual-image-stage img { width: 63%; }
.visual-image-width-64 .visual-image-stage img { width: 64%; }
.visual-image-width-65 .visual-image-stage img { width: 65%; }
.visual-image-width-66 .visual-image-stage img { width: 66%; }
.visual-image-width-67 .visual-image-stage img { width: 67%; }
.visual-image-width-68 .visual-image-stage img { width: 68%; }
.visual-image-width-69 .visual-image-stage img { width: 69%; }
.visual-image-width-70 .visual-image-stage img { width: 70%; }
.visual-image-width-71 .visual-image-stage img { width: 71%; }
.visual-image-width-72 .visual-image-stage img { width: 72%; }
.visual-image-width-73 .visual-image-stage img { width: 73%; }
.visual-image-width-74 .visual-image-stage img { width: 74%; }
.visual-image-width-75 .visual-image-stage img { width: 75%; }
.visual-image-width-76 .visual-image-stage img { width: 76%; }
.visual-image-width-77 .visual-image-stage img { width: 77%; }
.visual-image-width-78 .visual-image-stage img { width: 78%; }
.visual-image-width-79 .visual-image-stage img { width: 79%; }
.visual-image-width-80 .visual-image-stage img { width: 80%; }
.visual-image-width-81 .visual-image-stage img { width: 81%; }
.visual-image-width-82 .visual-image-stage img { width: 82%; }
.visual-image-width-83 .visual-image-stage img { width: 83%; }
.visual-image-width-84 .visual-image-stage img { width: 84%; }
.visual-image-width-85 .visual-image-stage img { width: 85%; }
.visual-image-width-86 .visual-image-stage img { width: 86%; }
.visual-image-width-87 .visual-image-stage img { width: 87%; }
.visual-image-width-88 .visual-image-stage img { width: 88%; }
.visual-image-width-89 .visual-image-stage img { width: 89%; }
.visual-image-width-90 .visual-image-stage img { width: 90%; }
.visual-image-width-91 .visual-image-stage img { width: 91%; }
.visual-image-width-92 .visual-image-stage img { width: 92%; }
.visual-image-width-93 .visual-image-stage img { width: 93%; }
.visual-image-width-94 .visual-image-stage img { width: 94%; }
.visual-image-width-95 .visual-image-stage img { width: 95%; }
.visual-image-width-96 .visual-image-stage img { width: 96%; }
.visual-image-width-97 .visual-image-stage img { width: 97%; }
.visual-image-width-98 .visual-image-stage img { width: 98%; }
.visual-image-width-99 .visual-image-stage img { width: 99%; }
.visual-image-width-100 .visual-image-stage img { width: 100%; }

.visual-image-placeholder {
    display: grid;
    place-items: center;
    align-content: center;
    gap: 4px;
    min-height: 130px;
    color: #728591;
    text-align: center;
}

.visual-image-placeholder > span {
    font-size: 2rem;
}

.visual-image-placeholder small {
    font-size: .72rem;
}

.visual-image-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 5px;
    margin-top: 7px;
}

.visual-upload-button {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 5px 10px;
    border: 1px solid #9fb9c8;
    border-radius: 4px;
    color: #245b7b;
    background: #f4f9fb;
    font-size: .78rem;
    font-weight: 800;
    cursor: pointer;
}

.visual-upload-button input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.visual-image-size-input {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    min-height: 32px;
    padding: 0 5px;
    border: 1px solid #c1d1da;
    border-radius: 4px;
    color: #526b79;
    background: #fff;
    font-size: .75rem;
}

.visual-image-size-input input {
    width: 48px;
    padding: 3px 2px;
    border: 0;
    color: inherit;
    background: transparent;
    text-align: right;
    font: inherit;
}

.visual-image-size-input input:focus {
    outline: none;
}

.visual-image-control.is-paste-target .visual-image-stage {
    border-color: #4e91b7;
    box-shadow: 0 0 0 2px rgba(78, 145, 183, .14);
}

.visual-image-toolbar button.is-active,
.visual-inline-controls button.is-active {
    border-color: #5e98b8;
    color: #155d87;
    background: #e7f3f9;
}

.visual-toolbar-divider {
    width: 1px;
    height: 24px;
    margin: 0 3px;
    background: #d5dfe4;
}

.visual-caption-input {
    width: 100%;
    padding: 6px 8px;
    border: 0;
    border-bottom: 1px solid #d9e0e4;
    color: #566c79;
    background: transparent;
    text-align: center;
    font-size: .82rem;
}

.visual-answer-lines {
    display: grid;
    gap: 0;
    margin: 8px 0 4px;
}

.visual-answer-lines > span {
    display: block;
    height: 36px;
    border-bottom: 1px solid #4f5a60;
}

.visual-answer-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 8px;
    padding-top: 6px;
}

.visual-inline-controls {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    color: #647985;
    font-size: .76rem;
}

.visual-inline-controls button {
    min-width: 28px;
    min-height: 28px;
}

.visual-points-control {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #516977;
    font-size: .78rem;
    font-weight: 800;
}

.visual-points-control input {
    width: 72px;
    min-height: 32px;
    padding: 4px 6px;
    border: 1px solid #bdccd5;
    border-radius: 4px;
    text-align: right;
}

.visual-solution-details,
.visual-block-details {
    margin-top: 10px;
    border: 1px solid #dae4e9;
    border-radius: 4px;
    background: #f8fbfc;
}

.visual-solution-details > summary,
.visual-block-details > summary {
    padding: 8px 10px;
    color: #456476;
    font-size: .78rem;
    font-weight: 800;
    cursor: pointer;
}

.visual-solution-details[open] > summary,
.visual-block-details[open] > summary {
    border-bottom: 1px solid #e0e7eb;
}

.visual-solution-field {
    display: grid;
    gap: 5px;
    padding: 10px;
    color: #4c6574;
    font-size: .78rem;
    font-weight: 800;
}

.visual-solution-field textarea,
.visual-solution-grid textarea,
.visual-solution-grid input {
    width: 100%;
    padding: 8px;
    border: 1px solid #bdccd5;
    border-radius: 4px;
    background: #fff;
    font: inherit;
    font-weight: 400;
}

.visual-solution-field textarea,
.visual-solution-grid textarea {
    resize: vertical;
}

.visual-criteria-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 10px 4px;
    color: #4d6573;
    font-size: .78rem;
}

.visual-criteria-head button,
.visual-inline-add {
    min-height: 30px;
    padding: 5px 9px;
    border: 1px solid #a7bfcd;
    border-radius: 4px;
    color: #285f80;
    background: #f5fafc;
    font: inherit;
    font-size: .76rem;
    font-weight: 800;
    cursor: pointer;
}

.visual-criterion-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 90px 34px;
    gap: 7px;
    padding: 5px 10px;
}

.visual-criterion-row input {
    min-height: 32px;
    padding: 5px 7px;
    border: 1px solid #c4d1d8;
    border-radius: 3px;
}

.visual-criterion-row label {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #617581;
    font-size: .75rem;
}

.visual-rulebook-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 9px;
}

.visual-rulebook-list label {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 8px;
    border: 1px solid #ccd9e0;
    border-radius: 999px;
    color: #506b7a;
    background: #fff;
    font-size: .75rem;
    cursor: pointer;
}

.visual-choice-list {
    display: grid;
    gap: 5px;
    margin-top: 8px;
}

.visual-choice-row {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr) auto 32px;
    align-items: center;
    gap: 9px;
    min-height: 42px;
}

.visual-choice-box {
    width: 14px;
    height: 14px;
    margin-left: 3px;
    border: 1px solid #4d565c;
    background: #fff;
}

.visual-choice-row input[type="text"] {
    min-height: 36px;
    padding: 6px 7px;
    border: 1px solid transparent;
    border-bottom-color: #d3dce1;
    background: transparent;
}

.visual-choice-row input[type="text"]:focus {
    outline: none;
    border-color: #8eb4ca;
    border-radius: 3px;
    background: #fbfdfe;
}

.visual-correct-toggle {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 7px;
    border-radius: 999px;
    color: #5e737f;
    background: #eef3f5;
    font-size: .7rem;
    font-weight: 800;
    cursor: pointer;
}

.visual-correct-toggle:has(input:checked) {
    color: #1f6339;
    background: #e7f4eb;
}

.visual-choice-hint {
    margin: 7px 0 0;
    color: #71838d;
    font-size: .72rem;
}

.visual-signal-single-layout {
    display: grid;
    grid-template-columns: minmax(170px, 35%) minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    margin: 10px 0;
}

.visual-signal-single-layout.is-right .visual-signal-single-image {
    order: 2;
}

.visual-signal-single-layout.is-right .visual-signal-single-answer {
    order: 1;
}

.visual-signal-single-image .visual-image-stage {
    min-height: 180px;
}

.visual-signal-single-answer {
    display: flex;
    align-items: center;
    min-height: 100%;
}

.visual-signal-answer-lines-only {
    width: 100%;
}

.visual-signal-single-answer .visual-answer-lines {
    margin: 0;
}

.visual-solution-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    padding: 10px;
}

.visual-solution-grid label {
    display: grid;
    gap: 4px;
    color: #4f6775;
    font-size: .75rem;
    font-weight: 800;
}

.visual-solution-grid .span-2 {
    grid-column: 1 / -1;
}

.visual-signal-table {
    overflow: hidden;
    margin-top: 10px;
    border: 1px solid #6d7478;
}

.visual-signal-table-row {
    display: grid;
    grid-template-columns: minmax(190px, 32%) minmax(0, 1fr);
    min-height: 240px;
}

.visual-signal-table-row + .visual-signal-table-row {
    border-top: 1px solid #6d7478;
}

.visual-signal-cell {
    padding: 10px;
}

.visual-signal-image-cell {
    border-right: 1px solid #6d7478;
}

.visual-signal-image-cell .visual-image-stage {
    min-height: 165px;
    border-color: #d5dee3;
}

.visual-signal-image-cell .visual-image-toolbar {
    justify-content: center;
}

.visual-signal-answer-cell {
    display: flex;
    flex-direction: column;
}

.visual-signal-answer-cell .visual-answer-lines {
    flex: 1 1 auto;
}

.visual-signal-row-delete {
    align-self: flex-end;
    margin-top: 8px;
    border: 0;
    color: #8b3e36;
    background: transparent;
    font-size: .7rem;
    cursor: pointer;
}

.visual-signal-add-row {
    margin-top: 8px;
}

.metadata-editor-panel {
    margin-top: 0;
}

.metadata-editor-notes {
    margin-top: 24px;
    padding-top: 22px;
    border-top: 1px solid #dce5e9;
}

.visual-savebar {
    z-index: 50;
}

.visual-save-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #657985;
    font-size: .8rem;
}

.save-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #6ea27c;
}

.visual-save-status.is-dirty .save-status-dot {
    background: #d28a31;
}

.visual-save-status.is-dirty {
    color: #72511e;
}

.visual-save-actions {
    display: flex;
    align-items: center;
    gap: 14px;
}

.visual-save-points {
    color: #4b6574;
    font-size: .84rem;
}

/* Neue Bildgrößen werden auch in der separaten Vorschau respektiert. */
.preview-standalone-image.align-left { margin-left: 0; margin-right: auto; }
.preview-standalone-image.align-center { margin-left: auto; margin-right: auto; }
.preview-standalone-image.align-right { margin-left: auto; margin-right: 0; }
.preview-inline-image img,
.signal-question-image img,
.signal-table-image img {
    max-width: 100%;
}

.preview-image-width-20 img { width: 20%; }
.preview-image-width-21 img { width: 21%; }
.preview-image-width-22 img { width: 22%; }
.preview-image-width-23 img { width: 23%; }
.preview-image-width-24 img { width: 24%; }
.preview-image-width-25 img { width: 25%; }
.preview-image-width-26 img { width: 26%; }
.preview-image-width-27 img { width: 27%; }
.preview-image-width-28 img { width: 28%; }
.preview-image-width-29 img { width: 29%; }
.preview-image-width-30 img { width: 30%; }
.preview-image-width-31 img { width: 31%; }
.preview-image-width-32 img { width: 32%; }
.preview-image-width-33 img { width: 33%; }
.preview-image-width-34 img { width: 34%; }
.preview-image-width-35 img { width: 35%; }
.preview-image-width-36 img { width: 36%; }
.preview-image-width-37 img { width: 37%; }
.preview-image-width-38 img { width: 38%; }
.preview-image-width-39 img { width: 39%; }
.preview-image-width-40 img { width: 40%; }
.preview-image-width-41 img { width: 41%; }
.preview-image-width-42 img { width: 42%; }
.preview-image-width-43 img { width: 43%; }
.preview-image-width-44 img { width: 44%; }
.preview-image-width-45 img { width: 45%; }
.preview-image-width-46 img { width: 46%; }
.preview-image-width-47 img { width: 47%; }
.preview-image-width-48 img { width: 48%; }
.preview-image-width-49 img { width: 49%; }
.preview-image-width-50 img { width: 50%; }
.preview-image-width-51 img { width: 51%; }
.preview-image-width-52 img { width: 52%; }
.preview-image-width-53 img { width: 53%; }
.preview-image-width-54 img { width: 54%; }
.preview-image-width-55 img { width: 55%; }
.preview-image-width-56 img { width: 56%; }
.preview-image-width-57 img { width: 57%; }
.preview-image-width-58 img { width: 58%; }
.preview-image-width-59 img { width: 59%; }
.preview-image-width-60 img { width: 60%; }
.preview-image-width-61 img { width: 61%; }
.preview-image-width-62 img { width: 62%; }
.preview-image-width-63 img { width: 63%; }
.preview-image-width-64 img { width: 64%; }
.preview-image-width-65 img { width: 65%; }
.preview-image-width-66 img { width: 66%; }
.preview-image-width-67 img { width: 67%; }
.preview-image-width-68 img { width: 68%; }
.preview-image-width-69 img { width: 69%; }
.preview-image-width-70 img { width: 70%; }
.preview-image-width-71 img { width: 71%; }
.preview-image-width-72 img { width: 72%; }
.preview-image-width-73 img { width: 73%; }
.preview-image-width-74 img { width: 74%; }
.preview-image-width-75 img { width: 75%; }
.preview-image-width-76 img { width: 76%; }
.preview-image-width-77 img { width: 77%; }
.preview-image-width-78 img { width: 78%; }
.preview-image-width-79 img { width: 79%; }
.preview-image-width-80 img { width: 80%; }
.preview-image-width-81 img { width: 81%; }
.preview-image-width-82 img { width: 82%; }
.preview-image-width-83 img { width: 83%; }
.preview-image-width-84 img { width: 84%; }
.preview-image-width-85 img { width: 85%; }
.preview-image-width-86 img { width: 86%; }
.preview-image-width-87 img { width: 87%; }
.preview-image-width-88 img { width: 88%; }
.preview-image-width-89 img { width: 89%; }
.preview-image-width-90 img { width: 90%; }
.preview-image-width-91 img { width: 91%; }
.preview-image-width-92 img { width: 92%; }
.preview-image-width-93 img { width: 93%; }
.preview-image-width-94 img { width: 94%; }
.preview-image-width-95 img { width: 95%; }
.preview-image-width-96 img { width: 96%; }
.preview-image-width-97 img { width: 97%; }
.preview-image-width-98 img { width: 98%; }
.preview-image-width-99 img { width: 99%; }
.preview-image-width-100 img { width: 100%; }

@media (max-width: 760px) {
    .visual-editor-summarybar,
    .visual-savebar,
    .visual-answer-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .visual-summary-values,
    .visual-save-actions {
        justify-content: space-between;
    }

    .visual-question-sheet {
        padding: 20px 14px 30px;
    }

    .visual-block-menu-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .visual-signal-single-layout,
    .visual-signal-table-row {
        grid-template-columns: minmax(0, 1fr);
    }

    .visual-signal-single-layout.is-right .visual-signal-single-image,
    .visual-signal-single-layout.is-right .visual-signal-single-answer {
        order: initial;
    }

    .visual-signal-image-cell {
        border-right: 0;
        border-bottom: 1px solid #6d7478;
    }

    .visual-choice-row {
        grid-template-columns: 22px minmax(0, 1fr) 32px;
    }

    .visual-correct-toggle {
        grid-column: 2 / 3;
        justify-self: start;
    }

    .visual-solution-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .visual-solution-grid .span-2 {
        grid-column: auto;
    }
}

/* Frageneditor: dynamische Kategorien/Themen, Quellen und Historie */
.classification-panel,
.history-tab-panel {
    display: grid;
    gap: 24px;
}

.classification-basics {
    align-items: start;
}

.title-suggestion-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
}

.compact-action {
    min-height: 42px;
    white-space: nowrap;
}

.field > small,
.field-help,
.term-editor-heading p,
.sources-editor-heading p {
    color: var(--muted-text, #667085);
    font-size: .88rem;
    line-height: 1.45;
}

.exam-type-required {
    border: 1px solid rgba(15, 45, 75, .14);
    border-radius: 12px;
    padding: 18px;
    background: rgba(255, 255, 255, .72);
}

.exam-type-required legend {
    font-weight: 700;
    padding: 0 6px;
}

.check-list-wide {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 18px;
}

.classification-term-grid,
.classification-axis-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.classification-axis-grid {
    margin-top: 18px;
}

.classification-axis-card select {
    width: 100%;
    min-height: 42px;
    margin-top: 14px;
    padding: 8px 10px;
    border: 1px solid #b9c7d0;
    border-radius: 6px;
    color: #283b47;
    background: #fff;
    font: inherit;
}

.classification-axis-card select[multiple] {
    min-height: 230px;
}

.classification-axis-card > small,
.muted-note {
    display: block;
    margin-top: 8px;
    color: var(--muted-text, #667085);
    line-height: 1.45;
}

.term-editor {
    border: 1px solid rgba(15, 45, 75, .14);
    border-radius: 12px;
    padding: 18px;
    background: rgba(255, 255, 255, .72);
}

.term-editor-heading h4,
.sources-editor-heading h4 {
    margin: 0 0 4px;
    font-size: 1rem;
}

.term-editor-heading p,
.sources-editor-heading p {
    margin: 0;
}

.term-entry-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    margin-top: 14px;
}

.term-entry-row input {
    min-width: 0;
    min-height: 42px;
    border: 1px solid rgba(15, 45, 75, .22);
    border-radius: 8px;
    padding: 8px 11px;
    font: inherit;
}

.term-entry-row button {
    border: 0;
    border-radius: 8px;
    padding: 0 14px;
    background: var(--primary, #1f5f9d);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
}

.term-chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    min-height: 36px;
    margin-top: 14px;
}

.term-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    border: 1px solid rgba(31, 95, 157, .2);
    border-radius: 999px;
    background: rgba(31, 95, 157, .08);
    padding: 5px 6px 5px 11px;
    line-height: 1.2;
}

.term-chip > span {
    font-weight: 650;
}

.term-chip button {
    display: grid;
    place-items: center;
    width: 25px;
    height: 25px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: inherit;
    cursor: pointer;
}

.term-chip button:hover,
.term-chip button:focus-visible {
    background: rgba(31, 95, 157, .12);
}

.sources-editor {
    border-top: 1px solid rgba(15, 45, 75, .12);
    padding-top: 22px;
}

.sources-editor-heading,
.question-source-head,
.history-entry-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 14px;
}

.question-sources-list {
    display: grid;
    gap: 14px;
    margin-top: 14px;
}

.question-source-card {
    border: 1px solid rgba(15, 45, 75, .14);
    border-radius: 12px;
    padding: 16px;
    background: #fff;
}

.question-source-head {
    align-items: center;
    margin-bottom: 14px;
}

.source-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.source-span-2 {
    grid-column: 1 / -1;
}

.source-empty-hint {
    margin-top: 12px;
    border: 1px dashed rgba(15, 45, 75, .2);
    border-radius: 10px;
    padding: 14px;
    color: var(--muted-text, #667085);
    text-align: center;
}

.change-comment-field {
    border-top: 1px solid rgba(15, 45, 75, .12);
    padding-top: 22px;
}

.visual-summary-values small {
    display: block;
    font-size: .72rem;
    font-weight: 600;
    opacity: .72;
}

.history-list-detailed {
    display: grid;
    gap: 14px;
}

.history-entry-detailed {
    display: block;
    border: 1px solid rgba(15, 45, 75, .14);
    border-radius: 12px;
    padding: 16px;
    background: #fff;
}

.history-entry-head > div {
    display: grid;
    gap: 3px;
}

.history-entry-head > div > span {
    color: var(--muted-text, #667085);
    font-size: .87rem;
}

.history-change-count {
    border-radius: 999px;
    background: rgba(31, 95, 157, .08);
    padding: 5px 9px;
    font-size: .82rem;
    font-weight: 700;
    white-space: nowrap;
}

.history-user-comment {
    margin-top: 12px;
    border-left: 3px solid rgba(31, 95, 157, .55);
    padding: 8px 12px;
    background: rgba(31, 95, 157, .045);
    line-height: 1.5;
}

.history-change-list {
    display: grid;
    gap: 7px;
    margin-top: 12px;
}

.history-change-item {
    border: 1px solid rgba(15, 45, 75, .1);
    border-radius: 9px;
    overflow: clip;
}

.history-change-item > summary {
    padding: 10px 12px;
    cursor: pointer;
    font-weight: 650;
    background: rgba(15, 45, 75, .025);
}

.history-diff-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    background: rgba(15, 45, 75, .1);
    border-top: 1px solid rgba(15, 45, 75, .1);
}

.history-diff-grid > div {
    min-width: 0;
    padding: 11px;
    background: #fff;
}

.history-diff-grid small {
    display: block;
    margin-bottom: 6px;
    color: var(--muted-text, #667085);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .03em;
}

.history-diff-grid pre {
    margin: 0;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    font: inherit;
    line-height: 1.45;
}

.compact-empty-state {
    min-height: auto;
}

@media (max-width: 850px) {
    .classification-term-grid,
    .classification-axis-grid,
    .check-list-wide,
    .source-form-grid,
    .history-diff-grid,
    .title-suggestion-row {
        grid-template-columns: 1fr;
    }

    .sources-editor-heading,
    .history-entry-head {
        align-items: stretch;
        flex-direction: column;
    }

    .compact-action {
        width: 100%;
    }
}

/* Varianten / Fragenfamilien */
.question-family-card,
.variant-source-card,
.variant-family-note {
    border: 1px solid #c9d9e2;
    background: #f7fafc;
    border-radius: 8px;
    padding: 14px 16px;
}

.question-family-card {
    display: grid;
    grid-template-columns: minmax(220px, .8fr) minmax(0, 1.2fr);
    gap: 18px;
    margin-bottom: 16px;
}

.question-family-card h4 {
    margin: 3px 0 5px;
    color: #1f506a;
}

.question-family-card p,
.variant-source-card span,
.variant-source-card small,
.variant-family-note {
    color: #607581;
}

.question-family-members {
    display: grid;
    gap: 6px;
}

.question-family-members a {
    display: block;
    padding: 8px 10px;
    border: 1px solid #d6e1e7;
    border-radius: 5px;
    background: #fff;
    color: #285b75;
    text-decoration: none;
}

.question-family-members a.is-current {
    border-color: #82aec5;
    background: #eef7fb;
    font-weight: 700;
}

.variant-source-card {
    display: grid;
    gap: 4px;
    margin-bottom: 14px;
}

.variant-copy-form {
    max-width: 900px;
}

.variant-copy-options {
    display: grid;
    gap: 8px;
    margin: 0 0 16px;
    padding: 0;
    border: 0;
}

.variant-copy-options legend {
    margin-bottom: 8px;
    color: #214d67;
    font-weight: 800;
}

.variant-copy-options label,
.metadata-checkbox-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid #d7e2e8;
    border-radius: 6px;
    background: #fff;
}

.variant-copy-options label span,
.metadata-checkbox-row span {
    display: grid;
    gap: 2px;
}

.variant-copy-options small,
.metadata-checkbox-row small {
    color: #71828c;
}

.variant-family-note {
    margin-bottom: 16px;
}

/* Benutzerverwaltung */
.user-admin-form {
    max-width: 920px;
}

.user-two-factor-toggle {
    margin-top: 14px;
}

.user-savebar {
    position: static;
    margin-top: 18px;
}

.toolbar-user-identity span {
    display: block;
    margin-top: 2px;
    color: #6a7d88;
    font-size: .78rem;
}

/* Historischer Metadatenbereich */
.metadata-row-form {
    grid-template-columns: minmax(0, 1fr) auto auto auto;
}

.metadata-row-form .danger-ghost {
    border-color: #d9aaa5;
    color: #8f2f25;
    background: #fff8f7;
}

@media (max-width: 760px) {
    .question-family-card {
        grid-template-columns: 1fr;
    }

    .metadata-row-form {
        grid-template-columns: 1fr auto auto;
    }

    .metadata-row-form input[type="text"] {
        grid-column: 1 / -1;
    }
}


.user-password-section {
    display: grid;
    gap: 8px;
}

.user-password-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.user-password-grid label {
    display: grid;
    gap: 6px;
}

.user-password-grid label > span {
    color: #536b79;
    font-size: .82rem;
    font-weight: 700;
}

.user-password-grid input {
    width: 100%;
}

.user-password-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.user-password-status {
    color: #386277;
    font-size: .82rem;
}

@media (max-width: 720px) {
    .user-password-grid {
        grid-template-columns: 1fr;
    }
}


/* Session-Inaktivitätsanzeige */
.toolbar-session-timer {
    margin-left: auto;
    margin-right: 8px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 8px;
    border-radius: 4px;
    color: rgba(255,255,255,.86);
    font-size: .72rem;
    white-space: nowrap;
}

.toolbar-session-timer strong {
    color: #fff;
    font-variant-numeric: tabular-nums;
}

.toolbar-session-timer.is-warning {
    background: rgba(255, 193, 7, .18);
}

.toolbar-session-timer.is-critical {
    background: rgba(220, 53, 69, .35);
}

@media (max-width: 760px) {
    .toolbar-session-timer {
        font-size: 0;
    }
    .toolbar-session-timer::before {
        content: 'Logout';
        font-size: .7rem;
    }
    .toolbar-session-timer strong {
        font-size: .7rem;
    }
}


.list-pagination-summary,
.pagination-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 12px 0;
    color: #5d7280;
    font-size: .82rem;
}

.pagination-nav {
    justify-content: center;
    margin-top: 18px;
}

.toolbar-session-timer + .toolbar-user-menu {
    margin-left: 0;
}

/* Read-only tabs in the question preview */
.preview-tabs {
    margin-bottom: 14px;
}

.preview-readonly-panel {
    display: grid;
    gap: 18px;
}

.preview-readonly-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.preview-readonly-card {
    display: grid;
    gap: 5px;
    padding: 14px 16px;
    border: 1px solid #d9e3e8;
    border-radius: 8px;
    background: #fff;
}

.preview-readonly-card > small {
    color: #647985;
    font-size: .76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .035em;
}

.preview-readonly-card > strong {
    color: #243946;
}

.preview-readonly-card > span {
    color: #526b79;
}

.preview-readonly-span-2 {
    grid-column: 1 / -1;
}

.preview-chip-list {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.preview-chip-list span {
    display: inline-flex;
    align-items: center;
    padding: 5px 9px;
    border: 1px solid #c8d8e0;
    border-radius: 999px;
    background: #f5f9fb;
    color: #36596d;
    font-size: .82rem;
}

.preview-sources-section,
.preview-history-panel {
    padding: 16px;
    border: 1px solid #d9e3e8;
    border-radius: 8px;
    background: #fff;
}

.preview-source-list {
    display: grid;
    gap: 12px;
    margin-top: 12px;
}

.preview-source-card {
    padding: 14px;
    border: 1px solid #dce5ea;
    border-radius: 7px;
    background: #fbfdfe;
}

.preview-source-card > strong {
    display: block;
    margin-bottom: 10px;
}

.preview-source-card dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 18px;
    margin: 0;
}

.preview-source-card dl > div {
    min-width: 0;
}

.preview-source-card dt {
    margin-bottom: 2px;
    color: #6b7f8a;
    font-size: .74rem;
    font-weight: 700;
}

.preview-source-card dd {
    margin: 0;
    color: #2e4654;
    overflow-wrap: anywhere;
}

.preview-source-wide {
    grid-column: 1 / -1;
}

@media (max-width: 720px) {
    .preview-readonly-grid,
    .preview-source-card dl {
        grid-template-columns: 1fr;
    }

    .preview-readonly-span-2,
    .preview-source-wide {
        grid-column: auto;
    }
}

/* v6.2 – Begleitbereiche, flexible Tabellen und Live-Vorschau */
.visual-image-composite {
    display: grid;
    gap: 16px;
    align-items: stretch;
}

.visual-image-composite.has-companion.is-left,
.visual-image-composite.has-companion.is-right {
    grid-template-columns: minmax(190px, 36%) minmax(0, 1fr);
}

.visual-image-composite.has-companion.is-center {
    grid-template-columns: 1fr;
}

.visual-image-composite.is-right .visual-image-pane {
    order: 2;
}

.visual-image-composite.is-right .visual-companion-area {
    order: 1;
}

.visual-image-composite:not(.has-companion) .visual-companion-area {
    margin-top: 4px;
}

.visual-image-pane,
.visual-companion-area {
    min-width: 0;
}

.visual-companion-area {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px;
    border: 1px dashed #cfdae0;
    border-radius: 5px;
    background: #fbfdfe;
}

.visual-companion-heading {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 4px 10px;
    color: #425f70;
}

.visual-companion-heading small {
    color: #738690;
    font-size: .75rem;
}

.visual-companion-list {
    display: grid;
    gap: 10px;
}

.visual-companion-block {
    padding: 9px;
    border: 1px solid #dbe4e9;
    border-radius: 5px;
    background: #fff;
}

.visual-companion-block > textarea {
    width: 100%;
    min-height: 44px;
    padding: 8px 7px;
    border: 1px solid #d8e2e7;
    border-radius: 3px;
    background: #fff;
    font: inherit;
    line-height: 1.45;
    resize: vertical;
}

.visual-companion-block > textarea:focus {
    outline: 2px solid rgba(39, 102, 137, .16);
    border-color: #8eb4ca;
}

.visual-companion-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 7px;
    color: #3e5c6e;
    font-size: .78rem;
}

.visual-companion-add {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    padding-top: 4px;
}

.visual-companion-add > span {
    margin-right: 2px;
    color: #657985;
    font-size: .75rem;
    font-weight: 700;
}

.visual-companion-add button,
.visual-table-cell-toolbar select,
.visual-table-toolbar button {
    min-height: 30px;
    padding: 4px 8px;
    border: 1px solid #cbd8df;
    border-radius: 4px;
    color: #365a6f;
    background: #fff;
    font: inherit;
    font-size: .75rem;
}

.visual-companion-add button,
.visual-table-toolbar button {
    font-weight: 800;
    cursor: pointer;
}

.visual-companion-add button:hover,
.visual-table-toolbar button:hover {
    background: #eef6f9;
}

.visual-table-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 8px 0;
    padding: 8px 10px;
    border: 1px solid #d9e3e8;
    border-radius: 5px;
    background: #f8fbfc;
}

.visual-table-toolbar > div:first-child {
    display: grid;
    gap: 2px;
}

.visual-table-toolbar small {
    color: #73858f;
    font-size: .74rem;
}

.visual-table-scroll,
.preview-flex-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.visual-flex-table,
.preview-flex-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.visual-flex-table td,
.preview-flex-table td {
    min-width: 150px;
    padding: 8px;
    vertical-align: middle;
    border: 1px solid #9eabb2;
}

.visual-table-cell-toolbar {
    margin-bottom: 7px;
}

.visual-table-cell-toolbar label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: #667b87;
    font-size: .7rem;
    font-weight: 700;
}

.visual-table-cell-editor textarea {
    width: 100%;
    min-height: 70px;
    padding: 7px;
    resize: vertical;
    border: 1px solid #d5dfe4;
    border-radius: 3px;
    background: #fff;
}

.visual-table-empty-cell {
    min-height: 62px;
    display: grid;
    place-items: center;
    color: #9aa8af;
    font-size: .75rem;
}

.visual-table-checkbox,
.preview-table-checkbox {
    width: 34px;
    height: 34px;
    margin: 14px auto;
    border: 2px solid #37474f;
    background: #fff;
}

.visual-table-free-space,
.preview-table-free-space {
    width: 100%;
}

.table-space-lines-1 { min-height: 28px; }
.table-space-lines-2 { min-height: 48px; }
.table-space-lines-3 { min-height: 68px; }
.table-space-lines-4 { min-height: 88px; }
.table-space-lines-5 { min-height: 108px; }
.table-space-lines-6 { min-height: 128px; }
.table-space-lines-7 { min-height: 148px; }
.table-space-lines-8 { min-height: 168px; }
.table-space-lines-9 { min-height: 188px; }
.table-space-lines-10 { min-height: 208px; }
.table-space-lines-11 { min-height: 228px; }
.table-space-lines-12 { min-height: 248px; }

.visual-table-space-controls {
    justify-content: center;
    margin-top: 6px;
}

.visual-table-size {
    color: #667b87;
    font-size: .78rem;
    font-weight: 700;
}

.preview-image-composite {
    display: grid;
    grid-template-columns: minmax(170px, 36%) minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    margin: 16px 0;
}

.preview-image-composite.is-right .preview-image-composite-pane {
    order: 2;
}

.preview-image-composite.is-right .preview-image-companion {
    order: 1;
}

.preview-image-composite.is-center {
    grid-template-columns: 1fr;
}

.preview-image-composite-pane {
    margin: 0;
    text-align: center;
}

.preview-image-composite-pane img,
.preview-table-cell-image img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 0 auto;
}

.preview-image-composite-pane figcaption {
    margin-top: 5px;
    color: #64757e;
    font-size: .78rem;
}

.preview-image-companion {
    min-width: 0;
}

.preview-companion-text,
.preview-companion-answer {
    margin: 8px 0;
}

.preview-table-block {
    margin-top: 14px;
}

.preview-flex-table td {
    padding: 10px;
}

.preview-table-cell-text {
    min-height: 36px;
    white-space: normal;
}

.preview-table-cell-image {
    margin: 0 auto;
}

.preview-table-solution {
    margin-top: 12px;
    padding: 10px 12px;
    border-left: 3px solid #728f7b;
    background: #f4f8f5;
}

.preview-table-solution > strong {
    display: block;
    margin-bottom: 5px;
}

.question-live-preview[hidden] {
    display: none;
}

.question-live-preview {
    position: fixed;
    inset: 0;
    z-index: 6500;
    display: grid;
    place-items: center;
    padding: 24px;
}

.question-live-preview-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(17, 31, 40, .72);
}

.question-live-preview-dialog {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    width: min(1160px, 100%);
    max-height: calc(100vh - 48px);
    overflow: hidden;
    border-radius: 9px;
    background: #eef3f5;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .36);
}

.question-live-preview-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 16px 18px;
    border-bottom: 1px solid #d4dfe4;
    background: #fff;
}

.question-live-preview-head h3,
.question-live-preview-head p {
    margin: 0;
}

.question-live-preview-head p {
    margin-top: 3px;
    color: #6c7e88;
    font-size: .8rem;
}

.question-live-preview-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 7px;
}

.question-live-preview-actions [data-live-preview-mode].is-active {
    border-color: #4f87a8;
    background: #eaf4f9;
}

.question-live-preview-scroll {
    overflow: auto;
    padding: 22px;
}

.question-live-preview-scroll [data-live-preview-content] {
    width: min(900px, 100%);
    margin: 0 auto;
}

.live-preview-open {
    overflow: hidden;
}

@media (max-width: 760px) {
    .visual-image-composite.has-companion.is-left,
    .visual-image-composite.has-companion.is-right,
    .preview-image-composite,
    .preview-image-composite.is-right {
        grid-template-columns: 1fr;
    }

    .visual-image-composite.is-right .visual-image-pane,
    .visual-image-composite.is-right .visual-companion-area,
    .preview-image-composite.is-right .preview-image-composite-pane,
    .preview-image-composite.is-right .preview-image-companion {
        order: initial;
    }

    .question-live-preview {
        padding: 8px;
    }

    .question-live-preview-dialog {
        max-height: calc(100vh - 16px);
    }

    .question-live-preview-head {
        flex-direction: column;
    }

    .question-live-preview-actions {
        justify-content: flex-start;
    }
}


/* Fragenübersicht: Miniatur und schnelle Layer-Vorschau */
.question-thumbnail-cell {
    width: 150px;
}

.question-thumbnail-button {
    display: block;
    width: 142px;
    height: 96px;
    padding: 0;
    overflow: hidden;
    border: 1px solid #cbd8df;
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 2px 6px rgba(31, 54, 68, .08);
    cursor: pointer;
}

.question-thumbnail-button:hover,
.question-thumbnail-button:focus-visible {
    border-color: #5e98b8;
    box-shadow: 0 0 0 2px rgba(94, 152, 184, .15);
    outline: none;
}

.question-thumbnail-paper {
    display: block;
    width: 610px;
    min-height: 410px;
    padding: 24px 28px;
    color: #20282d;
    background: #fff;
    text-align: left;
    transform: scale(.235);
    transform-origin: top left;
    pointer-events: none;
}

.question-quick-preview[hidden] {
    display: none;
}

.question-quick-preview {
    position: fixed;
    z-index: 1600;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 28px;
}

.question-quick-preview-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(12, 26, 34, .72);
}

.question-quick-preview-dialog {
    position: relative;
    display: flex;
    flex-direction: column;
    width: min(920px, 96vw);
    max-height: 92vh;
    overflow: hidden;
    border-radius: 7px;
    background: #eef3f6;
    box-shadow: 0 24px 70px rgba(0, 0, 0, .34);
}

.question-quick-preview-header,
.question-quick-preview-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 14px 18px;
    background: #fff;
}

.question-quick-preview-header {
    border-bottom: 1px solid #d5e0e6;
}

.question-quick-preview-header h3 {
    margin: 0;
}

.question-quick-preview-footer {
    border-top: 1px solid #d5e0e6;
    color: #526b79;
    font-size: .85rem;
}

.question-quick-preview-close {
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 50%;
    color: #315b75;
    background: #edf4f7;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
}

.question-quick-preview-scroll {
    overflow: auto;
    padding: 24px;
}

.question-quick-preview-sheet {
    width: min(720px, 100%);
    min-height: 520px;
    margin: 0 auto;
    padding: 42px 48px 56px;
    color: #20282d;
    background: #fff;
    box-shadow: 0 4px 18px rgba(31, 54, 68, .12);
}

body.question-quick-preview-open {
    overflow: hidden;
}

.qlp-question-body {
    font-family: Arial, sans-serif;
    font-size: 14px;
    line-height: 1.42;
}

.qlp-block {
    margin: 0 0 20px;
}

.qlp-text-block > div,
.qlp-text,
.qlp-prompt {
    white-space: normal;
}

.qlp-label {
    margin-right: 6px;
}

.qlp-prompt {
    margin-bottom: 8px;
}

.qlp-points {
    margin-top: 7px;
    text-align: right;
}

.qlp-total {
    margin-top: 30px;
    font-weight: 700;
    text-align: right;
}

.qlp-answer-lines {
    display: grid;
    width: 100%;
}

.qlp-answer-lines > span {
    height: 28px;
    border-bottom: 1px solid #454f55;
}

.qlp-choices {
    display: grid;
    gap: 7px;
}

.qlp-choice {
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 8px;
    align-items: start;
}

.qlp-choice-box,
.qlp-large-checkbox {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 1px solid #343b3f;
    background: #fff;
}

.qlp-large-checkbox {
    width: 34px;
    height: 34px;
}

.qlp-image {
    margin: 8px auto;
    text-align: center;
}

.qlp-image img {
    display: block;
    max-width: 100%;
    max-height: 360px;
    margin: 0 auto;
    object-fit: contain;
}

.qlp-width-20 img { width: 20%; }
.qlp-width-21 img { width: 21%; }
.qlp-width-22 img { width: 22%; }
.qlp-width-23 img { width: 23%; }
.qlp-width-24 img { width: 24%; }
.qlp-width-25 img { width: 25%; }
.qlp-width-26 img { width: 26%; }
.qlp-width-27 img { width: 27%; }
.qlp-width-28 img { width: 28%; }
.qlp-width-29 img { width: 29%; }
.qlp-width-30 img { width: 30%; }
.qlp-width-31 img { width: 31%; }
.qlp-width-32 img { width: 32%; }
.qlp-width-33 img { width: 33%; }
.qlp-width-34 img { width: 34%; }
.qlp-width-35 img { width: 35%; }
.qlp-width-36 img { width: 36%; }
.qlp-width-37 img { width: 37%; }
.qlp-width-38 img { width: 38%; }
.qlp-width-39 img { width: 39%; }
.qlp-width-40 img { width: 40%; }
.qlp-width-41 img { width: 41%; }
.qlp-width-42 img { width: 42%; }
.qlp-width-43 img { width: 43%; }
.qlp-width-44 img { width: 44%; }
.qlp-width-45 img { width: 45%; }
.qlp-width-46 img { width: 46%; }
.qlp-width-47 img { width: 47%; }
.qlp-width-48 img { width: 48%; }
.qlp-width-49 img { width: 49%; }
.qlp-width-50 img { width: 50%; }
.qlp-width-51 img { width: 51%; }
.qlp-width-52 img { width: 52%; }
.qlp-width-53 img { width: 53%; }
.qlp-width-54 img { width: 54%; }
.qlp-width-55 img { width: 55%; }
.qlp-width-56 img { width: 56%; }
.qlp-width-57 img { width: 57%; }
.qlp-width-58 img { width: 58%; }
.qlp-width-59 img { width: 59%; }
.qlp-width-60 img { width: 60%; }
.qlp-width-61 img { width: 61%; }
.qlp-width-62 img { width: 62%; }
.qlp-width-63 img { width: 63%; }
.qlp-width-64 img { width: 64%; }
.qlp-width-65 img { width: 65%; }
.qlp-width-66 img { width: 66%; }
.qlp-width-67 img { width: 67%; }
.qlp-width-68 img { width: 68%; }
.qlp-width-69 img { width: 69%; }
.qlp-width-70 img { width: 70%; }
.qlp-width-71 img { width: 71%; }
.qlp-width-72 img { width: 72%; }
.qlp-width-73 img { width: 73%; }
.qlp-width-74 img { width: 74%; }
.qlp-width-75 img { width: 75%; }
.qlp-width-76 img { width: 76%; }
.qlp-width-77 img { width: 77%; }
.qlp-width-78 img { width: 78%; }
.qlp-width-79 img { width: 79%; }
.qlp-width-80 img { width: 80%; }
.qlp-width-81 img { width: 81%; }
.qlp-width-82 img { width: 82%; }
.qlp-width-83 img { width: 83%; }
.qlp-width-84 img { width: 84%; }
.qlp-width-85 img { width: 85%; }
.qlp-width-86 img { width: 86%; }
.qlp-width-87 img { width: 87%; }
.qlp-width-88 img { width: 88%; }
.qlp-width-89 img { width: 89%; }
.qlp-width-90 img { width: 90%; }
.qlp-width-91 img { width: 91%; }
.qlp-width-92 img { width: 92%; }
.qlp-width-93 img { width: 93%; }
.qlp-width-94 img { width: 94%; }
.qlp-width-95 img { width: 95%; }
.qlp-width-96 img { width: 96%; }
.qlp-width-97 img { width: 97%; }
.qlp-width-98 img { width: 98%; }
.qlp-width-99 img { width: 99%; }
.qlp-width-100 img { width: 100%; }

.qlp-align-left { margin-left: 0; margin-right: auto; }
.qlp-align-center { margin-left: auto; margin-right: auto; }
.qlp-align-right { margin-left: auto; margin-right: 0; }

.qlp-image-composite {
    display: grid;
    grid-template-columns: minmax(170px, 38%) minmax(0, 1fr);
    gap: 18px;
    align-items: center;
}

.qlp-image-composite.qlp-right .qlp-image { order: 2; }
.qlp-image-composite.qlp-right .qlp-companion { order: 1; }

.qlp-table {
    width: 100%;
    border-collapse: collapse;
}

.qlp-table td {
    min-width: 80px;
    padding: 9px;
    border: 1px solid #727b80;
    vertical-align: middle;
}

.qlp-space-1 { min-height: 18px; }
.qlp-space-2 { min-height: 36px; }
.qlp-space-3 { min-height: 54px; }
.qlp-space-4 { min-height: 72px; }
.qlp-space-5 { min-height: 90px; }
.qlp-space-6 { min-height: 108px; }
.qlp-space-7 { min-height: 126px; }
.qlp-space-8 { min-height: 144px; }
.qlp-space-9 { min-height: 162px; }
.qlp-space-10 { min-height: 180px; }
.qlp-space-11 { min-height: 198px; }
.qlp-space-12 { min-height: 216px; }
.qlp-space-13 { min-height: 234px; }
.qlp-space-14 { min-height: 252px; }
.qlp-space-15 { min-height: 270px; }
.qlp-space-16 { min-height: 288px; }
.qlp-space-17 { min-height: 306px; }
.qlp-space-18 { min-height: 324px; }
.qlp-space-19 { min-height: 342px; }
.qlp-space-20 { min-height: 360px; }

.qlp-signal-single,
.qlp-signal-row {
    display: grid;
    grid-template-columns: minmax(150px, 32%) minmax(0, 1fr);
    border: 1px solid #737d82;
}

.qlp-signal-single > div,
.qlp-signal-row > div {
    min-height: 120px;
    padding: 10px;
}

.qlp-signal-single > div:first-child,
.qlp-signal-row > div:first-child {
    border-right: 1px solid #737d82;
}

.qlp-signal-single.qlp-right .qlp-image { order: 2; border-right: 0; border-left: 1px solid #737d82; }
.qlp-signal-single.qlp-right .qlp-signal-answer { order: 1; }

.qlp-signal-table {
    border-top: 1px solid #737d82;
}

.qlp-signal-row + .qlp-signal-row {
    border-top: 0;
}

.question-thumbnail-paper .qlp-question-body {
    font-size: 13px;
}

.question-thumbnail-paper .qlp-block {
    margin-bottom: 14px;
}

.question-thumbnail-paper .qlp-answer-lines > span {
    height: 22px;
}

@media (max-width: 760px) {
    .question-thumbnail-cell { width: 118px; }
    .question-thumbnail-button { width: 110px; height: 78px; }
    .question-thumbnail-paper { transform: scale(.182); }
    .question-quick-preview { padding: 10px; }
    .question-quick-preview-scroll { padding: 12px; }
    .question-quick-preview-sheet { padding: 26px 22px 36px; }
    .qlp-image-composite,
    .qlp-signal-single,
    .qlp-signal-row { grid-template-columns: 1fr; }
}

.question-list-filters {
    margin: 1rem 0 1.25rem;
    padding: 1rem 1.1rem;
    border: 1px solid var(--border-color, #d7dde8);
    border-radius: 16px;
    background: rgba(255,255,255,0.72);
}

.question-list-filter-grid {
    display: grid;
    grid-template-columns: minmax(16rem, 2fr) repeat(4, minmax(12rem, 1fr));
    gap: 0.9rem;
}

.question-filter-search {
    grid-column: span 2;
}

.question-list-filter-actions {
    margin-top: 0.9rem;
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.table-sort-link {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    color: inherit;
    text-decoration: none;
}

.table-sort-link.is-active {
    color: var(--accent-color, #234ea0);
}

.visual-graphic-zones-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(18rem, 1fr);
    gap: 1rem;
}

.visual-graphic-zones-stage-wrap,
.visual-graphic-zones-sidebar {
    border: 1px solid rgba(35, 78, 160, 0.16);
    border-radius: 16px;
    background: rgba(255,255,255,0.72);
    padding: 0.9rem;
}

.visual-zone-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.visual-zone-toolbar small {
    color: #667085;
}

.visual-graphic-zones-stage {
    position: relative;
}

.visual-graphic-zones-stage .visual-image-stage {
    position: relative;
    display: block;
    padding: 0;
    min-height: 0;
    overflow: hidden;
}

.visual-editor-block-graphic_zones .visual-image-stage img[data-image-preview] {
    width: 100% !important;
    max-height: none;
    object-fit: contain;
}

.visual-editor-block-graphic_zones .visual-image-placeholder {
    min-height: 220px;
}

.visual-graphic-zones-canvas {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 3;
}

.visual-editor-block-graphic_zones.is-drawing-zone .visual-image-stage {
    cursor: crosshair;
}

.visual-editor-block-graphic_zones.is-drawing-zone .visual-zone-overlay {
    pointer-events: none;
}

.visual-graphic-zones-canvas > img,
.preview-graphic-zones-canvas > img,
.qlp-graphic-canvas > img {
    display: block;
    width: 100%;
    height: auto;
}

.visual-graphic-zones-canvas .visual-zone-overlay,
.preview-answer-zone,
.qlp-zone {
    position: absolute;
    box-sizing: border-box;
}

.visual-zone-overlay {
    pointer-events: auto;
    border: 2px dashed #d52b1e;
    background: rgba(213, 43, 30, 0.08);
    border-radius: 8px;
    display: flex;
    align-items: flex-start;
    justify-content: flex-start;
    overflow: hidden;
}

.visual-zone-overlay.is-checkbox {
    align-items: center;
    justify-content: center;
}

.visual-zone-overlay.is-active {
    border-color: #234ea0;
    background: rgba(35, 78, 160, 0.12);
}

.visual-zone-overlay-label {
    font-size: 0.78rem;
    line-height: 1.2;
    padding: 0.2rem 0.35rem;
    background: rgba(255,255,255,0.92);
}

.visual-zone-overlay-checkbox,
.preview-answer-zone-checkbox,
.qlp-zone-checkbox {
    display: inline-flex;
    width: 1.05rem;
    height: 1.05rem;
    border: 2px solid currentColor;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    background: rgba(255,255,255,0.96);
}

.visual-zone-list {
    display: grid;
    gap: 0.75rem;
}

.visual-zone-item {
    border: 1px solid rgba(35, 78, 160, 0.14);
    border-radius: 14px;
    padding: 0.8rem;
    background: rgba(248, 250, 252, 0.95);
}

.visual-zone-item.is-highlighted {
    outline: 2px solid rgba(35, 78, 160, 0.35);
}

.visual-zone-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.65rem;
}

.visual-zone-actions {
    display: flex;
    gap: 0.5rem;
}

.visual-zone-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.7rem;
}

.visual-zone-grid > label {
    display: grid;
    gap: 0.35rem;
    font-size: 0.92rem;
}

.visual-zone-grid > label:first-child,
.visual-zone-solution {
    grid-column: 1 / -1;
}

.visual-zone-check-toggle {
    align-self: end;
}

.visual-zone-check-toggle input {
    width: auto;
}

.visual-zone-solution[hidden],
.visual-zone-check-toggle[hidden] {
    display: none;
}

.visual-zone-hint,
.visual-zone-points {
    color: #475467;
}

.preview-graphic-zones-image,
.qlp-graphic {
    margin: 0 auto;
}

.preview-graphic-zones-canvas,
.qlp-graphic-canvas {
    position: relative;
    display: block;
}

.preview-answer-zone {
    border: 2px solid #1d4ed8;
    border-radius: 8px;
    background: rgba(255,255,255,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.15rem;
    overflow: hidden;
}

.preview-answer-zone.is-solution {
    background: rgba(219, 234, 254, 0.92);
}

.preview-answer-zone-text {
    width: 100%;
    font-size: 0.82rem;
    line-height: 1.2;
    text-align: center;
}

.preview-graphic-zone-solutions {
    margin-top: 0.75rem;
    padding: 0.75rem 0.9rem;
    border-radius: 12px;
    background: rgba(37, 99, 235, 0.06);
}

.preview-graphic-zone-solutions ol {
    margin: 0.4rem 0 0;
    padding-left: 1.15rem;
}

.qlp-graphic-canvas {
    border: 1px solid #d0d5dd;
    border-radius: 8px;
    overflow: hidden;
}

.qlp-zone {
    border: 1.5px solid #234ea0;
    border-radius: 4px;
    background: rgba(255,255,255,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (max-width: 1100px) {
    .question-list-filter-grid,
    .visual-graphic-zones-layout {
        grid-template-columns: 1fr;
    }

    .question-filter-search {
        grid-column: auto;
    }
}


/* CSP-konforme Prozentklassen für Grafik-Antwortzonen. */
.zone-x-0 { left: 0%; }
.zone-x-1 { left: 1%; }
.zone-x-2 { left: 2%; }
.zone-x-3 { left: 3%; }
.zone-x-4 { left: 4%; }
.zone-x-5 { left: 5%; }
.zone-x-6 { left: 6%; }
.zone-x-7 { left: 7%; }
.zone-x-8 { left: 8%; }
.zone-x-9 { left: 9%; }
.zone-x-10 { left: 10%; }
.zone-x-11 { left: 11%; }
.zone-x-12 { left: 12%; }
.zone-x-13 { left: 13%; }
.zone-x-14 { left: 14%; }
.zone-x-15 { left: 15%; }
.zone-x-16 { left: 16%; }
.zone-x-17 { left: 17%; }
.zone-x-18 { left: 18%; }
.zone-x-19 { left: 19%; }
.zone-x-20 { left: 20%; }
.zone-x-21 { left: 21%; }
.zone-x-22 { left: 22%; }
.zone-x-23 { left: 23%; }
.zone-x-24 { left: 24%; }
.zone-x-25 { left: 25%; }
.zone-x-26 { left: 26%; }
.zone-x-27 { left: 27%; }
.zone-x-28 { left: 28%; }
.zone-x-29 { left: 29%; }
.zone-x-30 { left: 30%; }
.zone-x-31 { left: 31%; }
.zone-x-32 { left: 32%; }
.zone-x-33 { left: 33%; }
.zone-x-34 { left: 34%; }
.zone-x-35 { left: 35%; }
.zone-x-36 { left: 36%; }
.zone-x-37 { left: 37%; }
.zone-x-38 { left: 38%; }
.zone-x-39 { left: 39%; }
.zone-x-40 { left: 40%; }
.zone-x-41 { left: 41%; }
.zone-x-42 { left: 42%; }
.zone-x-43 { left: 43%; }
.zone-x-44 { left: 44%; }
.zone-x-45 { left: 45%; }
.zone-x-46 { left: 46%; }
.zone-x-47 { left: 47%; }
.zone-x-48 { left: 48%; }
.zone-x-49 { left: 49%; }
.zone-x-50 { left: 50%; }
.zone-x-51 { left: 51%; }
.zone-x-52 { left: 52%; }
.zone-x-53 { left: 53%; }
.zone-x-54 { left: 54%; }
.zone-x-55 { left: 55%; }
.zone-x-56 { left: 56%; }
.zone-x-57 { left: 57%; }
.zone-x-58 { left: 58%; }
.zone-x-59 { left: 59%; }
.zone-x-60 { left: 60%; }
.zone-x-61 { left: 61%; }
.zone-x-62 { left: 62%; }
.zone-x-63 { left: 63%; }
.zone-x-64 { left: 64%; }
.zone-x-65 { left: 65%; }
.zone-x-66 { left: 66%; }
.zone-x-67 { left: 67%; }
.zone-x-68 { left: 68%; }
.zone-x-69 { left: 69%; }
.zone-x-70 { left: 70%; }
.zone-x-71 { left: 71%; }
.zone-x-72 { left: 72%; }
.zone-x-73 { left: 73%; }
.zone-x-74 { left: 74%; }
.zone-x-75 { left: 75%; }
.zone-x-76 { left: 76%; }
.zone-x-77 { left: 77%; }
.zone-x-78 { left: 78%; }
.zone-x-79 { left: 79%; }
.zone-x-80 { left: 80%; }
.zone-x-81 { left: 81%; }
.zone-x-82 { left: 82%; }
.zone-x-83 { left: 83%; }
.zone-x-84 { left: 84%; }
.zone-x-85 { left: 85%; }
.zone-x-86 { left: 86%; }
.zone-x-87 { left: 87%; }
.zone-x-88 { left: 88%; }
.zone-x-89 { left: 89%; }
.zone-x-90 { left: 90%; }
.zone-x-91 { left: 91%; }
.zone-x-92 { left: 92%; }
.zone-x-93 { left: 93%; }
.zone-x-94 { left: 94%; }
.zone-x-95 { left: 95%; }
.zone-x-96 { left: 96%; }
.zone-x-97 { left: 97%; }
.zone-x-98 { left: 98%; }
.zone-x-99 { left: 99%; }
.zone-y-0 { top: 0%; }
.zone-y-1 { top: 1%; }
.zone-y-2 { top: 2%; }
.zone-y-3 { top: 3%; }
.zone-y-4 { top: 4%; }
.zone-y-5 { top: 5%; }
.zone-y-6 { top: 6%; }
.zone-y-7 { top: 7%; }
.zone-y-8 { top: 8%; }
.zone-y-9 { top: 9%; }
.zone-y-10 { top: 10%; }
.zone-y-11 { top: 11%; }
.zone-y-12 { top: 12%; }
.zone-y-13 { top: 13%; }
.zone-y-14 { top: 14%; }
.zone-y-15 { top: 15%; }
.zone-y-16 { top: 16%; }
.zone-y-17 { top: 17%; }
.zone-y-18 { top: 18%; }
.zone-y-19 { top: 19%; }
.zone-y-20 { top: 20%; }
.zone-y-21 { top: 21%; }
.zone-y-22 { top: 22%; }
.zone-y-23 { top: 23%; }
.zone-y-24 { top: 24%; }
.zone-y-25 { top: 25%; }
.zone-y-26 { top: 26%; }
.zone-y-27 { top: 27%; }
.zone-y-28 { top: 28%; }
.zone-y-29 { top: 29%; }
.zone-y-30 { top: 30%; }
.zone-y-31 { top: 31%; }
.zone-y-32 { top: 32%; }
.zone-y-33 { top: 33%; }
.zone-y-34 { top: 34%; }
.zone-y-35 { top: 35%; }
.zone-y-36 { top: 36%; }
.zone-y-37 { top: 37%; }
.zone-y-38 { top: 38%; }
.zone-y-39 { top: 39%; }
.zone-y-40 { top: 40%; }
.zone-y-41 { top: 41%; }
.zone-y-42 { top: 42%; }
.zone-y-43 { top: 43%; }
.zone-y-44 { top: 44%; }
.zone-y-45 { top: 45%; }
.zone-y-46 { top: 46%; }
.zone-y-47 { top: 47%; }
.zone-y-48 { top: 48%; }
.zone-y-49 { top: 49%; }
.zone-y-50 { top: 50%; }
.zone-y-51 { top: 51%; }
.zone-y-52 { top: 52%; }
.zone-y-53 { top: 53%; }
.zone-y-54 { top: 54%; }
.zone-y-55 { top: 55%; }
.zone-y-56 { top: 56%; }
.zone-y-57 { top: 57%; }
.zone-y-58 { top: 58%; }
.zone-y-59 { top: 59%; }
.zone-y-60 { top: 60%; }
.zone-y-61 { top: 61%; }
.zone-y-62 { top: 62%; }
.zone-y-63 { top: 63%; }
.zone-y-64 { top: 64%; }
.zone-y-65 { top: 65%; }
.zone-y-66 { top: 66%; }
.zone-y-67 { top: 67%; }
.zone-y-68 { top: 68%; }
.zone-y-69 { top: 69%; }
.zone-y-70 { top: 70%; }
.zone-y-71 { top: 71%; }
.zone-y-72 { top: 72%; }
.zone-y-73 { top: 73%; }
.zone-y-74 { top: 74%; }
.zone-y-75 { top: 75%; }
.zone-y-76 { top: 76%; }
.zone-y-77 { top: 77%; }
.zone-y-78 { top: 78%; }
.zone-y-79 { top: 79%; }
.zone-y-80 { top: 80%; }
.zone-y-81 { top: 81%; }
.zone-y-82 { top: 82%; }
.zone-y-83 { top: 83%; }
.zone-y-84 { top: 84%; }
.zone-y-85 { top: 85%; }
.zone-y-86 { top: 86%; }
.zone-y-87 { top: 87%; }
.zone-y-88 { top: 88%; }
.zone-y-89 { top: 89%; }
.zone-y-90 { top: 90%; }
.zone-y-91 { top: 91%; }
.zone-y-92 { top: 92%; }
.zone-y-93 { top: 93%; }
.zone-y-94 { top: 94%; }
.zone-y-95 { top: 95%; }
.zone-y-96 { top: 96%; }
.zone-y-97 { top: 97%; }
.zone-y-98 { top: 98%; }
.zone-y-99 { top: 99%; }
.zone-w-1 { width: 1%; }
.zone-w-2 { width: 2%; }
.zone-w-3 { width: 3%; }
.zone-w-4 { width: 4%; }
.zone-w-5 { width: 5%; }
.zone-w-6 { width: 6%; }
.zone-w-7 { width: 7%; }
.zone-w-8 { width: 8%; }
.zone-w-9 { width: 9%; }
.zone-w-10 { width: 10%; }
.zone-w-11 { width: 11%; }
.zone-w-12 { width: 12%; }
.zone-w-13 { width: 13%; }
.zone-w-14 { width: 14%; }
.zone-w-15 { width: 15%; }
.zone-w-16 { width: 16%; }
.zone-w-17 { width: 17%; }
.zone-w-18 { width: 18%; }
.zone-w-19 { width: 19%; }
.zone-w-20 { width: 20%; }
.zone-w-21 { width: 21%; }
.zone-w-22 { width: 22%; }
.zone-w-23 { width: 23%; }
.zone-w-24 { width: 24%; }
.zone-w-25 { width: 25%; }
.zone-w-26 { width: 26%; }
.zone-w-27 { width: 27%; }
.zone-w-28 { width: 28%; }
.zone-w-29 { width: 29%; }
.zone-w-30 { width: 30%; }
.zone-w-31 { width: 31%; }
.zone-w-32 { width: 32%; }
.zone-w-33 { width: 33%; }
.zone-w-34 { width: 34%; }
.zone-w-35 { width: 35%; }
.zone-w-36 { width: 36%; }
.zone-w-37 { width: 37%; }
.zone-w-38 { width: 38%; }
.zone-w-39 { width: 39%; }
.zone-w-40 { width: 40%; }
.zone-w-41 { width: 41%; }
.zone-w-42 { width: 42%; }
.zone-w-43 { width: 43%; }
.zone-w-44 { width: 44%; }
.zone-w-45 { width: 45%; }
.zone-w-46 { width: 46%; }
.zone-w-47 { width: 47%; }
.zone-w-48 { width: 48%; }
.zone-w-49 { width: 49%; }
.zone-w-50 { width: 50%; }
.zone-w-51 { width: 51%; }
.zone-w-52 { width: 52%; }
.zone-w-53 { width: 53%; }
.zone-w-54 { width: 54%; }
.zone-w-55 { width: 55%; }
.zone-w-56 { width: 56%; }
.zone-w-57 { width: 57%; }
.zone-w-58 { width: 58%; }
.zone-w-59 { width: 59%; }
.zone-w-60 { width: 60%; }
.zone-w-61 { width: 61%; }
.zone-w-62 { width: 62%; }
.zone-w-63 { width: 63%; }
.zone-w-64 { width: 64%; }
.zone-w-65 { width: 65%; }
.zone-w-66 { width: 66%; }
.zone-w-67 { width: 67%; }
.zone-w-68 { width: 68%; }
.zone-w-69 { width: 69%; }
.zone-w-70 { width: 70%; }
.zone-w-71 { width: 71%; }
.zone-w-72 { width: 72%; }
.zone-w-73 { width: 73%; }
.zone-w-74 { width: 74%; }
.zone-w-75 { width: 75%; }
.zone-w-76 { width: 76%; }
.zone-w-77 { width: 77%; }
.zone-w-78 { width: 78%; }
.zone-w-79 { width: 79%; }
.zone-w-80 { width: 80%; }
.zone-w-81 { width: 81%; }
.zone-w-82 { width: 82%; }
.zone-w-83 { width: 83%; }
.zone-w-84 { width: 84%; }
.zone-w-85 { width: 85%; }
.zone-w-86 { width: 86%; }
.zone-w-87 { width: 87%; }
.zone-w-88 { width: 88%; }
.zone-w-89 { width: 89%; }
.zone-w-90 { width: 90%; }
.zone-w-91 { width: 91%; }
.zone-w-92 { width: 92%; }
.zone-w-93 { width: 93%; }
.zone-w-94 { width: 94%; }
.zone-w-95 { width: 95%; }
.zone-w-96 { width: 96%; }
.zone-w-97 { width: 97%; }
.zone-w-98 { width: 98%; }
.zone-w-99 { width: 99%; }
.zone-w-100 { width: 100%; }
.zone-h-1 { height: 1%; }
.zone-h-2 { height: 2%; }
.zone-h-3 { height: 3%; }
.zone-h-4 { height: 4%; }
.zone-h-5 { height: 5%; }
.zone-h-6 { height: 6%; }
.zone-h-7 { height: 7%; }
.zone-h-8 { height: 8%; }
.zone-h-9 { height: 9%; }
.zone-h-10 { height: 10%; }
.zone-h-11 { height: 11%; }
.zone-h-12 { height: 12%; }
.zone-h-13 { height: 13%; }
.zone-h-14 { height: 14%; }
.zone-h-15 { height: 15%; }
.zone-h-16 { height: 16%; }
.zone-h-17 { height: 17%; }
.zone-h-18 { height: 18%; }
.zone-h-19 { height: 19%; }
.zone-h-20 { height: 20%; }
.zone-h-21 { height: 21%; }
.zone-h-22 { height: 22%; }
.zone-h-23 { height: 23%; }
.zone-h-24 { height: 24%; }
.zone-h-25 { height: 25%; }
.zone-h-26 { height: 26%; }
.zone-h-27 { height: 27%; }
.zone-h-28 { height: 28%; }
.zone-h-29 { height: 29%; }
.zone-h-30 { height: 30%; }
.zone-h-31 { height: 31%; }
.zone-h-32 { height: 32%; }
.zone-h-33 { height: 33%; }
.zone-h-34 { height: 34%; }
.zone-h-35 { height: 35%; }
.zone-h-36 { height: 36%; }
.zone-h-37 { height: 37%; }
.zone-h-38 { height: 38%; }
.zone-h-39 { height: 39%; }
.zone-h-40 { height: 40%; }
.zone-h-41 { height: 41%; }
.zone-h-42 { height: 42%; }
.zone-h-43 { height: 43%; }
.zone-h-44 { height: 44%; }
.zone-h-45 { height: 45%; }
.zone-h-46 { height: 46%; }
.zone-h-47 { height: 47%; }
.zone-h-48 { height: 48%; }
.zone-h-49 { height: 49%; }
.zone-h-50 { height: 50%; }
.zone-h-51 { height: 51%; }
.zone-h-52 { height: 52%; }
.zone-h-53 { height: 53%; }
.zone-h-54 { height: 54%; }
.zone-h-55 { height: 55%; }
.zone-h-56 { height: 56%; }
.zone-h-57 { height: 57%; }
.zone-h-58 { height: 58%; }
.zone-h-59 { height: 59%; }
.zone-h-60 { height: 60%; }
.zone-h-61 { height: 61%; }
.zone-h-62 { height: 62%; }
.zone-h-63 { height: 63%; }
.zone-h-64 { height: 64%; }
.zone-h-65 { height: 65%; }
.zone-h-66 { height: 66%; }
.zone-h-67 { height: 67%; }
.zone-h-68 { height: 68%; }
.zone-h-69 { height: 69%; }
.zone-h-70 { height: 70%; }
.zone-h-71 { height: 71%; }
.zone-h-72 { height: 72%; }
.zone-h-73 { height: 73%; }
.zone-h-74 { height: 74%; }
.zone-h-75 { height: 75%; }
.zone-h-76 { height: 76%; }
.zone-h-77 { height: 77%; }
.zone-h-78 { height: 78%; }
.zone-h-79 { height: 79%; }
.zone-h-80 { height: 80%; }
.zone-h-81 { height: 81%; }
.zone-h-82 { height: 82%; }
.zone-h-83 { height: 83%; }
.zone-h-84 { height: 84%; }
.zone-h-85 { height: 85%; }
.zone-h-86 { height: 86%; }
.zone-h-87 { height: 87%; }
.zone-h-88 { height: 88%; }
.zone-h-89 { height: 89%; }
.zone-h-90 { height: 90%; }
.zone-h-91 { height: 91%; }
.zone-h-92 { height: 92%; }
.zone-h-93 { height: 93%; }
.zone-h-94 { height: 94%; }
.zone-h-95 { height: 95%; }
.zone-h-96 { height: 96%; }
.zone-h-97 { height: 97%; }
.zone-h-98 { height: 98%; }
.zone-h-99 { height: 99%; }
.zone-h-100 { height: 100%; }
.percent-width-20 { width: 20%; }
.percent-width-21 { width: 21%; }
.percent-width-22 { width: 22%; }
.percent-width-23 { width: 23%; }
.percent-width-24 { width: 24%; }
.percent-width-25 { width: 25%; }
.percent-width-26 { width: 26%; }
.percent-width-27 { width: 27%; }
.percent-width-28 { width: 28%; }
.percent-width-29 { width: 29%; }
.percent-width-30 { width: 30%; }
.percent-width-31 { width: 31%; }
.percent-width-32 { width: 32%; }
.percent-width-33 { width: 33%; }
.percent-width-34 { width: 34%; }
.percent-width-35 { width: 35%; }
.percent-width-36 { width: 36%; }
.percent-width-37 { width: 37%; }
.percent-width-38 { width: 38%; }
.percent-width-39 { width: 39%; }
.percent-width-40 { width: 40%; }
.percent-width-41 { width: 41%; }
.percent-width-42 { width: 42%; }
.percent-width-43 { width: 43%; }
.percent-width-44 { width: 44%; }
.percent-width-45 { width: 45%; }
.percent-width-46 { width: 46%; }
.percent-width-47 { width: 47%; }
.percent-width-48 { width: 48%; }
.percent-width-49 { width: 49%; }
.percent-width-50 { width: 50%; }
.percent-width-51 { width: 51%; }
.percent-width-52 { width: 52%; }
.percent-width-53 { width: 53%; }
.percent-width-54 { width: 54%; }
.percent-width-55 { width: 55%; }
.percent-width-56 { width: 56%; }
.percent-width-57 { width: 57%; }
.percent-width-58 { width: 58%; }
.percent-width-59 { width: 59%; }
.percent-width-60 { width: 60%; }
.percent-width-61 { width: 61%; }
.percent-width-62 { width: 62%; }
.percent-width-63 { width: 63%; }
.percent-width-64 { width: 64%; }
.percent-width-65 { width: 65%; }
.percent-width-66 { width: 66%; }
.percent-width-67 { width: 67%; }
.percent-width-68 { width: 68%; }
.percent-width-69 { width: 69%; }
.percent-width-70 { width: 70%; }
.percent-width-71 { width: 71%; }
.percent-width-72 { width: 72%; }
.percent-width-73 { width: 73%; }
.percent-width-74 { width: 74%; }
.percent-width-75 { width: 75%; }
.percent-width-76 { width: 76%; }
.percent-width-77 { width: 77%; }
.percent-width-78 { width: 78%; }
.percent-width-79 { width: 79%; }
.percent-width-80 { width: 80%; }
.percent-width-81 { width: 81%; }
.percent-width-82 { width: 82%; }
.percent-width-83 { width: 83%; }
.percent-width-84 { width: 84%; }
.percent-width-85 { width: 85%; }
.percent-width-86 { width: 86%; }
.percent-width-87 { width: 87%; }
.percent-width-88 { width: 88%; }
.percent-width-89 { width: 89%; }
.percent-width-90 { width: 90%; }
.percent-width-91 { width: 91%; }
.percent-width-92 { width: 92%; }
.percent-width-93 { width: 93%; }
.percent-width-94 { width: 94%; }
.percent-width-95 { width: 95%; }
.percent-width-96 { width: 96%; }
.percent-width-97 { width: 97%; }
.percent-width-98 { width: 98%; }
.percent-width-99 { width: 99%; }
.percent-width-100 { width: 100%; }

textarea[data-autogrow], textarea.is-auto-grow {
    field-sizing: content;
    min-height: 44px;
}

.preview-answer-zone-text {
    overflow: hidden;
    overflow-wrap: anywhere;
    word-break: normal;
}

/* v6.4.4 – Grafikzonen und serverseitige Tabellensortierung */
.question-list-filter-grid {
    grid-template-columns: minmax(18rem, 2fr) repeat(3, minmax(12rem, 1fr));
}

.question-filter-search {
    grid-column: auto;
}

.question-table th.question-sortable-th {
    padding: 0;
}

.question-table th.question-sortable-th .table-sort-link {
    width: 100%;
    min-height: 42px;
    padding: 13px 14px;
    justify-content: space-between;
    box-sizing: border-box;
}

.question-table th.question-sortable-th .table-sort-link:hover,
.question-table th.question-sortable-th .table-sort-link:focus-visible {
    background: rgba(49, 91, 117, 0.08);
    text-decoration: none;
}

.visual-zone-box-toggle {
    align-self: end;
}

.visual-zone-box-toggle input {
    width: auto;
}

/* Im Editor bleibt eine ausgeblendete Box absichtlich als dezente Bearbeitungshilfe sichtbar. */
.visual-zone-overlay.is-output-hidden {
    border-color: #98a2b3;
    background: rgba(152, 162, 179, 0.08);
}

.visual-zone-overlay.is-output-hidden .visual-zone-overlay-label::after {
    content: " · Box ausgeblendet";
    color: #667085;
    font-size: 0.72rem;
}

/* In Prüfungs- und Musterlösungsansicht kann die Zone vollständig rahmenlos sein. */
.preview-answer-zone.is-box-hidden {
    border-color: transparent;
    background: transparent;
    border-radius: 0;
}

.preview-answer-zone.is-box-hidden.is-solution {
    background: transparent;
}

.preview-answer-zone.is-box-hidden .preview-answer-zone-checkbox {
    border-color: transparent;
    background: transparent;
}

.preview-answer-zone.is-solution .preview-answer-zone-text,
.preview-answer-zone.is-solution .preview-answer-zone-checkbox {
    color: #d10000;
    font-weight: 700;
}

.preview-answer-zone.is-solution .preview-answer-zone-checkbox {
    font-size: 1.25rem;
}

.qlp-zone.is-box-hidden {
    border-color: transparent;
    background: transparent;
    border-radius: 0;
}

.qlp-zone.is-box-hidden .qlp-zone-checkbox {
    visibility: hidden;
}

.preview-graphic-zone-solutions ul {
    margin: 0.4rem 0 0;
    padding-left: 1.15rem;
}

@media (max-width: 1100px) {
    .question-list-filter-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 720px) {
    .question-list-filter-grid {
        grid-template-columns: 1fr;
    }
}

/* v6.4.5 – kompakter Editor für Grafik-Antwortzonen */
.visual-graphic-zones-layout {
    grid-template-columns: minmax(0, 2.15fr) minmax(19rem, 0.85fr);
    align-items: start;
}

.visual-graphic-zones-stage-wrap {
    min-width: 0;
}

.visual-graphic-zones-sidebar {
    min-width: 0;
    max-height: 44rem;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.visual-graphic-zones-sidebar > .visual-zone-toolbar {
    flex: 0 0 auto;
}

.visual-zone-list {
    overflow-y: auto;
    padding-right: 0.25rem;
    margin-right: -0.25rem;
}

.visual-zone-item {
    padding: 0;
    overflow: hidden;
    background: #fff;
    transition: border-color 120ms ease, box-shadow 120ms ease;
}

.visual-zone-item.is-active {
    border-color: rgba(35, 78, 160, 0.42);
    box-shadow: 0 0 0 2px rgba(35, 78, 160, 0.07);
}

.visual-zone-head {
    margin: 0;
    gap: 0.45rem;
    padding: 0.45rem;
    background: rgba(248, 250, 252, 0.96);
}

.visual-zone-item.is-active .visual-zone-head {
    border-bottom: 1px solid rgba(35, 78, 160, 0.12);
}

.visual-zone-summary {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.55rem;
    padding: 0.4rem 0.45rem;
    border: 0;
    background: transparent;
    text-align: left;
    color: inherit;
    cursor: pointer;
}

.visual-zone-summary:hover,
.visual-zone-summary:focus-visible {
    background: rgba(35, 78, 160, 0.06);
    border-radius: 8px;
}

.visual-zone-summary-copy {
    min-width: 0;
    display: grid;
    gap: 0.05rem;
}

.visual-zone-summary-copy strong,
.visual-zone-summary-copy small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.visual-zone-summary-copy small {
    color: #667085;
    font-size: 0.78rem;
}

.visual-zone-chevron {
    flex: 0 0 auto;
    transition: transform 120ms ease;
}

.visual-zone-item.is-active .visual-zone-chevron {
    transform: rotate(180deg);
}

.visual-zone-actions {
    flex: 0 0 auto;
    align-items: center;
    gap: 0.35rem;
}

.visual-zone-draw-button {
    width: 7.7rem;
    min-width: 7.7rem;
    white-space: nowrap;
    padding-left: 0.55rem;
    padding-right: 0.55rem;
}

.visual-zone-actions .danger-ghost {
    width: 2.25rem;
    min-width: 2.25rem;
    padding-left: 0;
    padding-right: 0;
}

.visual-zone-body {
    padding: 0.8rem;
}

.visual-zone-body[hidden] {
    display: none;
}

.visual-zone-grid-main {
    grid-template-columns: minmax(0, 1.4fr) minmax(7.5rem, 1fr) minmax(5.2rem, 0.55fr);
    gap: 0.65rem;
}

.visual-zone-grid-main > label,
.visual-zone-position-grid > label {
    display: grid;
    gap: 0.28rem;
    font-size: 0.84rem;
    color: #475467;
}

.visual-zone-grid-main input,
.visual-zone-grid-main select,
.visual-zone-position-grid input {
    width: 100%;
}

.visual-zone-name {
    grid-column: auto !important;
}

.visual-zone-switch-row {
    margin-top: 0.7rem;
    padding: 0.62rem 0.7rem;
    border: 1px solid #e4e7ec;
    border-radius: 10px;
    background: #f9fafb;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    cursor: pointer;
}

.visual-zone-switch-row > span:first-child {
    min-width: 0;
    display: grid;
    gap: 0.05rem;
}

.visual-zone-switch-row strong {
    font-size: 0.86rem;
    color: #344054;
}

.visual-zone-switch-row small {
    color: #667085;
    font-size: 0.76rem;
    line-height: 1.25;
}

.visual-switch {
    position: relative;
    flex: 0 0 auto;
    width: 2.65rem;
    height: 1.45rem;
}

.visual-switch input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

.visual-switch > span {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: #cbd5e1;
    transition: background 120ms ease;
    pointer-events: none;
}

.visual-switch > span::after {
    content: '';
    position: absolute;
    width: 1.05rem;
    height: 1.05rem;
    left: 0.2rem;
    top: 0.2rem;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.25);
    transition: transform 120ms ease;
}

.visual-switch input:checked + span {
    background: #2563eb;
}

.visual-switch input:checked + span::after {
    transform: translateX(1.2rem);
}

.visual-switch input:focus-visible + span {
    outline: 2px solid #2563eb;
    outline-offset: 2px;
}

.visual-zone-solution {
    margin-top: 0.7rem;
    display: grid;
    gap: 0.3rem;
    font-size: 0.86rem;
    color: #475467;
}

.visual-zone-solution textarea {
    min-height: 4.6rem;
}

.visual-zone-advanced {
    margin-top: 0.72rem;
    border-top: 1px solid #eaecf0;
    padding-top: 0.65rem;
}

.visual-zone-advanced summary {
    color: #475467;
    font-size: 0.82rem;
    cursor: pointer;
    user-select: none;
}

.visual-zone-position-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.55rem;
    margin-top: 0.65rem;
}

/* Die komplette Tabellenüberschrift ist die Sortierfläche. */
.question-table th:has(.table-sort-link) {
    padding: 0;
}

.table-sort-link {
    width: 100%;
    min-height: 2.9rem;
    padding: 0.7rem 0.75rem;
    justify-content: space-between;
    box-sizing: border-box;
}

.table-sort-link:hover,
.table-sort-link:focus-visible {
    background: rgba(35, 78, 160, 0.06);
}

@media (max-width: 1180px) {
    .visual-zone-grid-main {
        grid-template-columns: 1fr 1fr;
    }

    .visual-zone-name {
        grid-column: 1 / -1 !important;
    }

    .visual-zone-position-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* v6.4.6 – direkte Bearbeitung der Grafik-Antwortzonen */
.visual-graphic-zones-layout {
    grid-template-columns: minmax(0, 1.7fr) minmax(22rem, 1fr);
    gap: 0.9rem;
}

.visual-zone-toolbar {
    align-items: flex-start;
}

.visual-zone-toolbar-copy {
    min-width: 0;
    display: grid;
    gap: 0.18rem;
}

.visual-zone-toolbar-copy > strong,
.visual-zone-toolbar-copy > small {
    display: block;
}

.visual-zone-toolbar-copy > small {
    line-height: 1.25;
}

.visual-grid-control {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    min-height: 2rem;
    font-size: 0.82rem;
    color: #475467;
    cursor: pointer;
}

.visual-switch.visual-switch-small {
    width: 2.35rem;
    height: 1.3rem;
}

.visual-switch.visual-switch-small > span::after {
    width: 0.92rem;
    height: 0.92rem;
    left: 0.19rem;
    top: 0.19rem;
}

.visual-switch.visual-switch-small input:checked + span::after {
    transform: translateX(1.05rem);
}

.visual-zone-grid-main {
    grid-template-columns: minmax(0, 1fr) minmax(5.5rem, 0.42fr);
    gap: 0.65rem;
}

.visual-zone-name {
    grid-column: 1 / -1 !important;
}

.visual-zone-grid-main > label > span,
.visual-zone-position-grid > label > span,
.visual-zone-solution > span {
    display: block;
}

.visual-zone-switch-line {
    margin-top: 0.72rem;
    min-height: 2.45rem;
    padding: 0.4rem 0.12rem;
    border-top: 1px solid #eaecf0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    color: #344054;
    font-size: 0.86rem;
}

.visual-zone-switch-line + .visual-zone-switch-line {
    margin-top: 0;
}

.visual-zone-draw-button {
    width: 7.5rem;
    min-width: 7.5rem;
}

.visual-zone-advanced summary {
    font-weight: 600;
}

.visual-graphic-zones-canvas.is-grid-enabled {
    background-image:
        linear-gradient(to right, rgba(35, 78, 160, 0.18) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(35, 78, 160, 0.18) 1px, transparent 1px);
    background-size: 5% 5%;
}

.visual-zone-overlay {
    cursor: move;
    touch-action: none;
    user-select: none;
}

.visual-zone-overlay.is-active {
    overflow: visible;
    z-index: 5;
}

.visual-zone-overlay.is-output-hidden .visual-zone-overlay-label::after {
    content: none;
}

.visual-zone-resize-handle {
    position: absolute;
    z-index: 7;
    width: 0.7rem;
    height: 0.7rem;
    border: 2px solid #2563eb;
    border-radius: 2px;
    background: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.22);
    pointer-events: auto;
}

.visual-zone-resize-handle.is-nw { left: -0.42rem; top: -0.42rem; cursor: nwse-resize; }
.visual-zone-resize-handle.is-n  { left: calc(50% - 0.35rem); top: -0.42rem; cursor: ns-resize; }
.visual-zone-resize-handle.is-ne { right: -0.42rem; top: -0.42rem; cursor: nesw-resize; }
.visual-zone-resize-handle.is-e  { right: -0.42rem; top: calc(50% - 0.35rem); cursor: ew-resize; }
.visual-zone-resize-handle.is-se { right: -0.42rem; bottom: -0.42rem; cursor: nwse-resize; }
.visual-zone-resize-handle.is-s  { left: calc(50% - 0.35rem); bottom: -0.42rem; cursor: ns-resize; }
.visual-zone-resize-handle.is-sw { left: -0.42rem; bottom: -0.42rem; cursor: nesw-resize; }
.visual-zone-resize-handle.is-w  { left: -0.42rem; top: calc(50% - 0.35rem); cursor: ew-resize; }

.visual-editor-block-graphic_zones.is-manipulating-zone .visual-zone-overlay.is-active {
    cursor: grabbing;
}

.visual-editor-block-graphic_zones.is-manipulating-zone .visual-zone-overlay-label {
    pointer-events: none;
}

@media (max-width: 1180px) {
    .visual-graphic-zones-layout {
        grid-template-columns: 1fr;
    }

    .visual-zone-grid-main {
        grid-template-columns: minmax(0, 1fr) minmax(6rem, 0.4fr);
    }
}

/* ==========================================================================
 * v7.1 – Toolbar und Klassifikationsverwaltung
 * ========================================================================== */

.menu-button {
    transition: width 180ms ease, flex-basis 180ms ease, background 160ms ease;
}

/* Der dunklere Toolbar-Bereich folgt auf Desktop der tatsächlichen Menübreite. */
@media (min-width: 1220px) {
    .admin-shell:not(.is-compact) .menu-button {
        width: var(--admin-sidebar-wide);
        flex-basis: var(--admin-sidebar-wide);
        flex-direction: row;
        gap: 9px;
        font-size: .82rem;
    }
}

/* Auf Tablets folgt er dem geöffneten Drawer, bleibt geschlossen kompakt. */
@media (min-width: 870px) and (max-width: 1219px) {
    .admin-shell.is-open .menu-button {
        width: var(--admin-sidebar-wide);
        flex-basis: var(--admin-sidebar-wide);
        flex-direction: row;
        gap: 9px;
        font-size: .82rem;
    }
}

/* Der neutrale Eintrag soll wie eine Platzhalteroption wirken, nicht wie ein deaktiviertes Feld. */
.question-list-filters select option.filter-empty-option {
    color: #8a99a3;
    font-style: italic;
}

.classification-admin-page {
    max-width: 1500px;
}

.classification-admin-layout {
    display: grid;
    grid-template-columns: minmax(360px, .95fr) minmax(420px, 1.05fr);
    gap: 22px;
    align-items: start;
}

.classification-tree-panel,
.classification-editor-panel {
    min-width: 0;
    overflow: hidden;
    border: 1px solid #cbd7de;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(26, 48, 63, .08);
}

.classification-panel-heading {
    min-height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 14px 18px;
    border-bottom: 1px solid #dce5ea;
    background: #f7f9fa;
}

.classification-panel-heading h3,
.classification-empty-state h3 {
    margin: 0;
    color: #183b54;
    font-size: 1.04rem;
}

.classification-panel-heading p,
.classification-empty-state p {
    margin: 4px 0 0;
    color: #647985;
    font-size: .82rem;
    line-height: 1.45;
}

.classification-panel-heading > span {
    flex: 0 0 auto;
    padding: 4px 8px;
    border-radius: 999px;
    color: #526a79;
    background: #e7eef2;
    font-size: .72rem;
    font-weight: 700;
}

.classification-tree {
    max-height: min(72vh, 920px);
    overflow: auto;
    padding: 10px 0 14px;
}

.classification-tree-list {
    margin: 0;
    padding: 0 0 0 22px;
    list-style: none;
}

.classification-tree > .classification-tree-list {
    padding-left: 0;
}

.classification-tree-item {
    position: relative;
}

.classification-tree-item > .classification-tree-list {
    margin-left: 18px;
    border-left: 1px solid #d5e0e6;
}

.classification-tree-row {
    display: flex;
    align-items: stretch;
    min-width: 0;
    border-left: 3px solid transparent;
}

.classification-tree-row:hover,
.classification-tree-row:focus-within {
    background: #f2f7fa;
}

.classification-tree-row.is-selected {
    border-left-color: var(--admin-navbar);
    background: #e4eff5;
}

.classification-tree-main {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 8px 10px 8px 13px;
    color: #244b64;
    text-decoration: none;
}

.classification-tree-code {
    flex: 0 0 auto;
    color: #1f678f;
    font-size: .74rem;
    font-weight: 800;
}

.classification-tree-name {
    min-width: 0;
    overflow: hidden;
    flex: 1 1 auto;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: .84rem;
}

.classification-tree-badge,
.classification-tree-usage {
    flex: 0 0 auto;
    padding: 2px 6px;
    border-radius: 999px;
    color: #5d7280;
    background: #e9eff2;
    font-size: .65rem;
    font-weight: 700;
}

.classification-tree-badge.is-muted {
    color: #7e6f72;
    background: #f0e8e9;
}

.classification-tree-usage {
    min-width: 23px;
    text-align: center;
}

.classification-tree-add {
    width: 38px;
    flex: 0 0 38px;
    display: grid;
    place-items: center;
    color: #27688f;
    text-decoration: none;
    font-size: 1.15rem;
    font-weight: 600;
}

.classification-tree-add:hover,
.classification-tree-add:focus-visible {
    color: #fff;
    background: var(--admin-navbar);
}

.classification-empty-state {
    padding: 28px 30px;
}

.classification-edit-form {
    display: grid;
    gap: 18px;
    padding: 22px;
}

.classification-form-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 150px;
    gap: 14px;
}

.classification-switches {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.classification-switch {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 13px 14px;
    border: 1px solid #d4dfe5;
    border-radius: 5px;
    background: #f8fafb;
    cursor: pointer;
}

.classification-switch input {
    margin-top: 3px;
}

.classification-switch span,
.classification-switch strong,
.classification-switch small {
    display: block;
}

.classification-switch strong {
    color: #244b64;
    font-size: .86rem;
}

.classification-switch small {
    margin-top: 3px;
    color: #657985;
    font-size: .75rem;
    line-height: 1.35;
}

.classification-technical-meta {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 14px 16px;
    border: 1px solid #dce4e8;
    border-radius: 5px;
    background: #f6f8f9;
}

.classification-technical-meta > div {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 14px;
}

.classification-technical-meta dt {
    color: #687b86;
    font-size: .73rem;
    font-weight: 700;
}

.classification-technical-meta dd {
    min-width: 0;
    margin: 0;
    overflow-wrap: anywhere;
    color: #2d4b5d;
    font-size: .78rem;
}

.classification-form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 4px;
}

@media (max-width: 1120px) {
    .classification-admin-layout {
        grid-template-columns: 1fr;
    }

    .classification-tree {
        max-height: 54vh;
    }
}

@media (max-width: 620px) {
    .classification-form-grid,
    .classification-switches,
    .classification-technical-meta > div {
        grid-template-columns: 1fr;
    }

    .classification-tree-main {
        flex-wrap: wrap;
    }

    .classification-tree-name {
        white-space: normal;
    }
}

/* =======================================================================
   Fragenworkflow v7.2.0
   ======================================================================= */
.question-workflow-strip {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin: 0 0 14px;
}

.workflow-step,
.workflow-status-grid > div {
    min-width: 0;
    padding: 11px 13px;
    border: 1px solid #c9d7df;
    border-radius: 8px;
    background: #f7fafb;
}

.workflow-step small,
.workflow-status-grid small,
.workflow-mini-stack small {
    display: block;
    margin-bottom: 3px;
    color: #687b86;
    font-size: .72rem;
    font-weight: 700;
}

.workflow-step strong,
.workflow-status-grid strong {
    color: #173d52;
    font-size: .84rem;
}

.workflow-step-secondary {
    background: #eef4f7;
}

.workflow-readonly-note {
    margin: 0 0 14px;
    padding: 11px 13px;
    border: 1px solid #d8caa6;
    border-radius: 8px;
    background: #fffaf0;
    color: #5f5132;
}

.workflow-fieldset {
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.workflow-fieldset[disabled] {
    opacity: .78;
}

.workflow-content-basics {
    margin-bottom: 14px;
}

.workflow-action-card,
.workflow-decision-card {
    margin-top: 16px;
    padding: 16px;
    border: 1px solid #c9d7df;
    border-radius: 9px;
    background: #f7fafb;
}

.workflow-action-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.workflow-action-card.compact {
    margin-top: 0;
}

.workflow-action-card p,
.workflow-decision-card p {
    margin: 4px 0 0;
    color: #687b86;
}

.workflow-action-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 9px;
    margin-top: 12px;
}

.workflow-action-row-secondary {
    padding-top: 12px;
    border-top: 1px solid #d7e1e6;
}

.workflow-action-stack {
    display: grid;
    gap: 12px;
    margin-top: 14px;
}

.workflow-status-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin: 14px 0;
}

.workflow-mini-stack {
    display: grid;
    gap: 5px;
    min-width: 180px;
}

.workflow-mini-stack > span {
    display: block;
}

.workflow-mini-stack strong {
    display: block;
    color: #294c60;
    font-size: .76rem;
    line-height: 1.25;
}

.workflow-mini-archived {
    margin-top: 3px;
    font-size: .73rem;
    font-weight: 700;
    color: #7b3333;
}

.history-event-label {
    display: inline-flex;
    align-items: center;
    padding: 2px 7px;
    border-radius: 999px;
    background: #e8f1f5;
    color: #24495d;
    font-size: .72rem;
    font-weight: 700;
}

@media (max-width: 980px) {
    .question-workflow-strip,
    .workflow-status-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 620px) {
    .question-workflow-strip,
    .workflow-status-grid {
        grid-template-columns: 1fr;
    }

    .workflow-action-card {
        align-items: stretch;
        flex-direction: column;
    }
}

.workflow-submit-card {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(260px, 1.1fr) auto;
    align-items: end;
}

.workflow-inline-comment {
    margin: 0;
}

@media (max-width: 980px) {
    .workflow-submit-card {
        grid-template-columns: 1fr;
        align-items: stretch;
    }
}

/* =======================================================================
   Frageneditor Workflow-Navigation v7.2.2
   Corporate-Design-Anpassung und zustands-/rechteabhängige Tabs
   ======================================================================= */
.question-page-path {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 11px;
    color: var(--admin-navbar);
}

.question-page-path a,
.question-page-current {
    margin: 0;
    color: #17658f;
    font-size: clamp(1.05rem, 2vw, 1.28rem);
    font-weight: 800;
    line-height: 1.2;
    text-decoration: none;
}

.question-page-path a:hover,
.question-page-path a:focus-visible {
    color: #b3262e;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.question-page-chevron {
    width: 9px;
    height: 9px;
    flex: 0 0 9px;
    border-top: 2px solid #6f94aa;
    border-right: 2px solid #6f94aa;
    transform: rotate(45deg);
}

.visual-editor-heading {
    align-items: center;
    margin-bottom: 14px;
}

.visual-editor-tabs {
    position: relative;
    z-index: 5;
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 0;
    margin-bottom: -14px;
    padding: 0 8px;
    overflow: visible;
    border: 1px solid #155f89;
    border-bottom: 0;
    border-radius: 8px 8px 0 0;
    background: linear-gradient(180deg, #1c719f 0%, #155d87 100%);
    box-shadow: 0 2px 8px rgba(19, 73, 104, .12);
}

.editor-tab-gate {
    position: relative;
    display: flex;
    align-items: stretch;
}

.visual-editor-tabs .editor-tab-gate > button {
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 17px;
    border: 0;
    border-right: 1px solid rgba(255, 255, 255, .15);
    border-radius: 0;
    color: #eef7fb;
    background: transparent;
    font: inherit;
    font-size: .88rem;
    font-weight: 800;
    cursor: pointer;
    transition: background .14s ease, color .14s ease, box-shadow .14s ease;
}

.visual-editor-tabs .editor-tab-gate > button:hover,
.visual-editor-tabs .editor-tab-gate > button:focus-visible {
    color: #fff;
    background: rgba(255, 255, 255, .12);
    outline: 0;
}

.visual-editor-tabs .editor-tab-gate > button.is-active {
    color: #164f73;
    background: #fff;
    box-shadow: inset 0 3px 0 #b3262e;
}

.editor-tab-gate.is-disabled > button,
.editor-tab-gate.is-disabled > button:hover,
.editor-tab-gate.is-disabled > button:focus {
    color: rgba(255, 255, 255, .72);
    background: rgba(13, 54, 78, .22);
    cursor: not-allowed;
}

.tab-gate-icon {
    position: relative;
    flex: 0 0 auto;
    display: inline-block;
}

.tab-gate-icon.is-permission {
    width: 16px;
    height: 14px;
    background: #f3c400;
    clip-path: polygon(50% 0, 100% 100%, 0 100%);
    filter: drop-shadow(0 0 1px #181818);
}

.tab-gate-icon.is-permission::after {
    content: "!";
    position: absolute;
    top: 2px;
    left: 0;
    width: 16px;
    color: #161616;
    font-size: 10px;
    font-weight: 950;
    line-height: 12px;
    text-align: center;
}

.tab-gate-icon.is-state {
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #c5232d;
    box-shadow: inset 0 0 0 1px #8d1720, 0 0 0 1px rgba(255, 255, 255, .3);
}

.tab-gate-icon.is-state::after {
    content: "";
    position: absolute;
    top: 6px;
    left: 3px;
    width: 9px;
    height: 3px;
    border-radius: 2px;
    background: #fff;
}

.editor-tab-gate.is-disabled::after {
    content: attr(data-tab-tooltip);
    position: absolute;
    z-index: 120;
    top: calc(100% + 9px);
    left: 50%;
    width: max-content;
    max-width: min(320px, 80vw);
    padding: 8px 10px;
    border-radius: 4px;
    color: #fff;
    background: #182934;
    box-shadow: 0 5px 16px rgba(17, 37, 49, .25);
    font-size: .77rem;
    font-weight: 650;
    line-height: 1.35;
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, -4px);
    transition: opacity .12s ease, transform .12s ease;
}

.editor-tab-gate.is-disabled:hover::after,
.editor-tab-gate.is-disabled:focus-visible::after,
.editor-tab-gate.is-disabled:focus-within::after {
    opacity: 1;
    transform: translate(-50%, 0);
}

.visual-tab-panel {
    padding: clamp(16px, 2.5vw, 24px);
    border: 1px solid #155f89;
    border-top: 0;
    border-radius: 0 0 8px 8px;
    background: #fff;
    box-shadow: 0 6px 20px rgba(20, 67, 94, .10);
}

.visual-tab-panel > .editor-panel,
.visual-tab-panel .workflow-content-basics {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
}

.workflow-content-basics {
    margin: 0 0 14px;
}

.visual-tab-panel .classification-basics {
    padding-top: 2px;
}

.visual-question-sheet {
    border-color: #b9ceda;
    box-shadow: 0 8px 26px rgba(22, 83, 116, .12);
}

.visual-question-help {
    border-left-color: #17658f;
    background: #f2f8fb;
}

.visual-add-button,
.primary-action {
    box-shadow: 0 2px 5px rgba(21, 93, 135, .12);
}

.visual-add-button:hover,
.visual-add-button:focus-visible,
.primary-action:hover,
.primary-action:focus-visible {
    box-shadow: 0 3px 8px rgba(21, 93, 135, .18);
}

@media (max-width: 760px) {
    .visual-editor-tabs {
        padding: 0;
    }

    .editor-tab-gate {
        flex: 1 1 50%;
    }

    .visual-editor-tabs .editor-tab-gate > button {
        width: 100%;
        justify-content: center;
        padding-right: 10px;
        padding-left: 10px;
    }
}

@media (max-width: 520px) {
    .question-page-path {
        flex-wrap: wrap;
    }

    .editor-tab-gate {
        flex-basis: 100%;
    }
}

/* =======================================================================
   Frageneditor Erstellung v7.2.3
   Gliederung des Erstellungsbereichs in ruhige, klar getrennte Cards
   ======================================================================= */
.creation-workspace {
    display: grid;
    gap: 18px;
}

.creation-card {
    overflow: hidden;
    border: 1px solid #c7d7e0;
    border-radius: 9px;
    background: #fff;
    box-shadow: 0 4px 14px rgba(22, 76, 106, .07);
}

.creation-card-heading {
    min-height: 58px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 13px 16px;
    border-bottom: 1px solid #d6e2e8;
    background: linear-gradient(180deg, #f8fbfd 0%, #f0f6f9 100%);
}

.creation-card-heading h3,
.creation-card-heading p {
    margin: 0;
}

.creation-card-heading h3 {
    color: #175f88;
    font-size: 1rem;
    font-weight: 850;
    line-height: 1.25;
}

.creation-card-heading p {
    margin-top: 3px;
    color: #687d89;
    font-size: .8rem;
    line-height: 1.4;
}

.creation-card-heading-compact {
    min-height: 52px;
}

.creation-card-body {
    padding: 16px;
}

.creation-card-basics .classification-basics {
    padding: 0;
}

.creation-card-editor {
    border-color: #afc8d6;
    box-shadow: 0 6px 20px rgba(22, 83, 116, .10);
}

.creation-card-editor .visual-editor-summarybar {
    margin: 0;
    border: 0;
    border-bottom: 1px solid #bcd0dc;
    border-radius: 0;
    background: linear-gradient(180deg, #edf6fa 0%, #e6f1f6 100%);
    box-shadow: none;
}

.creation-card-editor .visual-editor-summarybar > div:first-child strong {
    color: #155f89;
    font-size: 1rem;
}

.creation-card-editor .visual-question-sheet {
    margin: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.creation-card-sources.sources-editor {
    margin: 0;
    padding: 0;
    border: 1px solid #c7d7e0;
    border-radius: 9px;
    background: #fff;
}

.creation-card-sources .sources-editor-heading {
    margin: 0;
}

.creation-card-sources .question-sources-list {
    margin-top: 0;
}

.creation-card-comment .change-comment-field {
    margin: 0;
}

.creation-card-comment textarea {
    min-height: 92px;
}

.workflow-submit-card {
    border-color: #b9cfdb;
    background: linear-gradient(180deg, #f7fbfd 0%, #f1f7fa 100%);
    box-shadow: 0 4px 14px rgba(22, 76, 106, .06);
}

@media (max-width: 760px) {
    .creation-workspace {
        gap: 14px;
    }

    .creation-card-heading {
        align-items: stretch;
        flex-direction: column;
        gap: 10px;
    }

    .creation-card-heading .compact-action {
        align-self: flex-start;
    }

    .creation-card-body {
        padding: 14px;
    }
}

/* v7.2.4: contextual question title in the toolbar and quieter creation metadata. */
.toolbar-page-title {
    min-width: 0;
    overflow: hidden;
    color: #fff;
    font-size: 1.08rem;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.question-editor-actions-row {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 12px;
}

.creation-meta-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    align-self: end;
}

.creation-meta-facts span {
    display: grid;
    gap: 3px;
    min-width: 0;
    padding: 10px 12px;
    border: 1px solid #d7e0e5;
    border-radius: 6px;
    background: #f7fafc;
}

.creation-meta-facts small {
    color: #657986;
}

.creation-meta-facts strong {
    overflow: hidden;
    color: #244c65;
    font-size: .92rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 720px) {
    .toolbar-page-title {
        font-size: .98rem;
    }

    .creation-meta-facts {
        grid-template-columns: 1fr;
    }
}

/* =======================================================================
   Frageneditor Feinschliff v7.2.5
   Ruhigere Inhalte, Vorschau in der Tab-Leiste und klarere Eingabeelemente
   ======================================================================= */
.visual-editor-tabs .editor-tab-gate > button.is-active {
    box-shadow: inset 0 -3px 0 #b3262e;
}

.editor-tabs-toolbar {
    display: flex;
    align-items: center;
    margin-left: auto;
    padding: 6px 6px 6px 12px;
}

.tab-preview-action {
    min-height: 34px;
    padding: 6px 14px;
    border: 1px solid rgba(255, 255, 255, .72);
    border-radius: 5px;
    color: #fff;
    background: rgba(255, 255, 255, .09);
    font: inherit;
    font-size: .82rem;
    font-weight: 800;
    cursor: pointer;
    transition: background .14s ease, border-color .14s ease, box-shadow .14s ease;
}

.tab-preview-action:hover,
.tab-preview-action:focus-visible {
    border-color: #fff;
    background: rgba(255, 255, 255, .18);
    box-shadow: 0 2px 7px rgba(8, 38, 56, .18);
    outline: 0;
}

.creation-card {
    border-color: #9fb8c7;
    box-shadow: 0 4px 14px rgba(22, 76, 106, .09);
}

.creation-card-heading,
.creation-card-editor .visual-editor-summarybar {
    border-bottom-color: #adc3cf;
}

.creation-card-editor .visual-editor-summarybar {
    min-height: 48px;
    padding: 11px 16px;
}

.creation-card-editor .visual-editor-summarybar > strong {
    color: #155f89;
    font-size: 1rem;
}

.visual-tab-panel .field input[type="text"],
.visual-tab-panel .field input[type="number"],
.visual-tab-panel .field input[type="file"],
.visual-tab-panel .field textarea,
.visual-tab-panel .field select {
    border-color: #8fa8b7;
    box-shadow: inset 0 0 0 1px rgba(40, 91, 120, .035);
}

.visual-tab-panel .field input:hover,
.visual-tab-panel .field textarea:hover,
.visual-tab-panel .field select:hover {
    border-color: #6f93a8;
}

.visual-tab-panel .field input:focus,
.visual-tab-panel .field textarea:focus,
.visual-tab-panel .field select:focus {
    border-color: #17658f;
    box-shadow: 0 0 0 3px rgba(23, 101, 143, .13);
}

.visual-tab-panel .input-suffix > span {
    border-color: #8fa8b7;
    background: #edf3f6;
}

.visual-text-row textarea,
.visual-optional-prompt {
    border-color: #a5bac6;
    background: #fff;
    box-shadow: inset 0 0 0 1px rgba(40, 91, 120, .025);
}

.visual-text-row textarea:hover,
.visual-optional-prompt:hover {
    border-color: #789bad;
}

.visual-text-row textarea:focus,
.visual-optional-prompt:focus {
    border-color: #17658f;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(23, 101, 143, .11);
}

.visual-editor-block:not(.is-task) {
    border-color: #c0d1da;
    background: #fbfdfe;
}

.visual-editor-block:not(.is-task):hover,
.visual-editor-block:not(.is-task):focus-within {
    border-color: #8fabb9;
    box-shadow: 0 3px 11px rgba(34, 76, 99, .09);
}

.visual-block-actions button,
.visual-image-toolbar button,
.visual-inline-controls button,
.visual-row-remove,
.visual-menu-close {
    border-color: #9fb5c2;
}

.question-source-card {
    border-color: #a5bdca;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(24, 73, 99, .05);
}

.source-empty-hint {
    border-color: #9fb6c3;
    border-radius: 7px;
    background: #f8fbfc;
}

.visual-question-meta-line {
    display: flex;
    justify-content: flex-end;
    align-items: baseline;
    gap: 7px;
    margin-top: 16px;
    padding-top: 10px;
    border-top: 1px solid #d0dde4;
    color: #697e8a;
    font-size: .79rem;
}

.visual-question-meta-line strong {
    color: #355f77;
    font-size: .88rem;
}

@media (max-width: 760px) {
    .editor-tabs-toolbar {
        flex: 1 1 100%;
        justify-content: flex-end;
        padding: 6px 8px;
        border-top: 1px solid rgba(255, 255, 255, .15);
    }
}


/* =======================================================================
   Frageneditor Feinschliff v7.2.6
   Einheitliche Bereichsköpfe und ruhigere Metadaten bei Neuerstellung
   ======================================================================= */
.creation-card-heading,
.creation-card-editor .visual-editor-summarybar {
    min-height: 48px;
    padding: 11px 16px;
    border-bottom: 1px solid #9eb9c8;
    background: linear-gradient(180deg, #e8f3f8 0%, #dcecf4 100%);
}

.creation-card-heading h3,
.creation-card-editor .visual-editor-summarybar > strong {
    color: #155f89;
    font-size: 1rem;
    font-weight: 850;
}

.creation-card-heading p {
    color: #587381;
}

/* =======================================================================
   Frageneditor / Fragenliste v7.2.7
   Kompaktere Metadaten, sichtbare Vorschau und administrativer Test-Reset
   ======================================================================= */
.tab-preview-action.secondary-action {
    min-height: 40px;
    padding: 9px 14px;
    border: 1px solid #aebec8;
    border-radius: 4px;
    color: #234f6c;
    background: #fff;
    box-shadow: none;
    font-size: .82rem;
    font-weight: 700;
}

.tab-preview-action.secondary-action:hover,
.tab-preview-action.secondary-action:focus-visible {
    border-color: #8ea7b6;
    color: #173f5a;
    background: #eaf2f7;
    box-shadow: 0 2px 7px rgba(8, 38, 56, .12);
}

.creation-metadata-compact {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 16px 28px;
}

.creation-time-field {
    flex: 0 0 auto;
    width: auto;
    min-width: 0;
}

.creation-time-input {
    width: 132px;
}

.creation-time-input input {
    width: 76px;
    min-width: 0;
    text-align: right;
}

.creation-time-input > span {
    min-width: 48px;
    justify-content: center;
}

.creation-meta-value {
    min-width: 120px;
    min-height: 61px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    padding: 8px 0;
}

.creation-meta-value small {
    color: #667f8d;
    font-size: .72rem;
    font-weight: 700;
}

.creation-meta-value strong {
    color: #234f6c;
    font-size: .93rem;
    font-weight: 800;
}

.creation-change-comment {
    display: block;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #d8e3e9;
}

.visual-save-status.is-new {
    color: #687d89;
}

.visual-save-status.is-new .save-status-dot {
    background: #9cafba;
}

.question-reset-control {
    position: relative;
}

.question-reset-control > summary {
    list-style: none;
}

.question-reset-control > summary::-webkit-details-marker {
    display: none;
}

.danger-outline-action,
.danger-action {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 14px;
    border-radius: 4px;
    font: inherit;
    font-weight: 750;
    cursor: pointer;
}

.danger-outline-action {
    border: 1px solid #c86a70;
    color: #8e252c;
    background: #fff;
}

.danger-outline-action:hover,
.danger-outline-action:focus-visible,
.question-reset-control[open] > .danger-outline-action {
    border-color: #a92c35;
    background: #fff1f2;
    outline: 0;
}

.danger-action {
    border: 1px solid #9f2630;
    color: #fff;
    background: #a92c35;
}

.danger-action:hover,
.danger-action:focus-visible {
    background: #8f2028;
    outline: 0;
}

.question-reset-panel {
    position: absolute;
    z-index: 70;
    top: calc(100% + 8px);
    right: 0;
    width: min(470px, calc(100vw - 32px));
    padding: 16px;
    border: 1px solid #d5a1a5;
    border-radius: 7px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(56, 24, 27, .18);
}

.question-reset-panel > strong {
    display: block;
    color: #812129;
    font-size: .95rem;
}

.question-reset-panel > p {
    margin: 7px 0 14px;
    color: #5e6870;
    font-size: .82rem;
    line-height: 1.5;
}

.question-reset-panel form {
    display: grid;
    gap: 12px;
}

.question-reset-panel .field input {
    border-color: #c58e93;
}

@media (max-width: 760px) {
    .creation-metadata-compact {
        gap: 12px 20px;
    }

    .question-reset-panel {
        position: fixed;
        top: 84px;
        right: 16px;
        left: 16px;
        width: auto;
    }
}

/* =======================================================================
   Workflow-Trennung v7.3.0
   Persönliche Entwürfe, separate Einordnung/Fachprüfung und Schnellfilter
   ======================================================================= */
.question-workflow-strip {
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

.draft-submit-card {
    display: grid;
    grid-template-columns: minmax(220px, .9fr) minmax(260px, 1.1fr);
    align-items: start;
    gap: 14px 20px;
    margin-top: 16px;
    border-color: #9fbfce;
    background: linear-gradient(180deg, #f7fbfd 0%, #eef6fa 100%);
}

.draft-submit-card .workflow-action-row {
    grid-column: 1 / -1;
    margin-top: 0;
    padding-top: 13px;
    border-top: 1px solid #cbdde5;
}

.compact-status-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.question-quick-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 12px;
}

.question-quick-filter {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 6px 12px;
    border: 1px solid #9eb8c7;
    border-radius: 6px;
    color: #1b5d82;
    background: #fff;
    font-size: .84rem;
    font-weight: 800;
    text-decoration: none;
    transition: border-color .14s ease, background .14s ease, box-shadow .14s ease;
}

.question-quick-filter:hover,
.question-quick-filter:focus-visible {
    border-color: #397fa5;
    background: #f1f7fa;
    box-shadow: 0 2px 7px rgba(22, 76, 106, .10);
    outline: 0;
}

.question-quick-filter.is-active {
    border-color: #155f89;
    color: #fff;
    background: #155f89;
}

@media (max-width: 1180px) {
    .question-workflow-strip {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .question-workflow-strip,
    .compact-status-grid,
    .draft-submit-card {
        grid-template-columns: 1fr;
    }

    .draft-submit-card .workflow-action-row {
        grid-column: auto;
    }
}

/* =======================================================================
   Klassifikation v7.4.2
   Baureihenkunde plus TfV-Anlagen als erste Auswahl; alle Zuordnungen gleichwertig
   ======================================================================= */
.classification-step-card {
    border: 1px solid #aebfca;
    border-radius: 10px;
    padding: 18px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(20, 63, 89, .06);
}

.classification-step-card + .classification-step-card,
.classification-secondary-axes {
    margin-top: 18px;
    grid-template-columns: minmax(0, 1fr);
}

.tfv-root-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-top: 14px;
}

.tfv-root-choice {
    position: relative;
    display: block;
    cursor: pointer;
}

.tfv-root-choice input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.tfv-root-choice-body {
    position: relative;
    min-height: 76px;
    display: flex;
    align-items: center;
    padding: 14px 48px 14px 38px;
    border: 2px solid #b9c9d2;
    border-radius: 8px;
    background: #f8fbfc;
    transition: border-color .14s ease, background .14s ease, box-shadow .14s ease, transform .14s ease;
}

.tfv-root-choice-body strong {
    color: #174f70;
    font-size: .96rem;
    line-height: 1.35;
}

.tfv-root-help {
    position: absolute;
    top: 50%;
    right: 13px;
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    transform: translateY(-50%);
    border: 1px solid #8fa9b8;
    border-radius: 50%;
    color: #174f70;
    background: #fff;
    font-size: .78rem;
    font-weight: 800;
    font-style: normal;
    line-height: 1;
    cursor: help;
    z-index: 3;
}

.tfv-root-help::after {
    content: attr(data-tooltip);
    position: absolute;
    right: -7px;
    bottom: calc(100% + 10px);
    width: min(300px, 70vw);
    padding: 9px 11px;
    border-radius: 6px;
    color: #fff;
    background: #183746;
    box-shadow: 0 5px 16px rgba(12, 37, 51, .20);
    font-size: .78rem;
    font-weight: 500;
    line-height: 1.4;
    text-align: left;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(4px);
    transition: opacity .12s ease, transform .12s ease, visibility .12s ease;
    z-index: 20;
}

.tfv-root-help::before {
    content: '';
    position: absolute;
    right: 5px;
    bottom: calc(100% + 4px);
    border: 6px solid transparent;
    border-top-color: #183746;
    opacity: 0;
    visibility: hidden;
    transition: opacity .12s ease, visibility .12s ease;
    z-index: 21;
}

.tfv-root-help:hover::after,
.tfv-root-help:focus-visible::after,
.tfv-root-help:hover::before,
.tfv-root-help:focus-visible::before {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.tfv-root-help:focus-visible {
    outline: 2px solid #155f89;
    outline-offset: 2px;
}

.tfv-root-choice:hover .tfv-root-choice-body,
.tfv-root-choice input:focus-visible + .tfv-root-choice-body {
    border-color: #4a86a7;
    background: #f1f7fa;
    box-shadow: 0 3px 10px rgba(22, 79, 112, .10);
}

.tfv-root-choice input:checked + .tfv-root-choice-body {
    border-color: #155f89;
    background: #eaf4f9;
    box-shadow: inset 0 0 0 1px rgba(21, 95, 137, .18), 0 3px 10px rgba(22, 79, 112, .09);
}

.tfv-root-choice input:checked + .tfv-root-choice-body::before {
    content: '✓';
    position: absolute;
    top: 7px;
    left: 7px;
    width: 20px;
    height: 20px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    background: #155f89;
    font-size: .78rem;
    font-weight: 900;
}

.workflow-fieldset:disabled .tfv-root-choice {
    cursor: default;
}

.workflow-fieldset:disabled .tfv-root-choice-body {
    opacity: .72;
}

.classification-branch-list {
    display: grid;
    gap: 14px;
    margin-top: 14px;
}

.classification-branch {
    border: 1px solid #c1ced6;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.classification-branch-heading {
    display: flex;
    align-items: baseline;
    gap: 10px;
    padding: 10px 12px;
    border-bottom: 1px solid #c8d5dc;
    background: #edf4f7;
}

.classification-branch-heading strong {
    color: #174f70;
    font-size: .9rem;
}

.classification-branch-heading span {
    color: #4d6675;
    font-size: .82rem;
}

.classification-branch select {
    width: 100%;
    min-height: 230px;
    border: 0;
    border-radius: 0;
    padding: 8px;
    color: #283b47;
    background: #fff;
    font: inherit;
}

.classification-branch select:focus-visible {
    outline: 2px solid rgba(21, 95, 137, .28);
    outline-offset: -2px;
}

.classification-branch-empty {
    margin-top: 14px;
    padding: 13px 14px;
    border: 1px dashed #aabcc7;
    border-radius: 7px;
    color: #607582;
    background: #f8fbfc;
    font-size: .86rem;
}

.classification-secondary-axes {
    margin-top: 18px;
    grid-template-columns: minmax(0, 1fr);
}

@media (max-width: 1100px) {
    .tfv-root-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 700px) {
    .tfv-root-grid {
        grid-template-columns: 1fr;
    }

}

/* =======================================================================
   Klassifikation v7.4.3
   Zweispaltiger Browser: Bereichsnavigation + Knotenliste, Auswahl separat sichtbar
   ======================================================================= */
.classification-workspace-card {
    padding: 0;
    overflow: visible;
}

.classification-workspace-heading {
    padding: 16px 18px 0;
}

.classification-selected-summary {
    margin: 14px 18px 0;
    padding: 12px 14px;
    border: 1px solid #b7c8d2;
    border-radius: 8px;
    background: #f7fafc;
}

.classification-selected-summary-heading {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    color: #174f70;
}

.classification-selected-summary-heading strong {
    font-size: .9rem;
}

.classification-selected-summary-heading > span {
    min-width: 22px;
    height: 22px;
    display: inline-grid;
    place-items: center;
    padding: 0 6px;
    border-radius: 999px;
    color: #fff;
    background: #155f89;
    font-size: .72rem;
    font-weight: 800;
}

.classification-selected-empty {
    color: #647985;
    font-size: .84rem;
}

.classification-selected-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.classification-selected-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    max-width: 100%;
    padding: 6px 8px 6px 10px;
    border: 1px solid #8eb0c2;
    border-radius: 999px;
    color: #174f70;
    background: #fff;
    font: inherit;
    font-size: .79rem;
    text-align: left;
    cursor: pointer;
}

.classification-selected-chip:hover,
.classification-selected-chip:focus-visible {
    border-color: #b72b32;
    color: #842229;
    background: #fff8f8;
    outline: none;
}

.classification-selected-chip > span:first-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.classification-selected-chip-remove {
    flex: 0 0 auto;
    color: #b72b32;
    font-size: 1rem;
    font-weight: 900;
    line-height: 1;
}

.classification-workspace-grid {
    display: grid;
    grid-template-columns: minmax(210px, 27%) minmax(0, 1fr);
    gap: 0;
    margin-top: 14px;
    border-top: 1px solid #c3d0d8;
    min-height: 360px;
}

.classification-root-nav {
    padding: 12px;
    border-right: 1px solid #c3d0d8;
    background: #f3f7f9;
}

.classification-root-nav-item {
    position: relative;
    min-height: 58px;
    display: flex;
    align-items: stretch;
    margin-bottom: 8px;
    border: 1px solid #b8c8d1;
    border-radius: 8px;
    background: #fff;
    transition: border-color .12s ease, background .12s ease, box-shadow .12s ease;
}

.classification-root-nav-item:last-child {
    margin-bottom: 0;
}

.classification-root-nav-item.is-active {
    border-color: #155f89;
    background: #eaf4f9;
    box-shadow: inset 4px 0 0 #155f89;
}

.classification-root-nav-item.has-selection:not(.is-active) {
    border-color: #83aabd;
    background: #f8fcfe;
}

.classification-root-nav-button {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 42px 10px 12px;
    border: 0;
    border-radius: 8px;
    color: inherit;
    background: transparent;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.classification-root-nav-button:focus-visible {
    outline: 2px solid #155f89;
    outline-offset: 2px;
}

.classification-root-nav-label {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.classification-root-nav-label strong {
    color: #174f70;
    font-size: .9rem;
    line-height: 1.15;
}

.classification-root-nav-label > span {
    color: #344f5e;
    font-size: .78rem;
    line-height: 1.2;
}

.classification-root-count {
    flex: 0 0 auto;
    min-width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    padding: 0 6px;
    border-radius: 999px;
    color: #7a8e99;
    background: #edf2f4;
    font-size: .72rem;
    font-weight: 800;
}

.classification-root-count.has-selection {
    color: #fff;
    background: #155f89;
}

.classification-root-help {
    top: 50%;
    right: 9px;
    width: 22px;
    height: 22px;
}

.classification-node-browser {
    min-width: 0;
    background: #fff;
}

.classification-node-panel {
    height: 100%;
}

.classification-node-panel-heading {
    min-height: 58px;
    display: flex;
    align-items: center;
    padding: 10px 14px;
    border-bottom: 1px solid #c7d4dc;
    background: #edf4f7;
}

.classification-node-panel-heading > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.classification-node-panel-heading strong {
    color: #174f70;
    font-size: .92rem;
}

.classification-node-panel-heading span {
    color: #647985;
    font-size: .78rem;
}

.classification-node-list {
    max-height: 430px;
    overflow: auto;
    padding: 8px;
}

.classification-node-choice {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 9px;
    margin-left: calc(var(--classification-depth, 0) * 18px);
    padding: 8px 10px;
    border: 1px solid transparent;
    border-radius: 6px;
    cursor: pointer;
    transition: border-color .12s ease, background .12s ease;
}

.classification-node-choice:hover {
    border-color: #c1d1da;
    background: #f7fafc;
}

.classification-node-choice:has(input:checked) {
    border-color: #83adc2;
    background: #eaf4f9;
}

.classification-node-choice input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.classification-node-choice:focus-within {
    outline: 2px solid rgba(21, 95, 137, .28);
    outline-offset: 1px;
}

.classification-node-check {
    flex: 0 0 18px;
    width: 18px;
    height: 18px;
    display: grid;
    place-items: center;
    margin-top: 1px;
    border: 2px solid #8da4b1;
    border-radius: 4px;
    background: #fff;
}

.classification-node-choice input:checked + .classification-node-check {
    border-color: #155f89;
    background: #155f89;
}

.classification-node-choice input:checked + .classification-node-check::after {
    content: '✓';
    color: #fff;
    font-size: .72rem;
    font-weight: 900;
    line-height: 1;
}

.classification-node-text {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.classification-node-text strong {
    color: #174f70;
    font-size: .79rem;
    line-height: 1.2;
}

.classification-node-text > span {
    color: #314b59;
    font-size: .84rem;
    line-height: 1.3;
}

.workflow-fieldset:disabled .classification-root-nav-button,
.workflow-fieldset:disabled .classification-node-choice {
    cursor: default;
}

@media (max-width: 820px) {
    .classification-workspace-grid {
        grid-template-columns: 1fr;
    }

    .classification-root-nav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
        border-right: 0;
        border-bottom: 1px solid #c3d0d8;
    }

    .classification-root-nav-item {
        margin-bottom: 0;
    }

    .classification-root-nav-item.is-active {
        box-shadow: inset 0 -4px 0 #155f89;
    }
}

@media (max-width: 560px) {
    .classification-root-nav {
        grid-template-columns: 1fr;
    }

    .classification-selected-summary,
    .classification-workspace-heading {
        margin-left: 12px;
        margin-right: 12px;
    }

    .classification-workspace-heading {
        padding-left: 0;
        padding-right: 0;
    }
}

/* =======================================================================
   Klassifikation / Workflow v7.4.4
   Kompakte Bereichsnavigation, Zuordnungen unterhalb und Status direkt in Tabs
   ======================================================================= */
.toolbar-question-path {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    overflow: hidden;
}

.toolbar-question-chevron {
    width: 8px;
    height: 8px;
    flex: 0 0 8px;
    border-top: 2px solid rgba(255, 255, 255, .62);
    border-right: 2px solid rgba(255, 255, 255, .62);
    transform: rotate(45deg);
}

.toolbar-page-section {
    min-width: 0;
    overflow: hidden;
    color: rgba(255, 255, 255, .88);
    font-size: .98rem;
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tab-status-icon {
    position: relative;
    flex: 0 0 16px;
    width: 16px;
    height: 16px;
    display: inline-block;
}

.tab-status-icon.is-success {
    border-radius: 50%;
    background: #2f9d59;
    box-shadow: inset 0 0 0 1px #237d46, 0 0 0 1px rgba(255, 255, 255, .25);
}

.tab-status-icon.is-success::after {
    content: '';
    position: absolute;
    left: 4px;
    top: 3px;
    width: 7px;
    height: 4px;
    border-left: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(-45deg);
}

.tab-status-icon.is-pending {
    border: 2px solid #f1bd36;
    border-radius: 50%;
    background: #fff7dc;
    box-sizing: border-box;
}

.tab-status-icon.is-pending::before,
.tab-status-icon.is-pending::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 3px;
    width: 2px;
    border-radius: 2px;
    background: #805e00;
    transform-origin: 1px 5px;
}

.tab-status-icon.is-pending::before {
    height: 5px;
}

.tab-status-icon.is-pending::after {
    height: 4px;
    transform: rotate(125deg);
}

.tab-status-icon.is-locked {
    width: 15px;
    height: 12px;
    margin-top: 3px;
    border-radius: 2px;
    background: #dce7ed;
    box-shadow: inset 0 0 0 1px #6f8794;
}

.tab-status-icon.is-locked::before {
    content: '';
    position: absolute;
    left: 3px;
    top: -6px;
    width: 9px;
    height: 8px;
    border: 2px solid #6f8794;
    border-bottom: 0;
    border-radius: 7px 7px 0 0;
    box-sizing: border-box;
}

.tab-status-icon.is-attention {
    border-radius: 50%;
    background: #c53a43;
    box-shadow: inset 0 0 0 1px #94242b;
}

.tab-status-icon.is-attention::after {
    content: '!';
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 11px;
    font-weight: 900;
    line-height: 1;
}

.visual-editor-tabs .editor-tab-gate > button.is-active .tab-status-icon.is-pending {
    background: #fff7dc;
}

.visual-editor-tabs .editor-tab-gate > button.is-active .tab-status-icon.is-locked {
    background: #dce7ed;
}

.classification-workspace-grid {
    margin-top: 0;
    border-top: 0;
}

.classification-root-nav-item {
    height: 68px;
    min-height: 68px;
}

.classification-root-nav-button {
    min-height: 66px;
}

.classification-root-nav-label {
    justify-content: center;
    gap: 4px;
}

.classification-root-nav-label strong {
    font-size: .92rem;
}

.classification-root-nav-label > span {
    color: #526b79;
    font-size: .76rem;
    line-height: 1.15;
}

.classification-node-panel {
    min-height: 100%;
}

.classification-node-list {
    max-height: 430px;
    padding-top: 10px;
}

.classification-selected-summary {
    margin: 14px 14px 14px;
}

@media (max-width: 760px) {
    .toolbar-question-path {
        gap: 8px;
    }

    .toolbar-page-section {
        font-size: .9rem;
    }
}
