/* Variables globales - CRYK.cl - Comercializadora R&K */
:root {
    --primary: #1e40af;
    --primary-dark: #1e3a8a;
    --primary-light: #3b82f6;
    --secondary: #64748b;
    --success: #059669;
    --info: #0891b2;
    --warning: #d97706;
    --danger: #dc2626;
    --light: #f8fafc;
    --dark: #0f172a;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --border-radius: 0.75rem;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.08), 0 2px 10px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.15), 0 10px 20px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 25px 50px rgba(0, 0, 0, 0.2), 0 15px 30px rgba(0, 0, 0, 0.15);
    --gradient-primary: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
    --gradient-hero: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

/* Estilos generales */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--gray-800);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 25%, #f0f9ff 50%, #f8fafc 75%, #e0e7ff 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    position: relative;
    min-height: 100vh;
}

/* Animación del fondo */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Patrón de fondo sutil */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(30, 64, 175, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(59, 130, 246, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(118, 75, 162, 0.05) 0%, transparent 50%);
    background-size: 100% 100%;
    pointer-events: none;
    z-index: 0;
}

/* Asegurar que el contenido esté por encima del fondo */
body > * {
    position: relative;
    z-index: 1;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    color: var(--gray-900);
    line-height: 1.2;
}

/* Navbar - Diseño azul marino con letras destacadas */
.navbar,
.navbar.navbar-dark,
.navbar.navbar-expand-lg,
header .navbar,
header .navbar.navbar-dark {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #1e3a8a 100%) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 3px solid rgba(255, 255, 255, 0.3) !important;
    box-shadow: 0 8px 32px rgba(30, 58, 138, 0.3), 0 2px 8px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: relative;
}

/* Forzar que no haya fondo blanco de Bootstrap */
.navbar.bg-white,
.navbar-light {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #1e3a8a 100%) !important;
}

.navbar::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 0.8;
}

/* Asegurar que el navbar sticky funcione correctamente */
.sticky-top {
    position: sticky !important;
    top: 0 !important;
    z-index: 1030 !important;
}

/* Mejorar la transparencia y el efecto de blur */
.navbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.95) 0%, rgba(30, 64, 175, 0.95) 50%, rgba(30, 58, 138, 0.95) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: -1;
    border-radius: 0;
}

.navbar-brand,
.navbar-brand.text-white,
.navbar .navbar-brand,
.navbar-dark .navbar-brand,
.navbar.navbar-dark .navbar-brand,
a.navbar-brand {
    font-size: 1.5rem;
    color: #ffffff !important;
}

/* Estilos para el logo en el navbar */
.navbar-logo {
    height: 32px;
    width: 32px;
    max-height: 32px;
    max-width: 32px;
    object-fit: cover;
    border-radius: 8px;
    transition: all 0.3s ease;
    display: block;
    border: 2px solid rgba(255, 255, 255, 0.2);
    padding: 2px;
    background: rgba(255, 255, 255, 0.1);
}

.navbar-brand:hover .navbar-logo {
    transform: scale(1.05);
    opacity: 0.9;
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow: 0 2px 8px rgba(255, 255, 255, 0.2);
}

/* Ajustar navbar-brand cuando tiene logo */
.navbar-brand.d-flex {
    gap: 0.5rem;
}

/* Responsive: ajustar tamaño del logo en móviles */
@media (max-width: 768px) {
    .navbar-logo {
        height: 28px;
        width: 28px;
        max-height: 28px;
        max-width: 28px;
        border-radius: 6px;
    }
    
    .navbar-brand span {
        font-size: 1.1rem;
    }
}
    font-weight: 700;
    letter-spacing: -0.02em;
    transition: var(--transition);
    position: relative;
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.navbar-brand i,
.navbar-brand .fas {
    color: #ffffff !important;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.navbar-brand::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 0.5rem;
    transition: var(--transition);
    opacity: 0;
}

.navbar-brand:hover {
    transform: scale(1.05);
    color: #ffffff !important;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
}

