/* ee-lang-switch.css -- the DE | EN switch (I18n::render_switch(), i18n P0; dropdown 06.11.2026).
   Loaded by I18n on every app page: portal header, and outside the portal the theme menu or a
   fixed corner (where GTranslate's switch was). The portal's glass look stays in ee-portal.css.
   Quiet on purpose (Till): the current language as small text with a chevron, no globe,
   no pill until hover, no wider than the header icons. The menu lists every enabled
   locale ("Deutsch  DE"), the current one checked. Behaviour in assets/js/ee-i18n.js. */
.ee-portal-lang {
    position: relative;
    display: inline-flex;
    flex: none;
    margin-right: 2px;
}
.ee-portal-lang-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 1px;
    min-width: 34px;
    height: 34px;
    padding: 0 3px 0 4px;
    box-sizing: border-box;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--dls-muted, #64748b);
    font-family: inherit;
    font-size: 11px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: .02em;
    cursor: pointer;
    transition: background .15s ease, color .15s ease;
}
.ee-portal-lang-chev {
    flex: none;
    width: 8px;
    height: 8px;
    opacity: .75;
    transition: transform .15s ease;
}
.ee-portal-lang.is-open .ee-portal-lang-chev { transform: rotate(180deg); }
.ee-portal-lang-btn:hover,
.ee-portal-lang.is-open .ee-portal-lang-btn {
    background: rgba(var(--ee-fg-rgb, 15, 23, 42), 0.06);
    color: var(--dls-ink, #0f172a);
}
.ee-portal-lang-btn:focus-visible {
    outline: 2px solid #0a84ff;
    outline-offset: 1px;
}
.ee-portal-lang[aria-busy="true"] .ee-portal-lang-btn { cursor: progress; opacity: .6; }

.ee-portal-lang-menu {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    z-index: 950;
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 148px;
    padding: 4px;
    box-sizing: border-box;
    border: 1px solid var(--dls-line, rgba(15, 23, 42, .1));
    border-radius: 12px;
    background: var(--dls-card, #fff);
    box-shadow: var(--dls-shadow, 0 12px 32px -8px rgba(15, 23, 42, .18));
}
.ee-portal-lang-menu[hidden] { display: none; }
.ee-portal-lang-opt {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 7px 10px 7px 8px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--dls-ink, #0f172a);
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.2;
    text-align: left;
    white-space: nowrap;
    cursor: pointer;
}
.ee-portal-lang-check {
    flex: none;
    width: 14px;
    height: 14px;
    visibility: hidden;
}
.ee-portal-lang-opt[aria-checked="true"] .ee-portal-lang-check { visibility: visible; }
.ee-portal-lang-opt[aria-checked="true"] { font-weight: 600; }
.ee-portal-lang-name { flex: 1 1 auto; }
.ee-portal-lang-sep { height: 1px; margin: 4px 8px; background: currentColor; opacity: .1; }
.ee-portal-lang-opt[data-ee-pref][aria-checked="true"] { font-weight: 500; }
.ee-portal-lang-code {
    flex: none;
    color: var(--dls-muted, #64748b);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .04em;
}
.ee-portal-lang-opt:hover,
.ee-portal-lang-opt:focus-visible {
    outline: none;
    background: rgba(var(--ee-fg-rgb, 15, 23, 42), 0.06);
}

/* Entry and login pages: the switch sits centred under the card at the bottom of the
   page, so the menu opens centred and upwards. */
.ee-portal-lang--entry { align-self: center; margin: 18px auto 0; }
.ee-portal-lang--entry .ee-portal-lang-menu { top: auto; bottom: calc(100% + 6px); right: auto; left: 50%; transform: translateX(-50%); }
.ee-portal-lang--entry.is-open .ee-portal-lang-chev { transform: none; }
.ee-portal-lang--entry .ee-portal-lang-chev { transform: rotate(180deg); }

/* App pages outside the portal: in the theme menu where GTranslate's item was ... */
.menu-item-ee-lang { position: relative; display: inline-flex; align-items: center; }
/* ... or, without that menu on the page, a small fixed switch; its menu opens upwards. */
.ee-portal-lang--float {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 9990;
    margin: 0;
    border-radius: 999px;
    background: var(--dls-card, #fff);
    box-shadow: 0 4px 14px -4px rgba(15, 23, 42, .25);
}
.ee-portal-lang--float .ee-portal-lang-menu { top: auto; bottom: calc(100% + 6px); }
.ee-portal-lang--float .ee-portal-lang-chev { transform: rotate(180deg); }
.ee-portal-lang--float.is-open .ee-portal-lang-chev { transform: none; }
