/* ════════════════════════════════════════════════════════════════════════════════
   FROGGY PIXEL – LOGIN PAGE
   Design System: Aligned with Landing / Create-Company / Designer Premium
   ════════════════════════════════════════════════════════════════════════════════ */


/* ════════════════════════════════════════════════════════════════════════════════
   🎨 SECTION 1 · DESIGN TOKENS
   ════════════════════════════════════════════════════════════════════════════════ */

:root {
  --lg-primary-700: #6d28d9;
  --lg-primary-600: #7c3aed;
  --lg-primary-500: #8b5cf6;
  --lg-primary-400: #a78bfa;
  --lg-primary-300: #c4b5fd;
  --lg-primary-200: #ddd6fe;
  --lg-primary-100: #ede9fe;
  --lg-primary-50:  #f5f3ff;

  --lg-secondary-600: #3b82f6;
  --lg-secondary-500: #60a5fa;

  --lg-accent-600: #10b981;
  --lg-accent-500: #34d399;

  --lg-neutral-950: #0f172a;
  --lg-neutral-900: #1a1f3a;
  --lg-neutral-800: #1e293b;
  --lg-neutral-700: #334155;
  --lg-neutral-600: #475569;
  --lg-neutral-500: #64748b;
  --lg-neutral-400: #94a3b8;
  --lg-neutral-300: #cbd5e1;
  --lg-neutral-200: #e2e8f0;
  --lg-neutral-100: #f1f5f9;
  --lg-neutral-50:  #f8fafc;
  --lg-white: #ffffff;

  --lg-font-display: 'Space Grotesk', system-ui, sans-serif;
  --lg-font-body:    'Inter', system-ui, sans-serif;

  --lg-radius-sm:   8px;
  --lg-radius-md:   12px;
  --lg-radius-lg:   16px;
  --lg-radius-xl:   20px;
  --lg-radius-2xl:  24px;
  --lg-radius-3xl:  32px;
  --lg-radius-full: 9999px;

  --lg-shadow-sm:  0 2px 6px rgba(0,0,0,0.06);
  --lg-shadow-md:  0 4px 12px rgba(0,0,0,0.08);
  --lg-shadow-lg:  0 8px 24px rgba(0,0,0,0.1);
  --lg-shadow-xl:  0 16px 48px rgba(0,0,0,0.12);
  --lg-shadow-2xl: 0 25px 60px rgba(0,0,0,0.18);
  --lg-shadow-glow: 0 0 60px rgba(124, 58, 237, 0.2);

  --lg-ease-out:    300ms ease-out;
  --lg-ease-spring: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);
}


/* ════════════════════════════════════════════════════════════════════════════════
   ✨ SECTION 2 · KEYFRAME ANIMATIONS
   ════════════════════════════════════════════════════════════════════════════════ */

