:root {
    /* Colores actualizados - dorado en lugar de verde */
    --primary-color: #D4AF37; /* Color dorado */
    --primary-dark: #B8860B; /* Dorado oscuro para hover */
    --secondary-color: #1a3a5f; /* Azul médico profesional */
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --text-color: #333333;
    --gray-color: #6c757d;
    --light-gray: #e9ecef;
    --box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --transition: all 0.4s ease; /* Transición más lenta */
}

/* Fade ultra suave al cargar o recargar página */
html {
    scroll-behavior: smooth;
}

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

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
  overflow-x: hidden;
    opacity: 0;
    transition: opacity 1s ease-out; /* 👈 0.6s = suave pero no lento */
    background-color: #ffffff; /* o el color de fondo de tu sitio */
}

body.loaded {
    opacity: 1;
}
/* Overlay para efecto de transición */
#page-transition-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.5); /* Más transparente */
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease-in-out; /* Tiempo reducido */
}

#page-transition-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* Efecto de neblina ajustado para transición más rápida */
#page-fog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2); /* Más ligero */
    backdrop-filter: blur(3px); /* Efecto de neblina más suave */
    z-index: 99999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease-in-out; /* Tiempo reducido */
}

#page-fog-overlay.active {
    opacity: 1;
}

/* Ajustes para el cuerpo al salir y entrar */
body.page-transition-out {
    opacity: 0;
    transition: opacity 0.5s ease-in-out !important;
}

body.page-transition-in {
    opacity: 0;
    transition: none;
}

body.page-transition-in.loaded {
    opacity: 1;
    transition: opacity 0.5s ease-in-out;
}


/* Overlay para efecto de transición */
#page-transition-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.5);
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease-in-out;
}

#page-transition-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* Efecto de neblina ajustado para transición más rápida */
#page-fog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(3px);
    z-index: 99999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease-in-out;
}

#page-fog-overlay.active {
    opacity: 1;
}

/* Ajustes para el cuerpo al salir y entrar */
body.page-transition-out {
    opacity: 0;
    transition: opacity 0.5s ease-in-out !important;
}

/* Clase específica para transición de idioma más larga */
body.lang-transition-out {
    opacity: 0;
    transition: opacity 1.0s ease-in-out !important;
}

body.page-transition-in {
    opacity: 0;
    transition: none;
}

body.page-transition-in.loaded {
    opacity: 1;
    transition: opacity 0.5s ease-in-out;
}

/* Para transición de idioma */
body.lang-transition-in.loaded {
    opacity: 1;
    transition: opacity 1.0s ease-in-out;
}




/* CSS para el selector de idioma */
.language-switch {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.06);
    padding: 4px 8px;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(6px);
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    font-size: 13px;
}

.language-switch .lang-option {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-weight: 500;
    padding: 5px 12px;
    border-radius: 20px;
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    font-size: 13px;
    position: relative;
    letter-spacing: 0.3px;
    will-change: transform, background, color;
}

.language-switch .lang-option:hover {
    color: white;
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-0.5px) scale(1.02);
}

.language-switch .lang-option.active {
    background: var(--primary-color);
    color: white !important;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(212, 175, 55, 0.3);
    transform: translateY(-0.5px);
}

/* Overlay para efecto de transición */
#page-transition-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.5);
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease-in-out;
}

#page-transition-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* Efecto de neblina ajustado para transición más rápida */
#page-fog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(3px);
    z-index: 99999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 1.0s ease-in-out; /* Tiempo ajustado para transición más suave para idioma */
}

#page-fog-overlay.active {
    opacity: 1;
}

/* Ajustes para el cuerpo al salir y entrar */
body.page-transition-out {
    opacity: 0;
    transition: opacity 0.5s ease-in-out !important;
}

/* Clase específica para transición de idioma más larga */
body.lang-transition-out {
    opacity: 0;
    transition: opacity 1.0s ease-in-out !important;
}

body.page-transition-in {
    opacity: 0;
    transition: none;
}

body.page-transition-in.loaded {
    opacity: 1;
    transition: opacity 0.5s ease-in-out;
}

/* Para transición de idioma */
body.lang-transition-in.loaded {
    opacity: 1;
    transition: opacity 1.0s ease-in-out;
}


/* Contenedor principal para márgenes laterales */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

/* Top Bar */
.top-bar {
    background-color: var(--secondary-color);
    color: white;
    font-size: 0.875rem;
    padding: 8px 0;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.top-bar-left, .top-bar-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.top-bar a {
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 5px;
}








.language-switch {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.06);
    padding: 4px 8px;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(6px);
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.06);
    transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    font-size: 13px;
}

.language-switch .fas {
    color: white;
    font-size: 13px;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    transform-origin: center;
}

.language-switch:hover .fas {
    transform: rotate(20deg) scale(1.05);
}

.language-switch .lang-option {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-weight: 500;
    padding: 5px 12px;
    border-radius: 20px;
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    font-size: 13px;
    position: relative;
    letter-spacing: 0.3px;
    will-change: transform, background, color;
}

.language-switch .lang-option:hover {
    color: white;
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-0.5px) scale(1.02);
}

.language-switch .lang-option.active {
    background: var(--primary-color);
    color: white !important;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(212, 175, 55, 0.3);
    transform: translateY(-0.5px);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.language-switch .lang-option.active:hover {
    background: var(--primary-dark);
    box-shadow: 0 3px 12px rgba(184, 134, 11, 0.4);
    transform: translateY(-1px) scale(1.03);
}

/* Versión móvil — mantén usabilidad táctil pero más compacto */
@media (max-width: 768px) {
    .language-switch {
        padding: 5px 10px;
    }

    .language-switch .lang-option {
        padding: 6px 14px;
        font-size: 14px;
    }

    .language-switch .fas {
        font-size: 14px;
    }
}







/* Header - CORRECCIÓN DEFINITIVA DEL MENÚ */
.header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    transition: var(--transition);
    transform: translateY(0);
}

/* Ajuste del header para márgenes laterales */
.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 40px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.logo img {
    height: 50px;
    transition: var(--transition);
}

/* MENÚ DE ESCRITORIO - CORRECCIÓN CRÍTICA */
.main-nav {
    display: block;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 25px;
}

.main-nav ul li {
    position: relative;
}

.main-nav ul li a {
    color: var(--dark-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 16px;
    transition: var(--transition);
    padding: 5px 0;
    position: relative;
}

.main-nav ul li a.active, .main-nav ul li a:hover {
    color: var(--primary-color);
}

.main-nav ul li a.active::after, .main-nav ul li a:hover::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color);
}

.has-dropdown:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    min-width: 200px;
    box-shadow: var(--box-shadow);
    padding: 15px 0;
    border-radius: 4px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    z-index: 100;
}

.dropdown li {
    padding: 0;
}

.dropdown li a {
    display: block;
    padding: 10px 20px;
    color: var(--dark-color);
    font-weight: 400;
}

.dropdown li a:hover {
    background-color: var(--light-gray);
    color: var(--primary-color);
    padding-left: 25px;
}

.mobile-menu-toggle {
    display: none;
    cursor: pointer;
    font-size: 24px;
}

/* Hero Section */
.hero {
    height: 70vh;
    min-height: 500px;
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
}

.hero-slider {
    position: relative;
    width: 100%;
    height: 100%;
    grid-column: 1 / -1;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: top center;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
    z-index: 1;
}

.hero-slide.active {
    opacity: 1;
    z-index: 2;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.3));
}

/* Contenido del carrusel desde la columna 2 */
.hero-content {
    grid-column: 2 / -1;
    height: 90%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    padding-top: 80px;
    padding-left: 0;
    padding-right: 5%;
    padding-bottom: 10%;
    z-index: 3;
}

