/* --- CONFIGURACIÓN DE COLORES Y VARIABLES --- */
:root {
    --navy-dark: #0a1120;
    --navy-light: #18253a;
    --gold-start: #bf953f;
    --gold-end: #fcf6ba;
    --gold-solid: #c5a059;
    --white: #ffffff;
    --off-white: #f8f9fa;
    --text-gray: #4b5563;
    --shadow-soft: 0 20px 40px -10px rgba(0, 0, 0, 0.08);
    --glass: rgba(255, 255, 255, 0.95);
}

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

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--off-white);
    color: var(--text-gray);
    overflow-x: hidden;
    overflow-y: auto;
    max-width: 100vw;
    width: 100%;
    line-height: 1.7;
}

html {
    overflow-x: hidden;
    max-width: 100vw;
    width: 100%;
}

* {
    max-width: 100%;
    box-sizing: border-box;
}

h1, h2, h3, h4 {
    font-family: 'Cinzel', serif;
    color: var(--navy-dark);
    font-weight: 700;
}

/* Texto con efecto degradado dorado - Optimizado para composición */
.text-gold-gradient {
    background: linear-gradient(to right, #bf953f, #d4af37, #fcf6ba, #bf953f);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    background-size: 200% auto;
    animation: shine 5s linear infinite;
    will-change: background-position;
    transform: translateZ(0);
}

@keyframes shine {
    to {
        background-position: 200% center;
    }
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* --- BOTONES MODERNOS --- */
.btn {
    display: inline-block;
    padding: 14px 35px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    transition: all 0.4s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-gold {
    background: linear-gradient(45deg, #bf953f, #e3c378);
    color: var(--navy-dark);
    box-shadow: 0 10px 20px rgba(191, 149, 63, 0.3);
    border: none;
}

.btn-gold:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 25px rgba(191, 149, 63, 0.4);
}

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

.btn-outline:hover {
    background: white;
    color: var(--navy-dark);
}

/* Desactivar efectos hover en botones específicos */
.btn-no-hover:hover {
    background: transparent !important;
    color: inherit !important;
    transform: none !important;
    box-shadow: none !important;
    border-color: inherit !important;
}

/* --- HEADER & NAV --- */

/* Forzar header en index.php a siempre tener estilo scrolled */
body.index-page header {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px) !important;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05) !important;
    padding: 12px 5% !important;
    height: 100px !important;
}

body.index-page header .logo-img {
    height: 85px !important;
}

body.index-page header nav ul li a {
    color: var(--navy-dark) !important;
}

body.index-page header .hamburger {
    color: var(--navy-dark) !important;
}

/* Ajustar hero en index.php para compensar header siempre visible */
body.index-page .hero {
    padding-top: 120px !important;
}

/* Prevenir overflow horizontal en index.php */
body.index-page {
    overflow-x: hidden !important;
    max-width: 100vw;
    width: 100%;
}

body.index-page section {
    overflow-x: hidden !important;
    max-width: 100% !important;
    width: 100% !important;
}

body.index-page .hero,
body.index-page .section-padding {
    overflow-x: hidden !important;
}

body.index-page .hero-content {
    padding: 20px 15px !important;
    max-width: 100%;
    box-sizing: border-box;
}

body.index-page .hero h1 {
    font-size: 2.8rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
    padding: 0 10px;
}

body.index-page .hero p {
    padding: 0 10px;
    word-wrap: break-word;
    font-size: 1rem !important;
}

/* Ajustar botones del hero en móvil index */
body.index-page .hero-buttons {
    padding: 0 15px;
    box-sizing: border-box;
}

body.index-page .hero-buttons .btn {
    max-width: 100%;
    word-break: break-word;
    white-space: normal;
}

/* Ajustar badge del hero en móvil */
body.index-page .badge {
    font-size: 0.7rem;
    padding: 6px 15px;
    max-width: 90%;
    word-wrap: break-word;
}

/* Ajustar scroll indicator del hero en móvil */
body.index-page .hero-scroll-indicator {
    padding: 0 15px;
}

body.index-page .hero-scroll-indicator span {
    max-width: 1px;
    height: 35px;
}

/* Asegurar que los botones no causen overflow */
.btn, .btn-gold, .btn-outline {
    max-width: 100%;
    box-sizing: border-box;
}

/* Prevenir overflow en todos los elementos */
img, video, iframe {
    max-width: 100%;
    height: auto;
}

header {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 15px 5%;
    z-index: 1000;
    transition: 0.4s;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 110px;
    box-sizing: border-box;
}

header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    padding: 12px 5%;
    height: 100px;
}

