:root {
    --primary: #0f4c81;
    --primary-dark: #0b3a63;
    --primary-light: #eaf2f8;

    --background: #f3f6fb;
    --surface: #ffffff;
    --surface-alt: #f5f8fc;

    --text-primary: #1b2430;
    --text-secondary: #5b6675;
    --text-muted: #7f8a98;

    --border: #dbe3ec;
    --border-strong: #c6d1dd;

    --success: #2e7d32;
    --success-bg: #eaf7ed;

    --danger: #c62828;
    --danger-bg: #fdecec;

    --warning: #ef6c00;
    --warning-bg: #fff4e8;

    --shadow-sm: 0 2px 8px rgba(15, 36, 60, 0.06);
    --shadow-md: 0 8px 24px rgba(15, 36, 60, 0.08);
    --shadow-lg: 0 12px 34px rgba(15, 23, 42, 0.08);

    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 18px;
    --radius-xl: 20px;

    --transition: 0.18s ease;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 14px;
}

body {
    min-width: 320px;
    font-family: Tahoma, Verdana, "Segoe UI", Arial, sans-serif;
    font-size: 14px;
    line-height: 1.45;
    color: var(--text-primary);
    background: var(--background);
}

a,
a:visited,
a:hover,
a:active {
    text-decoration: none;
    color: inherit;
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    border: 0;
}

h1,
h2,
h3,
h4 {
    margin-top: 0;
    color: var(--text-primary);
    font-weight: 700;
    line-height: 1.25;
}

h1 {
    font-size: 24px;
    margin-bottom: 10px;
}

h2 {
    font-size: 19px;
    margin-bottom: 8px;
}

h3 {
    font-size: 16px;
    margin-bottom: 8px;
}

h4 {
    font-size: 14px;
    margin-bottom: 6px;
}

p {
    margin-top: 0;
    font-size: 14px;
    line-height: 1.5;
    color: var(--text-secondary);
}

img,
svg,
video {
    max-width: 100%;
}

/* ===== Einheitliche Form-Controls ===== */

input,
select,
textarea {
    width: 100%;
    min-height: 40px;
    padding: 10px 12px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: #ffffff;
    color: var(--text-primary);
    font-size: 14px;
    outline: none;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background-color 0.2s ease;
}

input[type="checkbox"],
input[type="radio"] {
    width: auto;
    min-height: 0;
    padding: 0;
    border-radius: initial;
}

textarea {
    min-height: 96px;
    resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(15, 76, 129, 0.10);
}

input[type="checkbox"]:focus,
input[type="radio"]:focus {
    box-shadow: none;
}

input:disabled,
select:disabled,
textarea:disabled {
    background: #f4f7fb;
    color: var(--text-muted);
    cursor: not-allowed;
    opacity: 1;
}

select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

/* ===== Shared UI ===== */

.meta-pill,
.badge {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 5px 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
}

.meta-pill {
    background: var(--surface-alt);
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.badge-active {
    background: var(--success-bg);
    color: var(--success);
}

.badge-disabled {
    background: #eef2f7;
    color: #5f6c80;
}

.btn {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 8px 14px;
    border-radius: 12px;
    border: 1px solid var(--primary);
    background: var(--primary);
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition:
        background var(--transition),
        border-color var(--transition),
        transform var(--transition),
        box-shadow var(--transition);
    box-shadow: 0 3px 10px rgba(15, 76, 129, 0.16);
}

.btn:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-primary {
    background: #ffffff;
    color: var(--primary-dark);
    border-color: #ffffff;
    box-shadow: none;
}

.btn-primary:hover {
    background: #eef3ff;
    border-color: #eef3ff;
    color: var(--primary-dark);
}

.btn-secondary {
    background: var(--primary);
    color: #ffffff;
    border-color: var(--primary);
}

.btn-secondary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
}

.btn-ghost {
    background: #ffffff;
    color: var(--text-primary);
    border-color: var(--border);
    box-shadow: none;
}

.btn-ghost:hover {
    background: var(--surface-alt);
    border-color: var(--border-strong);
}

