/* ===================================
   LAYOUT FIXES - ALTURA MÍNIMA
   =================================== */

/* Asegurar que html y body ocupen toda la altura */
html,
body {
    height: 100%;
    margin: 0;
    padding: 0;
}

/* Wrapper principal con flexbox */
.wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* El contenido principal debe expandirse */
.main-content {
    flex: 1;
    min-height: 400px;
    /* Altura mínima para evitar espacio muy pequeño */
}

/* ===================================
   PÁGINAS VACÍAS - SIN CONTENIDO
   =================================== */

/* Estilo para páginas sin contenido */
.empty-page-content {
    min-height: 60vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 80px 20px;
}

.empty-page-message {
    background: #f8f9fa;
    border: 2px dashed #dee2e6;
    border-radius: 10px;
    padding: 60px 40px;
    max-width: 600px;
    margin: 0 auto;
}

.empty-page-message h2 {
    color: #6c757d;
    font-size: 2rem;
    margin-bottom: 20px;
    font-weight: 300;
}

.empty-page-message p {
    color: #868e96;
    font-size: 1.1rem;
    margin-bottom: 30px;
    line-height: 1.6;
}

.empty-page-message .btn {
    background: #007bff;
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 500;
    transition: background 0.3s ease;
}

.empty-page-message .btn:hover {
    background: #0056b3;
    text-decoration: none;
    color: white;
}

/* ===================================
   BASIC CARD - CONTENIDO VACÍO
   =================================== */

