/* --- Digital Obsidian Refinements (Standard CSS - Final Force version) --- */

/* Typography Overrides (Global) */
h1, h2, h3, h4, h5, h6, .panel-title, .modal-header h2 {
    font-family: 'Lexend', sans-serif !important;
    font-weight: 800 !important;
    letter-spacing: -0.02em !important;
}

.tech-font, .v-tag, .badge, .status-badge, .ip-val, .label-md, .stat-value {
    font-family: 'Geist Mono', monospace !important;
    font-weight: 500 !important;
}

/* ────────────────────────────────────────────────────────────────────────── */
/* DARK MODE REFINEMENTS */
/* ────────────────────────────────────────────────────────────────────────── */

[data-theme="dark"] .dashboard-header, 
:root:not([data-theme="light"]) .dashboard-header {
    background: var(--obsidian-glass-bg) !important;
    backdrop-filter: var(--obsidian-glass-blur) !important;
    -webkit-backdrop-filter: var(--obsidian-glass-blur) !important;
    border: 1px solid var(--obsidian-outline-variant) !important;
    box-shadow: var(--obsidian-shadow-ambient) !important;
    padding: 0.45rem 1.25rem !important; /* Reducido verticalmente */
}

[data-theme="dark"] .panel, 
:root:not([data-theme="light"]) .panel,
[data-theme="dark"] .detail-card,
:root:not([data-theme="light"]) .detail-card,
[data-theme="dark"] .modal-content,
:root:not([data-theme="light"]) .modal-content {
    background: linear-gradient(135deg, #121a2c 0%, #0b0f19 100%) !important; /* Fondos profundos desaturados slate */
    border: 1px solid var(--obsidian-outline-variant) !important;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.65), 0 0 50px rgba(56, 189, 248, 0.04) !important; /* Sombras radiales azul acero ultra sutiles */
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
}

[data-theme="dark"] #notifications-dropdown, 
:root:not([data-theme="light"]) #notifications-dropdown,
[data-theme="dark"] .apps-dropdown, 
:root:not([data-theme="light"]) .apps-dropdown {
    background: var(--obsidian-surface-high) !important;
    color: var(--obsidian-text-primary) !important;
    border: 1px solid var(--obsidian-outline-variant) !important;
}

/* Custom Select in Dark Mode */
[data-theme="dark"] .custom-option,
:root:not([data-theme="light"]) .custom-option {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
}

/* ────────────────────────────────────────────────────────────────────────── */
/* LIGHT MODE REFINEMENTS */
/* ────────────────────────────────────────────────────────────────────────── */

[data-theme="light"] .dashboard-header {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.03) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.02), 0 1px 3px rgba(0, 0, 0, 0.01) !important;
    padding: 0.45rem 1.25rem !important; /* Reducido verticalmente */
}

/* High Visibility Modals in Light Mode */
[data-theme="light"] .panel, 
[data-theme="light"] .detail-card, 
[data-theme="light"] .login-card,
[data-theme="light"] .modal-content {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.03) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.02), 0 1px 3px rgba(0, 0, 0, 0.01) !important; /* Sombras tridimensionales sutiles */
    backdrop-filter: none !important;
}

[data-theme="light"] #notifications-dropdown,
[data-theme="light"] .apps-dropdown {
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.1) !important;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1) !important;
    color: var(--obsidian-text-primary) !important;
}

[data-theme="light"] .notif-item {
    background: #f8fafc !important;
    border-bottom: 1px solid rgba(0,0,0,0.05) !important;
}

[data-theme="light"] .custom-option {
    background: #ffffff !important;
    color: var(--obsidian-text-primary) !important;
    border-bottom: 1px solid rgba(0,0,0,0.05) !important;
}

/* ────────────────────────────────────────────────────────────────────────── */
/* COMMON REFINEMENTS & FIXES */
/* ────────────────────────────────────────────────────────────────────────── */

.panel, .detail-card, .login-card, .modal-content {
    border-radius: 28px !important;
    transition: var(--theme-transition) !important;
}

/* Fix Sidebar Custom Dropdown (Unified IP Select Clutter) */
.custom-options-list {
    background: var(--obsidian-surface-highest) !important;
    max-height: 400px !important;
    overflow-y: auto !important;
    padding: 8px 0 !important;
    z-index: 10000 !important;
    border: 1px solid var(--obsidian-outline-variant) !important;
    box-shadow: 0 15px 45px rgba(0,0,0,0.4) !important;
}

.custom-option {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    height: auto !important;
    min-height: 58px !important; /* Force space for multiline */
    padding: 12px 20px !important;
    line-height: 1.5 !important;
    font-size: 0.9rem !important;
    white-space: normal !important; /* Force wrap */
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    gap: 12px !important;
}

.custom-option i {
    font-size: 1rem !important;
    flex-shrink: 0 !important;
    width: 24px !important;
    text-align: center !important;
}

.custom-option span {
    flex: 1 !important;
    display: block !important;
}

.custom-option:hover, .custom-option.selected {
    background: var(--obsidian-surface-bright) !important;
    color: var(--obsidian-primary) !important;
}

/* Fix Login Input Overlap (FORCE) */
.login-form .input-group {
    position: relative !important;
    display: flex !important;
    align-items: center !important;
}

/* Specific target for the input to guarantee padding-left */
.login-form .input-group input, 
.login-form .input-group textarea {
    padding-left: 3.5rem !important;
    height: 60px !important; /* Larger premium height */
    font-size: 1rem !important;
}

/* Vertical centering for input icons */
.login-form .input-group .input-icon {
    position: absolute !important;
    left: 1.4rem !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    font-size: 1.1rem !important;
    color: var(--obsidian-text-secondary) !important;
    z-index: 5 !important;
    margin-top: 0 !important;
}

.password-toggle {
    right: 1.25rem !important;
}

/* Table Refinements: Eliminación de bordes internos y adición de padding premium */
.data-table {
    border-collapse: separate !important;
    border-spacing: 0 8px !important; /* Mayor separación vertical de filas */
    width: 100%;
}

.data-table th {
    background: var(--panel-bg) !important;
    border: none !important;
    padding: 1.1rem 1rem !important;
    font-size: 0.78rem !important;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700 !important;
}