.hero-text-container {
    max-width: 550px;
    margin: 0;
    text-align: left;
}

/* Tamaño de texto y espaciado */
.hero-title {
    font-size: 2.4rem;
    color: white;
    margin-bottom: 0.8rem;
    line-height: 1.2;
    text-align: left;
}

.hero-subtitle {
    font-size: 1.1rem;
    color: white;
    margin-bottom: 1.2rem;
    max-width: 500px;
    text-align: left;
}

/* Botones adaptados y alineados desde el 10% hacia arriba */
.hero-buttons {
    display: flex;
    gap: 12px;
    margin-top: auto;
    margin-bottom: 10%;
    flex-wrap: wrap;
    width: 100%;
}

.btn {
    display: inline-block;
    padding: 8px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    text-align: center;
    cursor: pointer;
    font-size: 14px;
    min-width: 120px;
}

/* Efecto de degradado intenso desde el 0% y sube un 10% */
.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 10%;
    background: linear-gradient(to top, rgba(255, 255, 255, 1), rgba(255, 255, 255, 0));
    z-index: 3;
}

/* Puntos del slider */
.hero-slider-nav {
    position: absolute;
    bottom: 120px;
    width: 100%;
    text-align: center;
    z-index: 10;
}

/* Imagen siempre desde la parte superior */
.hero-slide {
    background-position: top center !important;
}

/* Ajuste del contenido del hero para centrado y márgenes */
.hero-content {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 80px;
}

.hero-text-container {
    max-width: 700px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: left;
}

.hero-title {
    font-size: 3.5rem;
    color: white;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    text-align: left;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: white;
    margin-bottom: 2rem;
    max-width: 600px;
    text-align: left;
}

.hero-buttons {
    display: flex;
    gap: 15px;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    text-align: center;
    cursor: pointer;
    font-size: 16px;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    border: 2px solid var(--primary-color);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.btn-secondary {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

.btn-secondary:hover {
    background-color: white;
    color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.hero-slider-nav {
    position: absolute;
    bottom: 30px;
    width: 100%;
    text-align: center;
    z-index: 10;
}

.slider-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: var(--transition);
}

.dot.active {
    background-color: white;
    transform: scale(1.2);
}

/* Efectos de texto para carrusel */
.text-reveal {
    display: block;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.hero-slide.active .text-reveal {
    opacity: 1;
    transform: translateY(0);
}

/* Trust Section */
.trust-section {
    background-color: white;
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.trust-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.05) 0%, rgba(255, 255, 255, 0) 70%);
    z-index: 0;
}

.trust-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.trust-icon {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 30px;
    color: var(--dark-color);
}

.section-title span {
    color: var(--primary-color);
}

.trust-description {
    max-width: 700px;
    margin: 0 auto 40px;
    font-size: 1.1rem;
    color: var(--gray-color);
}

/* Estilos base para la sección de estadísticas - Pantallas grandes */
.trust-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
    background: #f8f9fa;
    padding: 40px;
    border-radius: 12px;
}

.stat-item {
    text-align: center;
    padding: 20px;
}

.stat-number {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
    line-height: 1.2;
    font-weight: 700;
}

.stat-label {
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 15px;
    font-size: 1.1rem;
}

/* Media Query para tablets (768px - 991px) */
@media (max-width: 991px) {
    .trust-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
        padding: 30px;
    }

    .stat-number {
        font-size: 2.2rem;
    }
}

/* Media Query para móviles (hasta 767px) */
@media (max-width: 767px) {
    .trust-stats {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 25px 15px;
    }

    .stat-number {
        font-size: 1.8rem;
    }

    .stat-label {
        font-size: 1rem;
        margin-bottom: 10px;
    }
}

/* Media Query para pantallas muy pequeñas (hasta 480px) */
@media (max-width: 480px) {
    .trust-stats {
        padding: 20px 10px;
    }

    .stat-number {
        font-size: 1.6rem;
    }

    .stat-item p {
        font-size: 0.85rem;
    }
}

/* Transiciones suaves para cambios responsivos */
.trust-stats, .stat-number, .stat-label {
    transition: all 0.3s ease;
}

/* Fuerza submenús verticales */
.main-nav .dropdown {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    min-width: 220px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    padding: 10px 0;
    z-index: 100;
}

.main-nav .dropdown li {
    display: block; /* ¡Esencial para vertical! */
    width: 100%;
}

.main-nav .dropdown li a {
    display: block;
    padding: 12px 20px;
    color: #333;
}

.main-nav .has-dropdown:hover > .dropdown {
    display: block;
}

/* Para móviles */
.mobile-menu-content .dropdown {
    padding-left: 20px;
    display: none;
}

.mobile-menu-content .has-dropdown.active > .dropdown {
    display: block;
}

/* Services Section */
.services-section {
    padding: 100px 0;
    background-color: var(--light-gray);
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.highlight {
    color: var(--primary-color);
}

/* Ajuste del grid de servicios para márgenes internos */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.service-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    text-align: center;
    padding: 30px;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.service-icon {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.service-card p {
    color: var(--gray-color);
    margin-bottom: 20px;
    min-height: 70px;
}

/* Why Us Section */
.why-us-section {
    padding: 100px 0;
    background-color: white;
}

/* Ajuste del grid de "why us" para márgenes internos */
.why-us-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.why-us-item {
    background: var(--light-gray);
    border-radius: 8px;
    padding: 30px;
    transition: var(--transition);
}

.why-us-item:hover {
    background: var(--secondary-color);
    transform: translateY(-5px);
}

.why-us-item:hover h3, .why-us-item:hover p {
    color: white;
}

.why-us-icon {
    font-size: 36px;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.why-us-item h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--secondary-color);
}

.why-us-item p {
    color: var(--gray-color);
}

/* Testimonials Section */
.testimonials-section {
    padding: 100px 0;
    background: linear-gradient(to bottom, var(--light-gray), white);
    position: relative;
    overflow: hidden;
}

.testimonials-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100" preserveAspectRatio="none"><path d="M0,0 L100,0 L100,100 Z" fill="white" opacity="0.1"/></svg>') no-repeat;
    background-size: 100% 100%;
    z-index: 0;
}

