/* Add here all your CSS customizations */

/* ===== Cabecera y menu lateral: diseno "menu oscuro" (nav-super.php y barralateral.php) ===== */
html .header.gx-header {
  background: #ffffff;
  border: 0;
  box-shadow: none;
  display: flex;
  font-family: "Plus Jakarta Sans", "Open Sans", sans-serif;
  height: 60px;
}

/* El logo va sobre el mismo fondo que el menu, con su mismo ancho */
.gx-header .logo-container {
  align-items: center;
  background: #0f172a;
  box-sizing: border-box;
  display: flex;
  flex: 0 0 300px;
  padding: 0 24px;
  position: relative;
}

.gx-header .gx-logo {
  display: flex;
  float: none;
  margin: 0;
}

.gx-header .gx-logo img {
  display: block;
  height: 40px;
  width: auto;
}

.gx-header .gx-header-right {
  align-items: center;
  border-bottom: 1px solid #e5e9f0; /* solo en la parte blanca: bajo el logo sigue el fondo del menu */
  box-sizing: border-box;
  display: flex;
  flex: 1 1 auto;
  float: none;
  gap: 14px;
  height: 100%;
  min-width: 0;
  padding: 0 24px;
}

.gx-toggle {
  align-items: center;
  background: #ffffff;
  border: 1px solid #e5e9f0;
  border-radius: 10px;
  color: #475569;
  cursor: pointer;
  display: flex;
  flex: 0 0 40px;
  font-size: 16px;
  height: 40px;
  justify-content: center;
}

.gx-toggle:hover {
  background: #f5f7fb;
  color: #0f172a;
}

.gx-title {
  color: #0f172a;
  font-size: 16px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Ficha del usuario y su menu */
.gx-user {
  margin-left: auto;
  position: relative;
}

.gx-user .gx-user-chip {
  align-items: center;
  background: #ffffff;
  border: 1px solid #e5e9f0;
  border-radius: 999px;
  color: #0f172a;
  display: flex;
  gap: 10px;
  height: 44px;
  padding: 0 12px 0 5px;
  text-decoration: none;
}

.gx-user .gx-user-chip:hover,
.gx-user .gx-user-chip:focus,
.gx-user.open .gx-user-chip {
  background: #f5f7fb;
  color: #0f172a;
  text-decoration: none;
}

.gx-avatar {
  align-items: center;
  background: #e8edff;
  border-radius: 50%;
  color: #2f4fe0;
  display: flex;
  flex: 0 0 34px;
  font-size: 12px;
  font-weight: 800;
  height: 34px;
  justify-content: center;
}

.gx-user-text {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
  text-align: left;
}

.gx-user-name {
  font-size: 13px;
  font-weight: 700;
}

.gx-user-role {
  color: #64748b;
  font-size: 12px;
}

.gx-caret {
  color: #64748b;
  font-size: 11px;
  transition: transform 0.15s;
}

.gx-user.open .gx-caret {
  transform: rotate(180deg);
}

.gx-user .gx-user-menu {
  border: 1px solid #e5e9f0;
  border-radius: 14px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.14);
  font-family: "Plus Jakarta Sans", "Open Sans", sans-serif;
  margin-top: 8px;
  min-width: 250px;
  padding: 8px;
}

.gx-user-menu > li > a {
  align-items: center;
  border-radius: 10px;
  color: #334155;
  display: flex;
  font-size: 14px;
  font-weight: 600;
  gap: 10px;
  padding: 10px 12px;
}

.gx-user-menu > li > a i {
  color: #64748b;
  text-align: center;
  width: 18px;
}

.gx-user-menu > li > a:hover,
.gx-user-menu > li > a:focus {
  background: #f5f7fb;
  color: #0f172a;
}

.gx-user-menu > li > a.gx-logout,
.gx-user-menu > li > a.gx-logout i {
  color: #dc2626;
}

.gx-user-menu > li > a.gx-logout:hover {
  background: #fef2f2;
}

.gx-user-head {
  border-bottom: 1px solid #eef1f5;
  margin: 0 0 6px;
  padding: 6px 12px 12px;
}

.gx-user-head strong {
  color: #0f172a;
  display: block;
  font-size: 14px;
}

.gx-user-head small {
  color: #64748b;
  font-size: 12px;
}