.navbar-brand:hover::before {
    opacity: 1;
}

.nav-link,
.navbar .nav-link,
.navbar-nav .nav-link,
.navbar-dark .nav-link,
.navbar.navbar-dark .nav-link,
a.nav-link {
    color: #ffffff !important;
    font-weight: 600;
    padding: 0.5rem 1rem !important;
    transition: var(--transition);
    position: relative;
    border-radius: 0.5rem;
    margin: 0 0.25rem;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
    opacity: 1;
}

.nav-link:hover,
.navbar .nav-link:hover,
.navbar-dark .nav-link:hover {
    color: #ffffff !important;
    opacity: 1;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.nav-link::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.25);
    opacity: 0;
    border-radius: 0.5rem;
    transition: var(--transition);
    z-index: -1;
}

.nav-link:hover {
    color: #ffffff !important;
    transform: translateY(-1px);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
}

.nav-link:hover::before {
    opacity: 1;
}

/* Navbar toggler (botón hamburguesa) */
.navbar-toggler {
    border: 2px solid rgba(255, 255, 255, 0.5);
    padding: 0.375rem 0.75rem;
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.25rem rgba(255, 255, 255, 0.25);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.95%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Dropdown toggle en navbar azul marino */
.navbar .dropdown-toggle,
.navbar-nav .dropdown-toggle {
    color: #ffffff !important;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
}

.navbar .dropdown-toggle::after,
.navbar-nav .dropdown-toggle::after {
    border-top-color: #ffffff !important;
    opacity: 0.9;
}

/* Botones en navbar celeste */
.navbar .btn-outline-primary {
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.6) !important;
    background: rgba(255, 255, 255, 0.1);
    font-weight: 600;
}

.navbar .btn-outline-primary:hover {
    background: rgba(255, 255, 255, 0.25) !important;
    border-color: rgba(255, 255, 255, 0.9) !important;
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: var(--primary);
    transition: var(--transition);
    transform: translateX(-50%);
}

.nav-link:hover::after {
    width: 100%;
}

/* Botones - Diseño mejorado */
.btn {
    font-weight: 600;
    border-radius: var(--border-radius);
    transition: var(--transition);
    padding: 0.625rem 1.75rem;
    letter-spacing: 0.01em;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.btn-primary {
    background: var(--gradient-primary);
    border: none;
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(30, 64, 175, 0.3);
}

.btn-outline-primary {
    color: var(--primary);
    border-color: var(--primary);
}

.btn-outline-primary:hover {
    background-color: var(--primary);
    border-color: var(--primary);
    transform: translateY(-1px);
}

/* Cards - Diseño mejorado */
.card {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08), 0 2px 10px rgba(0, 0, 0, 0.06);
    transition: var(--transition);
    background: #ffffff;
    overflow: hidden;
    position: relative;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-xl);
}

.card:hover::before {
    transform: scaleX(1);
}

.card-body {
    padding: 1.5rem;
}

/* Iconos en cards */
.bg-primary.bg-opacity-10 {
    background-color: rgba(59, 130, 246, 0.1) !important;
}

.bg-success.bg-opacity-10 {
    background-color: rgba(5, 150, 105, 0.1) !important;
}

.bg-info.bg-opacity-10 {
    background-color: rgba(8, 145, 178, 0.1) !important;
}

/* Formularios */
.form-control, .form-select {
    border: 1px solid var(--gray-300);
    border-radius: var(--border-radius);
    transition: var(--transition);
    padding: 0.75rem;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.25);
}

