/* ============================================================
   CalculosElectricos - Global Styles
   Sistema tipografico: Fraunces (display serif) + Geist (body sans)
   ============================================================ */

:root {
    --font-display: 'IBM Plex Mono', ui-monospace, 'Cascadia Mono', Consolas, 'Courier New', monospace;
    --font-body: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'IBM Plex Mono', ui-monospace, 'Cascadia Mono', Consolas, monospace;
}

html, body {
    font-family: var(--font-body);
    font-size: 15px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: "cv11", "ss01", "ss03";
}

/* Headings: typewriter mono — tracking neutro o leve negativo (mono no necesita el agresivo de un serif) */
h1, h2, h3, h4, h5, h6,
.mud-typography-h1, .mud-typography-h2, .mud-typography-h3,
.mud-typography-h4, .mud-typography-h5, .mud-typography-h6 {
    font-family: var(--font-display) !important;
    font-weight: 500 !important;
    letter-spacing: -0.01em;
    line-height: 1.2;
}

.mud-typography-h1, h1 {
    font-weight: 600 !important;
    letter-spacing: -0.02em;
}

.mud-typography-h2, .mud-typography-h3, h2, h3 {
    font-weight: 600 !important;
    letter-spacing: -0.015em;
}

.mud-typography-h5, .mud-typography-h6, h5, h6 {
    font-weight: 500 !important;
    letter-spacing: 0;
}

/* Brand del header en typewriter */
.app-brand-display {
    font-family: var(--font-display) !important;
    font-weight: 600 !important;
    letter-spacing: -0.02em;
}

/* Eyebrow / overline: caps espaciadas en body sans */
.eyebrow {
    font-family: var(--font-body);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: var(--mud-palette-text-secondary);
}

/* Labels and captions */
.mud-typography-caption,
.mud-input-label,
label {
    font-size: 12px !important;
    letter-spacing: 0.01em;
    font-family: var(--font-body);
}

/* Body text — sin serif, peso 400 */
.mud-typography-body1 {
    font-size: 15px;
    font-family: var(--font-body);
}

.mud-typography-body2 {
    font-size: 14px;
    font-family: var(--font-body);
}

/* Buttons en body sans, peso 500, tracking neutral */
.mud-button {
    font-family: var(--font-body) !important;
    font-weight: 500 !important;
    letter-spacing: 0 !important;
    text-transform: none !important;
}

