/* style.css */

:root {
    --color-primary-dark: #404040;
    --color-accent-yellow: #FFBE00;
    --color-white: #FFFFFF;
    --color-light-gray: #f4f4f4;
    --color-text-on-dark: #e0e0e0;
    --font-main: 'Montserrat', Arial, sans-serif;
    --container-padding: 50px 20px;
    --section-title-margin-bottom: 40px;
    /* VARIABLE PARA ALTURA DEL HEADER */
    --header-height: 100px; /* Ajusta este valor según la altura final de tu header */
}

/* Reseteo básico y fuentes */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth; /* Para el desplazamiento suave de los anclajes */
    /* AÑADIDO PARA EL DESPLAZAMIENTO DEL HEADER FIJO */
    scroll-padding-top: var(--header-height);
}

body {
    font-family: var(--font-main);
    line-height: 1.7;
    color: var(--color-primary-dark);
    background-color: var(--color-white);
    font-size: 16px; /* Base font size */
}

/* Contenedor principal para centrar contenido */
.container {
    width: 90%;
    max-width: 1100px;
    margin: 0 auto;
    padding: var(--container-padding);
}

/* Encabezados */
h1, h2, h3 {
    margin-bottom: 20px;
    line-height: 1.3;
    font-weight: 700;
}

h1 { font-size: 2.5em; }
h2 { font-size: 2em; }
h3 { font-size: 1.4em; }

p {
    margin-bottom: 15px;
}

a {
    color: var(--color-accent-yellow);
    text-decoration: none;
    transition: color 0.3s ease;
}
a:hover, a:focus {
    text-decoration: underline;
    color: #e6a900; /* Amarillo más oscuro al pasar el ratón */
}

img {
    max-width: 100%;
    height: auto;
    display: block; /* Evita espacio extra debajo de las imágenes */
}

/* Botón de Llamada a la Acción (CTA) */
.cta-button {
    display: inline-block;
    background-color: var(--color-accent-yellow);
    color: var(--color-primary-dark);
    padding: 15px 30px;
    text-decoration: none;
    font-weight: bold;
    border-radius: 5px;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    font-size: 1.1em;
    border: none;
    cursor: pointer;
    text-align: center;
}

.cta-button:hover, .cta-button:focus {
    background-color: #e6a900;
    transform: translateY(-2px);
    text-decoration: none;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Header */
.header {
    background-color: var(--color-primary-dark);
    color: var(--color-white);
    padding: 0; /* Quitamos padding vertical para controlar altura con height */
    height: var(--header-height); /* Altura fija para el header */
    display: flex; /* Para centrar verticalmente el contenido */
    align-items: center; /* Para centrar verticalmente el contenido */
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}
.header .header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%; /* Para que ocupe todo el ancho del header */
    padding-top: 0; /* Controlado por el height del header */
    padding-bottom: 0; /* Controlado por el height del header */
}
.header .logo-img {
    max-height: 50px; /* Ajustado para que quepa bien en el header */
    width: auto;
}
.header .main-nav ul {
    list-style: none;
    display: flex;
}
.header .main-nav ul li {
    margin-left: 25px;
}
.header .main-nav ul li a {
    color: var(--color-white);
    text-decoration: none;
    font-weight: 500;
    padding: 5px 0;
    position: relative;
}
.header .main-nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background-color: var(--color-accent-yellow);
    transition: width 0.3s ease;
}
.header .main-nav ul li a:hover::after,
.header .main-nav ul li a:focus::after {
    width: 100%;
}

.header .contact-info-header a {
    color: var(--color-white);
    font-size: 1em;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}
.header .contact-info-header .whatsapp-icon {
    width: 20px;
    height: 20px;
    filter: brightness(0) invert(1);
}
.header .contact-info-header a:hover {
    color: var(--color-accent-yellow);
    text-decoration: none;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
}
.hamburger,
.hamburger::before,
.hamburger::after {
    content: '';
    display: block;
    background-color: var(--color-white);
    height: 3px;
    width: 25px;
    border-radius: 3px;
    transition: transform 0.3s ease-in-out, background-color 0.3s ease-in-out;
}
.hamburger::before {
    transform: translateY(-8px);
}
.hamburger::after {
    transform: translateY(5px);
}
.nav-toggle.active .hamburger {
    background-color: transparent;
}
.nav-toggle.active .hamburger::before {
    transform: translateY(0px) rotate(45deg);
}
.nav-toggle.active .hamburger::after {
    transform: translateY(-3px) rotate(-45deg);
}


