/* ============================================================
   VOH Registration Form — Main Stylesheet
   ============================================================ */

:root {
  --voh-primary:    #2563eb;
  --voh-primary-dk: #1d4ed8;
  --voh-success:    #16a34a;
  --voh-danger:     #dc2626;
  --voh-warn:       #d97706;
  --voh-bg:         #f8fafc;
  --voh-card-bg:    #ffffff;
  --voh-border:     #e2e8f0;
  --voh-text:       #1e293b;
  --voh-muted:      #64748b;
  --voh-radius:     12px;
  --voh-shadow:     0 1px 3px rgba(0,0,0,.08), 0 4px 16px rgba(0,0,0,.06);
  --voh-transition: .22s ease;
}

/* Wrap */
.voh-reg-wrap {
  max-width: 100%;
  width: 100%;
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color: var(--voh-text);
  background: var(--voh-bg);
  box-sizing: border-box;
}

/* Suppress <br> tags injected by wpautop / Elementor */
.voh-reg-wrap br,
.voh-reg-wrap form br {
  display: none;
}

/* ---- Step Nav ---- */
.voh-steps {
  display: flex;
  gap: .25rem;
  background: var(--voh-card-bg);
  border: 1px solid var(--voh-border);
  border-radius: var(--voh-radius);
  padding: .5rem;
  margin-bottom: .75rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.voh-steps::-webkit-scrollbar { display: none; }

.voh-step-btn {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex: 1;
  min-width: 80px;
  padding: .6rem .75rem;
  border: none;
  background: transparent;
  border-radius: 8px;
  cursor: pointer;
  font-size: .8rem;
  font-weight: 500;
  color: var(--voh-muted);
  transition: background var(--voh-transition), color var(--voh-transition);
  white-space: nowrap;
  text-align: left;
}
.voh-step-btn:hover { background: #f1f5f9; color: var(--voh-text); }
.voh-step-btn.active {
  background: var(--voh-primary);
  color: #fff;
}
.voh-step-btn.completed {
  color: var(--voh-success);
}
.voh-step-btn.completed .voh-step-num {
  background: var(--voh-success);
  color: #fff;
}

.voh-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #e2e8f0;
  font-size: .75rem;
  font-weight: 700;
  flex-shrink: 0;
  transition: background var(--voh-transition), color var(--voh-transition);
}
.voh-step-btn.active .voh-step-num {
  background: rgba(255,255,255,.25);
  color: #fff;
}

.voh-step-label { font-size: .8rem; }

/* ---- Progress Bar ---- */
.voh-progress-bar {
  height: 4px;
  background: var(--voh-border);
  border-radius: 2px;
  margin-bottom: 1.5rem;
  overflow: hidden;
}
.voh-progress-fill {
  height: 100%;
  background: var(--voh-primary);
  border-radius: 2px;
  transition: width .4s ease;
}

/* ---- Panel ---- */
.voh-panel {
  display: none;
  animation: vohFadeIn .25s ease;
}
.voh-panel.active { display: block; }

@keyframes vohFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.voh-panel-header { margin-bottom: 1.25rem; }
.voh-panel-header h2 {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 .25rem;
}
.voh-panel-header p {
  color: var(--voh-muted);
  margin: 0;
  font-size: .9rem;
}

/* ---- Card ---- */
.voh-card {
  background: var(--voh-card-bg);
  border: 1px solid var(--voh-border);
  border-radius: var(--voh-radius);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--voh-shadow);
}
.voh-card-title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 1rem;
  padding-bottom: .6rem;
  border-bottom: 1px solid var(--voh-border);
}
.voh-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: .75rem;
}
.voh-card-head .voh-card-title { margin: 0; border: none; padding: 0; }

/* ---- Grid ---- */
.voh-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.voh-col-2 { grid-column: span 2; }

/* ---- Field ---- */
.voh-field { display: flex; flex-direction: column; gap: .3rem; }
.voh-field label {
  font-size: .82rem;
  font-weight: 600;
  color: var(--voh-text);
}
.voh-field input,
.voh-field select,
.voh-field textarea {
  padding: .55rem .75rem;
  border: 1.5px solid var(--voh-border);
  border-radius: 8px;
  font-size: .9rem;
  color: var(--voh-text);
  background: #fff;
  transition: border-color var(--voh-transition), box-shadow var(--voh-transition);
  width: 100%;
  box-sizing: border-box;
}
.voh-field input:focus,
.voh-field select:focus,
.voh-field textarea:focus {
  outline: none;
  border-color: var(--voh-primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,.12);
}
.voh-field input.voh-invalid,
.voh-field select.voh-invalid,
.voh-field textarea.voh-invalid {
  border-color: var(--voh-danger);
  box-shadow: 0 0 0 3px rgba(220,38,38,.1);
}
.voh-field textarea { resize: vertical; min-height: 70px; }

