/* ========================================
   RIVCA - Modern Clean Design System
   Uses MudBlazor v9 native theming for colors.
   This file only defines custom design tokens
   and component-specific styles.
   ======================================== */

/* === 1. CSS Variables & Design Tokens === */
:root {
    /* Primary Colors - driven by MudBlazor theme */
    --color-primary: var(--mud-palette-primary, #06B6D4);
    --color-primary-dark: var(--mud-palette-primary-darken, #0891B2);
    --color-primary-light: var(--mud-palette-primary-lighten, #22D3EE);
    --color-primary-rgb: var(--mud-palette-primary-rgb, 6, 182, 212);

    /* Neutral Colors - Light Mode */
    --color-slate-50: #F8FAFC;
    --color-slate-100: #F1F5F9;
    --color-slate-200: #E2E8F0;
    --color-slate-300: #CBD5E1;
    --color-slate-400: #94A3B8;
    --color-slate-500: #64748B;
    --color-slate-600: #475569;
    --color-slate-700: #334155;
    --color-slate-800: #1E293B;
    --color-slate-900: #0F172A;

    /* Semantic Colors - driven by MudBlazor theme */
    --color-success: var(--mud-palette-success, #10B981);
    --color-warning: var(--mud-palette-warning, #F59E0B);
    --color-error: var(--mud-palette-error, #EF4444);
    --color-info: var(--mud-palette-info, #3B82F6);

    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;

    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    /* Shadows - Light Mode */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 200ms ease;
    --transition-slow: 300ms ease;
}

/* === Dark Mode: custom design tokens only (NO --mud-palette-* overrides) === */
html.mud-theme-dark {
    --color-primary: var(--mud-palette-primary, #22D3EE);
    --color-primary-dark: var(--mud-palette-primary-darken, #06B6D4);
    --color-primary-light: var(--mud-palette-primary-lighten, #67E8F9);
    --color-primary-rgb: var(--mud-palette-primary-rgb, 34, 211, 238);

    --color-slate-50: #0F172A;
    --color-slate-100: #1E293B;
    --color-slate-200: #334155;
    --color-slate-300: #475569;
    --color-slate-400: #64748B;
    --color-slate-500: #94A3B8;
    --color-slate-600: #CBD5E1;
    --color-slate-700: #E2E8F0;
    --color-slate-800: #F1F5F9;
    --color-slate-900: #F8FAFC;

    --color-success: var(--mud-palette-success, #34D399);
    --color-warning: var(--mud-palette-warning, #FBBF24);
    --color-error: var(--mud-palette-error, #F87171);
    --color-info: var(--mud-palette-info, #60A5FA);

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.6);
}

/* === 2. Typography === */
html, body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--mud-palette-text-primary, var(--color-slate-900));
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.mud-typography-h1 { font-size: 3rem; font-weight: 700; }
.mud-typography-h2 { font-size: 2.25rem; font-weight: 700; }
.mud-typography-h3 { font-size: 1.875rem; font-weight: 600; }
.mud-typography-h4 { font-size: 1.5rem; font-weight: 600; }
.mud-typography-h5 { font-size: 1.25rem; font-weight: 600; }
.mud-typography-h6 { font-size: 1.125rem; font-weight: 500; }

.mud-typography-body1 { font-size: 1rem; line-height: 1.6; }
.mud-typography-body2 { font-size: 0.875rem; line-height: 1.5; }

/* === 3. Buttons (shape/animation only, colors handled by MudBlazor theme) === */
.mud-button-filled-primary {
    transition: all var(--transition-base);
    border-radius: var(--radius-md);
    font-weight: 500;
    letter-spacing: 0.01em;
}

.mud-button-filled-primary:hover {
    transform: translateY(-2px);
}

.mud-button-outlined {
    transition: all var(--transition-base);
    border-radius: var(--radius-md);
    font-weight: 500;
}

.mud-button-text {
    font-weight: 500;
    transition: all var(--transition-base);
}

/* === 4. Cards === */
.mud-paper {
    border-radius: var(--radius-lg);
    transition: all var(--transition-slow);
}

.feature-card {
    border: 1px solid var(--color-slate-200);
    border-radius: var(--radius-lg);
    transition: all var(--transition-slow);
    cursor: pointer;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--color-primary);
}

.feature-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

/* === 5. Hero Section === */
.hero-section {
    background: linear-gradient(135deg, var(--color-slate-50) 0%, var(--color-slate-100) 100%);
    padding: 5rem 0;
    border-radius: 0;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 50%;
    height: 100%;
    background: radial-gradient(circle at top right, rgba(var(--color-primary-rgb), 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.hero-title {
    font-weight: 700;
    color: var(--color-slate-900);
    line-height: 1.1;
    margin-bottom: 1rem;
}

.hero-subtitle {
    color: var(--color-slate-600);
    font-weight: 400;
    font-size: 1.25rem;
    line-height: 1.6;
}

.hero-cta { padding: 0.875rem 2rem; font-size: 1.125rem; }

.hero-logo {
    max-width: 400px;
    width: 100%;
    height: auto;
    opacity: 0.9;
    transition: all 0.3s ease;
    filter: drop-shadow(0 4px 12px rgba(var(--color-primary-rgb), 0.2));
}

.hero-logo:hover {
    opacity: 1;
    transform: scale(1.02);
    filter: drop-shadow(0 8px 24px rgba(var(--color-primary-rgb), 0.3));
}

.hero-logo-lottie {
    aspect-ratio: 2 / 1;
    display: block;
}

.hero-logo-lottie svg {
    width: 100%;
    height: 100%;
    display: block;
}

.login-logo-wrapper {
    display: flex;
    justify-content: center;
    margin: 1rem 0 2rem;
}

.login-logo {
    width: 240px;
    max-width: 80%;
    aspect-ratio: 2 / 1;
    filter: drop-shadow(0 4px 12px rgba(var(--color-primary-rgb), 0.15));
}

.login-logo svg {
    width: 100%;
    height: 100%;
    display: block;
}

/* Auth-Seiten (Login/Register) - Zentrierter, maximal begrenzter Container */
.auth-page {
    max-width: 720px;
    margin: 0 auto;
    padding: 1.5rem 1rem 3rem;
}

.auth-page h1 {
    margin-bottom: 1.5rem;
    font-weight: 700;
}

.auth-page h2 {
    font-size: 1.1rem;
    font-weight: 500;
    text-align: center;
    color: var(--mud-palette-text-secondary, #64748B);
}

.auth-page hr {
    opacity: 0.25;
}

/* Bootstrap form controls im Dark Mode (Identity-Seiten nutzen .form-control / .form-floating,
   nicht MudBlazor-Inputs, daher muessen wir sie hier explizit einfaerben). */
html.mud-theme-dark .form-control,
html.mud-theme-dark .form-select,
html.mud-theme-dark .form-control-plaintext {
    background-color: var(--mud-palette-surface, #1E293B);
    color: var(--mud-palette-text-primary, #F1F5F9);
    border-color: var(--mud-palette-lines-inputs, #334155);
}

html.mud-theme-dark .form-control:focus,
html.mud-theme-dark .form-select:focus {
    background-color: var(--mud-palette-surface, #1E293B);
    color: var(--mud-palette-text-primary, #F1F5F9);
    border-color: var(--color-primary, #22D3EE);
    box-shadow: 0 0 0 0.2rem rgba(var(--color-primary-rgb, 34, 211, 238), 0.25);
}

html.mud-theme-dark .form-control::placeholder,
html.mud-theme-dark .form-floating > .form-control::placeholder {
    color: var(--mud-palette-text-disabled, #64748B);
}

html.mud-theme-dark .form-floating > label {
    color: var(--mud-palette-text-secondary, #94A3B8);
}

html.mud-theme-dark .form-floating > .form-control:focus ~ label,
html.mud-theme-dark .form-floating > .form-control:not(:placeholder-shown) ~ label,
html.mud-theme-dark .form-floating > .form-select ~ label {
    color: var(--mud-palette-text-secondary, #94A3B8);
    background-color: transparent;
}

/* Autofill-Farben in Chromium ueberschreiben (sonst behaelt Browser weissen Hintergrund) */
html.mud-theme-dark .form-control:-webkit-autofill,
html.mud-theme-dark .form-control:-webkit-autofill:hover,
html.mud-theme-dark .form-control:-webkit-autofill:focus,
html.mud-theme-dark .form-control:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px var(--mud-palette-surface, #1E293B) inset !important;
    -webkit-text-fill-color: var(--mud-palette-text-primary, #F1F5F9) !important;
    caret-color: var(--mud-palette-text-primary, #F1F5F9);
    transition: background-color 5000s ease-in-out 0s;
}

html.mud-theme-dark .form-check-input {
    background-color: var(--mud-palette-surface, #1E293B);
    border-color: var(--mud-palette-lines-inputs, #334155);
}

html.mud-theme-dark .form-check-input:checked {
    background-color: var(--color-primary, #22D3EE);
    border-color: var(--color-primary, #22D3EE);
}

html.mud-theme-dark .form-check-label,
html.mud-theme-dark .auth-page label {
    color: var(--mud-palette-text-primary, #F1F5F9);
}

/* Bootstrap Cards im Dark Mode (z.B. /Account/Manage Profile) */
html.mud-theme-dark .card {
    background-color: var(--mud-palette-surface, #1E293B);
    color: var(--mud-palette-text-primary, #F1F5F9);
    border-color: var(--mud-palette-lines-default, #334155);
}

html.mud-theme-dark .card-header,
html.mud-theme-dark .card-footer {
    background-color: rgba(255, 255, 255, 0.03);
    border-color: var(--mud-palette-lines-default, #334155);
    color: var(--mud-palette-text-primary, #F1F5F9);
}

html.mud-theme-dark .card-title,
html.mud-theme-dark .card-subtitle,
html.mud-theme-dark .card-text {
    color: var(--mud-palette-text-primary, #F1F5F9);
}

/* Outline-Buttons (z.B. "Bild waehlen") im Dark Mode lesbar halten */
html.mud-theme-dark .btn-outline-primary,
html.mud-theme-dark .btn-outline-secondary {
    color: var(--color-primary-light, #67E8F9);
    border-color: var(--color-primary, #22D3EE);
    background-color: transparent;
}

html.mud-theme-dark .btn-outline-primary:hover,
html.mud-theme-dark .btn-outline-secondary:hover {
    background-color: rgba(var(--color-primary-rgb, 34, 211, 238), 0.12);
    color: var(--color-primary-light, #67E8F9);
}

/* List-Group (Identity-Seiten nutzen .list-group fuer Navigation im Profil) */
html.mud-theme-dark .list-group-item {
    background-color: var(--mud-palette-surface, #1E293B);
    color: var(--mud-palette-text-primary, #F1F5F9);
    border-color: var(--mud-palette-lines-default, #334155);
}

html.mud-theme-dark .list-group-item.active {
    background-color: var(--color-primary-dark, #0891B2);
    border-color: var(--color-primary-dark, #0891B2);
    color: #ffffff;
}

html.mud-theme-dark .list-group-item-action:hover,
html.mud-theme-dark .list-group-item-action:focus {
    background-color: rgba(255, 255, 255, 0.04);
    color: var(--mud-palette-text-primary, #F1F5F9);
}

/* Tabellen (Identity uses plain <table>) */
/* Canvas-Hintergrund fuer Workflow-Builder und aehnliche "Bastel-Flaechen",
   loest den haesslichen #f5f5f5 inline-style in beiden Themes ab. */
.workflow-canvas {
    background-color: #f5f5f5;
}

html.mud-theme-dark .workflow-canvas {
    background-color: var(--mud-palette-background, #0F172A);
    border: 1px solid var(--mud-palette-lines-default, #334155);
}

html.mud-theme-dark .table {
    color: var(--mud-palette-text-primary, #F1F5F9);
    --bs-table-bg: transparent;
    --bs-table-color: var(--mud-palette-text-primary, #F1F5F9);
    --bs-table-border-color: var(--mud-palette-lines-default, #334155);
    --bs-table-striped-bg: rgba(255, 255, 255, 0.03);
    --bs-table-hover-bg: rgba(255, 255, 255, 0.05);
}

@media (max-width: 960px) {
    .hero-logo { max-width: 280px; }
}

/* === 6. Sidebar Navigation === */
.sidebar {
    background: linear-gradient(180deg, #334155 0%, #1E293B 100%);
    box-shadow: 2px 0 12px rgba(0, 0, 0, 0.15);
    border-right: 1px solid rgba(var(--color-primary-rgb), 0.1);
}

html.mud-theme-dark .sidebar {
    background: linear-gradient(180deg, #0F172A 0%, #020617 100%);
    box-shadow: 2px 0 16px rgba(0, 0, 0, 0.4);
    border-right: 1px solid rgba(var(--color-primary-rgb), 0.15);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--color-primary-light);
    text-shadow: 0 0 20px rgba(var(--color-primary-rgb), 0.3);
}

/* Section Headers */
.nav-section-header {
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: 1.5px;
    color: var(--color-slate-400);
    padding: 1rem 1.5rem 0.5rem;
    margin-top: 0.5rem;
    text-transform: uppercase;
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all var(--transition-base);
    position: relative;
}

.nav-section-header:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

/* Kategorie-Sections */
.analytics-section { background-color: rgba(16, 185, 129, 0.1); border-left: 3px solid #10B981; }
.analytics-section * { color: #10B981 !important; }
.customer-section { background-color: rgba(59, 130, 246, 0.1); border-left: 3px solid #3B82F6; }
.customer-section * { color: #3B82F6 !important; }
.service-section { background-color: rgba(245, 158, 11, 0.1); border-left: 3px solid #F59E0B; }
.service-section * { color: #F59E0B !important; }
.accommodation-section { background-color: rgba(139, 92, 246, 0.1); border-left: 3px solid #8B5CF6; }
.accommodation-section * { color: #8B5CF6 !important; }
.transport-section { background-color: rgba(100, 116, 139, 0.1); border-left: 3px solid #64748B; }
.transport-section * { color: #94A3B8 !important; }
.trip-section { background-color: rgba(var(--color-primary-rgb), 0.1); border-left: 3px solid var(--color-primary); }
.trip-section * { color: var(--color-primary) !important; }
.booking-section { background-color: rgba(236, 72, 153, 0.1); border-left: 3px solid #EC4899; }
.booking-section * { color: #EC4899 !important; }
.excursion-section { background-color: rgba(76, 175, 80, 0.1); border-left: 3px solid #4CAF50; }
.excursion-section * { color: #4CAF50 !important; }
.partner-section { background-color: rgba(0, 150, 136, 0.1); border-left: 3px solid #009688; }
.partner-section * { color: #009688 !important; }
.task-section { background-color: rgba(99, 110, 158, 0.1); border-left: 3px solid #636E9E; }
.task-section * { color: #636E9E !important; }
.stamdaten-section { background-color: rgba(120, 144, 156, 0.1); border-left: 3px solid #78909C; }
.stamdaten-section * { color: #78909C !important; }
.admin-section { background-color: rgba(239, 68, 68, 0.1); border-left: 3px solid #EF4444; }
.admin-section * { color: #EF4444 !important; }

/* Nav Items */
.nav-item ::deep .nav-link {
    color: var(--color-slate-300);
    background: none;
    border: none;
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    border-left: 3px solid transparent;
}

.nav-item ::deep .nav-link:hover {
    background-color: rgba(var(--color-primary-rgb), 0.1);
    color: white;
    transform: translateX(4px);
    border-left-color: var(--color-primary);
}

.nav-item ::deep a.active {
    background: linear-gradient(90deg, rgba(var(--color-primary-rgb), 0.15) 0%, transparent 100%);
    border-left: 3px solid var(--color-primary);
    color: white;
}

/* Kategoriespezifische Link-Farben */
.nav-link-analytics:hover, .nav-link-analytics.active { background: linear-gradient(90deg, rgba(16, 185, 129, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #10B981 !important; }
.nav-link-customer:hover, .nav-link-customer.active { background: linear-gradient(90deg, rgba(59, 130, 246, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #3B82F6 !important; }
.nav-link-service:hover, .nav-link-service.active { background: linear-gradient(90deg, rgba(245, 158, 11, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #F59E0B !important; }
.nav-link-accommodation:hover, .nav-link-accommodation.active { background: linear-gradient(90deg, rgba(139, 92, 246, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #8B5CF6 !important; }
.nav-link-transport:hover, .nav-link-transport.active { background: linear-gradient(90deg, rgba(100, 116, 139, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #64748B !important; }
.nav-link-trip:hover, .nav-link-trip.active { background: linear-gradient(90deg, rgba(var(--color-primary-rgb), 0.15) 0%, transparent 100%) !important; border-left: 3px solid var(--color-primary) !important; }
.nav-link-booking:hover, .nav-link-booking.active { background: linear-gradient(90deg, rgba(236, 72, 153, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #EC4899 !important; }
.nav-link-order:hover, .nav-link-order.active { background: linear-gradient(90deg, rgba(236, 72, 153, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #EC4899 !important; }
.nav-link-admin:hover, .nav-link-admin.active { background: linear-gradient(90deg, rgba(239, 68, 68, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #EF4444 !important; }
.nav-link-excursion:hover, .nav-link-excursion.active { background: linear-gradient(90deg, rgba(76, 175, 80, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #4CAF50 !important; }
.nav-link-partner:hover, .nav-link-partner.active { background: linear-gradient(90deg, rgba(0, 150, 136, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #009688 !important; }
.nav-link-task:hover, .nav-link-task.active { background: linear-gradient(90deg, rgba(99, 110, 158, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #636E9E !important; }
.nav-link-stamdaten:hover, .nav-link-stamdaten.active { background: linear-gradient(90deg, rgba(120, 144, 156, 0.15) 0%, transparent 100%) !important; border-left: 3px solid #78909C !important; }
.nav-link-identity:hover, .nav-link-identity.active { background: linear-gradient(90deg, rgba(var(--color-primary-rgb), 0.15) 0%, transparent 100%) !important; border-left: 3px solid var(--color-primary) !important; }

/* Entity Badges */
.entity-badge-small {
    font-size: 0.55rem;
    font-weight: 500;
    padding: 0.125rem 0.375rem;
    background-color: rgba(var(--color-primary-rgb), 0.1);
    color: var(--color-slate-400);
    border-radius: 4px;
    font-family: 'Inter', monospace;
    letter-spacing: 0.03em;
}

.nav-link:hover .entity-badge-small {
    background-color: rgba(var(--color-primary-rgb), 0.2);
    color: var(--color-primary-light);
}

.nav-link.active .entity-badge-small {
    background-color: rgba(var(--color-primary-rgb), 0.25);
    color: var(--color-primary-light);
}

/* Separator */
.nav-separator {
    height: 1px;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.1), transparent);
    margin: 1.5rem 0;
}

/* Collapsible Navigation */
.nav-section-collapsible { margin: 0; }

.collapse-icon {
    font-size: 0.7rem;
    margin-left: auto;
    transition: transform var(--transition-base);
    color: var(--color-slate-400);
}

.collapse-icon.expanded { transform: rotate(-180deg); }

/* Top Row */
.top-row {
    background-color: var(--mud-palette-surface, white);
    border-bottom: 1px solid var(--color-slate-200);
    box-shadow: var(--shadow-sm);
}

/* === 7. Stepper === */
.mud-stepper {
    border-radius: var(--radius-lg);
}

.mud-step-label { font-weight: 500; }
.mud-step-label-active { font-weight: 600; }

/* === 8. Forms & Inputs === */
.mud-input {
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
}

.mud-input:focus-within {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(var(--color-primary-rgb), 0.1);
}

/* === 9. Tables === */
.mud-table {
    border-radius: var(--radius-lg);
    overflow: hidden;
}

/* MudTable Striped - im Dark Mode waren die abwechselnden Zeilen zu hell,
   weil MudBlazor --mud-palette-table-striped auf einen zu hellen Wert setzt.
   Wir zwingen die Palette-Variable global im Dark Mode auf einen subtilen
   schwarzen Overlay und ueberschreiben zusaetzlich die Zeilenregeln explizit. */
html.mud-theme-dark {
    --mud-palette-table-striped: rgba(0, 0, 0, 0.25);
    --mud-palette-table-hover: rgba(255, 255, 255, 0.04);
}

html.mud-theme-dark .mud-table-root.mud-table-striped tbody .mud-table-row:nth-of-type(odd),
html.mud-theme-dark .mud-table.mud-table-striped tbody tr:nth-of-type(odd),
html.mud-theme-dark .mud-table-striped tbody .mud-table-row:nth-of-type(odd),
html.mud-theme-dark .mud-table-root.mud-table-striped tbody .mud-table-row:nth-of-type(even),
html.mud-theme-dark .mud-table.mud-table-striped tbody tr:nth-of-type(even),
html.mud-theme-dark .mud-table-striped tbody .mud-table-row:nth-of-type(even) {
    background-color: transparent !important;
}

html.mud-theme-dark .mud-table-root.mud-table-striped tbody .mud-table-row:nth-of-type(odd),
html.mud-theme-dark .mud-table.mud-table-striped tbody tr:nth-of-type(odd),
html.mud-theme-dark .mud-table-striped tbody .mud-table-row:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.25) !important;
}

html.mud-theme-dark .mud-table.mud-table-hover tbody .mud-table-row:hover,
html.mud-theme-dark .mud-table-root.mud-table-hover tbody tr.mud-table-row:hover {
    background-color: rgba(255, 255, 255, 0.04) !important;
}

/* === 10. Utility Classes === */
.glass-effect {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.gradient-text {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hover-lift { transition: transform var(--transition-base); }
.hover-lift:hover { transform: translateY(-4px); }

/* === 11. Responsive === */
@media (max-width: 960px) {
    .hero-section { padding: 3rem 0; }
    .hero-title { font-size: 2rem; }
    .hero-subtitle { font-size: 1rem; }
}

/* === 12. Animations === */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in { animation: fadeIn 0.5s ease-out; }

/* === 13. Content Area === */
.content {
    padding-top: 2rem;
    background-color: var(--mud-palette-background, var(--color-slate-50));
    min-height: calc(100vh - 3.5rem);
}

/* === 14. MudBlazor shape overrides === */
.mud-paper-outlined { border-color: var(--color-slate-200); }
.mud-chip-filled { border-radius: var(--radius-md); }
.mud-dialog { border-radius: var(--radius-lg); }
.mud-snackbar { border-radius: var(--radius-md); }

/* === 15. Activity Drawer === */
.activity-drawer-scroll {
    display: flex !important;
    flex-direction: column !important;
    height: 100vh !important;
    max-height: 100vh !important;
    overflow: hidden !important;
    overscroll-behavior: contain !important;
    background-color: var(--mud-palette-background, #F8FAFC);
}

.activity-drawer-scroll .mud-drawer-header {
    background-color: var(--mud-palette-surface, #FFFFFF);
    border-bottom: 1px solid var(--mud-palette-divider, #E2E8F0);
}

.activity-drawer-scroll .activity-drawer-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    padding-bottom: 2rem;
    background-color: var(--mud-palette-background-gray, #F1F5F9);
}

.activity-drawer-scroll .mud-input-slot.mud-input-root-outlined,
.activity-drawer-scroll .mud-input-outlined .mud-input-slot {
    background-color: var(--mud-palette-surface, #FFFFFF);
}

/* Fix: Rechter Temporary-Drawer (Anchor.End) darf im closed-State weder
   als "Geist" sichtbar werden noch leeren Layout-Platz belegen, wenn ein
   transformed-ancestor den position:fixed-Kontext bricht (sichtbar beim
   horizontalen Seiten-Scroll, z.B. /base-trips/.../edit).
   Loesung: erst slide-out animieren (transform), DANACH visibility:hidden
   und width:0 -> kein Geist und kein leerer Bereich beim Horizontal-Scroll.
   MudBlazor 9.x: .mud-drawer-pos-right und .mud-drawer--open. */
.mud-drawer.mud-drawer-temporary.mud-drawer-pos-right,
.mud-drawer.mud-drawer-temporary.mud-drawer-right {
    transition-property: transform, visibility, width, min-width, max-width, box-shadow;
    transition-duration: .225s, 0s, 0s, 0s, 0s, .225s;
    transition-delay: 0s, 0s, 0s, 0s, 0s, 0s;
}

.mud-drawer.mud-drawer-temporary.mud-drawer-pos-right:not(.mud-drawer--open),
.mud-drawer.mud-drawer-temporary.mud-drawer-right:not(.mud-drawer--open) {
    visibility: hidden !important;
    pointer-events: none !important;
    width: 0 !important;
    min-width: 0 !important;
    max-width: 0 !important;
    overflow: hidden !important;
    transition-delay: 0s, .225s, .225s, .225s, .225s, 0s;
}

/* Hide "Theme Presets" section in MudThemeManager (not implemented upstream) */
.mud-drawer-right .mud-navmenu > .mud-nav-group:first-child {
    display: none !important;
}