.data-table td {
    background: rgba(255, 255, 255, 0.02) !important;
    border: none !important;
    padding: 1rem 1rem !important;
    transition: background 0.25s cubic-bezier(0.4, 0, 0.2, 1), color 0.25s cubic-bezier(0.4, 0, 0.2, 1), border 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Redondear celdas iniciales y finales para mini-tarjetas */
.data-table tbody tr td:first-child {
    border-top-left-radius: 12px !important;
    border-bottom-left-radius: 12px !important;
    border-left: 2px solid transparent !important;
}

.data-table tbody tr td:last-child {
    border-top-right-radius: 12px !important;
    border-bottom-right-radius: 12px !important;
    border-right: 2px solid transparent !important;
}

/* Efecto hover suave de fila flotante con fondo plano y sin bordes laterales */
[data-theme="dark"] .data-table tbody tr:hover td {
    background: rgba(56, 189, 248, 0.05) !important; /* Fondo translúcido azul acero suave */
    color: #ffffff !important;
}

[data-theme="light"] .data-table td {
    background: #ffffff !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.015) !important;
}

[data-theme="light"] .data-table tbody tr:hover td {
    background: rgba(99, 102, 241, 0.05) !important;
    color: var(--obsidian-primary) !important;
}

/* Modal Form High-Visibility Fixes */
.modal-content input, 
.modal-content select, 
.modal-content textarea {
    font-family: 'Geist Mono', monospace !important; /* Simular consola técnica */
    font-size: 0.88rem !important;
    border: 1px solid var(--obsidian-outline-variant) !important;
    color: var(--obsidian-text-primary) !important;
    border-radius: 12px !important;
    padding: 0.8rem 1rem !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
    background: rgba(0, 0, 0, 0.25) !important;
    outline: none !important;
}

/* Light Theme Inputs */
[data-theme="light"] .modal-content input, 
[data-theme="light"] .modal-content select, 
[data-theme="light"] .modal-content textarea {
    background: #f8fafc !important;
    border-color: rgba(0, 0, 0, 0.08) !important;
}

[data-theme="light"] .modal-content input:focus, 
[data-theme="light"] .modal-content select:focus, 
[data-theme="light"] .modal-content textarea:focus {
    background: #ffffff !important;
    border-color: var(--obsidian-primary) !important;
    box-shadow: 0 0 12px rgba(99, 102, 241, 0.15) !important;
}

/* Dark Theme Inputs Focus */
[data-theme="dark"] .modal-content input:focus, 
[data-theme="dark"] .modal-content select:focus, 
[data-theme="dark"] .modal-content textarea:focus,
:root:not([data-theme="light"]) .modal-content input:focus,
:root:not([data-theme="light"]) .modal-content select:focus,
:root:not([data-theme="light"]) .modal-content textarea:focus {
    border-color: var(--obsidian-primary) !important;
    box-shadow: 0 0 12px rgba(56, 189, 248, 0.15) !important; /* Glow azul acero suave */
    background: rgba(0, 0, 0, 0.45) !important;
}

[data-theme="dark"] .modal-content input:read-only,
:root:not([data-theme="light"]) .modal-content input:read-only {
    background: rgba(255, 255, 255, 0.03) !important;
    color: var(--obsidian-text-tertiary) !important;
}

.modal-overlay {
    backdrop-filter: blur(8px) !important;
    -webkit-backdrop-filter: blur(8px) !important;
    background: rgba(0, 0, 0, 0.6) !important;
}

.modal-header {
    border-bottom: 1px solid var(--obsidian-outline-variant) !important;
    margin-bottom: 1.5rem !important;
    padding-bottom: 1rem !important;
}

.modal-header h2 {
    color: var(--obsidian-primary) !important;
}

/* BRAND FOOTER (Theme Aware) */
.brand-footer {
    border-top: 1px solid var(--obsidian-outline-variant) !important;
    background: transparent !important;
    padding: 2rem 0 !important;
}

.attribution-text, .v-tag {
    color: var(--obsidian-text-secondary) !important;
}

/* ────────────────────────────────────────────────────────────────────────── */
/* MAINTENANCE VS WARNING DISTINCTION */
/* ────────────────────────────────────────────────────────────────────────── */

/* Orange-Amber for Maintenance (Screwdriver Wrench) */
.btn-maintenance {
    background: linear-gradient(135deg, #f97316, #ea580c) !important;
    color: white !important;
    border: none !important;
}

.btn-maintenance:hover:not(:disabled) {
    background: linear-gradient(135deg, #fb923c, #f97316) !important;
    box-shadow: 0 5px 15px rgba(249, 115, 22, 0.4) !important;
}

/* Subtle variant for the header action bar */
.btn-icon-subtle.btn-maintenance { 
    color: #f97316 !important; 
    background: rgba(249, 115, 22, 0.1) !important; 
    border-color: rgba(249, 115, 22, 0.2) !important; 
}

.btn-icon-subtle.btn-maintenance:hover:not(:disabled) { 
    background: #f97316 !important; 
    color: white !important; 
}

/* Maintenance Stat Badge in Header */
.stat-maintenance i, 
.stat-maintenance .stat-value {
    color: #f97316 !important;
}

.stat-badge.stat-maintenance:hover {
    background: rgba(249, 115, 22, 0.1) !important;
}

.stat-badge.stat-maintenance.active {
    background: rgba(249, 115, 22, 0.2) !important;
    box-shadow: 0 0 0 1px rgba(249, 115, 22, 0.5) !important;
}

/* ────────────────────────────────────────────────────────────────────────── */
/* PREMIUM INTERACTION GLOWS & AMBIENT SHADOWS */
/* ────────────────────────────────────────────────────────────────────────── */

/* Glow y Transición de Enfoque en Inputs de Búsqueda */
.search-wrapper {
    position: relative;
    border-radius: 9999px !important;
    background: var(--obsidian-surface-lowest) !important;
    border: 1px solid var(--obsidian-outline-variant) !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.search-wrapper:hover {
    border-color: rgba(148, 163, 184, 0.35) !important;
    box-shadow: 0 0 0 0 transparent !important;
}

.search-wrapper:focus-within {
    border-color: rgba(148, 163, 184, 0.45) !important;
    background: var(--obsidian-surface-lowest) !important;
    box-shadow: 0 0 0 3px rgba(148, 163, 184, 0.08) !important;
    transform: none !important;
}

/* Integrar el input interno al contenedor eliminando sus bordes y fondos duplicados */
.search-input-highlight {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    border-radius: 9999px !important;
    outline: none !important;
    padding: 0.8rem 3.5rem 0.8rem 3.8rem !important;
    transition: none !important;
}

.search-input-highlight:hover,
.search-input-highlight:focus {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    transform: none !important;
}

[data-theme="light"] .search-wrapper {
    background: #f1f5f9 !important;
    border-color: rgba(0, 0, 0, 0.07) !important;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.04) !important;
}

[data-theme="light"] .search-wrapper:focus-within {
    border-color: rgba(100, 116, 139, 0.4) !important;
    box-shadow: 0 0 0 3px rgba(100, 116, 139, 0.08) !important;
}

/* Search & Equipment box container */
.connection-hub-highlight {
    background: var(--obsidian-surface-container) !important;
    border: 1px solid rgba(148, 163, 184, 0.1) !important;
    box-shadow: none !important;
    padding: 1.2rem !important;
    border-radius: 18px !important;
    margin-bottom: 1.2rem !important;
    transition: var(--theme-transition) !important;
}

/* Cuando hay estación activa, borde sutil más visible */
.connection-hub-highlight.active-station {
    border-color: rgba(148, 163, 184, 0.2) !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15) !important;
}

/* Modo claro */
[data-theme="light"] .connection-hub-highlight {
    background: #f1f5f9 !important;
    border: 1px solid rgba(148, 163, 184, 0.2) !important;
    box-shadow: inset 0 1px 4px rgba(0, 0, 0, 0.03) !important;
}

[data-theme="light"] .connection-hub-highlight.active-station {
    border-color: rgba(100, 116, 139, 0.3) !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04) !important;
}

/* ========================================================================== */
/* AUDIT & CONNECTION LOG MODAL - PREMIUM REFINEMENTS */
/* ========================================================================== */

/* Modal Content & Layout */
.conn-log-modal-content {
    display: flex;
    flex-direction: column;
    height: auto !important;
    max-height: 85vh !important;
    width: 95vw !important;
    max-width: 1450px !important;
    border-radius: 24px !important;
    border: 1px solid var(--obsidian-outline-strong) !important;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.45) !important;
    overflow: hidden;
}

.conn-log-modal-content .modal-header {
    border-bottom: none !important;
    padding-bottom: 0 !important;
    margin-bottom: 0.6rem !important;
}

[data-theme="light"] .conn-log-modal-content {
    background: #ffffff !important;
    border-color: rgba(0, 0, 0, 0.1) !important;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.12) !important;
}

.conn-log-toolbar {
    margin-bottom: 0.6rem;
    display: flex;
    gap: 0.75rem;
    align-items: center;
    border-bottom: 1px solid var(--obsidian-outline-variant) !important;
    padding-bottom: 0.6rem !important;
    background: transparent !important; /* Asegurar fondo transparente */
}

[data-theme="light"] .conn-log-toolbar {
    background: transparent !important;
    border-bottom-color: rgba(0, 0, 0, 0.05) !important;
}

/* Glowing Search Box */
.conn-log-search-wrap {
    position: relative;
    border-radius: 9999px !important; /* Totalmente redondeado tipo píldora */
    background: rgba(0, 0, 0, 0.25) !important;
    border: 1px solid var(--obsidian-outline-variant);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
}

[data-theme="light"] .conn-log-search-wrap {
    background: #ffffff !important; /* Totalmente blanco para contrastar con el fondo transparente */
    border-color: rgba(0, 0, 0, 0.08) !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02) !important;
}

.conn-log-search-wrap:hover {
    border-color: rgba(59, 130, 246, 0.4);
}

.conn-log-search-wrap:focus-within {
    border-color: #3b82f6;
    box-shadow: 0 0 0 1px #3b82f6, 0 0 20px rgba(59, 130, 246, 0.2);
}

.conn-log-search-icon {
    position: absolute;
    left: 1rem;
    color: var(--obsidian-text-secondary);
    font-size: 0.95rem;
    pointer-events: none;
}

/* Specific target to override global .modal-content input styles */
.conn-log-modal-content .conn-log-search-input,
[data-theme="light"] .conn-log-modal-content .conn-log-search-input,
[data-theme="dark"] .conn-log-modal-content .conn-log-search-input,
.conn-log-modal-content .conn-log-search-input:focus,
[data-theme="light"] .conn-log-modal-content .conn-log-search-input:focus,
[data-theme="dark"] .conn-log-modal-content .conn-log-search-input:focus {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    border-radius: 9999px !important;
    outline: none !important;
}

.conn-log-search-input {
    padding: 0.75rem 1rem 0.75rem 2.8rem !important;
    color: var(--obsidian-text-primary) !important;
    font-size: 0.9rem !important;
    width: 100%;
}

.conn-log-search-clear {
    position: absolute;
    right: 1rem;
    background: transparent;
    border: none;
    color: #64748b;
    cursor: pointer;
    font-size: 1.1rem;
    padding: 0;
    display: flex;
    align-items: center;
    transition: color 0.2s;
}

.conn-log-search-clear:hover {
    color: var(--obsidian-primary);
}

/* Table Wrappers & High-performance Scrollbar */
.conn-log-table-wrap {
    flex: 1;
    overflow-y: auto;
    border-radius: 16px;
    background: rgba(0, 0, 0, 0.15);
    border: 1px solid var(--obsidian-outline-variant);
    max-height: 55vh;
    min-height: 280px !important; /* Evitar colapso vertical en estados vacíos */
}

[data-theme="light"] .conn-log-table-wrap {
    background: #ffffff;
    border-color: rgba(0, 0, 0, 0.08);
}

/* Table layout (Premium Separate Cards System) */
.conn-log-table {
    width: 100%;
    border-collapse: separate !important;
    border-spacing: 0 6px !important; /* Premium vertical spacing between rows */
    text-align: left;
}

.conn-log-table th {
    background: transparent !important;
    color: var(--obsidian-text-secondary);
    padding: 1.1rem 1rem !important;
    font-size: 0.74rem !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    border: none !important;
    border-bottom: 2px solid var(--obsidian-outline-variant) !important;
    user-select: none;
}