/* En páginas que NO son index.php, header siempre con fondo */
body:not(.index-page) header:not(.scrolled) {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

header.scrolled .logo-img {
    height: 85px;
}

.logo {
    display: flex;
    align-items: center;
    max-width: 350px;
}

.logo a {
    display: flex;
    align-items: center;
    width: 100%;
}

.logo-img {
    height: 95px;
    max-width: 100%;
    width: auto;
    object-fit: contain;
}

nav ul { display: flex; gap: 40px; }

nav ul li a {
    font-size: 0.9rem;
    color: rgba(255,255,255, 0.8);
    font-weight: 500;
    transition: color 0.3s ease;
}

/* Header sin scroll - textos blancos (solo en index.php) */
body.index-page header:not(.scrolled) nav ul li a {
    color: rgba(255,255,255, 0.8) !important;
}

/* Header con scroll - textos oscuros */
header.scrolled nav ul li a {
    color: var(--navy-dark) !important;
}

/* En páginas que NO son index.php, textos siempre oscuros */
body:not(.index-page) header:not(.scrolled) nav ul li a {
    color: var(--navy-dark) !important;
}

nav ul li a:hover { color: var(--gold-solid) !important; }

.hamburger {
    display: none;
    font-size: 1.5rem;
    color: white;
    cursor: pointer;
    transition: color 0.3s ease;
}

/* Hamburger en header sin scroll - blanco (solo en index.php) */
body.index-page header:not(.scrolled) .hamburger {
    color: white !important;
}

/* Hamburger en header con scroll - oscuro */
header.scrolled .hamburger {
    color: var(--navy-dark) !important;
}

/* En páginas que NO son index.php, hamburger siempre oscuro */
body:not(.index-page) header:not(.scrolled) .hamburger {
    color: var(--navy-dark) !important;
}

/* --- HERO SECTION --- */
.hero {
    height: 100vh;
    background: linear-gradient(rgba(10, 17, 32, 0.7), rgba(10, 17, 32, 0.6)),
                url('https://images.unsplash.com/photo-1505664194779-8beaceb93744?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100px;
    background: linear-gradient(to top, var(--off-white), transparent);
}

.hero-content {
    max-width: 900px;
    padding: 20px;
}

.badge {
    display: inline-block;
    padding: 8px 20px;
    border: 1px solid rgba(197, 160, 89, 0.5);
    border-radius: 30px;
    color: var(--gold-solid);
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 2px;
    margin-bottom: 20px;
    background: rgba(10, 17, 32, 0.5);
    backdrop-filter: blur(5px);
}

.hero h1 {
    font-size: 4.5rem;
    color: white;
    line-height: 1.1;
    margin-bottom: 25px;
}

.hero p {
    color: rgba(255,255,255, 0.9);
    font-size: 1.25rem;
    font-weight: 300;
    margin-bottom: 40px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    margin-top: 40px;
}

.hero-scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.8rem;
    animation: bounce 2s infinite;
}

.hero-scroll-indicator span {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, var(--gold-solid), transparent);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-10px); }
    60% { transform: translateX(-50%) translateY(-5px); }
}

/* --- SECCIONES GENERALES --- */
.section-padding { padding: 100px 5%; }

/* Lazy rendering para secciones below-the-fold */
.section-padding,
.stats-banner,
.team-grid,
.testimonials-grid,
.faq-container,
.contact-section,
.gallery-container {
    content-visibility: auto;
    contain-intrinsic-size: 500px;
}

.title-wrapper {
    text-align: center;
    margin-bottom: 70px;
}

.title-wrapper h2 {
    font-size: 2.8rem;
    margin-bottom: 15px;
}

