/* --- Global Styles & Variables --- */
:root {
    --font-heading: 'DM Serif Display', serif;
    --font-body: 'DM Sans', sans-serif;

    /* Nueva paleta de colores */
    --azul-principal: #0404fc;
    --azul-claro: #999df4;
    --azul-oscuro: #050593;
    --terracota: #a05c58;
    --gris-azulado: #b1b9cb;
    --rojo-cta: #E63946; /* Rojo para llamadas a la acción */
    --blanco: #FFFFFF;
    --negro: #000000;
}

html {
    scroll-behavior: smooth;
}

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

body {
    font-family: var(--font-body);
    color: var(--azul-oscuro);
    background-color: var(--blanco);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 40px;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 400;
    line-height: 1.2;
}

h1 { font-size: 3rem; }
h2 { font-size: 2rem; margin-bottom: 1.5rem; text-align: center; }

/* --- Buttons --- */
.btn {
    display: inline-block;
    padding: 12px 24px;
    font-size: 1rem;
    font-weight: 500;
    border: 1px solid;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-light {
    color: var(--blanco);
    border-color: var(--blanco);
}
.btn-light:hover {
    background-color: var(--blanco);
    color: var(--azul-oscuro);
}

.btn-dark {
    color: var(--azul-oscuro);
    border-color: var(--azul-oscuro);
}
.btn-dark:hover {
    background-color: var(--azul-oscuro);
    color: var(--blanco);
}

.btn-accent {
    background-color: var(--rojo-cta);
    color: var(--blanco);
    border-color: var(--rojo-cta);
}
.btn-accent:hover {
    background-color: var(--blanco);
    color: var(--rojo-cta);
    border-color: var(--rojo-cta);
}

/* --- Header --- */
#main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 40px;
    z-index: 1000;
    color: var(--blanco);
    transition: background-color 0.3s ease, color 0.3s ease, backdrop-filter 0.3s ease;
}

#main-header.scrolled {
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    color: var(--azul-oscuro);
    border-bottom: 1px solid var(--azul-claro);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1600px;
    margin: 0 auto;
}

.header-left .logo {
    /* Styles for the logo container can be added here if needed */
}

.header-left .logo img {
    width: 50px;
    border-radius: 50%;
}

.header-center {
    display: flex;
    gap: 30px;
}

.header-center a, .header-right a {
    font-size: 1rem;
    font-weight: 500;
}

.header-right {
    display: flex;
    gap: 20px;
    align-items: center;
}

/* --- Hero Section --- */
.hero {
    height: 85vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--blanco);
    overflow: hidden; /* Ensure image doesn't overflow */
}

.hero picture,
.hero .hero-background-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Cover the entire area */
    z-index: -2; /* Place behind content and overlay */
}

.hero .hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(rgba(5, 5, 147, 0.6), rgba(0, 0, 0, 0.3));
    z-index: -1; /* Place behind content, above image */
}

.hero-content {
    max-width: 1600px; /* Set max-width to match container */
    padding: 0 40px; /* Match container padding */
    position: relative;
    z-index: 1;
    text-align: center;
    width: 100%; /* Ensure it takes full width within the flex container */
}

.hero-content h1 {
    margin-bottom: 1rem;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* --- As Seen On Section --- */
@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.as-seen-on {
    overflow: hidden;
    background-color: var(--gris-azulado);
}

.logos-slider {
    display: block;
}

.as-seen-on h2 {
    font-size: 1.1rem;
    font-weight: 400;
    color: var(--azul-oscuro);
    margin-bottom: 2rem;
}

.as-seen-on .logos {
    display: flex;
    width: max-content;
    align-items: center;
    animation: scroll 40s linear infinite;
}

.as-seen-on .logos img {
    height: 100px;
    width: auto;
    max-width: 150px;
    object-fit: contain;
    opacity: 0.6;
    filter: grayscale(100%);
    transition: all 0.3s ease;
    margin: 0 40px;
}

.as-seen-on .logos img:hover {
    opacity: 1;
    filter: grayscale(0%);
}

/* --- Content Sections --- */
.content-section {
  padding-bottom: 30px;
    padding-top: 30px;
}

.full-screen-section {
    display: flex;
    align-items: center;
    padding: 0;
}

.container-flex {
    display: flex;
    align-items: center;
    gap: 60px;
    width: 100%;
}

.image-column, .text-column {
    flex: 1;
}

.image-column img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.text-column {
    padding: 0 4%;
}

.text-column h2 {
    text-align: left;
    margin-bottom: 1rem;
}

.text-column p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.text-image {
    background-color: var(--blanco);
}

.image-text {
    background-color: var(--azul-oscuro);
    color: var(--blanco);
}

.image-text .container-flex {
    flex-direction: row-reverse;
}

/* --- Testimonials Section --- */
#testimonials {
    background-color: var(--azul-claro);
    color: var(--azul-oscuro);
}

