/* ==========================================================================
   FastNetDesk - Landing / Login Page
   Gold & Blue glassmorphism design — uses helpdesk BEM orb system
   ========================================================================== */

/* ---------- Custom Properties ---------- */
:root {
  --gold: #E8B84B;
  --gold-light: #F5DFA0;
  --gold-deep: #C9962D;
  --blue: #3b82f6;
  --blue-light: #60a5fa;
  --blue-deep: #2563eb;
  --blue-glow: #60a5fa;
  --slate-50: #f8fafc;
  --slate-100: #f1f5f9;
  --slate-200: #e2e8f0;
  --slate-300: #cbd5e1;
  --slate-400: #94a3b8;
  --slate-500: #64748b;
  --slate-600: #475569;
  --slate-700: #334155;
  --slate-800: #1e293b;
  --slate-900: #0f172a;
  --font-sans: 'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 20px;
  --radius-3xl: 24px;
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

html {
  font-family: var(--font-sans);
  font-feature-settings: 'cv02', 'cv03', 'cv04';
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--slate-900);
}

/* ==========================================================================
   Background Layer (gradient + orbs + lightning)
   ========================================================================== */
.bg-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.bg-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(140deg, #0D1B3E, #1B3869, #0A2344, #111827);
  background-size: 300% 300%;
  animation: gradientShift 18s ease infinite;
}

@keyframes gradientShift { 0% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } }

.bg-orbs {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.bg-orbs img {
  position: absolute;
  filter: hue-rotate(195deg) saturate(1.4) brightness(1.1);
  object-fit: contain;
  pointer-events: none;
}

@keyframes floatSlow { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 25% { transform: translate(20px, -25px) rotate(3deg); } 50% { transform: translate(-15px, 20px) rotate(-4deg); } 75% { transform: translate(25px, 15px) rotate(5deg); } }
@keyframes floatSlow2 { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 25% { transform: translate(-18px, 30px) rotate(-3deg); } 50% { transform: translate(22px, -18px) rotate(5deg); } 75% { transform: translate(-12px, -20px) rotate(-6deg); } }
@keyframes floatMedium { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 33% { transform: translate(-25px, 20px) rotate(5deg); } 66% { transform: translate(20px, -30px) rotate(-6deg); } }
@keyframes floatMedium2 { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 33% { transform: translate(30px, -15px) rotate(-5deg); } 66% { transform: translate(-20px, 28px) rotate(7deg); } }
@keyframes floatFast { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 25% { transform: translate(18px, -15px) rotate(6deg); } 50% { transform: translate(-22px, 25px) rotate(-10deg); } 75% { transform: translate(28px, -18px) rotate(12deg); } }
@keyframes floatFast2 { 0%, 100% { transform: translate(0, 0) rotate(0deg); } 25% { transform: translate(-20px, 18px) rotate(-8deg); } 50% { transform: translate(25px, -22px) rotate(10deg); } 75% { transform: translate(-15px, 12px) rotate(-6deg); } }

/* ---------- Container ---------- */
.login-container {
  position: relative;
  z-index: 2;
  display: flex;
  min-height: 100vh;
  padding: 32px;
  gap: 32px;
  max-width: 1440px;
  margin: 0 auto;
}

/* ---------- Features Panel (60%) ---------- */
.features-panel {
  flex: 0 0 58%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 24px 0;
}

.features-header {
  margin-bottom: 36px;
}

.features-logo {
  height: 56px;
  width: auto;
  margin-bottom: 16px;
  filter: drop-shadow(0 4px 12px rgba(45, 125, 210, 0.3));
}

.features-title {
  font-size: 42px;
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.1;
  background: linear-gradient(135deg, var(--blue) 0%, var(--gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 8px;
}

.features-subtitle {
  font-size: 16px;
  font-weight: 500;
  color: var(--slate-400);
  letter-spacing: -0.01em;
}

/* ---------- Masonry Grid ---------- */
.masonry-grid {
  columns: 2;
  column-gap: 20px;
}

.feature-card {
  break-inside: avoid;
  margin-bottom: 20px;
  padding: 24px;
  background: rgba(18, 18, 18, 0.5);
  backdrop-filter: blur(40px) saturate(1.3);
  -webkit-backdrop-filter: blur(40px) saturate(1.3);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-2xl);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: transform 0.4s var(--ease-spring), box-shadow 0.4s ease;
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: 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.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.03;
  pointer-events: none;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.feature-card--tall {
  padding: 28px 24px;
}

.feature-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, rgba(45, 125, 210, 0.18), rgba(245, 195, 68, 0.12));
  margin-bottom: 16px;
}

.feature-icon svg,
.feature-icon .iconify {
  width: 24px;
  height: 24px;
  color: var(--blue-light);
}

.feature-card__title {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--slate-200);
  margin-bottom: 8px;
}

.feature-card__desc {
  font-size: 13px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--slate-400);
}