/* ── Page-load stagger reveal ── */
@keyframes fade-up {
    from { opacity: 0; transform: translateY(14px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.reveal-up {
    opacity: 0;
    animation: fade-up 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.reveal-in {
    opacity: 0;
    animation: fade-in 0.9s ease-out forwards;
}

.reveal-d1 { animation-delay: 0.08s; }
.reveal-d2 { animation-delay: 0.18s; }
.reveal-d3 { animation-delay: 0.30s; }
.reveal-d4 { animation-delay: 0.44s; }
.reveal-d5 { animation-delay: 0.60s; }
.reveal-d6 { animation-delay: 0.78s; }

@media (prefers-reduced-motion: reduce) {
    .reveal-up, .reveal-in {
        opacity: 1;
        animation: none;
    }
}

/* ════════════════════════════════════════════════════════════
   SHARED PAGE SYSTEM — page-head, form-card, settings-card.
   Tokens reutilizables por todas las pantallas internas.
   ════════════════════════════════════════════════════════════ */

/* PAGE HEAD: titulo + eyebrow + atmosphere */
.page-head {
    position: relative; overflow: hidden; isolation: isolate;
    margin: -8px -8px 32px;
    padding: 36px 28px;
    border-radius: 16px;
    background: var(--mud-palette-surface);
    border: 1px solid var(--mud-palette-divider);
}

.page-head-atmos {
    position: absolute; inset: 0; pointer-events: none; z-index: 0;
    background:
        radial-gradient(ellipse 70% 80% at 95% 10%, rgba(204, 120, 92, 0.10) 0%, transparent 60%),
        radial-gradient(ellipse 50% 60% at 0% 100%, rgba(245, 166, 35, 0.05) 0%, transparent 60%);
}

.mud-theme-dark .page-head-atmos {
    background:
        radial-gradient(ellipse 70% 80% at 95% 10%, rgba(204, 120, 92, 0.20) 0%, transparent 60%),
        radial-gradient(ellipse 50% 60% at 0% 100%, rgba(245, 166, 35, 0.08) 0%, transparent 60%);
}

.page-head-inner {
    position: relative; z-index: 1;
}

.page-head-row {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-areas: "text cta" "stats cta";
    gap: 24px 32px;
    align-items: center;
}

.page-head-with-back {
    display: grid;
    grid-template-columns: 48px 1fr;
    gap: 12px; align-items: start;
}

.page-back-btn {
    margin-top: 6px !important;
    border: 1px solid var(--mud-palette-divider) !important;
    border-radius: 10px !important;
}

.page-eyebrow {
    font-family: var(--font-body);
    font-size: 11px; font-weight: 600;
    text-transform: uppercase; letter-spacing: 0.16em;
    color: var(--mud-palette-primary);
    margin-bottom: 10px;
}

.page-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 500; letter-spacing: -0.035em; line-height: 1;
    color: var(--mud-palette-text-primary);
    margin: 0 0 8px;
}

.page-subtitle {
    font-family: var(--font-body); font-size: 15px;
    color: var(--mud-palette-text-secondary); margin: 0;
    max-width: 640px;
}

.page-head-stats {
    grid-area: stats;
    display: flex; gap: 36px; margin: 0;
    padding-top: 18px;
    border-top: 1px solid var(--mud-palette-divider);
}

.head-stat dt {
    font-family: var(--font-display); font-size: 1.6rem;
    font-weight: 500; line-height: 1;
    color: var(--mud-palette-primary);
    margin: 0 0 4px;
}

.head-stat dd {
    font-family: var(--font-body); font-size: 12px;
    color: var(--mud-palette-text-secondary); margin: 0;
}

.page-head-cta {
    grid-area: cta;
    padding: 12px 22px !important; font-weight: 500 !important;
    box-shadow: 0 8px 20px -8px rgba(204, 120, 92, 0.5) !important;
}

.page-head-cta:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 12px 28px -8px rgba(204, 120, 92, 0.7) !important;
}

@media (max-width: 599px) {
    .page-head { padding: 24px 20px; }
    .page-head-row {
        grid-template-columns: 1fr;
        grid-template-areas: "text" "stats" "cta";
    }
    .page-head-cta { width: 100%; }
    .page-head-stats { gap: 24px; flex-wrap: wrap; }
}

/* PAGE LOADING + EMPTY */
.page-loading { display: flex; justify-content: center; padding: 64px 0; }

.page-empty {
    display: flex; flex-direction: column; align-items: center;
    text-align: center; padding: 64px 24px 80px;
    max-width: 520px; margin: 0 auto;
}

.empty-mark {
    width: 88px; height: 88px; border-radius: 22px;
    background: linear-gradient(135deg, rgba(204, 120, 92, 0.12), rgba(245, 166, 35, 0.08));
    border: 1px solid var(--mud-palette-divider);
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 28px;
}
.empty-mark .mud-icon-root { font-size: 40px; color: var(--mud-palette-primary); }

.empty-title {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 3.8vw, 2.4rem);
    font-weight: 500; letter-spacing: -0.03em; line-height: 1.1;
    margin: 0 0 12px;
}

.empty-lead {
    font-family: var(--font-body); font-size: 15px; line-height: 1.55;
    color: var(--mud-palette-text-secondary);
    margin: 0 0 28px; max-width: 440px;
}

.empty-cta { padding: 14px 28px !important; }

/* FORM CARD: para pages tipo NuevoProyecto, EditarProyecto, NuevaInspeccion */
.form-card {
    background: var(--mud-palette-surface);
    border: 1px solid var(--mud-palette-divider);
    border-radius: 14px;
    padding: 28px;
    margin-bottom: 20px;
}

.form-card-head {
    display: grid; grid-template-columns: 48px 1fr;
    gap: 16px; align-items: start;
    margin-bottom: 24px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--mud-palette-divider);
}