.testimonials-slider {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.testimonial-slide {
    display: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.testimonial-slide.active {
    display: block;
    opacity: 1;
}

.testimonial-content {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: var(--box-shadow);
    position: relative;
}

.testimonial-content::before {
    content: '\201C';
    font-size: 80px;
    color: var(--primary-color);
    position: absolute;
    top: 20px;
    left: 20px;
    font-family: serif;
    line-height: 1;
}

.testimonial-text {
    font-size: 1.2rem;
    line-height: 1.7;
    color: var(--dark-color);
    font-style: italic;
    position: relative;
    z-index: 1;
}

.testimonial-author {
    text-align: right;
    margin-top: 20px;
}

.author-name {
    font-weight: 600;
    color: var(--secondary-color);
    font-size: 1.1rem;
}

.author-location {
    color: var(--primary-color);
    font-weight: 500;
}

.testimonials-nav {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 30px;
}

.testimonial-prev, .testimonial-next {
    background: var(--secondary-color);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.testimonial-prev:hover, .testimonial-next:hover {
    background: var(--primary-color);
    transform: scale(1.1);
}

/* Locations Section */
.locations-section {
    padding: 100px 0;
    background-color: white;
}

/* Ajuste del grid de ubicaciones para márgenes internos */
.locations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.location-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 20px;
}

.location-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.location-image {
    height: 200px;
    overflow: hidden;
    position: relative;
}

.location-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.location-card:hover .location-image img {
    transform: scale(1.05);
}

.location-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.7), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.location-card:hover .location-image::after {
    opacity: 1;
}

.location-content {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.location-content h3 {
    font-size: 1.8rem;
    color: var(--secondary-color);
    margin-bottom: 15px;
    position: relative;
    padding-bottom: 10px;
}

.location-content h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background-color: var(--primary-color);
}

.location-address, .location-phone {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 12px 0;
    color: var(--gray-color);
}

.location-hours {
    margin: 20px 0;
    padding-top: 20px;
    border-top: 1px solid var(--light-gray);
}

.location-hours h4 {
    font-size: 1.2rem;
    color: var(--secondary-color);
    margin-bottom: 10px;
}

.location-hours p {
    margin: 8px 0;
    color: var(--gray-color);
}

/* CTA Section */
.cta-section {
    padding: 100px 0;
    background: linear-gradient(to right, var(--secondary-color), #0a244d);
    color: white;
    text-align: center;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.cta-content h2 {
    font-size: 2.8rem;
    margin-bottom: 20px;
    color: white;
}

.cta-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
}

.btn-large {
    padding: 15px 40px;
    font-size: 1.1rem;
}

/* Footer */
.footer {
    background: var(--secondary-color);
    color: white;
    padding-top: 70px;
}

.footer-top {
    padding-bottom: 50px;
}

/* Ajuste del grid del footer para márgenes internos */
.footer-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-column h3 {
    font-size: 1.5rem;
    margin-bottom: 25px;
    color: white;
    position: relative;
    padding-bottom: 10px;
}

.footer-column h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background-color: var(--primary-color);
}

.footer-column p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 25px;
    line-height: 1.7;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
}

.footer-locations li {
    margin-bottom: 12px;
}

.footer-locations a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

.footer-locations a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.business-hours li {
    margin-bottom: 12px;
    color: rgba(255, 255, 255, 0.7);
}

.business-hours strong {
    color: white;
}

.footer-bottom {
    background: #0a1e38;
    padding: 20px 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.copyright {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

/* Efectos de animación */
.fade-in-section {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.slide-up {
    opacity: 1;
    transform: translateY(0);
}

.text-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* Mobile Menu - CORRECCIÓN DEFINITIVA: Solo para móviles */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    display: none;
    overflow-y: auto;
}

.mobile-menu-overlay.active {
    display: block;
}

.mobile-menu-content {
    position: relative;
    height: 100%;
    padding: 20px;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.close-menu {
    color: white;
    font-size: 24px;
    cursor: pointer;
}

.mobile-menu-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background-color: rgba(0, 0, 0, 0.9);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* CORRECCIÓN CRÍTICA: Solo aplicar estilos verticales al menú móvil */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }

    .header-content {
        padding: 15px 20px;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .main-nav {
        display: none;
    }

    .mobile-menu-overlay .main-nav {
        display: block;
    }

    .mobile-menu-overlay .main-nav ul {
        flex-direction: column;
        gap: 0;
    }

    .mobile-menu-overlay .main-nav ul li {
        margin: 15px 0;
    }

    .mobile-menu-overlay .main-nav ul li a {
        color: white;
        font-size: 18px;
    }

    .mobile-menu-overlay .has-dropdown .dropdown {
        display: none;
        position: static;
        box-shadow: none;
        padding: 0;
        background: transparent;
    }

    .mobile-menu-overlay .has-dropdown.open .dropdown {
        display: block;
    }

    .mobile-menu-overlay .submenu-toggle {
        position: absolute;
        right: 0;
        cursor: pointer;
    }
}

/* Media Queries */
@media (max-width: 992px) {
    .hero-title {
        font-size: 2.8rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 2.2rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .stat-number {
        font-size: 2.5rem;
    }

    .cta-content h2 {
        font-size: 2.2rem;
    }
}

@media (max-width: 576px) {
    .top-bar-content {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .hero-title {
        font-size: 1.8rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }

    .section-title {
        font-size: 1.7rem;
    }

    .locations-grid {
        grid-template-columns: 1fr;
    }
}

/* Selector de idiomas en el menú principal - NUEVO */
.main-nav ul li.language-switcher {
    position: relative;
    margin-left: 30px;
}

.main-nav ul li.language-switcher a.language-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--dark-color);
    font-weight: 500;
    transition: var(--transition);
    padding: 5px 0;
}

.main-nav ul li.language-switcher a.language-toggle:hover {
    color: var(--primary-color);
}

.main-nav ul li.language-switcher .dropdown {
    min-width: 120px;
    padding: 12px 0;
    text-align: center;
}

.main-nav ul li.language-switcher .dropdown li a {
    padding: 8px 15px;
    font-weight: 500;
    font-size: 16px;
}

/* Estado activo para idioma seleccionado */
.main-nav ul li.language-switcher .dropdown li a.active {
    color: var(--primary-color);
    font-weight: 700;
    background-color: rgba(212, 175, 55, 0.1);
    position: relative;
}

.main-nav ul li.language-switcher .dropdown li a.active::after {
    content: '✓';
    position: absolute;
    left: 10px;
    color: var(--primary-color);
}

/* Selector de idiomas - Efecto inverso */
.language-switch a.lang-option {
    color: var(--dark-color);
    transition: var(--transition);
}

/* Cuando el idioma ACTUAL es español, destacar el inglés */
html[lang="es"] .language-switch a[href*="lang=en"] {
    color: var(--primary-color);
}

/* Cuando el idioma ACTUAL es inglés, destacar el español */
html[lang="en"] .language-switch a[href*="lang=es"] {
    color: var(--primary-color);
}

/* Asegurar que el idioma actual NUNCA se muestre en dorado */
html[lang="es"] .language-switch a[href*="lang=es"],
html[lang="en"] .language-switch a[href*="lang=en"] {
    color: var(--dark-color) !important;
}

.trust-section {
    padding: 80px 0;
}

.trust-content {
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.trust-icon {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 25px;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 30px;
    color: var(--dark-color);
    line-height: 1.3;
}

.section-title span {
    color: var(--primary-color);
}

.trust-description {
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--gray-color);
    text-align: justify;
    text-justify: inter-word;
}

.trust-description p {
    margin-bottom: 20px;
}

.trust-stats {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 40px;
}

.stat-item {
    text-align: center;
    padding: 20px;
}

.stat-number {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.stat-label {
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 15px;
    font-size: 1.1rem;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .trust-section {
        padding: 60px 0;
    }

    .section-title {
        font-size: 2rem;
    }

    .trust-description {
        font-size: 1rem;
        text-align: left;
    }

    .trust-stats {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 30px 20px;
    }
}

.cta-section {
    padding: 100px 0;
    background: linear-gradient(135deg, var(--secondary-color) 0%, #0a244d 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100" preserveAspectRatio="none"><path d="M0,0 L100,0 L100,100 Z" fill="rgba(255,255,255,0.03)"/></svg>');
    background-size: 100% 100%;
}

.cta-content {
    position: relative;
    z-index: 2;
}

.cta-header {
    text-align: center;
    margin-bottom: 60px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.cta-header h2 {
    font-size: 2.8rem;
    margin-bottom: 20px;
    color: white;
    line-height: 1.2;
}

.cta-header p {
    font-size: 1.2rem;
    opacity: 0.9;
    line-height: 1.6;
}

.cta-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
}

.cta-option {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.cta-option:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.option-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.cta-option h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: white;
}

.cta-option p {
    margin-bottom: 25px;
    opacity: 0.8;
    line-height: 1.6;
}

.btn-large {
    padding: 15px 25px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 8px;
    width: 100%;
    margin-bottom: 15px;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    border: none;
}

.btn-primary:hover {
    background-color: #b8860b;
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: white;
    color: var(--secondary-color);
    border: none;
}

.btn-secondary:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
}

.btn-whatsapp {
    background-color: #25D366;
    color: white;
    border: none;
}

.btn-whatsapp:hover {
    background-color: #128C7E;
    transform: translateY(-2px);
}

.response-time, .security-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.9rem;
    opacity: 0.8;
}

.cta-assurances {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 25px;
    margin-bottom: 40px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.assurance-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.assurance-item i {
    color: var(--primary-color);
}

.cta-testimonial {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.testimonial-content {
    background: rgba(255, 255, 255, 0.05);
    padding: 25px;
    border-radius: 10px;
    border-left: 4px solid var(--primary-color);
}

.testimonial-text {
    font-style: italic;
    margin-bottom: 15px;
    line-height: 1.6;
    font-size: 1.1rem;
}

.testimonial-author {
    font-weight: 600;
}

.author-location {
    font-size: 0.9rem;
    opacity: 0.8;
}

/* Responsive */
@media (max-width: 768px) {
    .cta-header h2 {
        font-size: 2.2rem;
    }

    .cta-options {
        grid-template-columns: 1fr;
    }

    .cta-assurances {
        flex-direction: column;
        gap: 15px;
    }
}

/* Animaciones para los elementos de revelado */
.text-reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* Estilos para el nombre de Héctor Melgar */
.text-black {
    color: #000000;
    font-weight: 700;
}

.text-gold {
    color: var(--primary-color);
    font-weight: 700;
}

/* Para asegurar que el efecto dorado funcione en todos los contextos */
.highlight-name .text-gold {
    color: var(--primary-color);
    text-shadow: 0 0 3px rgba(212, 175, 55, 0.3);
}

/* Efecto hover para interacciones */
.text-gold:hover {
    color: var(--primary-dark);
    transition: color 0.3s ease;
}

/* =================== */
/* GALLERY SECTION CSS */
/* =================== */

/* Contenedor principal de la galería */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

/* Estilos base para cada elemento de la galería */
.gallery-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 250px; /* Altura fija para consistencia */
    cursor: pointer; /* Indica que es clickeable */
}

/* Imagenes - Mantienen proporción y tamaño */
.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

/* Efecto hover - Zoom suave en la imagen */
.gallery-item:hover img {
    transform: scale(1.05);
}

/* Información de la imagen - Overlay con transición suave */
.image-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85), transparent);
    padding: 20px;
    transform: translateY(30px);
    opacity: 0;
    transition: all 0.3s ease;
    color: white;
}

