:root,
.movexa-theme-dark {
    --movexa-bg: #0b1326;
    --movexa-surface: #171f33;
    --movexa-on-surface: #f0f4ff;
    --movexa-on-surface-variant: #b8c4e8;
    --movexa-primary: #6366F1;
    --movexa-cta: #5b5ee8;
    --movexa-glass-border: rgba(255, 255, 255, 0.12);
    --movexa-glass-surface: rgba(11, 19, 38, 0.92);
    --movexa-glass-inset: rgba(255, 255, 255, 0.06);
    --movexa-glass-hover-border: rgba(255, 255, 255, 0.18);
    --movexa-scrim: rgba(10, 12, 20, 0.78);
    --movexa-map-overlay: rgba(11, 19, 38, 0.55);
    --movexa-chip-bg: rgba(23, 31, 51, 0.7);
    --movexa-chat-bg: rgba(23, 31, 51, 0.85);
    --movexa-muted-fill: rgba(255, 255, 255, 0.04);
    --movexa-downloads-bg: rgba(0, 0, 0, 0.12);
    --movexa-map-host-bg: rgba(0, 0, 0, 0.2);
    --movexa-page-glow-1: rgba(99, 102, 241, 0.35);
    --movexa-page-glow-2: rgba(91, 141, 239, 0.12);
    --movexa-skeleton-a: rgba(255, 255, 255, 0.04);
    --movexa-skeleton-b: rgba(255, 255, 255, 0.10);
    --movexa-motion-fast: 180ms;
    --movexa-motion-normal: 280ms;
    --movexa-motion-panel: 360ms;
    --movexa-ease: cubic-bezier(0.16, 1, 0.3, 1);
    --movexa-ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --movexa-ease-in: cubic-bezier(0.55, 0, 1, 0.45);
}

.movexa-theme-light {
    --movexa-bg: #f0f4ff;
    --movexa-surface: #ffffff;
    --movexa-on-surface: #0b1326;
    --movexa-on-surface-variant: #374151;
    --movexa-primary: #6366F1;
    --movexa-cta: #5b5ee8;
    --movexa-glass-border: rgba(15, 23, 42, 0.12);
    --movexa-glass-surface: rgba(255, 255, 255, 0.92);
    --movexa-glass-inset: rgba(15, 23, 42, 0.04);
    --movexa-glass-hover-border: rgba(15, 23, 42, 0.22);
    --movexa-scrim: rgba(15, 23, 42, 0.45);
    --movexa-map-overlay: rgba(255, 255, 255, 0.82);
    --movexa-chip-bg: rgba(255, 255, 255, 0.88);
    --movexa-chat-bg: rgba(255, 255, 255, 0.95);
    --movexa-muted-fill: rgba(15, 23, 42, 0.04);
    --movexa-downloads-bg: rgba(15, 23, 42, 0.04);
    --movexa-map-host-bg: #e8eefc;
    --movexa-page-glow-1: rgba(99, 102, 241, 0.12);
    --movexa-page-glow-2: rgba(91, 141, 239, 0.08);
    --movexa-skeleton-a: rgba(15, 23, 42, 0.04);
    --movexa-skeleton-b: rgba(15, 23, 42, 0.10);
}

.movexa-page-bg {
    min-height: 100vh;
    min-height: 100dvh;
    background: var(--movexa-bg);
    background-image:
        radial-gradient(ellipse 80% 50% at 50% -20%, var(--movexa-page-glow-1), transparent),
        radial-gradient(ellipse 60% 40% at 100% 100%, var(--movexa-page-glow-2), transparent);
    color: var(--movexa-on-surface);
}

.movexa-portal-banner {
    background: var(--movexa-glass-surface);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--movexa-glass-border);
    border-radius: 16px;
    text-align: center;
    box-shadow: inset 0 1px 0 var(--movexa-glass-inset);
}

.movexa-portal-banner--platform {
    border-color: color-mix(in srgb, var(--mud-palette-secondary) 45%, var(--movexa-glass-border));
    box-shadow:
        inset 0 1px 0 var(--movexa-glass-inset),
        0 0 0 1px color-mix(in srgb, var(--mud-palette-secondary) 18%, transparent);
}

.movexa-portal-banner--tenant {
    border-color: color-mix(in srgb, var(--mud-palette-primary) 40%, var(--movexa-glass-border));
    box-shadow:
        inset 0 1px 0 var(--movexa-glass-inset),
        0 0 0 1px color-mix(in srgb, var(--mud-palette-primary) 16%, transparent);
}

.movexa-login-mode-chip {
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-weight: 700;
}

.movexa-portal-banner__title {
    font-weight: 800;
    letter-spacing: 0.06em;
    color: var(--movexa-on-surface);
}

.movexa-tenant-logo {
    object-fit: contain;
    display: block;
}

.movexa-tenant-logo--banner {
    max-height: 72px;
    max-width: 200px;
    margin-left: auto;
    margin-right: auto;
}

.movexa-tenant-logo--platform {
    max-height: 96px;
    max-width: 96px;
}

.movexa-tenant-logo--appbar {
    height: 32px;
    width: auto;
    max-width: 140px;
}

.movexa-tenant-logo--drawer {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--movexa-muted-fill);
    padding: 4px;
    flex-shrink: 0;
}

.movexa-appbar-brand {
    min-width: 0;
}

.movexa-appbar-brand .mud-typography {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.movexa-glass-panel {
    background: var(--movexa-glass-surface) !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--movexa-glass-border);
    border-radius: 16px;
    box-shadow:
        inset 0 1px 0 var(--movexa-glass-inset),
        0 8px 24px -2px rgba(15, 23, 42, 0.12),
        0 2px 6px rgba(15, 23, 42, 0.06);
    transition: border-color var(--movexa-motion-fast) var(--movexa-ease), box-shadow var(--movexa-motion-fast) var(--movexa-ease);
    color: var(--movexa-on-surface);
}

.movexa-glass-panel:hover {
    border-color: var(--movexa-glass-hover-border);
}

.movexa-tabular {
    font-variant-numeric: tabular-nums;
    font-weight: 800;
    letter-spacing: -0.02em;
}

/* Figma MxKpiCard (1:173): 12px radius, internal accent bar, ExtraBold value */
.movexa-kpi {
    position: relative;
    border-radius: 12px !important;
    padding-left: 1.1rem !important;
    overflow: hidden;
}

.movexa-kpi::before {
    content: "";
    position: absolute;
    left: 0.65rem;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 2.25rem;
    border-radius: 2px;
    background: var(--movexa-primary);
}