@keyframes lg-fadeInUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes lg-fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes lg-fadeInLeft {
  from { opacity: 0; transform: translateX(-30px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes lg-fadeInRight {
  from { opacity: 0; transform: translateX(30px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes lg-scaleIn {
  from { opacity: 0; transform: scale(0.9); }
  to   { opacity: 1; transform: scale(1); }
}

@keyframes lg-float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}

@keyframes lg-blob-drift {
  0%, 100% { transform: translate(0, 0) scale(1) rotate(0deg); }
  33%      { transform: translate(20px, -30px) scale(1.06) rotate(120deg); }
  66%      { transform: translate(-15px, 15px) scale(0.95) rotate(240deg); }
}

@keyframes lg-gradient-shift {
  0%, 100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}

@keyframes lg-shimmer-sweep {
  0%   { left: -100%; }
  100% { left: 100%; }
}

@keyframes lg-pulse-soft {
  0%, 100% { opacity: 0.6; }
  50%      { opacity: 1; }
}

@keyframes lg-feature-stagger-1 { from { opacity: 0; transform: translateX(-20px); } to { opacity: 1; transform: translateX(0); } }
@keyframes lg-feature-stagger-2 { from { opacity: 0; transform: translateX(-20px); } to { opacity: 1; transform: translateX(0); } }
@keyframes lg-feature-stagger-3 { from { opacity: 0; transform: translateX(-20px); } to { opacity: 1; transform: translateX(0); } }


/* ════════════════════════════════════════════════════════════════════════════════
   🌐 SECTION 3 · PAGE SHELL — full-viewport immersive background
   ════════════════════════════════════════════════════════════════════════════════ */

.lg-shell {
  position: relative;
  width: 100%;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  overflow: hidden;
  margin: 0;
  /* Kill any inherited gaps that cause the white line */
  margin-top: -1px;
  /* Deep gradient — richer than plain purple */
  background:
    radial-gradient(ellipse at 20% 80%, rgba(59, 130, 246, 0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(16, 185, 129, 0.08) 0%, transparent 50%),
    linear-gradient(135deg, #1e1b4b 0%, #312e81 25%, #3730a3 50%, #1e3a5f 75%, #0f172a 100%);
  font-family: var(--lg-font-body);
}

/* Reset any parent gaps causing the white line */
body:has(.lg-shell),
html:has(.lg-shell) {
  margin: 0 !important;
  padding: 0 !important;
  background: #1e1b4b !important;
}

/* Also target Dash's default wrapper */
.lg-shell * {
  box-sizing: border-box;
}

/* Decorative background blobs */
.lg-bg-blob-1 {
  position: absolute;
  width: 650px;
  height: 650px;
  background: radial-gradient(circle at 40% 40%, rgba(124, 58, 237, 0.18) 0%, transparent 55%);
  border-radius: 40% 60% 65% 35% / 45% 55% 45% 55%;
  top: -220px;
  left: -180px;
  animation: lg-blob-drift 28s ease-in-out infinite;
  filter: blur(80px);
  pointer-events: none;
}

.lg-bg-blob-2 {
  position: absolute;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle at 60% 60%, rgba(59, 130, 246, 0.14) 0%, transparent 55%);
  border-radius: 55% 45% 40% 60% / 50% 40% 60% 50%;
  bottom: -180px;
  right: -140px;
  animation: lg-blob-drift 34s ease-in-out infinite reverse;
  filter: blur(80px);
  pointer-events: none;
}

.lg-bg-blob-3 {
  position: absolute;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle at 50% 50%, rgba(16, 185, 129, 0.1) 0%, transparent 60%);
  border-radius: 35% 65% 55% 45% / 55% 35% 65% 45%;
  top: 50%;
  left: 60%;
  animation: lg-blob-drift 22s ease-in-out infinite;
  filter: blur(60px);
  pointer-events: none;
}

/* Grid overlay */
.lg-bg-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
}

/* Noise texture overlay */
.lg-bg-noise {
  position: absolute;
  inset: 0;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  pointer-events: none;
}


/* ════════════════════════════════════════════════════════════════════════════════
   📦 SECTION 4 · MAIN CONTAINER — two-panel split
   ════════════════════════════════════════════════════════════════════════════════ */

.lg-container {
  position: relative;
  z-index: 1;
  display: flex;
  width: 100%;
  max-width: 1060px;
  min-height: 580px;
  max-height: 720px;
  border-radius: var(--lg-radius-3xl);
  overflow: hidden;
  box-shadow:
    var(--lg-shadow-2xl),
    var(--lg-shadow-glow),
    0 0 0 1px rgba(255, 255, 255, 0.06) inset;
  animation: lg-scaleIn 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}


/* ════════════════════════════════════════════════════════════════════════════════
   🎆 SECTION 5 · LEFT PANEL — brand / hero (glassmorphic on dark)
   ════════════════════════════════════════════════════════════════════════════════ */

.lg-brand-panel {
  flex: 1 1 0%;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 2.75rem 2.5rem;
  color: white;
  overflow: hidden;
  /* Subtle frosted glass on the gradient */
  background:
    linear-gradient(160deg, rgba(124, 58, 237, 0.25) 0%, rgba(59, 130, 246, 0.12) 100%),
    rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(32px) saturate(1.2);
  -webkit-backdrop-filter: blur(32px) saturate(1.2);
  animation: lg-fadeInLeft 0.7s ease-out 0.15s both;
}

/* Inner decorative glow */
.lg-brand-panel::before {
  content: '';
  position: absolute;
  bottom: -80px;
  right: -80px;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.2) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

/* ─── Logo / Brand ─── */
.lg-brand-logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  margin-bottom: 2rem;
  animation: lg-fadeIn 0.8s ease-out 0.3s both;
  line-height: 1;
}

.lg-brand-logo-img {
  height: 60px;
  width: auto;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.15));
  transition: transform var(--lg-ease-out), filter var(--lg-ease-out);
}

.lg-brand-logo:hover .lg-brand-logo-img {
  transform: scale(1.03);
  filter: drop-shadow(0 4px 16px rgba(124, 58, 237, 0.25));
}

/* Mobile-only tagline — hidden on desktop, visible when hero is hidden */
.lg-brand-tagline-mobile {
  display: none;
  font-family: var(--lg-font-body);
  font-size: 0.82rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.55);
  margin: -1.25rem 0 0.5rem;
  letter-spacing: 0.01em;
  animation: lg-fadeIn 0.6s ease-out 0.5s both;
}