[data-theme="light"] .conn-log-table th {
    background: transparent !important;
    color: #475569;
    border-bottom: 2px solid rgba(0, 0, 0, 0.05) !important;
}

.conn-log-table th[data-audit-sort] {
    transition: background 0.25s, color 0.25s;
    cursor: pointer;
}

.conn-log-table th[data-audit-sort]:hover {
    color: var(--obsidian-primary) !important;
}

[data-theme="light"] .conn-log-table th[data-audit-sort]:hover {
    color: #2563eb !important;
}

.conn-log-table td {
    padding: 0.85rem 1rem !important;
    background: rgba(255, 255, 255, 0.015) !important; /* Soft card background */
    border: none !important;
    font-size: 0.85rem !important;
    color: var(--obsidian-text-secondary);
    vertical-align: middle;
    transition: background 0.25s cubic-bezier(0.4, 0, 0.2, 1), color 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

[data-theme="light"] .conn-log-table td {
    background: #f8fafc !important;
    color: #334155;
}

/* Card-like rounded corners for connection rows */
.conn-log-table tbody tr td:first-child {
    border-top-left-radius: 10px !important;
    border-bottom-left-radius: 10px !important;
}

.conn-log-table tbody tr td:last-child {
    border-top-right-radius: 10px !important;
    border-bottom-right-radius: 10px !important;
}

/* Floating scale and neon steel blue hover effect */
.conn-log-table tbody tr:hover td {
    background: rgba(56, 189, 248, 0.06) !important;
    color: #ffffff !important;
}

[data-theme="light"] .conn-log-table tbody tr:hover td {
    background: rgba(99, 102, 241, 0.05) !important;
    color: var(--obsidian-primary) !important;
}

/* Email text-wrap layout safety */
.conn-log-email, .conn-log-table td:nth-child(4) {
    max-width: 180px;
    word-break: break-all !important;
    white-space: normal !important;
    font-weight: 500;
}

/* Diffs Styles inside Cambios */
.audit-diff {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-family: 'Geist Mono', 'Cascadia Code', monospace;
    font-size: 0.85rem;
    max-width: 100%;
    margin: 0.25rem 0;
}

.audit-diff-item {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.35rem 0.75rem;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: background-color 0.25s, border-color 0.25s;
}

[data-theme="light"] .audit-diff-item {
    background: #f8fafc;
    border-color: rgba(0, 0, 0, 0.05);
}

.audit-old {
    text-decoration: line-through;
    color: #ef4444;
    background: rgba(239, 68, 68, 0.08);
    border: 1px solid rgba(239, 68, 68, 0.15);
    padding: 2px 6px;
    border-radius: 6px;
    font-size: 0.8rem;
}

.audit-arrow {
    color: #64748b;
    font-size: 0.8rem;
    margin: 0 0.1rem;
    opacity: 0.7;
}

.audit-new {
    color: #10b981;
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.15);
    padding: 2px 6px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.8rem;
}

/* Custom premium styles for critical status alerts in overrides */
.audit-status-alert {
    padding: 0.45rem 0.8rem !important;
    border-radius: 8px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 0.5rem !important;
    font-weight: 700 !important;
    font-size: 0.85rem !important;
    box-shadow: 0 2px 6px rgba(0,0,0,0.02) !important;
    transition: all 0.2s ease !important;
}

.audit-status-alert.deleted {
    border: 1px solid rgba(239, 68, 68, 0.2) !important;
    border-left: 4px solid #ef4444 !important;
    background: rgba(239, 68, 68, 0.05) !important;
    color: #ef4444 !important;
}

.audit-status-alert.restored {
    border: 1px solid rgba(16, 185, 129, 0.2) !important;
    border-left: 4px solid #10b981 !important;
    background: rgba(16, 185, 129, 0.05) !important;
    color: #10b981 !important;
}

.audit-status-alert.maintenance-enter {
    border: 1px solid rgba(249, 115, 22, 0.2) !important;
    border-left: 4px solid #f97316 !important;
    background: rgba(249, 115, 22, 0.05) !important;
    color: #f97316 !important;
}

.audit-status-alert.maintenance-leave {
    border: 1px solid rgba(16, 185, 129, 0.2) !important;
    border-left: 4px solid #10b981 !important;
    background: rgba(16, 185, 129, 0.05) !important;
    color: #10b981 !important;
}

/* Loading/Empty State in Modal */
.conn-log-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    color: var(--obsidian-text-secondary);
    font-size: 0.95rem;
    text-align: center;
}

/* Premium Pagination */
.conn-log-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.4rem;
    margin-top: 1.25rem;
    padding-top: 0.5rem;
    padding-bottom: 1.5rem; /* Espacio premium para evitar que quede al ras del borde inferior */
    user-select: none;
}

.pg-btn {
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid var(--obsidian-outline-variant) !important;
    color: var(--obsidian-text-primary) !important;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-weight: 600 !important;
    font-size: 0.85rem !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0 !important;
}

[data-theme="light"] .pg-btn {
    background: #f8fafc !important;
    border-color: rgba(0, 0, 0, 0.08) !important;
    color: #334155 !important;
}

.pg-btn:hover:not([disabled]) {
    background: rgba(59, 130, 246, 0.15) !important;
    border-color: #3b82f6 !important;
    color: var(--obsidian-primary) !important;
    transform: translateY(-1px);
}

[data-theme="light"] .pg-btn:hover:not([disabled]) {
    background: rgba(59, 130, 246, 0.08) !important;
    color: #2563eb !important;
}

.pg-btn.active {
    background: linear-gradient(135deg, #60a5fa, #2563eb) !important;
    border-color: #3b82f6 !important;
    color: white !important;
    box-shadow: 0 0 12px rgba(59, 130, 246, 0.4);
    transform: none !important;
}

.pg-btn[disabled] {
    opacity: 0.35;
    cursor: not-allowed;
}

.pg-dots {
    color: var(--obsidian-text-secondary);
    padding: 0 0.25rem;
    font-weight: 700;
}

/* Custom Scrollbar for Logs Table Wrap */
.conn-log-table-wrap::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
.conn-log-table-wrap::-webkit-scrollbar-track {
    background: transparent;
}
.conn-log-table-wrap::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.12);
    border-radius: 4px;
}
.conn-log-table-wrap::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.24);
}
[data-theme="light"] .conn-log-table-wrap::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.12);
}
[data-theme="light"] .conn-log-table-wrap::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.24);
}

/* ────────────────────────────────────────────────────────────────────────── */
/* ADDITIONAL BRAND AESTHETICS - FINAL POLISH */
/* ────────────────────────────────────────────────────────────────────────── */

/* Glassmorphic & Floating Header in Light Mode */
[data-theme="light"] .dashboard-header {
    background: rgba(255, 255, 255, 0.8) !important;
    backdrop-filter: var(--obsidian-glass-blur) !important;
    -webkit-backdrop-filter: var(--obsidian-glass-blur) !important;
    border: 1px solid rgba(0, 0, 0, 0.05) !important;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.04) !important;
}

/* Premium Steel Blue Hover Glow for Buttons in Dark Mode */
.action-btn.btn-primary:hover:not(:disabled),
.btn-primary:hover:not(:disabled) {
    box-shadow: 0 8px 20px rgba(56, 189, 248, 0.18), 
                0 0 15px rgba(56, 189, 248, 0.15) !important;
    background: var(--obsidian-primary-gradient) !important;
}

[data-theme="light"] .action-btn.btn-primary:hover:not(:disabled),
[data-theme="light"] .btn-primary:hover:not(:disabled) {
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.2), 
                0 0 15px rgba(99, 102, 241, 0.25) !important;
}

/* Technical Glassmorphic Badges for Dark Mode */
[data-theme="dark"] .badge,
:root:not([data-theme="light"]) .badge {
    border-radius: 8px !important;
    font-family: 'Geist Mono', monospace !important;
    padding: 0.3rem 0.75rem !important;
    font-weight: 600 !important;
    letter-spacing: 0.03em !important;
}

[data-theme="dark"] .badge-fuel,
:root:not([data-theme="light"]) .badge-fuel {
    background: rgba(56, 189, 248, 0.05) !important;
    border: 1px solid rgba(56, 189, 248, 0.15) !important;
    color: #7dd3fc !important;
    box-shadow: none !important;
}

[data-theme="dark"] .badge-dry,
:root:not([data-theme="light"]) .badge-dry {
    background: rgba(245, 158, 11, 0.05) !important;
    border: 1px solid rgba(245, 158, 11, 0.15) !important;
    color: #fde047 !important;
    box-shadow: none !important;
}

[data-theme="dark"] .badge-dry-mrc,
:root:not([data-theme="light"]) .badge-dry-mrc {
    background: rgba(148, 163, 184, 0.05) !important;
    border: 1px solid rgba(148, 163, 184, 0.15) !important;
    color: #cbd5e1 !important;
    box-shadow: none !important;
}

[data-theme="dark"] .badge-ambos,
:root:not([data-theme="light"]) .badge-ambos {
    background: rgba(167, 139, 250, 0.05) !important;
    border: 1px solid rgba(167, 139, 250, 0.15) !important;
    color: #d8b4fe !important;
    box-shadow: none !important;
}