/* HERO SECTION CON FORMULARIO ARRIBA */
.hero-section-form-first {
    background-color: var(--color-primary-dark);
    color: var(--color-white);
    padding-top: 40px; /* Espacio inicial, el scroll-padding-top maneja el anclaje */
    padding-bottom: 60px;
}
.hero-form-first-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
}
.hero-form-content {
    text-align: center;
    max-width: 800px;
}
.hero-form-content h1 {
    color: var(--color-white);
    margin-bottom: 15px;
}
.hero-form-content .subtitle {
    font-size: 1.3em;
    color: var(--color-text-on-dark);
    margin-bottom: 20px;
}
.hero-form-wrapper {
    width: 100%;
    max-width: 650px;
    background-color: rgba(255, 255, 255, 0.08);
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}
.hero-form-wrapper h2 {
    color: var(--color-accent-yellow);
    text-align: center;
    margin-bottom: 10px;
    font-size: 1.8em;
}
.hero-form-wrapper .price-indicator {
    text-align: center;
    color: var(--color-text-on-dark);
    margin-bottom: 25px;
    font-size: 1.1em;
}
.hero-form label {
    color: var(--color-text-on-dark);
}
.hero-form input, .hero-form select, .hero-form textarea {
    background-color: #585858;
    border-color: #777;
    color: var(--color-white); /* Asegurar color del texto en inputs */
}
/* Estilo específico para el placeholder en inputs oscuros */
.hero-form input::placeholder,
.hero-form textarea::placeholder {
    color: #bbb; /* Un gris claro para el placeholder */
    opacity: 1; /* Asegurar que se vea en Firefox */
}

/* Ajuste específico para el input file y su texto small */
.file-upload-container {
    margin-bottom: 20px;
}
.hero-form input[type="file"] {
    display: block;
    width: 100%;
    margin-bottom: 5px;
    padding: 10px;
    background-color: #585858;
    color: var(--color-text-on-dark);
    border: 1px solid #777;
    border-radius: 5px;
}
.hero-form input[type="file"]::file-selector-button {
    background-color: var(--color-accent-yellow);
    color: var(--color-primary-dark);
    border: none;
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    margin-right: 10px;
    font-weight: bold;
}
.hero-form .file-upload-info {
    display: block;
    font-size: 0.8em;
    color: #ccc;
}


/* Secciones con fondo claro */
.light-section {
    background-color: var(--color-white);
    color: var(--color-primary-dark);
}
.light-section h2 {
    text-align: center;
    color: var(--color-primary-dark);
    margin-bottom: var(--section-title-margin-bottom);
}

/* Secciones con fondo oscuro */
.dark-section {
    background-color: var(--color-primary-dark);
    color: var(--color-white);
}
.dark-section h2 {
    text-align: center;
    color: var(--color-accent-yellow);
    margin-bottom: var(--section-title-margin-bottom);
}
.dark-section p, .dark-section li {
    color: var(--color-text-on-dark);
}


