.wv-jobs-overlay {position:fixed;inset:0;z-index:2147483000;background:rgba(25,32,52,.48);display:flex;align-items:center;justify-content:center;padding:20px;box-sizing:border-box}
.wv-jobs-dialog {font-family:inherit;color:#343951;background:#fff;border-radius:20px;width:min(720px,100%);max-height:calc(100dvh - 40px);display:flex;flex-direction:column;box-shadow:0 18px 60px #19203440;overflow:hidden}
.wv-jobs-dialog * {box-sizing:border-box}
.wv-jobs-header {background:#353851;color:white;padding:20px 24px;display:flex;align-items:center;gap:16px;justify-content:space-between}
.wv-jobs-header h2 {font-size:22px;font-weight:700;color:inherit;margin:0}
.wv-jobs-dialog .wv-jobs-close {display:grid;place-items:center;background:transparent;color:white;border:0;border-radius:5px;width:36px;height:36px;min-width:36px;padding:0;font-size:23px;line-height:1;cursor:pointer;box-shadow:none}
.wv-jobs-dialog .wv-jobs-close:hover {background:transparent;color:#f24c5d;transform:none}
.wv-jobs-body {padding:24px;overflow:auto;min-height:0}
.wv-jobs-footer {border-top:1px solid #e4eaf0;padding:16px 24px;display:flex;justify-content:flex-end;gap:10px;flex-wrap:wrap}
.wv-jobs-body p {color:#61718a;line-height:1.5;margin:0 0 16px}
.wv-job-field {display:flex;flex-direction:column;gap:7px;margin:0 0 18px;font-weight:600;font-size:14px;text-align:left}
.wv-job-field input,.wv-job-field select,.wv-job-field textarea {width:100%;background:#fff;color:#343951;border:1px solid #dce4ee;border-radius:11px;padding:12px;font:inherit;min-height:44px}
.wv-job-field textarea {resize:vertical;min-height:100px}
.wv-job-button {border:1px solid #dae3ed;border-radius:11px;background:#f5f7fa;color:#353851;padding:11px 16px;font-family:inherit;font-size:14px;font-weight:600;line-height:1.4;cursor:pointer;min-height:44px;transition:background .15s,border-color .15s}
.wv-job-button:hover {background:#e9eef4;border-color:#bdcbdc;transform:none}
.wv-job-button.primary {background:#3c785b;color:#fff;border-color:#3c785b}
.wv-job-button.primary:hover {background:#30634a;border-color:#30634a}
.wv-job-button.danger {color:#af3d47;background:#fff5f5;border-color:#efd8da}
.wv-job-button:disabled {opacity:.55;cursor:default}
.wv-job-button:focus-visible,.wv-job-task:focus-within {outline:3px solid #88b8a5;outline-offset:2px}
.wv-job-row {display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 0;border-bottom:1px solid #e9edf3}
.wv-job-row small {display:block;color:#68778f;margin-top:4px}
.wv-job-actions {display:flex;gap:8px;flex-wrap:wrap}
.wv-job-task {display:flex;gap:12px;align-items:flex-start;border:1px solid #dde7e4;background:#f6faf8;padding:14px;border-radius:12px;margin-bottom:10px;cursor:pointer}
.wv-job-task input {width:18px;height:18px;flex:none;accent-color:#3c785b;margin:3px 0}
.wv-job-task small {display:block;font-size:13px;color:#60746a;white-space:pre-wrap;margin-top:5px}
.wv-job-error {color:#a5333d!important;background:#fff2f2;border-radius:10px;padding:12px;margin-bottom:16px}
.wv-job-instructions {white-space:pre-wrap;line-height:1.55;font-size:15px;color:#3f5262}
.wv-visit-jobs {scroll-margin-top:90px;background:white;border:1px solid #dce6ee;border-left:4px solid #3c785b;border-radius:16px;padding:18px;margin:16px 0}
.wv-visit-jobs h3 {font-size:18px;margin:0 0 12px;color:#343951}
.wv-visit-jobs details {border-top:1px solid #e5ece9;padding:12px 0}
.wv-visit-jobs summary {font-weight:650;color:#3c705a;cursor:pointer}
/* Partial-fill scheduling: compact product cards with explicit pick controls. */
.wv-partial-heading {font-size:16px;font-weight:700;color:#343951;margin:4px 0 6px}
.wv-jobs-body .wv-partial-hint {font-size:13px;margin-bottom:14px}
.wv-partial-list {display:grid;gap:8px;margin-bottom:20px}
.wv-job-partial {display:grid;grid-template-columns:44px minmax(0,1fr) 104px;align-items:center;gap:12px;padding:12px;border:1px solid #e2e8ef;border-radius:12px;background:#fff;text-align:left}
.wv-job-partial.is-selected {background:#f1f8f4;border-color:#a7cbb7}
.wv-partial-image {width:44px;height:54px;object-fit:contain;border-radius:7px;background:#fff;padding:3px}
.wv-partial-product {min-width:0;display:flex;flex-direction:column;gap:5px}
.wv-partial-selection {font-size:11px;font-weight:600;color:#63738a;line-height:1.3}
.wv-partial-name {font-size:13px;font-weight:600;line-height:1.45;color:#343951;overflow-wrap:anywhere}
.wv-partial-quantity {display:flex;flex-direction:column;gap:5px}
.wv-partial-quantity-label {font-size:11px;font-weight:600;color:#63738a;text-align:center}
.wv-partial-stepper {display:grid;grid-template-columns:30px minmax(0,1fr) 30px;border:1px solid #d4e2da;border-radius:9px;overflow:hidden;background:white}
.wv-partial-stepper .wv-job-button {min-height:40px;padding:0;border:0;border-radius:0;background:#edf5f0;color:#35664e;font-size:19px;line-height:1;box-shadow:none;margin:0}
.wv-partial-stepper .wv-job-button:hover:not(:disabled) {background:#dcece2;color:#28543e;transform:none}
.wv-partial-stepper .wv-job-button:disabled {background:#f5f7f8;color:#a1aab4;opacity:1}
.wv-partial-stepper input {width:100%;min-width:0;margin:0;padding:0 2px;border:0;border-radius:0;background:white;color:#343951;font:inherit;font-size:14px;font-weight:600;text-align:center;appearance:textfield;-moz-appearance:textfield;box-shadow:none}
.wv-partial-stepper input::-webkit-inner-spin-button,.wv-partial-stepper input::-webkit-outer-spin-button {appearance:none;margin:0}
.wv-partial-stepper:focus-within {outline:2px solid #3c785b;outline-offset:2px}
.wv-partial-stepper input:focus {outline:none}
.wv-job-field input:focus-visible,.wv-job-field select:focus-visible,.wv-job-field textarea:focus-visible {outline:2px solid #3c785b;outline-offset:2px;border-color:#9fc1ae}
@media(max-width:420px){.wv-job-partial{grid-template-columns:36px minmax(0,1fr) 96px;gap:8px;padding:10px}.wv-partial-image{width:36px;height:48px}.wv-partial-name{font-size:12px}}
@media(max-width:540px){.wv-jobs-overlay{padding:10px}.wv-jobs-dialog{max-height:calc(100dvh - 20px);border-radius:16px}.wv-jobs-header,.wv-jobs-body{padding:18px}.wv-jobs-header h2{font-size:20px}.wv-job-row{align-items:flex-start;flex-wrap:wrap}.wv-jobs-footer{padding:14px 18px}}

/* Explicit states prevent the global form-button hover from leaking into tables. */
.service-type-cell:has(.service-job-choice) { gap: 8px; }
.service-type-cell .service-type-select { min-width: 0; }
.service-type-cell .service-job-choice {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-height: 32px;
  margin: 0;
  padding: 6px 10px;
  border: 1px solid #d4e4db;
  border-radius: 9px;
  background: #f0f7f3;
  color: #35664e;
  font: inherit;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
  text-decoration: none;
  box-shadow: none;
  cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease;
}
.service-type-cell .service-job-choice:hover {
  background: #e2efe7;
  border-color: #a7c6b4;
  color: #28543e;
  text-decoration: none;
  transform: none;
  box-shadow: none;
}
.service-type-cell .service-job-choice:active { background: #d7e8dd; color: #28543e; }
.service-type-cell .service-job-choice:focus-visible { outline: 2px solid #3c785b; outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .service-type-cell .service-job-choice { transition: none; } }

.wv-jobs-close i {font-size:28px;line-height:1;margin:0}
.wv-jobs-dialog [hidden] {display:none!important}
.wv-jobs-dialog.wv-repair-reminder {width:min(480px,100%)}
.wv-repair-reminder .wv-repair-machine {font-weight:700;color:#343951;margin-bottom:8px}
.wv-repair-reminder .wv-jobs-body p:last-child {margin-bottom:0}

/* Keep visit instructions aligned with the existing mobile detail cards. */
#machine-detail-container .wv-visit-jobs {
  margin: 15px;
  padding: 15px 20px;
  border-radius: 12px;
  min-width: 0;
  overflow-wrap: anywhere;
}
#machine-detail-container .wv-visit-jobs details:last-child { padding-bottom: 0; }
.machine-schedule-action { border-top: 1px solid #e3e9ed; padding-top: 14px; margin-top: 4px; }
.action-buttons-section .machine-schedule-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  background: #f5f7fa;
  color: #353851;
  border: 1px solid #dae3ed;
  border-radius: 10px;
  font-size: 14px;
  min-height: 44px;
}
.action-buttons-section .machine-schedule-button:hover { background: #e9eef4; border-color: #bdcbdc; }
.action-buttons-section .machine-schedule-button:focus-visible { outline: 2px solid #3c785b; outline-offset: 3px; }
.wv-jobs-dialog [hidden] { display: none !important; }
