/* ============================================================
   PlayHub — Auth pages (login / register) — premium
   Uses a fixed dark palette so inputs stay readable in light themes.
   ============================================================ */
.auth-body {
  --auth-txt: #f5f2fc;
  --auth-dim: #b8b0d0;
  --auth-muted: #8f86a8;
  --auth-input-bg: rgba(255, 255, 255, .08);
  --auth-input-border: rgba(255, 255, 255, .16);
  --auth-input-focus-bg: rgba(255, 255, 255, .11);
  --auth-accent: #9a72ff;
  --auth-accent-soft: rgba(154, 114, 255, .22);
}

.auth-body .topbar .search,
.auth-body .top-actions .login-btn { opacity: .45; pointer-events: none; }

.auth-main {
  position: relative;
  margin-left: var(--rail-w);
  margin-top: var(--top-h);
  min-height: calc(100vh - var(--top-h));
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 24px 88px;
  overflow: hidden;
  background:
    radial-gradient(ellipse 80% 60% at 50% -10%, rgba(124, 77, 255, .18), transparent 55%),
    radial-gradient(ellipse 50% 40% at 100% 100%, rgba(255, 92, 138, .08), transparent 50%),
    var(--bg);
}
body.rail-closed .auth-main { margin-left: 0; }

.auth-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
.auth-bg::before,
.auth-bg::after {
  content: "";
  position: absolute;
  border-radius: 50%;
}
.auth-bg::before {
  top: -120px;
  left: 50%;
  transform: translateX(-60%);
  width: 560px;
  height: 560px;
  background: radial-gradient(circle, rgba(124, 77, 255, .32) 0%, transparent 68%);
}
.auth-bg::after {
  bottom: -180px;
  right: 8%;
  width: 480px;
  height: 480px;
  background: radial-gradient(circle, rgba(255, 92, 138, .14) 0%, transparent 68%);
}

.auth-shell {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 440px;
}

.auth-card {
  background:
    linear-gradient(165deg, rgba(42, 34, 66, .98) 0%, rgba(24, 19, 38, .96) 100%);
  border: 1px solid rgba(154, 114, 255, .28);
  border-radius: 26px;
  padding: 38px 36px 34px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .08),
    0 28px 80px rgba(0, 0, 0, .55),
    0 0 0 1px rgba(0, 0, 0, .25),
    0 0 100px rgba(124, 77, 255, .14);
  backdrop-filter: blur(20px);
}

.auth-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 26px;
  text-decoration: none;
  color: var(--auth-txt);
  transition: opacity .15s;
}
.auth-brand:hover { opacity: .88; }
.auth-brand .brand-mark,
.auth-brand .brand-mark img {
  width: 42px;
  height: 42px;
  border-radius: 13px;
}
.auth-brand .logo-txt {
  font-size: 22px;
  line-height: .92;
  color: var(--auth-txt);
}
.auth-brand .logo-txt small {
  font-size: 22px;
  color: var(--auth-accent);
}

.auth-card h1 {
  font-family: "Baloo 2", sans-serif;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -.02em;
  text-align: center;
  margin-bottom: 8px;
  color: var(--auth-txt);
}
.auth-sub {
  color: var(--auth-dim);
  font-weight: 600;
  font-size: 15px;
  line-height: 1.55;
  text-align: center;
  margin-bottom: 28px;
}

.auth-err {
  background: rgba(255, 92, 99, .14);
  border: 1px solid rgba(255, 138, 144, .3);
  color: #ffb4b8;
  border-radius: 14px;
  padding: 12px 15px;
  font-weight: 700;
  font-size: 14px;
  line-height: 1.45;
  margin-bottom: 16px;
}

