:root {
  --color-primary: #5850ec;
  --color-primary-light: #818cf8;
  --color-primary-muted: #ede9fe;
  --color-surface: #ffffff;
  --color-border: #e2e0f5;
  --color-text: #18181b;
  --color-text-muted: #6b7280;
  --color-text-faint: #a1a1aa;
  --color-danger: #ef4444;
  --color-success: #22c55e;
  --font-display: 'Sora', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 20px;
  --space-6: 24px;
  --space-8: 32px;
  --radius-md: 10px;
  --radius-xl: 24px;
  --radius-full: 9999px;
  --text-sm: 0.875rem;
  --text-2xl: 1.5rem;
}

.auth-body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
}

.auth-page {
  min-height: 100vh;
  display: flex;
  width: 100%;
  background: linear-gradient(135deg, #0c0b14 0%, #1a193a 50%, #0c0b14 100%);
}

.auth-deco {
  flex: 1;
  display: none;
  flex-direction: column;
  justify-content: center;
  padding: 48px 56px;
  background: linear-gradient(135deg, rgba(88, 80, 236, 0.2), rgba(129, 140, 248, 0.08));
  border-right: 1px solid rgba(255, 255, 255, 0.06);
}

@media (min-width: 901px) {
  .auth-deco {
    display: flex;
  }
}

.auth-deco-inner {
  max-width: 420px;
}

.auth-deco-logo img {
  display: block;
  max-width: 160px;
  height: auto;
  filter: brightness(0) invert(1);
  opacity: 0.95;
}

.auth-deco-headline {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin: var(--space-6) 0 var(--space-4);
}

.auth-deco-quote {
  font-size: var(--text-sm);
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.7;
  margin: 0 0 var(--space-4);
}

.auth-deco-testimonials {
  margin-top: var(--space-8);
}

.auth-deco-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-primary-light, #818cf8);
  margin-right: 8px;
}

.auth-form-panel {
  width: 100%;
  max-width: 50%;
  flex-shrink: 0;
  background: var(--color-surface);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--space-8) var(--space-6);
  overflow-y: auto;
  min-height: 100vh;
  box-sizing: border-box;
}

@media (max-width: 900px) {
  .auth-form-panel {
    max-width: none;
    padding: var(--space-6) var(--space-5);
  }
}

.auth-card {
  background: transparent;
  border-radius: 0;
  padding: 0;
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  box-shadow: none;
}

.auth-logo {
  text-align: center;
  margin-bottom: var(--space-6);
}

.auth-logo img {
  height: 40px;
}

.auth-title {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 700;
  text-align: center;
  margin: 0 0 var(--space-6);
}

.form-group {
  margin-bottom: var(--space-4);
}

.form-label {
  display: block;
  font-size: var(--text-sm);
  font-weight: 500;
  margin-bottom: 6px;
}

.form-input {
  width: 100%;
  box-sizing: border-box;
  padding: 10px 14px;
  font-size: var(--text-sm);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
}

.form-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(88, 80, 236, 0.25);
}

.form-error {
  color: var(--color-danger);
  font-size: 0.75rem;
  margin-top: 4px;
}

.alert {
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  margin-bottom: var(--space-4);
}

.alert-success {
  background: #ecfdf5;
  color: #166534;
}

.alert-error {
  background: #fef2f2;
  color: #991b1b;
}

.alert-info-box {
  background: #e0f2ff;
  color: #1e40af;
  padding: 12px 16px;
  border-radius: 8px;
  border: 1px solid #bfdbfe;
  font-size: var(--text-sm);
  margin-bottom: 1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 10px 20px;
  border-radius: var(--radius-full);
  font-family: var(--font-display);
  font-size: var(--text-sm);
  font-weight: 500;
  cursor: pointer;
  border: 2px solid transparent;
  text-decoration: none;
}

.btn-primary {
  background: var(--color-primary);
  color: #fff;
  width: 100%;
}

.btn-primary:hover {
  filter: brightness(0.95);
}

.btn-ghost {
  background: transparent;
  color: var(--color-text-muted);
  border-color: transparent;
}

.btn-oauth {
  width: 100%;
  justify-content: center;
  background: #f3f2fc;
  color: var(--color-text);
  border: 1px solid var(--color-border);
  margin-bottom: var(--space-2);
}