.divider {
    height: 3px;
    width: 70px;
    background: var(--gold-solid);
    margin: 0 auto;
    border-radius: 2px;
}

/* --- SERVICIOS (MODERNO) --- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.service-card {
    background: white;
    padding: 40px 30px;
    border-radius: 20px;
    transition: all 0.4s ease;
    position: relative;
    border: 1px solid rgba(0,0,0,0.03);
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-soft);
    border-color: rgba(197, 160, 89, 0.3);
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--gold-solid);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.service-card:hover::before { transform: scaleX(1); }

.icon-box {
    width: 70px;
    height: 70px;
    background: rgba(197, 160, 89, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    transition: 0.3s;
}

.service-card:hover .icon-box {
    background: var(--gold-solid);
}

.icon-box i {
    font-size: 1.8rem;
    color: var(--gold-solid);
    transition: 0.3s;
}

.service-card:hover .icon-box i { color: white; }

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
}

.service-list li {
    font-size: 0.95rem;
    margin-bottom: 10px;
    color: #6b7280;
    display: flex;
    align-items: center;
}

.service-list li::before {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--gold-solid);
    margin-right: 10px;
    font-size: 0.8rem;
}

/* --- ESTADÍSTICAS / BANNER --- */
.stats-banner {
    background-color: var(--navy-dark);
    padding: 80px 5%;
    color: white;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    text-align: center;
}

.stat-item h3 {
    font-size: 3.5rem;
    color: var(--gold-solid);
    margin-bottom: 5px;
}

.stat-item p {
    font-size: 1.1rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    opacity: 0.8;
}

/* --- ABOUT SECTION --- */
.about-container {
    max-width: 1200px;
    margin: 0 auto;
}

.about-content {
    display: flex;
    gap: 60px;
    align-items: center;
    flex-wrap: wrap;
}

.about-text {
    flex: 1;
    min-width: 350px;
}

.about-image {
    flex: 1;
    min-width: 350px;
}

.image-wrapper {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
}

.image-wrapper img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s ease;
}

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

.image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(10, 17, 32, 0.9), transparent);
    padding: 30px;
    color: white;
}

.overlay-text h4 {
    font-size: 2rem;
    color: var(--gold-solid);
    margin-bottom: 5px;
}

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

.value-item {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.value-item i {
    font-size: 1.8rem;
    color: var(--gold-solid);
}

.value-item h4 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.value-item p {
    font-size: 0.9rem;
    color: #6b7280;
}

/* --- TEAM SECTION --- */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 50px;
    max-width: 1200px;
    margin: 0 auto;
}

.team-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: all 0.4s ease;
}

.team-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-soft);
}

.team-image {
    position: relative;
    height: 280px;
    overflow: hidden;
}

.team-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    transition: transform 0.3s ease;
}

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

.team-social {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(197, 160, 89, 0.95), transparent);
    padding: 20px;
    display: flex;
    justify-content: center;
    gap: 15px;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.team-card:hover .team-social {
    transform: translateY(0);
}

.team-social a {
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--navy-dark);
    transition: all 0.3s ease;
}

.team-social a:hover {
    background: var(--gold-solid);
    color: white;
    transform: scale(1.1);
}

.team-info {
    padding: 25px;
    text-align: center;
}

.team-info h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.3rem;
    margin-bottom: 5px;
    color: var(--navy-dark);
}

.team-role {
    color: var(--gold-solid);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 15px;
    display: block;
}

.team-desc {
    font-size: 0.9rem;
    color: #6b7280;
    line-height: 1.6;
}

.team-expertise {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

.expertise-tag {
    background: var(--off-white);
    color: var(--navy-dark);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

/* --- TESTIMONIALS --- */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.testimonial-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 35px;
    transition: all 0.4s ease;
}

.testimonial-card:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-5px);
}

