:root {
  --primary: #1d6fce;
  --primary-dark: #1557a0;
  --success: #198754;
  --warning: #fd7e14;
  --danger: #dc3545;
}

/* ── Wizard steps ──────────────────────────────────────────────────────────── */
.wizard-steps { position: relative; }

.wizard-line {
  position: absolute;
  top: 18px;
  left: 10%;
  right: 10%;
  height: 2px;
  background: #dee2e6;
  z-index: 0;
}

.step-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #dee2e6;
  color: #6c757d;
  font-weight: 700;
  font-size: .95rem;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
  position: relative;
  transition: background .3s, color .3s, box-shadow .3s;
}

.step-circle.active {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 0 0 4px rgba(29, 111, 206, .2);
}

.step-circle.done {
  background: var(--success);
  color: #fff;
}

.step-label { font-size: .75rem; transition: color .3s; }
#step-indicator-1.done .step-label,
#step-indicator-2.done .step-label,
#step-indicator-3.done .step-label { color: var(--success); }

/* ── Panels ────────────────────────────────────────────────────────────────── */
.wizard-panel {
  border: none;
  border-radius: .75rem;
  animation: fadeSlide .25s ease;
}

@keyframes fadeSlide {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Drop zones ────────────────────────────────────────────────────────────── */
.drop-zone {
  border: 2px dashed #ced4da;
  border-radius: .6rem;
  padding: 2rem 1rem;
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, background .2s;
}

.drop-zone:hover,
.drop-zone.dragover {
  border-color: var(--primary);
  background: rgba(29, 111, 206, .04);
}

.drop-zone.has-file {
  border-color: var(--success);
  background: rgba(25, 135, 84, .04);
}

/* ── Extraction table confidence ───────────────────────────────────────────── */
.conf-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 4px;
}
.conf-high .conf-dot { background: #198754; }
.conf-med  .conf-dot { background: #fd7e14; }
.conf-low  .conf-dot { background: #dc3545; }

/* ── Extraction table inline edit ─────────────────────────────────────────── */
.field-value-inline {
  display: flex;
  align-items: center;
  gap: .35rem;
  min-height: 32px;
}

.btn-field-edit {
  line-height: 1;
}

.field-edit-inline {
  display: flex;
  align-items: center;
  gap: .35rem;
}

/* ── Behavioral CAPTCHA widget ───────────────────────────────────────── */
.captcha-box {
  border: 1px solid #d3d3d3;
  border-radius: 4px;
  background: #f9f9f9;
  padding: .75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 320px;
  margin-left: auto;
  margin-right: auto;
  box-shadow: 0 1px 3px rgba(0,0,0,.08);
  user-select: none;
}

.captcha-inner {
  display: flex;
  align-items: center;
  gap: .85rem;
}

.captcha-checkbox {
  width: 28px;
  height: 28px;
  border: 2px solid #b0b0b0;
  border-radius: 3px;
  background: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color .2s, background .2s;
  flex-shrink: 0;
  outline: none;
}
.captcha-checkbox:hover,
.captcha-checkbox:focus-visible {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(29,111,206,.15);
}
.captcha-checkbox.checking { border-color: var(--primary); }
.captcha-checkbox.passed {
  border-color: var(--success);
  background: var(--success);
  border-radius: 50%;
}
.captcha-checkbox.failed {
  border-color: var(--danger);
  background: #fff2f2;
  cursor: not-allowed;
}

.captcha-label {
  font-size: .92rem;
  color: #333;
  cursor: pointer;
}

.captcha-branding {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  color: #5f6368;
  text-align: center;
}
.captcha-branding small {
  font-size: .62rem;
  line-height: 1.2;
}

.captcha-logo {
  width: 34px;
  height: 34px;
  display: block;
  margin-bottom: 2px;
  object-fit: contain;
}

.captcha-spinner {
  width: 18px;
  height: 18px;
  border: 2px solid #ddd;
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: captcha-spin .7s linear infinite;
}
@keyframes captcha-spin { to { transform: rotate(360deg); } }

.captcha-check-icon { color: #fff; font-size: 1.1rem; font-weight: 700; }

.field-edit-inline .form-control {
  max-width: 240px;
}

.field-edit-date {
  align-items: flex-start;
}

.date-suggestions-list {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
}

.btn-field-action {
  width: 30px;
  height: 30px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ── Buttons ────────────────────────────────────────────────────────────────── */
.btn-primary {
  background: var(--primary);
  border-color: var(--primary);
}
.btn-primary:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
}