.form-card-num {
    font-family: var(--font-display);
    font-size: 1.8rem; font-weight: 500; font-style: italic;
    color: var(--mud-palette-primary);
    line-height: 1; padding-top: 4px;
}

.form-card-title {
    font-family: var(--font-display); font-size: 1.25rem;
    font-weight: 500; letter-spacing: -0.02em;
    margin: 0 0 4px;
}

.form-card-sub {
    font-family: var(--font-body); font-size: 13px;
    color: var(--mud-palette-text-secondary); margin: 0;
}

@media (max-width: 599px) {
    .form-card { padding: 22px 20px; }
}

/* Auxiliary italic (referenced in many pages) */
.hero-italic {
    font-style: italic;
    color: var(--mud-palette-primary);
    font-weight: 400;
}

/* ════════════════════════════════════════════════════════════
   APP-SECTION: wrapper opt-in para hacer que MudPaper o blocks
   internos se vean como form-card sin restructurar markup.
   Para pantallas grandes (Detalles, Calculo, etc.) donde
   no podemos reescribir el HTML completo.
   ════════════════════════════════════════════════════════════ */
.app-section {
    background: var(--mud-palette-surface) !important;
    border: 1px solid var(--mud-palette-divider) !important;
    border-radius: 14px !important;
    padding: 24px !important;
    margin-bottom: 18px !important;
    box-shadow: none !important;
}

.app-section > .mud-typography-h6:first-child,
.app-section > h6:first-child {
    font-family: var(--font-display) !important;
    font-size: 1.25rem !important;
    font-weight: 500 !important;
    letter-spacing: -0.02em !important;
    color: var(--mud-palette-text-primary) !important;
    margin: 0 0 18px !important;
    padding-bottom: 14px !important;
    border-bottom: 1px solid var(--mud-palette-divider) !important;
}

/* Estiliza MudExpansionPanels dentro de pantallas deep para que se
   vean como form-cards: bordes redondeados, fondo neutro, headers
   con tipografia serif. */
.app-deep .mud-expansion-panels {
    background: transparent !important;
    box-shadow: none !important;
}

.app-deep .mud-expansion-panel {
    background: var(--mud-palette-surface) !important;
    border: 1px solid var(--mud-palette-divider) !important;
    border-radius: 12px !important;
    margin-bottom: 10px !important;
    box-shadow: none !important;
    overflow: hidden;
}

.app-deep .mud-expansion-panel::before { display: none !important; }

.app-deep .mud-expansion-panel-header {
    padding: 18px 20px !important;
    transition: background-color .15s ease !important;
}

.app-deep .mud-expansion-panel-header:hover {
    background-color: rgba(204, 120, 92, 0.04) !important;
}

.app-deep .mud-expansion-panel-header .mud-typography-subtitle1,
.app-deep .mud-expansion-panel-header .mud-typography-h6,
.app-deep .mud-expansion-panel-text {
    font-family: var(--font-display) !important;
    font-weight: 500 !important;
    letter-spacing: -0.015em !important;
}

.app-deep .mud-expansion-panel-content {
    padding: 0 20px 20px !important;
}

/* MudPaper interno dentro de .app-deep que sea section (no card de data) */
.app-deep > .mud-paper:not(.mud-card):not(.mud-expansion-panel) {
    background: var(--mud-palette-surface) !important;
    border: 1px solid var(--mud-palette-divider) !important;
    border-radius: 14px !important;
    box-shadow: none !important;
    padding: 24px !important;
}

