/* auth.css — one-screen sign-in (Wave B). Tokens from app.css; phone-first. */
body.login-cinematic {
  margin: 0;
  font-family: var(--font-body, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif);
  color: #e2e8f0;
  background:
    linear-gradient(rgba(7, 11, 22, 0.78), rgba(7, 11, 22, 0.92)),
    url('/assets/ui/hero/login-hero.jpg') center / cover no-repeat fixed,
    #070b14;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: max(14px, env(safe-area-inset-top, 14px)) 14px max(24px, env(safe-area-inset-bottom, 24px));
  box-sizing: border-box;
}
@media (min-height: 760px) { body.login-cinematic { align-items: center; } }
.auth-card {
  width: 100%;
  max-width: 400px;
  background: rgba(15, 23, 35, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 22px 20px 18px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  box-sizing: border-box;
}
.auth-studio { font-family: var(--font-display, Rajdhani, system-ui, sans-serif); font-size: 0.66rem; font-weight: 700; letter-spacing: 0.32em; color: #94a3b8; text-align: center; }
.auth-title { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 6px 0 2px; font-family: var(--font-display, Rajdhani, system-ui, sans-serif); font-weight: 800; font-size: 1.35rem; letter-spacing: 0.06em; color: #fbbf24; }
.auth-purpose { text-align: center; color: #94a3b8; font-size: 0.86rem; margin: 0 0 16px; line-height: 1.4; }
.auth-error { display: none; margin: 0 0 12px; padding: 10px 12px; border-radius: 10px; background: rgba(239, 68, 68, 0.12); border: 1px solid rgba(239, 68, 68, 0.4); color: #fca5a5; font-size: 0.82rem; line-height: 1.4; }
.auth-error.is-visible { display: block; }
.auth-stack { display: flex; flex-direction: column; gap: 10px; }
.auth-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%; min-height: 48px; padding: 10px 14px;
  border-radius: 12px; border: 1px solid rgba(255, 255, 255, 0.12);
  background: #fff; color: #0f172a;
  font: 700 0.95rem/1 var(--font-body, system-ui, sans-serif);
  cursor: pointer; text-decoration: none;
  transition: transform 120ms ease, filter 120ms ease;
  -webkit-tap-highlight-color: transparent;
}
.auth-btn:active { transform: scale(0.99); }
.auth-btn:focus-visible { outline: 2px solid #fbbf24; outline-offset: 2px; }
.auth-btn[hidden] { display: none; }
.auth-btn--apple { background: #000; color: #fff; border-color: rgba(255, 255, 255, 0.25); }
.auth-btn--passkey { background: linear-gradient(180deg, #2dd4bf, #14b8a6); color: #042f2e; }
.auth-btn--primary { background: linear-gradient(180deg, #fbbf24 0%, #d97706 100%); color: #1f1404; font-family: var(--font-display, Rajdhani, system-ui, sans-serif); font-size: 1rem; letter-spacing: 0.04em; }
.auth-btn--ghost { background: transparent; color: #e2e8f0; border-color: rgba(255, 255, 255, 0.18); }
.auth-btn svg { width: 20px; height: 20px; flex: 0 0 auto; }
.auth-btn:disabled { opacity: 0.55; cursor: progress; }
.auth-divider { position: relative; text-align: center; margin: 16px 0 10px; font-size: 0.74rem; color: #64748b; }
.auth-divider::before { content: ''; position: absolute; left: 0; right: 0; top: 50%; height: 1px; background: rgba(255, 255, 255, 0.08); }
.auth-divider span { position: relative; padding: 0 10px; background: rgba(15, 23, 35, 0.94); }
.auth-field { display: flex; gap: 8px; }
.auth-input {
  flex: 1; min-width: 0; min-height: 48px; padding: 10px 12px;
  background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.12); border-radius: 12px;
  color: #e2e8f0; font-size: max(16px, 1rem); outline: none; box-sizing: border-box;
}
.auth-input:focus { border-color: #fbbf24; }
.auth-step { display: none; }
.auth-step.is-active { display: block; }
.auth-sent { color: #94a3b8; font-size: 0.84rem; margin: 0 0 10px; line-height: 1.45; text-align: center; }
.auth-sent b { color: #e2e8f0; }
.auth-code { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; margin: 4px 0 10px; }
.auth-code input {
  min-height: 54px; width: 100%; text-align: center; font: 800 1.4rem/1 var(--font-display, Rajdhani, system-ui, sans-serif);
  letter-spacing: 0; background: rgba(255, 255, 255, 0.05); border: 1px solid rgba(255, 255, 255, 0.14); border-radius: 12px; color: #fbbf24; outline: none; box-sizing: border-box;
  font-variant-numeric: tabular-nums;
}
.auth-code input:focus { border-color: #fbbf24; }
.auth-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 16px; margin: 6px 0 0; font-size: 0.8rem; }
.auth-link { color: #94a3b8; background: none; border: none; padding: 8px 4px; font: inherit; font-size: 0.8rem; text-decoration: underline; text-decoration-color: rgba(251, 191, 36, 0.4); text-underline-offset: 3px; cursor: pointer; min-height: 32px; }
.auth-link:hover, .auth-link:focus-visible { color: #e2e8f0; }
.auth-consent { display: flex; gap: 10px; align-items: flex-start; text-align: left; font-size: 0.8rem; color: #94a3b8; line-height: 1.45; margin: 4px 0 10px; }
.auth-consent input { margin-top: 3px; flex: 0 0 auto; width: 18px; height: 18px; }
.auth-consent a { color: #fbbf24; text-decoration: none; }
.auth-sim { margin: 14px 0 0; text-align: center; font-size: 0.72rem; color: #fb923c; line-height: 1.4; }
.auth-foot { margin-top: 14px; padding-top: 10px; border-top: 1px solid rgba(255, 255, 255, 0.08); color: #64748b; font-size: 0.68rem; line-height: 1.5; text-align: center; }
.auth-foot a { color: #94a3b8; text-decoration: underline; }
.auth-guest { text-align: center; margin: 12px 0 0; }
.auth-guest a { color: #2dd4bf; font-family: var(--font-display, Rajdhani, system-ui, sans-serif); font-weight: 800; font-size: 0.86rem; letter-spacing: 0.04em; text-decoration: none; }
.auth-legacy { margin-top: 12px; }
.auth-legacy summary { cursor: pointer; color: #94a3b8; font-size: 0.8rem; text-align: center; list-style: none; padding: 8px; }
.auth-legacy summary::-webkit-details-marker { display: none; }
.auth-legacy form { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.auth-legacy .auth-input { width: 100%; }
.auth-msg { min-height: 18px; margin: 8px 0 0; font-size: 0.8rem; text-align: center; color: #fca5a5; }
.auth-msg.ok { color: #10b981; }
/* Guest merge sheet */
.auth-sheet { position: fixed; inset: 0; background: rgba(0, 0, 0, 0.72); display: none; align-items: flex-end; justify-content: center; z-index: 50; padding: 12px; }
.auth-sheet.is-open { display: flex; }
.auth-sheet-card { width: 100%; max-width: 420px; background: #0f1723; border: 1px solid rgba(45, 212, 191, 0.35); border-radius: 18px; padding: 20px 18px max(18px, env(safe-area-inset-bottom, 18px)); box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.6); }
.auth-sheet h2 { margin: 0 0 6px; font-family: var(--font-display, Rajdhani, system-ui, sans-serif); font-size: 1.15rem; letter-spacing: 0.04em; color: #fbbf24; }
.auth-sheet p { margin: 0 0 14px; color: #cbd5e1; font-size: 0.9rem; line-height: 1.45; }
.auth-sheet-carry { display: flex; gap: 8px; margin: 0 0 14px; }
.auth-sheet-carry div { flex: 1; text-align: center; background: rgba(255, 255, 255, 0.04); border-radius: 12px; padding: 10px 6px; }
.auth-sheet-carry b { display: block; font-family: var(--font-display, Rajdhani, system-ui, sans-serif); font-size: 1.3rem; color: #e2e8f0; }
.auth-sheet-carry span { font-size: 0.66rem; letter-spacing: 0.08em; text-transform: uppercase; color: #94a3b8; }
@media (prefers-reduced-motion: reduce) { .auth-btn { transition: none; } }