/* Título en el overlay */
.image-info h3 {
    color: white;
    margin-bottom: 8px;
    font-size: 1.2rem;
    font-weight: 600;
}

/* Contenedor de estrellas */
.rating {
    margin: 8px 0;
    color: #FFD700; /* Dorado para las estrellas */
    font-size: 0.9rem;
}

/* Descripción */
.image-info p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
    line-height: 1.4;
    margin-top: 5px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Efecto hover - Mostrar información */
.gallery-item:hover .image-info {
    transform: translateY(0);
    opacity: 1;
}

/* Diseño responsivo - Ajustes para diferentes pantallas */
@media (max-width: 1200px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
}

@media (max-width: 992px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    }
}

@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }

    .gallery-item {
        height: 220px;
    }
}

@media (max-width: 576px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 15px;
    }

    .gallery-item {
        height: 180px;
        border-radius: 10px;
    }

    .image-info {
        padding: 15px;
    }

    .image-info h3 {
        font-size: 1.1rem;
    }
}

/* Efecto de carga para los elementos */
.gallery-item.fade-in-section {
    opacity: 0;
    transform: translateY(20px);
}

.gallery-item.slide-up {
    opacity: 1;
    transform: translateY(0);
}

/* Estilos adicionales para mejorar la experiencia en móviles */
@media (hover: none) {
    .gallery-item:hover .image-info {
        transform: translateY(0);
        opacity: 1;
    }

    .gallery-item:active .image-info {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Optimización para pantallas táctiles */
.gallery-item {
    touch-action: manipulation;
}

/* Estilos para el placeholder de imágenes */
.gallery-item img[src*="picsum"] {
    filter: brightness(0.9);
    transition: filter 0.3s ease;
}

.gallery-item:hover img[src*="picsum"] {
    filter: brightness(1);
}

/* =================== */
/* LIGHTBOX (VISTA GRANDE) - IMAGEN MÁS GRANDE */
/* =================== */

/* Overlay oscuro que cubre toda la pantalla */
.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 2000;
    display: none;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox-overlay.active {
    display: flex;
    opacity: 1;
}

/* Contenedor principal del lightbox */
.lightbox-container {
    position: relative;
    max-width: 95%;
    max-height: 95%;
    width: 900px;
    display: flex;
    flex-direction: column;
    animation: fadeIn 0.4s ease;
}

/* Imagen grande en el lightbox - AHORA MÁS GRANDE */
.lightbox-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    border-radius: 8px;
    margin-bottom: 15px; /* Reducido para dar más espacio a la imagen */
}

.lightbox-image img {
    max-width: 95%;
    max-height: 85vh; /* AUMENTADO de 60vh a 85vh - MÁS GRANDE */
    object-fit: contain;
    border-radius: 6px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease;
}

.lightbox-image img:hover {
    transform: scale(1.02);
}

/* Información detallada en el lightbox - AHORA MÁS COMPACTA */
.lightbox-info {
    background: white;
    border-radius: 8px;
    padding: 20px; /* Reducido para dar más espacio a la imagen */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    margin-top: 5px; /* Espacio reducido */
}

.lightbox-info h3 {
    color: var(--secondary-color);
    font-size: 1.6rem; /* Ligeramente reducido para equilibrar */
    margin-bottom: 10px; /* Reducido */
    position: relative;
    padding-bottom: 8px; /* Reducido */
}

.lightbox-info h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px; /* Ligeramente reducido */
    height: 2.5px; /* Ligeramente reducido */
    background-color: var(--primary-color);
}

/* Controles de navegación */
.lightbox-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px; /* Reducido */
}

.lightbox-nav {
    display: flex;
    gap: 12px; /* Ligeramente reducido */
}

.lightbox-btn {
    background: var(--secondary-color);
    color: white;
    border: none;
    width: 40px; /* Ligeramente reducido */
    height: 40px; /* Ligeramente reducido */
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    font-size: 1.1rem; /* Ligeramente reducido */
}

.lightbox-btn:hover {
    background: var(--primary-color);
    transform: scale(1.1);
}

/* Botón de cierre */
.close-lightbox {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    z-index: 10;
    font-size: 1.2rem;
}

.close-lightbox:hover {
    background: var(--primary-color);
    transform: rotate(90deg);
}

/* Contador de imágenes */
.image-counter {
    background: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    position: absolute;
    top: 20px;
    left: 20px;
    z-index: 10;
}

/* Rating en el lightbox - Más destacado */
.lightbox-info .rating {
    color: #D4AF37; /* Dorado */
    font-size: 1.1rem; /* Ligeramente reducido */
    margin: 8px 0; /* Reducido */
    display: flex;
    gap: 2px; /* Reducido */
}

.lightbox-info p {
    color: var(--text-color);
    line-height: 1.5; /* Ligeramente reducido */
    font-size: 0.95rem; /* Ligeramente reducido */
    margin: 8px 0 0 0; /* Ajustado */
}

/* Animaciones */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Diseño responsivo para el lightbox - MÁS ESPACIO PARA IMAGEN */
@media (max-width: 1200px) {
    .lightbox-container {
        width: 95%;
    }

    .lightbox-image img {
        max-height: 80vh; /* Aumentado para pantallas medianas */
    }
}

@media (max-width: 992px) {
    .lightbox-container {
        width: 95%;
    }

    .lightbox-image img {
        max-height: 75vh; /* Aumentado para tablets */
    }
}

