.location-tools {
  display: grid;
  grid-template-columns: minmax(240px,1fr) auto auto;
  gap: 10px;
  width: 100%;
  margin-top: 10px;
}

.location-search {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  min-width: 0;
  border: 1px solid rgba(160,190,220,.18);
  border-radius: 14px;
  background: rgba(3,14,26,.62);
}

.location-search:focus-within { border-color: rgba(99,182,255,.55); box-shadow: 0 0 0 3px rgba(99,182,255,.10); }
.location-search input {
  min-width: 0;
  flex: 1;
  height: 48px;
  padding: 0 14px;
  border: 0;
  background: transparent;
  color: #eef6ff;
  font: inherit;
}
.location-search input::placeholder { color: #71889f; }
.location-search input:focus { outline: none; }
.location-search input:focus-visible { outline: 2px solid #9fd0ff; outline-offset: -3px; }
.location-search button {
  margin: 5px;
  padding: 0 14px;
  border: 0;
  border-radius: 10px;
  background: rgba(99,182,255,.13);
  color: #dff1ff;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
}
.location-search button:disabled { opacity: .55; cursor: progress; }

.location-results {
  position: relative;
  z-index: 1;
  flex: 1 0 100%;
  max-height: min(280px, 46vh);
  margin: 0 6px 6px;
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid rgba(160,190,220,.20);
  border-radius: 12px;
  background: rgba(6,17,30,.98);
}
.location-search .location-result {
  display: grid;
  width: 100%;
  gap: 3px;
  padding: 12px 14px;
  border: 0;
  border-bottom: 1px solid rgba(160,190,220,.08);
  background: transparent;
  color: #f4f8fd;
  text-align: left;
  cursor: pointer;
}
.location-result:last-child { border-bottom: 0; }
.location-result:hover,
.location-result:focus-visible { background: rgba(99,182,255,.09); }
.location-result strong { font-size: 13px; }
.location-result span { color: #8fa4bb; font-size: 11px; }
.location-empty { padding: 14px; color: #8fa4bb; font-size: 12px; }

.location-action {
  min-height: 48px;
  white-space: nowrap;
}
.favorite-active { border-color: rgba(255,209,120,.35); background: rgba(255,209,120,.09); color: #ffe8b7; }

.favorites-row {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
  margin-top: 10px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: thin;
}
.favorites-label {
  flex: 0 0 auto;
  color: #8fa4bb;
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.favorite-chip {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 0 11px;
  border: 1px solid rgba(160,190,220,.13);
  border-radius: 999px;
  background: rgba(255,255,255,.025);
  color: #cfe0f0;
  cursor: pointer;
  font: inherit;
  font-size: 11px;
  font-weight: 750;
}
.favorite-chip:hover { border-color: rgba(99,182,255,.38); background: rgba(99,182,255,.07); }

@media (max-width: 820px) {
  .location-tools { grid-template-columns: 1fr 1fr; }
  .location-search { grid-column: 1 / -1; }
}

@media (max-width: 520px) {
  .location-tools { grid-template-columns: 1fr; }
  .location-search { grid-column: auto; }
  .location-action { width: 100%; }
}
