.patient-address-section[hidden] {
  display: none !important;
}

.form-section-note {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 15px;
}

.form-grid-full {
  grid-column: 1 / -1;
}

.optional-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.field-message {
  display: block;
  min-height: 18px;
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.field-message.is-error {
  color: var(--brand-red-dark);
}

.checkbox-field-message {
  margin: -4px 0 12px 30px;
}

.appointment-form [aria-invalid="true"] {
  border-color: var(--brand-red);
  background: #fff8f8;
}

.appointment-form input[type="checkbox"][aria-invalid="true"] {
  outline: 2px solid var(--brand-red);
  outline-offset: 2px;
}

.address-check-status {
  margin-top: 18px;
  padding: 13px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--light-gray);
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.address-check-status.is-success {
  border-color: #b7efcd;
  background: #ecfdf3;
  color: #087443;
}

.address-check-status.is-warning {
  border-color: #fde68a;
  background: #fffbeb;
  color: #92400e;
}

.address-check-status.is-error {
  border-color: #fecaca;
  background: #fff1f2;
  color: #b42318;
}

.form-privacy-note {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.booking-error-box:focus {
  outline: 3px solid var(--brand-red-soft);
  outline-offset: 3px;
}

.booking-confirmation-page {
  min-height: 70vh;
}

.booking-confirmation-card {
  max-width: 840px;
}

.booking-reference-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin: 24px 0 4px;
  padding: 18px;
  border: 1px solid var(--border);
  border-left: 5px solid var(--brand-red);
  border-radius: 14px;
  background: var(--light-gray);
}

.booking-reference-panel strong {
  display: block;
  margin-bottom: 6px;
  color: var(--charcoal);
}

.booking-reference-panel code {
  display: block;
  color: var(--brand-red-dark);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: clamp(18px, 3vw, 25px);
  font-weight: 900;
  letter-spacing: 0.02em;
  overflow-wrap: anywhere;
}

.booking-reference-copy {
  flex: 0 0 auto;
}

.booking-copy-status {
  min-height: 22px;
  margin: 6px 0 18px;
  font-size: 14px;
  font-weight: 800;
}

.booking-copy-status.is-success {
  color: #087443;
}

.booking-copy-status.is-error {
  color: var(--brand-red-dark);
}

.booking-next-steps {
  margin: 22px 0;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--white);
  text-align: left;
}

.booking-next-steps h2 {
  margin: 0 0 14px;
  color: var(--charcoal);
  font-size: 23px;
}

.booking-next-steps ol {
  margin: 0 0 14px;
  padding-left: 22px;
}

.booking-next-steps li {
  margin: 8px 0;
  line-height: 1.55;
}

.booking-next-steps p {
  margin: 0;
}

.booking-next-steps a {
  color: var(--brand-red);
  font-weight: 900;
}

.booking-emergency-reminder {
  text-align: left;
}

.booking-confirmation-actions {
  flex-wrap: wrap;
}

@media (max-width: 640px) {
  .form-grid-full {
    grid-column: auto;
  }

  .booking-reference-panel {
    align-items: stretch;
    flex-direction: column;
  }

  .booking-reference-copy {
    width: 100%;
  }
}

@media print {
  .site-header,
  .site-footer,
  .booking-confirmation-actions,
  .booking-reference-copy,
  .booking-copy-status {
    display: none !important;
  }

  .booking-confirmation-page,
  .page-hero {
    min-height: 0;
    padding: 0 !important;
    background: #ffffff !important;
  }

  .confirmation-wrap,
  .booking-confirmation-card {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
    box-shadow: none;
  }

  .booking-reference-panel,
  .booking-next-steps,
  .booking-emergency-reminder {
    break-inside: avoid;
  }
}
