/* jcpt-one-library-workbench-20260611
 * Lightweight one-library batch check workbench for amoytest.
 * Loaded after the built app; no business DOM is removed.
 */

.jcpt-ol-workbench {
  width: min(100% - 32px, 1180px);
  margin: 14px auto;
  padding: 10px 14px;
  border: 1px solid #bfd3df;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 6px 16px rgba(20, 58, 82, .06);
  color: #18344c;
  font-family: "HarmonyOS Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

.jcpt-ol-details {
  display: block;
}

.jcpt-ol-summary-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  list-style: none;
  cursor: pointer;
  outline: none;
}

.jcpt-ol-summary-toggle::-webkit-details-marker {
  display: none;
}

.jcpt-ol-summary-toggle span {
  display: grid;
  gap: 4px;
}

.jcpt-ol-summary-toggle strong {
  font-size: 17px;
  line-height: 1.25;
  color: #102b42;
}

.jcpt-ol-summary-toggle small {
  color: #526d80;
  font-size: 13px;
  line-height: 1.5;
}

.jcpt-ol-summary-toggle em {
  flex: 0 0 auto;
  min-width: 58px;
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #b9ccd8;
  border-radius: 999px;
  color: #0b6461;
  background: #f8fbfd;
  font-style: normal;
  font-weight: 800;
}

.jcpt-ol-details[open] .jcpt-ol-summary-toggle em {
  color: #ffffff;
  border-color: #0c6966;
  background: #0b6461;
}

.jcpt-ol-details[open] .jcpt-ol-summary-toggle em::before {
  content: "收起";
}

.jcpt-ol-details[open] .jcpt-ol-summary-toggle em {
  font-size: 0;
}

.jcpt-ol-details[open] .jcpt-ol-summary-toggle em::before {
  font-size: 13px;
}

.jcpt-ol-inner {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #e1ebf1;
}

.jcpt-ol-head,
.jcpt-ol-actions,
.jcpt-ol-summary,
.jcpt-ol-row-actions,
.jcpt-ol-snapshot {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.jcpt-ol-head {
  justify-content: space-between;
  gap: 16px;
}

.jcpt-ol-title {
  display: grid;
  gap: 4px;
}

.jcpt-ol-title strong {
  font-size: 18px;
  line-height: 1.3;
  color: #102b42;
}

.jcpt-ol-title span,
.jcpt-ol-note,
.jcpt-ol-snapshot,
.jcpt-ol-help {
  color: #526d80;
  font-size: 13px;
  line-height: 1.65;
}

.jcpt-ol-main {
  display: grid;
  grid-template-columns: minmax(280px, .78fr) minmax(0, 1.22fr);
  gap: 14px;
  margin-top: 14px;
}

.jcpt-ol-input-card,
.jcpt-ol-result-card {
  display: grid;
  gap: 12px;
  min-width: 0;
  padding: 12px;
  border: 1px solid #d2e0e8;
  border-radius: 14px;
  background: #f8fbfd;
}

.jcpt-ol-textarea {
  width: 100%;
  min-height: 112px;
  padding: 12px;
  border: 1px solid #b8ccd8;
  border-radius: 12px;
  background: #ffffff;
  color: #102b42;
  line-height: 1.65;
  resize: vertical;
  outline: none;
}

.jcpt-ol-textarea:focus {
  border-color: #1f6f91;
  box-shadow: 0 0 0 3px rgba(31, 111, 145, .12);
}

.jcpt-ol-file {
  min-height: 40px;
  padding: 8px;
  border: 1px dashed #9db9c9;
  border-radius: 12px;
  background: #fff;
}

.jcpt-ol-btn {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid #b9ccd8;
  border-radius: 12px;
  background: #ffffff;
  color: #18344c;
  font-weight: 700;
  cursor: pointer;
}

.jcpt-ol-btn.primary {
  color: #ffffff;
  border-color: #0c6966;
  background: linear-gradient(180deg, #0f7f7b, #0b6461);
}

.jcpt-ol-btn:disabled {
  cursor: not-allowed;
  color: #6f8493;
  background: #edf4f7;
  border-color: #c8d7df;
}

.jcpt-ol-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border: 1px solid #bad0dc;
  border-radius: 999px;
  background: #fff;
  color: #18344c;
  font-size: 12px;
  font-weight: 700;
}

.jcpt-ol-chip.ok { color: #0d5d3e; background: #e9f8f0; border-color: #9bd3b6; }
.jcpt-ol-chip.maybe { color: #805000; background: #fff5df; border-color: #e3c070; }
.jcpt-ol-chip.review { color: #164b78; background: #eaf4fb; border-color: #9fc2d8; }
.jcpt-ol-chip.none { color: #8a2d26; background: #fff0ee; border-color: #efb1aa; }

.jcpt-ol-table-wrap {
  max-height: 430px;
  overflow: auto;
  border: 1px solid #d5e3eb;
  border-radius: 14px;
  background: #fff;
}

.jcpt-ol-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.jcpt-ol-table th,
.jcpt-ol-table td {
  padding: 10px;
  border-bottom: 1px solid #e7eef3;
  vertical-align: top;
  text-align: left;
}

.jcpt-ol-table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #eef6fa;
  color: #17334a;
  font-weight: 800;
}

.jcpt-ol-table tr:last-child td {
  border-bottom: 0;
}

.jcpt-ol-candidate,
.jcpt-ol-labs {
  display: grid;
  gap: 4px;
}

.jcpt-ol-labs a {
  color: #0e6562;
  font-weight: 700;
  text-decoration: none;
}

.jcpt-ol-labs a:hover {
  text-decoration: underline;
}

.jcpt-ol-empty {
  padding: 24px;
  border: 1px dashed #bed2dd;
  border-radius: 14px;
  text-align: center;
  color: #526d80;
  background: #fff;
}

.jcpt-ol-progress {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #e2edf3;
}

.jcpt-ol-progress span {
  display: block;
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #0f7f7b, #1f6f91);
  transition: width .18s ease;
}

/* The old floating self-check button overlaps the new fixed workbench.
 * Keep the permanent workbench as the entry instead of a screen-covering float.
 */
#jcpt-sc-btn {
  display: none !important;
}

@media (max-width: 980px) {
  .jcpt-ol-workbench {
    width: calc(100% - 20px);
    margin: 12px auto;
    padding: 12px;
    border-radius: 16px;
  }

  .jcpt-ol-summary-toggle {
    align-items: flex-start;
  }

  .jcpt-ol-main {
    grid-template-columns: 1fr;
  }

  .jcpt-ol-table-wrap {
    max-height: 420px;
  }

  .jcpt-ol-table {
    min-width: 760px;
  }
}

@media (max-width: 640px) {
  #jcpt-suggest-box {
    max-height: min(42vh, 260px) !important;
    pointer-events: none !important;
  }

  .market-search-button,
  .market-search-button-strong {
    position: relative !important;
    z-index: 100002 !important;
  }
}