@media (max-width: 768px) {
    .lightbox-container {
        flex-direction: column;
        max-height: 95vh;
        width: 95%;
    }

    .lightbox-image {
        max-height: 70vh; /* AUMENTADO de 50vh a 70vh */
        margin-bottom: 12px;
    }

    .lightbox-image img {
        max-height: 65vh; /* AUMENTADO de 45vh a 65vh */
        max-width: 95%;
    }

    .lightbox-info {
        padding: 18px;
    }

    .lightbox-info h3 {
        font-size: 1.4rem;
    }

    .close-lightbox {
        top: 15px;
        right: 15px;
        width: 35px;
        height: 35px;
    }
}

@media (max-width: 576px) {
    .lightbox-container {
        padding: 8px;
    }

    .lightbox-info {
        padding: 12px;
    }

    .lightbox-info h3 {
        font-size: 1.2rem;
    }

    .lightbox-controls {
        flex-direction: column;
        gap: 8px;
    }

    .lightbox-nav {
        width: 100%;
        justify-content: center;
    }

    .lightbox-btn {
        width: 35px;
        height: 35px;
        font-size: 0.9rem;
    }

    .lightbox-image {
        max-height: 65vh; /* AUMENTADO para móviles pequeños */
    }

    .lightbox-image img {
        max-height: 60vh; /* AUMENTADO para móviles pequeños */
    }
}

/* Estilos generales */
.improved-design {
    padding: 2rem 0;
}

.improved-design .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.improved-design .section-header {
    text-align: center;
    margin-bottom: 2rem;
}

.improved-design .section-header h2 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
}

.improved-design .section-header p {
    font-size: 1.1rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

/* Mapa con margen del 5% */
.map-with-margin {
    width: 90%;
    margin: 0 5%;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    height: 350px;
    margin-bottom: 2rem;
}

.map-with-margin iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Contenedor de contenido */
.content-wrapper {
    width: 100%;
}

/* Sección de contacto */
.contact-section {
    margin-bottom: 3rem;
    padding: 0 5%;
}

.contact-section h3 {
    font-size: 1.6rem;
    margin-bottom: 1.5rem;
    color: #333;
}

.contact-info {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.contact-item i {
    color: var(--primary-color);
    font-size: 1.2rem;
    width: 24px;
}

.contact-item span, .contact-item a {
    font-size: 1.1rem;
    color: #333;
    text-decoration: none;
}

.map-buttons {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
}

.map-btn {
    padding: 1.25rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    font-size: 1.1rem;
    transition: all 0.2s ease;
}

.map-btn.google-maps {
    background: var(--primary-color);
    color: white;
}

.map-btn.apple-maps {
    background: #333;
    color: white;
}

/* Secciones de transporte */
.transport-section {
    padding: 2rem 5%;
    margin-bottom: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.public-transport {
    background: #ffffff;
}

.patient-transport {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 1px solid #e6f3ff;
}

.transport-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.transport-header i {
    color: var(--primary-color);
    font-size: 1.8rem;
}

.transport-header h3 {
    font-size: 1.6rem;
    margin: 0;
    color: #333;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.free-badge {
    background: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

/* Grid de transporte público */
.transport-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

.transport-item {
    display: flex;
    gap: 1.25rem;
    padding: 1.5rem;
    background: #f8f9fa;
    border-radius: 12px;
}

.transport-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.transport-icon.metro {
    background: #0039a6;
}

.transport-icon.bus {
    background: #ff6319;
}

.transport-icon i {
    color: white;
    font-size: 1.8rem;
}

.transport-details h4 {
    font-size: 1.3rem;
    margin: 0 0 0.5rem 0;
    color: #333;
}

.transport-details > p {
    font-size: 1rem;
    color: #666;
    margin: 0 0 1rem 0;
}

.transport-info p {
    font-size: 1rem;
    line-height: 1.5;
    color: #444;
    margin-bottom: 1rem;
}

.distance-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
}

.metro .distance-info {
    background: #e6f3ff;
    color: #0039a6;
}

.bus .distance-info {
    background: #fff5eb;
    color: #ff6319;
}

/* Transporte para pacientes */
.patient-transport .transport-content p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #444;
    margin-bottom: 1.5rem;
}

.service-features {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 2rem;
}

.feature {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.feature i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.feature span {
    font-weight: 500;
    font-size: 1rem;
}

.transport-actions {
    display: flex;
    justify-content: center;
}

.cta-button {
    background: var(--primary-color);
    color: white;
    padding: 1.25rem 2rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.1rem;
    transition: all 0.2s ease;
}

/* Efectos de hover */
.map-btn:hover,
.cta-button:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

/* Media queries para tablets */
@media (min-width: 768px) {
    .map-buttons {
        grid-template-columns: 1fr 1fr;
    }

    .transport-grid {
        grid-template-columns: 1fr 1fr;
    }

    .service-features {
        grid-template-columns: 1fr 1fr 1fr;
    }
}

/* Media queries para desktop */
@media (min-width: 1024px) {
    .improved-design {
        padding: 3rem 0;
    }

    .map-with-margin {
        height: 400px;
    }

    .contact-section,
    .transport-section {
        padding: 0 10%;
    }
}

/* Media queries para pantallas grandes */
@media (min-width: 1200px) {
    .map-with-margin {
        height: 450px;
    }
}







/* ===== SECCIÓN ANTES Y DESPUÉS - CARRUSEL SIMPLE CON UNA IMAGEN POR SLIDE ===== */
.before-after-fullscreen {
    width: 100%;
    background: white;
    position: relative;
    overflow: hidden;
    padding: 0;
    margin: 0;
}

.before-after-slider {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

.progress-bar {
    position: absolute;
    top: 20px;
    left: 0;
    width: 100%;
    height: 4px;
    background: rgba(0, 0, 0, 0.1);
    z-index: 10;
    border-radius: 2px;
}

.progress-bar-fill {
    height: 100%;
    background: var(--primary-color);
    width: 0%;
    transition: width 5s linear;
    border-radius: 2px;
}

.before-after-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease, visibility 0.8s;
}

.before-after-slide.active {
    opacity: 1;
    visibility: visible;
}

.before-after-container {
    display: flex;
    flex-direction: column;
    height: 100%;
    max-width: 1600px;
    margin: 0 auto;
    padding: 40px 60px;
}

/* === MODIFICACIONES CLAVE PARA CARRUSEL DE UNA SOLA IMAGEN === */
.image-comparison {
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 0;
    margin-bottom: 30px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    position: relative;
    height: 65vh;
}

/* Eliminamos la estructura de dos columnas y mantenemos solo una */
.image-column {
    flex: 1;
    position: relative;
    height: 100%;
    overflow: hidden;
    transition: all 0.4s ease;
    width: 100% !important;
}

/* Ocultamos la barra divisoria y los labels de "antes/después" */
.divider-bar,
.before-label,
.after-label {
    display: none !important;
}

/* Ajustamos el contenedor de imagen para ocupar todo el espacio */
.before-image,
.after-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    position: absolute;
    top: 0;
    left: 0;
    transition: transform 0.5s ease;
}

/* Mantenemos el efecto de zoom al hacer hover */
.before-after-slide:hover .before-image,
.before-after-slide:hover .after-image {
    transform: scale(1.02);
}

/* Ajustamos la sección de resultados para que esté más centrada */
.result-info {
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    margin-top: 20px;
    max-width: 800px;
    margin: 20px auto 0;
}

.result-info h3 {
    font-size: 2.2rem;
    margin-bottom: 25px;
    color: var(--dark-color);
    text-align: center;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.stat-item {
    text-align: center;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 10px;
    transition: all 0.3s ease;
    border-left: 4px solid var(--primary-color);
}

.stat-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    background: rgba(0, 102, 204, 0.05);
}

.stat-value {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--primary-color);
    display: block;
    line-height: 1;
}

.stat-label {
    font-size: 1.1rem;
    color: var(--dark-color);
    font-weight: 500;
    display: block;
    margin-top: 10px;
}

.result-description {
    font-size: 1.2rem;
    line-height: 1.7;
    color: var(--gray-color);
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

/* Navegación - Centrada y con estilo mejorado */
.before-after-nav {
    position: absolute;
    bottom: 30px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    z-index: 10;
}

.nav-btn {
    background: rgba(0, 0, 0, 0.3);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    z-index: 20;
}

.nav-btn:hover {
    background: var(--primary-color);
    transform: scale(1.1);
}

.before-after-dots {
    display: flex;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background: var(--primary-color);
    transform: scale(1.3);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.3);
}

/* Diseño responsivo para móviles */
@media (max-width: 768px) {
    .before-after-container {
        padding: 20px 15px;
    }
    
    .image-comparison {
        height: 55vh;
    }
    
    .result-info {
        padding: 25px;
    }
    
    .result-info h3 {
        font-size: 1.8rem;
    }
    
    .result-description {
        font-size: 1rem;
    }
    
    .stat-value {
        font-size: 2rem;
    }
    
    .nav-btn {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
}

/* Estilo adicional para el contenedor de la imagen */
.image-column {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
}

.image-column::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, rgba(0, 0, 0, 0.02) 25%, transparent 25%),
                linear-gradient(-45deg, rgba(0, 0, 0, 0.02) 25%, transparent 25%),
                linear-gradient(45deg, transparent 75%, rgba(0, 0, 0, 0.02) 75%),
                linear-gradient(-45deg, transparent 75%, rgba(0, 0, 0, 0.02) 75%);
    background-size: 10px 10px;
    z-index: 1;
    pointer-events: none;
    opacity: 0.3;
}

