/* ── CANDIDATE LOGIN PAGE ──────────────────────────────────── */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #f8fafb;
}

.candidate-auth-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100dvh - 74px);
  padding: 40px 16px;
}

.auth-container {
  width: 100%;
  max-width: 440px;
}

/* ── Card ─────────────────────────────────────────────────── */
.candidate-auth-card {
  background: #ffffff;
  border-radius: 20px;
  padding: 36px 32px;
  border: 1px solid #e8ecf2;
  box-shadow: 0 8px 32px rgba(15, 23, 42, 0.08);
}

/* ── Header ───────────────────────────────────────────────── */
.candidate-auth-head {
  text-align: center;
  margin-bottom: 24px;
}

.auth-logo {
  margin-bottom: 14px;
}

.auth-logo img {
  width: 48px;
  height: 48px;
  object-fit: contain;
}

.candidate-auth-head h2 {
  font-family: "Manrope", sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 6px;
}

.candidate-auth-head p {
  color: #64748b;
  font-size: 0.9rem;
  margin: 0;
}

/* ── Tabs ─────────────────────────────────────────────────── */
.tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  border: 1px solid #e8ecf2;
  border-radius: 12px;
  background: #f1f5f9;
  margin-bottom: 18px;
}
.tab {
  border: 0;
  border-radius: 9px;
  background: transparent;
  min-height: 40px;
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  color: #64748b;
  cursor: pointer;
  transition: all 0.2s ease;
}
.tab.active {
  background: #ffffff;
  color: #ea580c;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
}
.panel {
  display: none;
}
.panel.active {
  display: block;
}

/* ── Error Banner ─────────────────────────────────────────── */
.error-banner {
  display: none;
  margin-bottom: 14px;
  border-radius: 10px;
  padding: 10px 12px;
  background: #fee2e2;
  border: 1px solid #fca5a5;
  color: #991b1b;
  font-size: 0.84rem;
}
.error-banner.show {
  display: block;
}

/* ── Google Button ────────────────────────────────────────── */
.btn-google {
  width: 100%;
  min-height: 46px;
  border-radius: 10px;
  border: 1.5px solid #e2e8f0;
  background: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: inherit;
  font-weight: 600;
  font-size: 0.9rem;
  color: #0f172a;
  cursor: pointer;
  transition: all 0.2s ease;
}
.btn-google:hover {
  border-color: #94a3b8;
  background: #f8fafc;
}
.btn-google img {
  width: 18px;
  height: 18px;
}

/* ── Divider ──────────────────────────────────────────────── */
.divider {
  position: relative;
  text-align: center;
  margin: 20px 0;
  color: #94a3b8;
  font-size: 0.78rem;
}
.divider::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 100%;
  height: 1px;
  background: #e8ecf2;
}
.divider span {
  position: relative;
  background: #ffffff;
  padding: 0 12px;
}

/* ── Form ─────────────────────────────────────────────────── */
.form-group {
  margin-bottom: 16px;
}
.form-label {
  display: block;
  margin-bottom: 6px;
  font-size: 0.82rem;
  color: #334155;
  font-weight: 600;
}
.form-input {
  width: 100%;
  min-height: 46px;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1.5px solid #e2e8f0;
  font-size: 0.92rem;
  color: #0f172a;
  background: #ffffff;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}
.form-input:focus {
  outline: none;
  border-color: #ea580c;
  box-shadow: 0 0 0 3px rgba(234, 88, 12, 0.1);
}

.pw-wrap {
  position: relative;
}
.pw-toggle {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: transparent;
  color: #64748b;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
  letter-spacing: 0.04em;
}

.auth-actions-row {
  display: flex;
  justify-content: flex-end;
  margin: -6px 0 16px;
}

/* ── Buttons ──────────────────────────────────────────────── */
.btn-ghost {
  border: 0;
  background: transparent;
  color: #ea580c;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
}

.btn {
  width: 100%;
  min-height: 46px;
  border-radius: 10px;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}
.btn-primary {
  color: #ffffff;
  background: #ea580c;
  margin-bottom: 10px;
}
.btn-primary:hover {
  background: #c2410c;
}
.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.btn-outline {
  border: 1.5px solid #e2e8f0;
  background: #ffffff;
  color: #334155;
}
.btn-outline:hover {
  border-color: #ea580c;
  color: #ea580c;
  background: #fff7ed;
}

/* ── Switch Link ──────────────────────────────────────────── */
.switch-copy {
  margin-top: 16px;
  text-align: center;
  color: #64748b;
  font-size: 0.85rem;
}
.switch-copy a {
  color: #ea580c;
  text-decoration: none;
  font-weight: 700;
}
.switch-copy a:hover {
  text-decoration: underline;
}

/* ── Form Row ─────────────────────────────────────────────── */
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

/* ── Terms ────────────────────────────────────────────────── */
.terms-row {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  font-size: 0.83rem;
  color: #475569;
  margin-bottom: 14px;
  cursor: pointer;
}
.terms-row a {
  color: #ea580c;
  text-decoration: none;
  font-weight: 600;
}
.terms-row a:hover {
  text-decoration: underline;
}

/* ── Helpers ──────────────────────────────────────────────── */
.form-hint {
  display: block;
  margin-top: 4px;
  font-size: 0.76rem;
  color: #94a3b8;
}
.required {
  color: #ef4444;
}

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

/* ── Toast ────────────────────────────────────────────────── */
.toast-root {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast {
  background: #0f172a;
  color: #ffffff;
  padding: 11px 14px;
  border-radius: 10px;
  border-left: 4px solid #3b82f6;
  box-shadow: 0 14px 30px rgba(2, 6, 23, 0.26);
  min-width: 220px;
  max-width: 360px;
  font-size: 0.84rem;
}
.toast.success {
  border-left-color: #10b981;
}
.toast.error {
  border-left-color: #ef4444;
}

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 480px) {
  .candidate-auth-page {
    padding: 24px 14px;
    align-items: flex-start;
  }
  .candidate-auth-card {
    padding: 28px 20px;
    border-radius: 16px;
  }
  .candidate-auth-head h2 {
    font-size: 1.3rem;
  }
}