.form-label {
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

/* Secciones */
section {
    padding: 4rem 0;
    position: relative;
}

.bg-light {
    background: linear-gradient(135deg, rgba(248, 250, 252, 0.9) 0%, rgba(240, 249, 255, 0.9) 100%) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-top: 1px solid rgba(30, 64, 175, 0.1);
    border-bottom: 1px solid rgba(30, 64, 175, 0.1);
}

/* Secciones sin bg-light tienen fondo más sutil */
section:not(.bg-light) {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

/* Hero section - Diseño mejorado */
.hero-section {
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 50%, #f0f9ff 75%, #f8fafc 100%);
    position: relative;
    overflow: hidden;
    border-bottom: 2px solid rgba(30, 64, 175, 0.1);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 30%, rgba(30, 64, 175, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(59, 130, 246, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(118, 75, 162, 0.1) 0%, transparent 60%);
    pointer-events: none;
    animation: pulse 8s ease-in-out infinite;
}

.hero-section::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        repeating-linear-gradient(45deg, transparent, transparent 35px, rgba(30, 64, 175, 0.03) 35px, rgba(30, 64, 175, 0.03) 70px);
    pointer-events: none;
}

/* Footer - Diseño mejorado */
footer {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%) !important;
    border-top: 3px solid var(--primary);
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--gradient-primary);
    opacity: 0.5;
}

/* Responsive */
@media (max-width: 768px) {
    .display-5 {
        font-size: 2rem;
    }
    
    section {
        padding: 3rem 0;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    /* Asegurar que el navbar sea visible en móviles */
    .navbar {
        background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #1e3a8a 100%) !important;
    }
    
    .navbar::before {
        background: linear-gradient(135deg, rgba(30, 58, 138, 0.98) 0%, rgba(30, 64, 175, 0.98) 50%, rgba(30, 58, 138, 0.98) 100%);
    }
}

/* Asegurar que el navbar siempre esté visible en todos los dispositivos */
@media (min-width: 769px) {
    .navbar {
        background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #1e3a8a 100%) !important;
    }
    
    .navbar::before {
        background: linear-gradient(135deg, rgba(30, 58, 138, 0.98) 0%, rgba(30, 64, 175, 0.98) 50%, rgba(30, 58, 138, 0.98) 100%);
    }
}

/* Mejorar la visibilidad del navbar en scroll */
.navbar.scrolled {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #1e3a8a 100%) !important;
    box-shadow: 0 8px 32px rgba(30, 58, 138, 0.4), 0 2px 8px rgba(0, 0, 0, 0.2);
}

.navbar.scrolled::before {
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.98) 0%, rgba(30, 64, 175, 0.98) 50%, rgba(30, 58, 138, 0.98) 100%);
}

/* Asegurar que el navbar siempre esté visible */
.navbar {
    position: sticky !important;
    top: 0 !important;
    z-index: 1030 !important;
    transition: all 0.3s ease;
}

/* Mejorar la visibilidad en dispositivos móviles */
@media (max-width: 768px) {
    .navbar {
        position: sticky !important;
        top: 0 !important;
        z-index: 1030 !important;
        background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #1e3a8a 100%) !important;
    }
    
    .navbar::before {
        background: linear-gradient(135deg, rgba(30, 58, 138, 0.98) 0%, rgba(30, 64, 175, 0.98) 50%, rgba(30, 58, 138, 0.98) 100%);
    }
    
    /* Asegurar que el menú desplegable esté visible */
    .navbar-collapse {
        background: rgba(30, 58, 138, 0.95);
        border-radius: 0.5rem;
        box-shadow: 0 4px 25px rgba(30, 58, 138, 0.4);
        margin-top: 0.5rem;
        padding: 1rem;
        border: 1px solid rgba(255, 255, 255, 0.2);
    }
    
    .dropdown-menu {
        background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 250, 252, 0.98) 100%);
        border: 2px solid rgba(30, 58, 138, 0.3);
        box-shadow: 0 8px 32px rgba(30, 58, 138, 0.25), 0 4px 16px rgba(0, 0, 0, 0.1);
    }
}

/* Asegurar que el navbar esté siempre por encima de otros elementos */
.navbar,
.navbar * {
    z-index: 1030 !important;
}

/* Mejorar la visibilidad del dropdown */
.dropdown-menu {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 250, 252, 0.98) 100%);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 2px solid rgba(30, 58, 138, 0.3);
    box-shadow: 0 8px 32px rgba(30, 58, 138, 0.25), 0 4px 16px rgba(0, 0, 0, 0.1);
    border-radius: var(--border-radius);
    padding: 0.5rem;
    margin-top: 0.5rem;
}