/* Efecto de overlay sutil en la imagen */
.before-image::before,
.after-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.05);
    z-index: 1;
    transition: opacity 0.3s ease;
}

.before-after-slide:hover .before-image::before,
.before-after-slide:hover .after-image::before {
    opacity: 0;
}

/* Ajustes para que el carrusel funcione como un carrusel simple */
.before-after-slide {
    display: none;
}

.before-after-slide.active {
    display: block;
}

/* Asegurar que solo se muestre una imagen por slide */
.before-image, 
.after-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: 1;
}

/* Para que el carrusel muestre solo una imagen, eliminamos la estructura de dos columnas */
.image-comparison {
    display: block;
    height: 65vh;
}

.image-column {
    width: 100% !important;
    height: 100% !important;
}







.map-container {
    margin-top: 20px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.hero-buttons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    margin: 0 10px;
}

.hero-buttons a i {
    margin-right: 8px;
}

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

.btn-secondary {
    background-color: transparent;
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.btn-primary:hover {
    background-color: #005bb5;
}

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

 .map-slide {
        min-height: 100vh; /* Ajuste de altura para el slide del mapa */
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .map-slide .hero-content {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        height: 100%;
    }

    .map-slide .hero-text-container {
        text-align: center;
        z-index: 10;  /* Asegura el texto está sobre el mapa */
        margin-bottom: 20px;
    }

    .map-container {
        width: 100%;
        height: 500px; /* Ajusta la altura según se necesite */
        border-radius: 8px;
        overflow: hidden;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    }

    /* Ajustes para asegurar que el mapa iframe tome todo el espacio */
    .map-container iframe {
        width: 100%;
        height: 100%;
        border: none;
    }

    .hero-buttons {
        display: flex;
        gap: 10px;
        margin-top: 15px;
        justify-content: center;
    }

    .hero-buttons a {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 12px 24px;
        border-radius: 30px;
        text-decoration: none;
        font-weight: 600;
        transition: all 0.3s ease;
        margin: 0 10px;
    }

    .hero-buttons a i {
        margin-right: 8px;
    }

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

    .btn-secondary {
        background-color: transparent;
        color: white;
        border: 1px solid rgba(255, 255, 255, 0.5);
    }

    .btn-primary:hover {
        background-color: #005bb5;
    }

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









    .location-card-wrapper {
    text-decoration: none;
    color: inherit;
    display: block;
}

.location-card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.location-card-wrapper:hover .location-card {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.12);
}

/* Opcional: cursor pointer en toda la tarjeta */
.location-card-wrapper {
    cursor: pointer;
}

/* Estilo para la dirección y teléfono: sin cambios visuales forzados */
.location-address span,
.location-phone a {
    /* Ya no necesitan color azul ni subrayado, solo cursor pointer */
}




/* Estilo para el contenedor del mapa responsivo */
.map-container iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

/* Efecto hover sutil en botones */
.hero-buttons .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}

/* Animación de aparición suave */
.text-reveal {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease forwards;
}

.text-reveal[style*="--delay"] {
    animation-delay: var(--delay);
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}



/* Garantizar que el iframe del mapa se muestre correctamente */
.map-container iframe {
    width: 100% !important;
    height: 100% !important;
    border: none;
    display: block;
    position: relative;
    z-index: 1;
}

/* Estilo para contenedores flex y centrado */
.hero-slide {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Animaciones suaves */
.text-reveal {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards;
}

.text-reveal[style*="--delay"] {
    animation-delay: var(--delay);
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}




.map-container iframe {
    width: 100% !important;
    height: 100% !important;
    border: none !important;
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 2;
}

.map-container {
    position: relative;
}

.map-container > div {
    position: relative;
    z-index: 2;
}



    .hero-slider {
        position: relative;
        width: 100%;
        height: 100%;
        overflow: hidden;
    }










    /* Efecto de neblina mejorado para transiciones */
#page-fog-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.8) 0%, rgba(242, 242, 242, 0.9) 100%);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    z-index: 99999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

#page-fog-overlay.active {
    opacity: 1;
}

/* Transiciones mejoradas para el body */
body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    overflow-x: hidden;
    opacity: 1;
    transition: opacity 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

body.page-transition-out {
    opacity: 0;
}

/* Efecto para enlaces con transición */
a {
    transition: color 0.3s ease, opacity 0.3s ease;
}

a.fade-out {
    opacity: 0.7;
}

/* Efecto para botones de idioma durante transición */
.language-switch.transitioning {
    opacity: 0.7;
    transform: scale(0.98);
}

/* Mejora para la transición de carga inicial */
body.loading {
    opacity: 0;
}

body.loaded {
    opacity: 1;
}


/* ========== SOLO ESTILOS PARA LA IMAGEN Y SU CONTENEDOR ========== */

.about-content {
    display: flex;
    flex-direction: column; /* En móvil: imagen arriba, texto abajo */
    align-items: center;
    gap: 2rem;
    padding: 2rem 1.5rem;
}

.about-image {
    width: 100%;
    max-width: 420px;
    height: auto;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.12);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin: 0 auto; /* Centrado en móvil */
}

.about-image:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18);
}

.about-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
    aspect-ratio: 3 / 4; /* Ideal para retratos en móvil */
    transition: filter 0.3s ease;
}

.about-image:hover img {
    filter: brightness(1.05) contrast(1.08);
}

/* ========== ESCRITORIO: Imagen a la izquierda, texto a la derecha ========== */
@media (min-width: 992px) {
    .about-content {
        flex-direction: row;
        justify-content: flex-start;
        align-items: flex-start;
        gap: 3rem;
        padding: 3rem 2rem;
        max-width: 1200px;
        margin: 3rem auto;
    }

    .about-image {
        margin: 0; /* Ya no centrado, va a la izquierda */
        max-width: 380px;
        flex-shrink: 0; /* Evita que se encoja demasiado */
    }

    .about-image img {
        aspect-ratio: 4 / 5; /* Más vertical en escritorio */
    }
}

