/* Pantallas de acceso (login, recuperar/restablecer/crear contraseña y
   consentimiento OAuth). Diseño corporativo windUP · PulseUp: fondo negro,
   foto de marca a la izquierda y la tarjeta del formulario a la derecha.

   Medidas y colores tomados del diseño (lienzo de 1334px): tarjeta #242424 de
   619px con 36px de relleno, campos #3f3f3f de 38px con borde amarillo
   atenuado y botón píldora #fac713. */

@font-face {
  font-family: "Work Sans";
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  src: url("/static/fonts/WorkSans-Regular.woff2") format("woff2");
}
@font-face {
  font-family: "Work Sans";
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  src: url("/static/fonts/WorkSans-Bold.woff2") format("woff2");
}

:root {
  --ac-bg: #000000;
  --ac-card: #242424;
  --ac-input: #3f3f3f;
  --ac-border: rgba(250, 199, 19, 0.55);   /* el #a98919 del diseño sobre la tarjeta */
  --ac-accent: #fac713;
  --ac-accent-ink: #1c1c30;
  --ac-text: #ffffff;
  --ac-muted: #a3a3a3;
  --ac-placeholder: #9a9a9a;               /* más claro que en el diseño: legible sobre #3f3f3f */
  --ac-red: #ff8080;
  --ac-ok: #7ee2a8;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body.acceso {
  margin: 0;
  min-height: 100vh;
  background: var(--ac-bg);
  color: var(--ac-text);
  font-family: "Work Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 15px;
  line-height: 1.45;
  overflow-x: hidden;
  position: relative;
}

/* ─── Decoración (no recibe clics ni la leen los lectores de pantalla) ───── */
.acceso-deco { position: absolute; pointer-events: none; user-select: none; z-index: 0; }
.acceso-degradado {
  left: 0; bottom: 0;
  width: clamp(260px, 31vw, 420px);
  /* La imagen es una mancha que se desvanece hacia arriba y a la derecha: se
     ancla abajo a la izquierda y asoma por detrás de la foto hasta media
     altura, como en el diseño. */
  transform: translate(-20%, 15%);
}
.acceso-mancha {
  /* Las órbitas ocupan ~60% de la imagen: a 370px miden lo que en el diseño
     (~225px), centradas cerca de la esquina inferior derecha. */
  right: 0; bottom: 0;
  width: clamp(220px, 27vw, 370px);
}

/* ─── Composición ──────────────────────────────────────────────────────── */
.acceso-layout {
  position: relative; z-index: 1;
  min-height: 100vh;
  /* 390 (foto) + 98 (hueco) + 619 (tarjeta) como en el diseño, más el relleno. */
  max-width: 1210px;
  margin: 0 auto;
  padding: clamp(32px, 9vh, 85px) clamp(20px, 5vw, 48px);
  display: grid;
  grid-template-columns: minmax(280px, 390px) minmax(0, 619px);
  justify-content: center;
  align-items: start;
  column-gap: clamp(40px, 7vw, 98px);
}

.acceso-foto {
  margin: 0;
  align-self: stretch;
  max-height: 660px;
  border-radius: 22px;
  overflow: hidden;
}
.acceso-foto img {
  display: block; width: 100%; height: 100%;
  min-height: 520px; max-height: 660px;
  object-fit: cover; object-position: center;
}

.acceso-panel { display: flex; flex-direction: column; }

.acceso-marcas {
  display: flex; align-items: center; gap: 26px;
  padding-left: 36px;               /* alineadas con el contenido de la tarjeta */
  margin-bottom: 46px;
}
.acceso-marcas img { display: block; height: auto; }
.acceso-marcas .logo-windup { width: 133px; }
.acceso-marcas .logo-pulseup { width: 133px; }