.dropdown-item {
    border-radius: 0.5rem;
    padding: 0.625rem 1rem;
    transition: var(--transition);
    margin: 0.125rem 0;
    color: var(--gray-700);
    font-weight: 500;
}

.dropdown-item:hover {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 100%);
    color: white !important;
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.4);
}

.dropdown-item i {
    transition: var(--transition);
    color: inherit;
}

.dropdown-item:hover i {
    transform: scale(1.1);
    color: white;
}

/* Asegurar que el navbar siempre esté visible - override de cualquier otro estilo */
header.sticky-top,
header.sticky-top .navbar {
    position: sticky !important;
    top: 0 !important;
    z-index: 1030 !important;
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #1e3a8a 100%) !important;
}

/* Forzar la visibilidad en todos los navegadores */
@supports (position: sticky) {
    header.sticky-top,
    header.sticky-top .navbar {
        position: sticky !important;
        top: 0 !important;
    }
}

/* Fallback para navegadores que no soportan sticky */
@supports not (position: sticky) {
    header.sticky-top,
    header.sticky-top .navbar {
        position: fixed !important;
        top: 0 !important;
        width: 100%;
    }
    
    body {
        padding-top: 80px; /* Ajustar según la altura del navbar */
    }
}

/* Animaciones mejoradas */
.fade-in {
    animation: fadeIn 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(30px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* Hover effects sutiles */
.card:hover .fa-2x {
    transform: scale(1.1);
    transition: var(--transition);
}

/* Sombras sutiles */
.shadow-sm {
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05) !important;
}

/* Bordes redondeados consistentes */
.rounded-3 {
    border-radius: var(--border-radius) !important;
}

/* Espaciado consistente */
.g-4 > * {
    padding: 1rem;
}

/* Colores de texto consistentes */
.text-muted {
    color: var(--gray-600) !important;
}

.text-dark {
    color: var(--gray-900) !important;
}

/* Estilos para las tarjetas de problemas - Diseño mejorado */
.problem-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-radius: var(--border-radius);
    padding: 2rem;
    padding-top: 2.5rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08), 0 2px 10px rgba(0, 0, 0, 0.06);
    transition: var(--transition);
    height: 100%;
    border: 2px solid var(--gray-200);
    position: relative;
    margin-top: 2rem;
    overflow: visible;
}

.problem-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-primary);
    opacity: 0;
    transition: var(--transition);
    z-index: 0;
}

.problem-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary);
}

.problem-card:hover::after {
    opacity: 0.03;
}

.problem-icon {
    position: absolute;
    top: -1.25rem;
    left: 50%;
    transform: translateX(-50%);
    width: 3.5rem;
    height: 3.5rem;
    background: var(--gradient-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    box-shadow: 0 8px 20px rgba(30, 64, 175, 0.3), 0 4px 10px rgba(0, 0, 0, 0.1);
    z-index: 2;
    transition: var(--transition);
}

.problem-card:hover .problem-icon {
    transform: translateX(-50%) scale(1.1) rotate(5deg);
    box-shadow: 0 12px 30px rgba(30, 64, 175, 0.4), 0 6px 15px rgba(0, 0, 0, 0.15);
}

/* Evitar recorte de iconos en sección ¿Te está pasando esto? */
.section-problemas,
.section-problemas .row-problemas,
.section-problemas .col-lg-4,
.section-problemas .col-md-6 {
    overflow: visible;
}

/* Estilos para las tarjetas de impacto */
.impact-card {
    background: #fff;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08), 0 2px 10px rgba(0, 0, 0, 0.06);
    transition: var(--transition);
    height: 100%;
    border: 1px solid var(--gray-200);
}

.impact-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15), 0 10px 20px rgba(0, 0, 0, 0.1);
    border-color: var(--gray-300);
}

