/** Primary styles **/
body {
  margin: 0;
  padding: 0;
}

/** Color Palette
    * Black: #000
        Blue: #53c8e9, 83,200,233
        Yellow/Green: #d4fa21 , 212,250,33
        Purple: #7e47ba, 126,71,186


        Dark Blue: #007db3,  0,125,179
        Dark Green: #4c8113, 76,129,19
        Dark Purple: #583282, 88,50,130


**/
/** Override primary Bootstrap colors. **/

:root,
[data-bs-theme='light'] {
  --bs-blue: #53c8e9;
  --bs-indigo: #7e47ba;
  --bs-purple: #7e47ba;
  --bs-yellow: #d4fa21;
  --bs-green: #4c8113;
  --bs-primary: #53c8e9;
  --bs-primary-dark: #007db3;
  --bs-primary-rgb: 83, 200, 233;

  --bs-secondary: #7e47ba;
  --bs-secondary-dark: #583282;

  --bs-secondary-rgb: 126, 71, 186;
}

.btn-primary {
  --bs-btn-color: #fff;
  --bs-btn-bg: var(--bs-primary);
  --bs-btn-border-color: var(--bs-primary);
  --bs-btn-hover-color: #fff;
  --bs-btn-hover-bg: var(--bs-primary-dark);
  --bs-btn-hover-border-color: var(--bs-primary-dark);
  --bs-btn-focus-shadow-rgb: 49, 132, 253;
  --bs-btn-active-color: #fff;
  --bs-btn-active-bg: var(--bs-primary-dark);
  --bs-btn-active-border-color: #0a53be;
  --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
  --bs-btn-disabled-color: #fff;
  --bs-btn-disabled-bg: var(--bs-primary);
  --bs-btn-disabled-border-color: var(--bs-primary);
}

.btn-secondary {
  --bs-btn-color: #fff;
  --bs-btn-bg: var(--bs-secondary);
  --bs-btn-border-color: var(--bs-secondary);
  --bs-btn-hover-color: #fff;
  --bs-btn-hover-bg: var(--bs-secondary-dark);
  --bs-btn-hover-border-color: var(--bs-secondary-dark);
  --bs-btn-focus-shadow-rgb: 130, 138, 145;
  --bs-btn-active-color: #fff;
  --bs-btn-active-bg: var(--bs-secondary-dark);
  --bs-btn-active-border-color: var(--bs-secondary-dark);
  --bs-btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125);
  --bs-btn-disabled-color: #fff;
  --bs-btn-disabled-bg: var(--bs-secondary);
  --bs-btn-disabled-border-color: var(--bs-secondary);
}

.bg-primary,
.btn-primary {
  /* background-color: rgb(51, 122, 183) !important; */
}

.border-primary {
  border-color: var(--bs-primary) !important;
}

/** Medical clearance recommendation color **/
.purple1 {
  background-color: var(--bs-purple);
}
/** Level colors **/
.level-1,
.blue {
  background-color: rgb(7, 57, 146);
}
.level-2,
.green {
  background-color: rgb(76, 129, 19);
}
.level-3,
.purple2 {
  background-color: rgb(100, 30, 118);
}
.level-4,
.black {
  background-color: rgb(0, 0, 0);
}

.program-card {
  height: 660px;
  min-height: 660px;
  max-height: 660px;
}
.program-card .card-desc {
  max-height: 210px;
  display: -webkit-box;
  -webkit-line-clamp: 7;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
/** Program directory: map and cards **/

/*
 * This page is iframed into a third-party site, where anything that overflows is clipped
 * rather than scrollable and the frame never grows. So the map has a fixed height, nothing
 * here sets a min-width, and the card grid never goes past two columns: Bootstrap's lg
 * breakpoint applies at 1024px, which is about the width of the frame.
 */
#pd-map {
  height: 420px;
  border-radius: 0.375rem;
  border: 1px solid var(--bs-border-color);
  background: #e9eef2;
}

@media (max-width: 767.98px) {
  #pd-map {
    height: 320px;
  }
}