/* ========== TABLET ========== */
@media (min-width: 768px) and (max-width: 991px) {
    .about-content {
        padding: 2.5rem 2rem;
        gap: 2.5rem;
    }

    .about-image {
        max-width: 360px;
    }

    .about-image img {
        aspect-ratio: 3.5 / 5;
    }
}


/* ========== MEJORA INVISIBLE Y REPULSIVA — CONTACT SECTION ========== */

/* Evita que algo se salga del contenedor en móviles */
.contact-section,
.map-section {
    overflow-x: hidden;
}

/* Contenedor principal de contacto: mejora el padding responsivo */
.contact-section .container {
    padding-left: 1rem;
    padding-right: 1rem;
}

/* Cabecera de sección: mejora el espaciado en móvil */
.contact-section .section-header h2 {
    font-size: clamp(1.75rem, 5vw, 2.5rem);
    line-height: 1.2;
}

.contact-section .section-header p {
    font-size: clamp(1rem, 3.5vw, 1.15rem);
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
}

/* Grid de contacto: mejora el comportamiento en breakpoints intermedios */
.contact-grid {
    gap: 2rem;
    margin-top: 3rem;
}

/* Items de contacto: alineación visual profesional */
.contact-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 1.5rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(8px);
    transition: transform 0.3s var(--transition), box-shadow 0.3s var(--transition);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
}

.contact-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

/* Icono + texto alineados visualmente */
.contact-item .why-us-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    margin-bottom: 1.25rem;
}

.contact-item h3 {
    font-size: clamp(1.25rem, 4vw, 1.5rem);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.contact-item p {
    font-size: clamp(0.95rem, 3.5vw, 1rem);
    line-height: 1.6;
    margin-bottom: 1rem;
}

/* Botón dentro de contacto-info: mejora el espaciado */
.contact-item .btn {
    margin-top: auto;
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
}

/* Formulario: asegura que no se desborde en móviles */
.contact-form form {
    padding: 2rem;
    height: fit-content;
}

.contact-form h2 {
    font-size: clamp(1.5rem, 5vw, 2rem);
    text-align: left;
}

/* Labels: mejor contraste y espaciado */
.contact-form label {
    font-size: clamp(0.9rem, 3.5vw, 1rem);
    font-weight: 600;
}

/* Inputs y selects: altura consistente y buen padding */
.contact-form input,
.contact-form select,
.contact-form textarea {
    padding: 0.75rem;
    font-size: clamp(0.95rem, 3.5vw, 1rem);
    border: 1px solid var(--light-gray);
    border-radius: 6px;
    width: 100%;
    box-sizing: border-box;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    outline: 2px solid var(--primary-color);
    border-color: var(--primary-color);
}

/* Filas del formulario: ajuste en móvil */
.form-row {
    gap: 1rem;
}

/* Botón de envío: mejora el hover y active state */
.contact-form .btn {
    padding: 0.85rem;
    font-size: clamp(0.95rem, 4vw, 1rem);
    letter-spacing: 0.5px;
}

.contact-form .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
}

.contact-form .btn:active {
    transform: translateY(0);
}

/* Mapa: mejora responsividad */
.map-container {
    width: 100%;
    height: clamp(300px, 60vh, 500px);
    border-radius: 12px;
}

/* ========== BREAKPOINTS PROFESIONALES ========== */

/* Móvil pequeño (hasta 480px) */
@media (max-width: 480px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .contact-item {
        padding: 1.25rem;
    }

    .contact-form form {
        padding: 1.5rem;
    }
}

/* Tablet vertical (481px - 768px) */
@media (min-width: 481px) and (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .contact-item {
        padding: 1.75rem;
    }

    .contact-form form {
        padding: 2rem;
    }
}

/* Tablet horizontal / desktop pequeño (769px - 1024px) */
@media (min-width: 769px) and (max-width: 1024px) {
    .contact-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }

    .contact-item h3 {
        font-size: 1.35rem;
    }

    .contact-form h2 {
        font-size: 1.75rem;
    }
}

/* Desktop (1025px+) */
@media (min-width: 1025px) {
    .contact-section .container {
        max-width: 1200px;
    }

    .contact-item {
        padding: 2rem;
    }

    .contact-form form {
        padding: 2.5rem;
    }
}

/* ========== TRANSICIONES GLOBALES SUAVES ========== */
.contact-item,
.contact-form input,
.contact-form select,
.contact-form textarea,
.contact-form .btn {
    transition: all 0.3s var(--transition);
}

/* ========== ACCESIBILIDAD Y UX ========== */
@media (prefers-reduced-motion: reduce) {
    .contact-item,
    .contact-form .btn {
        transition: none;
        transform: none;
    }
}

/* Estilos para el selector de fecha personalizado */
.custom-date-label, .custom-time-label {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--dark-color);
    cursor: pointer;
}

.custom-date-container {
    position: relative;
    display: flex;
    align-items: center;
}

.custom-date-input {
    width: 100%;
    padding: 12px 45px 12px 12px;
    border: 2px solid var(--light-gray);
    border-radius: 8px;
    font-size: 1rem;
    background-color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.custom-date-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
}

.date-picker-toggle {
    position: absolute;
    right: 8px;
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.date-picker-toggle:hover {
    background-color: rgba(74, 144, 226, 0.1);
}

.custom-date-picker {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    max-width: 320px;
    background: white;
    border: 1px solid var(--light-gray);
    border-radius: 8px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.15);
    z-index: 1000;
    margin-top: 5px;
    display: none;
}

.custom-date-picker.active {
    display: block;
}

.date-picker-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 8px 8px 0 0;
}

.nav-button {
    background: none;
    border: none;
    color: white;
    font-size: 1rem;
    cursor: pointer;
    padding: 5px 8px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.nav-button:hover {
    background-color: rgba(255,255,255,0.2);
}

.current-month-year {
    font-weight: 600;
    font-size: 1.1rem;
    text-align: center;
    flex-grow: 1;
}

.date-picker-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    padding: 10px 5px;
    background-color: #f8f9fa;
    border-bottom: 1px solid var(--light-gray);
}

.weekday {
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-color);
}

.date-picker-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    padding: 10px 5px;
}

.day {
    text-align: center;
    padding: 10px 5px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.day:hover {
    background-color: #e9ecef;
}

.day.selected {
    background-color: var(--primary-color);
    color: white;
}

.day.today {
    background-color: #ffeaa7;
    font-weight: 600;
}

.day.other-month {
    color: #adb5bd;
}

.day.disabled {
    color: #dee2e6;
    cursor: not-allowed;
}

.day.disabled:hover {
    background-color: transparent;
}

.date-picker-actions {
    display: flex;
    justify-content: space-between;
    padding: 15px;
    border-top: 1px solid var(--light-gray);
}

/* Estilos para el selector de hora mejorado */
.custom-time-container {
    position: relative;
}

.custom-time-select {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--light-gray);
    border-radius: 8px;
    font-size: 1rem;
    background-color: white;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234a90e2' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    transition: all 0.3s ease;
}

.custom-time-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
}

.time-suggestion {
    margin-top: 8px;
    color: var(--light-text);
}

/* Responsive */
@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr !important;
    }
    
    .custom-date-picker {
        max-width: 100%;
    }
    
    .date-picker-header {
        padding: 10px;
    }
    
    .current-month-year {
        font-size: 1rem;
    }
}



/* ===== CONTACT CONTENT GRID ===== */

.contact-content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
    margin-top: 50px;
}

/* Form Card Styles */
.form-card {
    background: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.1);
}

