/* ============================================================
   Dealer Locator exposed form – layout & label fixes
   ============================================================ */

/* Hide the distance value div in places where it should not appear */
#views-exposed-form-dealer-block-leaf-dl .description,
.path-frontpage #views-exposed-form-dealer-block-leaf-dl .form-item-distance-value,
.contact-block #views-exposed-form-dealer-block-leaf-dl .proximity-filter-summary,
.contact-block #views-exposed-form-dealer-block-leaf-dl .form-item-distance-value,
#block-categoryfooterblock .form-item-distance-value,
.proximity-filter-summary {
  display: none !important;
}

/* ----------------------------------------------------------
   Field order fix: make the inner distance fieldset a flex
   row so source_configuration (Ihr Standort) renders first,
   followed by the value input (Entfernung).
   ---------------------------------------------------------- */
#edit-distance > .fieldset-wrapper {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 16px;
}

/* Origin address (Ihr Standort) must come first */
[data-drupal-selector="edit-distance-source-configuration"] {
  order: -1;
  flex: 1;
  min-width: 200px;
}

/* Distance value input stays compact, after the address */
.form-item-distance-value {
  order: 0;
  min-width: 100px;
  flex: 0 0 auto;
}

/* Hide the Geofield-generated legend that shows "<=" operator */
#edit-distance > legend,
#edit-distance-wrapper > legend {
  display: none;
}

/* Hide the "Units: Kilometers" description below the value input */
.form-item-distance-value .description {
  display: none !important;
}