/* assets/css/style.css */

/* Import Outfit or Inter font */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    color-scheme: dark;
    --bg-primary: #060608;
    --bg-secondary: #0d0d11;
    --bg-card: rgba(22, 22, 26, 0.7);
    --border-color: rgba(255, 255, 255, 0.06);
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --accent: #e50914;
    --accent-hover: #ff1e27;
    --accent-glow: rgba(229, 9, 20, 0.18);
    --success: #10b981;
    --success-bg: rgba(16, 185, 129, 0.1);
    --warning: #f59e0b;
    --warning-bg: rgba(245, 158, 11, 0.1);
    --danger: #ef4444;
    --danger-bg: rgba(239, 68, 68, 0.1);
    --info: #3b82f6;
    --info-bg: rgba(59, 130, 246, 0.1);
    --font-sans: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --sidebar-width: 260px;
    --border-radius: 16px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    color-scheme: dark;
}

body {
    font-family: var(--font-sans);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    overflow-x: hidden;
    color-scheme: dark;
}

/* App Container Layout */
.app-container {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

/* Sidebar Styling */
.sidebar {
    width: var(--sidebar-width);
    background-color: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    padding: 1.5rem 1.25rem;
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 100;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE / Edge */
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1), padding 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar::-webkit-scrollbar {
    display: none;
    width: 0;
    height: 0;
}

.sidebar-header-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-bottom: 2rem;
    position: relative;
    gap: 0.5rem;
}

.brand-section {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0;
}

.brand-logo-full {
    display: block;
    transition: var(--transition);
}

.brand-logo-mini {
    display: none;
    transition: var(--transition);
}

.brand-badge {
    background: var(--accent-glow);
    color: var(--accent-hover);
    font-size: 0.7rem;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    border: 1px solid rgba(229, 9, 20, 0.2);
    font-weight: 600;
    letter-spacing: 0.5px;
}

.btn-toggle-sidebar {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
    flex-shrink: 0;
}

.btn-toggle-sidebar:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--accent);
}

.btn-toggle-sidebar svg {
    width: 16px;
    height: 16px;
    transition: transform 0.3s ease;
}

.btn-sidebar-close {
    display: none;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    color: #fff;
    cursor: pointer;
    transition: var(--transition);
    flex-shrink: 0;
}

.btn-sidebar-close:hover {
    background: rgba(229, 9, 20, 0.2);
    border-color: var(--accent);
    color: var(--accent-hover);
}

.btn-topbar-toggle {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    cursor: pointer;
    transition: var(--transition);
    flex-shrink: 0;
}

.btn-topbar-toggle:hover {
    background: rgba(229, 9, 20, 0.15);
    border-color: var(--accent);
    color: var(--accent-hover);
}

.btn-topbar-toggle svg {
    width: 20px;
    height: 20px;
}

/* Sidebar Collapsed State on Desktop */
.app-container.sidebar-collapsed .sidebar {
    width: 76px;
    padding: 1.5rem 0.5rem;
}

.app-container.sidebar-collapsed .sidebar .brand-logo-full,
.app-container.sidebar-collapsed .sidebar .brand-badge,
.app-container.sidebar-collapsed .sidebar .nav-item span {
    display: none !important;
}

.app-container.sidebar-collapsed .sidebar .brand-logo-mini {
    display: block !important;
}

.app-container.sidebar-collapsed .sidebar .brand-section {
    margin-bottom: 1rem;
    justify-content: center;
    width: 100%;
}

.app-container.sidebar-collapsed .sidebar-header-wrapper {
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.app-container.sidebar-collapsed .btn-toggle-sidebar svg {
    transform: rotate(180deg);
}

.app-container.sidebar-collapsed .main-content {
    margin-left: 76px !important;
    width: calc(100% - 76px) !important;
    max-width: calc(100% - 76px) !important;
}

.app-container.sidebar-collapsed .nav-item a {
    justify-content: center;
    padding: 0.85rem 0.5rem;
}

.sidebar-backdrop {
    display: none;
}

.nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    flex: 1;
}

.nav-item a {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.85rem 1rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--border-radius);
    font-weight: 500;
    transition: var(--transition);
}

.nav-item a:hover, 
.nav-item.active a {
    color: var(--text-primary);
    background-color: rgba(255, 255, 255, 0.05);
}

.nav-item.active a {
    background-color: var(--accent);
    box-shadow: 0 4px 20px var(--accent-glow);
}

.nav-item a svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
}

/* Main Content Styling */
.main-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    min-width: 0;
    max-width: calc(100% - var(--sidebar-width));
    width: calc(100% - var(--sidebar-width));
    padding: 1.5rem 1.5rem;
    min-height: 100vh;
    box-sizing: border-box;
    transition: margin-left 0.3s cubic-bezier(0.4, 0, 0.2, 1), padding 0.3s cubic-bezier(0.4, 0, 0.2, 1), max-width 0.3s cubic-bezier(0.4, 0, 0.2, 1), width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Header */
.top-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
}

.page-title h1 {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.page-title p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

.header-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.header-actions .btn {
    white-space: nowrap;
    flex-shrink: 0;
}

/* Sheet Views Header (Ficha Técnica y Ficha de Cierre) */
.sheet-top-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.85rem;
    margin-bottom: 1.2rem;
    flex-wrap: wrap;
}

.sheet-top-header .header-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-shrink: 0;
    flex-wrap: nowrap;
}

.sheet-top-header .btn {
    padding: 0.42rem 0.75rem !important;
    font-size: 0.82rem !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 0.35rem !important;
}

.sheet-top-header .page-title h1 {
    font-size: 1.45rem;
}

