/* ─── Auth Pages (login) ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ─── Split Layout ────────────────────────────────────────────────────────── */
.auth-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 100vh;
}

/* ─── Brand Panel ─────────────────────────────────────────────────────────── */
.auth-brand {
  background: linear-gradient(145deg, #0D2A1E 0%, #1B4332 50%, #0A1628 100%);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.auth-brand::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 20% 80%, rgba(82,183,136,0.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(14,165,233,0.06) 0%, transparent 40%),
    radial-gradient(circle at 60% 60%, rgba(245,158,11,0.04) 0%, transparent 40%);
  pointer-events: none;
}
/* Subtle grid pattern */
.auth-brand::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(82,183,136,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(82,183,136,0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  pointer-events: none;
}
.auth-brand-inner {
  position: relative;
  z-index: 1;
  padding: 48px;
  max-width: 420px;
  display: flex;
  flex-direction: column;
  gap: 40px;
}
.auth-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: white;
  font-family: 'Rajdhani', sans-serif;
  font-size: 1.5rem;
  font-weight: 500;
  letter-spacing: 0.02em;
}
.auth-logo strong { font-weight: 700; color: #F59E0B; }
.auth-brand-text h1 {
  font-family: 'Rajdhani', sans-serif;
  font-size: 2.4rem;
  font-weight: 700;
  color: white;
  line-height: 1.1;
  letter-spacing: 0.02em;
  margin-bottom: 16px;
}
.auth-brand-text p {
  font-size: 0.95rem;
  color: rgba(255,255,255,0.6);
  line-height: 1.7;
}
.auth-brand-features {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.auth-feature {
  display: flex;
  align-items: center;
  gap: 14px;
  color: rgba(255,255,255,0.75);
  font-size: 0.9rem;
}
.auth-feature svg {
  width: 18px;
  height: 18px;
  color: #52B788;
  flex-shrink: 0;
}
.auth-quote {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 1rem;
  color: rgba(245,158,11,0.75);
  border-left: 2px solid rgba(245,158,11,0.3);
  padding-left: 16px;
  line-height: 1.6;
}

/* ─── Form Panel ─────────────────────────────────────────────────────────── */
.auth-form-panel {
  background: #FAFAF8;
  display: flex;
  align-items: center;
  justify-content: center;
}
.auth-form-inner {
  width: 100%;
  max-width: 400px;
  padding: 48px 40px;
}
.auth-form-header {
  margin-bottom: 32px;
}
.auth-form-header h2 {
  font-family: 'Rajdhani', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: #1B4332;
  margin-bottom: 8px;
  letter-spacing: 0.02em;
}
.auth-form-header p {
  font-size: 0.92rem;
  color: #6B7280;
}

/* ─── Form Fields ────────────────────────────────────────────────────────── */
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-group label {
  font-size: 0.84rem;
  font-weight: 500;
  color: #374151;
}
.form-group input {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid #D1D5DB;
  border-radius: 7px;
  font-size: 0.95rem;
  color: #111827;
  background: white;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-group input:focus {
  border-color: #2D6A4F;
  box-shadow: 0 0 0 3px rgba(45,106,79,0.1);
}
.form-group input.error {
  border-color: #DC2626;
  box-shadow: 0 0 0 3px rgba(220,38,38,0.08);
}

/* Password field */
.password-wrap { position: relative; }
.password-wrap input { padding-right: 44px; }
.password-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  color: #9CA3AF;
  display: flex;
  align-items: center;
  padding: 4px;
  transition: color 0.2s;
}
.password-toggle:hover { color: #374151; }
.password-toggle svg { width: 18px; height: 18px; }

/* ─── Submit Button ──────────────────────────────────────────────────────── */
.btn-auth {
  width: 100%;
  padding: 12px;
  background: #1B4332;
  color: white;
  border: none;
  border-radius: 7px;
  font-family: 'Rajdhani', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 8px;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}
.btn-auth:hover {
  background: #0D2A1E;
  transform: translateY(-1px);
  box-shadow: 0 8px 20px rgba(27,67,50,0.3);
}
.btn-auth:active { transform: translateY(0); }
.btn-auth:disabled {
  background: #9CA3AF;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ─── Spinner ────────────────────────────────────────────────────────────── */
.spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── Error Message ──────────────────────────────────────────────────────── */
.auth-error {
  background: #FEF2F2;
  border: 1px solid #FECACA;
  border-radius: 7px;
  padding: 12px 16px;
  font-size: 0.875rem;
  color: #B91C1C;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.auth-error::before {
  content: '⚠';
  font-size: 1rem;
  flex-shrink: 0;
}

/* ─── Back Link ──────────────────────────────────────────────────────────── */
.auth-back {
  margin-top: 28px;
  text-align: center;
}
.auth-back a {
  font-size: 0.875rem;
  color: #6B7280;
  text-decoration: none;
  transition: color 0.2s;
}
.auth-back a:hover { color: #2D6A4F; }

/* ─── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .auth-split { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .auth-form-panel { min-height: 100vh; background: white; }
  .auth-form-inner { padding: 48px 28px; }
}