.movexa-kpi .mud-typography-caption {
    font-size: 0.6875rem;
    font-weight: 500;
    color: var(--movexa-on-surface-variant);
}

.movexa-kpi--success { border-left: none; }
.movexa-kpi--success::before { background: #34D399; }
.movexa-kpi--warning { border-left: none; }
.movexa-kpi--warning::before { background: #FBBF24; }
.movexa-kpi--trust { border-left: none; }
.movexa-kpi--trust::before { background: #5B8DEF; }
.movexa-kpi--danger { border-left: none; }
.movexa-kpi--danger::before { background: #F87171; }
.movexa-kpi--progress { border-left: none; }
.movexa-kpi--progress::before { background: #6366F1; }
.movexa-kpi--urgency { border-left: none; }
.movexa-kpi--urgency::before { background: #F59E0B; }

.movexa-kpi--interactive {
    cursor: pointer;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
    outline: none;
}

.movexa-kpi--interactive:hover {
    border-color: rgba(129, 140, 248, 0.45);
    background: rgba(99, 102, 241, 0.08);
}

.movexa-kpi--interactive:focus-visible {
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.55);
}

.movexa-kpi--selected {
    border-color: var(--movexa-primary) !important;
    border-width: 1.5px !important;
    background: color-mix(in srgb, var(--movexa-primary) 12%, var(--movexa-surface)) !important;
    box-shadow: 0 0 0 1px rgba(99, 102, 241, 0.25);
}

.movexa-nav-link.mud-nav-link.active {
    border-left: 3px solid var(--movexa-cta);
    background: rgba(99, 102, 241, 0.12);
}

.movexa-map-scrim::before {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--movexa-scrim);
    pointer-events: none;
    z-index: 2;
    opacity: 0.35;
}

.movexa-map-scrim--waiting::before {
    opacity: 0;
}

.movexa-bottom-sheet {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    max-height: 45%;
    border-radius: 16px 16px 0 0;
}

.movexa-dialog-glass .mud-dialog {
    background: var(--movexa-glass-surface);
    backdrop-filter: blur(16px);
    border: 1px solid var(--movexa-glass-border);
    border-radius: 16px;
}

.movexa-chat-bubble {
    background: var(--movexa-chat-bg);
    border: 1px solid var(--movexa-glass-border);
    border-radius: 12px;
    padding: 0.5rem 0.75rem;
    margin-bottom: 0.5rem;
}

.movexa-chat-bubble--outgoing {
    background: rgba(99, 102, 241, 0.18);
    border-color: rgba(99, 102, 241, 0.35);
}

.movexa-skeleton {
    background: linear-gradient(90deg, var(--movexa-skeleton-a) 25%, var(--movexa-skeleton-b) 50%, var(--movexa-skeleton-a) 75%);
    background-size: 200% 100%;
    animation: movexa-shimmer 1.2s infinite;
    border-radius: 8px;
}

@keyframes movexa-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

.movexa-empty-state {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--movexa-on-surface-variant);
}

.movexa-ride-card-trust {
    border: 1px solid rgba(91, 141, 239, 0.35);
    border-radius: 12px;
    background: rgba(91, 141, 239, 0.08);
}

.movexa-search-sheet {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    max-height: 55%;
    overflow-y: auto;
}

.movexa-search-sheet--pending {
    top: auto;
    bottom: 0;
    left: 0;
    right: 0;
    max-height: min(42vh, 20rem);
    border-radius: 20px 20px 0 0;
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.32);
    overflow-y: auto;
}

@media (min-width: 768px) {
    .movexa-search-sheet--pending {
        top: auto;
        bottom: 1rem;
        left: 1rem;
        right: auto;
        width: min(24rem, calc(100% - 2rem));
        max-height: min(46vh, 22rem);
        border-radius: 16px;
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.28);
    }
}

.movexa-vehicle-chip {
    border: 1px solid var(--movexa-glass-border);
    background: var(--movexa-chip-bg);
    border-radius: 999px;
}

.movexa-vehicle-chip--selected {
    border-color: rgba(99, 102, 241, 0.55);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.25);
}

.movexa-search-page {
    position: relative;
    height: 100%;
    min-height: 24rem;
}

/* Pasajero: mapa fijo Calles — sin selector de capas */
.movexa-search-page .leaflet-control-layers,
.booking-page .leaflet-control-layers,
.ride-request-map .leaflet-control-layers {
    display: none !important;
}

.movexa-client-shell .mud-appbar {
    padding-top: env(safe-area-inset-top, 0px) !important;
}

.movexa-client-shell .mud-appbar.movexa-appbar--map {
    background: var(--movexa-map-overlay) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--movexa-glass-border) !important;
    z-index: 1200;
}

.movexa-client-shell .mud-main-content.movexa-main--map {
    padding: calc(var(--mud-appbar-height, 48px) + env(safe-area-inset-top, 0px)) 0 0 !important;
    height: 100vh;
    height: 100dvh;
    min-height: 0;
    overflow: hidden;
    box-sizing: border-box;
}

.movexa-client-shell .mud-main-content.movexa-main--map > * {
    height: 100%;
    min-height: 0;
}

.movexa-client-shell .mud-main-content.movexa-main--booking {
    padding-top: calc(var(--mud-appbar-height, 48px) + env(safe-area-inset-top, 0px)) !important;
    min-height: 100vh;
    min-height: 100dvh;
    box-sizing: border-box;
    overflow: auto;
}

/* Non-map routes (trips, profile, trip detail): AppBar adds safe-area padding-top,
   so main content must clear appbar-height + safe-area or the page title clips. */
.movexa-client-shell .mud-main-content:not(.movexa-main--map) {
    padding-top: calc(var(--mud-appbar-height, 48px) + env(safe-area-inset-top, 0px) + 1rem) !important;
    background: transparent;
}

/* Bottom-nav clearance must live here (global CSS after MudBlazor). Rules in
   ClientBottomNav.razor.css are scoped and never match MudMainContent.
   7.5rem covers nav (~4rem) + Android system/gesture overlap margin on tall phones. */
.movexa-client-shell {
    --movexa-bottom-nav-clearance: calc(7.5rem + env(safe-area-inset-bottom, 0px));
}

.movexa-client-shell .mud-main-content.movexa-main--with-bottom-nav {
    padding-bottom: var(--movexa-bottom-nav-clearance) !important;
}