/* Estilo para items con iconos (Proceso) - Reutilizado por Normativa */
.process-grid, .normativa-grid { /* Unificado */
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}
.process-step, .normativa-item { /* Unificado */
    text-align: center;
    padding: 25px;
    background-color: var(--color-light-gray);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.process-step:hover, .normativa-item:hover { /* Unificado */
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
}
.dark-section .process-step, .dark-section .normativa-item { /* Si se usaran en dark-section */
     background-color: #505050;
}

.process-step .icon, .normativa-item .icon { /* Clase .icon para los SVG */
    width: 50px;
    height: 50px;
    margin: 0 auto 15px auto;
    fill: var(--color-accent-yellow);
}
.process-step h3, .normativa-item h3 {
    color: var(--color-primary-dark);
    font-size: 1.3em;
    margin-bottom: 10px;
}
 .dark-section .process-step h3, .dark-section .normativa-item h3 {
     color: var(--color-white);
 }
.normativa-item { /* Ajuste específico si es necesario para normativa-item que ya está en light-section */
    background-color: #ebebeb; /* Ligeramente diferente para distinguir si se desea */
}
.normativa-item .icon {
    width: 40px;
    height: 40px;
    margin-bottom: 10px;
}


/* SECCIÓN NUESTRO SERVICIO - ESTILO SIMPLIFICADO */
.price-section {
    text-align: center;
}
.benefits-list-simple {
    list-style: none;
    padding: 0;
    margin: 20px auto;
    max-width: 600px;
    text-align: left;
}
.benefits-list-simple li {
    margin-bottom: 12px;
    font-size: 1.1em;
    display: flex;
    align-items: flex-start;
}
.benefits-list-simple .tick-icon {
    color: var(--color-accent-yellow);
    margin-right: 12px;
    font-weight: bold;
    line-height: 1.3;
}
.price-section .price-intro {
    margin-top: 30px;
    font-size: 1.3em;
}
.price-section .price-tag {
    font-size: 3.5em;
    font-weight: bold;
    color: var(--color-accent-yellow);
    margin: 5px 0 10px 0;
}
.price-section .vat-note {
    font-size: 0.5em;
    font-weight: normal;
    vertical-align: super;
}
.price-section .price-detail {
    font-size: 1.1em;
    margin-bottom: 25px;
}


/* Formulario de Contacto (general, usado por el hero form) */
.contact-form {
    max-width: 600px;
    margin: 30px auto 0 auto;
}
.contact-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    /* Color definido en .hero-form label o .dark-section label si hay otro form */
}
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form input[type="tel"],
.contact-form input[type="file"], /* Añadido para consistencia */
.contact-form select, /* Añadido para el selector */
.contact-form textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 20px;
    border: 1px solid #666;
    border-radius: 5px;
    font-family: var(--font-main);
    font-size: 1em;
    /* background-color y color definidos en .hero-form */
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.contact-form input[type="text"]:focus,
.contact-form input[type="email"]:focus,
.contact-form input[type="tel"]:focus,
.contact-form input[type="file"]:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--color-accent-yellow);
    box-shadow: 0 0 0 3px rgba(255, 190, 0, 0.25); /* Sombra de foco más visible */
}
.contact-form textarea {
    min-height: 100px; /* Reducido un poco */
    resize: vertical;
}
.contact-form .form-group-checkbox {
    margin-bottom: 20px;
    display: flex;
    align-items: flex-start;
}
.contact-form input[type="checkbox"] {
    margin-right: 10px;
    margin-top: 5px;
    width: auto;
    accent-color: var(--color-accent-yellow);
}
.contact-form label.checkbox-label {
    font-weight: normal;
    font-size: 0.9em;
    /* Color definido en .hero-form */
}
.contact-form .form-submit-button {
    width: 100%;
}
.contact-intro { /* Usado en sección contacto-final */
    text-align:center;
    max-width: 700px;
    margin-left:auto;
    margin-right:auto;
    margin-bottom: 30px;
}
.direct-contact-info {
    text-align: center;
    margin-top: 40px;
}
.direct-contact-info p {
    margin-bottom: 8px;
}


/* Sección Quiénes Somos */
.quienes-somos-content {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    align-items: center;
}
.quienes-somos-text {
    flex: 1 1 60%;
    min-width: 300px;
}
.quienes-somos-image {
    flex: 1 1 35%;
    min-width: 250px;
    text-align: center;
}
.quienes-somos-image img {
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    max-width: 100%;
}

/* Sección Opiniones */
.subtitle-section {
    font-size: 1.1em;
    color: #666;
    margin-top: -15px;
    margin-bottom: 30px;
}
.dark-section .subtitle-section {
    color: var(--color-text-on-dark);
}
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}
.review-item {
    background-color: var(--color-white);
    border: 1px solid #e0e0e0;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
}
.review-stars {
    color: var(--color-accent-yellow);
    font-size: 1.5em;
    margin-bottom: 10px;
}
.review-text {
    font-style: italic;
    color: #555;
    margin-bottom: 15px;
    flex-grow: 1;
}
.review-author {
    font-weight: bold;
    color: var(--color-primary-dark);
    margin-top: auto;
}
.cta-button-outline {
    background-color: transparent;
    color: var(--color-primary-dark);
    border: 2px solid var(--color-accent-yellow);
}
.cta-button-outline:hover {
    background-color: var(--color-accent-yellow);
    color: var(--color-primary-dark);
}

/* Sección FAQ */
.faq-grid {
    display: grid;
    gap: 15px;
}
.faq-item summary {
    font-weight: bold;
    padding: 15px;
    background-color: #505050;
    color: var(--color-accent-yellow);
    cursor: pointer;
    border-radius: 5px;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background-color 0.3s ease;
}
.faq-item summary:hover {
    background-color: #585858;
}
.faq-item summary::-webkit-details-marker {
    display: none;
}
.faq-item summary::after {
    content: '+';
    font-size: 1.5em;
    transition: transform 0.3s ease;
}
.faq-item[open] summary::after {
    transform: rotate(45deg);
    content: '−';
}
.faq-item p {
    padding: 15px;
    background-color: #484848;
    border-radius: 0 0 5px 5px;
    margin-top: -5px;
    color: var(--color-text-on-dark);
}

