
:root {
  --fondo: #071020;
  --tarjeta: #101d33;
  --linea: rgba(112, 163, 236, .18);
  --texto: #f3f8ff;
  --suave: #9eb2cd;
  --azul: #3d9aff;
  --cian: #69d8ff;
  --verde: #53dfac;
  --sombra: 0 25px 65px rgba(0, 0, 0, .24);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--texto);
  background: var(--fondo);
  font: 15px/1.6 system-ui, -apple-system,
    "Segoe UI", Arial, sans-serif;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  opacity: .52;
  cursor: not-allowed;
}

a {
  color: inherit;
  text-decoration: none;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

[hidden] {
  display: none !important;
}

.contenedor {
  width: min(1160px, calc(100% - 40px));
  margin: auto;
}

/* ===================================
   FONDO TORMENTA PREMIUM
=================================== */

.storm {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;

  background:
    radial-gradient(
      ellipse 60% 45% at 80% 15%,
      rgba(24, 93, 165, .22),
      transparent 74%
    ),
    radial-gradient(
      ellipse 50% 50% at 2% 44%,
      rgba(24, 73, 143, .16),
      transparent 80%
    ),
    linear-gradient(
      180deg,
      #071020,
      #091426 62%,
      #071020
    );
}

.storm::after {
  content: "";
  position: absolute;
  inset: 0;

  background-image:
    linear-gradient(
      rgba(105,216,255,.025) 1px,
      transparent 1px
    ),
    linear-gradient(
      90deg,
      rgba(105,216,255,.025) 1px,
      transparent 1px
    );

  background-size: 48px 48px;

  mask-image: linear-gradient(
    to bottom,
    transparent,
    #000 35%,
    transparent 96%
  );
}

.flash {
  position: absolute;
  inset: 0;
  opacity: 0;

  background: radial-gradient(
    ellipse 60% 45% at 75% 8%,
    rgba(100,165,255,.18),
    transparent 65%
  );

  animation: destello 16s infinite;
}

@keyframes destello {
  0%, 84%, 86%, 88%, 100% {
    opacity: 0;
  }

  85%, 87% {
    opacity: 1;
  }
}

main,
.pie {
  position: relative;
  z-index: 1;
}

/* ===================================
   ENCABEZADO
=================================== */

.encabezado {
  position: sticky;
  top: 0;
  z-index: 5;

  background: rgba(6,15,30,.88);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--linea);
}