/* Cards & Grid Layouts */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.stat-card {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.stat-info h3 {
    font-size: 0.85rem;
    text-transform: uppercase;
    color: var(--text-secondary);
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.stat-info .value {
    font-size: 1.75rem;
    font-weight: 700;
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-icon svg {
    width: 24px;
    height: 24px;
}

/* Tables and Lists */
.data-section {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 2.5rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
}

.table-wrapper {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

th {
    padding: 1rem;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.85rem;
    border-bottom: 1px solid var(--border-color);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

th:last-child,
th.th-actions {
    text-align: center;
}

td {
    padding: 1.2rem 1rem;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.95rem;
    vertical-align: middle;
}

td[data-label="Acciones"] {
    text-align: center;
    white-space: nowrap !important;
}

.action-buttons-inline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    white-space: nowrap;
    flex-wrap: nowrap;
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    background-color: rgba(255, 255, 255, 0.02);
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-success { background: var(--success-bg); color: var(--success); }
.badge-warning { background: var(--warning-bg); color: var(--warning); }
.badge-danger { background: var(--danger-bg); color: var(--danger); }
.badge-info { background: var(--info-bg); color: var(--info); }

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.65rem 1.25rem;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.btn-primary {
    background: var(--accent);
    color: var(--text-primary);
}

.btn-primary:hover {
    background: var(--accent-hover);
    box-shadow: 0 0 15px var(--accent-glow);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
}

/* Forms & Modals */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(11, 15, 25, 0.8);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.modal.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    width: 100%;
    max-width: 650px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 2rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    transform: scale(0.95);
    transition: transform 0.3s ease;
}

.modal.active .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
}

.modal-header h2 {
    font-size: 1.25rem;
    font-weight: 700;
}

.close-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    transition: var(--transition);
}

.close-btn:hover {
    color: var(--text-primary);
}

/* Form Layout */
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    margin-bottom: 1.25rem;
    width: 100%;
    box-sizing: border-box;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-width: 0;
    width: 100%;
    box-sizing: border-box;
}

.form-group.full-width {
    grid-column: span 2;
}

label {
    font-size: 0.82rem;
    color: var(--text-secondary);
    font-weight: 500;
    white-space: normal;
    word-break: break-word;
    line-height: 1.25;
}

input, select, textarea {
    color-scheme: dark;
    background: #121217;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    padding: 0.65rem 0.85rem;
    color: #ffffff;
    font-family: var(--font-sans);
    font-size: 0.9rem;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
    transition: var(--transition);
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 12px var(--accent-glow);
    background: #181822;
}

/* Select and Dropdown Options (Contraste neutro y letras claras sin colores llamativos) */
select {
    color-scheme: dark;
    background-color: #121217;
    color: #ffffff;
    cursor: pointer;
    text-overflow: ellipsis;
    white-space: nowrap;
}

select option {
    background-color: #1a1a22 !important;
    color: #ffffff !important;
    padding: 10px 14px !important;
    font-size: 0.95rem !important;
    font-weight: 500 !important;
}

select option:checked {
    background-color: #2d2d3d !important;
    color: #ffffff !important;
    font-weight: 600 !important;
}

select option:hover,
select option:focus {
    background-color: #282836 !important;
    color: #ffffff !important;
}

.header-actions select {
    background-color: #14141c;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.16);
    font-weight: 500;
}

/* Vehicle Detail view CSS */
.vehicle-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 2rem;
}

.vehicle-visual-panel {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.vehicle-visual-panel svg {
    width: 80px;
    height: 80px;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.specs-list {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.spec-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    padding: 0.75rem;
    border-radius: 8px;
}

.spec-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.spec-value {
    font-size: 1rem;
    font-weight: 600;
    margin-top: 0.25rem;
}

/* ==========================================================================
   PORTAL DE BIENVENIDA (INDEX PORTAL)
   ========================================================================== */
#welcome-portal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: radial-gradient(circle at center, #101014 0%, #040406 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), 
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

#welcome-portal::before {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(229, 9, 20, 0.12) 0%, transparent 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    animation: pulseGlow 4s infinite alternate;
}

#welcome-portal.fade-out {
    opacity: 0;
    transform: scale(1.08);
    pointer-events: none;
}

.portal-card {
    background: rgba(13, 13, 17, 0.6);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 3.5rem 3rem;
    border-radius: 28px;
    text-align: center;
    max-width: 480px;
    width: 90%;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.8),
                0 0 40px rgba(229, 9, 20, 0.05);
    z-index: 10;
    transform: translateY(0);
    animation: floatCard 6s ease-in-out infinite;
}

.portal-logo-glow {
    filter: drop-shadow(0 0 15px rgba(229, 9, 20, 0.35));
    margin-bottom: 2rem;
    animation: floatLogo 4s ease-in-out infinite;
}

.portal-subtitle {
    font-size: 0.8rem;
    letter-spacing: 3px;
    color: var(--text-secondary);
    text-transform: uppercase;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.portal-title {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 2rem;
    background: linear-gradient(180deg, #ffffff 0%, #a1a1aa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.5px;
}

.btn-portal {
    width: 100%;
    padding: 1.1rem !important;
    font-size: 1.05rem !important;
    border-radius: 14px !important;
    background: linear-gradient(135deg, #e50914 0%, #b91c1c 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 4px 25px rgba(229, 9, 20, 0.3) !important;
    transition: all 0.4s ease !important;
    position: relative;
    overflow: hidden;
}

.btn-portal:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(229, 9, 20, 0.5) !important;
    background: linear-gradient(135deg, #ff1e27 0%, #e50914 100%) !important;
}

.btn-portal::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -60%;
    width: 30%;
    height: 200%;
    background: rgba(255, 255, 255, 0.15);
    transform: rotate(35deg);
    transition: all 0.6s ease;
    opacity: 0;
}

.btn-portal:hover::after {
    left: 130%;
    opacity: 1;
}

.portal-footer {
    margin-top: 2.5rem;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.25);
    letter-spacing: 0.5px;
}

/* Animaciones */
@keyframes floatCard {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
    100% { transform: translateY(0px); }
}

@keyframes floatLogo {
    0% { transform: translateY(0px) scale(1); }
    50% { transform: translateY(-5px) scale(1.02); }
    100% { transform: translateY(0px) scale(1); }
}

@keyframes pulseGlow {
    0% { opacity: 0.6; width: 250px; height: 250px; }
    100% { opacity: 1; width: 350px; height: 350px; }
}

/* ==========================================================================
   SISTEMA DE DISEÑO TOTALMENTE RESPONSIVO (DESKTOP, TABLET Y MÓVIL)
   ========================================================================== */

/* Barra Inferior de Navegación Rápida Móvil (Mobile Bottom Bar) */
.mobile-bottom-nav {
    display: none;
}

/* 1. TABLETS Y PANTALLAS MEDIANAS (<= 1024px) */
@media (max-width: 1024px) {
    .sidebar {
        width: 76px;
        padding: 1.5rem 0.5rem;
    }
    
    .sidebar .brand-logo-full,
    .sidebar .brand-badge,
    .sidebar .nav-item span {
        display: none !important;
    }
    
    .sidebar .brand-logo-mini {
        display: block !important;
    }
    
    .sidebar .brand-section {
        justify-content: center;
        margin-bottom: 1rem;
        width: 100%;
    }
    
    .sidebar-header-wrapper {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
        margin-bottom: 1.5rem;
    }
    
    .sidebar .nav-item a {
        justify-content: center;
        padding: 0.85rem 0.5rem;
    }
    
    .main-content {
        margin-left: 76px !important;
        width: calc(100% - 76px) !important;
        max-width: calc(100% - 76px) !important;
        padding: 1.5rem 1.25rem;
    }
    
    .dash-kpi-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 1rem;
    }
    
    .vehicle-sheet-layout,
    .prep-sheet-layout,
    #vehicle-form-view .vehicle-sheet-layout,
    #preparation-form-view .prep-sheet-layout {
        grid-template-columns: 1fr !important;
        gap: 1.25rem !important;
    }
}

