/* =========================================================
   FINAL COMPACT BANGKOK COURSE FINDER
   Completely separate from previous finder CSS
   ========================================================= */

.foe-bkk-finder {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto 28px;
  padding: 20px 24px 15px;
  box-sizing: border-box;

  background: #f7f8fa;
  border: 1px solid #dfe2e7;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(16, 18, 56, 0.05);
}

.foe-bkk-finder *,
.foe-bkk-finder *::before,
.foe-bkk-finder *::after {
  box-sizing: border-box;
}

/* Prevent WordPress from creating blank internal spacing */

.foe-bkk-finder p:empty,
.foe-bkk-finder br {
  display: none !important;
}

/* =========================================================
   HEADING
   ========================================================= */

.foe-bkk-finder__heading {
  width: 100%;
  margin: 0 0 13px !important;
  padding: 0 !important;
}

.foe-bkk-finder__heading h2 {
  margin: 0 !important;
  padding: 0 !important;

  color: #191b4b;
  font-family: inherit;
  font-size: clamp(26px, 2.5vw, 32px);
  font-weight: 700;
  line-height: 1.12;
  text-align: left;
}

.foe-bkk-finder__heading p {
  margin: 4px 0 0 !important;
  padding: 0 !important;

  color: #666b76;
  font-family: inherit;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.4;
  text-align: left;
}

/* =========================================================
   SEARCH AND LOCATION
   ========================================================= */

.foe-bkk-finder__controls {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(290px, 0.95fr);
  align-items: end;
  gap: 16px;

  width: 100%;
  margin: 0 !important;
  padding: 0 !important;
}

.foe-bkk-finder__field {
  display: grid;
  grid-template-rows: auto 44px;
  gap: 5px;

  min-width: 0;
  margin: 0 !important;
  padding: 0 !important;
}

.foe-bkk-finder__field label {
  display: block;
  margin: 0 !important;
  padding: 0 !important;

  color: #191b4b;
  font-family: inherit;
  font-size: 12px !important;
  font-weight: 700;
  line-height: 1.2 !important;
  text-align: left;
}

.foe-bkk-finder__field input,
.foe-bkk-finder__field select {
  appearance: auto;
  display: block;

  width: 100%;
  height: 44px !important;
  min-height: 44px !important;
  margin: 0 !important;
  padding: 0 14px !important;

  color: #272a33;
  font-family: inherit;
  font-size: 14px !important;
  font-weight: 400;
  line-height: normal !important;

  background: #ffffff;
  border: 1px solid #cfd3da;
  border-radius: 8px;
  outline: none;
  box-shadow: none;
}

.foe-bkk-finder__field input::placeholder {
  color: #3e4148;
  opacity: 1;
}

.foe-bkk-finder__field input:focus,
.foe-bkk-finder__field select:focus {
  border-color: #191b4b;
  box-shadow: 0 0 0 3px rgba(25, 27, 75, 0.08);
}

/* =========================================================
   FILTER AREA
   ========================================================= */

.foe-bkk-finder__filter-area {
  width: 100%;
  margin: 13px 0 0 !important;
  padding: 12px 0 0 !important;

  border-top: 1px solid #dde1e6;
}

.foe-bkk-finder__filters {
  display: flex !important;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;

  width: 100%;
  margin: 0 !important;
  padding: 0 !important;
}

/* =========================================================
   PILL RESET
   ========================================================= */

.foe-bkk-finder .foe-bkk-filter {
  all: unset;

  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex: 0 0 auto;

  box-sizing: border-box !important;
  width: auto;
  min-width: 0;
  height: 38px !important;
  min-height: 38px !important;

  margin: 0 !important;
  padding: 0 17px !important;

  cursor: pointer;
  background: #ffffff;
  border: 1px solid #d8dce2;
  border-radius: 999px;
  box-shadow: none;

  color: #191b4b;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
}

