/* ============================================================
   Sponsor Registration Portal — Supplementary Styles
   Extends /assets/css/main.css (symlinked)
   ============================================================ */

/* ── Step wizard ─────────────────────────────────────────── */
.step-wizard {
  display: flex;
  align-items: center;
  gap: 0;
  margin-bottom: 28px;
  counter-reset: step;
}

.step-wizard__item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--neutral-400);
  counter-increment: step;
  white-space: nowrap;
}

.step-wizard__item::before {
  content: counter(step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 50%;
  background: var(--neutral-200);
  color: var(--neutral-500);
  font-size: 0.78rem;
  font-weight: 700;
  transition: background 0.2s, color 0.2s;
}

.step-wizard__item.is-active {
  color: var(--primary-700);
}

.step-wizard__item.is-active::before {
  background: var(--accent-500);
  color: var(--primary-900);
}

.step-wizard__item.is-complete {
  color: var(--primary-700);
}

.step-wizard__item.is-complete::before {
  background: var(--primary-500);
  color: #fff;
  content: "\2713";
}

.step-wizard__connector {
  flex: 1;
  height: 2px;
  background: var(--neutral-200);
  margin: 0 8px;
  min-width: 16px;
}

.step-wizard__connector.is-complete {
  background: var(--primary-500);
}

@media (max-width: 600px) {
  .step-wizard {
    flex-wrap: wrap;
    gap: 8px;
  }
  .step-wizard__connector {
    display: none;
  }
  .step-wizard__item {
    font-size: 0.72rem;
  }
  .step-wizard__item::before {
    width: 24px;
    height: 24px;
    min-width: 24px;
    font-size: 0.7rem;
  }
}

/* ── Type selector ───────────────────────────────────────── */
.type-selector {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}

.type-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 28px 20px;
  border-radius: var(--radius-md);
  border: 2px solid var(--neutral-200);
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s, transform 0.1s;
  text-align: center;
}

.type-card:hover {
  border-color: var(--primary-500);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.type-card.is-selected {
  border-color: var(--primary-500);
  box-shadow: 0 0 0 3px rgba(15,97,150,0.12);
  background: rgba(15,97,150,0.02);
}

.type-card input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.type-card__icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-sm);
  background: rgba(15,97,150,0.08);
  border: 1px solid rgba(15,97,150,0.12);
  display: grid;
  place-items: center;
}

.type-card__icon svg {
  width: 26px;
  height: 26px;
  stroke: var(--primary-700);
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.type-card h3 {
  margin: 0;
  font-size: 1.05rem;
  color: var(--primary-700);
  pointer-events: none;
}

.type-card p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--neutral-600);
  pointer-events: none;
}

@media (max-width: 520px) {
  .type-selector {
    grid-template-columns: 1fr;
  }
}

/* ── Form step panels ────────────────────────────────────── */
.form-step {
  display: none;
}

.form-step.is-active {
  display: block;
  animation: fadeIn 0.25s ease;
}

.form-step-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 24px;
}

.form-step-actions .btn:first-child:last-child {
  margin-left: auto;
}

/* ── Verification code input ─────────────────────────────── */
.verify-card {
  max-width: 440px;
  margin: 0 auto;
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--neutral-200);
  text-align: center;
}

.verify-card h2 {
  margin: 0 0 8px;
  color: var(--primary-900);
  font-size: 1.5rem;
}

.verify-card p {
  margin: 0 0 24px;
  color: var(--neutral-600);
  font-size: 0.92rem;
}

.verify-inputs {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-bottom: 24px;
}

.verify-inputs input {
  width: 48px;
  height: 56px;
  border: 2px solid var(--neutral-300);
  border-radius: var(--radius-sm);
  text-align: center;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary-900);
  transition: border-color 0.15s, box-shadow 0.15s;
}

.verify-inputs input:focus {
  outline: none;
  border-color: var(--primary-500);
  box-shadow: 0 0 0 3px rgba(15,97,150,0.12);
}

.verify-resend {
  margin-top: 16px;
  font-size: 0.88rem;
  color: var(--neutral-500);
}

.verify-resend a {
  color: var(--primary-500);
  font-weight: 600;
  cursor: pointer;
}

.verify-resend a:hover {
  text-decoration: underline;
}

/* ── Login card ──────────────────────────────────────────── */
.login-card {
  max-width: 420px;
  margin: 0 auto;
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 36px 32px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--neutral-200);
}

.login-card h2 {
  margin: 0 0 6px;
  color: var(--primary-900);
  font-size: 1.5rem;
}

.login-card > p {
  margin: 0 0 24px;
  color: var(--neutral-600);
  font-size: 0.92rem;
}