/* La barra azul de titulo del tema (page-header) no se usa: el titulo va en la cabecera.
   style.css la ocultaba solo con html.fixed, pero en celulares theme.js cambia "fixed" por "scroll" y reaparecia. */
html .page-header {
  display: none;
}

/* Mismo fondo que el contenido hasta el final de la pantalla (en celular el contenedor no llega abajo
   y se veia el gris del body). El login tiene su propio fondo (body.lg-body, mas especifico). */
html body,
html .body,
html .inner-wrapper {
  background-color: #f4f7fb;
}

/* Sin la franja vacia bajo la cabecera: era el espacio del page-header, que esta oculto */
@media only screen and (min-width: 768px) {
  html.fixed .inner-wrapper {
    padding-top: 60px;
  }
}

/* Menu lateral */
html .sidebar-left.gx-sidebar {
  background: #0f172a;
  box-shadow: none;
  font-family: "Plus Jakarta Sans", "Open Sans", sans-serif;
}

.gx-sidebar ul.nav-main {
  margin: 8px 0 0;
}

.gx-sidebar .gx-nav-section {
  color: #94a3b8;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 18px 24px 6px;
  text-transform: uppercase;
  white-space: nowrap;
}

.gx-sidebar ul.nav-main > li > a {
  align-items: center;
  border-radius: 10px;
  color: #cbd5e1;
  display: flex;
  font-size: 14px;
  font-weight: 600;
  gap: 12px;
  margin: 2px 12px;
  min-height: 42px;
  padding: 0 14px;
}

.gx-sidebar ul.nav-main > li > a:hover,
.gx-sidebar ul.nav-main > li > a:focus {
  background: #1e293b;
  color: #ffffff;
}

.gx-sidebar ul.nav-main > li.nav-expanded > a,
.gx-sidebar ul.nav-main > li.nav-active > a {
  background: #2f4fe0;
  box-shadow: none;
  color: #ffffff;
}

.gx-sidebar ul.nav-main li a i {
  color: inherit;
  flex: 0 0 20px;
  font-size: 16px;
  margin: 0;
  width: 20px;
}

/* Menu contraido: solo iconos; al pasar el mouse se despliega (comportamiento del tema) */
@media only screen and (min-width: 768px) {
  html.sidebar-left-collapsed .gx-header .logo-container {
    flex-basis: 73px;
    justify-content: center;
    padding: 0 10px;
  }

  html.sidebar-left-collapsed .gx-header .gx-logo img {
    height: auto;
    width: 52px;
  }

  html.sidebar-left-collapsed.fixed .gx-sidebar .nano {
    background: #0f172a;
    box-shadow: none;
  }

  html.sidebar-left-collapsed .gx-sidebar .gx-nav-section {
    border-top: 1px solid #1e293b;
    font-size: 0;
    margin: 10px 16px 6px;
    padding: 0;
  }

  html.sidebar-left-collapsed .gx-sidebar ul.nav-main > li > a {
    margin: 2px 10px;
    padding: 0 16px;
  }

  html.sidebar-left-collapsed.fixed .gx-sidebar .nano:hover .gx-nav-section {
    border: 0;
    font-size: 11px;
    margin: 0;
    padding: 18px 24px 6px;
  }
}

/* Movil: cabecera oscura con el boton del menu, el logo y la inicial del usuario */
@media only screen and (max-width: 767px) {
  html .header.gx-header {
    background: #0f172a;
    border: 0;
  }

  .gx-header .logo-container {
    background: #0f172a;
    border: 0;
    flex: 1 1 auto;
    padding: 0 0 0 68px;
  }

  .gx-header .logo-container .gx-logo {
    line-height: normal;
  }

  .gx-header .gx-logo img {
    height: 34px;
  }

  .gx-header .toggle-sidebar-left.gx-toggle-movil {
    background: #1e293b;
    border-radius: 12px;
    color: #e2e8f0;
    font-size: 18px;
    height: 44px;
    left: 12px;
    line-height: 44px;
    right: auto;
    top: 8px;
    width: 44px;
  }

  /* el tema la manda a una segunda linea en movil (margin-top: 60px; width: 100%) */
  .gx-header .gx-header-right {
    background: transparent;
    border: 0;
    flex: 0 0 auto;
    height: 100%;
    margin-top: 0;
    padding: 0 12px;
    width: auto;
  }

  .gx-title,
  .gx-user-text,
  .gx-caret {
    display: none;
  }

  .gx-user .gx-user-chip,
  .gx-user .gx-user-chip:hover,
  .gx-user.open .gx-user-chip {
    background: transparent;
    border: 0;
    padding: 0;
  }

  .gx-avatar {
    background: #2f4fe0;
    color: #ffffff;
    flex-basis: 38px;
    height: 38px;
  }
}

