/* Gemeinsame Gestaltung für IDE, Konto- und Verwaltungsseiten.
   Material-orientierte Flächen, Textreiter und Zustände mit TakeOffs blauer Palette.
   Schriftarten werden lokal verwendet; es gibt keine externen Font-Aufrufe. */
:root {
    --font-ui: "Segoe UI", Arial, sans-serif;
    --text: #27333e;
    --muted: #53616e;
    --primary: #0073bf;
    --primary-dark: #004778;
    --accent: var(--primary);
    --surface: #f4f7fa;
    --surface-card: #ffffff;
    --surface-container: #e8eff6;
    --selection: #e0e8ef;
    --border: #cbd7e1;
    --control-border: #657d93;
    --coral: #c4473a;
    --error: #a43131;
    --radius-control: 8px;
    --radius-panel: 16px;
    --radius-action: 24px;
    --shadow-menu: 0 8px 24px #17354e26;
    color-scheme: light;
    color: var(--text);
    background: var(--surface);
    font: 16px/1.5 var(--font-ui);
}

/* Bedienelemente erben nicht die kräftige Schrift ihrer umgebenden Beschriftung. */
button, input, select, textarea {
    font-family: var(--font-ui);
}
input, select, textarea {
    font-weight: 400;
}
button {
    font-weight: 600;
}
a {
    color: var(--primary-dark);
}
:focus-visible {
    outline: 3px solid var(--primary);
    outline-offset: 3px;
}

/* Derselbe Kopf in der IDE und auf den Übersichtsseiten. */
.brandbar {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    gap: 16px;
    min-height: 56px;
    padding: 6px 18px;
    background: var(--primary);
    color: white;
}
.brandbar .brand {
    color: white;
    font-size: 20px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}
.brandbar .brand-mark {
    width: 24px;
    height: 24px;
    vertical-align: -0.2em;
}
.brandbar h1,
.brandbar-title {
    min-width: 0;
    flex: 1;
    margin: 0;
    padding-left: 16px;
    border-left: 1px solid #ffffff80;
    font-size: 16px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.workspace-account-actions {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    gap: 10px;
    margin-left: auto;
}
.workspace-account-actions form {
    margin: 0;
}
.brandbar .workspace-account-actions button,
.brandbar .workspace-account-button {
    margin: 0;
    min-height: 40px;
    padding: 6px 12px;
    border: 1px solid #ffffffb3;
    border-radius: var(--radius-action);
    background: transparent;
    color: white;
    font-size: 16px;
    font-weight: 600;
}
.brandbar .workspace-account-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 50%;
    text-decoration: none;
}
.brandbar .workspace-account-button .bi {
    font-size: 22px;
    margin: 0;
}
.brandbar .workspace-account-actions button:hover:not(:disabled),
.brandbar .workspace-account-button:hover {
    background: var(--primary-dark);
}
.brandbar :focus-visible {
    outline-color: white;
}

/* Das Schließen-X bleibt auf der dunklen Hover- und Fokusfläche gut sichtbar. */
.management-dialog header button:is(:hover, :focus-visible):not(:disabled),
.ide-modal-close:is(:hover, :focus-visible):not(:disabled) {
    background: var(--primary-dark);
    color: white;
}

/* Textreiter bleiben normale Seitenlinks, keine ARIA-Tabs mit versteckten Panels.
   Auf schmalen Geräten scrollt nur die Navigation; der aktive Bereich bleibt sichtbar. */
.section-navigation {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 0;
    margin: 0;
    padding: 0 max(16px, calc((100% - 1160px) / 2));
    background: var(--surface-card);
    border-bottom: 1px solid var(--border);
    scroll-padding-inline: 16px;
}
.section-navigation a {
    position: relative;
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    min-height: 56px;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    color: var(--muted);
    text-decoration: none;
}
.section-navigation a:hover {
    background: var(--selection);
}
.section-navigation a[aria-current="page"] {
    color: var(--primary);
}
.section-navigation a[aria-current="page"]::after {
    content: "";
    position: absolute;
    inset: auto 24px 0;
    height: 3px;
    border-radius: 3px 3px 0 0;
    background: currentColor;
}
.section-navigation a:focus-visible {
    outline-offset: -4px;
}
@media (max-width: 480px) {
    .brandbar {
        flex-wrap: wrap;
        gap: 6px;
        padding: 8px 12px;
    }
    .brandbar h1,
    .brandbar-title {
        order: 3;
        flex-basis: 100%;
        padding-left: 0;
        border: 0;
    }
    .section-navigation {
        padding-inline: 8px;
    }
    .section-navigation a {
        padding-inline: 18px;
    }
}
@media (forced-colors: active) {
    .section-navigation a[aria-current="page"]::after {
        background: Highlight;
    }
}
