.container-body {
  height: 100dvh;
  display: grid;
  grid-template: 
    "header header" 70px
    "nav article" 1fr
    "nav footer" 100px / 
    300px 1fr;
}

header {
  grid-area: header;
}
nav {
  grid-area: nav;
  width: 300px;
  background-color: #303053;
  position: fixed;
  top: 80px; /* igual al height del header */
  height: calc(100vh - 70px);
  overflow-x: hidden;  /* Oculta el scroll horizontal */
  overflow-y: auto;
  z-index: 1;
  border-right: 1px solid #eee;
  border-radius: 10px;
  padding-top: 2rem;
  /* left: 0; */
}
article {
  grid-area: article;
  width: 98%;
  max-width: 1800px;
  margin: 10px auto; 
}
footer {
  grid-area: footer;
  font-size: 16px;
  margin-top: 0 !important;
  /* font-size: 16px;
    background-color: #303053;
    font-weight: normal;
    margin-left: 300px;
    max-width: 78%; */
}

.requerido {
  color: #BF1F13;
}

.img-primaria {
    border-radius: 30px;
    box-shadow: 0 0 15px 5px rgba(0, 0, 0, 0.3);
  }

/* HEADER: (asegúrate de que tenga height fijo) */
#main-header {
  height: 70px;
  width: 100%;
  position: fixed;
  
  z-index: 1;
  vertical-align: baseline !important;
}

/* ESTILOS DE MENU*/

ul {
  list-style-type: none;
  margin: 0; /*margen de arriba*/
  padding: 20px; /*sangria*/
  /* overflow-y:hidden; */
  /* width: 300px; */
  font-size: 16px;
}

li {
  float: none;
}

li a {
  /* display: block; */
  color: white;
  text-align: left;
  padding: 15px;
  text-decoration: none;
  border-radius: 10px;
}

li a:hover {
  background-color: #111111;
}


#side-menu ul {
  /* list-style: none;
  padding: 0;
  margin: 0; */
  overflow-x: hidden;  /* Oculta el scroll horizontal */
}

#side-menu ul li {
  position: relative;
}

#side-menu ul li a {
  display: flex;
  align-items: center;
  /* padding: 8px 16px; */
  /* color: #333;
  text-decoration: none;
  background: #fff; */
  /* border-bottom: 1px solid #eee; */
  white-space: nowrap;
}

.submenu-arrow {
  font-size: 0.8em;
  margin-left: 6px;
  transition: transform 0.2s;
}

.submenu-arrow.open {
  transform: rotate(180deg);
}

/* Submenus en columna (default, no absolute) */
#side-menu ul.submenu {
  margin-left: 20px; /* para indentación, puedes ajustar o quitar */
  /* border-left: 1px solid #eee; */
}

/* Oculta los submenus por defecto */
#side-menu .submenu {
  display: none;
}

#side-menu .submenu.active {
  display: block;
}

/* ESTILO IMAGENES */
.img{
  max-width: 100%;
  height: auto;
  display: block;
  margin-left: auto;
  margin-right: auto; 
}

/* ESTILO DE CONTENIDO*/
p {
  text-align: justify;
  font-size: 18px;
  color: #333333;
  font-weight: normal;
}
/* ESTILO DE TITULOS */
.titulo {
  scroll-margin-top: 80px; /* Ajusta según el alto real de tu header */
}

#scrollToTopBtn {
  display: none; /* Oculto por defecto */
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 100;
  font-size: 20px;
  background: #333;
  color: white;
  border: none;
  border-radius: 50%;
  padding: 10px 15px;
  cursor: pointer;
  box-shadow: 0px 2px 5px rgba(0,0,0,0.3);
}
#scrollToTopBtn:hover {
  background: #555;
}


@media (max-width: 768px){
    .container-body {
    height: 100dvh;
    display: grid;
    grid-template: 
      "header" 70px
      "nav" 100px
      "article" 1fr
      "footer" 100px / 
      1fr;
  }

  nav {
    height: auto;
    margin:10px 0;
    width: 100%;
    padding: 0;
    top:70px;
  }

  .text-center {
    display: none;
  }

  .opciones {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
  }

}
