/* Estilos generales */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 100vh;
    font-family: Arial, sans-serif;
    padding-top: 80px; /* Deja espacio para el navbar */
    overflow-x: hidden; /* Evita desplazamiento horizontal */
    overflow-y: auto; /* Permite desplazamiento vertical */
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #fff;
    padding: 15px 30px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.navbar .logo img {
    width: 130px;
    height: auto;
}

.nav-links {
    list-style: none;
    display: flex;
    margin: 0;
    padding: 0;
}

.nav-links li {
    margin-left: 25px;
}

.nav-links a {
    color: #333;
    text-decoration: none;
    font-size: 16px;
    font-weight: 600;
    transition: color 0.3s ease;
    padding: 10px;
}

.nav-links a:hover {
    color: #007BFF;
}

/* Estilo para el botón de menú (hamburguesa) */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    width: 30px;
    height: 25px;
    cursor: pointer;
}

.menu-toggle .bar {
    width: 30px;
    height: 5px;
    background-color: #333;
    border-radius: 5px;
}

.nav-links.active {
    display: block;
}

.search {
    display: flex;
    align-items: center;
}

.search input {
    padding: 8px 15px;
    font-size: 16px;
    border: 1px solid #ddd;
    border-radius: 30px;
    margin-right: 10px;
    outline: none;
    width: 200px;
}

.search input:focus {
    border-color: #007BFF;
}

.search-btn {
    background: none;
    border: none;
    cursor: pointer;
}

.search-btn img {
    width: 20px;
}

/* Contenido principal */
.main-content {
    text-align: center;
    margin: auto;
    max-width: 1000px;
    padding: 20px;
}

.main-content h1 {
    margin-top: 0;
    padding-top: 20px; /* Espacio debajo del navbar */
    margin-bottom: 30px; /* Espacio debajo del título */
    font-size: 32px;
    font-weight: bold;
    text-align: center;
}

/* Contenedor para las tarjetas */
.section-container {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 40px;
    flex-wrap: wrap; /* Para que se adapten en pantallas pequeñas */
}

/* Tarjetas de información */
.section {
    flex: 1;
    padding: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    border-radius: 15px;
    background-color: #f9f9f9;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 20px;
    cursor: pointer;
}

.section img {
    width: 50px;
    height: 50px;
    margin-bottom: 15px;
}

.section h2 {
    font-size: 24px;
    margin-bottom: 10px;
    color: #333;
}

.section p {
    font-size: 18px;
    line-height: 1.5;
    color: #555;
}

/* Efecto hover para las tarjetas */
.section:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.section:hover h2 {
    color: #007BFF;
}

/* Footer */
footer {
    background-color: #f1f1f1;
    padding: 20px 30px; /* Reducido el padding superior e inferior a 20px */
    width: 100%;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    margin-top: 40px;
    z-index: 1;
    position: relative;
    overflow: hidden; /* Oculta las partículas fuera del footer */
}

/* Animación de partículas flotantes */
footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(0, 123, 255, 0.3) 20%, transparent 20%) repeat;
    background-size: 20px 20px;
    animation: floating 10s linear infinite;
}

/* Keyframes para la animación de las partículas */
@keyframes floating {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
    100% {
        transform: translateY(0);
    }
}

/* Resto del contenido del footer */
.footer-content {
    display: flex;
    justify-content: space-between;
    width: 100%;
    flex-wrap: wrap;
    position: relative; /* Para que el contenido esté por encima de las partículas */
}

.footer-content div {
    width: 30%;
    margin-bottom: 30px;
}

.footer-content h3 {
    font-size: 22px;
    margin-bottom: 15px;
    font-weight: 600;
}

.footer-content p {
    font-size: 16px;
    line-height: 1.6;
}

.footer-whatsapp {
    text-align: right;
    padding-right: 20px;
}

.footer-whatsapp a img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.footer-whatsapp a img:hover {
    transform: scale(1.1);
}

/* Responsive Design */
@media (max-width: 768px) {

    body.menu-open .main-content{
        transform: translateY(200px);
        /* Ajusta la cantidad de desplazamiento a tu gusto */
        transition: transform 0.3s ease-in-out;
    }

    .menu-toggle {
        display: flex;
        position: absolute;
        top: 15px;
        right: 15px;
        z-index: 1100;
    }

    .navbar {
        flex-direction: column;
        padding: 10px;
    }

    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        text-align: center;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links li {
        margin: 10px 0;
    }

    .search input {
        width: 100%;
    }

    footer {
        flex-direction: column;
        align-items: center;
    }

    .footer-content div {
        width: 100%;
        text-align: center;
        margin-bottom: 20px;
    }

    .section-container {
        flex-direction: column; /* Cambia a vertical */
        align-items: center;
    }

    .section {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .menu-toggle {
        display: flex;
    }

    .navbar {
        padding: 10px 15px;
    }

    .search input {
        width: 150px;
    }

    footer {
        padding: 20px 15px;
    }

    .footer-content div {
        width: 100%;
    }

    .section-container {
        gap: 15px;
    }

    .section {
        margin-bottom: 20px;
    }
}