.testimonial-stars {
    color: var(--gold-solid);
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.testimonial-text {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.8;
    margin-bottom: 25px;
    font-style: italic;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.author-avatar {
    width: 50px;
    height: 50px;
    background: var(--gold-solid);
    color: var(--navy-dark);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1rem;
}

.testimonial-author h4 {
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    color: white;
    margin-bottom: 3px;
}

.testimonial-author p {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
}

/* --- FAQ SECTION --- */
.faq-container {
    max-width: 900px;
    margin: 0 auto;
}

.faq-item {
    background: white;
    border-radius: 15px;
    margin-bottom: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}

.faq-question {
    padding: 25px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: background 0.3s;
}

.faq-question:hover {
    background: var(--off-white);
}

.faq-question h4 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.1rem;
    color: var(--navy-dark);
    font-weight: 600;
}

.faq-question i {
    color: var(--gold-solid);
    font-size: 0.9rem;
    transition: transform 0.3s ease;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    padding: 0 30px;
}

.faq-answer p {
    padding: 0 0 25px 0;
    color: #6b7280;
    line-height: 1.8;
}

.faq-item.active .faq-answer {
    max-height: 500px;
}

/* --- CONTACTO --- */
.contact-section {
    display: flex;
    flex-wrap: wrap;
    background: white;
}

.contact-info {
    flex: 1;
    padding: 80px 5%;
    min-width: 400px;
}

.contact-map {
    flex: 1;
    min-width: 400px;
    min-height: 800px !important;
    height: 800px !important;
}

.info-card {
    display: flex;
    align-items: flex-start;
    margin-bottom: 40px;
    padding: 20px;
    border-radius: 15px;
    transition: 0.3s;
}

.info-card:hover {
    background: var(--off-white);
}

.info-icon {
    font-size: 1.5rem;
    color: var(--gold-solid);
    margin-right: 20px;
    margin-top: 5px;
}

.info-content h4 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.1rem;
    margin-bottom: 5px;
}

.contact-cta {
    margin-top: 20px;
}

/* --- FOOTER --- */
footer {
    background-color: var(--navy-dark);
    color: white;
    text-align: center;
    padding: 50px 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-logo {
    font-family: 'Cinzel', serif;
    font-size: 1.5rem;
    margin-bottom: 20px;
    display: inline-block;
}

.social-links { margin-top: 20px; }
.social-links a {
    color: rgba(255,255,255,0.6);
    margin: 0 10px;
    font-size: 1.2rem;
}
.social-links a:hover { color: var(--gold-solid); }

/* --- WHATSAPP FLOTANTE (ANIMADO) - Optimizado para composición --- */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #25d366;
    color: white;
    width: 65px;
    height: 65px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    box-shadow: 0 10px 20px rgba(37, 211, 102, 0.4);
    z-index: 2000;
    animation: pulse 2s infinite;
    will-change: transform;
    transform: translateZ(0);
}

