*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

/* ── ANIMATIONS ────────────────────────────────────────────── */

/* Glow shifts between the two SX brand colors: blue → green → blue */
@keyframes logoGlow {
  0%   { filter: drop-shadow(0 0 22px rgba(96,165,250,0.35))  drop-shadow(0 0 55px rgba(37,99,235,0.18)); }
  40%  { filter: drop-shadow(0 0 32px rgba(96,165,250,0.55))  drop-shadow(0 0 70px rgba(37,99,235,0.28)); }
  70%  { filter: drop-shadow(0 0 28px rgba(74,222,128,0.45))  drop-shadow(0 0 65px rgba(46,160,100,0.22)); }
  100% { filter: drop-shadow(0 0 22px rgba(96,165,250,0.35))  drop-shadow(0 0 55px rgba(37,99,235,0.18)); }
}

/* Barely perceptible scale breathe — just "alive", not bouncing */
@keyframes logoBreathe {
  0%, 100% { transform: scale(1); }
  50%       { transform: scale(1.018); }
}

@keyframes glowPulse {
  0%, 100% { opacity: 0.50; transform: scale(1); }
  50%       { opacity: 0.80; transform: scale(1.05); }
}
@keyframes cardFadeIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes cardLogoEntrance {
  from { opacity: 0; transform: scale(0.88); }
  to   { opacity: 1; transform: scale(1); }
}

body {
  font-family: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  min-height: 100vh;
  display: flex;
  background: #f0f4f8;
  color: #1e293b;
}

/* ── LEFT BRAND PANEL — matches sidebar exactly ───────────── */
.brand-panel {
  width: 42%;
  min-height: 100vh;
  background: #051226;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 28px;
}

.glow-a {
  position: absolute;
  width: 520px; height: 520px; border-radius: 50%;
  background: radial-gradient(circle, rgba(96,165,250,0.18) 0%, transparent 65%);
  top: -160px; left: -120px;
  pointer-events: none;
  animation: glowPulse 5s ease-in-out infinite;
}
.glow-b {
  position: absolute;
  width: 380px; height: 380px; border-radius: 50%;
  background: radial-gradient(circle, rgba(59,130,246,0.12) 0%, transparent 65%);
  bottom: -80px; right: -80px;
  pointer-events: none;
  animation: glowPulse 5s ease-in-out 2.5s infinite;
}

.hex-bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}

.brand-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.brand-logo {
  width: 85%;
  max-width: 85%;
  object-fit: contain;
  margin-bottom: 32px;
  animation:
    logoBreathe 5s cubic-bezier(0.45, 0, 0.55, 1) infinite,
    logoGlow    6s cubic-bezier(0.45, 0, 0.55, 1) infinite;
}

.brand-tagline {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.38);
}

/* ── RIGHT FORM PANEL ──────────────────────────────────────── */
.form-panel {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 32px;
  background: #dfe8f5;
  overflow: hidden;
}

/* Subtle orbs — ambient color for the glass card to blur through */
.orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(48px);
}
.orb-1 {
  width: 180px; height: 180px;
  background: radial-gradient(circle, rgba(96,165,250,0.30) 0%, transparent 70%);
  top: 10%; right: 10%;
  animation: glowPulse 7s ease-in-out infinite;
}
.orb-2 {
  width: 150px; height: 150px;
  background: radial-gradient(circle, rgba(33,65,136,0.20) 0%, transparent 70%);
  bottom: 15%; left: 8%;
  animation: glowPulse 7s ease-in-out 3.5s infinite;
}
.orb-3 {
  width: 120px; height: 120px;
  background: radial-gradient(circle, rgba(74,222,128,0.18) 0%, transparent 70%);
  top: 50%; left: 50%;
  animation: glowPulse 9s ease-in-out 1.5s infinite;
}

/* Hex pattern */
.form-hex-bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  opacity: 1;
}

