/* =========================================================
   DENTALKLINIKKEN MAP SECTION
   ========================================================= */

/* Ydre wrapper */
.map-panel {
  border: 1px solid rgba(12, 34, 92, 0.08);
  border-radius: 22px;
  box-shadow: 0 10px 28px rgba(12, 34, 92, 0.08);
  overflow: hidden;
  background-color: #ffffff;
}

.map-panel .row {
  min-height: 100%;
}

.map-panel .col-lg-7 {
  display: flex;
}

/* Venstre kolonne med map */
.map-panel-inner {
  position: relative;
  flex: 1 1 auto;
  display: flex;
  min-height: 100%;
  padding: 0;
  background-color: #ffffff;
}

.map-surface {
  width: 100%;
  flex: 1 1 auto;
  min-height: 500px;
  background: #f8fafc;
}

#dentalklinikken-map {
  width: 100%;
  height: 100%;
  min-height: 500px;
}

/* Højre kolonne */
.clinic-panel {
  background: #f8f9fa;
  border-left: 1px solid rgba(12, 34, 92, 0.06);
}

.clinic-panel-header {
  background: #ffffff;
  border-bottom: 1px solid rgba(12, 34, 92, 0.08);
  padding: 1rem;
}

/* Sticky header over kliniklisten */
.sticky-top-header {
  background: #ffffff;
  flex-shrink: 0;
  z-index: 3;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

/* Scrollområde */
.clinic-panel-body {
  padding: 1rem;
  flex: 1 1 auto;
}

#clinic-scroll-area {
  overflow-y: auto;
  height: calc(600px - 68px);
}

/* Scrollbar styling */
#clinic-scroll-area::-webkit-scrollbar {
  width: 8px;
}

#clinic-scroll-area::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 4px;
}

#clinic-scroll-area::-webkit-scrollbar-thumb:hover {
  background: #999;
}

/* Klinikliste */
#clinic-list li + li {
  margin-top: 1rem;
}

/* Klinik kort */
.clinic-card {
  transition: all 0.25s ease;
}

#clinic-list li:hover .clinic-card,
#clinic-list li:focus-within .clinic-card {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

#clinic-list li:hover .clinic-card strong,
#clinic-list li:hover .clinic-card a.text-dark,
#clinic-list li:focus-within .clinic-card strong,
#clinic-list li:focus-within .clinic-card a.text-dark {
  color: #003366 !important;
}

/* Aktiv klinik */
#clinic-list li.active-clinic .clinic-card {
  border-left: 4px solid #00a8e1;
  box-shadow: 0 10px 24px rgba(12, 34, 92, 0.10);
}

/* Telefon på én linje */
.clinic-phone {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
}

.clinic-phone i {
  margin-right: 0.4rem;
  flex-shrink: 0;
}

.clinic-phone a {
  white-space: nowrap;
}

/* Fade overlay i bunden */
.fade-overlay {
  position: sticky;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: linear-gradient(to top, rgba(248, 249, 250, 1), rgba(248, 249, 250, 0));
  pointer-events: none;
  border-bottom-left-radius: 0.25rem;
  border-bottom-right-radius: 0.25rem;
}

/* Reset button */
#reset-map {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 5;
  background-color: #ffffff;
  color: #333;
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 0.4rem 0.8rem;
  font-size: 0.85rem;
  line-height: 1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  transition: all 0.2s ease;
  cursor: pointer;
}

#reset-map i {
  margin-right: 4px;
}

#reset-map:hover,
#reset-map:focus {
  background-color: #f8f9fa;
  border-color: #999;
  outline: none;
}

/* Desktop spacing hvis du ønsker lidt luft mellem kolonnerne igen
   Fjern denne blok hvis du vil beholde helt tæt no-gutters udtryk */
@media (min-width: 992px) {
  .map-panel .col-lg-7 {
    padding-right: 0;
  }

  .map-panel .col-lg-5 {
    padding-left: 0;
  }
}

/* Responsive */
@media (max-width: 1199.98px) {
  .map-panel {
    border-radius: 20px;
  }
}

@media (max-width: 991.98px) {
  .map-panel .col-lg-7 {
    display: block;
  }

  .clinic-panel {
    border-left: 0;
    border-top: 1px solid rgba(12, 34, 92, 0.06);
  }

  .map-surface,
  #dentalklinikken-map {
    min-height: 420px;
  }
}

@media (max-width: 767.98px) {
  #dentalklinikken-map {
    min-height: 280px !important;
    height: 280px !important;
    margin-top: 1rem;
    margin-bottom: 1rem;
  }

  .row.flex-column-reverse > [class*="col-"] {
    margin-bottom: 1rem;
  }
}

/* Dark mode nuance */
@media (prefers-color-scheme: dark) {
  #reset-map {
    background-color: #2b2b2b;
    color: #f1f1f1;
    border-color: #555;
  }

  #reset-map:hover {
    background-color: #3a3a3a;
    border-color: #777;
  }
}