.form-title {
    color: var(--secondary-color);
    margin-bottom: 25px;
    font-size: 1.8rem;
}

.form-subtitle {
    margin-bottom: 25px;
    color: var(--text-color);
    line-height: 1.6;
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--light-gray);
    border-radius: 4px;
    font-size: 1rem;
    transition: var(--transition);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(var(--primary-color-rgb), 0.1);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--dark-color);
}

.required {
    color: var(--primary-color);
}

/* Dual Fields (Nombre/Tel, Fecha/Hora) */
.dual-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

/* Date Picker */
.date-picker-wrapper {
    position: relative;
}

.label-with-icon {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.label-with-icon i {
    color: var(--primary-color);
}

.date-input-container {
    position: relative;
}

.date-input {
    padding-right: 45px !important;
    cursor: pointer;
}

.date-picker-toggle {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--primary-color);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.date-picker-toggle:hover {
    background-color: rgba(0,0,0,0.05);
}

.date-picker-popup {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    max-width: 320px;
    background: white;
    border: 1px solid var(--light-gray);
    border-radius: 8px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.15);
    z-index: 1000;
    margin-top: 5px;
    display: none;
}

.date-picker-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 8px 8px 0 0;
}

.date-picker-header button {
    background: none;
    border: none;
    color: white;
    font-size: 1rem;
    cursor: pointer;
    padding: 5px 8px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.date-picker-header button:hover {
    background-color: rgba(255,255,255,0.2);
}

.current-month-year {
    font-weight: 600;
    font-size: 1.1rem;
    text-align: center;
    flex-grow: 1;
}

.date-picker-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    padding: 10px 5px;
    background-color: #f8f9fa;
    border-bottom: 1px solid var(--light-gray);
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-color);
}

.date-picker-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    padding: 10px 5px;
}

.date-picker-days div {
    padding: 8px;
    text-align: center;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.date-picker-days div:hover {
    background-color: #f0f0f0;
}

.date-picker-days div.selected {
    background-color: var(--primary-color);
    color: white;
}

.date-picker-footer {
    display: flex;
    justify-content: space-between;
    padding: 15px;
    border-top: 1px solid var(--light-gray);
}

.date-picker-footer button {
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.today-btn {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.today-btn:hover {
    background-color: var(--primary-color);
    color: white;
}

.confirm-date-btn {
    background: var(--primary-color);
    color: white;
    border: none;
}

.confirm-date-btn:hover {
    background-color: var(--primary-color-dark);
}

/* Time Select */
.select-with-icon {
    appearance: none;
    background-image: url('data:image/svg+xml;charset=UTF-8,%3csvg xmlns=\'http://www.w3.org/2000/svg\' viewBox=\'0 0 24 24\' fill=\'none\' stroke=\'%234a90e2\' stroke-width=\'2\' stroke-linecap=\'round\' stroke-linejoin=\'round\'%3e%3cpolyline points=\'6 9 12 15 18 9\'%3e%3c/polyline%3e%3c/svg%3e');
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
}

.time-info {
    margin-top: 8px;
    color: var(--light-text);
}

.time-info small {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Sidebar Cards */
.info-card, .faq-card {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.1);
}

.info-card {
    margin-bottom: 30px;
}

.card-title {
    color: var(--secondary-color);
    margin-bottom: 20px;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-title i {
    color: var(--primary-color);
}

.hours-list .hour-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
}

.hours-list .hour-item:last-child {
    border-bottom: none;
}

.hours-list .closed {
    color: var(--primary-color);
    font-weight: 600;
}

.lunch-break {
    padding: 15px 0;
    text-align: center;
    background-color: #f8f9fa;
    margin-top: 15px;
    border-radius: 5px;
}

.faq-item {
    margin-bottom: 15px;
}

.faq-item h4 {
    font-size: 1.1rem;
    margin-bottom: 5px;
    color: var(--dark-color);
}

.faq-item p {
    font-size: 0.9rem;
    color: var(--text-color);
    line-height: 1.5;
    margin: 0;
}

/* BUTTON */
.btn-block {
    width: 100%;
    padding: 15px;
    font-size: 1.1rem;
}

/* ===== RESPONSIVE MOBILE ===== */
@media (max-width: 768px) {
    .contact-content-grid {
        grid-template-columns: 1fr; /* Una sola columna en móvil */
        gap: 30px;
    }

    .dual-fields {
        grid-template-columns: 1fr; /* Apila los campos en móvil */
        gap: 15px;
    }

    .form-card,
    .info-card,
    .faq-card {
        padding: 25px;
    }

    .form-title {
        font-size: 1.5rem;
    }

    .card-title {
        font-size: 1.3rem;
    }

    /* Evitar que el datepicker se salga de pantalla */
    .date-picker-popup {
        max-width: 100% !important;
        left: 0 !important;
        right: 0;
        margin-left: auto;
        margin-right: auto;
    }
}

/* Solo el estilo para centrar los títulos y bajarlos más */
.hero-title {
    text-align: center;
    margin-top: 20px; /* Ajusta este valor según cuánto quieras bajar el texto */
}

/* Opcional: Si quieres que todo el contenido del hero-text-container baje */
.hero-text-container {
    padding-top: 8px; /* Ajusta este valor si quieres bajar todo el contenido */
}


.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}



.patient-testimonials-section {
    padding: 80px 0;
    background-color: #f8f9fa;
}
.patient-testimonials-section .section-header h2 span {
    color: var(--primary-color);
}
.testimonials-carousel {
    position: relative;
    overflow: hidden;
    margin: 40px 0;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}
.testimonial-slide {
    display: none;
    padding: 40px;
    background: white;
    animation: fadeIn 0.8s ease-in-out;
}
.testimonial-slide.active {
    display: block;
}
.testimonial-content {
    display: flex;
    align-items: center;
    gap: 40px;
}
.testimonial-image img {
    width: 300px;
    height: 300px;
    object-fit: cover;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border: 3px solid #fff;
}
.testimonial-info {
    flex: 1;
}
.testimonial-info h3 {
    color: var(--primary-color);
    font-size: 1.8rem;
    margin-bottom: 15px;
    font-weight: 700;
}
.testimonial-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    font-size: 0.95rem;
    color: #666;
}
.testimonial-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}
.testimonial-meta i {
    color: var(--primary-color);
}
.testimonial-info blockquote {
    font-style: italic;
    font-size: 1.1rem;
    line-height: 1.7;
    color: #333;
    margin: 25px 0;
    padding: 20px;
    background: #f1f8ff;
    border-left: 4px solid var(--primary-color);
    border-radius: 0 8px 8px 0;
}
.testimonial-result {
    background: #e8f5e9;
    padding: 15px;
    border-radius: 8px;
    font-weight: 600;
    color: #2e7d32;
    margin-top: 20px;
}
.testimonials-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 30px;
}
.testimonial-prev,
.testimonial-next {
    background: var(--primary-color);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}
.testimonial-prev:hover,
.testimonial-next:hover {
    background: #0056b3;
    transform: scale(1.05);
}
.testimonials-dots {
    display: flex;
    gap: 10px;
}
.testimonial-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ccc;
    cursor: pointer;
    transition: all 0.3s ease;
}
.testimonial-dot.active {
    background: var(--primary-color);
    transform: scale(1.3);
}
/* Responsive */
@media (max-width: 992px) {
    .testimonial-content {
        flex-direction: column;
        text-align: center;
    }
    .testimonial-image img {
        width: 250px;
        height: 250px;
    }
    .testimonial-meta {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
}
@media (max-width: 768px) {
    .testimonial-slide {
        padding: 20px;
    }
    .testimonial-info blockquote {
        font-size: 1rem;
        padding: 15px;
    }
}
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}


