/*
 * SESAM map control panels.
 *
 * Shared global styles for the map settings dropdown panels rendered
 * by the analyzer/editor map views. All classes already use the
 * `sesam-map-*` prefix.
 */

/* Section label shared by all panels. */
.sesam-map-control-section-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--bs-gray-600);
  margin-top: 0;
  margin-bottom: 4px;
}

.sesam-map-settings-panel {
  position: absolute;
  background: #fff;
  padding: 8px 10px;
  border-radius: 6px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  z-index: 1;
  font-size: 13px;
}

.sesam-map-settings-panel--below {
  top: 36px;
  right: 0;
}

.sesam-map-settings-panel--left {
  top: 0;
  right: calc(100% + 8px);
}

.sesam-map-settings-empty {
  opacity: 0.7;
  padding: 4px 0;
}

.sesam-map-settings-option-row {
  gap: 0.5rem;
  cursor: pointer;
  padding: 4px 0;
}

.sesam-map-settings-option-row .form-check-label {
  font-size: 13px;
  color: #8f93a3;
}

.sesam-map-settings-option-input {
  cursor: pointer;
  accent-color: #e1effe;
  position: static;
  margin: 0;
  flex: 0 0 auto;
}

.sesam-map-settings-group-spacer {
  height: 4px;
}


/* Overlap picker: compact list at the click position when several map elements lie under the click. */
.sesam-map-overlap-picker {
  position: absolute;
  z-index: 10;
  min-width: 200px;
  max-width: min(320px, calc(100% - 16px));
  background: #fff;
  border-radius: 6px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  font: 13px/1.4 "Inter", system-ui, sans-serif;
  outline: none;
  overflow: hidden;
}

.sesam-map-overlap-picker__header {
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  color: var(--bs-gray-600);
  background: var(--bs-gray-100);
  border-bottom: 1px solid var(--bs-gray-200);
}

.sesam-map-overlap-picker__list {
  max-height: min(240px, 40vh);
  margin: 0;
  padding: 0;
  list-style: none;
  overflow-y: auto;
}

/* Rows are at least 36px high so they are comfortable touch targets. */
.sesam-map-overlap-picker__row {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: 36px;
  padding: 4px 10px;
  border: 0;
  background: transparent;
  color: var(--bs-gray-700);
  text-align: left;
  cursor: pointer;
}

.sesam-map-overlap-picker__row:hover,
.sesam-map-overlap-picker__row:focus-visible {
  background: var(--bs-gray-100);
  outline: none;
}

.sesam-map-overlap-picker__icon {
  flex: 0 0 auto;
  width: 1.1em;
  text-align: center;
  color: var(--bs-gray-600);
}

.sesam-map-overlap-picker__type {
  flex: 0 0 auto;
}

.sesam-map-overlap-picker__title {
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--bs-font-monospace);
}