/* Dark frosted glass card */
.form-card {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 400px;
  background: rgba(5, 18, 38, 0.88);
  backdrop-filter: blur(28px) saturate(140%);
  -webkit-backdrop-filter: blur(28px) saturate(140%);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 20px;
  padding: 44px 40px 36px;
  box-shadow:
    0 32px 80px rgba(0, 0, 0, 0.22),
    0 8px 24px rgba(0, 0, 0, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  animation: cardFadeIn 0.6s ease-out both;
}

/* Card branding */
.card-logo {
  display: block;
  height: 60px;
  width: auto;
  margin: 0 auto 20px;
  object-fit: contain;
  animation: cardLogoEntrance 0.5s ease-out 0.3s both;
}

.card-title {
  font-family: 'Quicksand', sans-serif;
  font-size: 17px; font-weight: 700;
  letter-spacing: 2.5px;
  color: #ffffff;
  text-align: center;
  margin-bottom: 5px;
}

.card-subtitle {
  font-family: 'Quicksand', sans-serif;
  font-size: 12px; font-weight: 700;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #93c5fd;
  text-align: center;
  margin-bottom: 5px;
}

.card-org {
  font-size: 9.5px; font-weight: 500;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.60);
  text-align: center;
}

.card-rule {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  margin: 24px 0;
}

/* Error alert */
.alert {
  display: flex; align-items: center; gap: 9px;
  border-radius: 8px; padding: 10px 13px;
  font-size: 12.5px; margin-bottom: 18px;
  background: rgba(239,68,68,0.12);
  border: 1px solid rgba(239,68,68,0.30);
  color: #fca5a5;
}
.alert svg {
  width: 14px; height: 14px; flex-shrink: 0;
  stroke: #fca5a5; fill: none;
  stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}

/* Form fields */
.form-group { margin-bottom: 14px; }

.form-label {
  display: block; font-size: 10px; font-weight: 600;
  letter-spacing: 1.5px; text-transform: uppercase;
  color: rgba(255,255,255,0.80); margin-bottom: 7px;
}

.input-wrap { position: relative; }

.input-icon {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  width: 14px; height: 14px; pointer-events: none;
  stroke: rgba(255,255,255,0.28); fill: none;
  stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}

.form-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  padding: 11px 14px 11px 36px;
  font-size: 14px; color: #e2e8f0; font-family: inherit;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s; outline: none;
}
.form-input:focus {
  border-color: rgba(96,165,250,0.60);
  box-shadow: 0 0 0 3px rgba(96,165,250,0.15);
  background: rgba(255, 255, 255, 0.11);
}
.form-input::placeholder { color: rgba(255,255,255,0.22); }

/* Sign In button */
.btn-signin {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%;
  background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 60%, #3b82f6 100%);
  border: none;
  border-radius: 8px;
  padding: 12px 20px;
  font-size: 12.5px; font-weight: 700; cursor: pointer; font-family: inherit;
  color: #fff;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-top: 4px;
  transition: opacity 0.15s, box-shadow 0.15s, transform 0.1s;
  box-shadow: 0 4px 24px rgba(37,99,235,0.50);
}
.btn-signin svg {
  width: 15px; height: 15px; flex-shrink: 0;
  stroke: rgba(255,255,255,0.85); fill: none;
  stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}
.btn-signin:hover {
  opacity: 0.92;
  box-shadow: 0 6px 32px rgba(37,99,235,0.65);
}
.btn-signin:active { transform: scale(0.985); }

/* OR divider */
.divider {
  display: flex; align-items: center; gap: 12px;
  margin: 18px 0; font-size: 10px; font-weight: 600;
  letter-spacing: 1.5px; text-transform: uppercase;
  color: rgba(255,255,255,0.25);
}
.divider::before, .divider::after {
  content: ''; flex: 1; height: 1px;
  background: rgba(255,255,255,0.09);
}

/* Google button */
.btn-google {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  width: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  padding: 11px 14px;
  font-size: 13.5px; font-weight: 500;
  cursor: pointer; font-family: inherit;
  color: #e2e8f0;
  transition: background 0.15s, border-color 0.15s;
}
.btn-google:hover {
  background: rgba(255, 255, 255, 0.13);
  border-color: rgba(255, 255, 255, 0.22);
}

/* Card footer */
.card-footer {
  margin-top: 26px; text-align: center;
  font-size: 10px; color: rgba(255,255,255,0.45); letter-spacing: 0.5px;
}

/* ── RESPONSIVE ────────────────────────────────────────────── */
@media (max-width: 840px) {
  body { flex-direction: column; background: #dfe8f5; }
  .brand-panel { width: 100%; min-height: auto; padding: 32px 24px; }
  .form-panel { padding: 32px 20px; }
  .form-card { padding: 36px 28px 28px; }
}
