/* body {
  font-family: system-ui, sans-serif;
} */

table {
  font-size: 0.9rem;
}

#countries-container,
#climates-container {
  max-height: 300px; /* or any height you prefer */
  overflow-y: auto;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 6px 10px;
  background-color: white; /* neutral background */
}

.geo-block {
  background-color: white;
  transition: background-color 0.2s ease;
}

.continent-block {
  /* padding: 6px; */
  /* border-bottom: 1px solid #eee; */
}

.continent-block:hover {
  background-color: #f3f3f3;
}

.geo-block.disabled-block {
  opacity: 0.5;
  pointer-events: none;
}

.geo-block.active {
  background-color: #e9f0fa;
  border: 1px solid #21588f;
}

/* ========================================================================== */
/* ========================= Bootstrap Element Styling ======================= */
/* ========================================================================== */

.bg-light {
  background-color: rgb(238 145 39 / 6%) !important;
}

/* #rank-selector .btn {
  color: #333;
  border-color: #ccc;
  background-color: #f9f9f9;
  font-size: 0.8rem;
  padding: 2px 6px;
}

#rank-selector .btn:hover {
  background-color: #e9e9e9;
}

#rank-selector .btn.active {
  background-color: #ee9127;
  color: #fff;
  border-color: #ee9127;
} */

.text-primary {
  --bs-text-opacity: 1;
  color: rgb(183 112 32) !important;
}

.btn {
  color: #333;
  border-color: #ccc;
  background-color: #f9f9f9;
  font-size: 0.8rem;
  padding: 2px 6px;
}

.btn:hover {
  background-color: #e9e9e9;
  color: #333;
}

.btn.active {
  background-color: #ee9127;
  color: #fff;
  border-color: #ee9127;
}
.btn:disabled {
  background-color: #e9e9e9;
}

/* Hide default indeterminate style */
input[type="checkbox"].form-check-input:indeterminate {
  background-color: white; /* keep box white */
  border: 1px solid #ee9127; /* keep border */
  position: relative;
}

/* Draw a small blue dot in the center */
input[type="checkbox"].form-check-input:indeterminate::after {
  content: "";
  width: 4px;
  height: 4px;
  background-color: #ee9127; /* blue dot */
  border-radius: 50%;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.form-check-input:checked {
  background-color: #ee9127;
  border-color: #c3761e;
}

.tax-inner {
  transition:
    color 2.5s ease,
    transform 1.5s ease;
}

.tax-inner.tax-highlight {
  color: #ee9127; /* highlight color */
  transform: scale(1.2); /* simulate bold */
}

#export-overlay {
  display: none; /* hidden by default */
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5); /* semi-transparent black */
  z-index: 1050; /* above most elements */

  display: flex; /* ← add this */
  flex-direction: column; /* stack children vertically */
  justify-content: center; /* center vertically */
  align-items: center; /* center horizontally */

  color: white;
  font-size: 1.5rem;
  font-weight: bold;
  text-align: center;
  pointer-events: auto; /* block interactions below */
}

#export-overlay .small-text {
  font-size: 0.9rem; /* smaller than main overlay font */
  font-weight: normal; /* optional: lighter than bold */
}

#export-overlay .progress-text {
  margin-top: 0.8rem;
  font-size: 1rem;
  font-weight: bold;
}

/* Optional: spinner using Bootstrap or custom */
#export-overlay .spinner-border {
  margin-left: 10px;
  width: 1.5rem;
  height: 1.5rem;
  border-width: 0.2em;
}

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

#taxonomy-source-dropdown {
  color: rgb(183 112 32);
}

/* Spinner overlay for #run button */
#stop-run {
  color: #ff0000;
}

#run {
  position: relative; /* needed for spinner overlay */
  overflow: hidden; /* hide overflow */
}

#run .btn-spinner {
  position: absolute;
  top: 0;
  left: 0;
  width: 0%; /* start from 0 */
  height: 100%;
  background: #ee9127; /* subtle amber fill, adjust opacity */
  z-index: 1; /* behind text */
  pointer-events: none;
  animation: btn-fill 1.5s linear infinite;
}

/* Keep text always on top */
#run .btn-text {
  position: relative;
  z-index: 2;
}

/* Animate width from 0 → 100% in loop */
@keyframes btn-fill {
  0% {
    width: 0%;
  }
  50% {
    width: 100%;
  }
  100% {
    width: 0%;
  }
}

/* Info icon styling */
.info-icon {
  cursor: pointer;
  font-size: 0.9rem;
  color: #2b2b2b; /* Bootstrap secondary gray */
  user-select: none;
}
.info-icon:hover {
  color: rgb(183 112 32); /* darker on hover */
}

/* Make all popovers wider */
.popover {
  max-width: 400px; /* default 276px */
  font-size: 0.95rem; /* slightly smaller font if desired */
}

.popover-header {
  font-weight: bold; /* make text bold */
  background-color: #ee9127; /* amber background */
  color: white; /* text color */
}