/* ===== Modal "Cambiar contraseña" (nav-super.php) ===== */
.gx-modal {
  background: #ffffff;
  border-radius: 24px;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.25);
  color: #0f172a;
  font-family: "Plus Jakarta Sans", "Open Sans", sans-serif;
  margin: 30px auto;
  max-width: 440px;
  overflow: hidden;
  position: relative;
  text-align: left;
}

.gx-modal-head {
  align-items: flex-start;
  border-bottom: 1px solid #eef1f5;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  padding: 22px 24px 16px;
}

.gx-modal-head h3 {
  color: #0f172a;
  font-size: 20px;
  font-weight: 800;
  margin: 0 0 4px;
}

.gx-modal-head p {
  color: #64748b;
  font-size: 13px;
  margin: 0;
}

.gx-close {
  background: transparent;
  border: 0;
  border-radius: 10px;
  color: #334155;
  font-size: 26px;
  line-height: 1;
  padding: 2px 8px;
}

.gx-close:hover {
  background: #f5f7fb;
}

.gx-modal-body {
  padding: 18px 24px 4px;
}

.gx-field {
  margin-bottom: 14px;
}

.gx-field label {
  color: #0f172a;
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 6px;
}

.gx-pass {
  position: relative;
}

.gx-pass input {
  background: #f8fafc;
  border: 1px solid #e5e9f0;
  border-radius: 12px;
  box-sizing: border-box;
  color: #0f172a;
  font-size: 15px;
  height: 46px;
  outline: 0;
  padding: 0 48px 0 14px;
  width: 100%;
}

.gx-pass input:focus {
  background: #ffffff;
  border-color: #2f4fe0;
  box-shadow: 0 0 0 3px rgba(47, 79, 224, 0.12);
}

.gx-eye {
  background: transparent;
  border: 0;
  border-radius: 8px;
  color: #64748b;
  height: 36px;
  position: absolute;
  right: 5px;
  top: 5px;
  width: 36px;
}

.gx-eye:hover {
  background: #eef1f5;
  color: #0f172a;
}

.gx-rules {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  list-style: none;
  margin: 2px 0 0;
  padding: 0;
}

.gx-rules li {
  color: #64748b;
  font-size: 12px;
}

.gx-rules li::before {
  content: "\f111";
  font-family: "Font Awesome 6 Free";
  font-weight: 400;
  margin-right: 6px;
}

.gx-rules li.ok {
  color: #15803d;
}

.gx-rules li.ok::before {
  content: "\f058";
  font-weight: 900;
}

.gx-clave-error {
  background: #fef2f2;
  border-radius: 10px;
  color: #b91c1c;
  font-size: 13px;
  font-weight: 600;
  margin: 14px 0 0;
  padding: 10px 12px;
}

.gx-clave-error:empty {
  display: none;
}

.gx-modal-foot {
  background: #f8fafc;
  border-top: 1px solid #eef1f5;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 18px;
  padding: 16px 24px;
}

.gx-btn {
  align-items: center;
  border: 1px solid transparent;
  border-radius: 10px;
  display: inline-flex;
  font-size: 14px;
  font-weight: 700;
  gap: 8px;
  height: 44px;
  justify-content: center;
  padding: 0 18px;
}

.gx-btn-ghost {
  background: #ffffff;
  border-color: #e5e9f0;
  color: #0f172a;
}

.gx-btn-ghost:hover {
  background: #f5f7fb;
}

.gx-btn-primary {
  background: #2f4fe0;
  box-shadow: 0 6px 16px rgba(47, 79, 224, 0.28);
  color: #ffffff;
}

.gx-btn-primary:hover {
  background: #2541c4;
}

.gx-btn-primary:disabled {
  background: #a5b4f3;
  box-shadow: none;
  cursor: not-allowed;
}

@media only screen and (max-width: 480px) {
  .gx-modal {
    border-radius: 20px;
    margin: 12px;
  }

  .gx-modal-foot .gx-btn {
    flex: 1;
  }
}
