/* --- Bespoke Glassmorphic Gradient Theme for Auth Pages (Standalone CDN Version) --- */
:root {
  --bg: #061224;
  --bg-secondary: #0b1a30;
  --card: rgba(11, 26, 48, 0.65);
  --border: rgba(255, 255, 255, 0.08);
  --fg: #ffffff;
  --muted: #8fa0b5;
  --accent: #00e676; /* Vibrant Neon Growth Green */
  --accent-light: rgba(0, 230, 118, 0.15);
  --accent-secondary: #ff9f5a; /* Brand Peach Orange */
}

body.auth-body {
  font-family: 'DM Sans', sans-serif;
  background: var(--bg);
  color: var(--fg);
  min-height: 100vh;
  overflow-x: hidden;
}

.font-display {
  font-family: 'Space Grotesk', sans-serif;
}

/* Animated Background Orbs */
.bg-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.gradient-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.35;
  animation: float-orb 25s ease-in-out infinite;
}

.orb-1 {
  width: 500px;
  height: 500px;
  background: linear-gradient(135deg, var(--accent), #05c46b);
  top: -150px;
  right: -100px;
  animation-delay: 0s;
}

.orb-2 {
  width: 450px;
  height: 450px;
  background: linear-gradient(135deg, #00abff, #00d2d3);
  bottom: -120px;
  left: -80px;
  animation-delay: -8s;
}

.orb-3 {
  width: 350px;
  height: 350px;
  background: linear-gradient(135deg, var(--accent-secondary), #ff7675);
  top: 40%;
  left: 25%;
  animation-delay: -16s;
  opacity: 0.25;
}

@keyframes float-orb {
  0%, 100% { transform: translate(0, 0) scale(1); }
  25% { transform: translate(40px, -40px) scale(1.05); }
  50% { transform: translate(-30px, 30px) scale(0.95); }
  75% { transform: translate(30px, 40px) scale(1.02); }
}

/* Floating Particles */
.particle {
  position: absolute;
  width: 5px;
  height: 5px;
  background: var(--accent);
  border-radius: 50%;
  animation: particle-float 18s linear infinite;
  opacity: 0;
}

@keyframes particle-float {
  0% {
    opacity: 0;
    transform: translateY(100vh) scale(0);
  }
  10% {
    opacity: 0.6;
  }
  90% {
    opacity: 0.6;
  }
  100% {
    opacity: 0;
    transform: translateY(-100vh) scale(1);
  }
}

/* Main Container */
.main-container {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

/* Form Container */
.form-container {
  width: 100%;
  max-width: 440px;
  position: relative;
}

.form-card {
  background: var(--card);
  backdrop-filter: blur(40px);
  -webkit-backdrop-filter: blur(40px);
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: 2.75rem;
  box-shadow: 
    0 4px 6px -1px rgba(0, 0, 0, 0.05),
    0 20px 60px -15px rgba(0, 0, 0, 0.15);
  animation: form-appear 0.8s ease-out;
}

@keyframes form-appear {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
  animation: logo-entrance 0.6s ease-out;
}

@keyframes logo-entrance {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.logo-icon {
  width: 52px;
  height: 52px;
  background: linear-gradient(135deg, var(--accent), var(--accent-secondary));
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(0, 230, 118, 0.3);
  animation: logo-glow 4s ease-in-out infinite;
}

@keyframes logo-glow {
  0%, 100% { box-shadow: 0 8px 24px rgba(0, 230, 118, 0.3); }
  50% { box-shadow: 0 12px 36px rgba(0, 230, 118, 0.4); }
}

.logo-text {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--fg);
}

/* Welcome Text */
.welcome-text {
  text-align: center;
  margin-bottom: 2rem;
}

.welcome-text h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  animation: text-reveal 0.5s ease-out 0.2s backwards;
}

.welcome-text p {
  color: var(--muted);
  font-size: 0.95rem;
  animation: text-reveal 0.5s ease-out 0.3s backwards;
}

@keyframes text-reveal {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Tab Switcher */
.tab-switcher {
  display: flex;
  background: var(--bg-secondary);
  border-radius: 14px;
  padding: 5px;
  margin-bottom: 2rem;
  animation: text-reveal 0.5s ease-out 0.35s backwards;
}

.tab-btn {
  flex: 1;
  padding: 0.875rem 1.5rem;
  border: none;
  background: transparent;
  color: var(--muted);
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border-radius: 12px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
}

.tab-btn.active {
  background: rgba(255, 255, 255, 0.08);
  color: var(--fg);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.tab-btn:not(.active):hover {
  color: var(--fg);
}

/* Form Styles */
.form-group {
  margin-bottom: 1.25rem;
  animation: input-reveal 0.5s ease-out backwards;
}

.form-group:nth-child(1) { animation-delay: 0.4s; }
.form-group:nth-child(2) { animation-delay: 0.45s; }
.form-group:nth-child(3) { animation-delay: 0.5s; }
.form-group:nth-child(4) { animation-delay: 0.55s; }

@keyframes input-reveal {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--fg);
  margin-bottom: 0.5rem;
  transition: color 0.3s ease;
}

.input-wrapper {
  position: relative;
}

.form-input {
  width: 100%;
  padding: 1rem 1.25rem;
  padding-left: 3rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1.5px solid var(--border);
  border-radius: 14px;
  color: var(--fg);
  font-family: 'DM Sans', sans-serif;
  font-size: 1rem;
  transition: all 0.3s ease;
}

.form-input::placeholder {
  color: #5f758e;
}

.form-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-light);
}

.input-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: #b0b0b8;
  transition: color 0.3s ease;
  pointer-events: none;
}

.form-input:focus + .input-icon,
.input-wrapper:focus-within .input-icon {
  color: var(--accent);
}

.password-toggle {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #b0b0b8;
  cursor: pointer;
  padding: 4px;
  transition: color 0.3s ease;
}

.password-toggle:hover {
  color: var(--fg);
}

/* Submit Button - Color for Logo Background with Neon Green Border */
.submit-btn {
  width: 100%;
  padding: 1.125rem 2rem;
  background: #0b2240; /* Premium Logo Background Color */
  border: 2px solid var(--accent); /* Glowing Neon Growth Green Border */
  border-radius: 14px;
  color: #ffffff; /* High contrast white text */
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
  margin-top: 0.75rem;
  box-shadow: 0 4px 16px rgba(0, 230, 118, 0.25);
}

.submit-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--accent); /* Transits completely to neon green on hover */
  opacity: 0;
  transition: opacity 0.3s ease;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(0, 230, 118, 0.45);
  color: #0b2240; /* High contrast dark text against neon-green backdrop */
}