.req { color: var(--voh-danger); }
.voh-error {
  font-size: .78rem;
  color: var(--voh-danger);
  min-height: 1em;
  display: block;
}
.voh-hint {
  font-size: .82rem;
  color: var(--voh-muted);
  margin: 0 0 .75rem;
}

/* ---- Checkboxes ---- */
.voh-checkbox-group { display: flex; flex-direction: column; gap: .6rem; }
.voh-check-label {
  display: flex;
  align-items: flex-start;
  gap: .6rem;
  font-size: .88rem;
  cursor: pointer;
  line-height: 1.4;
}
.voh-check-label input[type="checkbox"] {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-top: .15rem;
  accent-color: var(--voh-primary);
  cursor: pointer;
}

/* Conditions grid */
.voh-conditions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: .5rem .75rem;
  margin-top: .4rem;
}

/* ---- Repeater buttons ---- */
.voh-btn-add {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .55rem 1.1rem;
  border: 2px dashed var(--voh-primary);
  border-radius: 8px;
  background: transparent;
  color: var(--voh-primary);
  font-size: .88rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--voh-transition);
  margin-top: .25rem;
}
.voh-btn-add:hover { background: rgba(37,99,235,.06); }

.voh-btn-remove {
  padding: .3rem .7rem;
  border: 1px solid var(--voh-danger);
  border-radius: 6px;
  background: transparent;
  color: var(--voh-danger);
  font-size: .78rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--voh-transition);
  white-space: nowrap;
}
.voh-btn-remove:hover { background: rgba(220,38,38,.07); }

/* ---- Collapsible secondary parent ---- */
.voh-secondary-parent { margin-top: 1rem; }

/* ---- Review card ---- */
.voh-review-card { background: #f0f9ff; border-color: #bae6fd; }
.voh-review-grid {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}
.voh-review-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .2rem;
}
.voh-review-label { font-size: .78rem; color: var(--voh-muted); }
.voh-review-val {
  font-size: 2rem;
  font-weight: 700;
  color: var(--voh-primary);
  line-height: 1;
}

/* ---- Navigation ---- */
.voh-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--voh-border);
}
.voh-nav-right { display: flex; gap: .75rem; }