#testimonials h2 {
    color: var(--azul-oscuro);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 3rem;
}

.testimonial-card {
    background-color: var(--blanco);
    color: var(--azul-oscuro);
    padding: 30px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
}

.testimonial-rating {
    margin-bottom: 1rem;
    color: var(--azul-principal);
    font-size: 1.2rem;
}

.testimonial-quote {
    flex-grow: 1;
    margin-bottom: 1rem;
    font-style: italic;
}

.testimonial-author {
    font-weight: 500;
    text-align: right;
}

.testimonial-footer {
    text-align: center;
    margin-top: 3rem;
}

/* --- Footer --- */
footer {
    background-color: var(--azul-oscuro);
    padding-top: 30px;
    color: var(--blanco);
}

.footer-main {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--azul-claro);
}

.footer-column h4 {
    font-size: 1rem;
    margin-bottom: 1rem;
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li a {
    color: var(--blanco);
    line-height: 2;
    transition: color 0.2s;
}

.footer-column ul li a:hover {
    color: var(--rojo-cta);
}

.footer-bottom {
    padding-top: 40px;
    text-align: center;
    font-size: 0.9rem;
    color: var(--blanco);
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .container-flex {
        gap: 30px;
    }
}

@media (min-width: 1025px) {
    .hero {
        /* justify-content: flex-start; */
    }
    .hero-content {
        text-align: left;
    }
    .hero-content h1 {
        font-size: 4.5rem;
    }
    .hero-content p {
        font-size: 1.5rem;
    }
    .full-screen-section {
        height: 100vh; /* Changed from min-height */
    }
    .full-screen-section .container {
        max-width: none;
        padding: 0;
        height: 100%; /* Ensure container fills height */
    }
    .full-screen-section .container-flex {
        gap: 0;
        height: 100%; /* Ensure flex container fills height */
    }
    .full-screen-section .image-column,
    .full-screen-section .text-column {
        flex: 0 0 50%; /* Set flex-basis to 50% */
        height: 100%;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
    .full-screen-section .image-column img {
        width: 100%;
        height: 100%;

        object-fit: cover;
    }
    .text-column {
        padding: 0 8%;
    }
}

@media (max-width: 768px) {
    h1 { font-size: 2.2rem; }
    .container { padding: 0 20px; }
    
    .header-center { display: none; } /* Simplificación para móvil */
    #main-header { padding: 15px 20px; }

    .container-flex {
        flex-direction: column !important;
    }
    .text-column {
        text-align: center;
        padding: 40px 20px;
    }
    .text-column h2 {
        text-align: center;
    }
    .footer-main {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .as-seen-on .logos {
        gap: 30px;
    }
     .as-seen-on .logos img {
        height: 20px;
    }
    .footer-main {
        grid-template-columns: 1fr;
    }
    .footer-column {
        text-align: center;
    }
}

/* --- Map Section --- */
.map-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    background: #eee;
    margin-top: 2rem; /* Add some space above the map */
}

.map-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.map-section {
    background-color: var(--blanco);
}

/* --- WhatsApp Floating Button --- */
.whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background-color: var(--rojo-cta);
    border-radius: 50%;
    display: flex !important;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    transition: transform 0.3s ease;
}

.whatsapp-float:hover {
    transform: scale(1.1);
}

.whatsapp-float img {
    width: 35px;
    height: 35px;
    border-radius: 50%;
}