.movexa-client-shell .mud-main-content.movexa-main--map-with-bottom-nav {
    padding-bottom: var(--movexa-bottom-nav-clearance) !important;
}

.movexa-client-shell .mud-main-content {
    background: transparent;
}

.movexa-admin-layout {
    --movexa-admin-content-x: 1.25rem;
    --movexa-admin-content-bottom: 1.5rem;
    --movexa-admin-content-top: 1.25rem;
    background: var(--movexa-bg);
    color: var(--movexa-on-surface);
    min-height: 100vh;
    min-height: 100dvh;
}

.movexa-admin-layout .mud-main-content {
    min-height: 100vh;
    min-height: 100dvh;
    padding-top: calc(var(--mud-appbar-height, 48px) + var(--movexa-admin-content-top));
    padding-right: var(--movexa-admin-content-x);
    padding-bottom: var(--movexa-admin-content-bottom);
    padding-left: var(--movexa-admin-content-x);
}

.movexa-admin-layout .mud-main-content.movexa-admin-content--flush {
    padding: var(--mud-appbar-height, 48px) 0 0;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

.movexa-admin-drawer {
    background: var(--movexa-glass-surface) !important;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-right: 1px solid var(--movexa-glass-border) !important;
}

.movexa-admin-drawer .mud-drawer-content {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
}

.movexa-admin-drawer-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.movexa-admin-drawer-nav {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
}

.movexa-admin-downloads {
    flex-shrink: 0;
    margin-top: auto;
    padding: 0.85rem 0.9rem 1.1rem;
    border-top: 1px solid var(--movexa-glass-border);
    background: var(--movexa-downloads-bg);
}

.movexa-admin-downloads__title {
    font-weight: 700;
    letter-spacing: 0.02em;
    margin-bottom: 0.15rem;
}

.movexa-admin-downloads__hint {
    display: block;
    margin-bottom: 0.65rem;
    opacity: 0.85;
}

.movexa-admin-downloads__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.4rem 0.5rem;
    align-items: end;
}

.movexa-admin-downloads__card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    padding: 0.45rem 0.25rem 0.55rem;
    border-radius: 12px;
    border: 1px solid var(--movexa-glass-border);
    background: var(--movexa-muted-fill);
    color: inherit;
    text-decoration: none;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.movexa-admin-downloads__card:hover {
    border-color: rgba(99, 102, 241, 0.45);
    background: rgba(99, 102, 241, 0.08);
}

.movexa-admin-downloads__card img {
    display: block;
    width: 96px;
    height: 96px;
    border-radius: 8px;
    background: #fff;
}

.movexa-admin-downloads__card .movexa-admin-downloads__label {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    text-align: center;
}

.movexa-admin-downloads__card .movexa-admin-downloads__updated-caption {
    display: block;
    margin-top: 0.05rem;
    font-size: 0.52rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    text-align: center;
    line-height: 1.2;
    opacity: 0.72;
    text-transform: uppercase;
}

.movexa-admin-downloads__card .movexa-admin-downloads__meta {
    display: block;
    margin-top: -0.15rem;
    font-size: 0.58rem;
    font-weight: 500;
    line-height: 1.25;
    letter-spacing: 0.01em;
    text-align: center;
    white-space: pre-line;
    opacity: 0.78;
    font-variant-numeric: tabular-nums;
}

.movexa-admin-downloads__notice {
    display: block;
    margin-top: 0.65rem;
    font-size: 0.65rem;
    line-height: 1.35;
    opacity: 0.85;
}

.movexa-admin-downloads--page {
    margin-top: 0;
    padding: 0;
    border-top: none;
    background: transparent;
}

.movexa-admin-downloads--page .movexa-admin-downloads__title {
    font-size: 0.95rem;
}

.movexa-admin-downloads--page .movexa-admin-downloads__hint {
    font-size: 0.8rem;
    line-height: 1.4;
    max-width: 40rem;
}

.movexa-admin-downloads--page .movexa-admin-downloads__grid {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    max-width: 32rem;
}

.movexa-admin-downloads--single .movexa-admin-downloads__grid,
.movexa-admin-downloads--page.movexa-admin-downloads--single .movexa-admin-downloads__grid {
    grid-template-columns: minmax(0, 16rem);
    max-width: 16rem;
}

.movexa-admin-downloads--page .movexa-admin-downloads__card {
    padding: 0.85rem 0.75rem 1rem;
}

.movexa-admin-downloads--page .movexa-admin-downloads__card img {
    width: 140px;
    height: 140px;
}

.movexa-admin-downloads--page .movexa-admin-downloads__label {
    font-size: 0.85rem;
}

.movexa-admin-downloads--page .movexa-admin-downloads__updated-caption,
.movexa-admin-downloads--page .movexa-admin-downloads__meta {
    font-size: 0.7rem;
}

.movexa-admin-downloads--page .movexa-admin-downloads__notice {
    font-size: 0.8rem;
    max-width: 40rem;
}

