/* =========================================================
   ORBITOHM — Auth ("Aurora Glass")
   A deliberately fixed, immersive dark theme for the sign-in/create-
   account/password-recovery pages — independent of the site's own
   light/dark toggle (style.css), the same way many premium consumer
   apps give their auth screen its own identity distinct from the
   in-app theme. A full-viewport drifting gradient-mesh background
   with floating color "orbs" behind a centered frosted-glass card.
   ========================================================= */

.auth-body{ margin:0; min-height:100vh; }

.aurora-page{
  --aurora-bg: #0d0715;
  --aurora-bg2: #1b0f2e;
  --aurora-card-bg: rgba(255,255,255,.055);
  --aurora-border: rgba(255,255,255,.14);
  --aurora-ink: #f5f0e8;
  --aurora-muted: #b6a9c9;
  --aurora-gold: #e3b96e;
  --aurora-gold-deep: #caa15a;
  --aurora-amethyst: #9b7fd4;
  --aurora-rose: #e0789e;
  --aurora-teal: #5fc7bb;
  --aurora-danger: #ef6f6f;
  --aurora-success: #6fd19a;

  position:relative; min-height:100vh; overflow:hidden; isolation:isolate;
  background:radial-gradient(120% 90% at 50% -10%, var(--aurora-bg2) 0%, var(--aurora-bg) 62%);
  display:flex; align-items:center; justify-content:center; padding:64px 20px;
  font-family:inherit; color:var(--aurora-ink);
}

/* ---------- Drifting gradient orbs ---------- */
.aurora-orb{ position:absolute; z-index:-1; border-radius:50%; filter:blur(70px); pointer-events:none; }
.aurora-orb-1{ width:440px; height:440px; background:var(--aurora-amethyst); opacity:.5; top:-140px; left:-120px; }
.aurora-orb-2{ width:400px; height:400px; background:var(--aurora-rose); opacity:.4; bottom:-160px; right:-100px; }
.aurora-orb-3{ width:320px; height:320px; background:var(--aurora-gold); opacity:.32; top:38%; right:6%; }
.aurora-orb-4{ width:280px; height:280px; background:var(--aurora-teal); opacity:.28; bottom:10%; left:6%; }
@media (prefers-reduced-motion: no-preference){
  .aurora-orb-1{ animation:auroraFloatA 24s ease-in-out infinite; }
  .aurora-orb-2{ animation:auroraFloatB 28s ease-in-out infinite; }
  .aurora-orb-3{ animation:auroraFloatC 32s ease-in-out infinite; }
  .aurora-orb-4{ animation:auroraFloatA 36s ease-in-out infinite reverse; }
}
@keyframes auroraFloatA{ 0%,100%{ transform:translate(0,0) scale(1); } 50%{ transform:translate(50px,60px) scale(1.12); } }
@keyframes auroraFloatB{ 0%,100%{ transform:translate(0,0) scale(1); } 50%{ transform:translate(-60px,-40px) scale(1.08); } }
@keyframes auroraFloatC{ 0%,100%{ transform:translate(0,0); } 50%{ transform:translate(-40px,50px); } }

/* ---------- Card ---------- */
.aurora-back{ position:absolute; top:28px; left:28px; z-index:3; font-size:.85rem; color:var(--aurora-muted); }
.aurora-back:hover{ color:var(--aurora-gold); }

.aurora-card{
  position:relative; z-index:2; width:100%; max-width:460px;
  background:var(--aurora-card-bg); backdrop-filter:blur(28px) saturate(160%); -webkit-backdrop-filter:blur(28px) saturate(160%);
  border:1px solid var(--aurora-border); border-radius:28px; padding:44px 40px;
  box-shadow:0 30px 80px rgba(0,0,0,.5);
  animation:aurora-rise .6s cubic-bezier(.22,.61,.36,1) both;
}
@keyframes aurora-rise{ from{ opacity:0; transform:translateY(24px) scale(.98); } to{ opacity:1; transform:translateY(0) scale(1); } }
@media (prefers-reduced-motion: reduce){ .aurora-card{ animation:none; } }