/* 2. DISPOSITIVOS MÓVILES (SMARTPHONES Y TABLETS PEQUEÑAS <= 768px) */
@media (max-width: 768px) {
    html, body {
        overflow-x: hidden !important;
        width: 100% !important;
    }
    
    body {
        flex-direction: column;
    }
    
    .app-container {
        flex-direction: column;
        width: 100%;
        min-width: 0;
    }
    
    /* Menú lateral convertido en Cajón Deslizante (Off-canvas Drawer) */
    .sidebar {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 285px !important;
        max-width: 85vw !important;
        height: 100vh !important;
        height: 100dvh !important;
        z-index: 2500 !important;
        transform: translateX(-100%) !important;
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
        background: #0e0e13 !important;
        box-shadow: 12px 0 45px rgba(0, 0, 0, 0.85) !important;
        padding: 1.5rem 1.25rem !important;
        border-right: 1px solid var(--border-color) !important;
        display: flex !important;
        flex-direction: column !important;
        overflow-y: auto !important;
    }
    
    body.sidebar-mobile-open .sidebar,
    .app-container.sidebar-mobile-open .sidebar {
        transform: translateX(0) !important;
    }
    
    /* Telón de fondo oscuro al abrir el menú en móvil */
    .sidebar-backdrop {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        background: rgba(0, 0, 0, 0.75) !important;
        backdrop-filter: blur(5px) !important;
        -webkit-backdrop-filter: blur(5px) !important;
        z-index: 2400 !important;
        opacity: 0 !important;
        pointer-events: none !important;
        transition: opacity 0.3s ease !important;
        display: block !important;
    }
    
    body.sidebar-mobile-open .sidebar-backdrop,
    .app-container.sidebar-mobile-open .sidebar-backdrop {
        opacity: 1 !important;
        pointer-events: auto !important;
    }
    
    .sidebar-header-wrapper {
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        margin-bottom: 2rem !important;
        width: 100% !important;
    }
    
    .sidebar .brand-section {
        flex-direction: column !important;
        align-items: flex-start !important;
        margin-bottom: 0 !important;
        width: auto !important;
    }
    
    .sidebar .brand-logo-full {
        display: block !important;
    }
    
    .sidebar .brand-logo-mini {
        display: none !important;
    }
    
    .sidebar .brand-badge {
        display: inline-block !important;
    }
    
    .sidebar .btn-toggle-sidebar {
        display: none !important;
    }
    
    .btn-sidebar-close {
        display: flex !important;
    }
    
    .sidebar .nav-links {
        width: 100% !important;
        flex-direction: column !important;
        gap: 0.5rem !important;
    }
    
    .sidebar .nav-item a {
        flex-direction: row !important;
        justify-content: flex-start !important;
        gap: 1rem !important;
        padding: 0.85rem 1rem !important;
        font-size: 0.95rem !important;
        border-radius: var(--border-radius) !important;
    }
    
    .sidebar .nav-item span {
        display: inline !important;
    }
    
    /* Contenido Principal en Móvil */
    .main-content {
        margin-left: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        padding: 1rem 0.85rem 90px 0.85rem !important; /* Espacio inferior para no tapar con la barra */
        box-sizing: border-box !important;
    }
    
    /* Barra de Navegación Inferior en Móvil (Thumb-friendly Bottom Bar) */
    .mobile-bottom-nav {
        display: flex !important;
        position: fixed !important;
        bottom: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 62px !important;
        height: calc(58px + env(safe-area-inset-bottom, 0px)) !important;
        padding-bottom: env(safe-area-inset-bottom, 0px) !important;
        background: rgba(13, 13, 18, 0.95) !important;
        backdrop-filter: blur(20px) !important;
        -webkit-backdrop-filter: blur(20px) !important;
        border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
        z-index: 2000 !important;
        align-items: center !important;
        justify-content: space-around !important;
        box-shadow: 0 -8px 30px rgba(0, 0, 0, 0.6) !important;
        box-sizing: border-box !important;
    }
    
    .mobile-nav-item {
        flex: 1 !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 3px !important;
        color: var(--text-secondary) !important;
        text-decoration: none !important;
        font-size: 0.7rem !important;
        font-weight: 600 !important;
        padding: 6px 2px !important;
        background: none !important;
        border: none !important;
        cursor: pointer !important;
        transition: var(--transition) !important;
        -webkit-tap-highlight-color: transparent !important;
    }
    
    .mobile-nav-item svg {
        width: 20px !important;
        height: 20px !important;
        stroke: currentColor !important;
        transition: transform 0.2s ease !important;
    }
    
    .mobile-nav-item:hover,
    .mobile-nav-item.active {
        color: #ffffff !important;
    }
    
    .mobile-nav-item.active svg {
        stroke: var(--accent) !important;
        filter: drop-shadow(0 0 8px var(--accent-glow)) !important;
        transform: scale(1.08) !important;
    }
    
    /* Cabeceras de Vistas en Móvil */
    .top-header {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.85rem !important;
        margin-bottom: 1.25rem !important;
    }
    
    .page-title h1 {
        font-size: 1.35rem !important;
        line-height: 1.2 !important;
    }
    
    .page-title p {
        font-size: 0.8rem !important;
    }
    
    .header-actions {
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 0.5rem !important;
        width: 100% !important;
    }
    
    .header-actions input,
    .header-actions select {
        width: 100% !important;
        max-width: 100% !important;
        flex: 1 1 130px !important;
        font-size: 16px !important; /* Evita que Safari/Chrome en iOS haga auto-zoom */
        min-height: 42px !important;
    }
    
    .header-actions .btn {
        width: 100% !important;
        justify-content: center !important;
        min-height: 42px !important;
    }
    
    /* Cabeceras de Fichas Técnicas (Sheet Top Headers) */
    .sheet-top-header {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0.75rem !important;
    }
    
    .sheet-top-header .header-actions {
        width: 100% !important;
        margin-left: 0 !important;
        justify-content: flex-end !important;
        display: flex !important;
        flex-wrap: wrap !important;
        gap: 0.5rem !important;
    }
    
    .sheet-top-header .header-actions .btn {
        flex: 1 1 auto !important;
        width: auto !important;
    }
    
    /* Tablas con scroll horizontal suave y táctil */
    .data-section {
        padding: 1rem !important;
        margin-bottom: 1.5rem !important;
        border-radius: 12px !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    .table-wrapper {
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch !important;
        border-radius: 10px !important;
        margin: 0 -0.5rem !important;
        padding: 0 0.5rem !important;
        width: calc(100% + 1rem) !important;
    }
    
    .table-wrapper table {
        min-width: 620px !important;
    }
    
    th, td {
        padding: 0.85rem 0.65rem !important;
        font-size: 0.85rem !important;
    }
    
    .action-buttons-inline {
        display: inline-flex !important;
        gap: 0.35rem !important;
        flex-wrap: nowrap !important;
    }
    
    .action-buttons-inline .btn {
        padding: 0.38rem 0.65rem !important;
        font-size: 0.78rem !important;
    }
    
    /* Formularios y Modales en Móvil */
    .form-grid {
        grid-template-columns: 1fr !important;
        gap: 0.75rem !important;
    }
    
    .form-group.full-width {
        grid-column: span 1 !important;
    }
    
    .sheet-grid-2,
    .sheet-grid-3,
    .sheet-grid-4 {
        grid-template-columns: 1fr !important;
        gap: 0.75rem !important;
    }
    
    .sheet-spec-item[style*="grid-column: span 2"] {
        grid-column: span 1 !important;
    }
    
    .modal-content {
        margin: 10px !important;
        padding: 1.25rem 1rem !important;
        max-height: 92vh !important;
        width: calc(100% - 20px) !important;
        max-width: 100% !important;
        border-radius: 16px !important;
    }
    
    .vehicle-detail-grid {
        grid-template-columns: 1fr !important;
        gap: 1.25rem !important;
    }
    
    .specs-list {
        grid-template-columns: 1fr !important;
    }
    
    .spec-item {
        grid-column: span 1 !important;
    }
    
    /* Catálogo Digital en Móvil */
    #catalog-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    
    /* Ajustes Dashboard en Móvil */
    .dash-kpi-grid {
        grid-template-columns: 1fr !important;
        gap: 0.85rem !important;
    }
    
    .stats-grid {
        grid-template-columns: 1fr 1fr !important;
        gap: 0.75rem !important;
    }
    
    .stat-card {
        padding: 1rem 0.85rem !important;
    }
    
    .stat-card .value {
        font-size: 1.35rem !important;
    }
    
    /* Inputs y controles táctiles de tamaño cómodo */
    input, select, textarea {
        font-size: 16px !important; /* Previene auto-zoom en navegadores móviles */
        padding: 0.75rem 0.85rem !important;
    }
}

/* 3. TELÉFONOS MUY PEQUEÑOS (<= 480px) */
@media (max-width: 480px) {
    .main-content {
        padding: 0.85rem 0.65rem 90px 0.65rem !important;
    }
    
    .page-title h1 {
        font-size: 1.2rem !important;
    }
    
    .stats-grid {
        grid-template-columns: 1fr !important;
        gap: 0.65rem !important;
    }
    
    .sheet-card {
        padding: 1rem 0.85rem !important;
        margin-bottom: 1rem !important;
        border-radius: 12px !important;
    }
    
    .btn {
        font-size: 0.85rem !important;
        padding: 0.65rem 1rem !important;
    }
}

/* ==========================================================================
   ELEMENTOS EXCLUSIVOS DE IMPRESIÓN (OCULTOS EN PANTALLA)
   ========================================================================== */
.print-only,
.print-official-header,
.print-signatures-block,
.print-legal-footer {
    display: none !important;
}

/* ==========================================================================
   ESTILOS DE IMPRESIÓN PROFESIONAL (FICHA TÉCNICA Y CIERRE DE VENTA)
   ========================================================================== */
@media print {
    @page {
        size: letter portrait;
        margin: 10mm 12mm 10mm 12mm;
    }

    *, *::before, *::after {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }

    html, body {
        background: #ffffff !important;
        color: #0f172a !important;
        font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important;
        font-size: 9.5pt !important;
        line-height: 1.4 !important;
        width: 100% !important;
        height: auto !important;
        min-height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
        overflow: visible !important;
    }

    /* Ocultar interfaz del sistema, navegación, botones y barras laterales */
    .sidebar,
    .btn-toggle-sidebar,
    .btn-topbar-toggle,
    #sidebar-toggle-btn,
    .top-header button,
    .top-header .btn,
    .header-actions,
    .close-btn,
    .btn-close-modal,
    #btn-edit-vehicle-admin,
    .btn,
    button,
    .no-print {
        display: none !important;
    }

    /* CASO 1: CUANDO HAY UN MODAL ABIERTO (ej. Ficha de Venta #modal-sale-detail) */
    body.modal-open .app-container,
    body:has(.modal.active) .app-container {
        display: none !important;
    }

    body.modal-open .modal.active,
    body:has(.modal.active) .modal.active {
        display: block !important;
        position: static !important;
        width: 100% !important;
        height: auto !important;
        background: #ffffff !important;
        padding: 0 !important;
        margin: 0 !important;
        backdrop-filter: none !important;
    }

    .modal.active .modal-content {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        background: #ffffff !important;
        color: #0f172a !important;
        border: none !important;
        padding: 0 !important;
        margin: 0 !important;
        transform: none !important;
        max-height: none !important;
        overflow: visible !important;
    }

    .modal.active .modal-header {
        border-bottom: 2px solid #0f172a !important;
        padding-bottom: 0.5rem !important;
        margin-bottom: 1rem !important;
    }

    .modal.active .modal-header h2 {
        color: #0f172a !important;
        font-size: 1.4rem !important;
        font-weight: 800 !important;
    }

    .modal.active .modal-content > div:last-child {
        display: none !important;
    }

    .modal.active .vehicle-detail-grid {
        display: grid !important;
        grid-template-columns: 240px 1fr !important;
        gap: 1.5rem !important;
    }

    .modal.active .vehicle-visual-panel {
        background: #f8fafc !important;
        border: 1px solid #cbd5e1 !important;
        border-radius: 8px !important;
        padding: 1rem !important;
        color: #0f172a !important;
    }

    .modal.active .vehicle-visual-panel h3 {
        color: #16a34a !important;
    }

    .modal.active .vehicle-visual-panel strong,
    .modal.active .vehicle-visual-panel span {
        color: #0f172a !important;
    }

    .modal.active .specs-list {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.5rem !important;
    }

    .modal.active .spec-item {
        background: #f8fafc !important;
        border: 1px solid #e2e8f0 !important;
        padding: 0.5rem !important;
        border-radius: 6px !important;
    }

    .modal.active .spec-label {
        color: #64748b !important;
        font-size: 0.7rem !important;
        font-weight: 700 !important;
        text-transform: uppercase !important;
    }

    .modal.active .spec-value {
        color: #0f172a !important;
        font-size: 0.9rem !important;
        font-weight: 700 !important;
    }

    /* CASO 2: IMPRESIÓN DE LA FICHA TÉCNICA A PÁGINA COMPLETA (#vehicle-detail-view) */
    .app-container {
        display: block !important;
        width: 100% !important;
        min-height: auto !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    .main-content {
        margin: 0 !important;
        padding: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        min-height: auto !important;
    }

    /* Ocultar todas las demás vistas que no sean vehicle-detail-view o sale-detail-view */
    #dashboard-view,
    #vehicles-view,
    #sales-view,
    #reports-view,
    #preparations-view,
    #catalog-view,
    #sale-registration-view {
        display: none !important;
    }

    #vehicle-detail-view[style*="display: none"],
    #sale-detail-view[style*="display: none"] {
        display: none !important;
    }

    #vehicle-detail-view,
    #sale-detail-view {
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    #vehicle-detail-view .top-header,
    #sale-detail-view .top-header {
        display: none !important;
    }

    /* ENCABEZADO OFICIAL DE IMPRESIÓN */
    .print-official-header {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        border-bottom: 2.5px solid #0f172a !important;
        padding-bottom: 0.75rem !important;
        margin-bottom: 1.25rem !important;
        page-break-inside: avoid !important;
        break-inside: avoid !important;
    }

    .print-brand-name {
        font-size: 1.8rem !important;
        font-weight: 900 !important;
        color: #0f172a !important;
        letter-spacing: -0.5px !important;
        line-height: 1 !important;
    }

    .print-brand-name .brand-red {
        color: #e50914 !important;
    }

    .print-brand-tagline {
        font-size: 0.75rem !important;
        font-weight: 800 !important;
        color: #334155 !important;
        margin-top: 0.35rem !important;
        letter-spacing: 0.5px !important;
        text-transform: uppercase !important;
    }

    .print-brand-sub {
        font-size: 0.7rem !important;
        color: #64748b !important;
    }

    .print-header-meta {
        text-align: right !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-end !important;
        gap: 0.2rem !important;
    }

    .print-meta-item {
        font-size: 0.8rem !important;
        color: #334155 !important;
    }

    /* GRILLA Y TARJETAS DE LA FICHA TÉCNICA */
    .vehicle-sheet-layout {
        display: grid !important;
        grid-template-columns: 270px 1fr !important;
        gap: 1.25rem !important;
        align-items: start !important;
    }

    .sheet-left-column,
    .sheet-right-column {
        display: flex !important;
        flex-direction: column !important;
    }

    .sheet-card {
        background: #ffffff !important;
        color: #0f172a !important;
        border: 1px solid #cbd5e1 !important;
        border-radius: 8px !important;
        padding: 1rem !important;
        margin-bottom: 1rem !important;
        page-break-inside: avoid !important;
        break-inside: avoid !important;
    }

    .sheet-card * {
        color: #0f172a;
    }

    .sheet-card-header {
        border-bottom: 1.5px solid #e2e8f0 !important;
        padding-bottom: 0.4rem !important;
        margin-bottom: 0.75rem !important;
    }

    .sheet-card-title {
        color: #0f172a !important;
        font-size: 0.95rem !important;
        font-weight: 800 !important;
    }

    .sheet-card h2,
    .sheet-card h3,
    .sheet-card h4 {
        color: #0f172a !important;
    }

    .sheet-card img {
        display: block !important;
        max-height: 180px !important;
        object-fit: cover !important;
        border: 1px solid #cbd5e1 !important;
        border-radius: 6px !important;
    }

    .sheet-card div[style*="height: 240px"],
    .sheet-card div[style*="height: 200px"] {
        height: 180px !important;
        background: #f1f5f9 !important;
        border: 1px solid #cbd5e1 !important;
    }

    .sheet-card div[style*="rgba(34, 197, 94"] {
        background: #f0fdf4 !important;
        border: 1.5px solid #86efac !important;
        padding: 0.75rem !important;
        margin-bottom: 0.75rem !important;
    }

    .sheet-card div[style*="color: #4ade80"] {
        color: #16a34a !important;
        font-size: 1.5rem !important;
    }

    .sheet-card div[style*="grid-template-columns: 1fr 1fr"] {
        background: #f8fafc !important;
        border: 1px solid #e2e8f0 !important;
        padding: 0.6rem !important;
    }

    .sheet-card strong[style*="color: var(--danger)"] {
        color: #dc2626 !important;
    }

    .sheet-card strong[style*="color: var(--info)"] {
        color: #2563eb !important;
    }

    .doc-pill {
        background: #f8fafc !important;
        border: 1px solid #e2e8f0 !important;
        padding: 0.45rem 0.65rem !important;
        margin-bottom: 0.4rem !important;
        border-radius: 6px !important;
    }

    .doc-pill div {
        color: #0f172a !important;
    }

    .sheet-grid-2 {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 0.6rem !important;
    }

    .sheet-grid-3 {
        display: grid !important;
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 0.5rem !important;
    }

    .sheet-spec-item {
        background: #f8fafc !important;
        border: 1px solid #e2e8f0 !important;
        padding: 0.45rem 0.65rem !important;
        border-radius: 6px !important;
    }

    .sheet-spec-label {
        color: #64748b !important;
        font-size: 0.68rem !important;
        font-weight: 700 !important;
        text-transform: uppercase !important;
        letter-spacing: 0.3px !important;
    }

    .sheet-spec-value {
        color: #0f172a !important;
        font-size: 0.88rem !important;
        font-weight: 700 !important;
    }

    .plate-badge {
        background: #ffffff !important;
        color: #000000 !important;
        font-family: 'Consolas', 'Courier New', monospace !important;
        font-size: 1.1rem !important;
        font-weight: 900 !important;
        letter-spacing: 2px !important;
        padding: 0.25rem 0.75rem !important;
        border: 2.5px solid #000000 !important;
        box-shadow: none !important;
        border-radius: 5px !important;
    }

    .plate-badge-sm {
        background: #ffffff !important;
        color: #000000 !important;
        font-family: 'Consolas', 'Courier New', monospace !important;
        font-size: 0.8rem !important;
        font-weight: 900 !important;
        letter-spacing: 1px !important;
        padding: 0.15rem 0.5rem !important;
        border: 1.8px solid #000000 !important;
        box-shadow: none !important;
    }

    .vin-plate {
        background: #f1f5f9 !important;
        color: #0f172a !important;
        font-family: 'Consolas', 'Courier New', monospace !important;
        font-size: 0.95rem !important;
        font-weight: 800 !important;
        border: 1.5px solid #94a3b8 !important;
        box-shadow: none !important;
        padding: 0.35rem 0.75rem !important;
        letter-spacing: 1.5px !important;
    }

    .badge {
        display: inline-block !important;
        padding: 0.2rem 0.55rem !important;
        border-radius: 4px !important;
        font-size: 0.72rem !important;
        font-weight: 800 !important;
        border: 1px solid #94a3b8 !important;
        text-transform: uppercase !important;
    }

    .badge-success {
        background: #dcfce7 !important;
        color: #15803d !important;
        border-color: #86efac !important;
    }

    .badge-info {
        background: #dbeafe !important;
        color: #1d4ed8 !important;
        border-color: #93c5fd !important;
    }

    .badge-warning {
        background: #fef3c7 !important;
        color: #b45309 !important;
        border-color: #fcd34d !important;
    }

    .badge-danger {
        background: #fee2e2 !important;
        color: #b91c1c !important;
        border-color: #fca5a5 !important;
    }

    .sheet-card div[style*="line-height: 1.6"] {
        background: #f8fafc !important;
        border: 1px solid #e2e8f0 !important;
        color: #1e293b !important;
        padding: 0.75rem !important;
        font-size: 0.85rem !important;
    }

    .sheet-card div[style*="rgba(255,255,255,0.02)"] {
        background: #f8fafc !important;
        border: 1px solid #e2e8f0 !important;
        color: #1e293b !important;
    }

    .sheet-card strong[style*="color: var(--accent)"] {
        color: #e50914 !important;
    }

    .sheet-card[style*="border-color: rgba(34, 197, 94"] {
        border-color: #86efac !important;
        background: #f0fdf4 !important;
    }

    /* BLOQUE DE FIRMAS Y PIE LEGAL */
    .print-signatures-block {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 4rem !important;
        margin-top: 1.5rem !important;
        padding-top: 1.5rem !important;
        page-break-inside: avoid !important;
        break-inside: avoid !important;
    }

    .print-sig-col {
        text-align: center !important;
    }

    .sig-line {
        border-top: 1.5px solid #0f172a !important;
        width: 80% !important;
        margin: 0 auto 0.4rem auto !important;
    }

    .sig-name {
        font-size: 0.85rem !important;
        font-weight: 800 !important;
        color: #0f172a !important;
    }

    .sig-desc {
        font-size: 0.72rem !important;
        color: #64748b !important;
    }

    .print-legal-footer {
        display: block !important;
        font-size: 0.68rem !important;
        color: #64748b !important;
        text-align: center !important;
        border-top: 1px solid #cbd5e1 !important;
        padding-top: 0.5rem !important;
        margin-top: 1.25rem !important;
        page-break-inside: avoid !important;
        break-inside: avoid !important;
    }
}