[data-theme="dark"] .badge-retail,
:root:not([data-theme="light"]) .badge-retail {
    background: rgba(52, 211, 153, 0.05) !important;
    border: 1px solid rgba(52, 211, 153, 0.15) !important;
    color: #a7f3d0 !important;
    box-shadow: none !important;
}

[data-theme="dark"] .badge-enex,
:root:not([data-theme="light"]) .badge-enex {
    background: rgba(244, 63, 94, 0.05) !important;
    border: 1px solid rgba(244, 63, 94, 0.15) !important;
    color: #fecdd3 !important;
    box-shadow: none !important;
}

/* Technical Editorial Badges for Light Mode */
[data-theme="light"] .badge {
    border-radius: 8px !important;
    font-family: 'Geist Mono', monospace !important;
    padding: 0.3rem 0.75rem !important;
    font-weight: 600 !important;
    letter-spacing: 0.03em !important;
}

[data-theme="light"] .badge-fuel {
    background: rgba(37, 99, 235, 0.06) !important;
    border: 1px solid rgba(37, 99, 235, 0.18) !important;
    color: #1d4ed8 !important;
}

[data-theme="light"] .badge-dry {
    background: rgba(217, 119, 6, 0.06) !important;
    border: 1px solid rgba(217, 119, 6, 0.18) !important;
    color: #b45309 !important;
}

[data-theme="light"] .badge-dry-mrc {
    background: rgba(71, 85, 105, 0.06) !important;
    border: 1px solid rgba(71, 85, 105, 0.18) !important;
    color: #475569 !important;
}

[data-theme="light"] .badge-ambos {
    background: rgba(109, 40, 217, 0.06) !important;
    border: 1px solid rgba(109, 40, 217, 0.18) !important;
    color: #6d28d9 !important;
}

[data-theme="light"] .badge-retail {
    background: rgba(5, 150, 105, 0.06) !important;
    border: 1px solid rgba(5, 150, 105, 0.18) !important;
    color: #047857 !important;
}

[data-theme="light"] .badge-enex {
    background: rgba(219, 39, 119, 0.06) !important;
    border: 1px solid rgba(219, 39, 119, 0.18) !important;
    color: #be185d !important;
}

/* Console-like Input & Select Fields with Geist Mono & Focus Glows */
.modal-content input[type="text"], 
.modal-content input[type="password"],
.modal-content select,
.modal-content textarea {
    font-family: 'Geist Mono', monospace !important;
    font-size: 0.88rem !important;
    letter-spacing: -0.01em !important;
}

/* Subtle Violet Focus Glow for Modals in Dark Mode */
[data-theme="dark"] .modal-content input:focus, 
[data-theme="dark"] .modal-content select:focus, 
[data-theme="dark"] .modal-content textarea:focus,
:root:not([data-theme="light"]) .modal-content input:focus, 
:root:not([data-theme="light"]) .modal-content select:focus, 
:root:not([data-theme="light"]) .modal-content textarea:focus {
    background: rgba(0, 0, 0, 0.4) !important;
    border-color: var(--obsidian-primary) !important;
    box-shadow: 0 0 0 1px var(--obsidian-primary), 
                0 0 16px rgba(167, 139, 250, 0.25) !important;
}

/* ────────────────────────────────────────────────────────────────────────── */
/* DIGITAL OBSIDIAN PREMIUM INTERACTION UPGRADES */
/* ────────────────────────────────────────────────────────────────────────── */

/* Premium smooth transitions across the board */
.panel, .detail-card, .modal-content, .card, .action-btn, .glow-btn, .stat-badge, .data-table tbody tr {
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

/* Sophisticated interactive hovering elevators (Transform shift removed for static stability) */
[data-theme="dark"] .panel:hover,
[data-theme="dark"] .detail-card:hover {
    border-color: rgba(167, 139, 250, 0.18) !important;
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.8), 0 0 60px rgba(167, 139, 250, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
}

[data-theme="light"] .panel:hover,
[data-theme="light"] .detail-card:hover {
    border-color: rgba(99, 102, 241, 0.18) !important;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.04), 0 1px 3px rgba(15, 23, 42, 0.01) !important;
}

/* Smooth active scale effect (Sutil press feedback) */
.panel:active, .detail-card:active, .card:active {
    transform: scale(0.997) !important;
}

/* Technical micro-badge animations */
.stat-badge {
    position: relative;
    overflow: hidden;
}

.stat-badge::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.12), transparent);
    transition: 0.6s ease;
}

.stat-badge:hover::after {
    left: 100%;
}

/* ────────────────────────────────────────────────────────────────────────── */
/* HIGH VISIBILITY SELECTED ROW & SIDEBAR HIGHLIGHTS */
/* ────────────────────────────────────────────────────────────────────────── */

/* 1. High Visibility Selected Row in Light Mode */
[data-theme="light"] .data-table tbody tr.selected td {
    background: #eef2ff !important; /* Premium soft indigo background */
    color: #1e3a8a !important; /* High contrast text */
    font-weight: 600 !important;
    border-top: 1px solid rgba(99, 102, 241, 0.25) !important;
    border-bottom: 1px solid rgba(99, 102, 241, 0.25) !important;
}

[data-theme="light"] .data-table tbody tr.selected td:first-child {
    border-left: 4px solid #3b82f6 !important; /* Prominent left indicator bar */
}

[data-theme="light"] .data-table tbody tr.selected td:last-child {
    border-right: 2px solid rgba(99, 102, 241, 0.25) !important;
}

/* 2. Right sidebar panel — clean, borderless, premium */
[data-theme="light"] .sidebar-column > .panel {
    background: #f8fafc !important;
    border: 1px solid rgba(148, 163, 184, 0.18) !important;
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.03) !important;
}

