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

:root {
  --ink: #0d0d12;
  --ink2: #3a3a4a;
  --muted: #7a7a90;
  --accent: #4f46e5;
  --accent2: #7c3aed;
  --surface: #ffffff;
  --surface2: #f8f7ff;
  --border: #e5e3f5;
  --success: #059669;
  --error: #dc2626;
  --radius: 14px;
  --font-head: "Poppins", sans-serif;
  --font-body: "DM Sans", sans-serif;
}

body.auth-page {
  font-family: var(--font-body);
  background: var(--surface);
  min-height: 100vh;
  display: flex;
}

/* ── Split layout ─────────────────────────────────────────────────────────── */
.auth-split {
  display: flex;
  width: 100%;
  min-height: 100vh;
}

/* Brand panel */
.auth-brand {
  flex: 0 0 45%;
  background: linear-gradient(
    145deg,
    #1e1b4b 0%,
    #312e81 40%,
    #4338ca 75%,
    #6d28d9 100%
  );
  padding: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.auth-brand::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      ellipse 60% 60% at 80% 20%,
      rgba(139, 92, 246, 0.25) 0%,
      transparent 60%
    ),
    radial-gradient(
      ellipse 40% 40% at 10% 80%,
      rgba(99, 102, 241, 0.2) 0%,
      transparent 60%
    );
}

.brand-inner {
  position: relative;
  z-index: 1;
  max-width: 380px;
  color: #fff;
}

.brand-logo {
  width: 56px;
  height: 56px;
  background: rgba(255, 255, 255, 0.15);
  border: 1.5px solid rgba(255, 255, 255, 0.3);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2rem;
  backdrop-filter: blur(10px);
}

.logo-mark {
  font-family: var(--font-head);
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
}

.brand-title {
  font-family: var(--font-head);
  font-size: 2.6rem;
  font-weight: 700;
  line-height: 1.15;
  color: #fff;
  margin-bottom: 1rem;
}

.brand-title em {
  font-style: normal;
  background: linear-gradient(90deg, #a5f3fc, #c4b5fd);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.brand-sub {
  color: rgba(255, 255, 255, 0.7);
  font-size: 1rem;
  line-height: 1.65;
  margin-bottom: 2rem;
}

.brand-stats {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.stat-num {
  font-family: var(--font-head);
  font-size: 1.9rem;
  font-weight: 700;
  color: #fff;
  line-height: 1;
}

.stat-lbl {
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.55);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Floating cards */
.floating-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.fc {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 24px;
  padding: 0.4rem 0.85rem;
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  animation: floatIn 0.6s ease both;
}

.fc-1 {
  animation-delay: 0.1s;
}
.fc-2 {
  animation-delay: 0.2s;
}
.fc-3 {
  animation-delay: 0.3s;
}
.fc-4 {
  animation-delay: 0.4s;
}

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

/* Feature list (register) */
.feature-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.feat {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.8);
}

.feat i {
  color: #6ee7b7;
  font-size: 1rem;
  flex-shrink: 0;
}

/* ── Form panel ───────────────────────────────────────────────────────────── */
.auth-form-panel {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
  background: var(--surface);
}

.auth-form-inner {
  width: 100%;
  max-width: 420px;
}

.form-header {
  margin-bottom: 2rem;
}

.form-header h2 {
  font-family: var(--font-head);
  font-size: 2.15rem;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 0.4rem;
}

.form-header p {
  color: var(--muted);
  font-size: 0.95rem;
}

/* Fields */
.field-group {
  margin-bottom: 1rem;
}

.field-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--ink2);
  margin-bottom: 0.4rem;
  letter-spacing: 0.02em;
}

.input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.input-wrap > i:first-child {
  position: absolute;
  left: 0.9rem;
  color: var(--muted);
  font-size: 1rem;
  pointer-events: none;
  z-index: 1;
}

.field-input {
  width: 100%;
  padding: 0.7rem 1rem 0.7rem 2.5rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink);
  background: var(--surface2);
  transition:
    border-color 0.2s,
    box-shadow 0.2s,
    background 0.2s;
  outline: none;
}

.field-input:focus {
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.pwd-toggle {
  position: absolute;
  right: 0.75rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--muted);
  padding: 0.25rem;
  transition: color 0.2s;
}

.pwd-toggle:hover {
  color: var(--accent);
}

/* Buttons */
.btn-primary-full {
  width: 100%;
  padding: 0.8rem 1.5rem;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: #fff;
  border: none;
  border-radius: var(--radius);
  font-family: var(--font-head);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  transition:
    opacity 0.2s,
    transform 0.1s,
    box-shadow 0.2s;
  box-shadow: 0 4px 18px rgba(79, 70, 229, 0.35);
  text-decoration: none;
  margin-top: 1.5rem;
}

.btn-primary-full:hover {
  opacity: 0.92;
  transform: translateY(-1px);
  box-shadow: 0 6px 22px rgba(79, 70, 229, 0.4);
}

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

.btn-outline-full {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.75rem 1.5rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink2);
  text-decoration: none;
  transition:
    border-color 0.2s,
    background 0.2s;
}

.btn-outline-full:hover {
  border-color: var(--accent);
  background: var(--surface2);
  color: var(--accent);
}

.auth-divider {
  text-align: center;
  margin: 1.25rem 0;
  position: relative;
  color: var(--muted);
  font-size: 0.8rem;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 38%;
  height: 1px;
  background: var(--border);
}

.auth-divider::before {
  left: 0;
}
.auth-divider::after {
  right: 0;
}

/* Alerts */
.alert-custom {
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.alert-error {
  background: #fef2f2;
  color: var(--error);
  border: 1px solid #fecaca;
}
.alert-success {
  background: #f0fdf4;
  color: var(--success);
  border: 1px solid #bbf7d0;
}

/* ── Responsive ───────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .auth-split {
    flex-direction: column;
  }
  .auth-brand {
    flex: none;
    padding: 2rem 1.5rem;
    min-height: 220px;
  }
  .brand-title {
    font-size: 1.9rem;
  }
  .brand-stats {
    display: none;
  }
  .floating-cards {
    display: none;
  }
  .auth-form-panel {
    padding: 2rem 1.25rem;
  }
}
