/* Pantalla de login con el estilo Wafer: marco negro, cielo en video con
   textura ASCII, tarjeta de vidrio oscuro, foco arcoíris y botón píldora. */
:root {
  color-scheme: dark;
  --sans: "Inter Tight", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --rainbow: conic-gradient(from 210deg, #ff2d9a, #8a3cff 18%, #2b6bff 38%,
             #19c2ff 50%, #c9d24a 62%, #f2c230 72%, #2b6bff 86%, #ff2d9a);
}
* { box-sizing: border-box; margin: 0; }
html, body { height: 100%; background: #000; color: #fff; }
body {
  font-family: var(--sans); font-size: 13px;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  -webkit-text-size-adjust: 100%;
}
.ac-marco {
  min-height: 100%; height: 100dvh;
  display: flex; flex-direction: column;
  padding: 4px 4px 0;
}
.ac-cielo {
  position: relative; flex: 1; min-height: 0;
  display: grid; place-items: center;
  padding: 16px;
  border-radius: 18px; overflow: hidden; isolation: isolate;
  background: #93aaa6;
}
#ac-video, #ac-ascii {
  position: absolute; inset: 0; width: 100%; height: 100%;
  pointer-events: none;
}
#ac-video { object-fit: cover; filter: saturate(.92) brightness(1.08); z-index: 0; }
#ac-ascii { z-index: 1; }

.ac-card {
  position: relative; z-index: 2;
  width: min(384px, calc(100vw - 28px));
  max-height: 100%; overflow: auto; scrollbar-width: none;
  padding: 29px 40px 0;
  border-radius: 20px;
  text-align: center;
  background: linear-gradient(180deg, rgba(14,18,20,.78) 0%, rgba(10,14,16,.84) 62%, rgba(6,8,9,.9) 100%);
  -webkit-backdrop-filter: blur(22px) saturate(1.2);
  backdrop-filter: blur(22px) saturate(1.2);
  box-shadow: 0 0 0 1px rgba(255,255,255,.07) inset, 0 30px 80px -10px rgba(0,0,0,.55), 0 8px 24px rgba(0,0,0,.3);
  opacity: 0; transform: scale(.94) translateY(10px); filter: blur(10px);
  transition: opacity .7s var(--ease), transform .9s var(--ease), filter .7s var(--ease);
}
.ac-card::-webkit-scrollbar { display: none; }
.listo .ac-card { opacity: 1; transform: none; filter: none; }
.ac-logo {
  width: 45px; height: 45px; margin: 0 auto;
  display: grid; place-items: center;
  border-radius: 11px; background: #000; color: #fff;
}
.ac-logo svg { width: 24px; height: 24px; }
.ac-card h1 {
  margin-top: 24px;
  font-family: "Outfit", var(--sans); font-weight: 300;
  font-size: 30px; line-height: 34px; letter-spacing: -.02em;
}
.ac-sub {
  margin-top: 8px;
  font-family: var(--mono); font-size: 12px; line-height: 18px; color: rgba(255,255,255,.6);
}
.ac-form { margin-top: 26px; display: grid; gap: 14px; text-align: left; }
.ac-campo { display: grid; gap: 6px; }
.ac-campo > span:first-child {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase;
  color: rgba(255,255,255,.55);
}
.ac-clave { position: relative; display: block; }
.ac-campo input {
  width: 100%; height: 40px; padding: 0 12px;
  border: 1px solid rgba(255,255,255,.12); border-radius: 10px;
  background: rgba(0,0,0,.35); color: #fff;
  font: 500 14px/1 var(--sans);
  outline: none;
  transition: border-color .16s var(--ease), background .16s var(--ease);
}
.ac-clave input { padding-right: 58px; }
.ac-campo input:hover { border-color: rgba(255,255,255,.22); }
.ac-campo input:focus {
  border-color: transparent;
  background: linear-gradient(#07090a, #07090a) padding-box, var(--rainbow) border-box;
}
.ac-ver {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  height: 28px; padding: 0 10px; border: 0; border-radius: 999px;
  background: rgba(255,255,255,.08); color: rgba(255,255,255,.75);
  font: 500 11px/1 var(--mono); cursor: pointer;
}
.ac-ver:hover { background: rgba(255,255,255,.14); }
.ac-error {
  min-height: 16px; font-size: 12px; line-height: 16px; color: #ff8f9e; text-align: center;
}
.ac-entrar {
  justify-self: center;
  height: 38px; padding: 0 30px; margin-top: 2px;
  border: 0; border-radius: 999px;
  background: #fff; color: #0b0b0b;
  font: 600 13px/1 var(--sans);
  cursor: pointer;
  transition: transform .2s var(--ease), box-shadow .25s var(--ease), opacity .2s;
}
.ac-entrar:hover { transform: translateY(-1px); box-shadow: 0 8px 24px rgba(255,255,255,.18); }
.ac-entrar:active { transform: scale(.97); }
.ac-entrar:disabled { opacity: .55; cursor: progress; transform: none; box-shadow: none; }
.ac-entrar:focus-visible, .ac-ver:focus-visible { outline: 2px solid #7db7ff; outline-offset: 2px; }
.ac-pie {
  margin-top: 30px; padding-bottom: 16px;
  font-family: var(--mono); font-size: 11px; line-height: 16px; color: rgba(255,255,255,.4);
}
.ac-legal {
  height: 39px; display: grid; place-items: center;
  padding-bottom: env(safe-area-inset-bottom); box-sizing: content-box;
  font-size: 11px; color: rgba(255,255,255,.5);
}
.ac-legal b { color: #fff; font-weight: 600; }
@media (max-width: 520px) {
  .ac-card { padding: 24px 22px 0; border-radius: 18px; }
  .ac-campo input { font-size: 16px; } /* iPhone no hace zoom con 16px */
}
@media (prefers-reduced-motion: reduce) {
  .ac-card { transition: none; filter: none; transform: none; }
}