.foe-bkk-finder .foe-bkk-filter span {
  display: block;
  margin: 0;
  padding: 0;

  font: inherit;
  line-height: 1;
  text-align: center;

  /*
   * Poppins looks slightly high when mathematically centred.
   * One pixel produces optical vertical centring.
   */
  transform: translateY(1px);
}

.foe-bkk-finder .foe-bkk-filter:hover,
.foe-bkk-finder .foe-bkk-filter.is-active,
.foe-bkk-finder .foe-bkk-filter[aria-pressed="true"] {
  height: 38px !important;
  min-height: 38px !important;
  margin: 0 !important;
  padding: 0 17px !important;

  color: #ffffff;
  background: #191b4b;
  border-color: #191b4b;
  box-shadow: none;
}

/* All states use exactly identical dimensions */

.foe-bkk-finder .foe-bkk-filter:first-child,
.foe-bkk-finder .foe-bkk-filter:first-child:hover,
.foe-bkk-finder .foe-bkk-filter:first-child.is-active {
  align-self: center;
  position: static;
  top: auto;
  bottom: auto;
  transform: none;
  margin: 0 !important;
}

/* Keyboard focus */

.foe-bkk-finder .foe-bkk-filter:focus-visible {
  outline: 3px solid rgba(25, 27, 75, 0.18);
  outline-offset: 2px;
}

/* =========================================================
   RESULT STATUS
   ========================================================= */

.foe-bkk-finder__status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;

  width: 100%;
  min-height: 17px;
  margin: 9px 0 0 !important;
  padding: 0 !important;
}

.foe-bkk-finder__result {
  display: block;
  margin: 0 !important;
  padding: 0 !important;

  color: #666b76;
  font-family: inherit;
  font-size: 12px;
  font-weight: 400;
  line-height: 1.3;
  text-align: left;
}

.foe-bkk-finder .foe-bkk-finder__clear {
  all: unset;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  box-sizing: border-box;
  margin: 0;
  padding: 0 0 1px;

  color: #191b4b;
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;

  cursor: pointer;
  border-bottom: 1px solid currentColor;
}

.foe-bkk-finder .foe-bkk-finder__clear[hidden] {
  display: none !important;
}

/* =========================================================
   NO RESULTS
   ========================================================= */

.foe-bkk-finder__no-results {
  width: 100%;
  margin: 11px 0 0;
  padding: 11px 13px;

  background: #fffaf0;
  border: 1px solid #eadcb8;
  border-radius: 8px;
}

.foe-bkk-finder__no-results strong,
.foe-bkk-finder__no-results span {
  display: block;
}

.foe-bkk-finder__no-results strong {
  color: #191b4b;
  font-size: 13px;
}

.foe-bkk-finder__no-results span {
  margin-top: 2px;
  color: #666b76;
  font-size: 12px;
}

/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 850px) {

  .foe-bkk-finder__controls {
    grid-template-columns: 1fr;
    gap: 10px;
  }

}

/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 767px) {

  .foe-bkk-finder {
    margin-bottom: 24px;
    padding: 17px 15px 14px;
    border-radius: 12px;
  }

  .foe-bkk-finder__heading {
    margin-bottom: 11px !important;
  }

  .foe-bkk-finder__heading h2 {
    font-size: 24px;
  }

  .foe-bkk-finder__heading p {
    font-size: 13px;
  }

  .foe-bkk-finder__field {
    gap: 4px;
  }

  .foe-bkk-finder__filter-area {
    margin-top: 11px !important;
    padding-top: 10px !important;
  }

  .foe-bkk-finder__filters {
    flex-wrap: nowrap;
    width: auto;
    margin-right: -15px !important;
    padding-right: 15px !important;
    padding-bottom: 4px !important;

    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-width: none;
  }

  .foe-bkk-finder__filters::-webkit-scrollbar {
    display: none;
  }

  .foe-bkk-finder__status {
    margin-top: 7px !important;
  }

}