.auth-card .field { margin-bottom: 18px; }
.auth-card label {
  display: block;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--auth-dim);
  margin-bottom: 8px;
}
.auth-card .inp {
  width: 100%;
  height: 52px;
  border-radius: 14px;
  border: 1px solid var(--auth-input-border);
  background: var(--auth-input-bg);
  color: var(--auth-txt);
  -webkit-text-fill-color: var(--auth-txt);
  caret-color: var(--auth-accent);
  padding: 0 16px;
  font-family: inherit;
  font-weight: 600;
  font-size: 16px;
  transition: border-color .2s, box-shadow .2s, background .2s;
}
.auth-card .inp::placeholder {
  color: var(--auth-muted);
  opacity: 1;
}
.auth-card .inp:focus {
  outline: none;
  border-color: rgba(154, 114, 255, .65);
  background: var(--auth-input-focus-bg);
  box-shadow: 0 0 0 3px var(--auth-accent-soft);
}
.auth-card .inp:-webkit-autofill,
.auth-card .inp:-webkit-autofill:hover,
.auth-card .inp:-webkit-autofill:focus,
.auth-card .inp:-webkit-autofill:active {
  -webkit-text-fill-color: var(--auth-txt) !important;
  caret-color: var(--auth-accent);
  box-shadow: 0 0 0 1000px rgba(28, 22, 44, .96) inset !important;
  border: 1px solid var(--auth-input-border) !important;
  transition: background-color 99999s ease-out 0s;
}
.auth-card .hint {
  color: var(--auth-muted);
  font-weight: 600;
  font-size: 12.5px;
  margin-top: 7px;
}

.btn-auth {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 54px;
  margin-top: 10px;
  border: none;
  border-radius: 16px;
  cursor: pointer;
  text-decoration: none;
  line-height: 1;
  font-family: "Baloo 2", sans-serif;
  font-weight: 800;
  font-size: 17px;
  letter-spacing: .01em;
  color: #fff;
  background: linear-gradient(135deg, #a07bff 0%, #7c4dff 48%, #6230d8 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .2),
    0 12px 32px rgba(124, 77, 255, .45);
  transition: transform .15s, box-shadow .2s, filter .15s;
  position: relative;
  overflow: hidden;
}
.btn-auth::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 38%, rgba(255, 255, 255, .22) 50%, transparent 62%);
  transform: translateX(-120%);
  transition: transform .55s ease;
  pointer-events: none;
}
.btn-auth:hover {
  transform: translateY(-2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .24),
    0 16px 40px rgba(124, 77, 255, .55);
}
.btn-auth:hover::after { transform: translateX(120%); }
.btn-auth:active { transform: translateY(0); filter: brightness(.96); }

.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  width: 100%;
  height: 52px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(255, 255, 255, .06);
  color: var(--auth-txt);
  font-family: inherit;
  font-weight: 800;
  font-size: 15px;
  text-decoration: none;
  line-height: 1;
  transition: background .15s, border-color .15s, transform .15s, box-shadow .15s;
}
.btn-google:hover {
  background: rgba(255, 255, 255, .11);
  border-color: rgba(255, 255, 255, .22);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .2);
}

.auth-or {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--auth-muted);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.auth-or::before,
.auth-or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .12), transparent);
}

.auth-perks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 22px;
}
.auth-perk {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(124, 77, 255, .14);
  border: 1px solid rgba(154, 114, 255, .24);
  color: #c4a8ff;
  font-size: 12px;
  font-weight: 800;
}
.auth-perk svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}

.auth-foot {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  text-align: center;
  color: var(--auth-dim);
  font-weight: 600;
  font-size: 14.5px;
}
.auth-foot a {
  color: var(--auth-accent);
  font-weight: 800;
  text-decoration: none;
  transition: color .15s;
}
.auth-foot a:hover { color: #c4a8ff; }

@media (max-width: 560px) {
  .auth-main { padding: 32px 16px 72px; align-items: flex-start; }
  .auth-card { padding: 28px 22px 24px; border-radius: 22px; }
  .auth-card h1 { font-size: 26px; }
  .auth-perks { gap: 6px; }
  .auth-perk { font-size: 11px; padding: 5px 10px; }
}
