/* ============ MODEL EXPLORER ============ */
.explorer {
  max-width: var(--container);
  margin: 0 auto;
  padding: 2.5rem 2.5rem 5rem;
}

.explorer-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.explorer-select-wrap label {
  display: block;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-bottom: 0.5rem;
}

.explorer-select-wrap select {
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--rule);
  border-radius: var(--radius-sm);
  padding: 12px 40px 12px 16px;
  min-width: 320px;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9'%3E%3Cpath d='M1 1l6 6 6-6' stroke='%2333463c' stroke-width='2' fill='none' fill-rule='evenodd'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
}

.explorer-select-wrap select:focus {
  outline: none;
  border-color: var(--green);
}

.legend {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-2);
}

.legend-swatch {
  width: 13px;
  height: 13px;
  border-radius: 4px;
  flex-shrink: 0;
}

.explorer-map-wrap {
  border: 1px solid var(--rule);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

#resultsMap {
  width: 100%;
  height: 560px;
  background: var(--paper-2);
}

.explorer-detail {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--rule);
}

.explorer-detail-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin-bottom: 1.25rem;
}

.explorer-detail-head h3 {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.detection-counts {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}

.count-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
  background: var(--paper-2);
  border: 1px solid var(--rule);
  border-radius: var(--radius-pill);
  padding: 8px 16px;
}

.count-chip .legend-swatch { width: 10px; height: 10px; }

.detection-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.detection-pill {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-3);
  background: var(--paper-2);
  border-radius: var(--radius-pill);
  padding: 5px 12px;
}

.explorer-caveat {
  font-size: 14px;
  color: var(--ink-4);
  line-height: 1.65;
  max-width: 760px;
}

@media (max-width: 768px) {
  .explorer { padding: 1.5rem 1.25rem 3.5rem; }
  .explorer-select-wrap select { min-width: 100%; }
  #resultsMap { height: 420px; }
}
