/* Estilo general */
body {
    margin: 0;
    padding: 0;
    font-family: Helvetica, Arial, sans-serif;
    background: #f2f2f2; 
    font-size: 1rem;
    line-height: 1.5;
    width: 100%;
}

.contenedor {
    width: 100vw;
    margin: 0;
    overflow: hidden;
}

/* Menú */
#menu {
    background: #00183a;
    color: white;
    padding: 1rem 0;
    text-align: center;
    width: 100%;
}

#menu .row {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

#menu .col-md-3, #menu .col-md-6 {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
}

#menu .col-md-3 img {
    width: 90%;
    height: auto;  /* Ajusta la altura automáticamente */
}

#menu h3 {
    font-size: 1.5rem;
    margin: 0;
}

/* Sub menú */
#sub_menu {
    padding: 1rem;
    text-align: center;
    box-shadow: 0px 1px 10px rgba(0, 0, 0, 0.2);
}

#main_content {
    flex: 1;
    max-width: 100%;
    margin: 2rem auto;
    padding: 0 1rem;
    color: #000000;
}

#main_content .col-md-4 {
    flex: 0 0 auto;
    padding: 1rem;
    width: 100%;  /* Asegura que las columnas ocupen el 100% del ancho en pantallas pequeñas */
}

#main_content .col-md-4 a{
    color: black;
}

/* Contenedor */
.cont {
    padding: 1.25rem;
    margin-bottom: 1.25rem;
    height: auto;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 6px;
    box-shadow: 0px 1px 10px rgba(0, 0, 0, 0.2);
    transition: all 400ms ease;
}

.cont img {
    max-width: 100%;  /* Hace que la imagen se ajuste al tamaño del contenedor */
    height: 100%;
    margin-bottom: 1rem;
}

.cont.centrar {
    display: block;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.cont h5 {
    margin-top: 1rem;
    font-size: 1.2rem;
    font-weight: bold; 
    color: black; 
}

.cont:hover {
    cursor: pointer;
    box-shadow: 5px 5px 20px rgba(0, 0, 0, 0.4);
    background-color: #00183a;
    color: white;
    transform: translateY(4%);
}

.cont:hover h5 {
    color: white;
    text-decoration: underline;
}

.cont:active {
    background-color: #00183a83;
    transform: translateX(4%);
}

/* Overlay y popup */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    z-index: 1000;
}

.popup {
    position: fixed;
    z-index: 1001;
    background: white;
    border: 1px solid #000000;
    border-radius: 5px;
    padding: 1rem;
    width: 60%;
    max-width: 700px;
    box-sizing: border-box;
}

.popup div {
    text-align: center;
}

.popup ol li {
    font-size: 1rem;
    color: #000000;
}

.close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    cursor: pointer;
}

/* Footer */
#main_footer {
    background: #00183a;
    color: white;
    padding: 2rem 0;
    bottom: 0;
    width: 100%;
}

#main_footer .row {
    display: flex;
    justify-content: center;
    align-items: center;
}

#main_footer .col-lg-5 {
    display: flex;
    justify-content: center;
    align-items: center;
}

#main_footer .col-lg-5 img {
    width: 70%;
    height: auto;
}

#main_footer .col-lg-3 a {
    color: white;
}

/* Botón */
.boton {
    padding: 1rem 2rem;
    background-color: #020080;
    color: white;
    font-weight: bold;
    text-align: center;
    box-shadow: 1px 1px 10px rgba(0, 0, 0, 0.2);
    border: 2px #666 solid;
}

.boton:hover {
    text-decoration: underline;
    cursor: pointer;
    box-shadow: 5px 5px 20px rgba(0, 0, 0, 0.4);
    transform: translateY(4%);
}

.boton:active {
    background-color: #0300be;
}

/* Contenedor de botones */
.button-container {
    margin-top: 2rem;
}

.button-container button {
    margin: 0 1rem;
}

/* Media queries para pantallas pequeñas */
@media (max-width: 800px) {
    
    .contenedor {
        width: 100%;
        margin: 0;
    }
    
    #menu h1 {
        font-size: 3.5vw;

    }

    #menu .col-md-3 img {
        width: 25%;
        height: 25%;
    }

    #sub_menu h3{
        font-size: 3vw;
    }

    #main_content {
        padding: 0.5rem;
    }

    .col-md-4 {
        width: 100%; 
        margin-bottom: 1rem;
    }

    .cont img {
        width: 50%;
    }

    .cont h5 {
        font-size: 1rem;
    }

    #main_footer .col-lg-5 img {
        width: 100%;
        height: auto;
    }

    .popup {
        width: 90%; 
    }

    .popup div {
        font-size: 0.9rem;
    }
}

/* Media queries para pantallas medianas */
@media (min-width: 801px) and (max-width: 1199px) {
    #menu h3 {
        font-size: 1.2rem;
    }

    #menu .col-md-3 .col-sd-3 img {
        width: 40%;
        height: auto;
    }

    #main_content {
        padding: 1rem;
    }

    .col-md-4 {
        width: 33%;
    }

    .popup {
        max-width: 90%;
    }
}

/* Media queries para pantallas grandes */
@media (min-width: 1200px) {
    #menu h3 {
        font-size: 2rem;
    }

    #main_content {
        padding: 1.5rem;
    }

    .col-md-4 {
        width: 25%; 
    }

    .popup {
        max-width: 90%;
    }

    #main_footer {
        bottom: 0;
    }
}