.btn-oauth:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin: var(--space-5) 0;
  color: var(--color-text-faint);
  font-size: var(--text-sm);
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--color-border);
}

.auth-footer {
  text-align: center;
  margin-top: var(--space-5);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
}

.auth-footer a {
  color: var(--color-primary);
  font-weight: 600;
  text-decoration: none;
}

.step-indicator {
  display: flex;
  align-items: center;
  margin-bottom: var(--space-6);
}

.step {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-sm);
  font-weight: 700;
  flex-shrink: 0;
  background: #f3f2fc;
  color: var(--color-text-muted);
  border: 2px solid var(--color-border);
}

.step.active {
  background: var(--color-primary);
  color: #fff;
  border-color: var(--color-primary);
}

.step.done {
  background: var(--color-success);
  color: #fff;
  border-color: var(--color-success);
}

.step-line {
  flex: 1;
  height: 2px;
  background: var(--color-border);
}

.interest-grid {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.interest-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
  font-size: var(--text-sm);
  cursor: pointer;
}

.interest-pill input {
  accent-color: var(--color-primary);
}

.role-select-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-3);
}

.role-select-card {
  position: relative;
  border: 2px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-6) var(--space-4);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.role-select-card:hover {
  border-color: var(--color-primary);
  background: rgba(237, 233, 254, 0.45);
}

.role-select-card.selected {
  border-color: var(--color-primary);
  background: var(--color-primary-muted);
  box-shadow: 0 0 0 3px rgba(88, 80, 236, 0.2);
}

.role-select-card input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.role-check {
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--color-primary);
  color: #fff;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
}

.role-select-card.selected .role-check {
  display: flex;
}

.role-icon {
  font-size: 2.25rem;
  margin-bottom: var(--space-3);
}

.role-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 800;
  margin-bottom: var(--space-2);
}

.role-desc {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  line-height: 1.5;
}

.role-meta {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-top: var(--space-3);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.register-step {
  display: none;
}

.register-step.is-active {
  display: block;
}

.row-actions {
  display: flex;
  justify-content: space-between;
  gap: var(--space-3);
  margin-top: var(--space-6);
}

.password-field-wrap {
  position: relative;
}

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

.password-toggle-btn {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  cursor: pointer;
  padding: 6px;
  color: var(--color-text-muted);
  border-radius: var(--radius-md);
  line-height: 1;
}

.password-toggle-btn:hover {
  color: var(--color-primary);
  background: rgba(237, 233, 254, 0.6);
}

.password-toggle-btn:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

.strength-meter {
  margin-top: 8px;
  height: 6px;
  border-radius: var(--radius-full);
  background: #e5e7eb;
  overflow: hidden;
}

.strength-meter-fill {
  height: 100%;
  width: 0%;
  border-radius: var(--radius-full);
  transition: width 0.2s ease, background 0.2s ease;
}

.strength-label {
  font-size: 0.7rem;
  color: var(--color-text-muted);
  margin-top: 4px;
}

.otp-inputs {
  display: flex;
  gap: var(--space-3);
  justify-content: center;
  flex-wrap: wrap;
  margin: var(--space-4) 0;
}

.otp-input {
  width: 48px;
  height: 56px;
  border-radius: var(--radius-md);
  border: 2px solid var(--color-border);
  background: #f9fafb;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 800;
  text-align: center;
  color: var(--color-primary);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.otp-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(88, 80, 236, 0.25);
}

.alert-danger-box {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: #fef2f2;
  border-left: 4px solid var(--color-danger);
  color: #991b1b;
  font-size: var(--text-sm);
  margin-bottom: var(--space-4);
}

.alert-warning-box {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: #fffbeb;
  border-left: 4px solid #f59e0b;
  color: #92400e;
  font-size: var(--text-sm);
  margin-bottom: var(--space-4);
}

.form-group.has-error .form-input {
  border-color: var(--color-danger);
}

.step-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--color-text-muted);
  margin-top: -8px;
  margin-bottom: var(--space-4);
}

.step-labels span {
  flex: 1;
  text-align: start;
}

.step-labels span:nth-child(2) {
  text-align: center;
}

.step-labels span:nth-child(3) {
  text-align: right;
}