/* ════════════════════════════════════════════════════════════
   MOBILE DRAWER (hamburger menu) — design language
   ════════════════════════════════════════════════════════════ */
.nav-drawer-mobile {
    width: 280px !important;
    border-right: 1px solid var(--mud-palette-divider);
}

.nav-drawer-mobile .nav-drawer-head {
    padding: 24px 20px 18px !important;
    border-bottom: 1px solid var(--mud-palette-divider);
}

.nav-drawer-mobile .mud-navmenu {
    padding: 16px 12px;
}

.nav-drawer-mobile .mud-nav-link {
    border-radius: 10px;
    margin-bottom: 4px;
    padding: 11px 14px !important;
    font-family: var(--font-body) !important;
    font-weight: 500 !important;
    font-size: 14px !important;
    transition: background-color .15s ease;
}

.nav-drawer-mobile .mud-nav-link:hover {
    background-color: rgba(204, 120, 92, 0.08) !important;
}

.nav-drawer-mobile .mud-nav-link.active {
    background-color: rgba(204, 120, 92, 0.12) !important;
    color: var(--mud-palette-primary) !important;
}

.nav-drawer-mobile .mud-nav-link.active .mud-nav-link-icon {
    color: var(--mud-palette-primary) !important;
}

.nav-drawer-mobile .mud-nav-group .mud-nav-link {
    padding-left: 14px !important;
}

.nav-drawer-mobile .mud-nav-group > .mud-nav-link {
    font-weight: 600 !important;
}

/* ── En mobile con sticky action bar, agregar padding-bottom al
   shell del layout para que el footer quede ARRIBA del action bar
   en vez de tapado por él. */
@media (max-width: 599px) {
    .app-page-shell:has(.det-mobile-actions),
    .app-page-shell:has(.calc-mobile-actions),
    .app-page-shell:has(.circ-mobile-actions) {
        padding-bottom: 140px;
    }
}

/* MudAlert dentro de app-deep: más editorial */
.app-deep .mud-alert {
    border-radius: 12px !important;
    border-left-width: 3px !important;
}

/* ── Mobile fixes para .app-deep ──
   El problema: MudStack Row tiene flex-wrap: nowrap por default. Eso comprime
   los items en columnas verticales narrow cuando el contenido excede el ancho.
   Solucion: forzar wrap + impedir shrink de chips/iconos. */
@media (max-width: 599px) {
    .app-deep .mud-expansion-panel-content {
        padding: 0 14px 14px !important;
    }

    /* Stacks Row dentro de app-deep cards: wrap + GAP REAL (no margins).
       MudStack usa margins para spacing, lo cual compoundea y solapa cuando
       hay flex-wrap. Reseteamos los margins y usamos CSS gap. */
    .app-deep .mud-stack-row {
        flex-wrap: wrap !important;
        gap: 8px !important;
    }
    .app-deep .mud-stack-row > * {
        margin: 0 !important;
    }

    /* Texto en stacks: GROW para tomar el ancho disponible — sin esto,
       el texto se exprime a min-content (1 palabra por linea) cuando los
       chips al lado tienen flex-shrink: 0. */
    .app-deep .mud-stack-row > .mud-typography,
    .app-deep .mud-stack-row > .mud-text,
    .app-deep .mud-stack-row .mud-text {
        flex: 1 1 auto;
        min-width: 140px;
        word-break: break-word;
        overflow-wrap: anywhere;
    }

    /* Chips: no encoger Y NO crecer — toman natural width.
       Cuando text llega a min-width: 140 y chips no caben, wrap. */
    .app-deep .mud-chip {
        flex: 0 0 auto !important;
    }

    /* Iconos: tamaño fijo */
    .app-deep .mud-stack-row .mud-icon-root,
    .app-deep .mud-stack-row .mud-icon-button {
        flex: 0 0 auto !important;
    }

    /* Chip content: inline, no rompe vertical */
    .app-deep .mud-chip .mud-chip-content {
        white-space: nowrap;
    }
}