.login-card .form-group {
  margin-bottom: 16px;
}

.login-card .form-group:last-of-type {
  margin-bottom: 24px;
}

.login-footer {
  margin-top: 16px;
  text-align: center;
  font-size: 0.88rem;
  color: var(--neutral-500);
}

.login-footer a {
  color: var(--primary-500);
  font-weight: 600;
}

/* ── Dashboard ───────────────────────────────────────────── */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 24px;
  margin-top: 8px;
}

@media (max-width: 768px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

/* ── Sponsor ID card ─────────────────────────────────────── */
.sponsor-id-card {
  background: linear-gradient(135deg, var(--primary-900) 0%, var(--primary-700) 100%);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 32px 28px;
  position: relative;
  overflow: hidden;
}

.sponsor-id-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--flag-red), var(--accent-500), var(--flag-blue));
}

.sponsor-id-card::before {
  content: '';
  position: absolute;
  top: -40px;
  right: -40px;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: rgba(255,255,255,0.04);
}

.sponsor-id-card__badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.2);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.9);
  margin-bottom: 16px;
}

.sponsor-id-card__number {
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
  color: var(--accent-500);
}

.sponsor-id-card__name {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 16px;
  color: rgba(255,255,255,0.9);
}

.sponsor-id-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.7);
}

.sponsor-id-card__meta dt {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.5);
  margin-bottom: 2px;
}

.sponsor-id-card__meta dd {
  margin: 0;
  font-weight: 600;
  color: rgba(255,255,255,0.9);
}

.sponsor-id-card__instruction {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(255,255,255,0.12);
  font-size: 0.82rem;
  color: rgba(255,255,255,0.65);
  line-height: 1.5;
}

/* ── Profile panel ───────────────────────────────────────── */
.profile-panel {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--neutral-200);
}

.profile-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.profile-panel__header h2 {
  margin: 0;
  font-size: 1.2rem;
  color: var(--primary-900);
}

.profile-section {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--neutral-200);
}

.profile-section:first-of-type {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.profile-section h3 {
  margin: 0 0 12px;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--primary-700);
}

.profile-field {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-bottom: 12px;
}

.profile-field__label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--neutral-500);
}

.profile-field__value {
  font-size: 0.95rem;
  color: var(--neutral-700);
  font-weight: 500;
}

.profile-field__value.empty {
  color: var(--neutral-400);
  font-style: italic;
}

/* ── Alerts / banners ────────────────────────────────────── */
.alert {
  padding: 14px 18px;
  border-radius: var(--radius-md);
  font-size: 0.88rem;
  margin-bottom: 20px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.alert--warning {
  background: rgba(217,119,6,0.08);
  border: 1px solid rgba(217,119,6,0.2);
  color: var(--warning);
}

.alert--success {
  background: rgba(15,123,79,0.08);
  border: 1px solid rgba(15,123,79,0.2);
  color: var(--success);
}

.alert--error {
  background: rgba(197,48,48,0.06);
  border: 1px solid rgba(197,48,48,0.15);
  color: var(--danger);
}

.alert--info {
  background: rgba(15,97,150,0.06);
  border: 1px solid rgba(15,97,150,0.15);
  color: var(--primary-700);
}

/* ── Review step ─────────────────────────────────────────── */
.review-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
}

.review-item {
  padding: 12px;
  border-radius: var(--radius-sm);
  background: var(--neutral-50);
  border: 1px solid var(--neutral-200);
}

.review-item dt {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--neutral-500);
  margin-bottom: 2px;
}

.review-item dd {
  margin: 0;
  font-weight: 600;
  color: var(--neutral-700);
  font-size: 0.92rem;
}

/* ── Loading / spinner ───────────────────────────────────── */
.spinner {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid var(--neutral-200);
  border-top-color: var(--primary-500);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.btn--loading {
  position: relative;
  pointer-events: none;
  color: transparent !important;
}

.btn--loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 18px;
  margin: -9px 0 0 -9px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

/* ── Password strength ───────────────────────────────────── */
.password-strength {
  height: 4px;
  border-radius: 2px;
  background: var(--neutral-200);
  margin-top: 6px;
  overflow: hidden;
}

.password-strength__bar {
  height: 100%;
  border-radius: 2px;
  transition: width 0.3s, background 0.3s;
  width: 0;
}

.password-strength__bar[data-strength="weak"] {
  width: 33%;
  background: var(--danger);
}

.password-strength__bar[data-strength="fair"] {
  width: 66%;
  background: var(--warning);
}

.password-strength__bar[data-strength="strong"] {
  width: 100%;
  background: var(--success);
}
