.wiLaunch .card {
  border-left: 4px solid #be7040;
}
.wiLaunch p {
  margin: 6px 0 14px;
}
.wiBadge {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  border-radius: 999px;
  padding: 6px 11px;
  font-weight: 700;
  font-size: 0.85rem;
  white-space: normal;
}
.wi-needs_review {
  background: #ffead8;
  color: #823b0d;
}
.wi-in_review {
  background: #fff2c4;
  color: #6d5000;
}
.wi-resolved {
  background: #ddf3e9;
  color: #18583d;
}
.wiNotice {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: #fff3e6;
  border: 1px solid #eac8a6;
  border-radius: 14px;
  padding: 15px;
  margin: 16px 0;
  color: #694624;
}
.wiFilters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 20px 0;
}
.wiFilters [aria-pressed='true'] {
  outline: 2px solid #176b67;
  background: #e4f3ef;
}
.wiRow {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  margin-bottom: 12px;
}
.wiRow h3 {
  margin: 10px 0 6px;
}
.wiRow small,
.wiReference {
  overflow-wrap: anywhere;
}
.wiGrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.wiForm,
.wiDetail {
  width: 100%;
  max-width: 740px;
}
.wiForm textarea,
.wiReviewForm textarea {
  width: 100%;
  resize: vertical;
}
.wiForm .field,
.wiReviewForm .field {
  margin: 16px 0;
}
.wiForm input,
.wiForm select,
.wiForm textarea,
.wiReviewForm select,
.wiReviewForm textarea {
  font-size: 16px;
  max-width: 100%;
  box-sizing: border-box;
}
.wiDetailField {
  border-bottom: 1px solid #e4e9e7;
  padding: 13px 0;
}
.wiDetail p {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.wiDetail h4 {
  margin: 24px 0 12px;
}
.wiReview {
  border: 1px solid #d9e3de;
  padding: 14px;
  border-radius: 12px;
  margin: 12px 0;
}
.wiReviewForm {
  background: #f1f6f3;
  border-radius: 14px;
  padding: 16px;
  margin: 20px 0;
}
.wiPage .actions {
  flex-wrap: wrap;
}
#wiSaveError,
#wiReviewError {
  color: #a32323;
  white-space: pre-wrap;
  margin: 10px 0;
}
@media (max-width: 600px) {
  .wiGrid {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .wiRow {
    align-items: flex-start;
    flex-direction: column;
  }
  .wiLaunch .sectionHead {
    flex-wrap: wrap;
  }
  .wiForm,
  .wiDetail {
    max-width: 100%;
  }
  .wiRow .btn {
    width: 100%;
  }
}
@media print {
  body.wiPrinting > * {
    display: none !important;
  }
  body.wiPrinting #modal {
    display: block !important;
    position: static !important;
    background: white !important;
    padding: 0 !important;
    overflow: visible !important;
    max-height: none !important;
  }
  body.wiPrinting #modal > * {
    max-height: none !important;
    overflow: visible !important;
    max-width: 100% !important;
    box-shadow: none !important;
  }
  body.wiPrinting .wiDetail {
    display: block !important;
    color: black !important;
  }
  body.wiPrinting .wiReviewForm,
  body.wiPrinting .wiPrintActions,
  body.wiPrinting #modal button,
  body.wiPrinting #modalStatus {
    display: none !important;
  }
  .wiDetailField,
  .wiReview {
    break-inside: avoid;
  }
}

/* Queue filters retain readable controls on phones. */
.wiScope {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 20px 0;
}
.wiScope .field {
  min-width: 0;
}
.wiScope label {
  display: block;
  font-weight: 700;
  margin-bottom: 8px;
}
.wiScope select {
  width: 100%;
  min-width: 0;
  min-height: 46px;
  font-size: 16px;
  border: 1px solid #becfc9;
  border-radius: 12px;
  background: #fffdf8;
  color: #173d3c;
  padding: 10px;
}
.wiPage .btn {
  min-height: 44px;
}
.wiScope select:focus-visible,
.wiPage .btn:focus-visible {
  outline: 3px solid #176b67;
  outline-offset: 3px;
}
.wiResult {
  color: #47615d;
  margin: 14px 0;
}
.wiRow > div {
  min-width: 0;
  overflow-wrap: anywhere;
}
.wiPage .sectionHead {
  flex-wrap: wrap;
}
.wiFilters .btn {
  white-space: normal;
  text-align: left;
}
@media (max-width: 600px) {
  .wiScope {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }
  .wiFilters {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .wiFilters .btn:first-child {
    grid-column: 1/-1;
  }
}
