/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ESTILOS PRINCIPALES */
html,
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.7em;
    background-color: #f4f4f4;
    color: #333;
}

a {
    color: #333;
    text-decoration: none;
}

h1,
h2,
h3 {
    padding-bottom: 10px;
}

p {
    margin: 10px 0;
}

/* UTILIDADES */
.container {
    margin: auto;
    max-width: 1100px;
    overflow: auto;
    padding: 0 20px;
}

.clr {
    clear: both;
}

.py-1 {
    padding: 10px 0;
}

.py-2 {
    padding: 20px 0;
}

.py-3 {
    padding: 30px 0;
}

.btn {
    display: inline-block;
    font-size: 18px;
    color: #fff;
    background: #333;
    padding: 13px 20px;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease-in-out;
}

.lead {
    font-size: 20px;
}

.text-primary {
    color: #000000;
}

.btn:hover {
    background-color: #9da37a;
    color: #333;
}

/* NAVEGACION */
#navbar {
    background: #000;
    color: #fff;
    overflow: auto;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#navbar a {
    color: #fff;
}

#navbar h1 {
    float: left;
    padding-top: 20px;
}

#navbar ul {
    list-style: none;
    float: right;
}

#navbar ul li {
    float: left;
}

#navbar ul li a {
    display: block;
    padding: 20px;
    text-align: center;
    transition: background 0.3s ease-in-out;
}

#navbar ul li a:hover,
#navbar ul li a.current {
    background: #9da37a;
    color: #000;
}

/* SHOWCASE */
#showcase {
    background: url('../img/mejor imagen 2.webp') no-repeat center center/cover;
    height: 600px;
    position: relative;
    z-index: 1;
}

#showcase::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: inherit;
    filter: blur(4px);
    z-index: -1;
}

#showcase .showcase-content {
    color: white;
    text-align: center;
    padding-top: 170px;
}

#showcase .showcase-content h1 {
    font-size: 60px;
    line-height: 1.2em;
}

#showcase .showcase-content p {
    padding-bottom: 20px;
    line-height: 1.7em;
}

/* CONTENEDOR DE BOTONES */
#showcase .btn-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-top: 20px;
}

#showcase .btn-group .btn {
    width: 80%;
    max-width: 350px;
}

/* HOME */
#home-info {
    padding: 30px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background-color: #f4f4f4;
}

#home-info .info-img {
    width: 100%;
    max-width: 400px;
    background: url('../img/showcase.jpg') no-repeat center center/cover;
    min-height: 300px;
    margin-bottom: 20px;
    border-radius: 10%;
    flex-shrink: 0;
}

#home-info .info-content {
    width: 100%;
    text-align: center;
    flex-grow: 1;
}

#home-info .info-content h2 {
    color: #333;
    font-size: 30px;
    font-weight: bold;
    margin-bottom: 10px;
}

#home-info .info-content p {
    color: #666;
    margin-bottom: 20px;
}

#home-info .info-content .btn {
    margin-top: 10px;
}

/* FEATURES */
#features {
    padding: 10px 0;
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.box {
    text-align: center;
    padding: 50px 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.box i {
    margin-bottom: 20px;
}

.bg-gray {
    background: #cfcfcf;
    color: #333;
}

.bg-light {
    background: #f4f4f4;
    color: #333;
}

.bg-primary {
    background: #9da37a;
    color: #333;
}

/* FOOTER */
#main-footer {
    background: #000;
    color: #fff;
    padding: 20px;
    text-align: center;
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.footer-content p {
    margin-bottom: 15px;
}

.social-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    gap: 20px;
}

.social-links li a {
    color: #fff;
    font-size: 24px;
    transition: color 0.3s ease-in-out;
}

.social-links li a:hover {
    color: #9da37a;
}

/* ABOUT US */
#about-info {
    background-color: #6a6964;
    padding: 30px 0;
    color: #fff;
    padding-top: 80px; /* Ajuste para compensar la barra de navegación fija */
}

#about-info .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0;
}

#about-info .info-left,
#about-info .info-right {
    max-width: 100%;
    text-align: center;
    margin-bottom: 20px;
}

#about-info .info-left h1 {
    color: #fff;
}

#about-info .info-right img {
    display: block;
    width: 70%;
    max-width: 400px;
    border-radius: 10%;
    height: auto;
    margin: auto;
}

/* PREGUNTAS FRECUENTES */
#testimonials {
    background: url(../img/terceraimagen.jpg) no-repeat center/cover;
    position: relative;
    z-index: 1;
    padding: 100px 50px;
}

#testimonials::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: inherit;
    filter: blur(5px);
    z-index: -1;
}

#testimonials .container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
}

#testimonials .container .l-heading {
    grid-column: 1 / -1;
    text-align: center;
    color: black;
    padding-bottom: 40px;
}

#testimonials .testimonial {
    background-color: #9da37a;
    padding: 20px;
    border-radius: 5px;
    opacity: 0.9;
}

