/* ─── Base Reset ─── */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Inter', sans-serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition: background-color 0.5s ease;
}

.hidden { display: none !important; }

/* ─── Background ─── */
.auth-background {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  background-size: 200% 200%;
  animation: gradientShift 15s ease infinite;
}

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

/* ─── Auth Card ─── */
.auth-card {
  width: 100%;
  max-width: 440px;
  margin: 20px;
  padding: 2.5rem 2rem;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 1.5rem;
  box-shadow:
    0 25px 60px rgba(0, 0, 0, 0.25),
    0 0 0 1px rgba(255, 255, 255, 0.1) inset;
  animation: cardSlideIn 0.5s ease-out;
}

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

/* ─── Logo ─── */
.auth-logo {
  text-align: center;
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, #667eea, #764ba2);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ─── Title & Subtitle ─── */
.auth-title {
  text-align: center;
  font-size: 2rem;
  font-weight: 800;
  color: #1a202c;
  margin-bottom: 0.4rem;
  letter-spacing: -0.02em;
}

.auth-subtitle {
  text-align: center;
  font-size: 0.95rem;
  color: #718096;
  margin-bottom: 2rem;
  line-height: 1.5;
}

/* ─── Form ─── */
.auth-form {
  width: 100%;
}

.form-group {
  margin-bottom: 1.2rem;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #4a5568;
  margin-bottom: 0.4rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.form-group input {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 2px solid #e2e8f0;
  border-radius: 0.75rem;
  background-color: #f7fafc;
  color: #1a202c;
  font-size: 0.95rem;
  font-family: 'Inter', sans-serif;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
  outline: none;
}

.form-group input:focus {
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.25);
  background-color: #fff;
}

.form-group input::placeholder {
  color: #a0aec0;
}

/* ─── Password Wrapper + Eye Button ─── */
.password-wrapper {
  position: relative;
  width: 100%;
}

.password-wrapper input {
  padding-right: 3rem;
}

.eye-btn {
  position: absolute;
  right: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: #a0aec0;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease;
  border-radius: 4px;
}

.eye-btn:hover {
  color: #4a5568;
}

/* ─── Remember Me ─── */
.remember-row {
  margin-bottom: 1.5rem;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: #4a5568;
}

.checkbox-label input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #667eea;
  cursor: pointer;
  border-radius: 4px;
}

/* ─── Submit Button ─── */
.auth-btn {
  width: 100%;
  padding: 0.9rem 1.5rem;
  border: none;
  border-radius: 0.75rem;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: #fff;
  font-size: 1.05rem;
  font-weight: 700;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
  box-shadow: 0 8px 25px rgba(102, 126, 234, 0.35);
  letter-spacing: 0.02em;
}

.auth-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 35px rgba(102, 126, 234, 0.45);
}

.auth-btn:active {
  transform: translateY(0);
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

/* ─── Message ─── */
.auth-message {
  text-align: center;
  font-size: 0.9rem;
  font-weight: 600;
  margin-top: 1rem;
  padding: 0.6rem 1rem;
  border-radius: 0.5rem;
}

.auth-message.error {
  color: #e53e3e;
  background: #fff5f5;
  border: 1px solid #fed7d7;
}

.auth-message.success {
  color: #38a169;
  background: #f0fff4;
  border: 1px solid #c6f6d5;
}

/* ─── Switch Link ─── */
.auth-switch {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 0.9rem;
  color: #718096;
}

.auth-link {
  color: #667eea;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.2s ease;
}

.auth-link:hover {
  color: #5a67d8;
  text-decoration: underline;
}

/* ─── Responsive ─── */
@media (max-width: 480px) {
  .auth-card {
    margin: 10px;
    padding: 2rem 1.4rem;
    border-radius: 1rem;
  }
  .auth-title {
    font-size: 1.6rem;
  }
  .auth-subtitle {
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
  }
}