/* ==========================================================================
   SIDEBAR DESPLEGABLE / CONTRAÍBLE (COLLAPSIBLE SIDEBAR)
   ========================================================================== */
.sidebar-header-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    margin-bottom: 1.5rem;
    position: relative;
}

.btn-toggle-sidebar {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.25s ease;
    flex-shrink: 0;
}

.btn-toggle-sidebar:hover {
    background: rgba(229, 9, 20, 0.15);
    border-color: var(--accent);
    color: #fff;
    box-shadow: 0 0 10px rgba(229, 9, 20, 0.2);
}

.btn-toggle-sidebar svg {
    width: 16px;
    height: 16px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-topbar-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.25s ease;
    flex-shrink: 0;
}

.btn-topbar-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border-color: var(--accent);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.btn-topbar-toggle svg {
    width: 20px;
    height: 20px;
}

.brand-logo-mini {
    display: none;
}

/* Modo Contraído para pantallas de escritorio/laptop */
@media (min-width: 769px) {
    .app-container.sidebar-collapsed {
        --sidebar-width: 76px;
    }

    .app-container.sidebar-collapsed .sidebar {
        width: 76px !important;
        padding: 1.25rem 0.5rem !important;
        align-items: center;
    }

    .app-container.sidebar-collapsed .main-content {
        margin-left: 76px !important;
        max-width: calc(100% - 76px) !important;
        width: calc(100% - 76px) !important;
        padding: 1.25rem 1rem !important;
    }

    .app-container.sidebar-collapsed .sidebar-header-wrapper {
        flex-direction: column;
        gap: 0.75rem;
        margin-bottom: 1.25rem;
    }

    .app-container.sidebar-collapsed .brand-section {
        margin-bottom: 0 !important;
    }

    .app-container.sidebar-collapsed .brand-logo-full {
        display: none !important;
    }

    .app-container.sidebar-collapsed .brand-logo-mini {
        display: flex !important;
        align-items: center;
        justify-content: center;
    }

    .app-container.sidebar-collapsed .btn-toggle-sidebar svg {
        transform: rotate(180deg);
    }

    .app-container.sidebar-collapsed .nav-links {
        align-items: center;
        width: 100%;
    }

    .app-container.sidebar-collapsed .nav-item {
        width: 100%;
    }

    .app-container.sidebar-collapsed .nav-item a {
        justify-content: center !important;
        padding: 0.85rem 0 !important;
        gap: 0 !important;
        position: relative;
    }

    .app-container.sidebar-collapsed .nav-item a span {
        display: none !important;
    }

    /* Tooltip flotante al pasar el cursor sobre los iconos */
    .app-container.sidebar-collapsed .nav-item a::after {
        content: attr(data-tooltip);
        position: absolute;
        left: calc(100% + 12px);
        top: 50%;
        transform: translateY(-50%) translateX(-6px);
        background: #141419;
        color: #fff;
        padding: 0.45rem 0.85rem;
        border-radius: 8px;
        font-size: 0.8rem;
        font-weight: 600;
        white-space: nowrap;
        box-shadow: 0 8px 25px rgba(0, 0, 0, 0.75);
        border: 1px solid rgba(255, 255, 255, 0.12);
        pointer-events: none;
        opacity: 0;
        transition: opacity 0.2s ease, transform 0.2s ease;
        z-index: 9999;
    }

    .app-container.sidebar-collapsed .nav-item a:hover::after {
        opacity: 1;
        transform: translateY(-50%) translateX(0);
    }
}