[data-theme="dark"] .sidebar-column > .panel,
:root:not([data-theme="light"]) .sidebar-column > .panel {
    background: linear-gradient(160deg, #111827 0%, #0b0f19 100%) !important;
    border: 1px solid rgba(148, 163, 184, 0.08) !important;
    box-shadow: 0 30px 65px rgba(0, 0, 0, 0.5), 0 2px 12px rgba(0, 0, 0, 0.3) !important;
}

/* Remove hover shift/movement animations on table rows */
.data-table tbody tr,
[data-theme="light"] .data-table tbody tr,
[data-theme="dark"] .data-table tbody tr {
    transform: none !important;
    transition: background 0.15s ease, box-shadow 0.15s ease !important;
}

.data-table tbody tr:hover,
[data-theme="light"] .data-table tbody tr:hover td,
[data-theme="dark"] .data-table tbody tr:hover td {
    transform: none !important;
}

/* Ensure confirm modal messages respect newlines */
.confirm-modal-message {
    white-space: pre-wrap !important;
}

/* ── Dynamic Confirm Modal Styling (Obsidian Aesthetic) ── */
.modal-overlay {
    transition: opacity 0.3s ease, visibility 0.3s ease !important;
}
.modal-overlay.show {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
}

.confirm-modal {
    background: var(--modal-bg, #ffffff) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border: 1px solid var(--panel-border, rgba(0,0,0,0.1)) !important;
    border-radius: 24px !important;
    padding: 2.2rem !important;
    width: 95% !important;
    max-width: 440px !important;
    text-align: center !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4) !important;
    transform: scale(0.9) translateY(20px) !important;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s ease !important;
    opacity: 0 !important;
    display: block !important;
}

[data-theme="dark"] .confirm-modal,
:root:not([data-theme="light"]) .confirm-modal {
    background: var(--obsidian-glass-bg, #0f172a) !important;
    border-color: var(--obsidian-outline-variant, rgba(255,255,255,0.1)) !important;
}

.modal-overlay.show .confirm-modal {
    transform: scale(1) translateY(0) !important;
    opacity: 1 !important;
}

.confirm-modal-icon {
    font-size: 2.5rem !important;
    color: #f59e0b !important; /* Amber */
    margin-bottom: 1.2rem !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
}

.confirm-modal-title {
    color: var(--text-primary, #0f172a) !important;
    font-size: 1.25rem !important;
    font-weight: 800 !important;
    margin-bottom: 1rem !important;
    letter-spacing: -0.02em !important;
}

[data-theme="dark"] .confirm-modal-title,
:root:not([data-theme="light"]) .confirm-modal-title {
    color: var(--obsidian-text-primary, #f8fafc) !important;
}

.confirm-modal-message {
    color: var(--text-secondary, #475569) !important;
    font-size: 0.92rem !important;
    line-height: 1.6 !important;
    margin-bottom: 2rem !important;
    font-weight: 500 !important;
}

[data-theme="dark"] .confirm-modal-message,
:root:not([data-theme="light"]) .confirm-modal-message {
    color: var(--obsidian-text-secondary, #94a3b8) !important;
}

.confirm-modal-actions {
    display: flex !important;
    gap: 1rem !important;
    justify-content: center !important;
}

.confirm-modal-btn {
    flex: 1 !important;
    padding: 0.8rem 1.5rem !important;
    border-radius: 12px !important;
    font-size: 0.88rem !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
    font-family: inherit !important;
    border: none !important;
    outline: none !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* Cancel Button Styling (The request asks to improve this!) */
.confirm-modal-btn.btn-cancel {
    background: rgba(0, 0, 0, 0.05) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    color: #475569 !important;
}

[data-theme="dark"] .confirm-modal-btn.btn-cancel,
:root:not([data-theme="light"]) .confirm-modal-btn.btn-cancel {
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #cbd5e1 !important;
}

.confirm-modal-btn.btn-cancel:hover {
    background: rgba(0, 0, 0, 0.1) !important;
    border-color: rgba(0, 0, 0, 0.15) !important;
    color: #1e293b !important;
}

[data-theme="dark"] .confirm-modal-btn.btn-cancel:hover,
:root:not([data-theme="light"]) .confirm-modal-btn.btn-cancel:hover {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: #f8fafc !important;
}

/* Success Accept Button Styling */
.confirm-modal-btn.btn-confirm-success {
    background: linear-gradient(135deg, #10b981, #059669) !important;
    color: white !important;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2) !important;
}

.confirm-modal-btn.btn-confirm-success:hover {
    background: linear-gradient(135deg, #34d399, #10b981) !important;
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.3) !important;
    transform: translateY(-1px) !important;
}

/* Danger Accept Button Styling */
.confirm-modal-btn.btn-confirm-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626) !important;
    color: white !important;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2) !important;
}

.confirm-modal-btn.btn-confirm-danger:hover {
    background: linear-gradient(135deg, #f87171, #ef4444) !important;
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.3) !important;
    transform: translateY(-1px) !important;
}

/* ── Premium Maintenance Alert Card Styling ── */
.maint-card {
    background: rgba(245, 158, 11, 0.04) !important;
    border: 1px solid rgba(245, 158, 11, 0.18) !important;
    border-left: 4px solid #f59e0b !important;
    border-radius: 16px !important;
    padding: 1.2rem !important;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.05) !important;
    transition: all 0.3s ease !important;
}

[data-theme="dark"] .maint-card,
:root:not([data-theme="light"]) .maint-card {
    background: rgba(245, 158, 11, 0.06) !important;
    border-color: rgba(245, 158, 11, 0.25) !important;
    border-left-color: #fbbf24 !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2), 0 0 15px rgba(245, 158, 11, 0.05) !important;
}

.maint-header {
    display: flex !important;
    align-items: center !important;
    gap: 0.6rem !important;
}

.maint-icon {
    color: #f59e0b !important;
    font-size: 1.1rem !important;
    animation: pulse-soft 2s infinite !important;
}

[data-theme="dark"] .maint-icon,
:root:not([data-theme="light"]) .maint-icon {
    color: #fbbf24 !important;
}

.maint-title {
    color: #b45309 !important;
    font-weight: 800 !important;
    font-size: 0.78rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.06em !important;
}

[data-theme="dark"] .maint-title,
:root:not([data-theme="light"]) .maint-title {
    color: #f59e0b !important;
}

.maint-note {
    color: #475569 !important;
    font-size: 0.84rem !important;
    line-height: 1.4 !important;
    font-family: inherit !important;
    margin-left: 1.7rem !important;
    display: flex !important;
    align-items: baseline !important;
    gap: 0.35rem !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

[data-theme="dark"] .maint-note,
:root:not([data-theme="light"]) .maint-note {
    color: #cbd5e1 !important;
}

.maint-note span {
    font-weight: 700 !important;
    color: #d97706 !important;
}

[data-theme="dark"] .maint-note span,
:root:not([data-theme="light"]) .maint-note span {
    color: #fbbf24 !important;
}

/* Soft desaturated LED dots in dark mode (No eye strain) */
[data-theme="dark"] .ip-dot.active {
    background: #34d399 !important;
    box-shadow: 0 0 6px rgba(52, 211, 153, 0.2) !important;
    border-color: rgba(52, 211, 153, 0.3) !important;
}

[data-theme="dark"] .ip-dot.online {
    background: #34d399 !important;
    box-shadow: 0 0 0 2px rgba(52, 211, 153, 0.1), 0 0 6px rgba(52, 211, 153, 0.3) !important;
    animation: pulse-online-soft 3s ease-in-out infinite !important;
}

@keyframes pulse-online-soft {
    0%, 100% {
        box-shadow: 0 0 0 2px rgba(52, 211, 153, 0.1), 0 0 6px rgba(52, 211, 153, 0.3) !important;
    }
    50% {
        box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.05), 0 0 10px rgba(52, 211, 153, 0.2) !important;
    }
}

/* Perfect grid alignment for IP details sidebar (Square & level) */
.detail-ip-row {
    display: grid !important;
    grid-template-columns: 110px 1fr !important;
    gap: 1rem !important;
    align-items: center !important; /* Vertically centered for perfect optical alignment */
    padding: 8px 0 !important;
}

.detail-ip-row.hidden {
    display: none !important;
}

.ip-label {
    width: 100% !important;
    white-space: nowrap !important;
    padding: 0 !important;
    margin: 0 !important;
}

.detail-ip-row .ip-val {
    padding: 0 !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
}



/* ── Sidebar Contact Button ──────────────────────────────────────────────── */
.btn-contact-sidebar {
    display: inline-flex !important;
    align-items: center !important;
    gap: 0.4rem !important;
    padding: 0.35rem 0.8rem !important;
    font-size: 0.78rem !important;
    font-weight: 600 !important;
    border-radius: 8px !important;
    background: rgba(56, 189, 248, 0.1) !important;
    color: #38bdf8 !important;
    border: 1px solid rgba(56, 189, 248, 0.25) !important;
    cursor: pointer !important;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease !important;
    white-space: nowrap !important;
}

.btn-contact-sidebar:hover {
    background: rgba(56, 189, 248, 0.2) !important;
    border-color: rgba(56, 189, 248, 0.5) !important;
    transform: translateY(-1px) !important;
}

.btn-contact-sidebar:active {
    transform: translateY(0) !important;
    background: rgba(56, 189, 248, 0.25) !important;
}

[data-theme="light"] .btn-contact-sidebar {
    background: rgba(2, 132, 199, 0.08) !important;
    color: #0284c7 !important;
    border-color: rgba(2, 132, 199, 0.25) !important;
}

[data-theme="light"] .btn-contact-sidebar:hover {
    background: rgba(2, 132, 199, 0.15) !important;
    border-color: rgba(2, 132, 199, 0.45) !important;
}


/* ── Audit Logs Filter Chips & Row ───────────────────────────────────────── */
.audit-filter-row {
    display: flex !important;
    align-items: center !important;
    gap: 0.45rem !important; /* Menor gap para mayor compactación horizontal */
    padding: 0.55rem 0.85rem !important; /* Más compacto */
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.02) 0%, rgba(255, 255, 255, 0.005) 100%) !important; /* Degradado sutil */
    border-radius: 12px !important;
    border: 1px solid rgba(255, 255, 255, 0.06) !important;
    margin: 0.8rem 0 1.1rem 0 !important;
    flex-wrap: nowrap !important; /* Forzar que todo quepa en una sola línea */
    overflow-x: auto !important; /* Permitir scroll si la pantalla es extremadamente pequeña */
    scrollbar-width: none !important; /* Ocultar barra en Firefox */
    transition: background 0.3s ease, border-color 0.3s ease !important;
}

.audit-filter-row::-webkit-scrollbar {
    display: none !important; /* Ocultar barra en Chrome/Safari */
}

.audit-filter-label {
    font-size: 0.78rem !important;
    font-weight: 600 !important;
    color: var(--obsidian-text-secondary) !important;
    display: flex !important;
    align-items: center !important;
    gap: 0.25rem !important;
    margin-right: 0.15rem !important;
    white-space: nowrap !important;
}

.audit-chip-divider {
    width: 1px !important;
    height: 16px !important;
    background: rgba(255, 255, 255, 0.1) !important;
    margin: 0 0.3rem !important;
    display: inline-block !important;
    flex-shrink: 0 !important;
}

/* Estilo Base del Chip (Con color sutil individual) */
.audit-chip {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    color: var(--obsidian-text-secondary) !important;
    border-radius: 20px !important;
    padding: 0.25rem 0.65rem !important; /* Más compacto */
    font-size: 0.74rem !important;
    font-weight: 500 !important;
    cursor: pointer !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 0.3rem !important;
    outline: none !important;
    user-select: none !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
}

/* Colores Sutiles Individuales - Estado Inactivo */
.audit-chip.chip-all {
    background: rgba(255, 255, 255, 0.01) !important;
    border-color: rgba(255, 255, 255, 0.06) !important;
    color: rgba(255, 255, 255, 0.5) !important;
}

.audit-chip.chip-update {
    background: rgba(245, 158, 11, 0.02) !important;
    border-color: rgba(245, 158, 11, 0.12) !important;
    color: rgba(245, 158, 11, 0.7) !important;
}

.audit-chip.chip-insert {
    background: rgba(16, 185, 129, 0.02) !important;
    border-color: rgba(16, 185, 129, 0.12) !important;
    color: rgba(16, 185, 129, 0.7) !important;
}

.audit-chip.chip-delete {
    background: rgba(239, 68, 68, 0.02) !important;
    border-color: rgba(239, 68, 68, 0.12) !important;
    color: rgba(239, 68, 68, 0.7) !important;
}

.audit-chip.chip-fuel {
    background: rgba(56, 189, 248, 0.02) !important;
    border-color: rgba(56, 189, 248, 0.12) !important;
    color: rgba(56, 189, 248, 0.7) !important;
}

.audit-chip.chip-dry {
    background: rgba(168, 85, 247, 0.02) !important;
    border-color: rgba(168, 85, 247, 0.12) !important;
    color: rgba(168, 85, 247, 0.7) !important;
}

.audit-chip.chip-drymrc {
    background: rgba(236, 72, 153, 0.02) !important;
    border-color: rgba(236, 72, 153, 0.12) !important;
    color: rgba(236, 72, 153, 0.7) !important;
}

.audit-chip.chip-ambos {
    background: rgba(20, 184, 166, 0.02) !important;
    border-color: rgba(20, 184, 166, 0.12) !important;
    color: rgba(20, 184, 166, 0.7) !important;
}

.audit-chip.chip-piretail {
    background: rgba(234, 179, 8, 0.02) !important;
    border-color: rgba(234, 179, 8, 0.12) !important;
    color: rgba(234, 179, 8, 0.7) !important;
}

.audit-chip.chip-enex {
    background: rgba(99, 102, 241, 0.02) !important;
    border-color: rgba(99, 102, 241, 0.12) !important;
    color: rgba(99, 102, 241, 0.7) !important;
}

/* Efectos Hover Dinámicos y Coloridos */
.audit-chip:hover {
    transform: translateY(-1px) !important;
}

.audit-chip.chip-all:hover {
    background: rgba(255, 255, 255, 0.04) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: var(--obsidian-text-primary) !important;
}

.audit-chip.chip-update:hover {
    background: rgba(245, 158, 11, 0.06) !important;
    border-color: rgba(245, 158, 11, 0.3) !important;
    color: #fbbf24 !important;
}

.audit-chip.chip-insert:hover {
    background: rgba(16, 185, 129, 0.06) !important;
    border-color: rgba(16, 185, 129, 0.3) !important;
    color: #34d399 !important;
}

.audit-chip.chip-delete:hover {
    background: rgba(239, 68, 68, 0.06) !important;
    border-color: rgba(239, 68, 68, 0.3) !important;
    color: #f87171 !important;
}

.audit-chip.chip-fuel:hover {
    background: rgba(56, 189, 248, 0.06) !important;
    border-color: rgba(56, 189, 248, 0.3) !important;
    color: #38bdf8 !important;
}

.audit-chip.chip-dry:hover {
    background: rgba(168, 85, 247, 0.06) !important;
    border-color: rgba(168, 85, 247, 0.3) !important;
    color: #c084fc !important;
}

.audit-chip.chip-drymrc:hover {
    background: rgba(236, 72, 153, 0.06) !important;
    border-color: rgba(236, 72, 153, 0.3) !important;
    color: #f472b6 !important;
}

.audit-chip.chip-ambos:hover {
    background: rgba(20, 184, 166, 0.06) !important;
    border-color: rgba(20, 184, 166, 0.3) !important;
    color: #2dd4bf !important;
}

.audit-chip.chip-piretail:hover {
    background: rgba(234, 179, 8, 0.06) !important;
    border-color: rgba(234, 179, 8, 0.3) !important;
    color: #facc15 !important;
}

.audit-chip.chip-enex:hover {
    background: rgba(99, 102, 241, 0.06) !important;
    border-color: rgba(99, 102, 241, 0.3) !important;
    color: #818cf8 !important;
}

.audit-chip:active {
    transform: translateY(0) !important;
}

/* Colores Intensos Específicos - Estado Activo (Brillo Glow) */
.audit-chip.active {
    font-weight: 600 !important;
}

.audit-chip.chip-all.active {
    background: rgba(56, 189, 248, 0.12) !important;
    border-color: #38bdf8 !important;
    color: #38bdf8 !important;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.15) !important;
}

.audit-chip.chip-update.active {
    background: rgba(245, 158, 11, 0.12) !important;
    border-color: #f59e0b !important;
    color: #f59e0b !important;
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.15) !important;
}