/* Cuando basic-card no tiene contenido */
.basic-card:empty,
.basic-card .container .row:empty {
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Contenedor para mensaje de "sin contenido" */
.no-content-wrapper {
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

/* ===================================
   BREADCRUMB Y PAGE HEADER
   =================================== */

/* ===================================
   BREADCRUMB Y PAGE HEADER - COMPACTO
   =================================== */

.page-header {
    background: #f8f9fa;
    border-bottom: 3px solid #007bff;
    color: #333;
    padding: 25px 0 20px 0;
    margin-bottom: 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.page-header h1 {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: #2c3e50;
    text-shadow: none;
}

.page-header .breadcrumb {
    background: transparent;
    padding: 0;
    margin: 0;
    font-size: 0.9rem;
}

.page-header .breadcrumb a {
    color: #6c757d;
    text-decoration: none;
    margin-right: 6px;
    transition: color 0.2s ease;
}

.page-header .breadcrumb a:hover {
    color: #007bff;
}

.page-header .breadcrumb a:after {
    content: " / ";
    color: #adb5bd;
    margin-left: 6px;
}

.page-header .breadcrumb a:last-child:after {
    content: "";
}

.page-header .breadcrumb a:last-child {
    color: #495057;
    font-weight: 500;
}

/* ===================================
   VARIANTE HEADER EXTRA COMPACTO
   =================================== */

/* Opción 1: Header minimalista */
.page-header.compact {
    background: white;
    border-bottom: 2px solid #e9ecef;
    padding: 1px 0 1px 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.page-header.compact h1 {
    font-size: 1.5rem;
    margin-top: 3px;
    margin-bottom: 1px;
    color: #495057;
}

.page-header.compact .breadcrumb {
    font-size: 0.85rem;
}

/* Opción 2: Header con línea de color */
.page-header.line-style {
    background: white;
    border-left: 4px solid #007bff;
    padding: 20px 0 15px 0;
    margin-bottom: 0;
    box-shadow: none;
}

.page-header.line-style .container {
    padding-left: 25px;
}

/* Opción 3: Header con badge */
.page-header.badge-style h1:before {
    content: "📁";
    margin-right: 10px;
    font-size: 1.2rem;
}

/* Breadcrumb estilo chips */
.breadcrumb-chips {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-top: 1px;
    margin-bottom: 3px;
}

.breadcrumb-chips a {
    background: #e9ecef;
    color: #495057;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    text-decoration: none;
    transition: all 0.2s ease;
}

.breadcrumb-chips a:hover {
    background: #007bff;
    color: white;
}

.breadcrumb-chips a:after {
    content: "";
}

.breadcrumb-chips .separator {
    color: #adb5bd;
    font-size: 0.7rem;
}

/* ===================================
   RESPONSIVE FIXES
   =================================== */

@media (max-width: 768px) {
    .empty-page-content {
        min-height: 50vh;
        padding: 40px 15px;
    }

    .empty-page-message {
        padding: 40px 20px;
    }

    .empty-page-message h2 {
        font-size: 1.5rem;
    }

    .page-header {
        padding: 20px 0 15px 0;
    }

    .page-header h1 {
        font-size: 1.5rem;
        margin-bottom: 6px;
    }

    .page-header .breadcrumb {
        font-size: 0.8rem;
    }
}

/* ===================================
   UTILIDADES
   =================================== */

/* Clase para forzar altura mínima */
.min-height-content {
    min-height: calc(100vh - 200px);
    /* 200px aprox para header + footer */
}

/* Clase para centrar contenido verticalmente */
.center-content {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 50vh;
}

/* ===== PRODUCT SEARCH FORM ===== */
.product-search-form {
    margin-top: 1px;
}

.search-form {
    /* background: rgba(255, 255, 255, 0.95); */
    border-radius: 12px;
    padding: 1px;
    /* box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); */
    backdrop-filter: blur(10px);
}

.search-input-group {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.search-select {
    flex: 0 0 140px;
    padding: 4px 12px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    background: white;
    font-size: 14px;
    color: #495057;
    transition: all 0.3s ease;
}

.search-select:focus {
    border-color: #007bff;
    outline: none;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.search-input {
    flex: 1;
    padding: 4px 15px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 14px;
    color: #495057;
    transition: all 0.3s ease;
    background: white;
}

.search-input:focus {
    border-color: #007bff;
    outline: none;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.search-input::placeholder {
    color: #6c757d;
    opacity: 0.8;
}

.search-btn {
    padding: 10px 15px;
    background: linear-gradient(135deg, #007bff, #0056b3);
    border: none;
    border-radius: 8px;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
}

.search-btn:hover {
    background: linear-gradient(135deg, #0056b3, #004085);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}

.search-btn i {
    font-size: 16px;
}

.clear-search {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #dc3545;
    text-decoration: none;
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.clear-search:hover {
    background: rgba(220, 53, 69, 0.1);
    color: #dc3545;
    text-decoration: none;
}

/* ===== SEARCH RESULTS ===== */
.search-results-section {
    margin-bottom: 40px;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 25px;
    border-left: 4px solid #007bff;
}

.search-results-header {
    margin-bottom: 20px;
}

.search-results-header h3 {
    color: #495057;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.4rem;
}

.search-results-header h3 i {
    color: #007bff;
}

.search-info {
    color: #6c757d;
    margin-bottom: 0;
    font-size: 14px;
}

.product-search-item {
    background: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
}

.product-search-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.product-image {
    text-align: center;
    margin-bottom: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    padding: 10px;
}

.product-info h5 {
    color: #495057;
    margin-bottom: 10px;
    font-weight: 600;
    font-size: 1.1rem;
}

.product-code {
    font-size: 13px;
    color: #6c757d;
    margin-bottom: 5px;
    background: #e9ecef;
    padding: 4px 8px;
    border-radius: 4px;
    display: inline-block;
    margin-right: 10px;
}

.product-description {
    color: #495057;
    font-size: 14px;
    line-height: 1.4;
    margin-bottom: 10px;
}

.product-price {
    color: #28a745;
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 10px;
}

.stock-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stock-badge.in-stock {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.stock-badge.out-stock {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.search-divider {
    margin: 40px 0;
    border: none;
    height: 2px;
    background: linear-gradient(90deg, transparent, #007bff, transparent);
}

/* ===================================
   HEADER PROFESIONAL
   =================================== */

.top-bar-professional {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: white;
    padding: 20px 0;
    position: relative;
    overflow: hidden;
}

.top-bar-professional::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.03)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

.top-bar-professional .container-fluid {
    position: relative;
    z-index: 2;
}

/* Logo mejorado */
.logo.logo-enhanced img {
    max-height: 100px;
    filter: brightness(1.1) contrast(1.1);
    transition: transform 0.3s ease;
}

.logo.logo-enhanced:hover img {
    transform: scale(1.05);
}

/* Items del top-bar mejorados */
.top-bar-item.item-enhanced {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 15px;
    margin: 5px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.top-bar-item.item-enhanced:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Iconos mejorados */
.top-bar-icon.icon-enhanced {
    width: 50px;
    height: 50px;
    background: var(--title);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
}

.top-bar-icon.icon-enhanced [class^="flaticon-"]::before {
    color: #ffffff !important;
    font-size: 24px !important;
}

/* Textos mejorados */
.top-bar-text.text-enhanced h3 {
    color: var(--title) !important;
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    margin-bottom: 5px !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.top-bar-text.text-enhanced p {
    color: var(--title) !important;
    font-size: 1.1rem !important;
    margin-bottom: 2px !important;
    line-height: 1.4;
}

/* Enlaces de contacto */
.phone-link,
.email-link {
    color: var(--title) !important;
    text-decoration: none;
    font-size: 1.1rem;
    line-height: 1.4;
    margin-bottom: 2px;
    display: block;
    transition: color 0.3s ease;
}

.phone-link:hover,
.email-link:hover {
    color: #ffffff;
    text-decoration: none;
}

/* ===================================
   NAVBAR MEJORADO (COMPATIBLE)
   =================================== */

.nav-bar.nav-bar-enhanced {
    background: #ffffff !important;
    border-bottom: 1px solid #e9ecef;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar.navbar-enhanced {
    background: #084c8f !important;
    padding: 0;
    min-height: 70px;
}

/* Brand mejorado */
.navbar-brand.navbar-brand-enhanced {
    background: #2c3e50 !important;
    color: white !important;
    padding: 20px 25px !important;
    margin-right: 0 !important;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: 1px;
    transition: background 0.3s ease;
    text-decoration: none;
}

.navbar-brand.navbar-brand-enhanced:hover {
    background: #34495e !important;
    color: white !important;
    text-decoration: none;
}

.navbar-brand.navbar-brand-enhanced i {
    font-size: 1.1rem;
}

/* Nav links mejorados */
.navbar-nav.navbar-nav-enhanced {
    background: transparent;
}

.nav-link.nav-link-enhanced {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 10px 10px !important;
    color: #ffffff !important;
    font-weight: 500 !important;
    font-size: 0.95rem !important;
    transition: all 0.3s ease !important;
    position: relative;
    text-decoration: none;
}

.nav-link.nav-link-enhanced::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 3px;
    background: #007bff;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link.nav-link-enhanced:hover,
.nav-link.nav-link-enhanced.active {
    color: #ffffff !important;
    background: rgba(0, 123, 255, 0.05) !important;
    text-decoration: none;
}

.nav-link.nav-link-enhanced:hover::before,
.nav-link.nav-link-enhanced.active::before {
    width: 80%;
}

.nav-link.nav-link-enhanced i {
    font-size: 1rem;
    opacity: 0.8;
}

/* ===================================
   ELEMENTOS DE ACCIÓN MEJORADOS
   =================================== */

.language-container.language-container-enhanced {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 0 15px;
}

.user-info-enhanced {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #ffffff;
    font-weight: 500;
    font-size: 0.9rem;
}

.user-info-enhanced i {
    font-size: 1.2rem;
    color: #ffffff;
}

.login-btn-enhanced {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #007bff;
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.login-btn-enhanced:hover {
    background: #0056b3;
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
}

.language-switcher-enhanced {
    display: flex;
    gap: 5px;
    background: #f8f9fa;
    border-radius: 25px;
    padding: 5px;
}

.lang-btn-enhanced {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 12px;
    border: none;
    background: transparent;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.8rem;
    font-weight: 500;
    color: #6c757d;
}

.lang-btn-enhanced.active,
.lang-btn-enhanced:hover {
    background: #007bff;
    color: white;
    transform: translateY(-1px);
}

.lang-btn-enhanced img {
    width: 20px;
    height: 15px;
    border-radius: 2px;
    object-fit: cover;
}

/* ===================================
   RESPONSIVE MEJORADO
   =================================== */

@media (max-width: 1199px) {
    .top-bar-item.item-enhanced {
        padding: 10px;
        margin: 2px;
    }

    .top-bar-text.text-enhanced h3 {
        font-size: 0.85rem !important;
    }

    .top-bar-text.text-enhanced p,
    .phone-link,
    .email-link {
        font-size: 0.8rem !important;
    }
}

@media (max-width: 991px) {
    .top-bar.top-bar-enhanced {
        padding: 10px 0;
        min-height: auto;
    }

    .logo.logo-enhanced {
        text-align: center;
    }

    .logo.logo-enhanced img {
        max-height: 60px;
    }

    .navbar-brand.navbar-brand-enhanced {
        padding: 15px 20px !important;
        font-size: 0.9rem;
    }

    .nav-link.nav-link-enhanced {
        padding: 15px 20px !important;
        border-bottom: 1px solid #f1f1f1;
    }

    .nav-link.nav-link-enhanced:last-child {
        border-bottom: none;
    }

    .language-container.language-container-enhanced {
        flex-direction: column;
        gap: 15px;
        padding: 15px;
        border-top: 1px solid #e9ecef;
        width: 100%;
    }
}

@media (max-width: 767px) {

    .login-btn-enhanced,
    .user-info-enhanced {
        font-size: 0.85rem;
    }

    .lang-btn-enhanced {
        padding: 6px 10px;
        font-size: 0.75rem;
    }
}

/* ===================================
   HEADER MEJORADO - RESPONSIVE PARA ZOOM
   =================================== */

/* Mejoras para el top-bar existente - Responsive Zoom */
.top-bar.top-bar-enhanced {
    background: var(--top-bar);
    color: white;
    min-height: 80px;
    padding: 10px 0;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
}

.top-bar.top-bar-enhanced::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.03)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

.top-bar.top-bar-enhanced .container-fluid {
    position: relative;
    z-index: 2;
    width: 100%;
}

.top-bar.top-bar-enhanced .row {
    margin: 0;
    width: 100%;
}

/* Logo mejorado - Más flexible */
.logo.logo-enhanced {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px;
}

.logo.logo-enhanced img {
    max-height: clamp(50px, 8vw, 80px);
    width: auto;
    filter: brightness(1.1) contrast(1.1);
    transition: transform 0.3s ease;
}

.logo.logo-enhanced:hover img {
    transform: scale(1.05);
}

/* Items del top-bar mejorados - Más flexibles */
.top-bar-item.item-enhanced {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: clamp(8px, 1.5vw, 15px);
    margin: 2px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    min-height: 60px;
    width: 100%;
}

.top-bar-item.item-enhanced:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Iconos mejorados - Tamaño adaptable */
.top-bar-icon.icon-enhanced {
    width: clamp(40px, 4vw, 50px);
    height: clamp(40px, 4vw, 50px);
    background: var(--title);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: clamp(8px, 1.5vw, 15px);
    flex-shrink: 0;
}

.top-bar-icon.icon-enhanced [class^="flaticon-"]::before {
    color: #ffffff !important;
    font-size: clamp(18px, 2vw, 24px) !important;
}

/* Textos mejorados - Tamaños escalables */
.top-bar-text.text-enhanced {
    flex: 1;
    min-width: 0;
}

.top-bar-text.text-enhanced h3 {
    color: var(--title) !important;
    font-size: clamp(0.75rem, 1.2vw, 0.95rem) !important;
    font-weight: 600 !important;
    margin-bottom: 3px !important;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.top-bar-text.text-enhanced p {
    color: var(--title) !important;
    font-size: clamp(0.7rem, 1vw, 0.9rem) !important;
    margin-bottom: 1px !important;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Enlaces de contacto - Adaptables */
.phone-link,
.email-link {
    color: var(--title) !important;
    text-decoration: none;
    font-size: clamp(0.7rem, 1vw, 0.9rem) !important;
    line-height: 1.3;
    margin-bottom: 1px;
    display: block;
    transition: color 0.3s ease;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.phone-link:hover,
.email-link:hover {
    color: #ffffff !important;
    text-decoration: none;
}

/* ===================================
   NAVBAR MEJORADO - RESPONSIVE ZOOM
   =================================== */

.nav-bar.nav-bar-enhanced {
    background: #ffffff !important;
    border-bottom: 1px solid #e9ecef;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar.navbar-enhanced {
    background: #084c8f !important;
    padding: 0;
    min-height: 60px;
    display: flex;
    align-items: center;
}

/* Brand mejorado - Más compacto */
.navbar-brand.navbar-brand-enhanced {
    background: #2c3e50 !important;
    color: white !important;
    padding: clamp(15px, 2vw, 20px) clamp(15px, 2.5vw, 25px) !important;
    margin-right: 0 !important;
    display: flex;
    align-items: center;
    gap: clamp(6px, 1vw, 10px);
    font-weight: 600;
    font-size: clamp(0.8rem, 1.2vw, 1rem);
    letter-spacing: 0.5px;
    transition: background 0.3s ease;
    text-decoration: none;
    white-space: nowrap;
}

.navbar-brand.navbar-brand-enhanced:hover {
    background: #34495e !important;
    color: white !important;
    text-decoration: none;
}

.navbar-brand.navbar-brand-enhanced i {
    font-size: clamp(0.9rem, 1.3vw, 1.1rem);
}

/* Nav links mejorados - Más adaptables */
.navbar-nav.navbar-nav-enhanced {
    background: transparent;
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.navbar-nav.navbar-nav-enhanced::-webkit-scrollbar {
    display: none;
}

.nav-link.nav-link-enhanced {
    display: flex !important;
    align-items: center !important;
    gap: clamp(4px, 0.8vw, 8px) !important;
    padding: clamp(8px, 1.5vw, 8px) clamp(8px, 1.5vw, 10px) !important;
    color: #ffffff !important;
    font-weight: 500 !important;
    font-size: clamp(0.75rem, 1.1vw, 0.95rem) !important;
    transition: all 0.3s ease !important;
    position: relative;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
}

.nav-link.nav-link-enhanced::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: #007bff;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link.nav-link-enhanced:hover,
.nav-link.nav-link-enhanced.active {
    color: #ffffff !important;
    background: rgba(0, 123, 255, 0.15) !important;
    text-decoration: none;
}

.nav-link.nav-link-enhanced:hover::before,
.nav-link.nav-link-enhanced.active::before {
    width: 80%;
}

.nav-link.nav-link-enhanced i {
    font-size: clamp(0.8rem, 1vw, 1rem);
    opacity: 0.9;
}

/* ===================================
   ELEMENTOS DE ACCIÓN - ZOOM RESPONSIVE
   =================================== */

.language-container.language-container-enhanced {
    display: flex;
    align-items: center;
    gap: clamp(10px, 2vw, 20px);
    padding: 0 clamp(8px, 1.5vw, 15px);
    flex-shrink: 0;
}

.user-info-enhanced {
    display: flex;
    align-items: center;
    gap: clamp(4px, 0.8vw, 8px);
    color: #ffffff;
    font-weight: 500;
    font-size: clamp(0.75rem, 1vw, 0.9rem);
    white-space: nowrap;
}

.user-info-enhanced i {
    font-size: clamp(1rem, 1.3vw, 1.2rem);
    color: #ffffff;
}

.login-btn-enhanced {
    display: flex;
    align-items: center;
    gap: clamp(4px, 0.8vw, 8px);
    padding: clamp(6px, 1.2vw, 10px) clamp(12px, 2vw, 20px);
    background: #007bff;
    color: white;
    text-decoration: none;
    border-radius: 20px;
    font-weight: 500;
    font-size: clamp(0.75rem, 1vw, 0.9rem);
    transition: all 0.3s ease;
    white-space: nowrap;
}

.login-btn-enhanced:hover {
    background: #0056b3;
    color: white;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
}

.language-switcher-enhanced {
    display: flex;
    gap: 3px;
    background: rgba(248, 249, 250, 0.1);
    border-radius: 20px;
    padding: 3px;
}

.lang-btn-enhanced {
    display: flex;
    align-items: center;
    gap: clamp(3px, 0.6vw, 5px);
    padding: clamp(4px, 1vw, 8px) clamp(6px, 1.2vw, 12px);
    border: none;
    background: transparent;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: clamp(0.65rem, 0.9vw, 0.8rem);
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    white-space: nowrap;
}

.lang-btn-enhanced.active,
.lang-btn-enhanced:hover {
    background: #007bff;
    color: white;
    transform: translateY(-1px);
}

.lang-btn-enhanced img {
    width: clamp(16px, 2vw, 20px);
    height: clamp(12px, 1.5vw, 15px);
    border-radius: 2px;
    object-fit: cover;
}

/* ===================================
   RESPONSIVE CAROUSEL
   =================================== */

/* Tablet */
@media (max-width: 1024px) {
    .carousel-container-fixed {
        height: 60vh;
        min-height: 350px;
        max-height: 500px;
    }

    .carousel-fixed .carousel-caption {
        bottom: 15px !important;
        padding: 15px 20px !important;
        max-width: 90% !important;
    }

    .carousel-fixed .carousel-control-prev,
    .carousel-fixed .carousel-control-next {
        width: 50px !important;
        height: 50px !important;
    }

    .carousel-fixed .carousel-control-prev {
        left: 15px !important;
    }

    .carousel-fixed .carousel-control-next {
        right: 15px !important;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .carousel-container-fixed {
        height: 50vh;
        min-height: 300px;
        max-height: 400px;
    }

    .carousel-fixed .carousel-caption {
        bottom: 10px !important;
        padding: 10px 15px !important;
        max-width: 95% !important;
    }

    .carousel-fixed .carousel-control-prev,
    .carousel-fixed .carousel-control-next {
        width: 40px !important;
        height: 40px !important;
    }

    .carousel-fixed .carousel-control-prev {
        left: 10px !important;
    }

    .carousel-fixed .carousel-control-next {
        right: 10px !important;
    }

    .carousel-fixed .carousel-control-prev-icon i,
    .carousel-fixed .carousel-control-next-icon i {
        font-size: 1.2rem !important;
    }

    .carousel-fixed .carousel-indicators li {
        width: 10px !important;
        height: 10px !important;
        margin: 0 5px !important;
    }
}

/* Muy pequeño */
@media (max-width: 480px) {
    .carousel-container-fixed {
        height: 40vh;
        min-height: 250px;
        max-height: 300px;
    }

    .carousel-fixed .carousel-caption {
        display: none !important;
        /* Ocultar en pantallas muy pequeñas */
    }
}

/* ===================================
   LOADING STATES PARA CAROUSEL
   =================================== */

/* Skeleton loading para el carousel */
.carousel-skeleton {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* Estado de carga */
.carousel-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
}

.carousel-loading::before {
    content: '';
    width: 50px;
    height: 50px;
    border: 4px solid #e3e3e3;
    border-top: 4px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* ===================================
   OPTIMIZACIONES DE PERFORMANCE
   =================================== */

/* Optimización para smooth scroll */
.carousel-fixed .carousel-item {
    will-change: transform;
    transform: translateZ(0);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

/* Preload para mejorar transiciones */
.carousel-fixed .carousel-item img {
    will-change: auto;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

/* Reducir layout shifts */
.carousel-fixed .carousel-inner {
    contain: layout style paint;
}

/* ===================================
   CAROUSEL - TAMAÑO FIJO SIN REDIMENSIONAMIENTO
   =================================== */

/* Contenedor principal del carousel con tamaño fijo */
.carousel-container-fixed {
    width: 100%;
    height: 70vh;
    /* Altura fija responsiva */
    min-height: 400px;
    /* Altura mínima */
    max-height: 600px;
    /* Altura máxima */
    overflow: hidden;
    position: relative;
    background: #f8f9fa;
    /* Color de fondo mientras carga */
    border-radius: 0;
}

/* Carousel con altura fija */
.carousel-fixed {
    height: 100%;
    width: 100%;
}

.carousel-fixed .carousel-inner {
    height: 100%;
    width: 100%;
}

/* NOTA: Los estilos del carousel han sido movidos a carousel-fixed.css 
   Los siguientes estilos están deshabilitados para evitar conflictos */

/*
.carousel-fixed .carousel-item {
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: #000;
}

.carousel-fixed .carousel-item img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center !important;
    transition: none !important;
    display: block !important;
    opacity: 0;
    transition: opacity 0.3s ease;
}
*/

/* Caption mejorado para altura fija */
.carousel-fixed .carousel-caption {
    position: absolute !important;
    bottom: 20px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    background: rgba(0, 0, 0, 0.7) !important;
    padding: 20px 30px !important;
    border-radius: 10px !important;
    backdrop-filter: blur(10px) !important;
    max-width: 80% !important;
    text-align: center !important;
}

.carousel-fixed .carousel-caption h5 {
    font-size: clamp(1.2rem, 3vw, 2rem) !important;
    font-weight: 600 !important;
    margin-bottom: 10px !important;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5) !important;
}

.carousel-fixed .carousel-caption p {
    font-size: clamp(0.9rem, 2vw, 1.1rem) !important;
    margin-bottom: 15px !important;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5) !important;
}

.carousel-fixed .carousel-caption .btn {
    font-size: clamp(0.8rem, 1.5vw, 1rem) !important;
    padding: 10px 25px !important;
    border-radius: 25px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    transition: all 0.3s ease !important;
}

.carousel-fixed .carousel-caption .btn:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 5px 15px rgba(0, 123, 255, 0.4) !important;
}

/* Controles del carousel mejorados */
.carousel-fixed .carousel-control-prev,
.carousel-fixed .carousel-control-next {
    width: 60px !important;
    height: 60px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    background: rgba(0, 0, 0, 0.5) !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s ease !important;
    backdrop-filter: blur(10px) !important;
}

.carousel-fixed .carousel-control-prev {
    left: 20px !important;
}

.carousel-fixed .carousel-control-next {
    right: 20px !important;
}

.carousel-fixed .carousel-control-prev:hover,
.carousel-fixed .carousel-control-next:hover {
    background: rgba(0, 0, 0, 0.8) !important;
    transform: translateY(-50%) scale(1.1) !important;
}

.carousel-fixed .carousel-control-prev-icon,
.carousel-fixed .carousel-control-next-icon {
    width: auto !important;
    height: auto !important;
    background: none !important;
}

.carousel-fixed .carousel-control-prev-icon i,
.carousel-fixed .carousel-control-next-icon i {
    font-size: 1.5rem !important;
    color: white !important;
}

/* Indicadores mejorados */
.carousel-fixed .carousel-indicators {
    bottom: 15px !important;
    margin-bottom: 0 !important;
}

.carousel-fixed .carousel-indicators li {
    width: 12px !important;
    height: 12px !important;
    border-radius: 50% !important;
    margin: 0 8px !important;
    background: rgba(255, 255, 255, 0.5) !important;
    border: 2px solid rgba(255, 255, 255, 0.8) !important;
    transition: all 0.3s ease !important;
}

.carousel-fixed .carousel-indicators .active {
    background: #007bff !important;
    border-color: #007bff !important;
    transform: scale(1.2) !important;
}

/* ===================================
   RESPONSIVE CAROUSEL
   =================================== */

/* Tablet */
@media (max-width: 1024px) {
    .carousel-container-fixed {
        height: 60vh;
        min-height: 350px;
        max-height: 500px;
    }

    .carousel-fixed .carousel-caption {
        bottom: 15px !important;
        padding: 15px 20px !important;
        max-width: 90% !important;
    }

    .carousel-fixed .carousel-control-prev,
    .carousel-fixed .carousel-control-next {
        width: 50px !important;
        height: 50px !important;
    }

    .carousel-fixed .carousel-control-prev {
        left: 15px !important;
    }

    .carousel-fixed .carousel-control-next {
        right: 15px !important;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .carousel-container-fixed {
        height: 50vh;
        min-height: 300px;
        max-height: 400px;
    }

    .carousel-fixed .carousel-caption {
        bottom: 10px !important;
        padding: 10px 15px !important;
        max-width: 95% !important;
    }

    .carousel-fixed .carousel-control-prev,
    .carousel-fixed .carousel-control-next {
        width: 40px !important;
        height: 40px !important;
    }

    .carousel-fixed .carousel-control-prev {
        left: 10px !important;
    }

    .carousel-fixed .carousel-control-next {
        right: 10px !important;
    }

    .carousel-fixed .carousel-control-prev-icon i,
    .carousel-fixed .carousel-control-next-icon i {
        font-size: 1.2rem !important;
    }

    .carousel-fixed .carousel-indicators li {
        width: 10px !important;
        height: 10px !important;
        margin: 0 5px !important;
    }
}

/* Muy pequeño */
@media (max-width: 480px) {
    .carousel-container-fixed {
        height: 40vh;
        min-height: 250px;
        max-height: 300px;
    }

    .carousel-fixed .carousel-caption {
        display: none !important;
        /* Ocultar en pantallas muy pequeñas */
    }
}

/* ===================================
   LOADING STATES PARA CAROUSEL
   =================================== */

/* Skeleton loading para el carousel */
.carousel-skeleton {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* Estado de carga */
.carousel-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
}

.carousel-loading::before {
    content: '';
    width: 50px;
    height: 50px;
    border: 4px solid #e3e3e3;
    border-top: 4px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* ===================================
   OPTIMIZACIONES DE PERFORMANCE
   =================================== */

/* Optimización para smooth scroll */
.carousel-fixed .carousel-item {
    will-change: transform;
    transform: translateZ(0);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

/* Preload para mejorar transiciones */
.carousel-fixed .carousel-item img {
    will-change: auto;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

/* Reducir layout shifts */
.carousel-fixed .carousel-inner {
    contain: layout style paint;
}