/* ===================================================
   FICHA COMPLETA DEL VEHÍCULO (FULL-PAGE DETAIL SHEET)
   =================================================== */
.vehicle-sheet-layout {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 1.75rem;
    align-items: start;
}

@media (max-width: 1024px) {
    .vehicle-sheet-layout {
        grid-template-columns: 1fr;
    }
}

.sheet-card {
    background: rgba(18, 18, 23, 0.7);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
    backdrop-filter: blur(10px);
}

.sheet-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.75rem;
}

.sheet-card-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #fff;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sheet-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.sheet-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.sheet-grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

@media (max-width: 768px) {
    .sheet-grid-2, .sheet-grid-3, .sheet-grid-4 {
        grid-template-columns: 1fr;
    }
}

.sheet-spec-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 0.85rem 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.sheet-spec-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-secondary);
    letter-spacing: 0.5px;
    font-weight: 600;
}

.sheet-spec-value {
    font-size: 0.95rem;
    font-weight: 600;
    color: #fff;
}

.vin-plate {
    background: linear-gradient(135deg, #18181f 0%, #25252e 100%);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    padding: 0.6rem 1rem;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 1rem;
    font-weight: 700;
    color: #f3f4f6;
    letter-spacing: 2px;
    display: inline-block;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.5);
}

