.result-explorer {
  display: grid;
  gap: 2rem;
  min-width: 0;
  grid-template-columns: minmax(0, 1fr);
}

.result-explorer > * {
  min-width: 0;
}

.result-explorer.page-layout {
  --page-content-gap: 2rem;
  gap: 1.5rem;
}

.result-explorer > section,
.result-explorer > details,
.result-explorer > .page-content > section,
.result-explorer > .page-content > details {
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
}

.result-explorer h2 {
  margin-top: 0;
}

.threshold-panel {
  display: grid;
  gap: 0.65rem;
  max-width: 44rem;
  padding: 1.25rem;
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  background: var(--soft);
}

.threshold-panel label {
  font-size: 1.1rem;
  font-weight: 750;
}

.threshold-panel output {
  display: inline-block;
  min-width: 1.5ch;
  color: var(--teal);
  font-size: 1.25rem;
  text-align: center;
}

.threshold-panel input[type="range"] {
  width: 100%;
  min-height: 2.25rem;
  accent-color: var(--teal);
}

.threshold-panel input[type="range"]:disabled {
  cursor: wait;
  opacity: 0.55;
}

.threshold-ticks {
  display: flex;
  justify-content: space-between;
  padding-inline: 0.55rem;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.threshold-panel p,
.result-explorer section > p {
  max-width: 52rem;
}

.noscript-warning,
.empty-state {
  padding: 0.75rem 1rem;
  border-left: 0.25rem solid var(--teal);
  background: var(--soft);
}

.table-scroll,
.blot-scroll {
  overflow-x: auto;
  padding: 0.2rem;
}

.result-explorer table {
  width: 100%;
  min-width: 44rem;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}

.result-explorer caption {
  padding-bottom: 0.55rem;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: left;
}

.result-explorer th,
.result-explorer td {
  padding: 0.6rem 0.7rem;
  border: 1px solid var(--border);
  text-align: right;
  vertical-align: top;
}

.result-explorer thead th {
  background: var(--navy);
  color: white;
  font-size: 0.86rem;
  white-space: nowrap;
}

.result-explorer tbody th,
.result-explorer td:nth-child(2) {
  text-align: left;
}

.result-explorer td:last-child {
  text-align: left;
}

.result-explorer tbody tr:nth-child(even) {
  background: var(--soft);
}

.result-explorer code {
  overflow-wrap: anywhere;
}

.overview-definition {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem 1.25rem;
}

.overview-definition div {
  display: grid;
  grid-template-columns: minmax(8rem, 0.45fr) minmax(0, 1fr);
  gap: 0.75rem;
}

.overview-definition dt {
  font-weight: 750;
}

.overview-definition dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.blot-scroll {
  max-width: 100%;
}

.blot {
  display: grid;
  grid-template-columns: 5rem minmax(max-content, 1fr);
  gap: 1rem;
  min-width: calc(6rem + var(--lane-count) * 7rem);
}

.blot-axis {
  position: relative;
  height: 34rem;
  margin-top: 2.4rem;
  border-right: 2px solid var(--navy);
}

.axis-label {
  position: absolute;
  top: calc(var(--axis-position) * 0.034rem);
  right: 0.55rem;
  transform: translateY(-50%);
  color: var(--muted);
  font-size: 0.76rem;
  white-space: nowrap;
}

.axis-label::after {
  position: absolute;
  top: 50%;
  left: calc(100% + 0.25rem);
  width: 0.55rem;
  border-top: 1px solid var(--navy);
  content: "";
}

.axis-label-top {
  transform: none;
}

.axis-label-bottom {
  transform: translateY(-100%);
}

.blot-lanes {
  display: flex;
  gap: 1rem;
}

.blot-lane {
  position: relative;
  width: 6rem;
  margin: 0;
}

.blot-lane figcaption {
  height: 2.4rem;
  overflow: hidden;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.15;
  text-align: center;
  text-overflow: ellipsis;
}

.blot-lane canvas {
  display: block;
  width: 6rem;
  height: 34rem;
  border: 1px solid #364452;
  background: #040608;
  image-rendering: auto;
}

.band-targets {
  position: absolute;
  top: 2.4rem;
  right: 0;
  left: 0;
  height: 34rem;
  pointer-events: none;
}

.band-target {
  position: absolute;
  top: calc(var(--band-position) * 0.034rem);
  left: 0;
  width: 100%;
  min-height: 0.7rem;
  padding: 0;
  transform: translateY(-50%);
  border: 1px solid transparent;
  border-radius: 0.2rem;
  background: transparent;
  cursor: pointer;
  pointer-events: auto;
}

.band-target:hover,
.band-target[aria-pressed="true"] {
  border-color: var(--teal);
  background: rgb(20 184 166 / 18%);
}

.band-target:focus-visible,
.band-select:focus-visible,
.component-select:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 2px;
}

