/* Cost bars, notes, legend, popup and touch panel in the resort list (cost-bars.js). */

.resort-option-extra {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 8px;
}

.cost-bars {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 14px;
}

.cost-bar {
  width: 4px;
  height: 14px;
  border-radius: 1px;
  background: #cbd5e1;
}

.cost-bar.is-on {
  background: #1d4ed8;
}

.cost-bars.is-dark {
  height: 16px;
}

.cost-bars.is-dark .cost-bar {
  width: 5px;
  height: 16px;
  background: #334155;
}

.cost-bars.is-dark .cost-bar.is-on {
  background: #93c5fd;
}

.cost-note {
  font-size: 12px;
  color: #64748b;
  text-align: right;
  white-space: nowrap;
}

/* The note's full sentence for screen readers (also the row's title). */
.cost-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.ts-wrapper.resort-select .ts-dropdown .resort-option.is-unpriced {
  cursor: default;
}

.ts-wrapper.resort-select .ts-dropdown .resort-option.is-unpriced .resort-option-name {
  color: #94a3b8;
}

.ts-wrapper.resort-select .ts-dropdown .resort-option.is-unpriced .tomselect-checkbox:not(:checked) {
  border-color: #e2e8f0;
}

/* Picked, then unavailable: still checked so it can be unpicked, but greyed. */
.ts-wrapper.resort-select .ts-dropdown .resort-option.is-picked-unavailable .tomselect-checkbox:checked {
  border-color: #cbd5e1;
  background-color: #cbd5e1;
  cursor: pointer;
}

.ts-wrapper.resort-select .ts-dropdown .resort-option.is-picked-unavailable {
  cursor: pointer;
}

/* Legend under the list. */
.cost-legend {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-top: 1px solid #e2e8f0;
  font-size: 12px;
  line-height: 1.4;
  color: #475569;
}

.cost-legend .cost-bars,
.cost-legend .cost-bar {
  flex: 0 0 auto;
  height: 12px;
}

.cost-legend[hidden],
.cost-panel[hidden],
.cost-popup[hidden] {
  display: none;
}

/* Touch: details in a dark panel at the bottom of the list. */
.cost-panel {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  border-top: 1px solid #e2e8f0;
  background: #0f172a;
  color: #ffffff;
}

.cost-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.cost-panel .cost-name {
  min-width: 0;
  font-size: 14px;
  font-weight: 800;
}

.cost-panel .cost-range {
  font-size: 16px;
  font-weight: 800;
}

.cost-panel .cost-room {
  font-size: 13px;
  color: #cbd5e1;
}

/* Hover / keyboard: a popup right of the list when it fits, else below (or above) the row. */
.cost-popup {
  position: absolute;
  z-index: 40;
  width: 280px;
  box-sizing: border-box;
  padding: 14px 16px;
  border-radius: 12px;
  background: #0f172a;
  color: #ffffff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.3);
  pointer-events: none;
}

.cost-popup .cost-arrow {
  position: absolute;
  left: -6px;
  top: 14px;
  width: 12px;
  height: 12px;
  background: #0f172a;
  transform: rotate(45deg);
}

.cost-popup.is-below .cost-arrow {
  top: -6px;
}

.cost-popup.is-above .cost-arrow {
  top: auto;
  bottom: -6px;
}

.cost-popup p {
  position: relative;
  margin: 0 0 4px;
}

.cost-popup .cost-name {
  font-size: 14px;
  font-weight: 800;
}

.cost-popup .cost-range {
  font-size: 20px;
  font-weight: 800;
}

.cost-popup .cost-room {
  margin-bottom: 8px;
  font-size: 13px;
  line-height: 1.5;
  color: #cbd5e1;
}

.cost-popup .cost-level {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
}