.doc-pill {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    margin-bottom: 0.6rem;
}

.plate-badge {
    background: #ffffff;
    color: #111827;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 1.15rem;
    font-weight: 900;
    letter-spacing: 3px;
    padding: 0.35rem 1rem;
    border-radius: 6px;
    border: 2.5px solid #1f2937;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
}

.plate-badge-sm {
    background: #ffffff;
    color: #111827;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 0.8rem;
    font-weight: 900;
    letter-spacing: 1.5px;
    padding: 0.15rem 0.6rem;
    border-radius: 4px;
    border: 1.8px solid #1f2937;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
}

/* ===================================================
   FORMULARIO DE VENTA A PÁGINA COMPLETA (FULL-PAGE SALE VIEW)
   =================================================== */
.sheet-card input[type="file"] {
    background: rgba(255, 255, 255, 0.03);
    border: 1.5px dashed var(--border-color);
    border-radius: 8px;
    padding: 0.6rem 0.8rem;
    color: var(--text-primary);
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
}

.sheet-card input[type="file"]:hover {
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.05);
}

.sheet-card input[type="file"]::file-selector-button {
    background: #272733;
    color: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 0.35rem 0.75rem;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    margin-right: 0.75rem;
    transition: background 0.2s;
}

.sheet-card input[type="file"]::file-selector-button:hover {
    background: var(--accent);
    color: #ffffff;
}

