/* Modern Login Page (mobile-first) */
:root {
  --brand: #4f46e5; /* indigo-600 */
  --brand-2: #22d3ee; /* cyan-400 */
  --glass-bg: rgba(255, 255, 255, 0.08);
  --text-muted: #8b949e;
}

html, body { height: 100%; }
#auth { min-height: 100%; }

/* Animated gradient background */
.auth-modern-bg {
  position: fixed;
  inset: 0;
  background: linear-gradient(120deg, #0f172a, #111827, #0b1324);
  overflow: hidden;
  z-index: -2;
}
.auth-modern-bg::before,
.auth-modern-bg::after {
  content: "";
  position: absolute;
  width: 60vmax;
  height: 60vmax;
  filter: blur(80px);
  opacity: 0.45;
  border-radius: 50%;
  animation: float 18s ease-in-out infinite;
}
.auth-modern-bg::before {
  background: radial-gradient(closest-side, var(--brand), transparent 70%);
  top: -10vmax; left: -10vmax;
}
.auth-modern-bg::after {
  background: radial-gradient(closest-side, var(--brand-2), transparent 70%);
  bottom: -12vmax; right: -10vmax;
  animation-delay: 3s;
}
@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(2vmax, -2vmax) scale(1.05); }
}

/* Glass card */
.auth-glass {
  background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0.06));
  backdrop-filter: blur(14px) saturate(140%);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: .6rem;
  text-decoration: none;
}
.auth-brand .logo-mark {
  width: 42px; height: 42px;
  border-radius: 11px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  display: grid; place-items: center; color: #fff;
  box-shadow: 0 8px 20px rgba(79, 70, 229, .35);
}
.auth-brand .brand-name { font-weight: 800; letter-spacing: .2px; }

.auth-title-modern { font-weight: 800; letter-spacing: .2px; }
.auth-subtitle-modern { color: var(--text-muted); }

.auth-field { position: relative; }
.auth-field .form-control {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #e5e7eb;
}
.auth-field .form-control:focus {
  border-color: rgba(79,70,229,.65);
  box-shadow: 0 0 0 .2rem rgba(79,70,229,.15);
}
.auth-field .toggle-password {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  color: #c7c9d1; cursor: pointer;
}

.btn-auth-primary {
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  border: none;
  font-weight: 700;
  letter-spacing: .3px;
  box-shadow: 0 12px 24px rgba(79,70,229,.25);
  transition: transform .15s ease, box-shadow .2s ease;
}
.btn-auth-primary:hover { transform: translateY(-1px); box-shadow: 0 16px 30px rgba(79,70,229,.35); }
.btn-auth-primary:active { transform: translateY(0); }

.auth-right-visual {
  position: relative; height: 100%;
  display: grid; place-items: center;
}
.auth-right-visual .ring {
  position: absolute; border-radius: 50%; border: 1px dashed rgba(255,255,255,.25);
  animation: spin 40s linear infinite;
}
.auth-right-visual .ring.r1 { width: 46vmin; height: 46vmin; animation-duration: 36s; }
.auth-right-visual .ring.r2 { width: 62vmin; height: 62vmin; animation-duration: 54s; }
.auth-right-visual .ring.r3 { width: 78vmin; height: 78vmin; animation-duration: 72s; }
@keyframes spin { to { transform: rotate(360deg); } }

.fade-in { opacity: 0; transform: translateY(8px); transition: all .5s ease; }
.fade-in.show { opacity: 1; transform: translateY(0); }

/* Light mode adjustment if needed */
@media (prefers-color-scheme: light) {
  .auth-field .form-control { color: #111827; }
}

/* Sports-themed subtle pattern overlay */
.auth-pattern {
  position: fixed;
  inset: 0;
  background-image: url('../../img/patterns/sports-pattern.svg');
  background-size: 120px 120px;
  background-repeat: repeat;
  opacity: .22;
  mix-blend-mode: soft-light;
  pointer-events: none;
  z-index: -1;
}

/* Prefer-reduced-motion support */
@media (prefers-reduced-motion: reduce) {
  .fade-in { transition: none; }
  .auth-modern-bg::before,
  .auth-modern-bg::after { animation: none; }
}

/* Breakpoints: enhance for larger screens */
@media (min-width: 576px) {
  .auth-glass { padding: 2rem; }
}

@media (min-width: 768px) {
  .auth-pattern { background-size: 140px 140px; }
}

@media (min-width: 992px) {
  .auth-pattern { background-size: 160px 160px; }
  .auth-right-visual .ring { display: block; }
}