.submit-btn:hover::before {
  opacity: 1;
}

.submit-btn:active {
  transform: translateY(0);
}

.btn-text {
  position: relative;
  z-index: 1;
}

/* Social Login */
.divider {
  display: flex;
  align-items: center;
  margin: 1.75rem 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.divider::before,
.divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

.divider span {
  padding: 0 1rem;
}

.social-buttons {
  display: flex;
  gap: 0.875rem;
}

.social-btn {
  flex: 1;
  padding: 0.95rem;
  background: white;
  border: 1.5px solid var(--border);
  border-radius: 14px;
  color: var(--fg);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.3s ease;
}

.social-btn:hover {
  border-color: #d0d0d8;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  transform: translateY(-2px);
}

/* Checkbox */
.checkbox-wrapper {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.custom-checkbox {
  width: 22px;
  height: 22px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 7px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  flex-shrink: 0;
  margin-top: 2px;
}

.custom-checkbox:hover {
  border-color: var(--accent);
}

.custom-checkbox.checked {
  background: var(--accent);
  border-color: var(--accent);
}

.custom-checkbox svg {
  opacity: 0;
  transform: scale(0);
  transition: all 0.2s ease;
}

.custom-checkbox.checked svg {
  opacity: 1;
  transform: scale(1);
}

.checkbox-label {
  font-size: 0.9rem;
  color: var(--muted);
  cursor: pointer;
  line-height: 1.5;
}

.checkbox-label a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}

.checkbox-label a:hover {
  text-decoration: underline;
}

/* Forgot Password */
.forgot-link {
  display: inline-block;
  font-size: 0.875rem;
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
  margin-top: 0.5rem;
  transition: color 0.3s ease;
}

.forgot-link:hover {
  color: var(--accent-secondary);
}

/* Footer */
.auth-footer {
  text-align: center;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  animation: text-reveal 0.5s ease-out 0.6s backwards;
}

.auth-footer p {
  font-size: 0.9rem;
  color: var(--muted);
}

.auth-footer a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.auth-footer a:hover {
  text-decoration: underline;
}

/* Focus Visible */
.form-input:focus-visible,
.submit-btn:focus-visible,
.social-btn:focus-visible,
.tab-btn:focus-visible,
.custom-checkbox:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Mobile Adjustments */
@media (max-width: 480px) {
  .form-card {
    padding: 2rem 1.5rem;
  }

  .logo-text {
    font-size: 1.5rem;
  }

  .welcome-text h1 {
    font-size: 1.25rem;
  }

  .social-btn span {
    display: none;
  }
}