.pd-map-controls {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 1000; /* above Leaflet's panes, below its own controls at 1000+ is fine here */
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.5rem;
}

.pd-chip {
  display: inline-block;
  background: #fff;
  border: 1px solid var(--bs-border-color);
  border-radius: 999px;
  padding: 0.2rem 0.75rem;
  font-size: 0.85rem;
}

.leaflet-container {
  font: inherit;
}

.leaflet-container a.leaflet-popup-close-button {
  color: var(--bs-secondary);
}

/* Pins are plain CSS. Leaflet's default PNG icon finds its path by inspecting the compiled
   stylesheet URL, which AssetMapper's digested file names break. */
.pd-marker {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--bs-primary-dark);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35);
}

.pd-marker-you {
  width: 18px;
  height: 18px;
  background: var(--bs-secondary);
  border-width: 3px;
}

.marker-cluster-small,
.marker-cluster-medium,
.marker-cluster-large {
  background-color: rgba(83, 200, 233, 0.4);
}

.marker-cluster-small div,
.marker-cluster-medium div,
.marker-cluster-large div {
  background-color: var(--bs-primary-dark);
  color: #fff;
  font-weight: 600;
}

.pd-popup {
  font-size: 0.9rem;
  line-height: 1.3;
}

.pd-card {
  transition: box-shadow 0.15s ease;
}

.pd-card.is-highlighted {
  box-shadow: 0 0 0 3px var(--bs-primary);
}

.pd-card-title {
  font-size: 1rem;
  line-height: 1.3;
  color: var(--bs-primary-dark);
  text-decoration: none;
  overflow-wrap: anywhere;
}

.pd-card-title:hover,
.pd-card-title:focus {
  text-decoration: underline;
}

/*
 * The title is a stretched-link, so its overlay covers the whole card and would swallow every
 * other click. Anything else clickable in a card sits above that overlay (z-index 1).
 */
.pd-card a,
.pd-card .pd-card-footer button {
  position: relative;
  z-index: 2;
}

/*
 * Long URLs and email addresses must wrap inside the card rather than push it wider.
 * break-word only splits where a word genuinely cannot fit, so "2unstoppable.org" stays whole.
 */
.pd-contact {
  overflow-wrap: break-word;
}

.pd-distance {
  color: var(--bs-secondary-dark);
  font-weight: 600;
}

.pd-card .badge {
  font-weight: 500;
}

.pd-card-footer:empty {
  display: none;
}

.pd-detail-list .pd-detail-row {
  padding: 0.5rem 0;
  border-top: 1px solid var(--bs-border-color);
}

.pd-detail-list dt {
  font-size: 0.75rem;
  letter-spacing: 0.02em;
  margin-bottom: 0.15rem;
}

.pd-detail-description {
  white-space: normal;
}

/** Upload Spread Area **/

#drop-area {
  border: 2px dashed #aaa;
  padding: 30px 20px 20px;
  text-align: center;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #f7f7f7;
  border-radius: 8px;
  min-height: 2in;
  flex-direction: column;
  gap: 10px;
  cursor: pointer;
  position: relative;
}

.drop-text {
  font-size: 18px;
  color: #888;
}

#dropped-content {
  width: calc(100% - 23px);
  height: 200px;
  min-height: 69px;
  max-height: 312px;
  margin-top: 20px;
  font-size: 16px;
  padding: 10px;
  border: 1px solid #555;
  resize: vertical;
  background-color: #444;
  color: #fff;
  outline: none;
  border-radius: 8px;
}

#dropped-content::-webkit-scrollbar {
  width: 8px;
}

#dropped-content::-webkit-scrollbar-track {
  background-color: #444;
}

#dropped-content::-webkit-scrollbar-thumb {
  background-color: #888;
  border-radius: 4px;
}

#dropped-content::-webkit-scrollbar-thumb:hover {
  background-color: #aaa;
}

.drop-icon i {
  color: #888;
  font-size: 4.5rem;
}
#drop-area .upload-control {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 9999;
  opacity: 0;
}