.alert-box {
    padding: 12px 14px;
    margin-bottom: 14px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
}

.alert-success {
    background: var(--success-bg);
    color: var(--success);
    border: 1px solid #c9ebcf;
}

.alert-error {
    background: var(--danger-bg);
    color: var(--danger);
    border: 1px solid #fecaca;
}

.form-stack,
.admin-form-stack,
.AdminFormStack,
.LoginForm {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.form-actions,
.LoginFormActions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
}

.form-hint {
    font-size: 12px;
    line-height: 1.5;
    color: var(--text-muted);
}

/* ===== Legacy Public Content Helpers ===== */

.app-shell {
    min-height: 100vh;
}

.topbar {
    max-width: 1400px;
    margin: 18px auto;
    min-height: 64px;
    padding: 0 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    background: linear-gradient(90deg, var(--primary-dark) 0%, var(--primary) 100%);
    color: #ffffff;
    border-radius: 18px;
    box-shadow: 0 4px 18px rgba(8, 28, 48, 0.16);
}

.topbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-badge {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
}

.brand-title {
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.1;
}

.brand-subtitle {
    margin-top: 3px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.74);
}

.topbar-nav {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.nav-link {
    color: rgba(255, 255, 255, 0.94);
    padding: 9px 13px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    transition: background var(--transition), color var(--transition);
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
}

.page-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 18px 24px;
}

.hero-card,
.admin-hero,
.landing-hero-inner {
    background: linear-gradient(135deg, rgba(54, 92, 245, 0.98), rgba(94, 121, 250, 0.93));
    color: #ffffff;
    border-radius: 22px;
    padding: 24px;
    box-shadow: 0 18px 42px rgba(54, 92, 245, 0.22);
}

.hero-kicker,
.admin-kicker,
.landing-kicker {
    display: inline-block;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.hero-card h1,
.admin-hero h1,
.landing-hero h1 {
    margin: 12px 0 10px;
    color: #ffffff;
    font-size: 30px;
    line-height: 1.08;
}

.hero-card p,
.admin-hero p,
.landing-hero p {
    margin: 0;
    max-width: 760px;
    color: rgba(255, 255, 255, 0.92);
    font-size: 15px;
    line-height: 1.55;
}

.hero-actions,
.admin-hero-actions,
.landing-actions {
    margin-top: 18px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.inline-hint {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.88);
}

.section-header,
.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 14px;
    margin: 20px 0 12px;
}

.section-header h2,
.section-heading h2,
.landing-container h2 {
    margin: 0 0 4px 0;
    font-size: 20px;
    line-height: 1.2;
}

.section-header p,
.section-heading p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 14px;
}

.card-grid,
.landing-grid,
.stats-grid,
.PublicGrid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.card-grid-two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.card,
.feature-card,
.stat-card,
.landing-card,
.PublicCard {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: 16px;
}

.card h3,
.feature-card h3,
.landing-card h3,
.PublicCard h3 {
    margin: 0 0 8px;
    font-size: 17px;
    line-height: 1.25;
}

.card p,
.feature-card p,
.landing-card p,
.PublicCard p {
    margin: 0 0 12px;
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.5;
}

.card-head,
.feature-card-head {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 12px;
    margin-bottom: 10px;
}

.card-meta,
.feature-meta,
.admin-meta-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 10px;
}

.stat-label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-secondary);
    font-size: 13px;
}

