/* ================================================
   LOGIN PAGE — Premium Security UI
   ================================================ */

:root {
  --bg-primary: #06060b;
  --glass-bg: rgba(12, 12, 22, 0.6);
  --glass-border: rgba(255, 255, 255, 0.06);
  --text-primary: #e8e8f0;
  --text-secondary: #8a8a9e;
  --text-muted: #55556a;
  --purple: #7c4dff;
  --purple-dim: rgba(124, 77, 255, 0.15);
  --blue: #448aff;
  --red: #ff1744;
  --red-dim: rgba(255, 23, 68, 0.15);
  --green: #00e676;
  --radius: 16px;
  --radius-sm: 10px;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

/* Background orbs */
.bg-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.4;
  pointer-events: none;
  animation: float 20s ease-in-out infinite;
}

.bg-orb-1 {
  width: 400px; height: 400px;
  background: rgba(124, 77, 255, 0.15);
  top: -100px; left: -100px;
}

.bg-orb-2 {
  width: 300px; height: 300px;
  background: rgba(68, 138, 255, 0.1);
  bottom: -50px; right: -50px;
  animation-delay: -7s;
}

.bg-orb-3 {
  width: 200px; height: 200px;
  background: rgba(0, 230, 118, 0.08);
  top: 50%; right: 20%;
  animation-delay: -14s;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -20px) scale(1.05); }
  66% { transform: translate(-20px, 20px) scale(0.95); }
}

/* Login container */
.login-container {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  padding: 20px;
  width: 100%;
  max-width: 440px;
}

/* Glass card */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
}

/* Login card */
.login-card {
  width: 100%;
  padding: 40px 36px;
  animation: slideUp 0.5s ease;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

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

.login-logo {
  font-size: 48px;
  margin-bottom: 12px;
  animation: pulse-logo 3s ease-in-out infinite;
}

@keyframes pulse-logo {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}

.login-header h1 {
  font-size: 22px;
  font-weight: 700;
  background: linear-gradient(135deg, #e8e8f0, #7c4dff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 8px;
}

.login-subtitle {
  font-size: 13px;
  color: var(--text-muted);
}

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

label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.label-icon {
  font-size: 14px;
}

input[type="email"],
input[type="password"],
input[type="text"] {
  width: 100%;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  outline: none;
  transition: all 0.3s ease;
}

input:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(124, 77, 255, 0.15);
  background: rgba(255, 255, 255, 0.06);
}

input::placeholder {
  color: var(--text-muted);
}

/* Password wrapper */
.password-wrapper {
  position: relative;
}

.toggle-password {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  font-size: 16px;
  padding: 4px;
  opacity: 0.5;
  transition: opacity 0.2s;
}

.toggle-password:hover {
  opacity: 1;
}

/* Error message */
.error-message {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: var(--red-dim);
  border: 1px solid rgba(255, 23, 68, 0.2);
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  font-size: 13px;
  color: var(--red);
  animation: shake 0.4s ease;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

/* Login button */
.login-btn {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, #7c4dff, #448aff);
  border: none;
  border-radius: var(--radius-sm);
  color: white;
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  position: relative;
  overflow: hidden;
}

.login-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(124, 77, 255, 0.3);
}

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

.login-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Loading spinner */
.loading-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Footer */
.login-footer {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--glass-border);
}

.security-badges {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}

.security-badge {
  font-size: 11px;
  color: var(--text-muted);
  padding: 4px 10px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.04);
}

/* Warning */
.login-warning {
  text-align: center;
}

.login-warning p {
  font-size: 12px;
  color: var(--text-muted);
  opacity: 0.7;
}

/* Responsive */
@media (max-width: 480px) {
  .login-card {
    padding: 28px 24px;
  }

  .login-header h1 {
    font-size: 18px;
  }

  .security-badges {
    flex-direction: column;
    align-items: center;
  }
}
