*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #080b14;
  --bg2: #0d1120;
  --card: rgba(255,255,255,0.04);
  --card-border: rgba(255,255,255,0.08);
  --primary: #6c63ff;
  --primary2: #a78bfa;
  --accent: #00d4aa;
  --text: #e2e8f0;
  --muted: #64748b;
  --danger: #f87171;
  --radius: 16px;
}

html { scroll-behavior: smooth; height: 100%; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
body::-webkit-scrollbar { display: none; }

.gradient-text {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── BUTTONS ── */
.btn-primary {
  background: linear-gradient(135deg, var(--primary), #8b5cf6);
  color: #fff; border: none; padding: 14px 28px;
  border-radius: 50px; font-weight: 700; font-size: 0.95rem;
  cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 4px 20px rgba(108,99,255,0.35);
  font-family: inherit;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(108,99,255,0.5); }

.btn-outline {
  background: transparent; color: var(--text);
  border: 1px solid var(--card-border); padding: 13px 28px;
  border-radius: 50px; font-weight: 600; font-size: 0.9rem;
  cursor: pointer; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; transition: border-color 0.2s, background 0.2s;
  font-family: inherit;
}
.btn-outline:hover { border-color: var(--primary); background: rgba(108,99,255,0.08); }

/* ── FORM ELEMENTS ── */
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-size: 0.82rem; font-weight: 600; color: var(--muted); letter-spacing: 0.5px; text-transform: uppercase; }
.input-wrap { position: relative; }
.input-wrap i.icon-left {
  position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
  color: var(--muted); font-size: 0.9rem; pointer-events: none;
}
.input-wrap input {
  width: 100%; background: rgba(255,255,255,0.05);
  border: 1px solid var(--card-border); border-radius: 12px;
  padding: 13px 16px 13px 42px; color: var(--text);
  font-size: 0.95rem; font-family: inherit;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  outline: none;
}
.input-wrap input::placeholder { color: var(--muted); }
.input-wrap input:focus {
  border-color: var(--primary);
  background: rgba(108,99,255,0.06);
  box-shadow: 0 0 0 3px rgba(108,99,255,0.15);
}
.input-wrap .toggle-pw {
  position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
  background: none; border: none; color: var(--muted); cursor: pointer;
  font-size: 0.9rem; padding: 4px; transition: color 0.2s;
}
.input-wrap .toggle-pw:hover { color: var(--text); }

.divider {
  display: flex; align-items: center; gap: 12px;
  color: var(--muted); font-size: 0.8rem;
}
.divider::before, .divider::after {
  content: ''; flex: 1; height: 1px; background: var(--card-border);
}

/* ── SOCIAL BUTTONS ── */
.social-btns { display: flex; gap: 12px; }
.btn-social {
  flex: 1; background: rgba(255,255,255,0.05);
  border: 1px solid var(--card-border); border-radius: 12px;
  padding: 11px; display: flex; align-items: center; justify-content: center; gap: 8px;
  color: var(--text); font-size: 0.85rem; font-weight: 600;
  cursor: pointer; text-decoration: none; font-family: inherit;
  transition: border-color 0.2s, background 0.2s;
}
.btn-social:hover { border-color: var(--primary); background: rgba(108,99,255,0.08); }
.btn-social img { width: 18px; height: 18px; }

/* ── LOGO ── */
.auth-logo {
  display: flex; align-items: center; gap: 10px;
  font-size: 1.3rem; font-weight: 800; color: #fff;
  text-decoration: none;
}
.auth-logo i { color: var(--primary); font-size: 1.4rem; }

/* ══════════════════════════════════════════
   DESKTOP LAYOUT  (≥ 900px)
══════════════════════════════════════════ */
.auth-page {
  display: flex; height: 100vh; overflow: hidden;
}

/* LEFT PANEL */
.auth-panel-left {
  flex: 1; position: relative; overflow: hidden;
  display: flex; flex-direction: column;
  padding: 40px 56px;
  background: linear-gradient(145deg, #0d0f1e 0%, #0f1628 60%, #0a1020 100%);
  height: 100vh;
}
.panel-orb {
  position: absolute; border-radius: 50%;
  filter: blur(80px); opacity: 0.18; pointer-events: none;
}
.po1 { width: 500px; height: 500px; background: var(--primary); top: -180px; left: -180px; animation: orbFloat 9s ease-in-out infinite; }
.po2 { width: 350px; height: 350px; background: var(--accent); bottom: -120px; right: -80px; animation: orbFloat 7s ease-in-out infinite 3s; }
.po3 { width: 250px; height: 250px; background: #8b5cf6; top: 40%; left: 30%; animation: orbFloat 11s ease-in-out infinite 6s; }
@keyframes orbFloat {
  0%,100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-24px) scale(1.04); }
}
.panel-grid {
  position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 50px 50px;
}
.panel-content {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; height: 100%;
}
.panel-body {
  flex: 1; display: flex; flex-direction: column;
  justify-content: center; gap: 40px;
}
.panel-heading { font-size: 2.4rem; font-weight: 900; line-height: 1.15; }
.panel-sub { color: var(--muted); font-size: 1rem; line-height: 1.7; max-width: 380px; }

.panel-stats { display: flex; flex-direction: column; gap: 16px; }
.pstat {
  display: flex; align-items: center; gap: 16px;
  background: rgba(255,255,255,0.04); border: 1px solid var(--card-border);
  border-radius: 14px; padding: 16px 20px;
  backdrop-filter: blur(10px);
}
.pstat-icon {
  width: 44px; height: 44px; border-radius: 12px; flex-shrink: 0;
  background: linear-gradient(135deg, rgba(108,99,255,0.25), rgba(0,212,170,0.15));
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; color: var(--primary);
}
.pstat-info strong { display: block; font-size: 1.1rem; font-weight: 800; color: #fff; }
.pstat-info span { font-size: 0.8rem; color: var(--muted); }

.panel-testimonial {
  background: rgba(255,255,255,0.04); border: 1px solid var(--card-border);
  border-radius: 16px; padding: 24px; backdrop-filter: blur(10px);
}
.pt-stars { color: #fbbf24; font-size: 0.85rem; margin-bottom: 10px; }
.pt-quote { color: var(--text); font-size: 0.9rem; line-height: 1.6; font-style: italic; margin-bottom: 16px; }
.pt-author { display: flex; align-items: center; gap: 10px; }
.pt-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; font-weight: 700;
}
.pt-author strong { font-size: 0.85rem; display: block; }
.pt-author small { color: var(--muted); font-size: 0.75rem; }

.panel-footer { color: var(--muted); font-size: 0.78rem; }

/* RIGHT PANEL */
.auth-panel-right {
  width: 520px; flex-shrink: 0;
  display: flex; flex-direction: column;
  justify-content: center; align-items: center;
  padding: 48px 56px;
  background: var(--bg);
  border-left: 1px solid var(--card-border);
  height: 100vh;
  overflow: hidden;
  position: sticky;
  top: 0;
}
.auth-form-wrap { width: 100%; max-width: 400px; }
.auth-title { font-size: 1.8rem; font-weight: 900; margin-bottom: 6px; }
.auth-subtitle { color: var(--muted); font-size: 0.9rem; margin-bottom: 32px; }
.auth-form { display: flex; flex-direction: column; gap: 20px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.forgot-link {
  font-size: 0.82rem; color: var(--primary); text-decoration: none;
  text-align: right; display: block; margin-top: -8px;
  transition: color 0.2s;
}
.forgot-link:hover { color: var(--primary2); }
.terms-check { display: flex; align-items: flex-start; gap: 10px; font-size: 0.82rem; color: var(--muted); }
.terms-check input[type="checkbox"] {
  width: 16px; height: 16px; margin-top: 1px; flex-shrink: 0;
  accent-color: var(--primary); cursor: pointer;
}
.terms-check a { color: var(--primary); text-decoration: none; }
.terms-check a:hover { text-decoration: underline; }
.auth-switch { text-align: center; font-size: 0.85rem; color: var(--muted); margin-top: 8px; }
.auth-switch a { color: var(--primary); text-decoration: none; font-weight: 600; }
.auth-switch a:hover { color: var(--primary2); }



/* Hide mobile elements on desktop only */
@media (min-width: 900px) {
  .mobile-only { display: none !important; }
  .desktop-form-area { display: flex; flex-direction: column; gap: 20px; }
}

/* Hide desktop elements on mobile */
@media (max-width: 899px) {
  .desktop-only { display: none !important; }
  .desktop-form-area { display: none; }
}

/* ══════════════════════════════════════════
   MOBILE LAYOUT — Android & iPhone
══════════════════════════════════════════ */
.mobile-auth-page {
  display: none;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
  flex-direction: column;
  align-items: center;
  padding: 0 0 48px;
}
.mobile-auth-page::-webkit-scrollbar { display: none; }

@media (max-width: 899px) {
  .mobile-auth-page { display: flex; }
}

/* Orbs */
.mob-orb {
  position: fixed; border-radius: 50%;
  filter: blur(70px); opacity: 0.12; pointer-events: none; z-index: 0;
}
.mob-orb1 { width: 380px; height: 380px; background: var(--primary); top: -160px; left: -120px; }
.mob-orb2 { width: 280px; height: 280px; background: var(--accent); bottom: 10%; right: -100px; }
.mob-orb3 { width: 200px; height: 200px; background: #8b5cf6; top: 45%; left: 20%; }
.mob-grid {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 44px 44px;
}

/* Top logo area */
.mob-top {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; align-items: center;
  padding: 60px 24px 24px;
  text-align: center;
}
.mob-logo {
  display: flex; align-items: center; gap: 10px;
  text-decoration: none; margin-bottom: 10px;
}
.mob-logo-icon {
  width: 44px; height: 44px; border-radius: 14px;
  background: linear-gradient(135deg, var(--primary), #8b5cf6);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; color: #fff;
  box-shadow: 0 4px 16px rgba(108,99,255,0.4);
}
.mob-logo span {
  font-size: 1.3rem; font-weight: 800; color: #fff;
}
.mob-tagline {
  font-size: 0.85rem; color: var(--muted); margin-top: 4px;
}

/* Card */
.mob-card {
  position: relative; z-index: 1;
  width: calc(100% - 32px); max-width: 420px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 24px;
  padding: 28px 24px;
  backdrop-filter: blur(20px);
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
.mob-card-header { margin-bottom: 20px; text-align: center; }
.mob-card-title {
  font-size: 1.5rem; font-weight: 900; color: #fff;
  display: flex; align-items: center; justify-content: center; gap: 8px;
}
.mob-emoji { font-size: 1.3rem; line-height: 1; }
.mob-card-sub {
  font-size: 0.85rem; color: var(--muted); margin-top: 4px;
}

/* Social buttons */
.mob-social { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.mob-social-btn {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  padding: 13px 16px; border-radius: 14px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  color: #fff; font-size: 0.9rem; font-weight: 600;
  text-decoration: none; font-family: inherit;
  transition: background 0.2s, border-color 0.2s;
}
.mob-social-btn:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.2); }
.mob-social-btn img { width: 20px; height: 20px; }
.mob-apple { background: rgba(255,255,255,0.08); }
.mob-apple i { font-size: 1.1rem; }

/* Divider */
.mob-divider {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 20px;
}
.mob-divider::before, .mob-divider::after {
  content: ''; flex: 1; height: 1px;
  background: rgba(255,255,255,0.08);
}
.mob-divider span { color: var(--muted); font-size: 0.78rem; white-space: nowrap; }

/* Form fields */
.mob-form { display: flex; flex-direction: column; gap: 12px; }
.mob-field {
  display: flex; align-items: center; gap: 12px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px; padding: 0 16px;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.mob-field:focus-within {
  border-color: var(--primary);
  background: rgba(108,99,255,0.07);
  box-shadow: 0 0 0 3px rgba(108,99,255,0.15);
}
.mob-field > i {
  color: var(--muted); font-size: 0.88rem; flex-shrink: 0;
}
.mob-field input {
  flex: 1; background: none; border: none; outline: none;
  color: var(--text); font-size: 0.95rem; font-family: inherit;
  padding: 14px 0;
}
.mob-field input::placeholder { color: var(--muted); }
.mob-eye {
  background: none; border: none; color: var(--muted);
  cursor: pointer; padding: 4px; font-size: 0.88rem;
  transition: color 0.2s; flex-shrink: 0;
}
.mob-eye:hover { color: var(--text); }

/* Password strength */
.mob-strength-bar {
  height: 3px; border-radius: 99px;
  background: rgba(255,255,255,0.07); overflow: hidden;
  margin-top: -4px;
}
.mob-strength-fill {
  height: 100%; width: 0%; border-radius: 99px;
  transition: width 0.3s, background 0.3s;
}

/* Forgot */
.mob-forgot {
  font-size: 0.82rem; color: var(--primary);
  text-decoration: none; text-align: right;
  display: block; margin-top: -4px;
}
.mob-forgot:hover { color: var(--primary2); }

/* Terms */
.mob-terms {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 0.82rem; color: var(--muted); cursor: pointer;
}
.mob-terms input[type="checkbox"] {
  width: 16px; height: 16px; margin-top: 1px;
  accent-color: var(--primary); flex-shrink: 0;
}
.mob-terms a { color: var(--primary); text-decoration: none; }

/* Submit */
.mob-submit {
  background: linear-gradient(135deg, var(--primary), #8b5cf6);
  color: #fff; border: none; padding: 15px;
  border-radius: 14px; font-weight: 700; font-size: 0.95rem;
  cursor: pointer; width: 100%; font-family: inherit;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  box-shadow: 0 4px 20px rgba(108,99,255,0.4);
  transition: transform 0.2s, box-shadow 0.2s;
  margin-top: 4px;
}
.mob-submit:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(108,99,255,0.55); }

/* Switch */
.mob-switch {
  text-align: center; font-size: 0.85rem;
  color: var(--muted); margin-top: 20px;
}
.mob-switch a { color: var(--primary); text-decoration: none; font-weight: 600; }
.mob-switch a:hover { color: var(--primary2); }

/* Trust badges */
.mob-trust {
  position: relative; z-index: 1;
  display: flex; align-items: center; justify-content: center;
  gap: 10px; flex-wrap: wrap;
  padding: 24px 16px 0;
}
.mob-trust-item {
  display: flex; align-items: center; gap: 6px;
  font-size: 0.75rem; color: var(--muted);
}
.mob-trust-item i { color: var(--accent); font-size: 0.75rem; }
.mob-trust-dot {
  width: 3px; height: 3px; border-radius: 50%;
  background: var(--muted); opacity: 0.4;
}

/* iPhone safe area */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
  .mobile-auth-page { padding-bottom: calc(40px + env(safe-area-inset-bottom)); }
}