/* ─── Hero copy ─── */
.lg-brand-hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  animation: lg-fadeInUp 0.8s ease-out 0.4s both;
}

.lg-brand-headline {
  font-family: var(--lg-font-display);
  font-size: clamp(1.4rem, 2.5vw, 1.9rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.03em;
  margin: 0 0 0.85rem;
  background: linear-gradient(135deg, #ffffff 0%, rgba(255,255,255,0.75) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.lg-brand-subtext {
  font-size: 0.9rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.65);
  margin: 0;
  max-width: 380px;
}

/* ─── Feature list ─── */
.lg-features {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  animation: lg-fadeInUp 0.8s ease-out 0.6s both;
}

.lg-feature-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--lg-radius-md);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.07);
  transition: all var(--lg-ease-out);
  backdrop-filter: blur(6px);
}

.lg-feature-item:nth-child(1) { animation: lg-feature-stagger-1 0.5s ease-out 0.7s both; }
.lg-feature-item:nth-child(2) { animation: lg-feature-stagger-2 0.5s ease-out 0.85s both; }
.lg-feature-item:nth-child(3) { animation: lg-feature-stagger-3 0.5s ease-out 1.0s both; }

.lg-feature-item:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.12);
  transform: translateX(4px);
}

.lg-feature-icon {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.35) 0%, rgba(59, 130, 246, 0.25) 100%);
  border-radius: var(--lg-radius-sm);
  color: white;
  font-size: 0.85rem;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(124, 58, 237, 0.2);
}

.lg-feature-text {
  font-size: 0.82rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.8);
  line-height: 1.4;
}

/* ─── Trust badge ─── */
.lg-trust {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  animation: lg-fadeIn 0.8s ease-out 1.1s both;
}

.lg-trust-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--lg-accent-500);
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
  animation: lg-pulse-soft 2s ease-in-out infinite;
}

.lg-trust-text {
  font-size: 0.72rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.45);
  letter-spacing: 0.02em;
}


/* ════════════════════════════════════════════════════════════════════════════════
   📝 SECTION 6 · RIGHT PANEL — login form (clean white)
   ════════════════════════════════════════════════════════════════════════════════ */

.lg-form-panel {
  flex: 0 0 420px;
  background: var(--lg-white);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 3rem 2.75rem;
  position: relative;
  animation: lg-fadeInRight 0.7s ease-out 0.2s both;
}

/* Subtle gradient accent at top */
.lg-form-panel::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--lg-primary-600), var(--lg-secondary-600), var(--lg-accent-600));
}

/* Watermark logo — brand cohesion */
.lg-form-watermark {
  position: absolute;
  bottom: 20px;
  right: 20px;
  width: 120px;
  height: auto;
  opacity: 0.045;
  pointer-events: none;
  user-select: none;
  filter: grayscale(1) brightness(0);
}

/* Inner wrapper to control width */
.lg-form-inner {
  width: 100%;
  max-width: 320px;
}

/* ─── Welcome badge ─── */
.lg-welcome-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.9rem;
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.08) 0%, rgba(59, 130, 246, 0.05) 100%);
  border: 1.5px solid rgba(124, 58, 237, 0.15);
  border-radius: var(--lg-radius-full);
  font-family: var(--lg-font-display);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--lg-primary-600);
  margin-bottom: 1.25rem;
  animation: lg-fadeInUp 0.5s ease-out 0.4s both;
}

/* ─── Form heading ─── */
.lg-form-title {
  font-family: var(--lg-font-display);
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--lg-neutral-800);
  margin: 0 0 0.4rem;
  animation: lg-fadeInUp 0.5s ease-out 0.5s both;
}

.lg-form-subtitle {
  font-size: 0.85rem;
  color: var(--lg-neutral-500);
  line-height: 1.5;
  margin: 0 0 2rem;
  animation: lg-fadeInUp 0.5s ease-out 0.55s both;
}

/* ─── Divider ─── */
.lg-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.5rem 0;
  animation: lg-fadeIn 0.5s ease-out 0.8s both;
}

.lg-divider-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--lg-neutral-200), transparent);
}

.lg-divider-text {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--lg-neutral-400);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  white-space: nowrap;
}


/* ════════════════════════════════════════════════════════════════════════════════
   🔘 SECTION 7 · OAUTH BUTTONS — Premium social login
   ════════════════════════════════════════════════════════════════════════════════ */