@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7); }
    70% { box-shadow: 0 0 0 15px rgba(37, 211, 102, 0); }
    100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); }
}

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    html, body {
        overflow-x: hidden;
        width: 100%;
        max-width: 100vw;
    }

    * {
        max-width: 100%;
        box-sizing: border-box;
    }

    .hero h1 { font-size: 2.8rem; }
    nav {
        position: absolute;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: white;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: 0.4s;
        box-shadow: -5px 0 20px rgba(0,0,0,0.1);
        max-width: 80vw;
    }
    nav.active { right: 0; }
    nav ul { flex-direction: column; text-align: center; gap: 25px; }

    /* Textos del nav en móvil - siempre oscuros */
    nav ul li a {
        color: var(--navy-dark) !important;
        font-size: 1.2rem;
    }

    /* Hamburger en móvil - siempre negro */
    .hamburger {
        display: block;
        z-index: 1001;
        color: var(--navy-dark) !important;
    }

    /* Cuando el menú está activo, mantener el color oscuro */
    .hamburger.active {
        color: var(--navy-dark) !important;
    }

    .contact-section { flex-direction: column; }
    .contact-info, .contact-map {
        min-width: 100%;
        width: 100%;
        flex: none;
    }
    .contact-info { padding: 50px 5%; }
    .contact-map { min-height: 600px !important; height: 600px !important; }

    .about-content { flex-direction: column; }
    .about-text, .about-image { min-width: 100%; width: 100%; }

    .title-wrapper h2 { font-size: 2rem; }
    .stats-banner { padding: 50px 5%; grid-template-columns: 1fr; gap: 30px; }
    .stat-item h3 { font-size: 2.5rem; }

    /* Ajustar botones para móvil */
    .btn {
        width: auto;
        max-width: 100%;
        padding: 12px 25px;
        font-size: 0.85rem;
        word-break: break-word;
        white-space: normal;
    }

    /* Ajustar secciones con padding */
    .section-padding { padding: 60px 5%; }

    /* Prevenir overflow en hero del index */
    .hero {
        padding: 0 !important;
        overflow: hidden;
    }

    .hero-content {
        padding: 15px !important;
        max-width: 100% !important;
    }

    .hero h1 {
        font-size: 2.2rem !important;
        word-wrap: break-word;
        padding: 0 5px;
    }

    .hero p {
        font-size: 1rem !important;
        padding: 0 5px;
    }

    .hero-buttons {
        flex-direction: column;
        width: 100%;
        max-width: 100%;
        padding: 0 5px;
        gap: 15px !important;
    }

    .hero-buttons .btn {
        width: 100% !important;
        max-width: 100% !important;
        padding: 12px 20px !important;
        font-size: 0.85rem !important;
    }

    /* Ajustar grids */
    .services-grid,
    .team-grid,
    .testimonials-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    /* Ajustar FAQs */
    .faq-container {
        padding: 0 10px;
        width: 100%;
    }
    .faq-question { padding: 20px; }
    .faq-answer { padding: 0 20px; }

    /* Ajustar logo en header */
    .logo-img {
        height: 80px;
        max-width: 180px;
        width: auto;
    }

    /* Ajustar header para móvil - siempre blanco para legibilidad */
    header {
        padding: 15px 5%;
        height: 90px;
        background: rgba(255, 255, 255, 0.95) !important;
        backdrop-filter: blur(10px) !important;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1) !important;
    }

    /* Asegurar que en index.php móvil, el header también sea blanco desde el inicio */
    body.index-page header {
        background: rgba(255, 255, 255, 0.95) !important;
    }

    /* Forzar hamburguesa negro en móvil en todas las páginas */
    .hamburger {
        color: var(--navy-dark) !important;
    }

    /* Forzar textos del nav negro en móvil en todas las páginas */
    nav ul li a {
        color: var(--navy-dark) !important;
    }

    header.scrolled {
        padding: 12px 5%;
        height: 85px;
    }

    .logo {
        max-width: 70%;
    }

    /* Asegurar que el nav móvil esté por encima */
    nav {
        z-index: 999;
    }

    /* En móvil, textos del nav siempre oscuros */
    nav ul li a {
        color: var(--navy-dark) !important;
        font-size: 1.2rem;
    }

    /* Evitar overflow en imágenes */
    img {
        max-width: 100%;
        height: auto;
    }

    /* Prevenir overflow de texto largo */
    h1, h2, h3, h4, p, span, div, a {
        overflow-wrap: break-word;
        word-wrap: break-word;
        -webkit-hyphens: auto;
        -ms-hyphens: auto;
        hyphens: auto;
    }

    /* CTA buttons container */
    .cta-buttons {
        flex-direction: column;
        width: 100%;
        gap: 15px;
    }
    .cta-buttons .btn {
        width: 100%;
        text-align: center;
        padding: 14px 20px;
    }

    /* Ajustes específicos para elementos con botones inline */
    a.btn[style*="background-color: black"],
    a.btn[style*="border-color"] {
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* Ajustes para contenedores CTA */
    .cta-container,
    .cta-container-dark {
        padding: 40px 20px !important;
        margin: 0 auto;
        max-width: 100%;
        box-sizing: border-box;
    }

    .cta-container h2,
    .cta-container-dark h2 {
        font-size: 1.5rem !important;
        word-wrap: break-word;
    }

    .cta-container p,
    .cta-container-dark p {
        font-size: 0.95rem !important;
        padding: 0 10px;
    }

    /* Ajustes para page headers */
    .page-header-section {
        padding: 80px 20px 50px !important;
        width: 100%;
        box-sizing: border-box;
    }

    .header-content {
        width: 100%;
        max-width: 100%;
        padding: 0 10px;
        box-sizing: border-box;
    }

    .header-content h1 {
        font-size: 2rem !important;
        word-wrap: break-word;
        line-height: 1.3 !important;
    }

    .header-content p {
        font-size: 1rem !important;
        padding: 0 5px;
        word-wrap: break-word;
    }

    /* Ajustes para grids con min-width problemático */
    .success-cases,
    .services-grid,
    .team-grid,
    .testimonials-grid {
        grid-template-columns: 1fr !important;
        gap: 20px;
        padding: 0 10px;
    }

    .success-case,
    .service-card,
    .team-card,
    .testimonial-card {
        padding: 25px 20px !important;
        min-width: 100% !important;
        width: 100% !important;
        box-sizing: border-box;
    }

    /* Ajustes finales para prevenir cualquier overflow */
    .service-list li {
        font-size: 0.9rem;
        word-wrap: break-word;
    }

    .info-card {
        padding: 15px !important;
        margin-bottom: 20px;
    }

    .info-icon {
        font-size: 1.3rem;
        margin-right: 15px;
    }

    /* Ajustar iframes y mapas */
    iframe {
        max-width: 100%;
        width: 100%;
    }

    /* Prevenir overflow en elementos con posición absoluta */
    [style*="position: absolute"] {
        max-width: 100%;
    }

    /* === ASEGURAR COLORES CORRECTOS EN MÓVIL (reglas finales) === */
    /* Forzar hamburguesa negro en móvil - sobrescribe cualquier regla anterior */
    .hamburger {
        color: var(--navy-dark) !important;
    }

    /* Desactivar background-attachment fixed en móvil */
    .hero {
        background-attachment: scroll !important;
    }
}

