/* Keep the actual CF7 submit control visible while the fields scroll. */
@media (max-width: 767px) {
  #modalSchedule { top: var(--sos-viewport-top, 0px); height: var(--sos-viewport-height, 100dvh); bottom: auto; overflow: hidden; }
  #modalSchedule .modal-dialog { margin: 8px auto; min-height: 0; height: calc(100% - 16px); }
  #modalSchedule .modal-content { height: 100%; max-height: none; grid-template-rows: auto minmax(0, 1fr); overflow: hidden; }
  #modalSchedule .modalSchedule-main { min-height: 0; display: flex; flex-direction: column; overflow: hidden; padding: 12px 16px 0; }
  #modalSchedule .modal-heading { flex: 0 0 auto; margin-bottom: 12px; }
  #modalSchedule .modal-heading__title { font-size: 22px; }
  #modalSchedule .modal-body, #modalSchedule .wpcf7, #modalSchedule form { display: flex; flex-direction: column; flex: 1 1 auto; min-height: 0; }
  #modalSchedule .form-fields { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; align-content: flex-start; padding-top: 2px; scroll-padding: 12px; }
  #modalSchedule .sos-booking-actions { flex: 0 0 auto; padding: 10px 0 max(10px, env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid #e8e8e8; }
  #modalSchedule .sos-booking-actions .form-field { padding: 0; width: 100%; }
  #modalSchedule .sos-booking-actions .form-field-button { margin-bottom: 6px; }
  #modalSchedule .sos-booking-actions .form-field-required { margin: 0; font-size: 11px; line-height: 1.3; }
  #modalSchedule .sos-booking-actions p { margin: 0; }
  #modalSchedule .wpcf7-response-output { flex: 0 0 auto; margin: 4px 0 8px; max-height: 70px; overflow: auto; }
  #modalSchedule.sos-keyboard-open .modal-heading { display: none; }
  #modalSchedule.sos-keyboard-open .sos-booking-actions .form-field-required { display: none; }
  #modalSchedule.sos-keyboard-open .modalSchedule-call { padding-top: 8px; padding-bottom: 8px; }
}