.sale-calc-container {
    background: linear-gradient(145deg, rgba(16, 185, 129, 0.06) 0%, rgba(13, 13, 17, 0.9) 100%);
    border: 1.5px solid rgba(16, 185, 129, 0.3);
    border-radius: 14px;
    padding: 1.25rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* ===================================================
   VISTA DE FORMULARIO DE VEHÍCULO A PANTALLA COMPLETA
   =================================================== */
#vehicle-form-view .vehicle-sheet-layout {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.15rem;
    align-items: start;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

#vehicle-form-view .sheet-left-column,
#vehicle-form-view .sheet-right-column {
    min-width: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

#vehicle-form-view .sheet-card {
    padding: 1.15rem 1.25rem;
    margin-bottom: 1.15rem;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

@media (max-width: 860px) {
    #vehicle-form-view .vehicle-sheet-layout {
        grid-template-columns: 1fr;
    }
}

/* ===================================================
   VISTA DE ASIGNAR PREPARACIÓN A PANTALLA COMPLETA
   =================================================== */
#preparation-form-view .prep-sheet-layout {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.15rem;
    align-items: start;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

#preparation-form-view .sheet-left-column,
#preparation-form-view .sheet-right-column {
    min-width: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

#preparation-form-view .sheet-card {
    padding: 1.15rem 1.25rem;
    margin-bottom: 1.15rem;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
}

@media (max-width: 860px) {
    #preparation-form-view .prep-sheet-layout {
        grid-template-columns: 1fr;
    }
}

/* ===================================================
   DASHBOARD EJECUTIVO (EXECUTIVE DASHBOARD VIEW)
   =================================================== */

.dashboard-executive-view {
    animation: fadeInDash 0.35s ease-out;
}

@keyframes fadeInDash {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Welcome Hero Banner */
.dash-welcome-card {
    position: relative;
    background: radial-gradient(circle at 85% 20%, rgba(229, 9, 20, 0.12), transparent 50%),
                linear-gradient(135deg, rgba(26, 26, 34, 0.8) 0%, rgba(14, 14, 18, 0.95) 100%);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 1.25rem 1.6rem;
    margin-bottom: 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
    overflow: hidden;
}

.dash-welcome-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, var(--accent) 0%, var(--success) 100%);
}

.dash-live-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: var(--success);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    margin-bottom: 0.55rem;
    text-transform: uppercase;
}

.dash-pulse-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 8px var(--success);
    animation: dashPulse 2s infinite ease-in-out;
}

@keyframes dashPulse {
    0%, 100% {
        transform: scale(0.9);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.3);
        opacity: 1;
        box-shadow: 0 0 12px var(--success);
    }
}

.dash-welcome-title {
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: #ffffff;
    margin-bottom: 0.25rem;
}

.dash-welcome-desc {
    color: var(--text-secondary);
    font-size: 0.86rem;
    line-height: 1.45;
    max-width: 680px;
    margin: 0;
}

.dash-welcome-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-shrink: 0;
}

.dash-quick-stat-badge {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 0.75rem 1.25rem;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.2rem;
}

.dash-quick-stat-badge .badge-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dash-quick-stat-badge .badge-status {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--success);
}

/* The 4 Core KPI Cards Grid */
.dash-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.85rem;
    margin-bottom: 0.9rem;
    width: 100%;
    box-sizing: border-box;
}

.dash-kpi-card {
    position: relative;
    background: linear-gradient(145deg, rgba(26, 26, 32, 0.85) 0%, rgba(15, 15, 20, 0.95) 100%);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 13px;
    padding: 0.85rem 1rem 0.75rem 1rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    overflow: hidden;
    min-width: 0;
    box-sizing: border-box;
}

.dash-kpi-card .kpi-card-glow {
    position: absolute;
    top: -40px;
    right: -40px;
    width: 90px;
    height: 90px;
    border-radius: 50%;
    filter: blur(30px);
    opacity: 0.15;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.dash-kpi-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px -6px rgba(0, 0, 0, 0.5);
}

.dash-kpi-card:hover .kpi-card-glow {
    opacity: 0.3;
}