.impact-icon {
    width: 3rem;
    height: 3rem;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin: 0 auto 1rem;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15), 0 4px 8px rgba(0, 0, 0, 0.1);
}

.impact-value {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary);
    margin: 0.5rem 0;
}

/* Estilos para las tarjetas de responsabilidad */
.responsibility-card {
    background: #fff;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08), 0 2px 10px rgba(0, 0, 0, 0.06);
    transition: var(--transition);
    height: 100%;
    border: 1px solid var(--gray-200);
    position: relative;
}

.responsibility-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15), 0 10px 20px rgba(0, 0, 0, 0.1);
    border-color: var(--gray-300);
}

.responsibility-icon {
    width: 3rem;
    height: 3rem;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin: 0 auto 1rem;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15), 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Estilos para el modal de registro completo */
.modal-xl {
    max-width: 90%;
}

.modal-header.bg-primary {
    border-bottom: none;
}

.modal-body {
    max-height: 70vh;
    overflow-y: auto;
}

.form-label {
    font-weight: 500;
    color: var(--dark);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

.input-group-text {
    background-color: var(--light);
    border-color: var(--border-color);
    color: var(--muted);
}

/* Estilos para las secciones del formulario */
.modal-body h6 {
    color: var(--primary);
    border-bottom: 2px solid var(--primary);
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

/* Estilos para el checkbox de términos */
.form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}

.form-check-label a {
    text-decoration: none;
}

.form-check-label a:hover {
    text-decoration: underline;
}

/* Mejoras adicionales de diseño */
.display-5 {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
    letter-spacing: -0.02em;
    text-shadow: 0 2px 10px rgba(30, 64, 175, 0.1);
}

/* Cards con fondo más definido */
.card {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* Efectos de hover mejorados para secciones */
section {
    position: relative;
}

section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    opacity: 0.3;
}

/* Mejoras en los iconos */
.fa-2x {
    transition: var(--transition);
}

.card:hover .fa-2x {
    transform: scale(1.15) rotate(5deg);
    color: var(--primary);
}

/* Mejoras en los badges y etiquetas */
.badge {
    font-weight: 600;
    letter-spacing: 0.02em;
    padding: 0.5rem 0.75rem;
}

/* Mejoras en los inputs */
.form-control:focus,
.form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.25rem rgba(30, 64, 175, 0.15);
    transform: translateY(-1px);
    transition: var(--transition);
}

/* Efectos de glassmorphism mejorados */
.glass-effect {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

/* Mejoras en las tarjetas de impacto */
.impact-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 2px solid var(--gray-200);
    transition: var(--transition);
}

.impact-card:hover {
    border-color: var(--primary);
    background: linear-gradient(135deg, #ffffff 0%, #eff6ff 100%);
}

.impact-icon {
    background: var(--gradient-primary);
    transition: var(--transition);
}

.impact-card:hover .impact-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 12px 30px rgba(30, 64, 175, 0.4);
}

.impact-value {
    font-size: 1.25rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Mejoras en las tarjetas de responsabilidad */
.responsibility-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 2px solid var(--gray-200);
    transition: var(--transition);
}

.responsibility-card:hover {
    border-color: var(--primary);
    background: linear-gradient(135deg, #ffffff 0%, #eff6ff 100%);
}

.responsibility-icon {
    background: var(--gradient-primary);
    transition: var(--transition);
}

.responsibility-card:hover .responsibility-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 12px 30px rgba(30, 64, 175, 0.4);
}

/* ============================================
   CHATBOX WIDGET
   ============================================ */
.chatbox-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    font-family: 'Inter', sans-serif;
}

/* Botón flotante del chat */
.chatbox-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.chatbox-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(102, 126, 234, 0.6);
}

.chatbox-toggle.active {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.chatbox-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ef4444;
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    border: 2px solid white;
}

/* Panel del chat */
.chatbox-panel {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 380px;
    max-width: calc(100vw - 40px);
    height: 500px;
    max-height: calc(100vh - 120px);
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.95);
    transition: all 0.3s ease;
}

