.qt-entry { margin-top: 24px; }
.qt-entry > .task-support-body { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.qt-entry strong { font-size: 13px; }
.qt-entry p { margin-bottom: 0; }
.qt-panel { display: grid; gap: 22px; min-width: 0; }
.qt-tabs { display: flex; gap: 6px; padding-bottom: 12px; border-bottom: 1px solid #e1e6ee; }
.qt-tabs .button[aria-pressed=true] { color: #354982; background: #edf1f8; border-color: #bfcbe0; }
.qt-form { display: grid; gap: 20px; min-width: 0; }
.qt-form > .field { margin: 0; }
.qt-note { padding: 15px 17px; border-left: 3px solid #8b9fbd; background: #f3f6fa; font-size: 12px; line-height: 1.75; overflow-wrap: anywhere; }
.qt-note strong { color: #344763; font-size: 13px; }
.qt-note p { margin: 5px 0 0; color: #65758b; }
.qt-section { border-top: 1px solid #e1e6ee; padding-top: 20px; }
.qt-section-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.qt-section-head h3 { margin: 6px 0 0; font-size: 16px; }
.qt-eyebrow { font-size: 10px; color: #71839f; letter-spacing: .07em; }
.qt-count { flex-shrink: 0; font-size: 12px; color: #506589; font-variant-numeric: tabular-nums; }
.qt-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px 20px; min-width: 0; }
.qt-fields > .field { min-width: 0; margin: 0; }
.qt-fields input, .qt-fields select, .qt-fields textarea { min-width: 0; max-width: 100%; }
.qt-help { color: #758197; font-size: 11px; line-height: 1.85; margin: 0; overflow-wrap: anywhere; }
.qt-selection-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 11px; color: #64758f; }
.qt-selection-head .actions { gap: 3px; }
.qt-people, .qt-slot-picks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px 14px; max-height: 285px; overflow-y: auto; padding: 1px; }
.qt-check { display: flex; align-items: flex-start; gap: 9px; padding: 9px 7px; font-size: 12px; line-height: 1.55; cursor: pointer; border-radius: 4px; min-width: 0; }
.qt-check:has(input:checked) { background: #edf2fa; }
.qt-check input { width: 16px; height: 16px; margin-top: 2px; flex-shrink: 0; accent-color: #536c9f; }
.qt-check span { min-width: 0; overflow-wrap: anywhere; }
.qt-check strong { display: block; font-size: 12px; font-weight: 500; }
.qt-check small { display: block; color: #7d899c; font-size: 10px; margin-top: 2px; }
.qt-event-picker { border: 1px solid #dde4ee; border-radius: 5px; padding: 10px 13px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 12px; min-width: 0; }
.qt-event-picker legend { font-size: 12px; color: #526580; padding-inline: 5px; }
.qt-footer { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 16px; border-top: 1px solid #e1e6ee; }
/* Keep explicit confirmation visible while the independently scrolling preview is inspected. */
#modal[open]:has([data-form="qt-apply"]) { display: flex; flex-direction: column; overflow: hidden; }
#modal:has([data-form="qt-apply"]) > .modal-head { flex-shrink: 0; }
#modal:has([data-form="qt-apply"]) > .modal-body { display: flex; flex-direction: column; padding: 0; overflow: hidden; min-height: 0; }
.qt-panel:has(> [data-form="qt-apply"]) { display: flex; flex-direction: column; min-height: 0; }
.qt-form[data-form="qt-apply"] { display: flex; flex-direction: column; gap: 0; min-height: 0; overflow: hidden; }
.qt-preview-content { display: grid; gap: 20px; padding: 20px; overflow-y: auto; min-height: 0; overscroll-behavior: contain; }
.qt-form[data-form="qt-apply"] > .qt-footer { position: sticky; bottom: 0; z-index: 2; flex-shrink: 0; background: #fff; padding: 14px 20px; box-shadow: 0 -4px 14px #283d5707; }
#modal:has([data-form="qt-apply"]) [data-form-error]:not(:empty) { margin: 0; padding: 12px 20px; max-height: 100px; overflow-y: auto; flex-shrink: 0; background: #fff7f5; }
.qt-metrics { display: flex; gap: 35px; padding: 6px 0 15px; border-bottom: 1px solid #e1e6ee; }
.qt-metrics strong { display: block; color: #344968; font-size: 27px; font-weight: 500; }
.qt-metrics span { display: block; font-size: 11px; color: #78869b; margin-top: 4px; }
.qt-preview-list { display: grid; gap: 0; }
.qt-preview-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 14px 5px; border-bottom: 1px solid #e5e9f0; min-width: 0; }
.qt-preview-row > div:first-child { flex: 1; min-width: 0; }
.qt-preview-row strong, .qt-time-row strong { font-size: 12px; font-weight: 500; overflow-wrap: anywhere; }
.qt-preview-row small, .qt-time-row small { display: block; font-size: 10px; color: #7d899b; margin-top: 4px; line-height: 1.7; overflow-wrap: anywhere; }
.qt-preview-row.has-error { background: #fff7ef; }
.qt-preview-row details { margin-top: 8px; font-size: 11px; color: #697c98; }
.qt-preview-row summary { cursor: pointer; }
.qt-row-actions { display: grid; justify-items: end; gap: 6px; flex-shrink: 0; }
.qt-answers { display: grid; grid-template-columns: minmax(70px, 1fr) minmax(0, 2fr); gap: 6px 12px; font-size: 11px; color: #65748d; margin: 12px 0 0; }
.qt-answers dt, .qt-answers dd { margin: 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.qt-answers dd { color: #364b68; }
.qt-node-save { display: flex; align-items: flex-end; gap: 12px; margin: 20px 0 10px; }
.qt-node-save .field { flex: 1; min-width: 0; margin: 0; }
.qt-node-save > .button { min-height: 37px; }
.qt-node-list { margin-top: 12px; }
.qt-node-list article { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid #e4e9f1; }
.qt-node-list article > div { min-width: 0; }
.qt-node-list strong { font-size: 12px; overflow-wrap: anywhere; }
.qt-node-list small { display: block; font-size: 10px; color: #7e8a9e; line-height: 1.7; margin-top: 5px; overflow-wrap: anywhere; }
.qt-node-list .button { flex-shrink: 0; }
.qt-summary { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 12px 20px; font-size: 12px; line-height: 1.7; }
.qt-summary dt { color: #7a879c; }
.qt-summary dd { margin: 0; overflow-wrap: anywhere; }
.qt-order-fold { border-top: 1px solid #e3e8f0; padding-top: 14px; }
.qt-order-fold summary { font-size: 12px; color: #576d8b; cursor: pointer; margin-bottom: 12px; }
.qt-order-row, .qt-time-row { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid #e7ebf1; font-size: 12px; }
.qt-order-row > span:nth-child(2) { flex: 1; min-width: 0; }
.qt-order-row small { display: block; margin-top: 3px; color: #7c8a9f; font-size: 10px; }
.qt-order-row .actions { flex-shrink: 0; gap: 3px; }
.qt-order { width: 24px; height: 24px; flex-shrink: 0; display: grid; place-items: center; background: #edf1f7; border-radius: 50%; color: #5b7094; font-size: 11px; }
.qt-time-row { align-items: flex-start; padding: 14px 0; }
.qt-time-row > div { min-width: 0; }
.qt-time-row p { font-size: 12px; margin: 7px 0 0; color: #3d5376; line-height: 1.7; }
.qt-issues { padding-left: 18px; font-size: 11px; color: #996d43; line-height: 1.9; }
.reg-batch-filters { display: grid; gap: 9px; padding: 0 1px 14px; }
.reg-batch-filters .field { font-size: 11px; margin: 0; }
.reg-batch-filters select { font-size: 12px; padding: 9px; }
.reg-batch-select-all { padding: 0 3px 10px; font-size: 11px; }
.reg-batch-task { display: flex; gap: 5px; align-items: flex-start; }
.reg-batch-task > label { flex-shrink: 0; display: grid; place-items: center; width: 27px; padding-top: 18px; }
.reg-batch-task > label input { width: 16px; height: 16px; accent-color: #536c9f; }
.reg-batch-task .reg-task { min-width: 0; flex: 1; }
.reg-batch-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; background: #edf2f9; border: 1px solid #d8e1ef; border-radius: 6px; margin-bottom: 16px; }
.reg-batch-toolbar > strong { font-size: 12px; color: #486080; }
.reg-batch-toolbar .actions { gap: 6px; }
.sched-batch-entry { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 0 0 16px; }
@media (pointer: coarse) { .qt-node-save > .button { min-height: 44px; } }
@media (max-width: 640px) {
  .qt-panel, .qt-form { gap: 17px; }
  .qt-tabs .button { flex: 1; padding: 10px 6px; font-size: 12px; }
  .qt-selection-head { align-items: flex-start; flex-direction: column; gap: 6px; }
  .qt-fields { grid-template-columns: minmax(0, 1fr); gap: 13px; }
  .qt-people, .qt-slot-picks, .qt-event-picker { grid-template-columns: minmax(0, 1fr); }
  .qt-section-head { gap: 8px; }
  .qt-section-head h3 { font-size: 15px; }
  .qt-count { font-size: 10px; }
  .qt-note { padding: 12px; }
  .qt-node-save { align-items: stretch; flex-direction: column; }
  .qt-node-save .button { align-self: flex-end; min-height: 44px; }
  .qt-order-row { gap: 7px; font-size: 11px; }
  .qt-order-row .button { font-size: 10px; padding-inline: 5px; }
  .qt-footer > .button { padding-inline: 10px; font-size: 12px; }
  .qt-preview-content { gap: 17px; padding: 16px; }
  .qt-form[data-form="qt-apply"] > .qt-footer { padding: 12px 16px; }
  .qt-preview-row { gap: 7px; }
  .qt-preview-row > .badge { max-width: 85px; }
  .qt-preview-row strong { font-size: 11px; }
  .qt-row-actions .button { padding-inline: 5px; font-size: 10px; }
  .qt-summary { grid-template-columns: 65px minmax(0, 1fr); gap: 10px 14px; }
  .qt-entry > .task-support-body { align-items: flex-start; flex-direction: column; }
  .reg-batch-toolbar { align-items: flex-start; flex-direction: column; padding: 12px; }
  .reg-batch-toolbar .actions { flex-wrap: wrap; width: 100%; }
  .reg-batch-toolbar .button { font-size: 11px; padding-inline: 8px; }
  .reg-batch-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sched-batch-entry { align-items: flex-start; flex-direction: column; }
}