/* Extra pequeño: teléfonos muy pequeños */
@media (max-width: 480px) {
    body.index-page .hero h1 {
        font-size: 2rem !important;
        padding: 0 5px;
    }

    body.index-page .hero p {
        font-size: 0.9rem !important;
        padding: 0 5px;
    }

    body.index-page .hero-content {
        padding: 10px 5px !important;
    }

    .hero h1 { font-size: 2.2rem; }
    .section-padding { padding: 40px 5%; }
    .btn { font-size: 0.8rem; padding: 10px 20px; }
    .title-wrapper h2 { font-size: 1.6rem; }

    .logo-img {
        height: 70px;
        max-width: 160px;
    }

    header {
        padding: 12px 4%;
        height: 65px;
    }

    .logo {
        max-width: 55%;
    }

    .hamburger {
        font-size: 1.3rem;
    }

    /* Asegurar colores correctos en pantallas muy pequeñas también */
    .hamburger {
        color: var(--navy-dark) !important;
    }

    nav ul li a {
        color: var(--navy-dark) !important;
    }
}

/* --- BLOG STYLES --- */
.blog-page {
    padding-top: 80px;
}

.page-header-section {
    background: linear-gradient(rgba(10, 17, 32, 0.85), rgba(10, 17, 32, 0.75)),
                url('https://images.unsplash.com/photo-1481627834876-b7833e8f5570?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    padding: 120px 5% 80px;
    text-align: center;
    color: white;
}

.header-content h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    color: white;
}

.header-content p {
    font-size: 1.2rem;
    opacity: 0.9;
}

.blog-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 5%;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.blog-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
}

.blog-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-soft);
}

.blog-image-wrapper {
    position: relative;
    width: 100%;
    padding-top: 55%;
    overflow: hidden;
}

.blog-image-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.blog-card:hover .blog-image-wrapper img {
    transform: scale(1.1);
}

.blog-category {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--gold-solid);
    color: var(--navy-dark);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

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

.blog-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 0.85rem;
    color: #888;
}

.blog-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.blog-meta i {
    color: var(--gold-solid);
}

.blog-content h3 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.2rem;
    margin-bottom: 12px;
    line-height: 1.4;
    color: var(--navy-dark);
}

.blog-content h3 a {
    color: inherit;
    transition: color 0.3s;
}

.blog-content h3 a:hover {
    color: var(--gold-solid);
}