.barra-superior {
  min-height: 88px;

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.marca {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.marca-icono,
.mini-icono {
  display: grid;
  place-items: center;

  font-weight: 900;
  background: linear-gradient(
    145deg,
    #2579ed,
    #69d8ff
  );

  box-shadow:
    0 10px 30px rgba(36,135,250,.28);

  border-radius: 13px;
  color: #fff;
}

.marca-icono {
  width: 45px;
  height: 45px;
  font-size: 26px;
}

.marca strong {
  font-size: 17px;
  letter-spacing: .065em;
  display: block;
  line-height: 1.2;
  white-space: nowrap;
}

.marca em {
  font-style: normal;
  color: var(--cian);
}

.marca small {
  display: block;
  font-size: 10px;
  letter-spacing: .15em;
  color: var(--suave);
  margin-top: 5px;
}

.navegacion {
  display: flex;
  align-items: center;
  gap: 24px;
}

.navegacion a {
  color: #b9c9e0;
  font-weight: 600;
  font-size: 13px;
}

/* ===================================
   BOTONES
=================================== */

.boton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;

  border: 1px solid transparent;
  border-radius: 12px;
  padding: 12px 20px;
  min-height: 46px;

  color: white;
  font-weight: 750;

  transition:
    transform .2s,
    background .2s,
    box-shadow .2s;
}

.boton:hover:not(:disabled) {
  transform: translateY(-2px);
}

.boton-primario {
  background: linear-gradient(
    110deg,
    #1f70ec,
    #35a8ff
  );

  box-shadow:
    0 10px 27px rgba(27,113,242,.26);
}

.boton-borde {
  background: rgba(22,49,86,.45);
  border-color: rgba(92,162,255,.34);
}

.boton-peligro {
  background: rgba(143,39,69,.24);
  border-color: rgba(241,116,140,.32);
  color: #ffc1cb;
}

.boton-ancho {
  width: 100%;
}

/* ===================================
   PORTADA PRINCIPAL
=================================== */

.portada {
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  align-items: center;
  gap: 58px;

  min-height: 600px;
  padding-top: 70px;
  padding-bottom: 80px;
}

.etiqueta {
  display: inline-flex;
  align-items: center;
  gap: 10px;

  background: rgba(43,115,195,.15);
  border: 1px solid rgba(94,170,255,.24);
  border-radius: 99px;

  color: #b9dfff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .16em;
  padding: 8px 13px;
}

.pulso,
.punto-azul {
  width: 8px;
  height: 8px;

  background: var(--verde);
  border-radius: 50%;

  box-shadow:
    0 0 15px rgba(83,223,172,.45);
}

.portada h1 {
  font-size: clamp(40px, 4.5vw, 70px);
  line-height: 1.12;
  letter-spacing: -.045em;
  margin: 25px 0;
}

.portada h1 span,
.acceso-presentacion h2 span {
  background: linear-gradient(
    95deg,
    #67d8ff,
    #5894ff
  );

  color: transparent;
  background-clip: text;
}

.subtitulo {
  color: var(--suave);
  font-size: 17px;
  line-height: 1.8;
  max-width: 580px;
}

.acciones-portada {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin: 34px 0;
}

.franja-confianza {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;

  color: #9bb5d4;
  font-size: 12px;
}

/* ===================================
   VISTA PREVIA TECNOLÓGICA
=================================== */

.vista-previa {
  background: linear-gradient(
    150deg,
    rgba(26,58,103,.78),
    rgba(10,24,45,.96)
  );

  border: 1px solid rgba(109,181,255,.23);
  border-radius: 26px;
  padding: 25px;

  box-shadow: var(--sombra);
  position: relative;
  overflow: hidden;
}

.vista-encabezado,
.vista-pie {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  gap: 10px;
}

.vista-encabezado > div {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
}

.mini-icono {
  width: 30px;
  height: 30px;
  border-radius: 9px;
}

.etiqueta-chica {
  font-size: 9px;
  font-weight: 800;
  color: #9abbdc;

  background: rgba(116,159,219,.13);
  border: 1px solid var(--linea);
  padding: 6px 9px;
  border-radius: 8px;
}

.vista-centro {
  height: 225px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;

  position: relative;
  text-align: center;
}

.orbita {
  font-size: 115px;
  line-height: 1;
  color: #56b8ff;

  filter: drop-shadow(
    0 0 25px rgba(63,166,250,.32)
  );
}

.vista-centro p {
  margin: 14px 0 0;
  color: #a8c8e8;
  font-size: 13px;
}

.vista-tarjetas {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.vista-tarjetas > div {
  background: rgba(5,17,35,.64);
  border: 1px solid var(--linea);
  border-radius: 12px;
  padding: 15px 10px;
}

.vista-tarjetas span,
.vista-tarjetas strong,
.vista-tarjetas small {
  display: block;
}

.vista-tarjetas span {
  font-size: 20px;
}

.vista-tarjetas strong {
  font-size: 12px;
  margin: 8px 0 4px;
}

.vista-tarjetas small {
  color: var(--suave);
  font-size: 10px;
}

.vista-pie {
  justify-content: flex-start;
  border-top: 1px solid var(--linea);
  padding-top: 18px;
  margin-top: 22px;

  color: #b9d1eb;
  font-size: 12px;
}

/* ===================================
   FUNCIONES
=================================== */

.seccion-funciones {
  padding: 25px 0 90px;
}

.seccion-titulo {
  text-align: center;
  max-width: 700px;
  margin: auto auto 30px;
}

.superindice {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .18em;
  color: #6fbfff;
}

.seccion-titulo h2 {
  font-size: clamp(27px, 3vw, 39px);
  margin: 10px 0;
}

.seccion-titulo p {
  color: var(--suave);
}

.cuadricula-funciones {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.tarjeta-funcion,
.panel-card,
.tarjeta-acceso {
  background: linear-gradient(
    160deg,
    rgba(22,41,72,.95),
    rgba(11,25,47,.97)
  );

  border: 1px solid var(--linea);
  border-radius: 19px;

  box-shadow:
    0 12px 35px rgba(0,0,0,.12);
}

.tarjeta-funcion {
  padding: 26px;
  min-height: 210px;
}

.icono-funcion {
  display: grid;
  place-items: center;

  width: 49px;
  height: 49px;

  background: rgba(38,128,243,.15);
  border: 1px solid rgba(96,166,255,.22);
  border-radius: 12px;
  font-size: 24px;
}

.tarjeta-funcion h3 {
  margin: 20px 0 8px;
  font-size: 17px;
}

.tarjeta-funcion p {
  color: var(--suave);
  font-size: 13px;
}

/* ===================================
   ACCESO Y REGISTRO
=================================== */

.acceso-seccion {
  display: grid;
  grid-template-columns: 1fr 430px;
  gap: 70px;
  align-items: center;
  padding: 30px 0 110px;
}

.acceso-presentacion h2 {
  font-size: clamp(35px, 4vw, 56px);
  line-height: 1.15;
  margin: 16px 0;
}

.acceso-presentacion p {
  max-width: 440px;
  color: var(--suave);
  font-size: 16px;
}

.acceso-sello {
  margin-top: 25px;
  display: inline-block;
  font-size: 12px;
  color: #b8cee6;

  padding: 10px 14px;
  border: 1px solid var(--linea);
  border-radius: 10px;
}

.tarjeta-acceso {
  padding: 32px;
}

.tarjeta-acceso h2 {
  font-size: 25px;
  margin-bottom: 8px;
}

.tarjeta-acceso p {
  color: var(--suave);
}

label {
  display: block;
  color: #d2e4fb;
  font-size: 12px;
  font-weight: 700;
  margin: 18px 0 7px;
}

input,
select {
  width: 100%;
  border: 1px solid rgba(120,167,221,.3);
  border-radius: 10px;
  background: #09182e;
  color: #f4f8ff;
  padding: 12px 14px;
  outline: none;
}

input:focus,
select:focus {
  border-color: #4fafff;
  box-shadow:
    0 0 0 3px rgba(58,157,255,.13);
}

.tarjeta-acceso form .boton {
  margin-top: 22px;
}

.texto-cambio {
  text-align: center;
  font-size: 13px;
  margin-top: 19px;
}

.enlace-boton {
  border: 0;
  background: none;
  color: #7cc7ff;
  font-weight: 800;
  cursor: pointer;
  padding: 0;
}

.mensaje {
  min-height: 1em;
  margin-top: 12px;
  color: #8ce6b3;
  font-size: 13px;
  overflow-wrap: anywhere;
}

.mensaje.error {
  color: #ff9cab;
}

/* ===================================
   DASHBOARD
=================================== */

.dashboard {
  padding: 55px 0 90px;
  min-height: 70vh;
}

.dashboard-bienvenida {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  margin-bottom: 28px;
}

.dashboard-bienvenida h1 {
  font-size: clamp(27px, 3.2vw, 43px);
  margin: 9px 0;
}

.dashboard-bienvenida p {
  color: var(--suave);
  margin: 0;
}

.panel-card {
  padding: 25px;
  margin-bottom: 19px;
}

.titulo-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.titulo-panel h2 {
  margin: 5px 0 0;
  font-size: 21px;
}

.panel-card p {
  color: var(--suave);
}

/* ===================================
   TARJETAS DE ESTADÍSTICAS
=================================== */

.cuadricula-resumen {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin: 20px 0 24px;
}

.cifra {
  background: linear-gradient(
    145deg,
    #102440,
    #0c1b33
  );

  border: 1px solid var(--linea);
  padding: 20px;
  border-radius: 15px;
  min-width: 0;
}

.cifra > span {
  color: #a4bcd7;
  font-size: 12px;
  display: block;
}

.cifra > strong {
  display: block;
  font-size: 31px;
  margin-top: 10px;
  color: #8ed3ff;
}

.cifra > strong.texto-metrica {
  font-size: 17px;
  overflow-wrap: anywhere;
}

.cuadricula-panel {
  display: grid;
  grid-template-columns: repeat(
    2,
    minmax(0, 1fr)
  );
  gap: 18px;
}

.cuadricula-panel .panel-card {
  margin: 0;
}

.info-panel {
  background: #09182b;
  border: 1px solid rgba(110,161,227,.16);
  border-radius: 12px;

  padding: 16px;
  margin: 16px 0;
}

.info-panel h3 {
  margin: 0 0 10px;
  font-size: 17px;
}

.info-panel p {
  margin: 8px 0;
  font-size: 13px;
}

.codigo-admin {
  font-size: clamp(23px, 3vw, 34px);
  letter-spacing: .12em;
  color: #86e6b4;
  overflow-wrap: anywhere;
}

#waQr {
  display: block;
  max-width: 100%;
  background: white;
  border-radius: 12px;
  padding: 10px;
  margin: 12px auto;
}

/* ===================================
   COMANDOS
=================================== */

.lista-comandos > div {
  display: flex;
  justify-content: space-between;
  align-items: center;

  border-bottom: 1px solid var(--linea);
  padding: 10px 0;
  gap: 14px;
}

.lista-comandos > div:last-child {
  border: 0;
}

.lista-comandos span {
  font-size: 12px;
  color: var(--suave);
  text-align: right;
}

.lista-comandos code {
  font-size: 12px;
  color: #98d5ff;
  overflow-wrap: anywhere;
}

.nota {
  font-size: 12px;
  border-top: 1px solid var(--linea);
  padding-top: 12px;
}

/* ===================================
   PANEL ADMINISTRADOR
=================================== */

.lista-clientes {
  display: grid;

  grid-template-columns: repeat(
    auto-fit,
    minmax(min(100%, 300px), 1fr)
  );

  gap: 16px;
}

.cliente {
  background: #08182e;
  border: 1px solid var(--linea);
  border-radius: 14px;
  padding: 19px;
  overflow-wrap: anywhere;
}

.cliente > strong {
  display: block;
  color: #a3d6ff;
}

.cliente p {
  font-size: 13px;
}

.estado {
  display: inline-block;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 750;
  padding: 5px 10px;
  background: #263b56;
}

.estado.activo {
  color: #7fe3b1;
  background: #124d3b;
}

.estado.pendiente {
  color: #ffdb91;
  background: #614821;
}

.estado.suspendido {
  color: #ffb5bd;
  background: #612b3a;
}

.licencia {
  border-top: 1px solid var(--linea);
  margin-top: 18px;
  padding-top: 12px;
}

.licencia h3 {
  font-size: 16px;
}

.licencia select,
.licencia .boton {
  margin-top: 10px;
  width: 100%;
}

/* ===================================
   PIE DE PÁGINA
=================================== */

.pie {
  background: rgba(3,11,24,.68);
  border-top: 1px solid var(--linea);
  padding: 32px 0;
  text-align: center;
}

.pie .contenedor {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 18px;
  align-items: center;
}

.pie strong {
  font-size: 12px;
}

.pie span,
.pie small {
  font-size: 11px;
  color: var(--suave);
}

/* ===================================
   RESPONSIVE - TABLET
=================================== */

@media (max-width: 950px) {

  .portada {
    gap: 30px;
  }

  .cuadricula-funciones {
    grid-template-columns: repeat(2, 1fr);
  }

  .acceso-seccion {
    grid-template-columns: 1fr 410px;
    gap: 30px;
  }
}

/* ===================================
   RESPONSIVE - MÓVIL
=================================== */

@media (max-width: 760px) {

  .barra-superior {
    min-height: 78px;
  }

  .navegacion a {
    display: none;
  }

  .marca strong {
    font-size: 14px;
  }

  .marca small {
    font-size: 8px;
  }

  .portada {
    grid-template-columns: 1fr;
    min-height: 0;
    padding-top: 55px;
  }

  .portada h1 {
    font-size: clamp(38px, 9vw, 58px);
  }

  .vista-previa {
    max-width: 540px;
    width: 100%;
    margin: auto;
  }

  .acceso-seccion {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .cuadricula-panel {
    grid-template-columns: 1fr;
  }

  .dashboard-bienvenida {
    align-items: flex-start;
  }

  .cuadricula-resumen {
    grid-template-columns: 1fr 1fr;
  }

  .cuadricula-resumen .cifra:last-child {
    grid-column: 1 / -1;
  }
}

/* ===================================
   RESPONSIVE - TELÉFONO PEQUEÑO
=================================== */

@media (max-width: 500px) {

  .contenedor {
    width: calc(100% - 28px);
  }

  .marca-icono {
    width: 39px;
    height: 39px;
  }

  .marca strong {
    font-size: 12px;
  }

  .navegacion {
    gap: 0;
  }

  .navegacion .boton {
    font-size: 11px;
    padding: 8px 10px;
    min-height: 38px;
  }

  .acciones-portada .boton {
    width: 100%;
  }

  .franja-confianza {
    gap: 8px 15px;
  }

  .vista-tarjetas {
    gap: 6px;
  }

  .vista-tarjetas > div {
    padding: 12px 7px;
  }

  .vista-tarjetas small {
    font-size: 9px;
  }

  .cuadricula-funciones {
    grid-template-columns: 1fr;
  }

  .tarjeta-acceso {
    padding: 24px;
  }

  .dashboard-bienvenida {
    flex-direction: column;
  }

  .cuadricula-resumen {
    grid-template-columns: 1fr;
  }

  .cuadricula-resumen .cifra:last-child {
    grid-column: auto;
  }

  .panel-card {
    padding: 19px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