.audit-chip.chip-insert.active {
    background: rgba(16, 185, 129, 0.12) !important;
    border-color: #10b981 !important;
    color: #10b981 !important;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.15) !important;
}

.audit-chip.chip-delete.active {
    background: rgba(239, 68, 68, 0.12) !important;
    border-color: #ef4444 !important;
    color: #ef4444 !important;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.15) !important;
}

.audit-chip.chip-fuel.active {
    background: rgba(56, 189, 248, 0.12) !important;
    border-color: #38bdf8 !important;
    color: #38bdf8 !important;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.15) !important;
}

.audit-chip.chip-dry.active {
    background: rgba(168, 85, 247, 0.12) !important;
    border-color: #a855f7 !important;
    color: #a855f7 !important;
    box-shadow: 0 0 10px rgba(168, 85, 247, 0.15) !important;
}

.audit-chip.chip-drymrc.active {
    background: rgba(236, 72, 153, 0.12) !important;
    border-color: #ec4899 !important;
    color: #ec4899 !important;
    box-shadow: 0 0 10px rgba(236, 72, 153, 0.15) !important;
}

.audit-chip.chip-ambos.active {
    background: rgba(20, 184, 166, 0.12) !important;
    border-color: #20b8a6 !important;
    color: #20b8a6 !important;
    box-shadow: 0 0 10px rgba(20, 184, 166, 0.15) !important;
}

.audit-chip.chip-piretail.active {
    background: rgba(234, 179, 8, 0.12) !important;
    border-color: #eab308 !important;
    color: #eab308 !important;
    box-shadow: 0 0 10px rgba(234, 179, 8, 0.15) !important;
}

.audit-chip.chip-enex.active {
    background: rgba(99, 102, 241, 0.12) !important;
    border-color: #6366f1 !important;
    color: #6366f1 !important;
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.15) !important;
}

/* Contador de Registros */
.audit-record-count {
    margin-left: auto !important;
    font-size: 0.76rem !important;
    font-weight: 600 !important;
    color: var(--obsidian-text-secondary) !important;
    background: rgba(255, 255, 255, 0.04) !important;
    padding: 0.25rem 0.75rem !important;
    border-radius: 20px !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    letter-spacing: 0.02em !important;
    flex-shrink: 0 !important;
}

/* Adaptación a Light Theme */
[data-theme="light"] .audit-filter-row {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.015) 0%, rgba(0, 0, 0, 0.005) 100%) !important;
    border-color: rgba(0, 0, 0, 0.06) !important;
}

[data-theme="light"] .audit-chip {
    background: rgba(0, 0, 0, 0.01) !important;
}

[data-theme="light"] .audit-chip-divider {
    background: rgba(0, 0, 0, 0.08) !important;
}

[data-theme="light"] .audit-chip.chip-all {
    border-color: rgba(0, 0, 0, 0.08) !important;
    color: #64748b !important;
}

[data-theme="light"] .audit-chip.chip-update {
    background: rgba(245, 158, 11, 0.015) !important;
    border-color: rgba(245, 158, 11, 0.12) !important;
    color: #b45309 !important;
}

[data-theme="light"] .audit-chip.chip-insert {
    background: rgba(16, 185, 129, 0.015) !important;
    border-color: rgba(16, 185, 129, 0.12) !important;
    color: #047857 !important;
}

[data-theme="light"] .audit-chip.chip-delete {
    background: rgba(239, 68, 68, 0.015) !important;
    border-color: rgba(239, 68, 68, 0.12) !important;
    color: #b91c1c !important;
}

[data-theme="light"] .audit-chip.chip-fuel {
    background: rgba(2, 132, 199, 0.015) !important;
    border-color: rgba(2, 132, 199, 0.12) !important;
    color: #0369a1 !important;
}

[data-theme="light"] .audit-chip.chip-dry {
    background: rgba(168, 85, 247, 0.015) !important;
    border-color: rgba(168, 85, 247, 0.12) !important;
    color: #7e22ce !important;
}

[data-theme="light"] .audit-chip.chip-drymrc {
    background: rgba(236, 72, 153, 0.015) !important;
    border-color: rgba(236, 72, 153, 0.12) !important;
    color: #be185d !important;
}

[data-theme="light"] .audit-chip.chip-ambos {
    background: rgba(20, 184, 166, 0.015) !important;
    border-color: rgba(20, 184, 166, 0.12) !important;
    color: #0f766e !important;
}

[data-theme="light"] .audit-chip.chip-piretail {
    background: rgba(234, 179, 8, 0.015) !important;
    border-color: rgba(234, 179, 8, 0.12) !important;
    color: #a16207 !important;
}

[data-theme="light"] .audit-chip.chip-enex {
    background: rgba(99, 102, 241, 0.015) !important;
    border-color: rgba(99, 102, 241, 0.12) !important;
    color: #4338ca !important;
}

/* Hover Light Theme */
[data-theme="light"] .audit-chip.chip-all:hover {
    background: rgba(0, 0, 0, 0.03) !important;
    border-color: rgba(0, 0, 0, 0.18) !important;
    color: #0f172a !important;
}

[data-theme="light"] .audit-chip.chip-update:hover {
    background: rgba(245, 158, 11, 0.04) !important;
    border-color: rgba(245, 158, 11, 0.25) !important;
    color: #78350f !important;
}

[data-theme="light"] .audit-chip.chip-insert:hover {
    background: rgba(16, 185, 129, 0.04) !important;
    border-color: rgba(16, 185, 129, 0.25) !important;
    color: #064e3b !important;
}

[data-theme="light"] .audit-chip.chip-delete:hover {
    background: rgba(239, 68, 68, 0.04) !important;
    border-color: rgba(239, 68, 68, 0.25) !important;
    color: #7f1d1d !important;
}