.aurora-brand{ display:flex; justify-content:center; margin-bottom:22px; }
.aurora-brand img{ height:42px; border-radius:8px; box-shadow:0 4px 18px rgba(0,0,0,.45); }
.aurora-card .eyebrow{ display:block; text-align:center; color:var(--aurora-gold); font-size:.76rem; }
.aurora-card h1{ text-align:center; color:#fff; font-family:var(--font-serif); font-size:1.7rem; margin:.25em 0 .5em; }
.aurora-card > p:not(.field-hint):not(.auth-switch){ text-align:center; color:var(--aurora-muted); margin-bottom:28px; font-size:.92rem; }
.aurora-card a{ color:var(--aurora-gold); }
.aurora-card a:hover{ color:#fff; }

/* ---------- Alerts (dark-glass variants of style.css's .alert-*) ---------- */
.aurora-card .alert{ border-radius:14px; padding:14px 16px; font-size:.88rem; margin-bottom:20px; }
.aurora-card .alert-danger{ background:rgba(239,111,111,.13); border:1px solid rgba(239,111,111,.35); color:#ffbcbc; }
.aurora-card .alert-success{ background:rgba(111,209,154,.13); border:1px solid rgba(111,209,154,.35); color:#aeeecb; }

/* ---------- Sign-in method toggle (Password / OTP) ---------- */
.auth-method-toggle{ display:flex; gap:4px; background:rgba(255,255,255,.05); border:1px solid var(--aurora-border); border-radius:999px; padding:4px; margin-bottom:26px; }
.auth-method-btn{ flex:1; border:none; background:none; padding:10px 14px; border-radius:999px; font-size:.85rem; color:var(--aurora-muted); cursor:pointer; transition:background-color .2s ease, color .2s ease; }
.auth-method-btn.active{ background:linear-gradient(135deg, var(--aurora-gold), var(--aurora-amethyst)); color:#180f26; font-weight:700; }
.auth-method-panel{ display:none; }
.auth-method-panel.active{ display:block; animation:aurora-rise .4s cubic-bezier(.22,.61,.36,1) both; }

/* ---------- Floating-label fields (glass inputs) ---------- */
.field-float{ position:relative; margin-bottom:18px; }
.field-float input{
  width:100%; padding:21px 44px 8px 16px; border-radius:14px; border:1px solid var(--aurora-border);
  background:rgba(255,255,255,.05); font-size:1rem; color:var(--aurora-ink);
  transition:border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}
.field-float input::placeholder{ color:transparent; }
.field-float label{
  position:absolute; left:16px; top:16px; font-size:1rem; color:var(--aurora-muted); pointer-events:none;
  transition:all .16s ease; transform-origin:left top;
}
.field-float input:focus{ outline:none; border-color:var(--aurora-gold); background:rgba(255,255,255,.08); box-shadow:0 0 0 4px rgba(227,185,110,.16); }
.field-float input:focus + label,
.field-float input:not(:placeholder-shown) + label{
  top:8px; font-size:.66rem; letter-spacing:.06em; text-transform:uppercase; color:var(--aurora-gold);
}
.field-float.has-error input{ border-color:var(--aurora-danger); }
.field-float.has-error input:focus{ box-shadow:0 0 0 4px rgba(239,111,111,.14); }
.field-float.is-valid input{ border-color:var(--aurora-success); }

/* Neutralize the browser's own autofill styling (usually a jarring white/yellow
   fill) so an autofilled email/password field still reads as part of the dark
   glass card instead of a bright rectangle punched through it. */
.field-float input:-webkit-autofill,
.field-float input:-webkit-autofill:hover,
.field-float input:-webkit-autofill:focus{
  -webkit-text-fill-color: var(--aurora-ink);
  -webkit-box-shadow: 0 0 0 1000px rgba(40,25,58,.92) inset;
  transition: background-color 9999s ease-in-out 0s;
}

.field-status-icon{
  position:absolute; right:14px; top:18px; width:18px; height:18px; display:none; align-items:center; justify-content:center;
  border-radius:50%; font-size:.68rem; line-height:1;
}
.field-float.is-valid .field-status-icon.icon-valid{ display:flex; background:rgba(111,209,154,.18); color:var(--aurora-success); }
.field-float.has-error .field-status-icon.icon-error{ display:flex; background:rgba(239,111,111,.18); color:var(--aurora-danger); }

.password-toggle{
  position:absolute; right:12px; top:14px; background:none; border:none; color:var(--aurora-muted); padding:6px; cursor:pointer;
  display:flex; align-items:center; justify-content:center;
}
.password-toggle:hover{ color:var(--aurora-gold); }
.field-float:has(.password-toggle) input{ padding-right:44px; }

.field-hint{ font-size:.78rem; margin-top:6px; min-height:1.1em; color:var(--aurora-muted); }
.field-hint.hint-error{ color:var(--aurora-danger); }
.field-hint.hint-ok{ color:var(--aurora-success); }

/* ---------- Password strength meter ---------- */
.strength-meter{ display:flex; gap:5px; margin-top:8px; }
.strength-bar{ height:4px; flex:1; border-radius:3px; background:rgba(255,255,255,.12); transition:background-color .2s ease; }
.strength-label{ font-size:.75rem; margin-top:6px; color:var(--aurora-muted); }
.strength-1 .strength-bar:nth-child(1){ background:var(--aurora-danger); }
.strength-2 .strength-bar:nth-child(-n+2){ background:#e0a15c; }
.strength-3 .strength-bar:nth-child(-n+3){ background:var(--aurora-gold); }
.strength-4 .strength-bar{ background:var(--aurora-success); }

/* ---------- Remember-me checkbox ---------- */
.auth-remember-me{ display:flex; align-items:center; gap:9px; font-size:.88rem; color:var(--aurora-muted); margin:-6px 0 20px; cursor:pointer; }
.auth-remember-me input{ width:16px; height:16px; accent-color:var(--aurora-gold); cursor:pointer; }

/* ---------- Buttons (scoped overrides of style.css's .btn-primary/.btn-outline,
   so the rest of the site's buttons are completely unaffected) ---------- */
.aurora-card .btn-primary{
  background:linear-gradient(135deg, var(--aurora-gold), var(--aurora-amethyst));
  border:none; color:#180f26; font-weight:700;
  box-shadow:0 10px 30px rgba(227,185,110,.22);
  transition:transform .18s ease, box-shadow .18s ease;
}
.aurora-card .btn-primary:hover{ transform:translateY(-2px); box-shadow:0 14px 36px rgba(227,185,110,.32); }
.aurora-card .btn-secondary,
.aurora-card .btn-outline{ background:rgba(255,255,255,.06); border:1px solid var(--aurora-border); color:var(--aurora-ink); }
.aurora-card .btn-secondary:hover,
.aurora-card .btn-outline:hover{ border-color:var(--aurora-gold); color:var(--aurora-gold); }
.aurora-card .btn:disabled{ opacity:.6; cursor:not-allowed; transform:none; }

.btn-auth-submit{ position:relative; margin-top:6px; }
.btn-auth-submit .btn-spinner{ display:none; width:16px; height:16px; border-radius:50%; border:2px solid rgba(24,15,38,.35); border-top-color:#180f26; animation:btn-spin .7s linear infinite; }
.btn-auth-submit.is-loading .btn-text{ opacity:.6; }
.btn-auth-submit.is-loading .btn-spinner{ display:inline-block; }
@keyframes btn-spin{ to{ transform:rotate(360deg); } }
@media (prefers-reduced-motion: reduce){ .btn-auth-submit .btn-spinner{ animation:none; } }

/* ---------- Title / First name / Last name row (signup.php) ---------- */
.name-field-row{ display:grid; grid-template-columns:100px 1fr 1fr; gap:12px; }
/* Plain <select> elements ignore a custom `color`/`background` in most browsers
   unless you also take over their native appearance — without appearance:none, e.g.
   Windows Chrome/Edge keep rendering the box with a system-native light background,
   which made the light "aurora-ink" text on it effectively invisible. The
   background-image chevron replaces the native dropdown arrow that appearance:none
   also removes. */
.title-select,
.aurora-card .phone-otp-group select{
  appearance:none; -webkit-appearance:none; -moz-appearance:none;
  background-color:rgba(255,255,255,.05);
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23b6a9c9' fill='none' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat:no-repeat; background-position:right 14px center;
  color:var(--aurora-ink);
}
.title-select option,
.aurora-card .phone-otp-group select option{
  background:#1b0f2e; color:var(--aurora-ink);
}

.title-select{
  width:100%; height:58px; padding:0 34px 0 12px; border-radius:14px; border:1px solid var(--aurora-border);
  font-size:.92rem; align-self:start;
}
.title-select:focus{ outline:none; border-color:var(--aurora-gold); box-shadow:0 0 0 4px rgba(227,185,110,.16); }
@media (max-width:520px){ .name-field-row{ grid-template-columns:1fr; } .title-select{ height:auto; padding:14px 34px 14px 12px; } }

/* ---------- Mobile-number + OTP widget (signup.php) — dark-glass variants of the
   .phone-otp-group / .status-pill styling from style.css ---------- */
.aurora-card .phone-otp-group select{
  border:1px solid var(--aurora-border); border-radius:12px; padding:12px 30px 12px 14px;
}
.aurora-card .phone-otp-group input{
  background:rgba(255,255,255,.05); border:1px solid var(--aurora-border); color:var(--aurora-ink);
  border-radius:12px; padding:12px 14px;
}
.aurora-card .phone-otp-group select:focus,
.aurora-card .phone-otp-group input:focus{ outline:none; border-color:var(--aurora-gold); }
.aurora-card #otpStatus{ color:var(--aurora-muted); }
.aurora-card #otpStatus.is-error{ color:var(--aurora-danger); }
#otpLoginStatus{ color:var(--aurora-muted); }
#otpLoginStatus.is-error{ color:var(--aurora-danger); }
.aurora-card .status-pill.status-paid{ background:rgba(111,209,154,.15); color:var(--aurora-success); }

/* ---------- Trust bullets + live-order stat (compact, inside the card) ---------- */
.aurora-trust{ list-style:none; margin:26px 0 0; padding:22px 0 0; border-top:1px solid var(--aurora-border); display:flex; flex-direction:column; gap:11px; }
.aurora-trust li{ display:flex; align-items:center; gap:10px; font-size:.84rem; color:var(--aurora-muted); }
.aurora-trust .tick{ width:20px; height:20px; flex:none; border-radius:50%; background:rgba(227,185,110,.12); border:1px solid var(--aurora-gold-deep); color:var(--aurora-gold); display:flex; align-items:center; justify-content:center; font-size:.62rem; }

.aurora-live-stat{ display:flex; align-items:center; justify-content:center; gap:9px; margin-top:20px; padding:8px 16px; border-radius:999px; background:rgba(111,209,154,.08); border:1px solid rgba(111,209,154,.25); color:var(--aurora-ink); font-size:.8rem; }
.aurora-live-dot{ width:7px; height:7px; border-radius:50%; background:var(--aurora-success); flex:none; }
@media (prefers-reduced-motion: no-preference){ .aurora-live-dot{ animation:aurora-live-pulse 1.8s ease-in-out infinite; } }
@keyframes aurora-live-pulse{ 0%,100%{ opacity:1; box-shadow:0 0 0 0 rgba(111,209,154,.5); } 50%{ opacity:.7; box-shadow:0 0 0 5px rgba(111,209,154,0); } }

/* ---------- Misc ---------- */
.auth-switch{ text-align:center; margin-top:26px; font-size:.92rem; color:var(--aurora-muted); }
.auth-divider{ display:flex; align-items:center; gap:14px; margin:26px 0; color:var(--aurora-muted); font-size:.78rem; text-transform:uppercase; letter-spacing:.05em; }
.auth-divider::before, .auth-divider::after{ content:''; flex:1; height:1px; background:var(--aurora-border); }

@media (max-width: 560px){
  .aurora-card{ padding:36px 26px; border-radius:22px; }
  .aurora-page{ padding:48px 14px; }
}
