/* ── Auth screens ────────────────────────────────────────────────────────────── */

/* Card registrazione/setup scrollabile */
.auth-scroll {
  align-items: flex-start !important;
  padding-top: 32px !important;
  overflow-y: auto !important;
}
.auth-scroll .auth-card {
  margin: 0 auto;
  max-width: 560px;
}

/* Header sezione dentro auth card */
.auth-section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--gray-200);
}
.auth-section-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--gray-900);
}

/* Step wizard recupero PIN */
.recovery-steps {
  display: flex;
  gap: 0;
  margin-bottom: 24px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--gray-200);
}
.recovery-step {
  flex: 1;
  padding: 9px 6px;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  background: var(--gray-50);
  color: var(--gray-400);
  border-right: 1px solid var(--gray-200);
  transition: var(--transition);
}
.recovery-step:last-child { border-right: none; }
.recovery-step.active     { background: var(--blue-800); color: white; }
.recovery-step.done       { background: var(--green-100); color: var(--green-700); }

/* Card medico nel select */
.doctor-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: var(--transition);
}
.doctor-option:hover     { background: var(--blue-50); }
.doctor-option.selected  { background: var(--blue-100); }
.doctor-option-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: var(--blue-800);
  color: white;
  font-size: 12px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.doctor-option-name  { font-size: 13px; font-weight: 600; color: var(--gray-800); }
.doctor-option-clinic{ font-size: 11px; color: var(--gray-500); }

/* PIN strength indicator */
.pin-strength {
  height: 4px;
  border-radius: 99px;
  margin-top: 6px;
  background: var(--gray-200);
  overflow: hidden;
  transition: var(--transition);
}
.pin-strength-bar {
  height: 100%;
  border-radius: 99px;
  transition: width .3s ease, background .3s ease;
}
.pin-strength-weak   .pin-strength-bar { width: 33%;  background: var(--red-700); }
.pin-strength-medium .pin-strength-bar { width: 66%;  background: var(--amber-700); }
.pin-strength-strong .pin-strength-bar { width: 100%; background: var(--green-700); }

/* Welcome banner dopo login */
.welcome-banner {
  background: linear-gradient(135deg, var(--blue-900), var(--blue-700));
  color: white;
  padding: 16px 20px;
  border-radius: var(--radius-lg);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}
.welcome-name  { font-size: 16px; font-weight: 700; }
.welcome-sub   { font-size: 12px; opacity: .75; margin-top: 2px; }
.welcome-date  { font-size: 13px; opacity: .8; text-align: right; }

/* ── Setup server wizard ──────────────────────────────────────────────────────── */
.setup-progress {
  display: flex;
  align-items: center;
  margin-bottom: 22px;
  gap: 0;
}
.setup-step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  position: relative;
}
.setup-step::after {
  content: '';
  position: absolute;
  top: 14px;
  left: 50%;
  right: -50%;
  height: 2px;
  background: var(--gray-200);
  z-index: 0;
}
.setup-step:last-child::after { display: none; }
.setup-step-dot {
  width: 28px; height: 28px;
  border-radius: 50%;
  border: 2px solid var(--gray-200);
  background: white;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700;
  color: var(--gray-400);
  position: relative;
  z-index: 1;
  transition: var(--transition);
}
.setup-step.active .setup-step-dot  { border-color: var(--blue-800); color: var(--blue-800); }
.setup-step.done .setup-step-dot    { border-color: var(--green-700); background: var(--green-700); color: white; }
.setup-step-label { font-size: 11px; font-weight: 600; color: var(--gray-400); text-align: center; }
.setup-step.active .setup-step-label { color: var(--blue-800); }
.setup-step.done .setup-step-label   { color: var(--green-700); }

/* ── Session timeout warning ─────────────────────────────────────────────────── */
.session-warning {
  position: fixed;
  bottom: 20px; right: 20px;
  background: var(--amber-700);
  color: white;
  padding: 14px 18px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  font-size: 13px;
  z-index: 999;
  animation: fadeUp .3s ease;
  max-width: 280px;
}
.session-warning-title { font-weight: 700; margin-bottom: 6px; }
.session-warning-btns  { display: flex; gap: 8px; margin-top: 10px; }

@media(max-width: 600px) {
  .auth-card    { padding: 22px 16px; }
  .welcome-date { display: none; }
}