[data-theme="light"] .audit-chip.chip-fuel:hover {
    background: rgba(2, 132, 199, 0.04) !important;
    border-color: rgba(2, 132, 199, 0.25) !important;
    color: #0c4a6e !important;
}

[data-theme="light"] .audit-chip.chip-dry:hover {
    background: rgba(168, 85, 247, 0.04) !important;
    border-color: rgba(168, 85, 247, 0.25) !important;
    color: #581c87 !important;
}

[data-theme="light"] .audit-chip.chip-drymrc:hover {
    background: rgba(236, 72, 153, 0.04) !important;
    border-color: rgba(236, 72, 153, 0.25) !important;
    color: #701a75 !important;
}

[data-theme="light"] .audit-chip.chip-ambos:hover {
    background: rgba(20, 184, 166, 0.04) !important;
    border-color: rgba(20, 184, 166, 0.25) !important;
    color: #115e59 !important;
}

[data-theme="light"] .audit-chip.chip-piretail:hover {
    background: rgba(234, 179, 8, 0.04) !important;
    border-color: rgba(234, 179, 8, 0.25) !important;
    color: #713f12 !important;
}

[data-theme="light"] .audit-chip.chip-enex:hover {
    background: rgba(99, 102, 241, 0.04) !important;
    border-color: rgba(99, 102, 241, 0.25) !important;
    color: #1e1b4b !important;
}

/* Activos Light Theme (Con Sombra Suave del Color Correspondiente) */
[data-theme="light"] .audit-chip.chip-all.active {
    background: rgba(2, 132, 199, 0.08) !important;
    border-color: #0284c7 !important;
    color: #0284c7 !important;
    box-shadow: 0 0 8px rgba(2, 132, 199, 0.12) !important;
}

[data-theme="light"] .audit-chip.chip-update.active {
    background: rgba(217, 119, 6, 0.08) !important;
    border-color: #d97706 !important;
    color: #d97706 !important;
    box-shadow: 0 0 8px rgba(217, 119, 6, 0.12) !important;
}

[data-theme="light"] .audit-chip.chip-insert.active {
    background: rgba(5, 150, 105, 0.08) !important;
    border-color: #059669 !important;
    color: #059669 !important;
    box-shadow: 0 0 8px rgba(5, 150, 105, 0.12) !important;
}

[data-theme="light"] .audit-chip.chip-delete.active {
    background: rgba(220, 38, 38, 0.08) !important;
    border-color: #dc2626 !important;
    color: #dc2626 !important;
    box-shadow: 0 0 8px rgba(220, 38, 38, 0.12) !important;
}

[data-theme="light"] .audit-chip.chip-fuel.active {
    background: rgba(2, 132, 199, 0.08) !important;
    border-color: #0284c7 !important;
    color: #0284c7 !important;
    box-shadow: 0 0 8px rgba(2, 132, 199, 0.12) !important;
}

[data-theme="light"] .audit-chip.chip-dry.active {
    background: rgba(168, 85, 247, 0.08) !important;
    border-color: #a855f7 !important;
    color: #a855f7 !important;
    box-shadow: 0 0 8px rgba(168, 85, 247, 0.12) !important;
}

[data-theme="light"] .audit-chip.chip-drymrc.active {
    background: rgba(236, 72, 153, 0.08) !important;
    border-color: #ec4899 !important;
    color: #ec4899 !important;
    box-shadow: 0 0 8px rgba(236, 72, 153, 0.12) !important;
}

[data-theme="light"] .audit-chip.chip-ambos.active {
    background: rgba(20, 184, 166, 0.08) !important;
    border-color: #20b8a6 !important;
    color: #20b8a6 !important;
    box-shadow: 0 0 8px rgba(20, 184, 166, 0.12) !important;
}

[data-theme="light"] .audit-chip.chip-piretail.active {
    background: rgba(234, 179, 8, 0.08) !important;
    border-color: #eab308 !important;
    color: #eab308 !important;
    box-shadow: 0 0 8px rgba(234, 179, 8, 0.12) !important;
}

[data-theme="light"] .audit-chip.chip-enex.active {
    background: rgba(99, 102, 241, 0.08) !important;
    border-color: #6366f1 !important;
    color: #6366f1 !important;
    box-shadow: 0 0 8px rgba(99, 102, 241, 0.12) !important;
}

[data-theme="light"] .audit-record-count {
    background: rgba(0, 0, 0, 0.03) !important;
    border-color: rgba(0, 0, 0, 0.06) !important;
    color: #475569 !important;
}

/* ── Audit Logs Timeline View (Premium - Mirrors Reference Image) ── */
.audit-timeline {
    position: relative;
    padding: 0.75rem 0 0.75rem 3rem !important; /* Spacing left for vertical axis line */
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

/* Timeline Vertical Axis Line */
.audit-timeline::before {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    bottom: 0 !important;
    left: 1.5rem !important;
    width: 2px !important;
    background: rgba(255, 255, 255, 0.08) !important; /* Dark Mode */
    z-index: 1 !important;
}
[data-theme="light"] .audit-timeline::before {
    background: rgba(0, 0, 0, 0.06) !important; /* Light Mode */
}

/* Timeline Item containing Node + Card */
.audit-timeline-item {
    position: relative !important;
    display: flex !important;
    align-items: flex-start !important;
    width: 100% !important;
}

/* Timeline Circular Node (Icons) */
.audit-timeline-node {
    position: absolute !important;
    left: -3rem !important; /* Center on axis */
    top: 0.5rem !important;
    width: 38px !important;
    height: 38px !important;
    border-radius: 50% !important;
    background: #0b0f19 !important;
    border: 2px solid var(--node-color, #64748b) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    z-index: 2 !important;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.5) !important;
    transition: all 0.25s ease !important;
}
[data-theme="light"] .audit-timeline-node {
    background: #ffffff !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08) !important;
}

.audit-timeline-node i {
    font-size: 0.88rem !important;
    color: var(--node-color, #64748b) !important;
}

/* Node Side Dot Indicators (matches the yellow/green/red dots on the right of reference circles) */
.audit-timeline-node::after {
    content: '' !important;
    position: absolute !important;
    right: -8px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 6px !important;
    height: 6px !important;
    border-radius: 50% !important;
    background: var(--node-color, #64748b) !important;
    box-shadow: 0 0 8px var(--node-color, #64748b) !important;
}

/* Timeline Action Card */
.audit-timeline-card {
    flex: 1 !important;
    background: rgba(255, 255, 255, 0.01) !important;
    border: 1px solid rgba(255, 255, 255, 0.04) !important;
    border-radius: 12px !important;
    padding: 0.7rem 1rem !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2) !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
.audit-timeline-card:hover {
    border-color: rgba(255, 255, 255, 0.08) !important;
    background: rgba(255, 255, 255, 0.02) !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3) !important;
}

[data-theme="light"] .audit-timeline-card {
    background: #ffffff !important;
    border-color: rgba(0, 0, 0, 0.04) !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.02) !important;
}
[data-theme="light"] .audit-timeline-card:hover {
    border-color: rgba(0, 0, 0, 0.08) !important;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.04) !important;
}

/* Card Header Layout */
.audit-card-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
    margin-bottom: 0.45rem !important;
    flex-wrap: wrap !important;
    gap: 0.35rem !important;
}

/* Card Title Left Side (Badge + File) */
.audit-card-title-wrap {
    display: flex !important;
    align-items: center !important;
    gap: 0.75rem !important;
}

.audit-action-badge {
    padding: 3px 10px !important;
    border-radius: 6px !important;
    font-size: 0.72rem !important;
    font-weight: 800 !important;
    letter-spacing: 0.05em !important;
    text-transform: uppercase !important;
    display: inline-block !important;
}

.audit-action-badge.update {
    background: rgba(245, 158, 11, 0.12) !important;
    color: #fbbf24 !important;
    border: 1px solid rgba(245, 158, 11, 0.2) !important;
}
.audit-action-badge.insert {
    background: rgba(16, 185, 129, 0.12) !important;
    color: #34d399 !important;
    border: 1px solid rgba(16, 185, 129, 0.2) !important;
}
.audit-action-badge.delete {
    background: rgba(239, 68, 68, 0.12) !important;
    color: #f87171 !important;
    border: 1px solid rgba(239, 68, 68, 0.2) !important;
}

.audit-card-file {
    font-family: 'Lexend', sans-serif !important;
    font-weight: 700 !important;
    font-size: 1.05rem !important;
    color: #ffffff !important;
}
[data-theme="light"] .audit-card-file {
    color: #1e293b !important;
}

/* Card Header Right Side (User Info) */
.audit-card-meta {
    text-align: right !important;
}

.audit-card-user {
    font-size: 0.82rem !important;
    font-weight: 600 !important;
    color: var(--obsidian-text-secondary) !important;
    display: block !important;
    margin-bottom: 0.15rem !important;
}
.audit-card-date {
    font-size: 0.72rem !important;
    color: #64748b !important;
    font-family: 'Geist Mono', monospace !important;
}

/* Card Body (Diff block) */
.audit-card-body {
    background: #080c14 !important; /* Deep dark background matches reference image precisely */
    border: 1px solid rgba(255, 255, 255, 0.02) !important;
    border-radius: 6px !important;
    padding: 0.45rem 0.75rem !important;
    font-family: 'Geist Mono', monospace !important;
    font-size: 0.82rem !important;
    line-height: 1.45 !important;
    overflow-x: auto !important;
}
[data-theme="light"] .audit-card-body {
    background: #f8fafc !important;
    border-color: rgba(0, 0, 0, 0.04) !important;
}

/* Diff elements formatting inside the dark box */
.audit-diff {
    display: flex !important;
    flex-direction: column !important;
    gap: 0.35rem !important;
}

.audit-diff-line {
    display: flex !important;
    align-items: center !important;
    flex-wrap: wrap !important;
    gap: 0.4rem !important;
}

.audit-diff-label {
    color: #94a3b8 !important;
    font-weight: 500 !important;
}
[data-theme="light"] .audit-diff-label {
    color: #475569 !important;
}

.audit-diff-old {
    text-decoration: line-through !important;
    color: #ef4444 !important;
    opacity: 0.75 !important;
}

.audit-diff-arrow {
    color: #64748b !important;
}

.audit-diff-new {
    color: #10b981 !important;
    font-weight: 600 !important;
    text-shadow: 0 0 10px rgba(16, 185, 129, 0.1) !important;
}

.audit-diff-alert {
    display: flex !important;
    align-items: center !important;
    gap: 0.4rem !important;
    font-weight: 600 !important;
}
.audit-diff-alert.restored {
    color: #10b981 !important;
}
.audit-diff-alert.deleted {
    color: #ef4444 !important;
}
.audit-diff-alert.maintenance {
    color: #f97316 !important;
}

/* Chip filter helper dot inside action chips */
.chip-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    margin-right: 6px;
}
.chip-dot.update {
    background-color: #f59e0b;
    box-shadow: 0 0 6px #f59e0b;
}
.chip-dot.insert {
    background-color: #10b981;
    box-shadow: 0 0 6px #10b981;
}
.chip-dot.delete {
    background-color: #ef4444;
    box-shadow: 0 0 6px #ef4444;
}

