/* ============================================
   FINANCE SUITE — Auth Screen (Dark Glassmorphism)
   Gray/Black with decorative floating shapes
   ============================================ */

.auth-screen {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  width: 100%;
  background: linear-gradient(145deg, #0d0d0d 0%, #1a1a2e 30%, #16213e 60%, #0f0f0f 100%);
  position: relative;
  overflow: hidden;
}

/* Ambient glow orbs */
.auth-screen::before {
  content: '';
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(100, 100, 120, 0.08) 0%, transparent 70%);
  border-radius: 50%;
  top: -15%;
  left: -10%;
  animation: auth-drift 12s ease-in-out infinite;
}

.auth-screen::after {
  content: '';
  position: absolute;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(80, 80, 100, 0.06) 0%, transparent 70%);
  border-radius: 50%;
  bottom: -20%;
  right: -8%;
  animation: auth-drift 15s ease-in-out infinite reverse;
}

@keyframes auth-drift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(25px, -15px) scale(1.04); }
}

/* Decorative SVG shapes */
.auth-deco {
  position: absolute;
  z-index: 1;
  opacity: 0.6;
  pointer-events: none;
}

.auth-deco-1 {
  width: 260px;
  height: 260px;
  top: 8%;
  left: 5%;
  animation: auth-float-1 10s ease-in-out infinite;
}

.auth-deco-2 {
  width: 200px;
  height: 100px;
  bottom: 15%;
  left: 12%;
  animation: auth-float-2 8s ease-in-out infinite;
}

.auth-deco-3 {
  width: 180px;
  height: 180px;
  top: 20%;
  right: 8%;
  animation: auth-float-3 11s ease-in-out infinite;
}

.auth-deco-4 {
  width: 140px;
  height: 140px;
  bottom: 10%;
  right: 15%;
  animation: auth-float-4 9s ease-in-out infinite;
}

@keyframes auth-float-1 {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  50% { transform: translate(15px, -10px) rotate(5deg); }
}
@keyframes auth-float-2 {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  50% { transform: translate(-10px, 12px) rotate(-3deg); }
}
@keyframes auth-float-3 {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  50% { transform: translate(10px, 8px) rotate(4deg); }
}
@keyframes auth-float-4 {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  50% { transform: translate(-8px, -10px) rotate(-5deg); }
}

/* Glass card */
.auth-card {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(28px) saturate(1.4);
  -webkit-backdrop-filter: blur(28px) saturate(1.4);
  border-radius: 24px;
  padding: 40px 32px;
  box-shadow:
    0 8px 40px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.auth-card-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ---- Brand Section ---- */
.auth-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 32px;
}

.auth-brand-icon {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #3a3a4a, #525265);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  margin-bottom: 12px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  animation: auth-icon-pulse 3s ease-in-out infinite;
}

@keyframes auth-icon-pulse {
  0%, 100% { box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4); }
  50% { box-shadow: 0 12px 36px rgba(80, 80, 100, 0.5); }
}

.auth-brand-icon svg {
  width: 24px;
  height: 24px;
}

.auth-brand-title {
  font-size: 24px;
  font-weight: 700;
  color: #e8e8ed;
  margin-bottom: 4px;
  letter-spacing: -0.02em;
}

.auth-brand-subtitle {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.4);
  text-align: center;
}

/* ---- Auth Form ---- */
.auth-form {
  width: 100%;
  display: flex;
  flex-direction: column;
}

.auth-form .form-group {
  margin-bottom: 16px;
}

.auth-form .form-label {
  color: rgba(255, 255, 255, 0.6);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 6px;
}

.auth-form .form-input {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #e8e8ed;
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 14px;
  transition: all 0.2s ease;
}

.auth-form .form-input::placeholder {
  color: rgba(255, 255, 255, 0.25);
}

.auth-form .form-input:focus {
  border-color: rgba(160, 160, 180, 0.4);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 0 3px rgba(160, 160, 180, 0.1);
  outline: none;
}

.auth-submit {
  margin-top: 8px;
  height: 48px;
  font-size: 15px;
  font-weight: 600;
  width: 100%;
  border-radius: 12px;
  background: linear-gradient(135deg, #2a2a3a, #1a1a28);
  color: #e8e8ed;
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: all 0.2s ease;
  letter-spacing: 0.01em;
}

.auth-submit:hover {
  background: linear-gradient(135deg, #35354a, #252538);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

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

/* ---- Error Message ---- */
.auth-error {
  display: none;
  align-items: center;
  gap: 8px;
  color: #ff6b6b;
  font-size: 12px;
  margin-bottom: 16px;
  padding: 10px 14px;
  background: rgba(255, 107, 107, 0.1);
  border: 1px solid rgba(255, 107, 107, 0.15);
  border-radius: 10px;
  text-align: left;
  width: 100%;
}

.auth-error svg { width: 16px; height: 16px; flex-shrink: 0; color: #ff6b6b; }
.auth-error.visible { display: flex; }

/* ---- Footer Toggle ---- */
.auth-footer {
  margin-top: 24px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.4);
  text-align: center;
}

.auth-footer a {
  color: #a0a0b4;
  font-weight: 600;
  cursor: pointer;
  margin-left: 4px;
  transition: color 0.2s;
}

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

/* ---- Password Toggle ---- */
.password-wrapper {
  position: relative;
  width: 100%;
}

.password-wrapper .form-input {
  padding-right: 44px;
}

.password-toggle {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.4);
  transition: color 0.2s ease;
}

.password-toggle:hover {
  color: rgba(255, 255, 255, 0.7);
}

.password-toggle svg {
  width: 18px;
  height: 18px;
}

.password-toggle .hidden {
  display: none;
}

/* ---- Responsive ---- */
@media (max-width: 480px) {
  .auth-card {
    max-width: 100%;
    margin: 0 16px;
    padding: 32px 20px;
    border-radius: 20px;
  }
  .auth-deco { display: none; }
}