/* ─── Tarjeta ─────────────────────────────────────────────────────────── */
.acceso-card {
  background: var(--ac-card);
  border: 1px solid var(--ac-accent);   /* marco amarillo de 1px, petición de diseño */
  border-radius: 6px;
  padding: 32px 36px 36px;
}
.acceso-card h1 {
  margin: 0 0 22px;
  font-size: clamp(25px, 3vw, 40px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
}
.acceso-card .sub {
  margin: -10px 0 22px;
  color: var(--ac-muted);
  font-size: 14px;
}
.acceso-card .sub b { color: var(--ac-text); }

.acceso-card form { margin: 0; }
.campo { max-width: 464px; margin-bottom: 18px; }
.campo label {
  display: block; margin: 0 0 8px;
  font-size: 15px; color: var(--ac-text);
}
.campo input {
  width: 100%; height: 38px; padding: 0 10px;
  background: var(--ac-input);
  border: 1px solid var(--ac-border);
  border-radius: 4px;
  color: var(--ac-text);
  font: inherit; font-size: 14px;
}
.campo input::placeholder { color: var(--ac-placeholder); font-size: 13px; }
.campo input:focus {
  outline: none;
  border-color: var(--ac-accent);
  box-shadow: 0 0 0 3px rgba(250, 199, 19, 0.25);
}
.campo .hint { margin-top: 6px; font-size: 12px; color: var(--ac-muted); }

.recordarme {
  display: inline-flex; align-items: center; gap: 9px;
  margin: 2px 0 22px;
  font-size: 13.5px; color: var(--ac-muted); cursor: pointer;
}
.recordarme input {
  width: 16px; height: 16px; margin: 0;
  accent-color: var(--ac-accent);
}

/* ─── Acciones ────────────────────────────────────────────────────────── */
.acciones {
  display: flex; align-items: center; flex-wrap: wrap; gap: 14px 24px;
  margin-top: 8px;
}
.btn-acceso {
  display: inline-flex; align-items: center; gap: 10px;
  height: 43px; padding: 0 20px;
  border: 0; border-radius: 999px;
  background: var(--ac-accent); color: var(--ac-accent-ink);
  font: inherit; font-size: 18px; font-weight: 400;
  cursor: pointer; text-decoration: none;
  transition: filter .15s ease, transform .15s ease;
}
.btn-acceso:hover { filter: brightness(1.06); }
.btn-acceso:active { transform: translateY(1px); }
.btn-acceso:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.btn-acceso svg { width: 18px; height: 18px; flex: 0 0 auto; }
.btn-acceso.secundario {
  background: transparent; color: var(--ac-text);
  border: 1px solid #5a5a5a;
}

.enlace {
  color: var(--ac-muted); font-size: 13.5px;
  text-decoration: underline; text-underline-offset: 3px;
}
.enlace:hover, .enlace:focus-visible { color: var(--ac-text); }

/* ─── Avisos ──────────────────────────────────────────────────────────── */
.error, .aviso, .ok {
  max-width: 464px;
  margin: 0 0 18px; padding: 10px 12px;
  border-radius: 4px; font-size: 13.5px;
}
.error { background: rgba(224, 68, 68, 0.14); border: 1px solid rgba(255, 128, 128, 0.45); color: var(--ac-red); }
.aviso { background: rgba(250, 199, 19, 0.10); border: 1px solid var(--ac-border); color: var(--ac-text); }
.ok    { background: rgba(46, 160, 98, 0.14); border: 1px solid rgba(126, 226, 168, 0.45); color: var(--ac-ok); }

/* ─── Consentimiento OAuth ────────────────────────────────────────────── */
.quien {
  max-width: 464px; margin: 0 0 18px; padding: 14px 16px;
  background: var(--ac-input); border-radius: 4px; font-size: 14px;
}
.quien b { display: block; font-size: 15px; margin-bottom: 2px; }
.quien span { color: var(--ac-muted); font-size: 13px; }
.quien span b { display: inline; font-size: 13px; color: var(--ac-text); }
.permisos { max-width: 464px; margin: 0 0 18px; padding: 0; list-style: none; }
.permisos li {
  position: relative; padding: 8px 0 8px 22px;
  font-size: 13.5px; border-bottom: 1px solid #3a3a3a;
}
.permisos li:last-child { border-bottom: 0; }
.permisos li::before { content: "•"; position: absolute; left: 6px; color: var(--ac-accent); font-weight: 700; }
.pie { margin: 18px 0 0; color: var(--ac-muted); font-size: 12.5px; }

/* ─── Móvil y tabletas: sin foto, la tarjeta a todo el ancho ───────────── */
@media (max-width: 900px) {
  .acceso-layout {
    grid-template-columns: minmax(0, 560px);
    padding-top: 40px; padding-bottom: 140px;
  }
  .acceso-foto { display: none; }
  .acceso-marcas { padding-left: 0; justify-content: center; margin-bottom: 28px; }
  .acceso-card { padding: 26px 22px 28px; }
  .campo, .error, .aviso, .ok, .quien, .permisos { max-width: none; }
  .acceso-mancha { width: 200px; opacity: .85; }
  .acceso-degradado { width: 220px; }
}
@media (max-width: 420px) {
  .acceso-marcas { gap: 18px; }
  .acceso-marcas .logo-windup, .acceso-marcas .logo-pulseup { width: 112px; }
  .acciones { flex-direction: column; align-items: stretch; }
  .btn-acceso { justify-content: center; }
  .enlace { text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  .btn-acceso { transition: none; }
}