.blog-content p {
    color: #6b7280;
    line-height: 1.7;
    margin-bottom: 15px;
    font-size: 0.95rem;
    flex: 1;
}

.blog-read-more {
    color: var(--gold-solid);
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
}

.blog-read-more:hover {
    color: var(--navy-dark);
    gap: 12px;
}

/* --- BLOG POST PAGE STYLES --- */
.blog-post-page {
    padding-top: 80px;
}

.blog-post-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 5%;
}

.blog-post-header {
    background: linear-gradient(135deg, var(--navy-dark) 0%, var(--navy-light) 100%);
    padding: 80px 5% 60px;
    text-align: center;
    color: white;
}

.blog-post-category {
    display: inline-block;
    background: var(--gold-solid);
    color: var(--navy-dark);
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.blog-post-header h1 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: white;
    line-height: 1.3;
}

.blog-post-meta {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    font-size: 0.9rem;
    opacity: 0.9;
}

.blog-post-meta span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.blog-post-featured-image {
    width: 100%;
    max-height: 500px;
    overflow: hidden;
}

.blog-post-featured-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.blog-post-content {
    background: white;
    padding: 60px 0;
}

.blog-post-body {
    color: #374151;
    line-height: 1.9;
}

.blog-intro {
    font-size: 1.15rem;
    font-weight: 400;
    color: #4b5563;
    background: var(--off-white);
    padding: 25px;
    border-left: 4px solid var(--gold-solid);
    border-radius: 8px;
    margin-bottom: 40px;
}

.blog-post-body h2 {
    font-size: 1.8rem;
    margin: 50px 0 20px;
    color: var(--navy-dark);
    padding-bottom: 10px;
    border-bottom: 2px solid var(--gold-solid);
}

.blog-post-body h3 {
    font-size: 1.4rem;
    margin: 35px 0 15px;
    color: var(--navy-dark);
}

.blog-post-body p {
    margin-bottom: 20px;
}

.blog-post-body ul, .blog-post-body ol {
    margin: 20px 0 20px 30px;
}

.blog-post-body li {
    margin-bottom: 12px;
    line-height: 1.7;
}

.blog-table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.blog-table th, .blog-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
}

.blog-table th {
    background: var(--navy-dark);
    color: white;
    font-weight: 600;
}

.blog-table tr:hover {
    background: var(--off-white);
}

.blog-conclusion {
    background: linear-gradient(135deg, rgba(197, 160, 89, 0.1) 0%, rgba(197, 160, 89, 0.05) 100%);
    padding: 30px;
    border-radius: 12px;
    border-left: 4px solid var(--gold-solid);
    margin-top: 40px;
}

.author-box {
    display: flex;
    gap: 25px;
    background: var(--off-white);
    padding: 30px;
    border-radius: 15px;
    margin: 60px 0;
    align-items: flex-start;
}

.author-box img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--gold-solid);
}

.author-info h4 {
    font-size: 1.3rem;
    margin-bottom: 5px;
    color: var(--navy-dark);
}

.author-role {
    color: var(--gold-solid);
    font-weight: 600;
    margin-bottom: 10px !important;
}

.related-posts {
    margin-top: 60px;
}

.related-posts h3 {
    font-size: 1.5rem;
    margin-bottom: 25px;
    color: var(--navy-dark);
}

.related-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.related-post-card {
    display: block;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    transition: all 0.3s;
}

.related-post-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.related-post-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
}

.related-post-card h4 {
    padding: 15px;
    font-size: 1rem;
    color: var(--navy-dark);
    margin: 0;
}

/* --- ESTILOS PARA BLOG INDIVIDUAL (SINGLE) --- */
.blog-single-page {
    width: 100%;
    overflow-x: hidden;
}