#testimonials .testimonial img {
    width: 100px;
    float: left;
    margin-right: 20px;
    border-radius: 50%;
}

/* PANFLETO INFORMATIVO */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    visibility: hidden;
    opacity: 0;
    transition: visibility 0s, opacity 0.3s ease;
    z-index: 1000;
}

.modal-overlay.visible {
    visibility: visible;
    opacity: 1;
}

.panfleto-container {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: auto;
    gap: 20px;
    width: 1500px;
    max-width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    background-color: #fff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 20px;
    position: relative;
}

.cerrar-btn {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 2em;
    font-weight: bold;
    color: #6c757d;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s ease;
}

.cerrar-btn:hover {
    color: #000;
}

.columna {
    padding: 30px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

/* ESTILOS CORREGIDOS PARA LA COLUMNA DE LA IMAGEN */
.columna-portada {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    padding: 20px;
    background-color: #9da37a;
    color: #fff;
    min-height: 300px;
    overflow: hidden;
}

.columna-portada h2 {
    font-size: 2.2em;
    margin-bottom: 5px;
    color: #fff;
}

.columna-portada img {
    max-width: 90%;
    height: auto;
    display: block;
    margin: 5px auto 5px auto;
}

.columna-portada p {
    font-size: 1.1em;
    margin-top: 5px;
    color: #fff;
}

.columna-contenido h3 {
    color: #9da37a;
    border-bottom: 2px solid #9da37a;
    padding-bottom: 5px;
}

/* NUEVO CONTENEDOR PARA SWIPER */
.float-clear-wrapper {
    overflow: hidden;
    width: 100%;
}

/* SWIPER - ESTILOS CRUCIALES */
.swiper-container {
    width: 100%;
    max-width: 1100px;
    margin: 50px auto;
    padding-top: 20px;
    padding-bottom: 50px;
    overflow: hidden;
}

.swiper-container .swiper-wrapper {
    display: flex !important;
    box-sizing: content-box;
}

.swiper-container .swiper-slide {
    width: 380px;
    flex-shrink: 0;
    background-color: #fdfdfd;
    overflow: hidden;
    border-radius: 8px;
    color: rgb(9, 9, 9);
    margin-right: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.swiper-slide .picture {
    width: 100%;
    height: 380px;
    overflow: hidden;
}

.swiper-slide .picture img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ESTILOS PARA LA PAGINACIÓN Y NAVEGACIÓN */
.swiper-pagination-bullet {
    background: #9da37a;
    opacity: 0.7;
}

.swiper-pagination-bullet-active {
    background: #000;
    opacity: 1;
}

.swiper-button-next,
.swiper-button-prev {
    color: #9da37a;
    transition: color 0.3s ease-in-out;
}

.swiper-button-next:hover,
.swiper-button-prev:hover {
    color: #333;
}

.swiper-button-next:after,
.swiper-button-prev:after {
    font-size: 25px;
}

/* SECCION FAQ - ACORDEON */
#faq {
    padding: 60px 0;
    background: url('../img/segunda imagen.jpg') no-repeat center center/cover;
    position: relative;
    z-index: 1;
}

#faq::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: -1;
}

#faq .l-heading {
    text-align: center;
    margin-bottom: 40px;
    font-size: 40px;
    color: #333;
}

.accordion {
    max-width: 800px;
    margin: auto;
}

.accordion-item {
    background-color: #f9f9f9;
    border: 1px solid #ddd;
    margin-bottom: 10px;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease-in-out;
}

.accordion-item.active {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.accordion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    cursor: pointer;
    background-color: #9da37a;
    transition: background-color 0.3s ease-in-out;
}

.accordion-header:hover {
    background-color: #909477;
}

.accordion-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #fff;
    transition: color 0.3s ease-in-out;
}

.accordion-item.active .accordion-header h3 {
    color: #333;
}

.accordion-header .icon {
    font-size: 24px;
    font-weight: bold;
    color: #fff;
    transition: transform 0.3s ease-in-out, color 0.3s ease-in-out;
}

.accordion-item.active .accordion-header .icon {
    transform: rotate(45deg);
    color: #333;
}

.accordion-content {
    padding: 0 30px;
    background-color: #fff;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-in-out;
}

.accordion-content p {
    padding: 20px 0;
    margin: 0;
    line-height: 1.6em;
}

.accordion-item.active .accordion-content {
    max-height: 500px;
}

/* SECCION DE CONTACTO - FORMULARIO */
#contact {
    background: #fdfdfd;
    padding: 60px 0;
    padding-top: 80px; /* Ajuste para compensar la barra de navegación fija */
}

#contact .l-heading {
    color: #333;
    margin-bottom: 10px;
}

#contact .lead {
    color: #666;
    margin-bottom: 40px;
}

#contact form {
    max-width: 600px;
    margin: auto;
    padding: 40px;
    border-radius: 12px;
    background: #f4f4f4;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

/* Estilos para las etiquetas flotantes */
.floating-label-group {
    position: relative;
    margin-bottom: 30px;
    font-size: 16px;
}

