/* ESTILOS COMUNES */

/* ----- FUENTE ----- */
@font-face {
    font-family: 'Open Sans';
    font-style: normal;
    font-weight: normal;
    src: url("../font/opensans/OpenSans-VariableFont.ttf");
}

body {
    font-family: 'Open Sans';
}


/* ----- Contenedor vertical ----- */
#contenedorBusquedaVertical {
  display: flex;
  flex-direction: column; /* apila verticalmente */
  align-items: center;    /* centra horizontalmente */
  gap: 8px;               /* espacio entre buscador y checkbox */
}

/* ----- BUSCADOR ----- */
#buscador {
  display: flex;
  align-items: center;
  gap: 5px;  /* espacio entre input y botón */
}

#buscador input {
  width: 250px; /* tamaño fijo del input */
}

/* ----- FILTRAR ----- */
#filtrar {
  display: flex;
  align-items: center;
  gap: 5px; /* espacio entre checkbox y label */
}

#filtrar input[type="checkbox"] {
  width: 20px;   /* checkbox más grande */
  height: 20px;  /* checkbox más grande */
  margin: 0;
}

#filtrar label {
  margin: 0;
  line-height: 1;
}

/* ----- FORMULARIOS ----- */
form div.formItem {
    margin: 10px auto;
    text-align: center;
}

div.formItem input, 
div.formItem select, 
div.formItem textarea {
    display: block;
    margin: auto;
    min-height: 28px;
    width: 100%;
    min-width: 320px;   /* asegura que el campo no sea demasiado estrecho dentro del formulario */
    max-width: 100%;
    border: 1px solid gray;
    border-radius: 5px;
    background-color: white;
}

div.formItem input[type="file"] {
    border: 0;
    border-radius: 0;
    background-color: aliceblue;
}

form {
    /* más ancho para que los campos sean más largos */
    width: 45%;
    min-width: 520px;    /* ancho mínimo en pantallas medianas/desktop */
    max-width: 900px;    /* evita que crezca demasiado en pantallas muy grandes */
    border: 1px solid gray;
    border-radius: 5px;
    margin: 1em auto;
    padding: 14px;
    color: #014179;
    background-color: aliceblue;
}

label {
    text-align: left;
}

div.formItem input[type="checkbox"] {
    min-width: 20px;
    width: auto;
    display: inline-block;
    position: static;
}

@media (max-width:576px) {
    form {
        width: 92%;
        padding: 3.4%;
        min-width: 250px;
        font-size: 0.95em;
    }
    div.formItem input, 
    div.formItem select, 
    div.formItem textarea {
        min-width: 0;
        width: 100%;
    }
}

div#divExito,
div#divError {
    display: none;
}

#loadingImg {
    display: none;
}

#loadingImg img {
    width: 32px;
    height: 32px;
}

/* ----- MENÚ DE NAVEGACIÓN -----*/

nav#menuPadres ul li,
nav#menuSecretaria ul li {
    cursor: pointer;
}

.topnav {
    background-color: #333;
    overflow: hidden;
}

/* Style the links inside the navigation bar */
.topnav li {
    float: left;
    display: block;
    color: #f2f2f2;
    text-align: center;
    padding: 14px 16px;
    text-decoration: none;
    font-size: 17px;
}

/* Change the color of links on hover */
.topnav li:hover {
    background-color: #00a1a7;
}

/* Add an active class to highlight the current page */
.topnav li.active {
    background-color: #00adc4;
    color: white;
}

/* Hide the link that should open and close the topnav on small screens */
.topnav .icon {
    display: none;
}

@media screen and (max-width: 600px) {
    .topnav li:not(:first-child) {display: none;}
    .topnav li.icon {
        float: right;
        display: block;
    }
}
  
/* The "responsive" class is added to the topnav with JavaScript when the user clicks on the icon. This class makes the topnav look good on small screens (display the links vertically instead of horizontally) */
@media screen and (max-width: 600px) {
    .topnav.responsive {position: relative;}
    .topnav.responsive li.icon {
        position: absolute;
        right: 0;
        top: 0;
    }
    .topnav.responsive li {
        float: none;
        display: block;
        text-align: left;
    }
}