.blog-single-container {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.blog-article {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.blog-article-content {
    padding: 40px;
    font-size: 1.05rem;
    line-height: 1.8;
    color: #333;
}

.blog-article-content p {
    margin-bottom: 20px;
}

.blog-article-content h2 {
    font-family: 'Cinzel', serif;
    color: var(--navy-dark);
    font-size: 1.6rem;
    margin: 35px 0 15px;
    font-weight: 700;
}

.blog-article-content h3 {
    font-family: 'Cinzel', serif;
    color: var(--navy-dark);
    font-size: 1.3rem;
    margin: 25px 0 12px;
    font-weight: 600;
}

.blog-article-content ul, 
.blog-article-content ol {
    margin: 15px 0 20px 25px;
}

.blog-article-content li {
    margin-bottom: 10px;
    line-height: 1.7;
}

.blog-article-content strong {
    color: var(--navy-dark);
}

.blog-meta-header {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 15px;
    font-size: 0.9rem;
    color: rgba(255,255,255,0.8);
}

.blog-meta-header span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.blog-meta-header i {
    color: var(--gold-solid);
}

/* Sidebar del Blog */
.blog-sidebar {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.sidebar-widget {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
}

.sidebar-widget h3 {
    font-family: 'Cinzel', serif;
    color: var(--navy-dark);
    font-size: 1.1rem;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--gold-solid);
}

.author-widget {
    text-align: center;
}

.author-photo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 15px;
    border: 3px solid var(--gold-solid);
}

.author-widget h3 {
    border-bottom: none;
    padding-bottom: 0;
    font-size: 1rem;
}

.author-widget p {
    font-size: 0.85rem;
    color: #666;
    margin: 10px 0 15px;
    line-height: 1.5;
}

.categories-widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.categories-widget li {
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.categories-widget li:last-child {
    border-bottom: none;
}

.categories-widget a {
    color: var(--text-gray);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s;
    display: flex;
    align-items: center;
    gap: 8px;
}

.categories-widget a::before {
    content: "›";
    color: var(--gold-solid);
    font-weight: bold;
    font-size: 1.2rem;
}

.categories-widget a:hover {
    color: var(--gold-solid);
}

.contact-widget p {
    font-size: 0.85rem;
    margin-bottom: 10px;
    color: #555;
    display: flex;
    align-items: center;
    gap: 8px;
}

.contact-widget i {
    color: var(--gold-solid);
    width: 16px;
}

/* CTA Box en Blog */
.blog-cta-box {
    background: linear-gradient(135deg, var(--navy-dark) 0%, var(--navy-light) 100%);

    padding: 40px;
    border-radius: 15px;
    text-align: center;
    margin-top: 60px;
}

.blog-cta-box h3 {
    color: white;
    margin-bottom: 15px;
}

.blog-cta-box p {
    color: rgba(255,255,255,0.9);
    margin-bottom: 25px;
}

.blog-cta-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .header-content h1 {
        font-size: 2rem;
    }

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

    .blog-card:hover {
        transform: translateY(-5px);
    }

    .blog-content h3 {
        font-size: 1.1rem;
    }

    .blog-post-header h1 {
        font-size: 1.8rem;
    }

    .blog-post-meta {
        flex-direction: column;
        gap: 10px;
    }

    .author-box {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }

    .blog-post-body h2 {
        font-size: 1.5rem;
    }

    .blog-post-body h3 {
        font-size: 1.2rem;
    }

    .blog-intro {
        padding: 20px;
    }

    .blog-cta-buttons {
        flex-direction: column;
    }

    .blog-cta-buttons .btn {
        width: 100%;
    }

    /* Responsive para Blog Single */
    .blog-single-container {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 0 15px;
    }

    .blog-article-content {
        padding: 25px 20px;
        font-size: 1rem;
    }

    .blog-article-content h2 {
        font-size: 1.3rem;
    }

    .blog-article-content h3 {
        font-size: 1.1rem;
    }

    .blog-sidebar {
        order: -1;
    }

    .sidebar-widget {
        padding: 20px;
    }

    .blog-cta-box {
        padding: 30px 20px;
        margin-top: 30px;
    }

    .blog-meta-header {
        font-size: 0.8rem;
        gap: 12px;
    }

    .author-photo {
        width: 90px;
        height: 90px;
    }

    .related-posts-grid {
        grid-template-columns: 1fr;
        padding: 0 15px;
    }

    .related-post-card h3 {
        font-size: 0.95rem;
    }
}