/* ── Global Border Radius ── */
.mud-card,
.mud-paper,
.mud-expansion-panel,
.mud-dialog .mud-dialog-content,
.mud-alert {
    border-radius: 12px !important;
}

/* ── Chips - Rectangular style ── */
.mud-chip,
.mud-chip.mud-chip-filled,
.mud-chip.mud-chip-outlined,
.mud-chip.mud-chip-text,
.mud-chip.mud-chip-size-small,
.mud-chip.mud-chip-size-medium,
.mud-chip.mud-chip-size-large,
span.mud-chip {
    border-radius: 6px !important;
}

.mud-button,
.mud-icon-button,
.mud-fab {
    border-radius: 8px !important;
}

.mud-input,
.mud-input-control .mud-input-slot,
.mud-select .mud-input-slot {
    border-radius: 8px !important;
}

/* ── Shadows ── */
.mud-theme-light .mud-card,
.mud-theme-light .mud-paper:not(.mud-paper-outlined) {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.06) !important;
}

.mud-theme-dark .mud-card,
.mud-theme-dark .mud-paper:not(.mud-paper-outlined) {
    box-shadow: none !important;
}

/* ── Transitions ── */
.mud-button,
.mud-icon-button,
.mud-fab,
.mud-card,
.mud-chip,
.mud-list-item {
    transition: all 0.15s ease-in-out !important;
}

.mud-button:hover,
.mud-icon-button:hover,
.mud-fab:hover {
    transform: translateY(-1px);
}

.mud-card:hover {
    transform: translateY(-2px);
}

/* ── Global Spacing ── */
.mud-main-content {
    padding: 24px 32px !important;
}

@media (max-width: 599px) {
    .mud-main-content {
        padding: 16px !important;
    }
}

/* ── Form Controls — touch targets razonables ── */
.mud-input-control {
    min-height: 40px;
}

.mud-input-slot {
    min-height: 40px !important;
}

.mud-select .mud-input-slot {
    min-height: 40px !important;
}

/* Forzar Geist (body sans) en inputs — IBM Plex Mono se ve gigante en
   text fields, especialmente con texto largo (emails, descripciones) */
.mud-input input,
.mud-input textarea,
.mud-select-input,
.mud-input-slot input {
    font-family: var(--font-body) !important;
}

/* ── Mobile Buttons ── */
@media (max-width: 599px) {
    .mobile-full-width {
        width: 100% !important;
    }

    .mobile-btn-lg {
        min-height: 48px !important;
        font-size: 16px !important;
    }

    /* Fixed action buttons at bottom */
    .mobile-action-bar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        padding: 12px 16px;
        background: var(--mud-palette-surface);
        border-top: 1px solid var(--mud-palette-divider);
        z-index: 100;
    }

    .mobile-action-bar .mud-button {
        min-height: 48px !important;
        width: 100%;
    }
}

/* ── Cards - Full Width on Mobile ── */
@media (max-width: 599px) {
    .mud-grid-item.xs-12 {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }

    .project-card-grid .mud-card {
        border-radius: 0 !important;
        margin-left: -16px;
        margin-right: -16px;
        width: calc(100% + 32px);
    }
}

/* ── Chips - Truncation ── */
.chip-truncate .mud-chip-content {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 599px) {
    .chip-truncate .mud-chip-content {
        max-width: 100px;
    }
}

/* ── Tables - Horizontal Scroll ── */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table-responsive .mud-table {
    min-width: 600px;
}

/* ── Navigation Drawer ── */
.nav-drawer {
    width: 280px !important;
}

.nav-drawer .mud-navmenu {
    padding: 16px;
}