.voh-btn {
  padding: .65rem 1.5rem;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .3rem;
  line-height: 1;
  white-space: nowrap;
  transition: background var(--voh-transition), transform .1s;
}
.voh-btn:active { transform: scale(.98); }
.voh-btn-primary  { background: var(--voh-primary); color: #fff; }
.voh-btn-primary:hover  { background: var(--voh-primary-dk); }
.voh-btn-secondary { background: #f1f5f9; color: var(--voh-text); border: 1px solid var(--voh-border); }
.voh-btn-secondary:hover { background: #e2e8f0; }
.voh-btn-success  { background: var(--voh-success); color: #fff; }
.voh-btn-success:hover  { background: #15803d; }
.voh-btn:disabled { opacity: .55; cursor: not-allowed; }

/* ---- Submit message ---- */
.voh-submit-msg {
  padding: 1rem 1.25rem;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 500;
  margin-top: 1rem;
  display: none;
}
.voh-submit-msg.success { background: #dcfce7; color: #166534; border: 1px solid #bbf7d0; display: block; }
.voh-submit-msg.error   { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; display: block; }

/* ---- Responsive ---- */
@media (max-width: 640px) {
  /* Grid — single column */
  .voh-grid { grid-template-columns: 1fr; }
  .voh-col-2 { grid-column: span 1; }

  /* Address sub-grid — 1 col on mobile */
  .voh-address-sub { grid-template-columns: 1fr !important; }

  /* Step nav — numbers only, hide labels */
  .voh-step-label { display: none; }
  .voh-step-sub   { display: none; }
  .voh-step-btn   { min-width: 36px; padding: .5rem .4rem; justify-content: center; flex: 0 0 auto; }
  .voh-step-num   { width: 28px; height: 28px; font-size: .8rem; }

  /* Navigation bar — stack vertically */
  .voh-nav {
    flex-direction: column;
    align-items: stretch;
    gap: .75rem;
  }
  .voh-nav-right {
    flex-direction: column;
    gap: .5rem;
    width: 100%;
  }
  .voh-draft-wrap { width: 100%; }
  .voh-draft-hint { display: none; }

  /* Buttons — full width on mobile */
  .voh-btn,
  .voh-btn-draft {
    width: 100%;
    text-align: center;
    justify-content: center;
    height: 46px;
    font-size: .9rem;
  }
  #voh-prev { width: 100%; }

  /* Add/Remove buttons */
  .voh-btn-add { width: 100%; justify-content: center; }

  /* Radio/checkbox pills — full width on mobile */
  .voh-radio-group,
  .voh-check-pill-group { gap: .4rem; }
  .voh-radio-label,
  .voh-check-pill { flex: 1; min-width: calc(50% - .4rem); justify-content: center; }

  /* Review counters */
  .voh-review-counters { gap: .5rem; }
  .voh-review-counter-item .voh-review-val { font-size: 1.75rem; }
  .voh-summary-grid { grid-template-columns: 1fr; }

  /* Conditions grid */
  .voh-conditions-grid { grid-template-columns: 1fr 1fr; }

  /* Card padding tighter */
  .voh-card { padding: 1rem; }

  /* Panel header — stack badge below title */
  .voh-panel-header-top { flex-wrap: wrap; gap: .4rem; }
}

@media (max-width: 400px) {
  /* Very small screens — pills go full width */
  .voh-radio-label,
  .voh-check-pill { min-width: 100%; }
}

@media (min-width: 641px) and (max-width: 900px) {
  .voh-conditions-grid { grid-template-columns: repeat(3, 1fr); }

  /* Tab text — truncate sub-label on tablet */
  .voh-step-sub {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 90px;
  }
  .voh-step-btn { padding: .6rem .5rem; }
  .voh-step-label { font-size: .78rem; }

  .voh-btn { padding: 0 1.1rem; font-size: .85rem; }
  .voh-btn-draft { padding: 0 1rem; font-size: .85rem; }
}

/* ---- Step nav sub-labels ---- */
.voh-step-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.2;
  min-width: 0;
}
.voh-step-label {
  font-size: .82rem;
  font-weight: 600;
  white-space: nowrap;
}
.voh-step-sub {
  font-size: .7rem;
  font-weight: 400;
  color: var(--voh-muted);
  white-space: normal;
  line-height: 1.3;
}
.voh-step-btn.active .voh-step-sub { color: rgba(255,255,255,.75); }
.voh-step-btn.completed .voh-step-sub { color: var(--voh-muted); }

/* ---- Steps header ---- */
.voh-steps-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: .4rem;
}
.voh-steps-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--voh-text);
  letter-spacing: -.01em;
}

/* ---- Panel header top row ---- */
.voh-panel-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: .25rem;
}
.voh-panel-header-top h2 { margin: 0; }

/* ---- Step badge ---- */
.voh-step-badge {
  font-size: .75rem;
  font-weight: 600;
  color: var(--voh-muted);
  background: #f1f5f9;
  border: 1px solid var(--voh-border);
  border-radius: 20px;
  padding: .2rem .65rem;
  white-space: nowrap;
}

/* ---- Info banner ---- */
.voh-info-banner {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-left: 4px solid var(--voh-primary);
  border-radius: 8px;
  padding: .75rem 1rem;
  font-size: .82rem;
  color: #1e40af;
  margin-bottom: 1.25rem;
  line-height: 1.5;
}

/* ---- Review counters row ---- */
.voh-review-submit-section {
  margin-top: 1.5rem;
}
.voh-review-submit-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--voh-text);
  margin: 0 0 1rem;
  padding-bottom: .6rem;
  border-bottom: 2px solid var(--voh-border);
}
.voh-review-counters {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.voh-review-counter-item {
  flex: 1;
  background: var(--voh-card-bg);
  border: 1px solid var(--voh-border);
  border-radius: var(--voh-radius);
  padding: 1rem 1rem .85rem;
  text-align: center;
  box-shadow: var(--voh-shadow);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .35rem;
}
.voh-review-counter-label {
  font-size: .75rem;
  font-weight: 500;
  color: var(--voh-muted);
  line-height: 1.3;
  text-align: center;
}
.voh-review-counter-item .voh-review-val {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--voh-primary);
  line-height: 1;
  display: block;
}