/* Search bar shortcut badge styling */
.search-shortcut-badge {
    pointer-events: none;
    font-family: inherit;
    transition: opacity 0.15s ease;
}

/* Override the modal wrap scroll for the timeline */
#audit-log-modal .conn-log-table-wrap {
    background: transparent !important;
    border: none !important;
    max-height: 60vh !important;
    box-shadow: none !important;
}

/* Expand the connection log table height to fill the modal and remove empty space */
#conn-log-modal .conn-log-table-wrap {
    max-height: 66vh !important;
}

/* ========================================================================== */
/* STATIONS LIST PREMIUM PAGINATION & ELEMENTS SELECTOR */
/* ========================================================================== */

.pagination-wrapper {
    position: relative !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 0.35rem 1.6rem !important;
    border-top: 1px solid var(--obsidian-outline-variant) !important;
    background: transparent !important;
    flex-wrap: nowrap !important;
    gap: 0.5rem !important;
    margin-top: 0 !important;
}

.pagination-container {
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    display: flex !important;
    align-items: center !important;
    gap: 0.4rem !important;
    pointer-events: auto !important;
}

.last-updated-info {
    font-family: 'Geist Mono', monospace !important;
    font-size: 0.72rem !important;
    color: var(--obsidian-text-secondary) !important;
    opacity: 0.85 !important;
}

/* Sleek text buttons for Anterior / Siguiente */
.pg-text-btn {
    width: auto !important;
    padding: 0 0.8rem !important;
    height: 36px !important;
    font-size: 0.8rem !important;
    font-weight: 600 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.25rem !important;
    background: transparent !important;
    border: 1px solid transparent !important;
    color: var(--obsidian-text-secondary) !important;
    box-shadow: none !important;
    border-radius: 10px !important;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    user-select: none;
}

.pg-text-btn:hover:not([disabled]) {
    color: var(--obsidian-primary) !important;
    background: rgba(56, 189, 248, 0.08) !important;
    border-color: rgba(56, 189, 248, 0.15) !important;
}

[data-theme="light"] .pg-text-btn:hover:not([disabled]) {
    color: var(--obsidian-primary) !important;
    background: rgba(37, 99, 235, 0.06) !important;
    border-color: rgba(37, 99, 235, 0.12) !important;
}

.pg-text-btn:active:not([disabled]) {
    transform: translateY(0);
    background: rgba(56, 189, 248, 0.15) !important;
}

.pg-text-btn[disabled] {
    opacity: 0.35 !important;
    cursor: not-allowed !important;
}

/* Page Size Selector Styling */
.page-size-selector-wrap {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.8rem;
    color: var(--obsidian-text-secondary);
    margin-left: auto;
}

.page-size-label {
    font-weight: 600;
    font-size: 0.76rem;
    user-select: none;
    letter-spacing: 0.01em;
}

/* ── Custom Dropdown ─────────────────────────────── */
.custom-dropdown {
    position: relative;
    display: inline-flex;
}

.custom-dropdown-trigger {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: rgba(15, 23, 42, 0.55);
    border: 1px solid rgba(148, 163, 184, 0.18);
    color: var(--obsidian-text-primary);
    padding: 0.32rem 0.7rem;
    border-radius: 10px;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    outline: none;
    user-select: none;
    font-family: inherit;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 1px 4px rgba(0,0,0,0.2), inset 0 1px 0 rgba(255,255,255,0.05);
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
    min-width: 68px;
}

.custom-dropdown-trigger:hover {
    border-color: rgba(56, 189, 248, 0.45);
    background: rgba(30, 41, 59, 0.7);
    box-shadow: 0 0 0 1px rgba(56,189,248,0.15), 0 2px 8px rgba(0,0,0,0.25);
}

.custom-dropdown.open .custom-dropdown-trigger {
    border-color: var(--obsidian-primary);
    box-shadow: 0 0 0 1.5px rgba(56,189,248,0.35), 0 2px 12px rgba(56,189,248,0.15);
    background: rgba(30, 41, 59, 0.8);
}

.custom-dropdown-chevron {
    font-size: 0.58rem;
    opacity: 0.7;
    transition: transform 0.22s cubic-bezier(0.4,0,0.2,1);
    color: var(--obsidian-text-secondary);
    flex-shrink: 0;
}

.custom-dropdown.open .custom-dropdown-chevron {
    transform: rotate(180deg);
    opacity: 1;
    color: var(--obsidian-primary);
}

.custom-dropdown-value {
    min-width: 2.4ch;
    text-align: left;
}

/* Dropdown panel */
.custom-dropdown-menu {
    display: none;
    position: absolute;
    bottom: calc(100% + 6px);
    right: 0;
    min-width: 100%;
    list-style: none;
    margin: 0;
    padding: 0.3rem;
    background: rgba(13, 22, 40, 0.92);
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 12px;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 8px 32px rgba(0,0,0,0.45), 0 0 0 1px rgba(56,189,248,0.08);
    z-index: 9999;
    transform-origin: bottom center;
    animation: dropdownFadeIn 0.18s cubic-bezier(0.4,0,0.2,1);
}

.custom-dropdown.open .custom-dropdown-menu {
    display: block;
}

@keyframes dropdownFadeIn {
    from { opacity: 0; transform: scaleY(0.88) translateY(4px); }
    to   { opacity: 1; transform: scaleY(1)   translateY(0);    }
}

.custom-dropdown-option {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.38rem 0.8rem;
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--obsidian-text-primary);
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
    user-select: none;
}

.custom-dropdown-option:hover {
    background: rgba(56, 189, 248, 0.12);
    color: var(--obsidian-primary);
}

.custom-dropdown-option.active {
    background: rgba(56, 189, 248, 0.18);
    color: var(--obsidian-primary);
    font-weight: 800;
}

/* Light theme overrides */
[data-theme="light"] .custom-dropdown-trigger {
    background: rgba(248, 250, 252, 0.9);
    border-color: rgba(37, 99, 235, 0.2);
    color: #1e293b;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08), inset 0 1px 0 rgba(255,255,255,0.8);
}

[data-theme="light"] .custom-dropdown-trigger:hover {
    border-color: rgba(37, 99, 235, 0.4);
    background: #ffffff;
    box-shadow: 0 0 0 1px rgba(37,99,235,0.12), 0 2px 8px rgba(0,0,0,0.08);
}

[data-theme="light"] .custom-dropdown.open .custom-dropdown-trigger {
    border-color: #2563eb;
    box-shadow: 0 0 0 1.5px rgba(37,99,235,0.3);
}

[data-theme="light"] .custom-dropdown-chevron {
    color: #64748b;
}

[data-theme="light"] .custom-dropdown.open .custom-dropdown-chevron {
    color: #2563eb;
}

[data-theme="light"] .custom-dropdown-menu {
    background: rgba(255, 255, 255, 0.97);
    border-color: rgba(37, 99, 235, 0.15);
    box-shadow: 0 8px 32px rgba(0,0,0,0.12), 0 0 0 1px rgba(37,99,235,0.06);
}

[data-theme="light"] .custom-dropdown-option {
    color: #1e293b;
}

[data-theme="light"] .custom-dropdown-option:hover {
    background: rgba(37, 99, 235, 0.08);
    color: #2563eb;
}

[data-theme="light"] .custom-dropdown-option.active {
    background: rgba(37, 99, 235, 0.12);
    color: #2563eb;