.chatbox-panel.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

/* Header del chat */
.chatbox-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 16px 20px;
    border-radius: 16px 16px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chatbox-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.chatbox-close {
    background: transparent;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: background 0.2s;
}

.chatbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Body del chat */
.chatbox-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    background: #f8f9fa;
}

.chatbox-body::-webkit-scrollbar {
    width: 6px;
}

.chatbox-body::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.chatbox-body::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
}

.chatbox-body::-webkit-scrollbar-thumb:hover {
    background: #999;
}

/* Mensajes */
.chatbox-message {
    display: flex;
    margin-bottom: 16px;
    gap: 10px;
    animation: fadeInMessage 0.3s ease;
}

@keyframes fadeInMessage {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chatbox-message-user {
    flex-direction: row-reverse;
}

.chatbox-message-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 16px;
}

.chatbox-message-bot .chatbox-message-avatar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.chatbox-message-user .chatbox-message-avatar {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

.chatbox-message-content {
    max-width: 75%;
    padding: 12px 16px;
    border-radius: 18px;
    word-wrap: break-word;
}

.chatbox-message-bot .chatbox-message-content {
    background: white;
    border-bottom-left-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.chatbox-message-user .chatbox-message-content {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-bottom-right-radius: 4px;
}

.chatbox-message-ejecutiva {
    display: flex;
    margin-bottom: 16px;
    gap: 10px;
    animation: fadeInMessage 0.3s ease;
}

.chatbox-message-ejecutiva .chatbox-message-avatar {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
}

.chatbox-message-ejecutiva .chatbox-message-content {
    background: #e7f3ff;
    border-bottom-left-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Modal de identificación en chatbox */
.chatbox-identificacion {
    padding: 16px;
    margin-bottom: 16px;
    animation: fadeInMessage 0.3s ease;
}

.chatbox-identificacion .card {
    border: 2px solid #667eea;
    background: linear-gradient(135deg, #f8f9ff 0%, #ffffff 100%);
}

.chatbox-identificacion .form-control-sm {
    font-size: 13px;
    padding: 8px 12px;
}

.chatbox-identificacion .btn-sm {
    font-size: 13px;
    padding: 8px 16px;
}

.chatbox-message-content p {
    margin: 0;
    line-height: 1.5;
}

.chatbox-message-content a {
    color: #667eea;
    text-decoration: underline;
}

.chatbox-message-user .chatbox-message-content a {
    color: white;
    opacity: 0.9;
}

/* Footer del chat */
.chatbox-footer {
    padding: 16px;
    background: white;
    border-top: 1px solid #e5e7eb;
    border-radius: 0 0 16px 16px;
}

.chatbox-form {
    margin-bottom: 12px;
}

.chatbox-form .input-group {
    display: flex;
    gap: 8px;
}

.chatbox-form .form-control {
    border: 1px solid #e5e7eb;
    border-radius: 24px;
    padding: 10px 16px;
    font-size: 14px;
}

.chatbox-form .form-control:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.chatbox-form .btn {
    border-radius: 50%;
    width: 40px;
    height: 40px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
}

.chatbox-form .btn:hover {
    transform: scale(1.05);
}

/* Botones rápidos */
.chatbox-quick-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.chatbox-quick-btn {
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    padding: 6px 12px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    color: #374151;
}

.chatbox-quick-btn:hover {
    background: #e5e7eb;
    border-color: #667eea;
    color: #667eea;
}

/* Información de ejecutiva asignada */
.chatbox-ejecutiva-info {
    margin-bottom: 16px;
    animation: fadeInMessage 0.3s ease;
}

.chatbox-ejecutiva-info .alert {
    margin-bottom: 0;
    padding: 12px 16px;
    border-radius: 12px;
    background: linear-gradient(135deg, #e0e7ff 0%, #dbeafe 100%);
}

.chatbox-ejecutiva-info .alert strong {
    color: #1e40af;
    display: block;
    margin-bottom: 4px;
}

.chatbox-ejecutiva-info .alert .small {
    color: #4b5563;
    font-size: 12px;
}

.chatbox-ejecutiva-info .alert i {
    color: #667eea;
}

/* Indicador de escritura */
.chatbox-typing .chatbox-message-content {
    background: white;
    border-bottom-left-radius: 4px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 12px 16px;
}

.chatbox-typing-dots {
    display: flex;
    gap: 4px;
    align-items: center;
}

.chatbox-typing-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #667eea;
    animation: typingDot 1.4s infinite;
}

.chatbox-typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.chatbox-typing-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typingDot {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.7;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .chatbox-panel {
        width: calc(100vw - 20px);
        right: 10px;
        bottom: 80px;
    }
    
    .chatbox-toggle {
        width: 56px;
        height: 56px;
        font-size: 22px;
    }
}

/* ============================================
   CARRUSEL DE PRODUCTOS
   ============================================ */
#productosCarousel {
    margin: 2rem 0;
}

.carousel-slide-content {
    padding: 1rem;
    min-height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-image-wrapper {
    position: relative;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    overflow: hidden;
    border-radius: 1rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

.carousel-image {
    width: 100%;
    height: auto;
    min-height: 600px;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.carousel-image-wrapper:hover .carousel-image {
    transform: scale(1.05);
}

.carousel-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.1) 50%, rgba(0, 0, 0, 0.5) 100%);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 1rem;
}

.carousel-image-wrapper:hover .carousel-overlay {
    opacity: 1;
}

.ver-detalle-btn {
    transition: var(--transition);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    background: rgba(30, 64, 175, 0.9) !important;
    border: 2px solid rgba(255, 255, 255, 0.3);
    font-weight: 600;
    padding: 0.75rem 2rem;
}

.ver-detalle-btn:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 6px 30px rgba(30, 64, 175, 0.6);
    background: rgba(30, 64, 175, 1) !important;
}

/* Indicadores del carrusel personalizados */
.carousel-indicators {
    margin-bottom: 1.5rem;
}

.carousel-indicators button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: var(--gray-400);
    border: 2px solid transparent;
    transition: var(--transition);
}

.carousel-indicators button.active {
    background-color: var(--primary);
    width: 30px;
    border-radius: 6px;
}

.carousel-indicators button:hover {
    background-color: var(--primary-light);
}

/* Controles del carrusel personalizados */
.carousel-control-prev,
.carousel-control-next {
    width: 50px;
    height: 50px;
    background: rgba(30, 64, 175, 0.8);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.8;
    transition: var(--transition);
}

.carousel-control-prev {
    left: 20px;
}

.carousel-control-next {
    right: 20px;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    opacity: 1;
    background: var(--primary);
    transform: translateY(-50%) scale(1.1);
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 20px;
    height: 20px;
}

/* Modal de imagen */
#modalImagen .modal-content {
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
}

#modalImagen .modal-body {
    max-height: 90vh;
    overflow: auto;
}

#modalImagen .modal-body img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
}

#modalImagen .btn-close {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    padding: 0.5rem;
    opacity: 0.8;
    transition: var(--transition);
}

#modalImagen .btn-close:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

/* Responsive para carrusel */
@media (max-width: 768px) {
    .carousel-slide-content {
        padding: 0.5rem;
        min-height: 400px;
    }
    
    .carousel-image-wrapper {
        max-width: 100%;
    }
    
    .carousel-image {
        min-height: 400px;
    }
    
    .carousel-overlay {
        padding: 1.5rem;
        opacity: 1; /* Mostrar siempre en móvil */
    }
    
    .ver-detalle-btn {
        padding: 0.625rem 1.5rem;
        font-size: 0.9rem;
    }
    
    .carousel-control-prev,
    .carousel-control-next {
        width: 40px;
        height: 40px;
    }
    
    .carousel-control-prev {
        left: 10px;
    }
    
    .carousel-control-next {
        right: 10px;
    }
}