/* Blue Card: Inventario */
.kpi-card-blue .kpi-card-glow { background: #3b82f6; }
.kpi-card-blue:hover { border-color: rgba(59, 130, 246, 0.4); box-shadow: 0 12px 28px -6px rgba(59, 130, 246, 0.2); }
.kpi-card-blue .kpi-icon-wrap { background: rgba(59, 130, 246, 0.12); color: #60a5fa; border: 1px solid rgba(59, 130, 246, 0.25); }
.kpi-card-blue .kpi-bullet { background: #3b82f6; box-shadow: 0 0 5px #3b82f6; }
.kpi-card-blue .kpi-pill { background: rgba(59, 130, 246, 0.1); color: #93c5fd; border: 1px solid rgba(59, 130, 246, 0.2); }
.kpi-card-blue .kpi-link { color: #60a5fa; }

/* Amber Card: Vendidos */
.kpi-card-amber .kpi-card-glow { background: #f59e0b; }
.kpi-card-amber:hover { border-color: rgba(245, 158, 11, 0.4); box-shadow: 0 12px 28px -6px rgba(245, 158, 11, 0.2); }
.kpi-card-amber .kpi-icon-wrap { background: rgba(245, 158, 11, 0.12); color: #fbbf24; border: 1px solid rgba(245, 158, 11, 0.25); }
.kpi-card-amber .kpi-bullet { background: #f59e0b; box-shadow: 0 0 5px #f59e0b; }
.kpi-card-amber .kpi-pill { background: rgba(245, 158, 11, 0.1); color: #fcd34d; border: 1px solid rgba(245, 158, 11, 0.2); }
.kpi-card-amber .kpi-link { color: #fbbf24; }

/* Cyan Card: Ingresos */
.kpi-card-cyan .kpi-card-glow { background: #06b6d4; }
.kpi-card-cyan:hover { border-color: rgba(6, 182, 212, 0.4); box-shadow: 0 12px 28px -6px rgba(6, 182, 212, 0.2); }
.kpi-card-cyan .kpi-icon-wrap { background: rgba(6, 182, 212, 0.12); color: #38bdf8; border: 1px solid rgba(6, 182, 212, 0.25); }
.kpi-card-cyan .kpi-bullet { background: #06b6d4; box-shadow: 0 0 5px #06b6d4; }
.kpi-card-cyan .kpi-pill { background: rgba(6, 182, 212, 0.1); color: #7dd3fc; border: 1px solid rgba(6, 182, 212, 0.2); }
.kpi-card-cyan .kpi-link { color: #38bdf8; }

/* Emerald Card: Ganancia Neta */
.kpi-card-emerald .kpi-card-glow { background: #10b981; }
.kpi-card-emerald:hover { border-color: rgba(16, 185, 129, 0.5); box-shadow: 0 12px 28px -6px rgba(16, 185, 129, 0.25); }
.kpi-card-emerald .kpi-icon-wrap { background: rgba(16, 185, 129, 0.15); color: #34d399; border: 1px solid rgba(16, 185, 129, 0.35); }
.kpi-card-emerald .kpi-bullet { background: #10b981; box-shadow: 0 0 5px #10b981; }
.kpi-card-emerald .kpi-pill { background: rgba(16, 185, 129, 0.12); color: #6ee7b7; border: 1px solid rgba(16, 185, 129, 0.25); }
.kpi-card-emerald .kpi-link { color: #34d399; }

.kpi-card-featured {
    border-color: rgba(16, 185, 129, 0.3);
    background: linear-gradient(145deg, rgba(16, 185, 129, 0.05) 0%, rgba(18, 22, 24, 0.95) 100%);
}

.kpi-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.65rem;
}

.kpi-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: var(--text-secondary);
}

.kpi-bullet {
    width: 5px;
    height: 5px;
    border-radius: 50%;
}

.kpi-icon-wrap {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease;
}

.dash-kpi-card:hover .kpi-icon-wrap {
    transform: scale(1.06) rotate(2deg);
}

.kpi-icon-wrap svg {
    width: 17px;
    height: 17px;
}

.kpi-card-body {
    margin-bottom: 0.65rem;
}

.kpi-title {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.2rem;
}

.kpi-main-value {
    font-size: clamp(1.4rem, 1.8vw, 1.7rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #ffffff;
    line-height: 1.15;
    margin-bottom: 0.2rem;
}

.kpi-val-cyan {
    color: #38bdf8;
}

.kpi-val-emerald {
    color: #10b981;
    text-shadow: 0 0 16px rgba(16, 185, 129, 0.2);
}

.kpi-subtitle {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.45);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.kpi-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.35rem;
    padding-top: 0.55rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    flex-wrap: nowrap;
}

.kpi-pill {
    font-size: 0.65rem;
    font-weight: 600;
    padding: 0.15rem 0.45rem;
    border-radius: 4px;
    white-space: nowrap;
    flex-shrink: 0;
}

.kpi-link {
    font-size: 0.7rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    transition: transform 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.dash-kpi-card:hover .kpi-link {
    transform: translateX(2px);
}

.kpi-link svg {
    width: 12px;
    height: 12px;
}

/* Executive Ratio Panel (Inventario vs Ventas, Ingresos vs Ganancia) */
.dash-ratios-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
    margin-bottom: 0.9rem;
    width: 100%;
    box-sizing: border-box;
}

.dash-ratio-card {
    background: linear-gradient(135deg, rgba(22, 22, 28, 0.8) 0%, rgba(13, 13, 17, 0.95) 100%);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 13px;
    padding: 0.85rem 1.15rem 0.75rem 1.15rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
    min-width: 0;
    box-sizing: border-box;
}

.ratio-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.35rem;
}

.ratio-title-group .ratio-badge {
    display: inline-block;
    font-size: 0.62rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: var(--text-secondary);
    margin-bottom: 0.15rem;
}

.ratio-title-group h4 {
    font-size: 0.95rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.01em;
}

.ratio-stat-pill {
    background: rgba(245, 158, 11, 0.12);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: #fbbf24;
    font-size: 0.88rem;
    font-weight: 800;
    padding: 0.18rem 0.55rem;
    border-radius: 7px;
    letter-spacing: -0.02em;
}

.ratio-stat-pill.pill-emerald {
    background: rgba(16, 185, 129, 0.12);
    border-color: rgba(16, 185, 129, 0.3);
    color: #34d399;
}

.ratio-description {
    font-size: 0.73rem;
    color: var(--text-secondary);
    margin-bottom: 0.45rem;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ratio-progress-container {
    margin-bottom: 0.45rem;
}

.ratio-progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 999px;
    overflow: hidden;
}

.ratio-progress-fill {
    height: 100%;
    border-radius: 999px;
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.ratio-progress-fill.fill-amber {
    background: linear-gradient(90deg, #f59e0b, #fbbf24);
    box-shadow: 0 0 8px rgba(245, 158, 11, 0.4);
}

.ratio-progress-fill.fill-emerald {
    background: linear-gradient(90deg, #10b981, #34d399);
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.4);
}

.ratio-metrics-legend {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.72rem;
    color: var(--text-secondary);
    padding-top: 0.15rem;
}

.legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.legend-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.dot-amber { background: #f59e0b; }
.dot-emerald { background: #10b981; }
.dot-cyan { background: #06b6d4; }
.dot-muted { background: rgba(255, 255, 255, 0.2); }

/* Quick Navigation Deck */
.dash-quick-nav-deck {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
    margin-bottom: 1rem;
    width: 100%;
    box-sizing: border-box;
}

.quick-nav-item {
    background: linear-gradient(135deg, rgba(22, 22, 28, 0.7) 0%, rgba(14, 14, 18, 0.85) 100%);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 11px;
    padding: 0.55rem 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    cursor: pointer;
    transition: all 0.25s ease;
    min-width: 0;
    box-sizing: border-box;
}

.quick-nav-item:hover {
    transform: translateY(-2px);
    border-color: rgba(255, 255, 255, 0.15);
    background: linear-gradient(135deg, rgba(30, 30, 38, 0.85) 0%, rgba(18, 18, 24, 0.95) 100%);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}

.quick-nav-icon {
    width: 30px;
    height: 30px;
    border-radius: 7px;
    background: rgba(59, 130, 246, 0.12);
    color: #60a5fa;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.quick-nav-icon.icon-amber { background: rgba(245, 158, 11, 0.12); color: #fbbf24; }
.quick-nav-icon.icon-emerald { background: rgba(16, 185, 129, 0.12); color: #34d399; }
.quick-nav-icon.icon-purple { background: rgba(139, 92, 246, 0.12); color: #a78bfa; }

.quick-nav-icon svg {
    width: 16px;
    height: 16px;
}

.quick-nav-info {
    flex: 1;
    min-width: 0;
    overflow: hidden;
}

.quick-nav-title {
    display: block;
    font-size: 0.8rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.05rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.quick-nav-desc {
    display: block;
    font-size: 0.68rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.quick-nav-arrow {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.3);
    transition: transform 0.2s ease, color 0.2s ease;
    flex-shrink: 0;
}

.quick-nav-item:hover .quick-nav-arrow {
    transform: translateX(3px);
    color: #ffffff;
}

/* Responsive Breakpoints for Dashboard */
@media (max-width: 1024px) {
    .dash-kpi-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .dash-quick-nav-deck {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .dash-welcome-card {
        flex-direction: column;
        align-items: flex-start;
        padding: 1.15rem;
    }
    .dash-welcome-actions {
        width: 100%;
        justify-content: flex-start;
    }
    .dash-quick-stat-badge {
        align-items: flex-start;
        width: 100%;
    }
    .dash-kpi-grid {
        grid-template-columns: 1fr;
    }
    .dash-ratios-grid {
        grid-template-columns: 1fr;
    }
    .dash-quick-nav-deck {
        grid-template-columns: 1fr;
    }
}