.stat-value {
    display: block;
    font-size: 24px;
    line-height: 1.05;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-text {
    margin: 8px 0 0;
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.45;
}

/* ===== Logged-In Layout ===== */

.AppBodyLoggedIn {
    background: var(--background);
    color: var(--text-primary);
}

.AppHeader {
    position: sticky;
    top: 0;
    z-index: 1200;
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 0 24px;
    background: linear-gradient(90deg, #0f172a 0%, #111827 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    box-shadow: 0 4px 18px rgba(8, 28, 48, 0.18);
}

.AppHeaderLeft,
.AppHeaderRight {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.AppLogoLink {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.AppLogoText {
    color: #ffffff;
    font-size: 20px;
    font-weight: 700;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.AppHeaderIcon,
.AppSidebarIcon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    flex: 0 0 auto;
}

.AppHeaderIcon svg,
.AppSidebarIcon svg,
.AppLogoutButtonIcon svg {
    width: 18px;
    height: 18px;
    display: block;
    fill: currentColor;
}

.AppHeaderIcon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

.AppUserBox {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
    margin-left: 4px;
    min-width: 0;
}

.AppUserName {
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
    max-width: 220px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.AppUserRole {
    color: rgba(255, 255, 255, 0.72);
    font-size: 12px;
    line-height: 1.2;
    max-width: 220px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.AppLogoutForm {
    margin: 0;
}

.AppLogoutButton {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border: 0;
    border-radius: 12px;
    background: #dc2626;
    color: #ffffff;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: transform var(--transition), background var(--transition);
}

.AppLogoutButton:hover {
    background: #b42318;
    transform: translateY(-1px);
}

.AppLogoutButtonIcon {
    width: 16px;
    height: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: currentColor;
}

.AppShell {
    display: flex;
    min-height: calc(100vh - 72px);
}

.AppSidebar {
    width: 270px;
    min-width: 270px;
    background: linear-gradient(180deg, #0f172a 0%, #111827 100%);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    padding: 18px 14px;
    overflow-y: auto;
    position: sticky;
    top: 72px;
    height: calc(100vh - 72px);
}

.AppSidebarSection {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.AppSidebarSectionTitle {
    padding: 0 10px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.42);
}

.AppSidebarDivider {
    height: 1px;
    margin: 16px 4px;
    background: rgba(255, 255, 255, 0.08);
}

.AppSidebarNav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.AppSidebarLink {
    position: relative;
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 14px;
    background: transparent;
    color: rgba(255, 255, 255, 0.86);
    font-size: 14px;
    font-weight: 600;
    transition: background var(--transition), color var(--transition), box-shadow var(--transition);
}

.AppSidebarLink:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.AppSidebarLink.is-active {
    background: rgba(59, 130, 246, 0.22);
    color: #ffffff;
    box-shadow: inset 3px 0 0 #60a5fa;
}

.AppSidebarLabel {
    display: inline-block;
    line-height: 1.2;
    color: rgba(255, 255, 255, 0.86);
}

.AppMain {
    flex: 1;
    min-width: 0;
    padding: 24px;
}

.AppMainInner {
    width: 100%;
    max-width: 100%;
}

.AppContentCard {
    background: #ffffff;
    border-radius: 14px;
    padding: 18px;
    box-shadow: var(--shadow-lg);
    min-height: calc(100vh - 140px);
}

/* ===== Legacy Public/Auth Blocks ===== */

.PublicPage {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.PublicHero {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    color: #fff;
    border-radius: 18px;
    padding: 28px;
}

.PublicHeroInner h1 {
    margin: 0 0 10px 0;
    font-size: 28px;
}

.PublicHeroInner p {
    margin: 0;
    color: rgba(255, 255, 255, 0.85);
}

.PublicHeroActions {
    margin-top: 16px;
}

.AuthPage {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 70vh;
}

.AuthCard {
    width: 100%;
    max-width: 420px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 24px;
    box-shadow: var(--shadow-md);
}

.AuthHeader h1 {
    margin-bottom: 4px;
}

.AuthHeader p {
    margin-bottom: 16px;
    color: var(--text-secondary);
}

.login-wrapper {
    max-width: 620px;
    margin: 0 auto;
}

.login-card {
    padding: 18px;
}

.login-hint {
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: 12px;
    background: var(--surface-alt);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.55;
}

/* ===== Public Topbar ===== */

.PublicBody {
    background: #08111d;
}

.PublicTopbar {
    position: sticky;
    top: 0;
    z-index: 1200;
    width: 100%;
    background: rgba(7, 17, 29, 0.68);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.PublicTopbarInner {
    max-width: 1380px;
    margin: 0 auto;
    min-height: 72px;
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.PublicBrand {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    color: #ffffff;
}

.PublicBrandMark {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(255,255,255,0.22), rgba(255,255,255,0.08));
    border: 1px solid rgba(255,255,255,0.16);
    color: #ffffff;
    font-size: 18px;
    font-weight: 800;
    backdrop-filter: blur(8px);
}

.PublicBrandText {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.PublicBrandTitle {
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.1;
}

.PublicBrandSubtitle {
    color: rgba(255, 255, 255, 0.68);
    font-size: 12px;
    line-height: 1.1;
}

.PublicNav {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.PublicNavLink {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 14px;
    border-radius: 12px;
    color: rgba(255,255,255,0.88);
    font-size: 13px;
    font-weight: 700;
    transition: background var(--transition), color var(--transition), border-color var(--transition);
}

.PublicNavLink:hover {
    background: rgba(255,255,255,0.10);
    color: #ffffff;
}

.PublicNavLinkPrimary {
    background: rgba(255,255,255,0.14);
    border: 1px solid rgba(255,255,255,0.18);
    color: #ffffff;
}

.PublicNavLinkPrimary:hover {
    background: rgba(255,255,255,0.20);
}

/* ===== Landing ===== */

.LandingPage {
    position: relative;
    min-height: calc(100vh - 72px);
    overflow: hidden;
    background: #08111d;
}

.LandingVideo {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.LandingOverlay {
    position: fixed;
    inset: 0;
    z-index: 1;
    background:
        radial-gradient(circle at top left, rgba(26, 89, 163, 0.28), transparent 34%),
        linear-gradient(120deg, rgba(5, 12, 22, 0.88) 0%, rgba(7, 18, 32, 0.74) 45%, rgba(8, 28, 48, 0.68) 100%);
}

.LandingHero {
    position: relative;
    z-index: 2;
    min-height: calc(100vh - 72px);
    max-width: 1380px;
    margin: 0 auto;
    padding: 56px 32px 72px;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(420px, 0.9fr);
    gap: 40px;
    align-items: center;
}

.LandingLeft {
    display: flex;
    flex-direction: column;
    gap: 34px;
    color: #ffffff;
}

.LandingBrand {
    display: flex;
    align-items: center;
    gap: 16px;
}

.LandingBrandMark {
    width: 64px;
    height: 64px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 800;
    color: #ffffff;
    background: linear-gradient(135deg, rgba(255,255,255,0.22), rgba(255,255,255,0.08));
    border: 1px solid rgba(255,255,255,0.18);
    backdrop-filter: blur(10px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.22);
}

.LandingBrandTitle {
    font-size: 24px;
    font-weight: 700;
    line-height: 1.1;
    color: #ffffff;
}

.LandingBrandSub {
    font-size: 14px;
    color: rgba(255,255,255,0.72);
    margin-top: 4px;
}

.LandingCopy {
    max-width: 700px;
}

.LandingEyebrow {
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.14);
    color: rgba(255,255,255,0.84);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 18px;
}

.LandingCopy h1 {
    margin: 0 0 18px;
    font-size: 56px;
    line-height: 1.02;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: #ffffff;
    max-width: 820px;
}

.LandingCopy p {
    margin: 0;
    max-width: 640px;
    font-size: 18px;
    line-height: 1.7;
    color: rgba(255,255,255,0.8);
}

.LandingActions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 30px;
}

.LandingBtn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    padding: 0 22px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 700;
    transition: all 0.2s ease;
}

.LandingBtnPrimary {
    background: #ffffff;
    color: #0b1626;
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.18);
}

.LandingBtnPrimary:hover {
    transform: translateY(-1px);
    background: #f4f7fb;
    color: #0b1626;
}

.LandingBtnSecondary {
    background: rgba(255,255,255,0.08);
    color: #ffffff;
    border: 1px solid rgba(255,255,255,0.18);
    backdrop-filter: blur(8px);
}

.LandingBtnSecondary:hover {
    background: rgba(255,255,255,0.14);
    color: #ffffff;
}

.LandingStats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    max-width: 760px;
}

.LandingStat {
    padding: 18px 18px 16px;
    border-radius: 18px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.12);
    backdrop-filter: blur(12px);
}

.LandingStat strong {
    display: block;
    margin-bottom: 8px;
    font-size: 15px;
    color: #ffffff;
}

.LandingStat span {
    font-size: 13px;
    color: rgba(255,255,255,0.74);
}

.LandingRight {
    display: flex;
    justify-content: flex-end;
}

.LandingPanel {
    width: 100%;
    max-width: 520px;
    padding: 30px;
    border-radius: 28px;
    background: rgba(255,255,255,0.92);
    border: 1px solid rgba(255,255,255,0.55);
    box-shadow: 0 30px 70px rgba(4, 14, 28, 0.28);
    backdrop-filter: blur(16px);
}

.LandingPanelBadge {
    display: inline-block;
    padding: 7px 12px;
    margin-bottom: 16px;
    border-radius: 999px;
    background: #f6f9fc;
    color: #35577c;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.LandingPanelTop h2 {
    margin: 0 0 12px;
    font-size: 30px;
    line-height: 1.15;
    color: #0d1a2b;
}

.LandingPanelTop p {
    margin: 0 0 28px;
    color: #516172;
    line-height: 1.7;
    font-size: 15px;
}

.LandingFeatureList {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.LandingFeature {
    display: grid;
    grid-template-columns: 52px 1fr;
    gap: 16px;
    align-items: start;
    padding: 18px;
    border-radius: 18px;
    background: #f6f9fc;
    border: 1px solid #e2e8f0;
}

.LandingFeatureIcon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 800;
    color: #27496e;
    background: linear-gradient(135deg, #edf4fb, #dfeaf7);
}

.LandingFeature h3 {
    margin: 2px 0 8px;
    font-size: 16px;
    color: #102033;
}

.LandingFeature p {
    margin: 0;
    font-size: 14px;
    line-height: 1.65;
    color: #5d6c7c;
}

/* ===== Login ===== */

.LoginHero {
    position: relative;
    z-index: 2;
    min-height: calc(100vh - 72px);
    max-width: 1280px;
    margin: 0 auto;
    padding: 56px 32px 72px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(380px, 460px);
    gap: 40px;
    align-items: center;
}

.LoginHeroLeft {
    display: flex;
    flex-direction: column;
    gap: 28px;
    color: #ffffff;
}

.LoginCopy {
    max-width: 620px;
}

.LoginCopy h1 {
    margin: 0 0 16px;
    font-size: 48px;
    line-height: 1.04;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: #ffffff;
}

.LoginCopy p {
    margin: 0;
    max-width: 560px;
    font-size: 18px;
    line-height: 1.7;
    color: rgba(255,255,255,0.82);
}

.LoginHeroRight {
    display: flex;
    justify-content: flex-end;
}

.LoginPanel {
    width: 100%;
    max-width: 460px;
    padding: 30px;
    border-radius: 28px;
    background: rgba(255,255,255,0.94);
    border: 1px solid rgba(255,255,255,0.55);
    box-shadow: 0 30px 70px rgba(4, 14, 28, 0.28);
    backdrop-filter: blur(16px);
}

.LoginPanelTop h2 {
    margin: 0 0 10px;
    font-size: 28px;
    line-height: 1.15;
    color: #0d1a2b;
}

.LoginPanelTop p {
    margin: 0 0 20px;
    color: #516172;
    line-height: 1.6;
    font-size: 15px;
}

.LoginPanelFooter {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #e5edf5;
    color: #667587;
    font-size: 13px;
    line-height: 1.5;
}

.LoginPanel .LandingBtnSecondary {
    background: #ffffff;
    color: #102033;
    border: 1px solid #dbe3ec;
}

.LoginPanel .LandingBtnSecondary:hover {
    background: #f5f8fc;
    color: #102033;
    border-color: #c6d1dd;
}

/* ===== User Menu / Profile ===== */

.UserMenuRoot {
    position: relative;
}

.UserMenuToggle {
    background: transparent;
    border: 0;
    padding: 0;
    cursor: pointer;
}

.UserMenuBackdrop {
    position: fixed;
    inset: 0;
    z-index: 90;
}

.UserMenuPanel {
    position: absolute;
    top: 56px;
    right: 0;
    z-index: 100;
    min-width: 220px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: #ffffff;
    box-shadow: var(--shadow-lg);
}

.UserMenuHeader {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding-bottom: 10px;
    margin-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.UserMenuHeader strong {
    color: var(--text-primary);
    font-size: 14px;
}

.UserMenuHeader span {
    color: var(--text-secondary);
    font-size: 12px;
}

.UserMenuBody {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.UserMenuItem {
    width: 100%;
    display: block;
    padding: 9px 10px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--text-primary);
    text-align: left;
    text-decoration: none;
    font: inherit;
    font-size: 14px;
    cursor: pointer;
}

.UserMenuItem:hover {
    background: rgba(15, 23, 42, 0.06);
}

.UserMenuItemDanger {
    color: var(--danger);
}

.ProfilePage {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.ProfileCheckbox {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    cursor: pointer;
}

.ProfileCheckbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin: 0;
    cursor: pointer;
}

.ProfileCheckbox span {
    color: var(--text-primary);
}

/* ===== Responsive ===== */

@media (max-width: 1200px) {
    .AppSidebar {
        width: 240px;
        min-width: 240px;
        position: static;
        height: auto;
    }
}

@media (max-width: 1100px) {
    .LandingHero,
    .LoginHero {
        grid-template-columns: 1fr;
        gap: 28px;
        padding-top: 36px;
    }

    .LandingRight,
    .LoginHeroRight {
        justify-content: flex-start;
    }

    .LandingPanel,
    .LoginPanel {
        max-width: 100%;
    }

    .LandingCopy h1 {
        font-size: 44px;
    }

    .LoginCopy h1 {
        font-size: 40px;
    }
}

@media (max-width: 980px) {
    .topbar {
        flex-direction: column;
        align-items: stretch;
        padding: 14px 18px;
    }

    .card-grid,
    .card-grid-two,
    .landing-grid,
    .stats-grid,
    .PublicGrid {
        grid-template-columns: 1fr;
    }

    .hero-actions,
    .admin-hero-actions,
    .landing-actions,
    .form-actions,
    .LoginFormActions {
        flex-direction: column;
        align-items: stretch;
    }

    .form-actions .btn,
    .LoginFormActions .btn {
        width: 100%;
    }

    .hero-card h1,
    .admin-hero h1,
    .landing-hero h1 {
        font-size: 26px;
    }

    .AppHeader {
        padding: 0 16px;
    }

    .AppLogoText,
    .AppUserRole,
    .AppLogoutButton span {
        display: none;
    }

    .AppUserName {
        max-width: 150px;
    }

    .AppSidebar {
        width: 84px;
        min-width: 84px;
        padding: 16px 10px;
    }

    .AppSidebarSectionTitle,
    .AppSidebarDivider {
        display: none;
    }

    .AppSidebarLink {
        justify-content: center;
        padding: 14px 10px;
    }

    .AppSidebarLabel {
        display: none;
    }

    .AppMain {
        padding: 18px;
    }

    .AppContentCard {
        padding: 18px;
    }
}

@media (max-width: 760px) {
    .LandingStats,
    .PublicGrid {
        grid-template-columns: 1fr;
    }

    .AppHeader {
        min-height: 64px;
        padding: 0 12px;
    }

    .AppHeaderLeft,
    .AppHeaderRight {
        gap: 10px;
    }

    .AppHeaderIcon {
        width: 38px;
        height: 38px;
    }

    .AppUserBox {
        align-items: flex-start;
    }

    .AppUserName {
        max-width: 120px;
    }

    .AppShell {
        flex-direction: column;
        min-height: calc(100vh - 64px);
    }

    .AppSidebar {
        position: static;
        width: 100%;
        min-width: 100%;
        height: auto;
        border-right: 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
        padding: 12px;
    }

    .AppSidebarSectionTitle,
    .AppSidebarDivider {
        display: block;
    }

    .AppSidebarNav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
    }

    .AppSidebarLink {
        justify-content: flex-start;
        padding: 12px;
    }

    .AppSidebarLabel {
        display: inline;
    }

    .AppMain {
        padding: 14px;
    }

    .AppContentCard {
        min-height: auto;
        padding: 16px;
        border-radius: 16px;
    }

    .LandingHero,
    .LoginHero {
        padding: 24px 16px 40px;
    }

    .LandingCopy h1 {
        font-size: 34px;
    }

    .LandingCopy p,
    .LoginCopy p {
        font-size: 16px;
    }

    .LoginCopy h1 {
        font-size: 32px;
    }

    .LandingPanel,
    .LoginPanel {
        padding: 22px;
        border-radius: 22px;
    }

    .LandingFeature {
        grid-template-columns: 44px 1fr;
        padding: 16px;
    }

    .LandingFeatureIcon {
        width: 44px;
        height: 44px;
        border-radius: 14px;
    }

    .PublicTopbarInner {
        min-height: auto;
        padding: 14px 16px;
        flex-direction: column;
        align-items: stretch;
    }

    .PublicBrand {
        justify-content: flex-start;
    }

    .PublicNav {
        width: 100%;
        justify-content: stretch;
    }

    .PublicNavLink,
    .PublicNavLinkPrimary {
        flex: 1 1 auto;
    }

    .UserMenuPanel {
        position: fixed;
        top: 66px;
        right: 12px;
        left: 12px;
        width: auto;
        min-width: 0;
    }
}

@media (max-width: 480px) {
    html {
        font-size: 13px;
    }

    body {
        font-size: 13px;
    }

    h1 {
        font-size: 22px;
    }

    h2 {
        font-size: 18px;
    }

    .btn {
        width: 100%;
    }

    .AppHeader {
        gap: 8px;
    }

    .AppHeaderRight {
        margin-left: auto;
    }

    .AppUserName {
        display: none;
    }

    .AppSidebarNav {
        grid-template-columns: 1fr;
    }

    .LandingBrand {
        align-items: flex-start;
    }

    .LandingBrandMark {
        width: 52px;
        height: 52px;
        border-radius: 16px;
    }

    .LandingBrandTitle {
        font-size: 20px;
    }

    .LandingCopy h1 {
        font-size: 30px;
    }

    .LoginCopy h1 {
        font-size: 28px;
    }

    .LandingActions,
    .PublicNav {
        flex-direction: column;
        align-items: stretch;
    }

    .LandingBtn,
    .PublicNavLink {
        width: 100%;
    }

    .LandingFeature {
        grid-template-columns: 1fr;
    }
}

.AppHeaderLeft {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.MetisLogoButton {
    all: unset;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
}

.MetisLogoButton .AppLogoText {
    display: inline-block;
    font: inherit;
    color: inherit;
}

.MetisLogoButton:hover .AppLogoText,
.MetisLogoButton:focus .AppLogoText {
    text-decoration: underline;
}

.MetisModalBackdrop {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background: rgba(15, 23, 42, 0.55);
}

.MetisModalBackdrop[hidden] {
    display: none;
}

.MetisModal {
    width: min(720px, 100%);
    max-height: 85vh;
    overflow: auto;
    background: #fff;
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 24px 80px rgba(15, 23, 42, 0.28);
}

.MetisModalHeader {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.MetisModalHeader h2 {
    margin: 0;
}

.MetisModalHeader p {
    margin: 0.25rem 0 0;
}

.MetisModalBody p {
    margin: 0 0 1rem;
    line-height: 1.6;
}

.MetisModalBody p:last-child {
    margin-bottom: 0;
}

.MetisLogoButton .AppLogoText {
    line-height: 1;
    white-space: nowrap;
    font-size: 20px;
    color: #fff
}

.MetisLogoButton:hover .AppLogoText {
    text-decoration: underline;
    opacity: 0.85;
}