/* ---- Summary card ---- */
.voh-summary-card {
  background: #f8fafc;
  border-color: var(--voh-border);
}
.voh-summary-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-bottom: 1.25rem;
}
.voh-summary-col { display: flex; flex-direction: column; gap: .35rem; }
.voh-summary-col p { margin: 0; font-size: .88rem; }
.voh-summary-heading {
  font-size: .9rem;
  font-weight: 700;
  color: var(--voh-text);
  margin: 0 0 .5rem;
  padding-bottom: .4rem;
  border-bottom: 1px solid var(--voh-border);
}
.voh-summary-section {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--voh-border);
}
.voh-summary-section p { margin: .25rem 0; font-size: .88rem; }

/* ---- Save Draft button ---- */
.voh-btn-draft {
  background: #fff;
  color: var(--voh-text);
  border: 1.5px solid var(--voh-border);
  padding: 0 1.25rem;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  line-height: 1;
  transition: background var(--voh-transition), border-color var(--voh-transition);
}
.voh-btn-draft:hover {
  background: #f1f5f9;
  border-color: #94a3b8;
}
.voh-btn-draft:disabled {
  opacity: .6;
  cursor: not-allowed;
}

/* ---- Responsive overrides for new elements — merged into main block above ---- */

/* ---- Radio group ---- */
.voh-radio-group {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem .75rem;
  margin-top: .25rem;
}
.voh-radio-label {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: .88rem;
  cursor: pointer;
  padding: .45rem .9rem;
  border: 1.5px solid var(--voh-border);
  border-radius: 8px;
  background: #fff;
  transition: border-color var(--voh-transition), background var(--voh-transition);
  user-select: none;
  font-weight: 500;
}
.voh-radio-label:hover { border-color: var(--voh-primary); background: #eff6ff; }
.voh-radio-label input[type="radio"] {
  accent-color: var(--voh-primary);
  width: 15px; height: 15px;
  flex-shrink: 0;
  cursor: pointer;
}
.voh-radio-label:has(input:checked) {
  border-color: var(--voh-primary);
  background: #eff6ff;
  color: var(--voh-primary);
  font-weight: 600;
}

/* ---- Checkbox pill group (Preferred Communication) ---- */
.voh-check-pill-group {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem .75rem;
  margin-top: .25rem;
}
.voh-check-pill {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: .88rem;
  cursor: pointer;
  padding: .45rem .9rem;
  border: 1.5px solid var(--voh-border);
  border-radius: 8px;
  background: #fff;
  transition: border-color var(--voh-transition), background var(--voh-transition);
  user-select: none;
  font-weight: 500;
}
.voh-check-pill:hover { border-color: var(--voh-primary); background: #eff6ff; }
.voh-check-pill input[type="checkbox"] {
  accent-color: var(--voh-primary);
  width: 15px; height: 15px;
  flex-shrink: 0;
  cursor: pointer;
}
.voh-check-pill:has(input:checked) {
  border-color: var(--voh-primary);
  background: #eff6ff;
  color: var(--voh-primary);
  font-weight: 600;
}

/* ---- (Required) label text ---- */
.voh-req-text {
  font-size: .72rem;
  font-weight: 400;
  color: var(--voh-muted);
  font-style: italic;
}

/* ---- Field hint (below input) ---- */
.voh-field-hint {
  font-size: .72rem;
  font-weight: 500;
  color: #94a3b8;
  margin-top: -.05rem;
  font-style: italic;
}

/* ---- Optional label ---- */
.voh-optional {
  font-size: .72rem;
  font-weight: 400;
  color: var(--voh-muted);
}

/* ---- Address box — grouped with border ---- */
.voh-address-box {
  border: 1.5px solid var(--voh-border);
  border-radius: 10px;
  padding: 1rem;
  background: #f8fafc;
  display: flex;
  flex-direction: column;
  gap: .75rem;
  margin-top: .25rem;
}
.voh-address-sub { grid-template-columns: 1fr 1fr 1fr; }

/* ---- Application For card (above tabs) ---- */
.voh-app-for-card {
  margin-bottom: 1rem;
}

/* ---- Secondary toggle ---- */
.voh-toggle-secondary {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  font-size: .9rem;
  font-weight: 600;
  color: var(--voh-primary);
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  gap: .5rem;
}
.voh-toggle-icon-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform var(--voh-transition);
}
.voh-toggle-secondary.open .voh-toggle-icon-wrap { transform: rotate(180deg); }
.voh-chevron { display: block; }

/* ---- Draft wrap ---- */
.voh-draft-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .15rem;
}
.voh-draft-hint {
  font-size: .7rem;
  font-weight: 500;
  color: var(--voh-muted);
  font-style: italic;
}