/* ---------- Login Panel (40%) ---------- */
.login-panel {
  flex: 0 0 38%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 0;
}

.login-card {
  width: 100%;
  max-width: 400px;
  padding: 40px 36px;
  background: rgba(13, 27, 62, 0.65);
  backdrop-filter: blur(60px) saturate(1.4);
  -webkit-backdrop-filter: blur(60px) saturate(1.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-3xl);
  box-shadow:
    0 24px 80px rgba(0, 0, 0, 0.5),
    0 8px 24px rgba(0, 0, 0, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  position: relative;
  overflow: hidden;
}

.login-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: 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.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.03;
  pointer-events: none;
}

.login-card > * {
  position: relative;
  z-index: 1;
}

/* Login card header */
.login-card__header {
  text-align: center;
  margin-bottom: 32px;
}

.login-card__logo {
  height: 64px;
  width: auto;
  margin-bottom: 16px;
  filter: drop-shadow(0 4px 16px rgba(45, 125, 210, 0.5)) brightness(1.1);
}

.login-card__title {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, var(--blue-deep), var(--blue-light));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 4px;
}

.login-card__subtitle {
  font-size: 14px;
  color: var(--slate-500);
  font-weight: 500;
}

/* Form */
.login-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--slate-400);
  letter-spacing: -0.01em;
}

.form-input-wrap {
  position: relative;
}

.form-input-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: var(--slate-400);
  pointer-events: none;
  transition: color 0.2s;
}

.form-input {
  width: 100%;
  height: 48px;
  padding: 0 16px 0 42px;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  color: var(--slate-200);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.form-input::placeholder {
  color: var(--slate-500);
  font-weight: 400;
}

.form-input:focus {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--blue-light);
  box-shadow: 0 0 0 3px rgba(45, 125, 210, 0.15);
}

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

/* Sign in button */
.login-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 50px;
  margin-top: 4px;
  padding: 0 24px;
  font-family: var(--font-sans);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #0D1B3E;
  background: linear-gradient(135deg, #C9962D, #E8B84B);
  border: none;
  border-radius: var(--radius-lg);
  cursor: pointer;
  box-shadow:
    0 4px 16px rgba(201, 150, 45, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transition: transform 0.3s var(--ease-spring), box-shadow 0.3s ease;
}

.login-btn:hover {
  transform: translateY(-2px);
  box-shadow:
    0 8px 28px rgba(232, 184, 75, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

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

.login-btn__icon {
  width: 20px;
  height: 20px;
}

/* Error message */
.login-error {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  margin-bottom: 20px;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 500;
  color: #f87171;
}

.login-error .iconify { flex-shrink: 0; }

/* Divider */
.login-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
}

.login-divider::before,
.login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(45, 125, 210, 0.15), transparent);
}

.login-divider span {
  font-size: 12px;
  font-weight: 500;
  color: var(--slate-500);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Google sign-in button */
.google-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 46px;
  padding: 0 24px;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, #EA4335 0%, #c5221f 100%);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  text-decoration: none;
  box-shadow:
    0 4px 12px rgba(234, 67, 53, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transition: transform 0.3s var(--ease-spring), box-shadow 0.3s ease;
}

.google-btn:hover {
  transform: translateY(-2px);
  box-shadow:
    0 8px 24px rgba(234, 67, 53, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

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

.google-hint {
  text-align: center;
  font-size: 12px;
  color: var(--slate-500);
  margin-top: 8px;
}

/* Footer */
.login-card__footer {
  margin-top: 20px;
  text-align: center;
  font-size: 12px;
  color: var(--slate-500);
}

.login-card__footer strong {
  color: var(--blue-light);
  font-weight: 600;
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .login-container {
    padding: 24px;
    gap: 24px;
  }

  .features-panel { flex: 0 0 55%; }
  .login-panel    { flex: 0 0 42%; }

  .features-title { font-size: 34px; }
  .masonry-grid   { column-gap: 16px; }
}

@media (max-width: 768px) {
  .login-container {
    flex-direction: column;
    padding: 20px;
    gap: 0;
  }

  .features-panel {
    display: none;
  }

  .login-panel {
    flex: 1;
    padding: 0;
    min-height: 100vh;
  }

  .login-card {
    max-width: 420px;
    padding: 36px 28px;
  }
}

@media (max-width: 480px) {
  .login-container {
    padding: 16px;
  }

  .login-card {
    padding: 28px 20px;
    border-radius: var(--radius-2xl);
  }

  .login-card__logo { height: 52px; }
  .login-card__title { font-size: 22px; }
}

/* ---------- Reduced Motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .bg-gradient { animation: none; }
  .bg-orbs img { animation: none; }
  .feature-card { transition: none; }
  .login-btn { transition: none; }
}

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-thumb { border-radius: 10px; background-color: rgba(255, 255, 255, 0.15); }
