/* Submenú de gestión centrado */
.nav-pills-gestion {
  background-color: var(--azul-oscuro);
  padding: 8px;
  border-radius: 50px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  display: inline-flex;
}
li.nav-item a{
font-size: 14px !important;
}

.nav-pills-gestion .nav-link {
  color: var(--blanco) !important;
  font-family: var(--f_k_r);

  padding: 8px 18px;
  border-radius: 30px;
  transition: all 0.3s ease;
  text-decoration: none;
}

.nav-pills-gestion .nav-link:hover {
  background-color: var(--azul-medio);
  color: var(--blanco) !important;
}

/* Estado Activo con Color Dorado Institucional */
.nav-pills-gestion .nav-link.active {
  background-color: var(--dorado) !important;
  color: var(--azul-oscuro) !important;
  font-family: var(--f_k_b);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* Customización de Nav Pills Institucionales */
.cards-navbar .nav-pills {
  background-color: var(--azul-oscuro);
  padding: 8px 4px;
  border-radius: 8px;
  border: 1px solid var(--borde);
}

.cards-navbar .nav-link {
  color: var(--blanco);
  font-family: var(--f_k_r);
  font-size: 15px;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease-in-out;
}

.cards-navbar .nav-link:hover {
  color: var(--dorado-claro);
  background-color: rgba(255, 255, 255, 0.1);
}

/* Estado Activo */
.cards-navbar .nav-link.active,
.cards-navbar .nav-pills .nav-link.active {
  background-color: var(--dorado) !important;
  color: var(--azul-oscuro) !important;
  font-family: var(--f_k_b);
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

/* Regla para OCULTAR el ícono cuando el enlace esté activo */
.cards-navbar .nav-link.active i,
.cards-navbar .nav-link.disabled i {
  display: none !important;
}

/* Estado Deshabilitado o Sin Acceso */
.cards-navbar .nav-link.disabled {
  color: rgba(255, 255, 255, 0.4) !important;
  opacity: 0.6;
}

/* Dropdown Personalizado */
.cards-navbar .dropdown-menu {
  background-color: var(--blanco);
  border: 1px solid var(--borde);
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.cards-navbar .dropdown-item {
  color: var(--texto);
  font-family: var(--f_k_r);
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.cards-navbar .dropdown-item:hover {
  background-color: var(--gris_claro);
  color: var(--azul);
}

.cards-navbar .dropdown-item.active {
  background-color: var(--azul-medio);
  color: var(--blanco);
}

/* Estilo para los divisores */
.cards-navbar .dropdown-divider {
  border-top: 1px solid var(--borde);
}
/* ==========================================================================
   ESTILOS COMPLEMENTARIOS PARA MÓVIL (HAMBURGUESA A 760px)
   ========================================================================== */
.nav_contenedor .icosize i {
  font-size: 20px;
  color: black;
}

.nav_contenedor {
  position: relative;
  width: calc(100% - 600px);
}

/* Botón Hamburguesa oculto por defecto en escritorio */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 21px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1000;
}

.hamburger span {
  width: 100%;
  height: 3px;
  background-color: #333;
  border-radius: 10px;
  transition: all 0.3s ease;
}

/* Estilo base para los s de lista */
.botones_men li {
  position: relative;
   width: 140px;
   /* Permite posicionar los submenús respecto a este  */
}

/* Botones principales e hijos (enlaces) */
.botones_men a {
  display: flex;
  align-items: center;
  text-decoration: none;
  padding: 10px 15px;
  background-color: #ffffff;
  color: #333333;
  border-radius: 6px;
  border: 3px solid;
  border-color: var(--borde);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: all 0.25s ease;
  white-space: nowrap;
  flex-wrap: wrap;
  text-align: center;
  align-content: center;
  justify-content: center;
  height: 62px;
  i{  width: 100%;}
}


.botones_men ul {
  display: none;
  position: absolute;
  list-style: none;
  padding: 0;
  margin: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  border-radius: 6px;
  background-color: #ffffff;
  z-index: 999;
}

/* Mostrar submenú inmediatamente inferior al hacer hover */
.botones_men li:hover > ul {
  display: block;
}

/* --- POSICIONAMIENTO POR NIVEL --- */

/* NIVEL 2: Aparece abajo del botón principal */
.botones_men > li > ul {
  top: 88%;
  left: 0;
  margin-top: 5px;
}

/* NIVEL 3: Aparece a la derecha del  del Nivel 2 */
.botones_men ul ul {
  top: 0;
  left: 97%;
  margin-left: 2px;
}

.botones_men > li > a:nth-child(6) {
  background: red !important;
}

/* Ajustes de enlaces específicos dentro de los submenús (Nivel 2 y 3) */
.botones_men ul a {
  border: 0 0 2px solid black;
  border-radius: 0;
  padding: 6x 12px;
  justify-content: flex-start;
  width: 200px;
  /* Ancho fijo para los submenús */
  box-shadow: none;
  font-size: 16px;
}

/* Redondear esquinas del primer y último enlace de los submenús */
.botones_men ul li:first-child > a {
  border-top-left-radius: 6px;
  border-top-right-radius: 6px;
}

.botones_men ul li:last-child > a {
  border-bottom-left-radius: 6px;
  border-bottom-right-radius: 6px;
}

/* Indicador visual de que existe un submenú hijo (opcional) */
.botones_men ul li:has(ul) > a::after {
  content: " »";
  margin-left: auto;
  font-weight: bold;
}

/* .botones_men > li:nth-child(1) > a:nth-child(1) {
  background: #ffe311;
}
.botones_men > li:nth-child(2) > a:nth-child(1) {
  background: #edd100;
} */

.botones_men > li > a{
  background-color: var(--dorado-claro);
}

li.logout > a:nth-child(1) {
  background: red;
  border-radius: none;
  width: 60px;
}

li.logout > a:hover:nth-child(1) {
  background: #eb7191;
  border-radius: 50%;
}

/* hover */
.botones_men > li:hover a {
  background: #fcef91;

  i,
  p {
    color: #787547;
  }
}
.botones_men > li:nth-child(2):hover > a:nth-child(1) {
  background: #ede78d;
  

  i,
  p {
    color: #787547;
  }
}

.botones_men > li:nth-child(3):hover > a:nth-child(1) {
  background: #f2ec8f;
  

  i,
  p {
    color: rgb(120, 117, 71);
  }
}

.botones_men > li:nth-child(4):hover > a:nth-child(1) {
  background: #ded883;
  

  i,
  p {
    color: rgb(120, 117, 71);
  }
}

.botones_men > li:nth-child(5):hover > a:nth-child(1) {
  background: #c9c477;
  

  i,
  p {
    color: rgb(120, 117, 71);
  }
}

.botones_men > li:nth-child(8) > a:nth-child(1) {
  background: #ff0445;
  text-align: center;
  width: 88px;
}

.botones_men > li:nth-child(8):hover > a:nth-child(1) {
  background: #ff044529;
  border-radius: 59%;
}

/* --- MEDIA QUERY: DISPOSITIVOS MÓVILES (<= 760px) --- */
@media (max-width: 760px) {
  .botones_men {
    background: none;
  }
  /* Hacer visible la hamburguesa */
  nav.nav_contenedor .hamburger {
    display: flex !important;
    margin: 15px 0;
  }

  /* Animación de la hamburguesa a una "X" cuando está activa */
  nav.nav_contenedor .hamburger.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
  }
  nav.nav_contenedor .hamburger.active span:nth-child(2) {
    opacity: 0;
  }
  nav.nav_contenedor .hamburger.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
  }

  /* Transformar la barra horizontal en menú vertical desplegable */
  nav.nav_contenedor .botones_men {
    display: none !important; /* Forzar que se oculte por defecto */
    flex-direction: column;
    width: 100%;
    gap: 0;
    margin: 10px 0;
    background-color: #fcfcfc;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 5px 0;
  }

  /* REGLA CRÍTICA: Mostrar el menú con máxima prioridad cuando tenga la clase .active */
  nav.nav_contenedor .botones_men.active {
    display: flex !important;
  }

  nav.nav_contenedor .botones_men li {
    width: 100%;
    position: relative;
    margin: 0;
  }

  /* Ajustar los enlaces principales al formato móvil */
  nav.nav_contenedor .botones_men a {
    border: none;
    border-radius: 0;
    box-shadow: none;
    padding: 12px 20px;
    width: 100%;
    box-sizing: border-box;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
  }

  /* submenús móviles (Nivel 2 y 3) de manera vertical */
  nav.nav_contenedor .botones_men ul {
    position: static !important;
    box-shadow: none;
    background-color: #f7f9fa;
    border-radius: 0;
    width: 100%;
    display: none; /* Ocultos por defecto en móvil hasta que se haga hover o clic */
  }

  /* Mostrar submenús en móvil al pasar el cursor o heredar visualización */
  nav.nav_contenedor .botones_men li:hover > ul {
    display: block !important;
  }

  nav.nav_contenedor .botones_men ul a {
    width: 100%;
    padding-left: 40px !important;
    background-color: #f5f7f8;
  }

  nav.nav_contenedor .botones_men ul ul a {
    padding-left: 60px !important;
    background-color: #edf1f3;
  }
}

/*.ulmen > a:nth-child(1) {
background: #651ffa;
}

.ulmen > a:nth-child(2) {
background: #ffc2d6;
}

 .ulmen > a:nth-child(3) {
background: #0A9BD8;
} 

.ulmen > a:nth-child(4) {
background: #1fff42;
}*/
/* .cont_menu_h a:hover{
  border-radius: 50%;
  box-shadow: 2px 2px 2px black;
} */
/* ============================ PANEL DE CONTROL  ============================ */
.testprueb {
  p {
    font-size: 28px;
  }
}
.cards {
display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  padding: 10px 0 0 0 !important;
  text-align: center;
  width: 100%;
  background: var(--fondo_principal);
  p,
  a {
    text-decoration: none;
    font-size: 18px;
    color: black;
    width: fit-content;
    font-family: var(--f_k_r);
    margin-bottom: 0px !important;
  }
  i {
    text-decoration: none;
    font-size: 32px;
    color: black;
    padding-top: 7px !important;
  }
  .d-flex{
    width: 100%!important;
  }
}
.cards-navbar {
width: 100%!important;
}
.card_6 {
  background: #ff0445;
}
.card_6:hover {
  background: #ff3f72;
}

/* ============================ USUARIOS  ============================ */

.titul_men {
  width: 100%;
  display: flex;
  justify-content: space-between;
  p {
    text-align: left;
  }
}
.botones_men {
  padding: 0 5px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  list-style: none;
  padding: 0;
  margin: 20px 0;
  position: relative;
  /* width: calc(100% - 600px); */
}
.edit_ico,
.elim_ico {
  font-size: 24px !important;
  padding: 0;
  border-radius: 3%;
  box-shadow: 1px 1px 4px black;
}
.edit_ico {
  background: yellow;
}
.elim_ico {
  background: rgb(255, 0, 0);
  color: white !important;
}

/*cont_aportes*/
.cont_aportes {
  max-width: 100vw;
padding: 0 1%;
}

.cont_conf_ind {
  width: 95%;
  margin: auto;
}

@media (min-width: 1201px) {

  .nav_contenedor {
    width: calc(100% - 650px);
  }
  .subpg {
width: 850px !important;
}
.subnav {
width: calc(100% - 850px) !important;
}
}

@media (max-width: 1200px) {
  .cards {
    flex-wrap: wrap;
  }

  .nav_contenedor {
    width: 100%;
    padding: 0;
    margin: 5px 0 5px 0;
  }

.subpg {
width: 850px !important;
}
.subnav {
width: calc(100% - 850px) !important;
}
}


.bt_fuentes{
background: #ffffff17 !important;
  border-bottom: 7px double #ffbe5a !important;
  width: 193px !important;
  margin: 14px auto !important;
  display: flex !important;
  box-shadow: none !important;
  border: none;
  img{
   max-width: 86% !important;
  height: auto!important;
  margin: 0 auto!important;}
}
.bt_fuentes:hover{
background: #fada9fb1 !important;
  border-bottom: 7px dotted #fd9800 !important;
min-width: 193px !important;
}
 .bt_fuentes  img:hover{
   width: 80%;
    margin: auto;
  } 
.cont_panelp{
  background: url(../img/img_index/fondo_pc_3.jpg);
  background-position: top left;
background-attachment: fixed;
}