/* ---- Draft toast notification ---- */
#voh-draft-toast {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: #1e293b;
  color: #fff;
  padding: .65rem 1.25rem;
  border-radius: 8px;
  font-size: .85rem;
  font-weight: 500;
  box-shadow: 0 4px 20px rgba(0,0,0,.2);
  opacity: 0;
  transition: opacity .3s ease, transform .3s ease;
  z-index: 99999;
  white-space: nowrap;
  pointer-events: none;
}
#voh-draft-toast.voh-toast-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* ---- Dark spinner (for Save Draft button) ---- */
.voh-spinner-dark {
  border-color: rgba(0,0,0,.15);
  border-top-color: var(--voh-text);
}

/* ---- Date input ---- */
.voh-date-input { font-variant-numeric: tabular-nums; letter-spacing: .03em; cursor: pointer; }
.voh-date-input::placeholder { color: #94a3b8; letter-spacing: normal; }

/* ---- Flatpickr theme overrides ---- */
.flatpickr-calendar {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
  border-radius: 10px !important;
  box-shadow: 0 8px 30px rgba(0,0,0,.12) !important;
  border: 1px solid #e2e8f0 !important;
  z-index: 100000 !important;
}
.flatpickr-day.selected,
.flatpickr-day.selected:hover {
  background: #2563eb !important;
  border-color: #2563eb !important;
}
.flatpickr-day:hover {
  background: #eff6ff !important;
}
.flatpickr-months .flatpickr-month,
.flatpickr-weekdays,
span.flatpickr-weekday {
  background: #2563eb !important;
  color: #fff !important;
  fill: #fff !important;
}
.flatpickr-current-month .flatpickr-monthDropdown-months,
.flatpickr-current-month input.cur-year {
  color: #fff !important;
}

/* Fix for WordPress Themes overwriting standard select styling in Flatpickr */
.flatpickr-current-month .flatpickr-monthDropdown-months {
  appearance: none !important;
  -webkit-appearance: none !important;
  -moz-appearance: none !important;
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 0.5ch 0 0 !important;
  margin: 0 !important;
  width: auto !important;
  outline: none !important;
  font-weight: inherit !important;
  font-size: inherit !important;
  font-family: inherit !important;
  line-height: inherit !important;
}

.flatpickr-current-month .flatpickr-monthDropdown-months:hover {
  background: rgba(255, 255, 255, 0.1) !important;
}

.flatpickr-current-month .flatpickr-monthDropdown-months option {
  background: #fff !important;
  color: #000 !important;
}
.flatpickr-prev-month svg,
.flatpickr-next-month svg { fill: #fff !important; }
.flatpickr-day.today { border-color: #2563eb !important; }
.flatpickr-day.today:hover { background: #eff6ff !important; color: #2563eb !important; }

/* ---- Submit spinner ---- */
.voh-spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255,255,255,.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: voh-spin .7s linear infinite;
  vertical-align: middle;
  margin-right: 4px;
}
@keyframes voh-spin {
  to { transform: rotate(360deg); }
}

/* ---- Thank you screen ---- */
.voh-thankyou {
  text-align: center;
  padding: 3rem 1.5rem;
  background: var(--voh-card-bg);
  border: 1px solid var(--voh-border);
  border-radius: var(--voh-radius);
  box-shadow: var(--voh-shadow);
  margin-top: 1rem;
}
.voh-thankyou-icon {
  width: 64px;
  height: 64px;
  background: var(--voh-success);
  color: #fff;
  font-size: 2rem;
  line-height: 64px;
  border-radius: 50%;
  margin: 0 auto 1.25rem;
}
.voh-thankyou h2 {
  font-size: 1.6rem;
  font-weight: 700;
  margin: 0 0 .75rem;
  color: var(--voh-text);
}
.voh-thankyou p {
  font-size: 1rem;
  color: var(--voh-muted);
  margin: 0 0 1.5rem;
}
.voh-thankyou-appid {
  display: inline-block;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 6px;
  padding: .5rem 1.25rem;
  font-size: .95rem;
  font-weight: 600;
  color: #166534;
  margin: 0 0 1.25rem;
}
.voh-pdf-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .6rem;
  margin-top: .5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--voh-border);
}
.voh-pdf-desc {
  font-size: .82rem;
  color: var(--voh-muted);
  margin: 0;
}
.voh-btn-pdf {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .65rem 1.5rem;
  background: var(--voh-primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--voh-transition), transform .1s;
}
.voh-btn-pdf:hover  { background: var(--voh-primary-dk); }
.voh-btn-pdf:active { transform: scale(.98); }

@media (max-width: 640px) {
  .voh-btn-pdf { width: 100%; justify-content: center; }
}

/* ---- Consent radio rows ---- */
#voh-consent-radios .voh-consent-row {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  padding: .6rem 0;
  border-bottom: 1px solid var(--voh-border);
}
#voh-consent-radios .voh-consent-row:last-of-type { border-bottom: none; }
.voh-consent-text {
  flex: 1;
  font-size: .88rem;
  line-height: 1.5;
  color: var(--voh-text);
}
.voh-consent-radios-wrap {
  display: flex;
  gap: .5rem;
  flex-shrink: 0;
}
.voh-consent-radios-wrap .voh-radio-label {
  min-width: 60px;
  justify-content: center;
}
.voh-consent-error {
  display: block;
  font-size: .78rem;
  color: var(--voh-danger);
  min-width: 120px;
  padding-top: .15rem;
}

