/* ===== Planea — Pantallas de autenticación =====
   Reproduce el diseño de assets/js/auth.jsx con HTML/CSS nativo,
   reusando las variables de styles.css. */

.auth-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--bg-subtle);
  background-image: radial-gradient(circle at 1px 1px, rgba(0,0,0,.025) 1px, transparent 0);
  background-size: 22px 22px;
}
[data-theme="dark"] .auth-page {
  background-image: radial-gradient(circle at 1px 1px, rgba(255,255,255,.035) 1px, transparent 0);
}

/* Top bar */
.auth-topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px 28px;
}
.auth-topbar .muted { font-size: 13px; color: var(--text-3); }
.auth-link { color: var(--accent); font-weight: 500; cursor: pointer; text-decoration: none; }
.auth-link:hover { text-decoration: underline; }

/* Logo */
.auth-logo { display: inline-flex; align-items: center; gap: 10px; }
.auth-logo .mark {
  width: 30px; height: 30px; border-radius: 9px; background: var(--accent);
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 2px 8px rgba(59,91,219,.35);
}
.auth-logo .name { font-size: 19px; font-weight: 700; letter-spacing: -.02em; color: var(--text); }

/* Main + card */
.auth-main { flex: 1; display: flex; align-items: center; justify-content: center; padding: 10px 20px 60px; }
.auth-card {
  width: 100%; max-width: 404px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 16px;
  padding: 34px 34px 30px; box-shadow: var(--shadow-md);
}
.auth-card h1 { font-size: 22px; font-weight: 680; margin: 0 0 6px; letter-spacing: -.02em; color: var(--text); }
.auth-sub { margin: 0 0 26px; color: var(--text-3); font-size: 14px; line-height: 1.5; }

/* Fields with leading icon + password eye */
.auth-field { margin-bottom: 16px; }
.auth-field .wrap { position: relative; }
.auth-field .ico { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); pointer-events: none; display: flex; }
.auth-field .input.has-ico { padding-left: 38px; }
.auth-field .input.has-eye { padding-right: 40px; }
.auth-eye {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  border: none; background: transparent; padding: 6px; display: flex;
}

.auth-row-end { display: flex; justify-content: flex-end; margin: -6px 0 18px; }

/* Full-width tall buttons used on auth */
.btn.block { width: 100%; justify-content: center; }
.btn.lg { height: 42px; font-size: 14px; }

/* Divider with "o" */
.auth-divider { display: flex; align-items: center; gap: 12px; margin: 18px 0; }
.auth-divider .line { flex: 1; height: 1px; background: var(--border); }
.auth-divider .word { font-size: 12px; color: var(--text-4); }

/* 6-digit code inputs */
.code-inputs { display: flex; gap: 9px; justify-content: space-between; margin-bottom: 22px; }
.code-box {
  width: 50px; height: 58px; text-align: center; font-size: 24px; font-weight: 600;
  color: var(--text); border: 1.5px solid var(--border-strong); border-radius: 10px;
  outline: none; background: var(--surface); transition: all .12s;
}
.code-box:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.code-box.filled { border-color: var(--accent); background: var(--accent-soft); }

/* Footer */
.auth-foot-link { text-align: center; font-size: 13px; color: var(--text-3); margin: 16px 0 0; }
.auth-foot { text-align: center; padding: 0 0 26px; font-size: 12.5px; color: var(--text-4); }

/* Big success / status circle */
.auth-circle {
  width: 62px; height: 62px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  margin: 6px auto 24px; background: var(--green-soft);
}

/* Alerts */
.alert { border-radius: 9px; padding: 11px 13px; font-size: 13px; line-height: 1.5; margin-bottom: 18px; border: 1px solid transparent; }
.alert--error { background: var(--red-soft); color: var(--red); border-color: color-mix(in srgb, var(--red) 24%, transparent); }
.alert--warn  { background: var(--orange-soft); color: var(--orange); border-color: color-mix(in srgb, var(--orange) 24%, transparent); }
.alert--ok    { background: var(--green-soft); color: var(--green); border-color: color-mix(in srgb, var(--green) 24%, transparent); }
.alert--info  { background: var(--accent-soft); color: var(--accent); border-color: var(--accent-soft-2); }
.alert a { color: inherit; font-weight: 600; text-decoration: underline; }

/* Dev banner (código en pantalla cuando el SMTP aún no está configurado) */
.dev-banner {
  border: 1px dashed var(--accent); background: var(--accent-soft); color: var(--accent);
  border-radius: 9px; padding: 10px 13px; font-size: 13px; margin-bottom: 18px; text-align: center;
}
.dev-banner b { font-size: 16px; letter-spacing: 3px; }

/* Field stack helper */
.auth-field .label { margin-bottom: 6px; }