.blot-empty {
  position: absolute;
  top: 50%;
  right: 0.35rem;
  left: 0.35rem;
  margin: 0;
  color: #dce9f0;
  font-size: 0.75rem;
  text-align: center;
}

.possible-section {
  padding-right: 1rem;
  padding-bottom: 1rem;
  padding-left: 1rem;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  border-left: 0.3rem solid var(--teal);
  border-radius: 0.25rem;
}

.diagnostic-section {
  padding-right: 1rem;
  padding-bottom: 1rem;
  padding-left: 1rem;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  border-left: 0.3rem solid #6b7280;
  border-radius: 0.25rem;
}

.match-status {
  display: inline-block;
  padding: 0.15rem 0.45rem;
  border: 1px solid currentcolor;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 750;
  line-height: 1.25;
  white-space: nowrap;
}

.match-status-accepted_hamming_guaranteed {
  color: #146c43;
  background: #e9f7ef;
}

.match-status-possible_match_ambiguous {
  color: #875a00;
  background: #fff7dc;
}

.match-status-blast_candidate_hamming_above_threshold,
.match-status-no_blast_candidate,
.match-status-rna_shorter_than_probe {
  color: #4b5563;
  background: #f3f4f6;
}

.match-details {
  min-width: 15rem;
}

.match-details > summary,
.band-components-fallback > summary {
  color: var(--navy);
  font-weight: 750;
  cursor: pointer;
}

.match-evidence {
  display: grid;
  grid-template-columns: repeat(2, minmax(15rem, 1fr));
  gap: 0.5rem 1rem;
  min-width: 34rem;
  margin: 0.85rem 0;
}

.match-evidence div {
  display: grid;
  grid-template-columns: minmax(9rem, 0.45fr) minmax(0, 1fr);
  gap: 0.65rem;
}

.match-evidence dt {
  font-weight: 750;
}

.match-evidence dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.coordinate-note {
  color: var(--muted);
  font-size: 0.82rem;
}

.hsp-provenance {
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
}

.hsp-provenance h4 {
  margin: 0;
}

.hsp-table {
  min-width: 72rem !important;
}

.diagnostic-hsp {
  box-shadow: inset 0.25rem 0 var(--teal);
}

.diagnostic-label {
  color: var(--teal);
  font-size: 0.72rem;
  font-weight: 750;
  text-transform: uppercase;
}

.band-select,
.component-select {
  padding: 0.4rem 0.65rem;
  border: 1px solid var(--navy);
  border-radius: 0.25rem;
  background: white;
  color: var(--navy);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.band-select[aria-pressed="true"] {
  background: var(--navy);
  color: white;
}

.band-components-fallback {
  margin-top: 0.6rem;
}

.band-component-fallback {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
}

.band-selection {
  margin-top: 1rem;
  padding: 1rem;
  border: 2px solid var(--teal);
  border-radius: 0.5rem;
  background: var(--soft);
}

.band-selection h3 {
  margin-top: 0;
}

.band-component-table {
  min-width: 50rem;
}

.band-component-record {
  margin-top: 1rem;
}

.interpretation-note summary {
  color: var(--navy);
  font-weight: 750;
  cursor: pointer;
}

.interpretation-note li + li {
  margin-top: 0.45rem;
}

@media (max-width: 40rem) {
  .result-explorer {
    gap: 1.5rem;
  }

  .threshold-panel {
    margin-inline: -0.5rem;
  }

  .overview-definition,
  .overview-definition div,
  .match-evidence,
  .match-evidence div {
    grid-template-columns: minmax(0, 1fr);
  }
}