@media (max-width: 540px) {
  #voh-consent-radios .voh-consent-row {
    flex-wrap: wrap;
  }
  .voh-consent-text {
    flex-basis: 100%;
  }
  .voh-consent-radios-wrap {
    flex-basis: 100%;
  }
  .voh-consent-error {
    flex-basis: 100%;
    min-width: 0;
  }
}

/* ---- Step 6 Enrollment (extends existing layout tokens) ---- */
.voh-grid-3 { grid-template-columns: 1fr 1fr 1fr; }
.voh-mono { font-variant-numeric: tabular-nums; }
.voh-fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.voh-fieldset legend { font-size: .82rem; font-weight: 600; margin-bottom: .5rem; padding: 0; }

.voh-carried {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  padding: 1rem 1.1rem;
}
.voh-carried-top {
  display: flex;
  justify-content: space-between;
  gap: .75rem;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: .75rem;
}
.voh-carried-from {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--voh-primary);
}
.voh-link-btn {
  background: none;
  border: none;
  padding: 0;
  font: inherit;
  font-size: .82rem;
  font-weight: 600;
  color: var(--voh-primary);
  cursor: pointer;
  text-decoration: underline;
}
.voh-pairs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: .75rem 1.25rem;
  margin: 0;
}
.voh-pairs dt {
  font-size: .7rem;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--voh-muted);
  font-weight: 700;
}
.voh-pairs dd { margin: .15rem 0 0; font-size: .9rem; }

.voh-fees-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.voh-fees-table {
  width: 100%;
  border-collapse: collapse;
  border-spacing: 0;
  table-layout: fixed;
  display: table;
  margin: 0;
  border: 0;
}
.voh-fees-table thead { display: table-header-group; }
.voh-fees-table tbody { display: table-row-group; }
.voh-fees-table tfoot { display: table-footer-group; }
.voh-fees-table tr { display: table-row; }
.voh-fees-table th,
.voh-fees-table td {
  display: table-cell;
  vertical-align: middle;
  box-sizing: border-box;
}
.voh-fees-table th {
  text-align: left;
  font-size: .7rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--voh-muted);
  font-weight: 700;
  padding: 0 .6rem .5rem;
  border: 0;
  border-bottom: 2px solid var(--voh-border);
}
.voh-fees-table th.voh-num,
.voh-fees-table td.voh-num { text-align: right; }
.voh-fees-table td {
  padding: .75rem .6rem;
  border: 0;
  border-bottom: 1px solid var(--voh-border);
  font-size: .9rem;
}
.voh-fees-table tbody tr:last-child td { border-bottom: 0; }
.voh-fees-table tfoot td {
  border: 0;
  border-top: 2px solid var(--voh-border);
  font-weight: 700;
  padding-top: .85rem;
  padding-bottom: 0;
}
.voh-rate-badge {
  display: inline-block;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  padding: .15rem .45rem;
  border-radius: 4px;
  background: #eff6ff;
  color: var(--voh-primary);
  border: 1px solid #bfdbfe;
}
.voh-rate-badge.alt {
  background: #f1f5f9;
  color: var(--voh-muted);
  border-color: var(--voh-border);
}

