/* Interactive destination map on /galamerki/ (pages/destination_map.php, assets/js/destination-map.js). */
.dmap {
  --dmap-ink: #0d1a2d;
  --dmap-body: #46566a;
  --dmap-muted: #75859a;
  --dmap-blue: #087da3;
  --dmap-blue-dark: #075e7a;
  --dmap-line: #dfe5e8;
  --dmap-sea: #dcecf3;
  --dmap-land: #f5f2ea;
  --dmap-border: #ffffff;
  --dmap-available: #cfe6dc;
  --dmap-available-hover: #a9d3c3;
  --dmap-ice: #edf6fa;
  margin: 4px 0 46px;
  color: var(--dmap-ink);
}
.dmap-visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Heading and key numbers */
.dmap__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px 48px;
  margin-bottom: 22px;
}
.dmap__intro { flex: 1 1 440px; max-width: 640px; }
.site-route-page .dmap h2 { margin: 0 0 8px; font-size: clamp(21px, 2.3vw, 27px); line-height: 1.15; letter-spacing: -.03em; }
.dmap__lead { margin: 0; color: var(--dmap-body); font-size: 15px; line-height: 1.6; text-wrap: pretty; }
.dmap__stats { display: flex; margin: 0 0 3px; }
.dmap__stats div {
  display: flex;
  flex-direction: column-reverse;
  justify-content: flex-end;
  gap: 3px;
  padding: 0 24px;
  border-left: 1px solid var(--dmap-line);
}
.dmap__stats div:first-child { padding-left: 0; border-left: 0; }
.dmap__stats div:last-child { padding-right: 0; }
.dmap__stats dt { color: var(--dmap-muted); font-size: 12px; line-height: 1.3; white-space: nowrap; }
.dmap__stats dd { margin: 0; font-size: 28px; font-weight: 800; line-height: 1.05; letter-spacing: -.03em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dmap__stats dd small { margin-right: 1px; color: var(--dmap-muted); font-size: 15px; font-weight: 700; letter-spacing: 0; }
.dmap__stat--price dd { color: var(--dmap-blue-dark); }

/* Filters: what and where on top, when / how much / how far below */
.dmap__filters {
  margin: 0 0 14px;
  overflow: hidden;
  border: 1px solid #dce6e9;
  border-radius: 16px;
  background: #fff;
}
.dmap__filters[hidden] { display: none; }
/* Mobile-only toggle; see the 720px breakpoint. */
.dmap__filters-toggle { display: none; }
.dmap__filters-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 20px;
  padding: 11px 14px;
}
.dmap__filters-row:first-child { background: linear-gradient(105deg, #f0f7f8 0%, #fbfcfa 74%); }
.dmap__filters-row + .dmap__filters-row { border-top: 1px solid #e6edf0; }
.dmap-filter { display: flex; align-items: center; gap: 9px; margin: 0; padding: 0; border: 0; color: var(--dmap-body); font-size: 13px; }
.dmap-filter legend { float: left; margin-right: 4px; padding: 0; font-size: 13px; }
.dmap-filter--types { gap: 6px; }
.dmap-filter select,
.dmap-filter input[type="search"] {
  min-height: 38px;
  border: 1px solid #d5dfe3;
  border-radius: 10px;
  background: #fff no-repeat;
  color: var(--dmap-ink);
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  transition: border-color .16s ease, box-shadow .16s ease;
}
.dmap-filter select {
  padding: 0 34px 0 12px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5l3 3 3-3' fill='none' stroke='%2346566a' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-position: right 11px center;
  background-size: 12px;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
}
.dmap-filter input[type="search"] {
  padding: 0 12px 0 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='7' cy='7' r='4.5' fill='none' stroke='%2375859a' stroke-width='1.6'/%3E%3Cpath d='M10.5 10.5L14 14' stroke='%2375859a' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E");
  background-position: left 12px center;
  background-size: 15px;
  font-weight: 500;
}
.dmap-filter input[type="search"]::placeholder { color: var(--dmap-muted); }
.dmap-filter select:hover, .dmap-filter input[type="search"]:hover { border-color: #b4c5cd; }
.dmap-filter select:focus-visible, .dmap-filter input[type="search"]:focus-visible { border-color: var(--dmap-blue); outline: none; box-shadow: 0 0 0 3px rgba(8, 125, 163, .2); }
.dmap-filter--search { flex: 1 1 180px; max-width: 260px; margin-left: auto; }
.dmap-filter--search input { width: 100%; }
.dmap-filter--budget output { min-width: 6.4em; color: var(--dmap-ink); font-weight: 700; font-variant-numeric: tabular-nums; }
.dmap-filter--budget input {
  --fill: 100%;
  width: 130px;
  height: 22px;
  margin: 0;
  background: transparent;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
}
.dmap-filter--budget input:focus-visible { outline: none; }
.dmap-filter--budget input::-webkit-slider-runnable-track { height: 4px; border-radius: 4px; background: linear-gradient(to right, var(--dmap-blue) var(--fill), #d5dfe3 var(--fill)); }
.dmap-filter--budget input::-webkit-slider-thumb {
  width: 18px; height: 18px;
  margin-top: -7px;
  border: 2px solid var(--dmap-blue);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 3px rgba(13, 26, 45, .25);
  -webkit-appearance: none;
  transition: box-shadow .16s ease;
}
.dmap-filter--budget input:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 4px rgba(8, 125, 163, .22); }
.dmap-filter--budget input::-moz-range-track { height: 4px; border-radius: 4px; background: #d5dfe3; }
.dmap-filter--budget input::-moz-range-progress { height: 4px; border-radius: 4px; background: var(--dmap-blue); }
.dmap-filter--budget input::-moz-range-thumb { width: 14px; height: 14px; border: 2px solid var(--dmap-blue); border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(13, 26, 45, .25); }
.dmap-chip { position: relative; display: inline-flex; cursor: pointer; }
.dmap-chip input { position: absolute; opacity: 0; pointer-events: none; }
.dmap-chip span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 15px 0 11px;
  border: 1px solid #d5dfe3;
  border-radius: 999px;
  background: #fff;
  color: var(--dmap-body);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  transition: background-color .16s ease, border-color .16s ease, color .16s ease;
}
.dmap-chip span::before {
  content: "";
  flex: none;
  box-sizing: border-box;
  width: 16px; height: 16px;
  border: 1.5px solid #b4c3ca;
  border-radius: 5px;
  background: #fff center / 12px no-repeat;
  transition: background-color .16s ease, border-color .16s ease;
}
.dmap-chip:hover span { border-color: #b4c5cd; color: var(--dmap-ink); }
.dmap-chip input:checked + span { border-color: rgba(8, 125, 163, .4); background: #e8f4f8; color: var(--dmap-blue-dark); }
.dmap-chip input:checked + span::before {
  border-color: var(--dmap-blue);
  background-color: var(--dmap-blue);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2.5 6.2l2.3 2.3 4.7-5' fill='none' stroke='%23fff' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.dmap-chip input:focus-visible + span { outline: 3px solid rgba(8, 125, 163, .3); outline-offset: 2px; }
.dmap-chip--warm input:checked + span { border-color: rgba(233, 138, 43, .5); background: #fdf0e1; color: #9a4a14; }
.dmap-chip--warm input:checked + span::before { border-color: #e98a2b; background-color: #e98a2b; }
.dmap-reset {
  min-height: 38px;
  margin-left: auto;
  padding: 0 4px;
  border: 0;
  background: none;
  color: var(--dmap-blue);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.dmap-reset:hover { color: var(--dmap-blue-dark); text-decoration: underline; text-underline-offset: 3px; }

/* Map and side panel */
.dmap__layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 14px;
  align-items: start;
}
.dmap__stage { position: relative; min-width: 0; }
.dmap__viewport {
  position: relative;
  width: 100%;
  overflow: hidden;
  border: 1px solid #d3e3ea;
  border-radius: 18px;
  background: var(--dmap-sea);
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}
.dmap.is-ready .dmap__viewport { aspect-ratio: auto !important; height: min(680px, 78vh); min-height: 460px; cursor: grab; }
.dmap.is-ready .dmap__viewport.is-dragging { cursor: grabbing; }
.dmap__viewport:focus-visible { outline: 3px solid rgba(8, 125, 163, .45); outline-offset: 2px; }
.dmap__svg { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.dmap__sea { fill: var(--dmap-sea); }
.dmap__land { fill: var(--dmap-land); stroke: var(--dmap-border); stroke-width: .7px; vector-effect: non-scaling-stroke; }
.dmap__country {
  fill: var(--dmap-available);
  stroke: var(--dmap-border);
  stroke-width: .7px;
  vector-effect: non-scaling-stroke;
  transition: fill .2s ease, opacity .2s ease;
}
.dmap.is-ready .dmap__country { cursor: pointer; }
.dmap__country.is-muted { fill: var(--dmap-land); }
.dmap__country.is-hover, .dmap__country.is-active { fill: var(--dmap-available-hover); }
/* Flight: a faint dotted guide, the route drawing itself, and a plane at its tip. */
.dmap-flight { position: absolute; left: 0; top: 0; z-index: 1; overflow: visible; pointer-events: none; }
.dmap-flight__trail, .dmap-flight__line { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.dmap-flight__trail { stroke: var(--dmap-blue); stroke-width: 1.5px; stroke-dasharray: 1 6; opacity: 0; transition: opacity .3s ease; }
.dmap-flight__line { stroke: var(--dmap-blue); stroke-width: 2.5px; stroke-dasharray: 7 6; filter: drop-shadow(0 1px 2px rgba(8, 125, 163, .3)); }
.dmap-flight.is-landed .dmap-flight__line { animation: dmap-route 1.2s linear infinite; }
@keyframes dmap-route { to { stroke-dashoffset: -26; } }
.dmap-flight.is-flying .dmap-flight__trail { opacity: .55; }
.dmap-flight__plane { fill: var(--dmap-ink); stroke: #fff; stroke-width: 1.4px; stroke-linejoin: round; opacity: 0; transition: opacity .25s ease; filter: drop-shadow(0 2px 3px rgba(13, 26, 45, .35)); }
.dmap-flight.is-flying .dmap-flight__plane { opacity: 1; }
.dmap-flight.is-landed .dmap-flight__plane { opacity: 0; transition-delay: .2s; }

/* Pins: before the script runs they carry a name and price; with it they are plain dots
   and the details live in the hover card. */
.dmap__pins { position: absolute; inset: 0; pointer-events: none; }
.dmap-pin, .dmap-riga, .dmap-cluster {
  position: absolute;
  width: 0;
  height: 0;
  pointer-events: auto;
}
.dmap.is-ready .dmap-pin, .dmap.is-ready .dmap-riga, .dmap.is-ready .dmap-cluster { left: 0 !important; top: 0 !important; will-change: transform; }
.dmap-pin { --size: 12px; z-index: 2; color: var(--dmap-ink); text-decoration: none; }
.dmap-pin[hidden], .dmap-cluster[hidden] { display: none; }
.dmap-pin__dot {
  position: absolute;
  left: calc(var(--size) / -2); top: calc(var(--size) / -2);
  width: var(--size); height: var(--size);
  border: 2px solid #fff;
  border-radius: 50%;
  background: var(--dot, var(--dmap-blue));
  box-shadow: 0 1px 3px rgba(13, 26, 45, .35);
  transition: transform .18s cubic-bezier(.2, .8, .3, 1.4), box-shadow .18s ease;
}
.dmap-pin__dot::before { content: ""; position: absolute; inset: -9px; border-radius: 50%; }
.dmap-pin__dot::after {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: 50%;
  border: 2px solid var(--dot, var(--dmap-blue));
  opacity: 0;
}
.dmap-pin.is-hover, .dmap-pin:focus-visible { z-index: 6; }
.dmap-pin.is-hover .dmap-pin__dot, .dmap-pin:focus-visible .dmap-pin__dot { transform: scale(1.45); box-shadow: 0 2px 8px rgba(13, 26, 45, .35); }
.dmap-pin.is-hover .dmap-pin__dot::after { animation: dmap-ripple 1.4s ease-out infinite; }
@keyframes dmap-ripple { from { opacity: .7; transform: scale(1); } to { opacity: 0; transform: scale(2.6); } }
.dmap-pin:focus-visible { outline: none; }
.dmap-pin:focus-visible .dmap-pin__dot { outline: 3px solid rgba(8, 125, 163, .5); outline-offset: 3px; }
.dmap-pin__label {
  position: absolute;
  left: 0;
  bottom: calc(var(--size) / 2 + 4px);
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(13, 26, 45, .16), 0 0 0 1px rgba(13, 26, 45, .06);
  font-size: 12px;
  line-height: 1.15;
  white-space: nowrap;
  transform: translateX(-50%);
}
.dmap-pin__name { font-weight: 700; }
.dmap-pin__price { color: var(--dmap-blue-dark); font-weight: 800; font-variant-numeric: tabular-nums; }
.dmap-pin__temp { color: var(--dmap-muted); font-weight: 700; font-variant-numeric: tabular-nums; }
.dmap.is-ready .dmap-pin__label { display: none; }
.dmap-pin.is-selected { z-index: 7; }
.dmap.is-ready .dmap-pin.is-selected .dmap-pin__label { display: flex; background: var(--dmap-ink); color: #fff; }
.dmap-pin.is-selected .dmap-pin__price, .dmap-pin.is-selected .dmap-pin__temp { display: none; }
.dmap-pin.is-selected .dmap-pin__dot { transform: scale(1.3); box-shadow: 0 0 0 4px rgba(13, 26, 45, .18); }

.dmap-cluster { z-index: 3; }
.dmap-cluster button {
  position: absolute;
  left: 0; top: 0;
  display: grid;
  place-items: center;
  min-width: 26px; height: 26px;
  padding: 0 6px;
  border: 2px solid #fff;
  border-radius: 999px;
  background: var(--dmap-ink);
  color: #fff;
  box-shadow: 0 2px 8px rgba(13, 26, 45, .3);
  font-size: 12px;
  font-weight: 800;
  transform: translate(-50%, -50%);
  cursor: pointer;
  transition: transform .18s cubic-bezier(.2, .8, .3, 1.4), background-color .15s ease;
}
.dmap-cluster button:hover { background: var(--dmap-blue-dark); transform: translate(-50%, -50%) scale(1.15); }
.dmap-cluster button:focus-visible { outline: 3px solid rgba(8, 125, 163, .45); outline-offset: 2px; }

/* Hover card */
.dmap-card {
  position: absolute;
  left: 0; top: 0;
  z-index: 9;
  width: 272px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 10px 30px rgba(13, 26, 45, .22), 0 0 0 1px rgba(13, 26, 45, .06);
  color: var(--dmap-ink);
  font-size: 13px;
  pointer-events: none;
  opacity: 0;
  margin-top: 6px;
  transition: opacity .16s ease, margin-top .16s ease;
}
.dmap-card.is-below { margin-top: -6px; }
.dmap-card.is-visible { opacity: 1; margin-top: 0; }
.dmap-card[hidden] { display: none; }
.dmap-card__head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.dmap-card__head strong { font-size: 16px; letter-spacing: -.01em; }
.dmap-card__head span { color: var(--dmap-muted); font-size: 12px; white-space: nowrap; }
.dmap-card__price { display: flex; align-items: baseline; gap: 8px; margin: 3px 0 8px; }
.dmap-card__price b { color: var(--dmap-blue-dark); font-size: 18px; font-weight: 800; font-variant-numeric: tabular-nums; }
.dmap-card__price span { color: var(--dmap-muted); font-size: 12px; }
.dmap-card__facts { display: flex; flex-wrap: wrap; gap: 4px 12px; margin: 0 0 8px; padding: 0; list-style: none; font-weight: 700; font-variant-numeric: tabular-nums; }
.dmap-card__facts span { margin-right: 4px; }
.dmap-card__facts small { color: var(--dmap-muted); font-weight: 600; }
.dmap-card__season { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 0 0 9px; }
.dmap-card__season small { color: var(--dmap-body); font-size: 12px; }
.dmap-season { padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 800; letter-spacing: .02em; }
.dmap-season--best { background: #dff1e6; color: #1d6a3e; }
.dmap-season--ok { background: #e8f2f6; color: #23607a; }
.dmap-season--hot { background: #fde4d6; color: #a2421a; }
.dmap-season--rainy { background: #e3e8f6; color: #34488c; }
.dmap-season--cool, .dmap-season--cold { background: #e7eef5; color: #3f5872; }
.dmap-costs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; margin: 0; padding: 0; list-style: none; }
.dmap-costs li { display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 6px 2px; border-radius: 9px; background: var(--dmap-ice); text-align: center; }
.dmap-costs span { font-size: 15px; line-height: 1.1; }
.dmap-costs small { color: var(--dmap-muted); font-size: 10px; line-height: 1.2; }
.dmap-costs b { font-size: 12px; font-variant-numeric: tabular-nums; }
.dmap-card__level { margin: 6px 0 0; color: var(--dmap-body); font-size: 12px; }
/* Touch: the card is pinned to the tapped dot, grows out of it and opens the details. */
.dmap-card.is-pinned {
  max-width: calc(100% - 16px);
  margin-top: 0;
  box-sizing: border-box;
  pointer-events: auto;
  cursor: pointer;
  scale: .88;
  transition: opacity .18s ease, scale .32s cubic-bezier(.2, .9, .3, 1.15);
}
.dmap-card.is-pinned.is-visible { scale: 1; }
.dmap-card.is-pinned.is-away { visibility: hidden; }
.dmap-card.is-pinned .dmap-card__head { padding-right: 30px; }
.dmap-card[data-side]::after {
  content: "";
  position: absolute;
  width: 12px; height: 12px;
  border-radius: 2px;
  background: inherit;
  transform: rotate(45deg);
}
.dmap-card[data-side="below"]::after { top: -5px; left: calc(var(--tail) - 6px); }
.dmap-card[data-side="above"]::after { bottom: -5px; left: calc(var(--tail) - 6px); }
.dmap-card[data-side="right"]::after { left: -5px; top: calc(var(--tail) - 6px); }
.dmap-card[data-side="left"]::after { right: -5px; top: calc(var(--tail) - 6px); }
.dmap-card__close {
  position: absolute;
  top: 6px; right: 6px;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 32px; height: 32px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  color: var(--dmap-muted);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.dmap-card__close:active { background: var(--dmap-ice); color: var(--dmap-ink); }
.dmap-card__more {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  border: 0;
  border-radius: 10px;
  background: var(--dmap-blue);
  color: #fff;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: background-color .15s ease, transform .12s ease;
}
.dmap-card__more span { font-size: 16px; line-height: 1; }
.dmap-card__more:active { background: var(--dmap-blue-dark); transform: scale(.98); }
.dmap-card__more:focus-visible, .dmap-card__close:focus-visible { outline: 3px solid rgba(8, 125, 163, .4); outline-offset: 2px; }
.dmap-card.is-pinned .dmap-card__season { margin-bottom: 10px; }
/* The card names the destination, so its dark label would only cover the map. */
.dmap.has-pinned-card .dmap-pin.is-selected .dmap-pin__label { display: none !important; }

.dmap-riga { z-index: 4; pointer-events: none; }
.dmap-riga__dot {
  position: absolute;
  left: -7px; top: -7px;
  width: 14px; height: 14px;
  border: 3px solid #fff;
  border-radius: 50%;
  background: var(--dmap-ink);
  box-shadow: 0 0 0 0 rgba(13, 26, 45, .35);
  animation: dmap-pulse 2.4s ease-out infinite;
}
.dmap-riga__label {
  position: absolute;
  left: 11px; top: -9px;
  color: var(--dmap-ink);
  font-size: 12px;
  font-weight: 800;
  text-shadow: 0 0 3px #fff, 0 0 3px #fff, 0 0 3px #fff;
  white-space: nowrap;
}
@keyframes dmap-pulse { 70% { box-shadow: 0 0 0 12px rgba(13, 26, 45, 0); } 100% { box-shadow: 0 0 0 0 rgba(13, 26, 45, 0); } }

/* Toolbar, legend and hint on top of the map */
.dmap__toolbar {
  position: absolute;
  top: 10px; left: 10px; right: 10px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  pointer-events: none;
}
.dmap__toolbar[hidden] { display: none; }
.dmap__regions, .dmap__zoom {
  display: flex;
  gap: 1px;
  padding: 2px;
  border-radius: 9px;
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 2px 10px rgba(13, 26, 45, .12);
  pointer-events: auto;
}
.dmap__regions { align-self: flex-start; overflow-x: auto; scrollbar-width: none; }
.dmap__regions::-webkit-scrollbar { display: none; }
.dmap__regions button, .dmap__zoom button {
  min-height: 24px;
  padding: 2px 8px;
  border: 0;
  border-radius: 7px;
  background: none;
  color: var(--dmap-body);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
}
.dmap__zoom { flex-direction: column; align-self: flex-start; }
.dmap__zoom button { width: 26px; padding: 0; font-size: 16px; line-height: 1; }
.dmap__regions button:hover, .dmap__zoom button:hover { background: var(--dmap-ice); color: var(--dmap-ink); }
.dmap__regions button[aria-pressed="true"] { background: var(--dmap-ink); color: #fff; }
.dmap__regions button:focus-visible, .dmap__zoom button:focus-visible { outline: 3px solid rgba(8, 125, 163, .4); outline-offset: 1px; }
.dmap__legend {
  position: absolute;
  left: 10px; bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  max-width: calc(100% - 20px);
  padding: 4px 8px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 2px 10px rgba(13, 26, 45, .12);
  color: var(--dmap-body);
  font-size: 11px;
  pointer-events: none;
}
.dmap__legend[hidden] { display: none; }
.dmap-legend__scale { display: flex; overflow: hidden; border-radius: 4px; }
.dmap-legend__scale span { padding: 1px 4px; color: #fff; font-size: 10px; font-weight: 700; font-variant-numeric: tabular-nums; }
.dmap__hint {
  position: absolute;
  right: 12px; bottom: 12px;
  margin: 0;
  padding: 6px 10px;
  border-radius: 10px;
  background: rgba(13, 26, 45, .82);
  color: #fff;
  font-size: 12px;
  pointer-events: none;
  transition: opacity .25s ease;
}
.dmap__hint[hidden] { display: none; }
.dmap__empty {
  position: absolute;
  left: 50%; top: 50%;
  max-width: 320px;
  margin: 0;
  padding: 14px 18px;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 6px 24px rgba(13, 26, 45, .18);
  text-align: center;
  transform: translate(-50%, -50%);
}
.dmap__empty button { margin-top: 8px; border: 0; background: none; color: var(--dmap-blue); font-weight: 700; cursor: pointer; }

/* Side panel: suggestions or one destination */
.dmap__panel {
  position: relative;
  max-height: max(460px, min(680px, 78vh));
  overflow-y: auto;
  border: 1px solid var(--dmap-line);
  border-radius: 18px;
  background: #fff;
  overscroll-behavior: contain;
}
.dmap__panel[hidden] { display: none; }
.dmap-panel__section { padding: 16px 18px; border-top: 1px solid #edf1f3; }
.dmap-panel__section:first-child { border-top: 0; }
.dmap-panel__section h3, .dmap-panel__section h4 { margin: 0 0 10px; font-size: 15px; letter-spacing: -.01em; }
.dmap-panel__section h4 { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; font-size: 14px; }
.dmap-panel__section h4 small { color: var(--dmap-muted); font-size: 12px; font-weight: 600; }
.dmap-panel__intro { margin: 0; color: var(--dmap-body); font-size: 13px; line-height: 1.55; }
.dmap-picks { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.dmap-picks button {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 10px;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-radius: 10px;
  background: none;
  color: var(--dmap-ink);
  font-size: 13px;
  text-align: left;
  cursor: pointer;
}
.dmap-picks button:hover, .dmap-picks button:focus-visible { background: var(--dmap-ice); outline: none; }
.dmap-picks strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dmap-picks small { grid-column: 1; color: var(--dmap-muted); font-size: 12px; }
.dmap-picks em { grid-row: 1 / span 2; grid-column: 2; align-self: center; color: var(--dmap-blue-dark); font-style: normal; font-weight: 800; font-variant-numeric: tabular-nums; }

.dmap-detail__media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; border-radius: 17px 17px 0 0; background: var(--dmap-ice); }
.dmap-detail__media img { display: block; width: 100%; height: 100%; object-fit: cover; }
.dmap-detail__media small { position: absolute; right: 8px; bottom: 6px; color: rgba(255, 255, 255, .85); font-size: 10px; text-shadow: 0 1px 2px rgba(0, 0, 0, .6); }
.dmap-detail__close {
  position: absolute;
  top: 10px; right: 10px;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .94);
  color: var(--dmap-ink);
  box-shadow: 0 2px 8px rgba(13, 26, 45, .2);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.dmap-detail__close:focus-visible { outline: 3px solid rgba(8, 125, 163, .45); outline-offset: 2px; }
.dmap-detail__bar { display: none; }
.dmap-detail__head { position: relative; padding: 16px 18px 6px; }
.dmap-detail__head h3 { margin: 0; font-size: 22px; letter-spacing: -.025em; }
.dmap-detail__head p { margin: 3px 0 0; color: var(--dmap-muted); font-size: 13px; }
.dmap-detail__head:only-child { padding-right: 56px; }
.dmap-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin: 0; padding: 10px 18px 16px; }
.dmap-facts div { padding: 8px 9px; border-radius: 10px; background: var(--dmap-ice); }
.dmap-facts dt { color: var(--dmap-muted); font-size: 11px; line-height: 1.3; }
.dmap-facts dd { margin: 2px 0 0; font-size: 14px; font-weight: 800; font-variant-numeric: tabular-nums; }
.dmap-now { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; color: var(--dmap-body); font-size: 13px; }
.dmap-now strong { color: var(--dmap-ink); font-size: 20px; letter-spacing: -.02em; }
.dmap-now__icon { font-size: 26px; line-height: 1; }
.dmap-now__days { display: flex; gap: 6px; width: 100%; margin: 4px 0 0; padding: 0; list-style: none; }
.dmap-now__days li { flex: 1; padding: 6px 4px; border-radius: 10px; background: var(--dmap-ice); font-size: 12px; text-align: center; }
.dmap-now__days b { display: block; font-size: 17px; font-weight: 400; }
.dmap-now__days span { font-weight: 700; font-variant-numeric: tabular-nums; }
.dmap-now__loading { color: var(--dmap-muted); font-size: 13px; }

.dmap-climate { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 3px; align-items: end; height: 132px; margin: 4px 0 6px; padding: 0; list-style: none; }
.dmap-climate li { position: relative; display: flex; flex-direction: column; justify-content: flex-end; height: 100%; }
.dmap-climate button {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  color: var(--dmap-muted);
  font-size: 10px;
  cursor: pointer;
}
.dmap-climate__bar { width: 100%; min-height: 4px; border-radius: 5px 5px 2px 2px; background: var(--bar, #9ccfdc); }
.dmap-climate__value { margin-bottom: 2px; color: var(--dmap-ink); font-size: 10px; font-weight: 700; font-variant-numeric: tabular-nums; }
.dmap-climate__sea { position: absolute; left: 50%; width: 7px; height: 7px; border: 1.5px solid #fff; border-radius: 50%; background: var(--dmap-blue); transform: translate(-50%, 50%); }
.dmap-climate__month { margin-top: 3px; text-transform: uppercase; }
.dmap-climate button.is-current .dmap-climate__month { color: var(--dmap-ink); font-weight: 800; }
.dmap-climate button.is-current .dmap-climate__bar { box-shadow: 0 0 0 2px var(--dmap-ink); }
.dmap-climate button:focus-visible { outline: 2px solid var(--dmap-blue); outline-offset: 1px; border-radius: 4px; }
.dmap-climate-note { display: flex; flex-wrap: wrap; gap: 4px 12px; margin: 0; color: var(--dmap-body); font-size: 12px; }
.dmap-climate-note i { display: inline-block; width: 8px; height: 8px; margin-right: 4px; border-radius: 50%; background: var(--dmap-blue); vertical-align: 0; }
.dmap-climate-month { margin: 0 0 8px; color: var(--dmap-body); font-size: 13px; line-height: 1.5; }
.dmap-climate-month strong { color: var(--dmap-ink); }
.dmap-best { margin: 8px 0 0; padding: 8px 10px; border-radius: 10px; background: #fff7df; color: #6b5310; font-size: 12px; line-height: 1.45; }

.dmap-trips { display: grid; gap: 2px; margin: 0 0 6px; padding: 0; list-style: none; }
.dmap-trips a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1px 10px;
  padding: 7px 8px;
  margin: 0 -8px;
  border-radius: 10px;
  color: var(--dmap-ink);
  font-size: 13px;
  text-decoration: none;
}
.dmap-trips a:hover, .dmap-trips a:focus-visible { background: var(--dmap-ice); outline: none; }
.dmap-trips span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dmap-trips small { grid-column: 1; color: var(--dmap-muted); font-size: 12px; }
.dmap-trips em { grid-row: 1 / span 2; grid-column: 2; align-self: center; color: var(--dmap-blue-dark); font-style: normal; font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.dmap-more { color: var(--dmap-blue); font-size: 13px; font-weight: 700; text-decoration: none; }
.dmap-more:hover { text-decoration: underline; }
.dmap-months { display: flex; flex-wrap: wrap; gap: 4px; margin: 0; padding: 0; list-style: none; }
.dmap-months li { padding: 3px 7px; border-radius: 6px; background: #f1f3f4; color: #a3adb7; font-size: 11px; font-weight: 700; text-transform: uppercase; }
.dmap-months li.is-on { background: #dff1ea; color: #1d6a4c; }
.dmap-months li.is-chosen { background: var(--dmap-ink); color: #fff; }
.dmap-actions { display: grid; gap: 8px; }
.dmap-button {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 10px 16px;
  border: 1px solid var(--dmap-blue);
  border-radius: 10px;
  background: var(--dmap-blue);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
}
.dmap-button:hover { border-color: var(--dmap-blue-dark); background: var(--dmap-blue-dark); }
.dmap-button--ghost { background: #fff; color: var(--dmap-blue); }
.dmap-button--ghost:hover { background: var(--dmap-ice); color: var(--dmap-blue-dark); }
.dmap-button--map { display: none; }

/* Sortable list under the map */
.dmap__list { margin-top: 22px; }
.site-route-page .dmap__list h3 { margin: 0 0 10px; font-size: 18px; }
.dmap-static-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 6px 14px; margin: 0; padding: 0; list-style: none; }
.dmap-static-list a { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0; border-bottom: 1px solid #eef1f2; color: var(--dmap-ink); text-decoration: none; }
.dmap-static-list span { color: var(--dmap-blue-dark); font-weight: 700; }
.dmap-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.dmap-table th { padding: 0 8px 8px; border-bottom: 1px solid var(--dmap-line); color: var(--dmap-muted); font-size: 12px; font-weight: 600; text-align: left; white-space: nowrap; }
.dmap-table th.is-num, .dmap-table td.is-num { text-align: right; font-variant-numeric: tabular-nums; }
.dmap-table th button { padding: 0; border: 0; background: none; color: inherit; font: inherit; cursor: pointer; }
.dmap-table th button:hover { color: var(--dmap-ink); }
.dmap-table th[aria-sort] button { color: var(--dmap-ink); font-weight: 800; }
.dmap-table th[aria-sort="ascending"] button::after { content: " ↑"; }
.dmap-table th[aria-sort="descending"] button::after { content: " ↓"; }
.dmap-table td { padding: 9px 8px; border-bottom: 1px solid #eef1f2; vertical-align: middle; }
.dmap-table tbody tr { cursor: pointer; }
.dmap-table tbody tr:hover, .dmap-table tbody tr.is-selected { background: var(--dmap-ice); }
.dmap-table td:first-child button { padding: 0; border: 0; background: none; color: var(--dmap-ink); font: inherit; font-weight: 700; text-align: left; cursor: pointer; }
.dmap-table td:first-child small { display: block; color: var(--dmap-muted); font-size: 12px; font-weight: 400; }
.dmap-table .dmap-price { color: var(--dmap-blue-dark); font-weight: 800; }
.dmap-types { display: flex; gap: 4px; }
.dmap-types span { padding: 2px 6px; border-radius: 6px; background: #eef1f2; color: var(--dmap-body); font-size: 11px; font-weight: 700; white-space: nowrap; }
.dmap-temp { display: inline-flex; align-items: center; gap: 5px; }
.dmap-temp::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--dot, #c5ced6); }
.dmap__sources { margin: 14px 0 0; color: var(--dmap-muted); font-size: 12px; line-height: 1.55; }

@media (max-width: 1080px) {
  .dmap__layout { grid-template-columns: minmax(0, 1fr); }
  /* No inner scrolling below the map, so the back bar can stick to the screen while reading. */
  .dmap__panel { max-height: none; overflow: visible; }
  .dmap-button--map { display: flex; }
  .dmap-detail__close { display: none; }
  .dmap-detail__bar {
    position: sticky;
    top: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 6px 6px 6px 8px;
    border-bottom: 1px solid var(--dmap-line);
    border-radius: 17px 17px 0 0;
    background: rgba(255, 255, 255, .96);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
  }
  .dmap-detail__bar button {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 40px;
    padding: 0 10px;
    border: 0;
    border-radius: 10px;
    background: none;
    color: var(--dmap-blue);
    font: inherit;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
  }
  .dmap-detail__bar button[data-dmap-close] { justify-content: center; width: 40px; padding: 0; color: var(--dmap-muted); font-size: 22px; font-weight: 400; }
  .dmap-detail__bar button:active { background: var(--dmap-ice); }
  .dmap-detail__bar button:focus-visible { outline: 3px solid rgba(8, 125, 163, .4); outline-offset: 1px; }
  .dmap-detail__bar ~ .dmap-detail__media { border-radius: 0; }
}
@media (max-width: 720px) {
  .dmap__head { gap: 18px; margin-bottom: 18px; }
  .dmap__intro { flex-basis: 100%; }
  .dmap__lead { font-size: 14px; }
  .dmap__stats { width: 100%; margin: 0; }
  .dmap__stats div { flex: 1; min-width: 0; padding: 0 12px; }
  .dmap__stats dt { font-size: 11px; white-space: normal; }
  .dmap__stats dd { font-size: 22px; }
  .dmap__stats dd small { font-size: 13px; }
  .dmap__filters-toggle:not([hidden]) {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    min-height: 44px;
    margin: 0 0 10px;
    padding: 0 14px;
    border: 1px solid #dce6e9;
    border-radius: 14px;
    background: linear-gradient(105deg, #f0f7f8 0%, #fbfcfa 74%);
    color: var(--dmap-ink);
    font: inherit;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  .dmap__filters-toggle::after {
    content: "";
    width: 8px;
    height: 8px;
    margin: -4px 2px 0 auto;
    border-right: 2px solid var(--dmap-blue);
    border-bottom: 2px solid var(--dmap-blue);
    transform: rotate(45deg);
    transition: transform .2s ease, margin .2s ease;
  }
  .dmap__filters-toggle[aria-expanded="true"]::after { margin-top: 4px; transform: rotate(-135deg); }
  .dmap__filters-toggle:focus-visible { outline: 3px solid rgba(8, 125, 163, .4); outline-offset: 1px; }
  .dmap__filters-count {
    min-width: 20px;
    padding: 1px 6px;
    border-radius: 10px;
    background: var(--dmap-blue);
    color: #fff;
    font-size: 12px;
    line-height: 18px;
    text-align: center;
  }
  .dmap__filters-count[hidden] { display: none; }
  .dmap.is-ready:not(.is-filters-open) .dmap__filters { display: none; }
  .dmap__filters { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px 8px; padding: 12px; }
  .dmap__filters-row { display: contents; }
  .dmap__filters-row > * { min-width: 0; }
  .dmap-filter--types {
    grid-column: 1 / -1;
    display: flex;
    min-inline-size: 0;
    margin: 0 -12px;
    padding: 0 12px 2px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .dmap-filter--types::-webkit-scrollbar { display: none; }
  .dmap-filter--types legend { display: none; }
  .dmap-filter--month, .dmap-filter--flight { order: 1; flex-direction: column; align-items: stretch; gap: 4px; font-size: 12px; }
  .dmap-filter--budget, .dmap-chip--warm, .dmap-reset { order: 2; }
  .dmap-filter--month select, .dmap-filter--flight select { width: 100%; }
  .dmap-filter--budget { grid-column: 1 / -1; justify-content: space-between; }
  .dmap-filter--budget input { flex: 1; width: auto; }
  .dmap-filter--search { grid-column: 1 / -1; max-width: none; margin-left: 0; }
  .dmap-filter--search input { width: 100%; }
  .dmap-chip--warm { grid-column: 1 / -1; }
  .dmap-chip--warm span { width: 100%; justify-content: center; }
  .dmap-reset { grid-column: 1 / -1; justify-self: center; min-height: 32px; margin-left: 0; }
  .dmap.is-ready .dmap__viewport { height: 480px; min-height: 0; border-radius: 14px; }
  .dmap__toolbar { top: 8px; left: 8px; right: 8px; }
  .dmap__legend { left: 8px; bottom: 8px; gap: 6px; padding: 5px 7px; font-size: 11px; }
  .dmap__legend > span:first-child { max-width: 92px; line-height: 1.2; }
  .dmap-legend__scale span { padding: 2px 3px; font-size: 10px; }
  .dmap__hint { display: none; }
  .dmap-table .dmap-col-types, .dmap-table .dmap-col-sea { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .dmap__filters-toggle::after { transition: none; }
  .dmap-riga__dot, .dmap-pin.is-hover .dmap-pin__dot::after, .dmap-flight.is-landed .dmap-flight__line { animation: none; }
  .dmap-pin__dot, .dmap-cluster button, .dmap-card, .dmap-card.is-pinned { transition: none; }
  .dmap-card.is-pinned { scale: 1; }
}
