/* ============================================
   AUTH — Login & Register · iOS Premium Style
   ============================================ */

.auth-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  position: relative;
  overflow-y: auto;
}

/* ── Full-bleed two-panel layout on desktop ── */
.auth-layout {
  display: flex;
  width: 100%;
  max-width: 960px;
  min-height: 600px;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl), 0 0 0 1px var(--card-border);
  position: relative;
  z-index: 1;
}

/* ── Left: branding panel (desktop only) ── */
.auth-brand-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 48px 44px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(145deg, #0A1628 0%, #0D2044 50%, #0A1628 100%);
}

.auth-brand-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(0, 122, 255, 0.35) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 80%, rgba(94, 92, 230, 0.25) 0%, transparent 55%);
  pointer-events: none;
}

.auth-brand-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,122,255,0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,122,255,0.06) 1px, transparent 1px);
  background-size: 40px 40px;
  pointer-events: none;
}

.auth-brand-content {
  position: relative;
  z-index: 1;
}

.auth-brand-icon {
  width: 64px; height: 64px;
  background: linear-gradient(135deg, var(--blue), var(--purple));
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 32px rgba(0, 122, 255, 0.45);
  margin-bottom: 24px;
}

.auth-brand-icon svg { width: 32px; height: 32px; color: #fff; }

.auth-brand-name {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: #fff;
  margin-bottom: 8px;
}

.auth-brand-name span { color: var(--blue); }

.auth-brand-tagline {
  font-size: 15px;
  color: rgba(255,255,255,0.55);
  line-height: 1.6;
  margin-bottom: 32px;
}

.auth-brand-features {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-brand-feature {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  color: rgba(255,255,255,0.75);
}

.auth-brand-feature-dot {
  width: 32px; height: 32px;
  border-radius: 10px;
  background: rgba(0, 122, 255, 0.18);
  border: 1px solid rgba(0, 122, 255, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.auth-brand-feature-dot svg { width: 15px; height: 15px; color: var(--blue); }

/* ── Right: form panel ── */
.auth-form-panel {
  width: 420px;
  min-width: 420px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 48px 40px;
  background: var(--card);
  backdrop-filter: blur(40px) saturate(200%);
  -webkit-backdrop-filter: blur(40px) saturate(200%);
  border-left: 1px solid var(--card-border);
  overflow-y: auto;
}

/* ── Logo / header ── */
.auth-header {
  margin-bottom: 32px;
}

.auth-logo-mark {
  width: 52px; height: 52px;
  background: linear-gradient(135deg, var(--blue), var(--purple));
  border-radius: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--blue-glow-sm);
  margin-bottom: 20px;
}
.auth-logo-mark svg { width: 26px; height: 26px; color: #fff; }

.auth-title {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.035em;
  color: var(--text);
  margin-bottom: 6px;
}

.auth-subtitle {
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.5;
}

/* ── Form ── */
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Input with icon */
.input-with-icon {
  position: relative;
}

.input-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-3);
  pointer-events: none;
  display: flex;
  align-items: center;
}
.input-icon svg { width: 17px; height: 17px; }

.input-with-icon .form-input { padding-left: 44px; }

/* Password wrap */
.pw-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.pw-wrap .form-input { padding-right: 48px; }

.pw-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-3);
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: color 0.15s;
  -webkit-tap-highlight-color: transparent;
}
.pw-toggle:hover { color: var(--text); }
.pw-toggle svg   { width: 18px; height: 18px; }

/* ── Divider ── */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 6px 0;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}
.auth-divider span {
  font-size: 12px;
  color: var(--text-3);
  font-weight: 500;
  white-space: nowrap;
}

/* ── Footer toggle ── */
.auth-footer {
  text-align: center;
  font-size: 14px;
  color: var(--text-2);
  margin-top: 24px;
}
.auth-footer a { font-weight: 600; }

/* ── Password hint ── */
.pw-hint {
  font-size: 12px;
  color: var(--text-3);
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.pw-hint svg { width: 12px; height: 12px; }

/* ── Submit button ── */
.auth-submit {
  width: 100%;
  padding: 14px;
  font-size: 16px;
  font-weight: 700;
  border-radius: var(--radius-md);
  margin-top: 4px;
}

/* ── Mobile: single-panel, full background ── */
@media (max-width: 820px) {
  .auth-body {
    padding: 20px 16px;
    align-items: flex-start;
    justify-content: flex-start;
    min-height: 100vh;
  }

  .auth-layout {
    max-width: 480px;
    min-height: unset;
    width: 100%;
    border-radius: var(--radius-xl);
    flex-direction: column;
    margin: 0 auto;
  }

  .auth-brand-panel { display: none; }

  .auth-form-panel {
    width: 100%;
    min-width: unset;
    padding: 36px 28px;
    border-left: none;
    border-radius: var(--radius-xl);
    overflow-y: visible;
  }
}

@media (max-width: 480px) {
  .auth-body {
    padding: 16px 12px;
    align-items: flex-start;
  }
  .auth-form-panel { padding: 28px 20px; }
  .auth-title   { font-size: 22px; }
}