.movexa-admin-downloads__stack {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.movexa-admin-downloads__play {
    display: flex;
    justify-content: flex-start;
    min-width: 0;
    width: 100%;
}

.movexa-admin-downloads__play .movexa-play-badge {
    width: auto;
    max-width: 100%;
    align-items: flex-start;
}

/* Drawer: badges pequeños, altura fija uniforme (ratio nativo). */
.movexa-admin-downloads__play .movexa-play-badge__img {
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 32px;
}

.movexa-admin-downloads__play .movexa-play-badge--compact .movexa-play-badge__img {
    max-height: 32px;
}

.movexa-admin-downloads--page .movexa-admin-downloads__play .movexa-play-badge__img,
.movexa-admin-downloads--page .movexa-admin-downloads__play .movexa-play-badge--compact .movexa-play-badge__img {
    max-height: 48px;
}

/* Insignia oficial Google Play — no rediseñar el artwork; solo escala uniforme. */
.movexa-play-badge {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
    min-width: 0;
    padding: 0;
    border: none;
    background: transparent;
    color: inherit;
    text-decoration: none;
    line-height: 0;
    transition: opacity 0.15s ease;
}

.movexa-play-badge:hover {
    opacity: 0.9;
}

.movexa-play-badge:focus-visible {
    outline: 2px solid var(--movexa-primary, #6366F1);
    outline-offset: 3px;
    border-radius: 4px;
}

.movexa-play-badge__label {
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    line-height: 1.2;
    opacity: 0.78;
    margin-bottom: 0.05rem;
}

.movexa-play-badge__img {
    display: block;
    width: auto;
    height: auto;
    max-height: 52px;
    max-width: 100%;
    aspect-ratio: 646 / 250;
    object-fit: contain;
    object-position: left center;
}

.movexa-play-badge--compact {
    gap: 0.15rem;
}

.movexa-play-badge--compact .movexa-play-badge__img {
    max-height: 40px;
}

.movexa-play-badge--compact .movexa-play-badge__label {
    font-size: 0.62rem;
}

/* Clipped drawer already starts below the AppBar — do not add appbar-height again. */
.movexa-admin-drawer .mud-drawer-header.movexa-admin-drawer-header {
    padding: var(--movexa-admin-content-top, 1.25rem) 1.25rem 1.25rem;
    min-height: auto;
    height: auto;
    border-bottom: 1px solid var(--movexa-glass-border);
    margin-bottom: 0.25rem;
}

.movexa-admin-drawer-brand {
    display: flex;
    align-items: flex-start;
    gap: 0.875rem;
    width: 100%;
}

.movexa-admin-drawer-brand__icon {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 12px;
    background: rgba(99, 102, 241, 0.14);
    border: 1px solid rgba(99, 102, 241, 0.28);
    color: var(--movexa-primary);
}

.movexa-admin-drawer-brand__text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    padding-top: 0.125rem;
}

.movexa-admin-drawer-brand__title {
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: 0.01em;
    word-break: break-word;
}

.movexa-admin-drawer-brand__subtitle {
    line-height: 1.4;
}

/* Impersonation lives inside MudAppBar — no separate top banner that breaks fixed appbar offset */
.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating {
    background: linear-gradient(90deg, #115e59 0%, #0f766e 45%, #0e7490 100%) !important;
    color: #ffffff !important;
    border-bottom: 1px solid rgba(15, 23, 42, 0.35) !important;
    transition: background-color var(--movexa-motion-normal) var(--movexa-ease),
                color var(--movexa-motion-fast) var(--movexa-ease);
}

/* Light chrome for labels / nav — exclude the return CTA so it can keep its own contrast */
.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .mud-typography,
.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .mud-icon-button,
.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .mud-icon-root,
.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating a,
.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .mud-button-root:not(.movexa-appbar-impersonation__cta) {
    color: #ffffff !important;
}

.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .mud-button-root:not(.movexa-appbar-impersonation__cta):hover {
    background: rgba(255, 255, 255, 0.16) !important;
}

.movexa-appbar-impersonation {
    min-width: 0;
    max-width: 42vw;
}

.movexa-appbar-impersonation__text {
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #ffffff;
    text-shadow: 0 1px 1px rgba(15, 23, 42, 0.35);
}

.movexa-appbar-impersonation__slug {
    padding: 0.1rem 0.45rem;
    border-radius: 4px;
    background: rgba(15, 23, 42, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.35);
    color: #ffffff;
    font-size: 0.75rem;
    flex-shrink: 0;
}

/* Dark CTA on teal bar: stays readable even if Mud forces light label color */
.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .movexa-appbar-impersonation__cta.mud-button-root,
.movexa-appbar-impersonation__cta.mud-button-root {
    flex-shrink: 0;
    background: #0f172a !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.5) !important;
    font-weight: 700;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.35);
}

.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .movexa-appbar-impersonation__cta.mud-button-root:hover,
.movexa-appbar-impersonation__cta.mud-button-root:hover {
    background: #1e293b !important;
    color: #ffffff !important;
}

.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .movexa-appbar-impersonation__cta.mud-button-root .mud-button-label,
.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .movexa-appbar-impersonation__cta.mud-button-root .mud-typography,
.movexa-admin-layout--impersonating .mud-appbar.movexa-appbar--impersonating .movexa-appbar-impersonation__cta.mud-button-root .mud-icon-root,
.movexa-appbar-impersonation__cta.mud-button-root .mud-button-label {
    color: #ffffff !important;
}

.movexa-appbar-title {
    /* Antes 28vw cortaba "ADMIN — PLATAFORMA (SuperAdmin)" con espacio libre en la barra */
    max-width: min(42rem, calc(100vw - 14rem));
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Legacy banner class kept harmless if referenced */
.movexa-impersonation-banner {
    display: none;
}

/* SuperAdmin ↔ empresa: cinematic context switch during forceLoad */
html.movexa-scope-switch-hold {
    background: #0b1326;
}

html.movexa-scope-switch-hold[data-scope-switch="enter"] {
    background: #0c3532;
}

html.movexa-scope-switch-hold::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 200000;
    pointer-events: none;
    background:
        radial-gradient(ellipse 90% 60% at 50% 110%, rgba(99, 102, 241, 0.42), transparent 58%),
        radial-gradient(ellipse 50% 40% at 20% 20%, rgba(91, 141, 239, 0.18), transparent),
        #0b1326;
}

html.movexa-scope-switch-hold[data-scope-switch="enter"]::before {
    background:
        radial-gradient(ellipse 90% 60% at 50% 110%, rgba(20, 184, 166, 0.45), transparent 58%),
        radial-gradient(ellipse 50% 40% at 80% 15%, rgba(14, 116, 144, 0.22), transparent),
        #0c3532;
}

.movexa-scope-switch {
    font-family: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
    --mxs-ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --mxs-ease-in: cubic-bezier(0.55, 0, 1, 0.45);
    --mxs-ease-spring: cubic-bezier(0.34, 1.25, 0.64, 1);
    position: fixed;
    inset: 0;
    z-index: 200010;
    display: grid;
    place-items: center;
    padding: 1.5rem;
    opacity: 0;
    pointer-events: none;
}

.movexa-scope-switch.is-visible {
    opacity: 1;
    pointer-events: auto;
}

.movexa-scope-switch.is-revealing {
    pointer-events: none;
    animation: movexa-scope-root-fade 480ms var(--mxs-ease-in) forwards;
}

.movexa-scope-switch__scrim {
    position: absolute;
    inset: 0;
    overflow: hidden;
    background: linear-gradient(165deg, #0b1326 0%, #121a30 52%, #0b1326 100%);
}

.movexa-scope-switch--enter .movexa-scope-switch__scrim {
    background: linear-gradient(165deg, #0c3532 0%, #115e59 48%, #0e7490 100%);
}

.movexa-scope-switch__mesh {
    position: absolute;
    inset: 0;
    opacity: 0.35;
    background-image:
        radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.07) 1px, transparent 0);
    background-size: 28px 28px;
    mask-image: radial-gradient(ellipse 80% 70% at 50% 42%, #000 20%, transparent 72%);
}

.movexa-scope-switch__blob {
    position: absolute;
    border-radius: 999px;
    filter: blur(48px);
    opacity: 0;
    will-change: transform, opacity;
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__blob {
    opacity: 1;
}

.movexa-scope-switch__blob--1 {
    width: 42vw;
    height: 42vw;
    max-width: 22rem;
    max-height: 22rem;
    top: -8%;
    left: -6%;
    background: rgba(99, 102, 241, 0.42);
    animation: movexa-scope-blob-a 9s ease-in-out infinite;
}

.movexa-scope-switch__blob--2 {
    width: 36vw;
    height: 36vw;
    max-width: 18rem;
    max-height: 18rem;
    bottom: -12%;
    right: -8%;
    background: rgba(91, 141, 239, 0.28);
    animation: movexa-scope-blob-b 10.5s ease-in-out infinite;
}

.movexa-scope-switch__blob--3 {
    width: 28vw;
    height: 28vw;
    max-width: 14rem;
    max-height: 14rem;
    top: 38%;
    right: 18%;
    background: rgba(139, 92, 246, 0.2);
    animation: movexa-scope-blob-c 7.8s ease-in-out infinite;
}

.movexa-scope-switch--enter .movexa-scope-switch__blob--1 {
    background: rgba(20, 184, 166, 0.42);
}

.movexa-scope-switch--enter .movexa-scope-switch__blob--2 {
    background: rgba(14, 116, 144, 0.3);
}

.movexa-scope-switch--enter .movexa-scope-switch__blob--3 {
    background: rgba(45, 212, 191, 0.22);
}

.movexa-scope-switch__curtain {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 85% 55% at 50% 28%, rgba(99, 102, 241, 0.28), transparent 62%),
        linear-gradient(180deg, #0b1326 0%, #121a30 55%, #0b1326 100%);
    transform: translateY(100%);
    clip-path: inset(0 0 0 0);
}

.movexa-scope-switch--enter .movexa-scope-switch__curtain {
    background:
        radial-gradient(ellipse 85% 55% at 50% 28%, rgba(20, 184, 166, 0.32), transparent 62%),
        linear-gradient(180deg, #0c3532 0%, #115e59 52%, #0e7490 100%);
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__curtain {
    animation: movexa-scope-curtain-in 680ms var(--mxs-ease-out) forwards;
}

.movexa-scope-switch--exit.is-mounted .movexa-scope-switch__curtain {
    animation: movexa-scope-curtain-in-exit 680ms var(--mxs-ease-out) forwards;
}

.movexa-scope-switch.is-revealing .movexa-scope-switch__curtain {
    animation: movexa-scope-curtain-out 480ms var(--mxs-ease-in) forwards;
}

.movexa-scope-switch--enter.is-revealing .movexa-scope-switch__curtain {
    animation: movexa-scope-curtain-out-enter 480ms var(--mxs-ease-in) forwards;
}

.movexa-scope-switch__card {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.65rem;
    width: min(100%, 18.75rem);
    padding: 1.75rem 1.5rem 1.45rem;
    border-radius: 22px;
    text-align: center;
    color: #f0f4ff;
    background: rgba(11, 19, 38, 0.62);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 24px 48px rgba(0, 0, 0, 0.45),
        0 0 0 1px rgba(99, 102, 241, 0.1);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    transform: translateY(24px) scale(0.96);
    opacity: 0;
    filter: blur(8px);
}

.movexa-scope-switch--enter .movexa-scope-switch__card {
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 24px 48px rgba(0, 0, 0, 0.45),
        0 0 0 1px rgba(20, 184, 166, 0.14);
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__card {
    animation: movexa-scope-card-in 620ms var(--mxs-ease-spring) forwards;
}

.movexa-scope-switch.is-revealing .movexa-scope-switch__card {
    animation: movexa-scope-card-out 340ms var(--mxs-ease-in) forwards;
}

.movexa-scope-switch__hero {
    position: relative;
    width: 4.5rem;
    height: 4.5rem;
    margin: 0 0 0.35rem;
}

.movexa-scope-switch__glow {
    position: absolute;
    inset: -0.35rem;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.35) 0%, transparent 68%);
    opacity: 0;
    transform: scale(0.85);
}

.movexa-scope-switch--enter .movexa-scope-switch__glow {
    background: radial-gradient(circle, rgba(20, 184, 166, 0.38) 0%, transparent 68%);
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__glow {
    animation: movexa-scope-glow-in 680ms var(--mxs-ease-out) 60ms forwards;
}

.movexa-scope-switch__ring {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    border: 1.5px dashed rgba(255, 255, 255, 0.22);
    opacity: 0;
    transform: scale(0.88) rotate(-18deg);
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__ring {
    animation: movexa-scope-ring-in 900ms var(--mxs-ease-out) 120ms forwards,
               movexa-scope-ring-spin 9s linear 900ms infinite;
}

.movexa-scope-switch__ripple {
    position: absolute;
    inset: 0.35rem;
    border-radius: 999px;
    border: 2px solid rgba(165, 180, 252, 0.55);
    opacity: 0;
    transform: scale(0.6);
}

.movexa-scope-switch--enter .movexa-scope-switch__ripple {
    border-color: rgba(94, 234, 212, 0.55);
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__ripple {
    animation: movexa-scope-ripple 1.8s var(--mxs-ease-out) 200ms infinite;
}

.movexa-scope-switch__icon {
    position: absolute;
    inset: 0.5rem;
    display: grid;
    place-items: center;
    border-radius: 999px;
    font-size: 1.35rem;
    color: #ffffff;
    background:
        radial-gradient(circle at 28% 24%, rgba(255, 255, 255, 0.38), transparent 48%),
        linear-gradient(145deg, #6366f1, #5b8def);
    border: 1px solid rgba(165, 180, 252, 0.35);
    box-shadow:
        0 8px 20px rgba(99, 102, 241, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transform: scale(0.72) rotate(-10deg);
    opacity: 0;
}

.movexa-scope-switch--enter .movexa-scope-switch__icon {
    background:
        radial-gradient(circle at 28% 24%, rgba(255, 255, 255, 0.42), transparent 48%),
        linear-gradient(145deg, #14b8a6, #0e7490);
    border-color: rgba(94, 234, 212, 0.35);
    box-shadow:
        0 8px 20px rgba(20, 184, 166, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__icon {
    animation: movexa-scope-icon-pop 560ms var(--mxs-ease-spring) 80ms forwards;
}

.movexa-scope-switch__icon.has-logo {
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(255, 255, 255, 0.28);
    box-shadow:
        0 8px 20px rgba(0, 0, 0, 0.22),
        inset 0 1px 0 rgba(255, 255, 255, 0.65);
    padding: 0.4rem;
}

.movexa-scope-switch--enter .movexa-scope-switch__icon.has-logo {
    background: rgba(255, 255, 255, 0.96);
    border-color: rgba(255, 255, 255, 0.28);
    box-shadow:
        0 8px 20px rgba(0, 0, 0, 0.22),
        inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

.movexa-scope-switch__logo {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 999px;
}

.movexa-scope-switch__icon i[hidden],
.movexa-scope-switch__logo[hidden] {
    display: none !important;
}

.movexa-scope-switch__pill,
.movexa-scope-switch__title,
.movexa-scope-switch__subtitle,
.movexa-scope-switch__dots {
    opacity: 0;
    transform: translateY(10px);
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__pill {
    animation: movexa-scope-line-in 420ms var(--mxs-ease-out) 200ms forwards;
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__title {
    animation: movexa-scope-line-in 420ms var(--mxs-ease-out) 280ms forwards;
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__subtitle {
    animation: movexa-scope-line-in 420ms var(--mxs-ease-out) 360ms forwards;
}

.movexa-scope-switch.is-mounted .movexa-scope-switch__dots {
    animation: movexa-scope-line-in 420ms var(--mxs-ease-out) 440ms forwards;
}

.movexa-scope-switch__pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    border: 1px solid rgba(165, 180, 252, 0.35);
    background: rgba(99, 102, 241, 0.16);
    margin-bottom: 0.15rem;
}

.movexa-scope-switch--enter .movexa-scope-switch__pill {
    border-color: rgba(94, 234, 212, 0.35);
    background: rgba(20, 184, 166, 0.14);
}

.movexa-scope-switch__kicker {
    margin: 0;
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(199, 210, 254, 0.95);
}

.movexa-scope-switch--enter .movexa-scope-switch__kicker {
    color: rgba(153, 246, 228, 0.95);
}

.movexa-scope-switch__title {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 800;
    line-height: 1.3;
    letter-spacing: -0.02em;
    text-wrap: balance;
    color: #ffffff;
}

.movexa-scope-switch__subtitle {
    margin: 0 0 0.35rem;
    font-size: 0.875rem;
    line-height: 1.45;
    color: rgba(240, 244, 255, 0.78);
}

.movexa-scope-switch__dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 0.5rem;
}

.movexa-scope-switch__dots > span {
    display: block;
    width: 0.375rem;
    height: 0.375rem;
    border-radius: 999px;
    background: rgba(165, 180, 252, 0.35);
    transform: scale(0.85);
    animation: movexa-scope-dot-pulse 1.2s ease-in-out infinite;
}

.movexa-scope-switch__dots > span:nth-child(1) {
    width: 0.5rem;
    height: 0.5rem;
    background: #a5b4fc;
    animation-delay: 0ms;
}

.movexa-scope-switch__dots > span:nth-child(2) {
    animation-delay: 160ms;
}

.movexa-scope-switch__dots > span:nth-child(3) {
    animation-delay: 320ms;
}

.movexa-scope-switch--enter .movexa-scope-switch__dots > span {
    background: rgba(94, 234, 212, 0.35);
}

.movexa-scope-switch--enter .movexa-scope-switch__dots > span:nth-child(1) {
    background: #5eead4;
}

@keyframes movexa-scope-curtain-in {
    0% { transform: translateY(100%); }
    100% { transform: translateY(0); }
}

@keyframes movexa-scope-curtain-in-exit {
    0% { transform: translateY(-100%); }
    100% { transform: translateY(0); }
}

@keyframes movexa-scope-curtain-out {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(-18%); opacity: 0; }
}

@keyframes movexa-scope-curtain-out-enter {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(14%); opacity: 0; }
}

@keyframes movexa-scope-card-in {
    0% {
        transform: translateY(28px) scale(0.94);
        opacity: 0;
        filter: blur(6px);
    }
    100% {
        transform: translateY(0) scale(1);
        opacity: 1;
        filter: blur(0);
    }
}

@keyframes movexa-scope-card-out {
    0% {
        transform: translateY(0) scale(1);
        opacity: 1;
        filter: blur(0);
    }
    100% {
        transform: translateY(-12px) scale(0.96);
        opacity: 0;
        filter: blur(4px);
    }
}

@keyframes movexa-scope-line-in {
    0% {
        opacity: 0;
        transform: translateY(10px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes movexa-scope-icon-pop {
    0% {
        opacity: 0;
        transform: scale(0.7) rotate(-12deg);
    }
    70% {
        transform: scale(1.06) rotate(4deg);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
}

@keyframes movexa-scope-ring-in {
    0% {
        opacity: 0;
        transform: scale(0.82) rotate(-24deg);
    }
    100% {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
}

@keyframes movexa-scope-ring-spin {
    to { transform: scale(1) rotate(360deg); }
}

@keyframes movexa-scope-root-fade {
    0% { opacity: 1; }
    100% { opacity: 0; }
}

@keyframes movexa-scope-ripple {
    0% {
        opacity: 0.65;
        transform: scale(0.6);
    }
    70% {
        opacity: 0;
        transform: scale(1.35);
    }
    100% {
        opacity: 0;
        transform: scale(1.35);
    }
}

@keyframes movexa-scope-blob-a {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(6%, 8%) scale(1.08); }
}

@keyframes movexa-scope-blob-b {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(-8%, -5%) scale(1.06); }
}

@keyframes movexa-scope-blob-c {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(5%, -7%) scale(0.94); }
}

@keyframes movexa-scope-glow-in {
    0% {
        opacity: 0;
        transform: scale(0.85);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes movexa-scope-dot-pulse {
    0%, 100% {
        opacity: 0.35;
        transform: scale(0.85);
    }
    50% {
        opacity: 1;
        transform: scale(1);
    }
}

@media (prefers-reduced-motion: reduce) {
    .movexa-scope-switch__curtain,
    .movexa-scope-switch__card,
    .movexa-scope-switch__pill,
    .movexa-scope-switch__title,
    .movexa-scope-switch__subtitle,
    .movexa-scope-switch__dots,
    .movexa-scope-switch__icon,
    .movexa-scope-switch__ring,
    .movexa-scope-switch__ripple,
    .movexa-scope-switch__glow {
        animation: none !important;
        transform: none !important;
        opacity: 1 !important;
        filter: none !important;
    }

    .movexa-scope-switch__blob,
    .movexa-scope-switch__dots > span {
        animation: none !important;
    }
}

.movexa-admin-drawer-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    background: rgba(99, 102, 241, 0.12);
    border: 1px solid rgba(99, 102, 241, 0.28);
    color: var(--movexa-on-surface-variant);
}

.movexa-admin-drawer .mud-nav-menu {
    padding: 0.5rem 0.75rem 1rem;
}

.movexa-admin-drawer .mud-nav-link {
    border-radius: 10px;
    margin-bottom: 0.1rem;
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
    align-items: center;
}

.movexa-admin-drawer .mud-nav-link i.fa-solid {
    width: 1.15em;
    text-align: center;
    margin-inline-end: 0.4rem;
}

/* Clay nav icons — same soft-3D language as mobile TabBar */
.movexa-admin-drawer .mud-nav-link .mud-nav-link-text {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
}

.movexa-admin-drawer .movexa-clay-nav-icon {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 1px 1px rgba(15, 23, 42, 0.12));
}

.movexa-admin-drawer .movexa-nav-group > .mud-nav-link > .mud-nav-link-text {
    font-weight: 400;
}

.movexa-admin-drawer .movexa-nav-group .mud-navmenu .mud-nav-item .mud-nav-link .movexa-clay-nav-icon {
    width: 26px;
    height: 26px;
}

.movexa-admin-drawer .movexa-nav-group > .mud-nav-link .mud-nav-link-expand-icon {
    flex-shrink: 0;
    margin-inline-start: 0.15rem;
    font-size: 1.25rem;
    width: 1.25rem;
    height: 1.25rem;
}

.movexa-admin-drawer .movexa-nav-group .mud-navmenu .mud-nav-item .mud-nav-link {
    padding-inline-start: 1.75rem;
}

.movexa-page-header {
    row-gap: 0.75rem;
    column-gap: 1rem;
    margin-bottom: 1.75rem;
}

.movexa-page-header__identity {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    min-width: 0;
}

.movexa-page-header__leading {
    flex-shrink: 0;
}

.movexa-page-header__clay-icon {
    width: 44px;
    height: 44px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 2px 4px rgba(15, 23, 42, 0.14));
}

.movexa-clay-tab {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    white-space: nowrap;
}

.movexa-clay-tab__label {
    line-height: 1.2;
}

.movexa-clay-tab-icon,
.movexa-admin-layout .mud-tab .movexa-clay-nav-icon.movexa-clay-tab-icon {
    width: 26px;
    height: 26px;
    flex-shrink: 0;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 1px 1px rgba(15, 23, 42, 0.12));
}

.movexa-admin-layout .mud-tabs-tabbar .mud-tab {
    gap: 0.15rem;
}

.movexa-page-header__titles {
    min-width: 0;
}

.movexa-tenant-logo--page-header {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--movexa-muted-fill);
    padding: 4px;
    object-fit: contain;
}

.movexa-tenant-logo--page-header-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--movexa-on-surface);
}

.movexa-form-section__label {
    display: block;
    letter-spacing: 0.08em;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.movexa-slug-preview {
    display: flex;
    align-items: flex-start;
    gap: 0.35rem;
    padding: 0.65rem 0.85rem;
    border-radius: 10px;
    background: rgba(99, 102, 241, 0.08);
    border: 1px solid rgba(99, 102, 241, 0.22);
    color: var(--movexa-on-surface-variant);
}

.movexa-slug-preview code {
    color: var(--movexa-on-surface);
}

.movexa-form-actions {
    border-top: 1px solid var(--movexa-glass-border);
}

.movexa-password-rules {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    background: var(--movexa-muted-fill);
    border: 1px solid var(--movexa-glass-border);
}

.movexa-password-rules__title {
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 0.25rem;
    color: var(--movexa-on-surface-variant);
}

.movexa-password-rules__item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    line-height: 1.35;
    transition: color var(--movexa-motion-fast) var(--movexa-ease);
}

.movexa-password-rules__item--met {
    color: #34D399;
}

.movexa-password-rules__item--pending {
    color: var(--movexa-on-surface-variant);
}

@media (min-width: 960px) {
    .movexa-admin-layout {
        --movexa-admin-content-x: 1.5rem;
        --movexa-admin-content-top: 1.5rem;
    }
}

.movexa-zone-map-host {
    position: relative;
    width: 100%;
    min-height: 420px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--movexa-glass-border);
    margin-bottom: 0.5rem;
    background: var(--movexa-map-host-bg);
}

.movexa-zone-map-host > body {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    margin: 0 !important;
    overflow: hidden !important;
}

.movexa-zone-map-host .leaflet-container {
    min-height: 420px;
    width: 100% !important;
    border-radius: 12px;
}

.mud-dialog .movexa-zone-map-host {
    min-height: 420px;
}

/* Map tile dimming only in dark shells (Admin + AppClient) */
.movexa-theme-dark .leaflet-tile-pane {
    filter: brightness(0.72) contrast(1.15) saturate(0.65);
}

.movexa-theme-light .leaflet-tile-pane {
    filter: none;
}

/* Light chrome: glass overrides Mud AppBar primary+white-text → white-on-white.
   Force readable ink on appbar, drawer, and glass panels. */
.movexa-theme-light .mud-appbar.movexa-glass-panel,
.movexa-theme-light .mud-appbar.movexa-appbar--map,
.movexa-theme-light .mud-appbar {
    color: var(--movexa-on-surface) !important;
}

.movexa-theme-light .mud-appbar .mud-typography,
.movexa-theme-light .mud-appbar .mud-button-root,
.movexa-theme-light .mud-appbar .mud-icon-button,
.movexa-theme-light .mud-appbar .mud-icon-root,
.movexa-theme-light .mud-appbar a {
    color: inherit !important;
}

.movexa-theme-light .movexa-admin-drawer,
.movexa-theme-light .movexa-admin-drawer .mud-nav-link,
.movexa-theme-light .movexa-admin-drawer .mud-typography,
.movexa-theme-light .movexa-admin-drawer .mud-icon-root {
    color: var(--movexa-on-surface);
}

.movexa-theme-light .movexa-admin-drawer .mud-nav-link .mud-nav-link-text,
.movexa-theme-light .movexa-admin-drawer-brand__subtitle,
.movexa-theme-light .movexa-admin-downloads__hint,
.movexa-theme-light .movexa-admin-downloads__notice {
    color: var(--movexa-on-surface-variant) !important;
}

.movexa-theme-light .movexa-glass-panel {
    color: var(--movexa-on-surface);
}

.movexa-theme-light .movexa-portal-banner__title,
.movexa-theme-light .movexa-portal-banner {
    color: var(--movexa-on-surface);
}

/* Status badges: pastel-on-dark fails on light surfaces */
.movexa-theme-light .movexa-fleet-badge--gps-on {
    color: #166534;
    background: rgba(22, 163, 74, 0.12);
    border-color: rgba(22, 163, 74, 0.35);
}

.movexa-theme-light .movexa-fleet-badge--gps-off {
    color: #c2410c;
    background: rgba(234, 88, 12, 0.12);
    border-color: rgba(234, 88, 12, 0.35);
}

.movexa-theme-light .movexa-fleet-badge--app-on {
    color: #3730a3;
    background: rgba(99, 102, 241, 0.12);
    border-color: rgba(99, 102, 241, 0.35);
}

.movexa-theme-light .movexa-active-trip-badge--assigned {
    color: #1d4ed8;
    background: rgba(37, 99, 235, 0.12);
    border-color: rgba(37, 99, 235, 0.35);
}

.movexa-theme-light .movexa-active-trip-badge--accepted {
    color: #6d28d9;
    background: rgba(124, 58, 237, 0.12);
    border-color: rgba(124, 58, 237, 0.35);
}

.movexa-theme-light .movexa-active-trip-badge--started {
    color: #047857;
    background: rgba(16, 185, 129, 0.12);
    border-color: rgba(16, 185, 129, 0.35);
}

.movexa-theme-light .movexa-password-rules__item--met {
    color: #047857;
}

/* Muted copy must NOT use Mud Color.Secondary (tenant brand accent). */
.movexa-muted-text {
    color: var(--movexa-on-surface-variant) !important;
}

/* Warning yellow (#FBBF24) fails AA on light surfaces — keep dark palette bright. */
.movexa-theme-light .mud-button-outlined-warning,
.movexa-theme-light .mud-button-text-warning,
.movexa-theme-light .mud-chip-outlined-warning,
.movexa-theme-light .mud-typography-warning,
.movexa-theme-light .mud-icon-root.mud-warning-text {
    color: #a16207 !important;
}

.movexa-theme-light .mud-button-outlined-warning {
    border-color: #a16207 !important;
}

.movexa-theme-light .mud-input-label,
.movexa-theme-light .mud-input-helper-text {
    color: var(--movexa-on-surface-variant);
}

.movexa-theme-light .mud-table-cell {
    color: var(--movexa-on-surface);
}

/* Captions/body that used Color.Secondary as "muted" — brand Secondary is not muted ink. */
.movexa-theme-light .mud-typography-body1.mud-secondary-text,
.movexa-theme-light .mud-typography-body2.mud-secondary-text,
.movexa-theme-light .mud-typography-caption.mud-secondary-text,
.movexa-theme-light .mud-typography-overline.mud-secondary-text,
.movexa-theme-light .mud-typography-subtitle2.mud-secondary-text {
    color: var(--movexa-on-surface-variant) !important;
}

.movexa-help-inline {
    display: inline-flex;
    align-items: center;
    gap: 0.1rem;
    min-width: 0;
}

.movexa-help-field {
    display: flex;
    align-items: flex-start;
    gap: 0.1rem;
    min-width: 0;
}

.movexa-help-field .mud-input-control,
.movexa-help-field .mud-select,
.movexa-help-field .mud-autocomplete {
    flex: 1 1 auto;
    min-width: 0;
}

.movexa-help-switch {
    display: flex;
    align-items: center;
    gap: 0.15rem;
}

.movexa-help-switch > .mud-switch,
.movexa-help-switch > .mud-checkbox {
    flex: 1 1 auto;
    min-width: 0;
}

.movexa-help-icon {
    margin-top: 0.35rem;
    flex: 0 0 auto;
    cursor: help;
}

.movexa-help-inline .movexa-help-icon,
.movexa-help-switch .movexa-help-icon {
    margin-top: 0;
}

.movexa-help-tooltip {
    max-width: 22rem;
    white-space: normal;
    line-height: 1.45;
}

/* —— Table toolbar (search + filters + export) —— */
.movexa-table-toolbar__row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.75rem 1rem;
}

.movexa-table-toolbar__search {
    flex: 1 1 16rem;
    min-width: 12rem;
    max-width: 20rem;
}

.movexa-table-toolbar__filters {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.75rem;
    flex: 1 1 auto;
    min-width: 0;
}

.movexa-table-toolbar__filters > .mud-input-control,
.movexa-table-toolbar__filters .mud-input-control {
    margin-top: 0;
}

/* Alinear selects/pickers del filtro con el search (Margin.Dense ≈ 40px) */
.movexa-table-toolbar__filters .mud-input.mud-input-outlined {
    min-height: 40px;
}

.movexa-table-toolbar__filters .mud-input-control:not(.mud-input-control-margin-dense) .mud-input-slot,
.movexa-table-toolbar__filters .mud-input-control:not(.mud-input-control-margin-dense) .mud-select-input {
    padding-top: 8px;
    padding-bottom: 8px;
}

.movexa-table-toolbar__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.5rem;
    flex: 0 0 auto;
    margin-left: auto;
    padding-bottom: 0.15rem;
}

.movexa-table-toolbar__field--status {
    min-width: 9.5rem;
    max-width: 12rem;
}

.movexa-table-toolbar__field--date {
    min-width: 9rem;
    max-width: 10.5rem;
}

.movexa-table-toolbar__field--company {
    min-width: 11rem;
    max-width: 16rem;
    flex: 1 1 11rem;
}

.movexa-table-toolbar__field--modality {
    min-width: 10rem;
    max-width: 14rem;
}

@media (max-width: 599.98px) {
    .movexa-table-toolbar__search {
        flex: 1 1 100%;
        max-width: none;
    }

    .movexa-table-toolbar__filters {
        flex: 1 1 100%;
    }

    .movexa-table-toolbar__filters > * {
        flex: 1 1 calc(50% - 0.4rem);
        min-width: 0 !important;
        max-width: none !important;
    }

    .movexa-table-toolbar__actions {
        margin-left: 0;
        width: 100%;
    }
}