.lg-oauth-stack {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  width: 100%;
  animation: lg-fadeInUp 0.5s ease-out 0.65s both;
}

.lg-oauth-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  width: 100%;
  padding: 0.82rem 1.25rem;
  font-family: var(--lg-font-body);
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: var(--lg-radius-md);
  cursor: pointer;
  transition: all 280ms ease-out;
  text-decoration: none !important;
  position: relative;
  overflow: hidden;
  border: 1.5px solid var(--lg-neutral-200);
  background: var(--lg-white);
  color: var(--lg-neutral-700);
}

/* Shimmer sweep on hover */
.lg-oauth-btn::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(124, 58, 237, 0.04), transparent);
  transition: left 0.5s ease;
  pointer-events: none;
}

.lg-oauth-btn:hover {
  border-color: var(--lg-primary-300);
  box-shadow: 0 4px 16px rgba(124, 58, 237, 0.1);
  transform: translateY(-2px);
  color: var(--lg-primary-600);
}

.lg-oauth-btn:hover::before {
  left: 100%;
}

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

/* Google specific */
.lg-oauth-btn--google .lg-oauth-icon {
  color: #4285f4;
}

.lg-oauth-btn--google:hover {
  border-color: rgba(66, 133, 244, 0.35);
  box-shadow: 0 4px 16px rgba(66, 133, 244, 0.12);
  color: #4285f4;
}

/* Microsoft specific */
.lg-oauth-btn--microsoft .lg-oauth-icon {
  color: #00a4ef;
}

.lg-oauth-btn--microsoft:hover {
  border-color: rgba(0, 164, 239, 0.35);
  box-shadow: 0 4px 16px rgba(0, 164, 239, 0.12);
  color: #00a4ef;
}

.lg-oauth-icon {
  font-size: 1.1rem;
  width: 22px;
  text-align: center;
  transition: transform var(--lg-ease-out);
}

.lg-oauth-btn:hover .lg-oauth-icon {
  transform: scale(1.12);
}

.lg-oauth-label {
  letter-spacing: 0.01em;
}


/* ════════════════════════════════════════════════════════════════════════════════
   📄 SECTION 8 · FOOTER LEGAL
   ════════════════════════════════════════════════════════════════════════════════ */

.lg-legal {
  margin-top: 2rem;
  text-align: center;
  animation: lg-fadeIn 0.5s ease-out 0.9s both;
}

.lg-legal-text {
  font-size: 0.68rem;
  color: var(--lg-neutral-400);
  line-height: 1.6;
  margin: 0;
}

.lg-legal-text a {
  color: var(--lg-primary-500);
  text-decoration: none;
  font-weight: 600;
  transition: color var(--lg-ease-out);
}

.lg-legal-text a:hover {
  color: var(--lg-primary-600);
  text-decoration: underline;
}


/* ════════════════════════════════════════════════════════════════════════════════
   📱 SECTION 9 · RESPONSIVE
   ════════════════════════════════════════════════════════════════════════════════ */

@media (max-width: 900px) {
  .lg-container {
    flex-direction: column;
    max-height: none;
    max-width: 480px;
  }

  .lg-brand-panel {
    padding: 2rem 2rem 1.5rem;
  }

  .lg-brand-hero {
    display: none;
  }

  .lg-features {
    display: none;
  }

  /* Show tagline when hero is hidden */
  .lg-brand-tagline-mobile {
    display: block;
  }

  .lg-trust {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
  }

  .lg-form-panel {
    flex: 1 1 auto;
    padding: 2rem 2rem;
  }

  .lg-form-watermark {
    width: 90px;
    bottom: 14px;
    right: 14px;
  }
}

@media (max-width: 576px) {
  .lg-shell {
    padding: 0.75rem;
  }

  .lg-container {
    border-radius: var(--lg-radius-2xl);
  }

  .lg-brand-panel {
    padding: 1.5rem;
  }

  .lg-form-panel {
    padding: 1.75rem 1.5rem;
  }

  .lg-form-title {
    font-size: 1.3rem;
  }
}


/* ════════════════════════════════════════════════════════════════════════════════
   ♿ SECTION 10 · A11Y & MOTION PREFS
   ════════════════════════════════════════════════════════════════════════════════ */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.lg-oauth-btn:focus-visible {
  outline: 2px solid var(--lg-primary-500);
  outline-offset: 2px;
}

::selection {
  background: rgba(124, 58, 237, 0.3);
  color: white;
}