.voh-enroll-counters { margin-top: 1.25rem; margin-bottom: 0; }
.voh-review-counter-item.voh-counter-hi {
  background: #fffbeb;
  border-color: #fcd34d;
}
.voh-counter-hi .voh-review-val { color: var(--voh-warn); }
.voh-counter-hi .voh-review-counter-label { color: #b45309; }

.voh-radio-cards { gap: .75rem; }
.voh-radio-card {
  flex: 1;
  min-width: 220px;
  align-items: flex-start;
  padding: .85rem 1rem;
}
.voh-radio-card strong { display: block; font-size: .9rem; }
.voh-radio-card em {
  display: block;
  font-style: normal;
  font-size: .78rem;
  color: var(--voh-muted);
  font-weight: 400;
  margin-top: .2rem;
}

.voh-payer-row {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr auto;
  gap: .75rem;
  align-items: end;
  padding-bottom: 1rem;
  margin-bottom: 1rem;
  border-bottom: 1px dashed var(--voh-border);
}
.voh-payer-row:last-of-type { border-bottom: 0; margin-bottom: .5rem; }

.voh-terms {
  border: 1px solid var(--voh-border);
  border-radius: 8px;
  background: #f8fafc;
  padding: 1rem 1.1rem;
  max-height: 250px;
  overflow: auto;
  font-size: .88rem;
  line-height: 1.6;
}
.voh-terms p { margin: 0 0 .75rem; }
.voh-terms p:last-child { margin: 0; }

.voh-agree-box {
  display: flex;
  gap: .75rem;
  align-items: flex-start;
  margin-top: 1rem;
  border: 1.5px solid var(--voh-border);
  border-radius: 8px;
  padding: .9rem 1rem;
  background: #fff;
}
.voh-agree-box:has(input:checked) {
  border-color: var(--voh-primary);
  background: #eff6ff;
}
.voh-agree-box input { width: 18px; height: 18px; margin-top: .15rem; flex-shrink: 0; accent-color: var(--voh-primary); }
.voh-agree-box label { font-size: .88rem; cursor: pointer; }

.voh-sig-input { font-size: 1.15rem; font-weight: 500; }

.voh-info-banner.voh-banner-warn {
  background: #fffbeb;
  border-color: #fcd34d;
  border-left-color: var(--voh-warn);
  color: #92400e;
}

@media (max-width: 640px) {
  .voh-grid-3 { grid-template-columns: 1fr; }
  .voh-payer-row { grid-template-columns: 1fr; }
  .voh-enroll-counters { flex-wrap: wrap; }
  .voh-enroll-counters .voh-review-counter-item { min-width: calc(50% - .5rem); }
  .voh-fees-table { table-layout: auto; }
  .voh-fees-table thead { display: none; }
  .voh-fees-table tbody,
  .voh-fees-table tfoot { display: block; }
  .voh-fees-table tbody tr {
    display: block;
    border-bottom: 1px solid var(--voh-border);
    padding: .6rem 0;
  }
  .voh-fees-table tbody tr:last-child { border-bottom: 0; }
  .voh-fees-table tbody td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: .75rem;
    border: 0;
    padding: .2rem 0;
  }
  .voh-fees-table tbody td::before {
    content: attr(data-l);
    font-size: .7rem;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--voh-muted);
    font-weight: 700;
  }
  .voh-fees-table tfoot tr {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: .75rem;
    border-top: 2px solid var(--voh-border);
    padding: .85rem 0 0;
  }
  .voh-fees-table tfoot td {
    display: block;
    border: 0;
    padding: 0;
    width: auto;
  }
  .voh-fees-table tfoot td::before { content: none; }
}

@media (min-width: 641px) and (max-width: 900px) {
  .voh-grid-3 { grid-template-columns: 1fr 1fr; }
}