.floating-input {
    width: 100%;
    padding: 12px 10px;
    border: none;
    border-bottom: 2px solid #ddd;
    background: transparent;
    font-size: 1em;
    outline: none;
    transition: all 0.3s ease-in-out;
}

.floating-label {
    position: absolute;
    top: 12px;
    left: 10px;
    color: #999;
    pointer-events: none;
    transition: all 0.3s ease-in-out;
}

.floating-input:focus,
.floating-input:not(:placeholder-shown) {
    border-bottom: 2px solid #9da37a;
}

.floating-input:focus + .floating-label,
.floating-input:not(:placeholder-shown) + .floating-label {
    top: -15px;
    font-size: 0.8em;
    color: #9da37a;
}

/* Estilos de los grupos de formulario (campos normales) */
.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #555;
    font-size: 16px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    transition: border-color 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #9da37a;
    box-shadow: 0 0 8px rgba(157, 163, 122, 0.4);
}

.form-group textarea {
    resize: vertical;
}

/* Estilos para los select */
#contact .form-group select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23333' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 12px;
}

/* Estilos para los checkboxes */
#contact .form-group .checkbox-group {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

#contact .form-group .checkbox-group input[type="checkbox"] {
    width: auto;
    margin-right: 10px;
}

#contact .form-group .checkbox-group label {
    margin-bottom: 0;
    font-weight: normal;
}

/* Estilos para el botón de enviar */
.btn-dark {
    display: inline-block;
    width: 100%;
    font-size: 18px;
    color: #fff;
    background: #333;
    padding: 15px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 1px;
    transition: background-color 0.3s ease-in-out;
}

.btn-dark:hover {
    background-color: #9da37a;
    color: #333;
}

/* Agrupacion de campos de direccion con CSS Grid */
.address-group {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-bottom: 25px;
}

/* Estilos para los campos de fecha */
input[type="date"] {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 16px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: #555;
    transition: border-color 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
}

input[type="date"]:focus {
    outline: none;
    border-color: #9da37a;
    box-shadow: 0 0 8px rgba(157, 163, 122, 0.4);
}

/* Estilos para el pop-up de error */
#error-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    visibility: hidden;
    opacity: 0;
    transition: visibility 0s, opacity 0.3s ease;
    z-index: 2000;
}

#error-popup-overlay.visible {
    visibility: visible;
    opacity: 1;
}

#error-popup {
    background-color: #fff;
    padding: 30px;
    border-radius: 10px;
    text-align: center;
    max-width: 400px;
    position: relative;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

#close-popup-btn {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 2em;
    font-weight: bold;
    color: #6c757d;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s ease;
}

#close-popup-btn:hover {
    color: #000;
}

.popup-content p {
    font-size: 1.2em;
    margin-bottom: 20px;
    line-height: 1.5;
}

.popup-content .btn {
    background-color: #9da37a;
    color: #fff;
    padding: 12px 25px;
    border-radius: 5px;
    display: inline-block;
}

.popup-content .btn:hover {
    background-color: #7a825b;
}

/*
 * =================================
 * ESTILOS RESPONSIVE (MEDIA QUERIES)
 * =================================
 */

/* Para pantallas de móviles y más pequeñas (máximo 767px) */
@media(max-width: 767px) {
    /* Ocultar el texto en la página principal para ahorrar espacio */
    .showcase .showcase-content p {
        display: none;
    }
}

/* Para tabletas y pantallas medianas (768px y más) */
@media(min-width: 768px) {
    /* Vuelve a mostrar el texto en pantallas grandes */
    .showcase .showcase-content p {
        display: block;
    }
    
    /* En pantallas más grandes, los botones se colocan en fila */
    #showcase .btn-group {
        flex-direction: row;
        justify-content: center;
        gap: 20px;
    }

    #showcase .btn-group .btn {
        width: auto;
    }
    
    /* HOME - Alinear la imagen y el texto uno al lado del otro */
    #home-info {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        text-align: left;
        padding: 0;
        max-width: none;
        margin: 0;
    }

    #home-info .info-img {
        width: 55%;
        max-width: none;
        height: 400px;
        margin-bottom: 0;
        border-radius: 0;
    }

    #home-info .info-content {
        width: 45%;
        padding: 0 40px;
        text-align: left;
        flex-grow: 0;
        max-width: none;
    }

    /* FEATURES - Restaura el layout de 3 columnas para pantallas más grandes */
    #features {
        grid-template-columns: repeat(3, 1fr);
    }
    
    /* ABOUT - Restablece la distribución en columnas */
    #about-info .container {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
    
    #about-info .info-left,
    #about-info .info-right {
        max-width: 48%;
        text-align: left;
        margin-bottom: 0;
    }

    #about-info .info-right img {
        margin: 0;
    }
}

/* Para pantallas de escritorio (1024px y más) */
@media(min-width: 1024px) {
    #testimonials .container {
        grid-template-columns: repeat(4, 1fr);
    }
    .panfleto-container {
        grid-template-columns: repeat(4, 1fr);
    }
}