.nav-drawer .mud-nav-link {
    border-radius: 8px;
    margin-bottom: 4px;
    padding: 12px 16px;
}

/* ── Desktop nav links (hidden on mobile) ── */
@media (max-width: 959px) {
    .desktop-nav-links {
        display: none !important;
    }
}

@media (min-width: 960px) {
    .mobile-menu-btn {
        display: none !important;
    }

    .nav-drawer {
        display: none !important;
    }
}

/* ── Chat Widget - Full Width on Mobile ── */
@media (max-width: 599px) {
    .ai-chat-drawer {
        width: 100% !important;
    }
}

/* ── Expansion Panels ── */
.mud-expansion-panel {
    margin-bottom: 8px !important;
}

.mud-expansion-panel::before {
    display: none !important;
}

.mud-expansion-panel-header {
    padding: 16px !important;
}

/* ── MudContainer override for consistent padding ── */
.mud-container {
    padding-left: 24px !important;
    padding-right: 24px !important;
}

@media (max-width: 599px) {
    .mud-container {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* ── Form layouts - Single column on mobile ── */
@media (max-width: 599px) {
    .mobile-form .mud-grid-item {
        flex-basis: 100% !important;
        max-width: 100% !important;
    }
}

/* ── Alert styling ── */
.mud-alert {
    border-radius: 12px !important;
}

/* ── Dialog styling ── */
.mud-dialog {
    border-radius: 16px !important;
}

.mud-dialog .mud-dialog-title {
    padding: 20px 24px 12px !important;
}

.mud-dialog .mud-dialog-content {
    padding: 0 24px 20px !important;
}

.mud-dialog .mud-dialog-actions {
    padding: 12px 24px 20px !important;
}

/* ── Snackbar styling ── */
.mud-snackbar {
    border-radius: 12px !important;
}

/* ── Loading states ── */
.loading-skeleton {
    animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* ── Legacy Bootstrap overrides ── */
a, .btn-link {
    color: #cc785c;
}

.btn-primary {
    color: #fff;
    background-color: #cc785c;
    border-color: #cc785c;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #cc785c;
}

.content {
    padding-top: 1.1rem;
}

/* Eliminar el outline de focus en titulos. Los headings no son interactivos
   y el screen reader los anuncia sin necesidad de outline visual. El browser
   auto-focusea el h1 al navegar entre paginas (Blazor Enhanced Navigation),
   lo que mostraba un rectangulo azul feo arriba del titulo. */
h1, h2, h3, h4, h5, h6,
.page-title, .empty-title, .transition-title,
.section-title, .hero-headline, .feature-featured-title,
.tool-section-title, .form-card-title, .settings-card-title,
.cta-final-title, .herram-cta-title, .ai-title,
.mud-typography-h1, .mud-typography-h2, .mud-typography-h3,
.mud-typography-h4, .mud-typography-h5, .mud-typography-h6 {
    outline: none !important;
}

h1:focus, h2:focus, h3:focus,
.page-title:focus, .empty-title:focus {
    outline: none !important;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

.blazor-error-boundary::after {
    content: "An error has occurred."
}

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ── Cursor pointer for clickable cards ── */
.cursor-pointer {
    cursor: pointer;
}

/* ── Panel Designer ── */
.pd-rail-wrapper { margin-bottom: 24px; overflow-x: auto; }
.pd-occ-bar-track { height: 4px; background: #21262d; border-radius: 2px; margin-top: 6px; }
.pd-occ-bar-fill { height: 4px; background: #238636; border-radius: 2px; transition: width 0.2s; }
.pd-lib-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 4px;
    margin-bottom: 4px;
    cursor: grab;
    background: var(--mud-palette-background-grey);
    border: 1px solid var(--mud-palette-lines-default);
}
.pd-lib-item:active { cursor: grabbing; }
.pd-lib-dot {
    width: 10px;
    height: 20px;
    border-radius: 2px;
    flex-shrink: 0;
}