/* Contacto Final Section */
.contact-final-section .contact-intro {
    color: var(--color-primary-dark);
    text-align: center;
}
.direct-contact-info-final {
    text-align: center;
    margin-top: 30px;
}
.direct-contact-info-final p {
    margin-bottom: 15px;
    font-size: 1.1em;
    display: flex;
    align-items: center;
    justify-content: center; /* Centra el contenido del <p> (icono y texto) */
    gap: 10px;
}
.direct-contact-info-final .contact-icon {
    width: 24px;
    height: 24px;
    fill: var(--color-primary-dark); /* Color para iconos SVG en sección clara */
}
.direct-contact-info-final .whatsapp-icon-final { /* Para el icono de WhatsApp si es un <img> */
    width: 24px;
    height: 24px;
    /* Si el SVG es negro y necesitas que sea del color primario oscuro,
       no necesitarás filtro. Si es blanco y necesitas oscuro, tendrías
       que usar otro SVG o ajustar el filtro (lo cual es más complejo para pasar de blanco a oscuro).
       Por simplicidad, asumo que el SVG de WhatsApp es versátil o ya tiene el color adecuado.
       Si el img/whatsapp-icon.svg es blanco (como en el header), necesitarás un SVG de color
       o aplicar filter: invert(20%) sepia(0%) saturate(7500%) hue-rotate(320deg) brightness(95%) contrast(80%);
       para que se parezca a --color-primary-dark, o más fácil, usar un SVG ya coloreado.
       Si tu img/whatsapp-icon.svg es negro, no necesita filtros aquí.
    */
}

/* NUEVO: Wrapper para centrar el botón en la sección de contacto final */
.contact-final-button-wrapper {
    text-align: center; /* Centra el botón inline-block */
    margin-top: 30px;
}



/* BANNER DE COOKIES */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--color-primary-dark);
    color: var(--color-text-on-dark);
    padding: 20px;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
    z-index: 2000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    font-size: 0.9em;
}
.cookie-banner p {
    margin: 0;
    flex-grow: 1;
}
.cookie-banner a {
    color: var(--color-accent-yellow);
    text-decoration: underline;
}
.cookie-accept-btn {
    padding: 10px 20px;
    font-size: 0.9em;
    flex-shrink: 0;
}


/* Footer */
.footer {
    background-color: #303030;
    color: var(--color-text-on-dark);
    text-align: center;
    padding: 30px 20px;
    font-size: 0.9em;
}
.footer p {
    margin-bottom: 10px;
}
.footer a {
    color: var(--color-accent-yellow);
}
.footer .footer-links {
    margin-bottom: 15px;
}
.footer .main-site-link a {
    font-weight: bold;
}


/* Responsive Design Ajustes */
@media (max-width: 992px) {
    :root {
        --header-height: 60px;
    }
    h1 { font-size: 2.2em; }
    h2 { font-size: 1.8em; }

     .hero-form-first-container {
        flex-direction: column;
    }
    .hero-form-content {
        order: 1;
    }
    .hero-form-wrapper {
        order: 2;
        width: 90%;
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 55px;
    }
    h1 { font-size: 2em; }
    h2 { font-size: 1.6em; }
    h3 { font-size: 1.2em; }
    .hero-section-form-first .subtitle { font-size: 1.1em; } /* Referencia correcta */

    .container {
        padding: 40px 15px;
    }

    .header .header-container {
        position: relative;
    }

    .header .main-nav ul {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--color-primary-dark);
        padding: 10px 0;
        box-shadow: 0 5px 5px rgba(0,0,0,0.2);
    }
    .header .main-nav ul.active {
        display: flex;
    }
    .header .main-nav ul li {
        margin: 10px 0;
        text-align: center;
        width: 100%;
    }
    .header .main-nav ul li a {
        display: block;
        padding: 10px;
    }

    .nav-toggle {
        display: block;
    }

    .header .contact-info-header {
        font-size: 0.9em;
    }
    .header .contact-info-header .whatsapp-icon {
        width: 18px;
        height: 18px;
    }

    .hero-section-form-first { /*Padding para que no se solape el contenido con el header fijo en móvil*/
        padding-top: 20px; /* Reducido, ya que el scroll-padding-top maneja el anclaje */
        padding-bottom: 40px;
    }
    .hero-form-wrapper h2 {
        font-size: 1.6em;
    }
    .hero-form-wrapper .price-indicator {
        font-size: 1em;
    }
    .hero-form input[type="file"] {
        font-size: 0.9em;
    }
    .hero-form input[type="file"]::file-selector-button {
        padding: 6px 10px;
        font-size: 0.9em;
    }

    .cookie-banner {
        flex-direction: column;
        text-align: center;
    }
    .cookie-banner p {
        margin-bottom: 15px;
    }
    .direct-contact-info-final p {
        font-size: 1em;
        flex-direction: column;
        gap: 5px;
    }
    .direct-contact-info-final .contact-icon {
        margin-bottom: 5px;
    }
}

@media (max-width: 480px) {
    .cta-button {
        padding: 12px 20px;
        font-size: 1em;
    }
    .price-section .price-tag { /* Referencia correcta */
        font-size: 2.8em;
    }
}