.authorized-distributors-wrap * {
  box-sizing: border-box;
}
.authorized-distributors-wrap .inside {
  max-width: 1070px !important;
}
.intro-text {
    margin-bottom: 80px;
}
.intro-text p {
    line-height: 1.625;
    margin-bottom: 0 !important;
    margin-top: 0;
}
.intro-text p + p {
  margin-top: 30px;
}
.intro-text a {
    color: #1290D8 !important; /* Espressif Red */
    text-decoration: underline !important;
}

/* Filter Section */
.filter-section {
    margin-bottom: 48px;
}
.filter-label {
    font-family: var(--esp-font-family-medium);
    font-size: var(--esp-font-size-h3);
}
.filter-section-left {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 600px;
  padding: 0 25px 0 20px;
  margin-bottom: 12px;
}
#reset-filters {
  font-family: var(--esp-font-family-regular);
  display: none;
}
#reset-filters.active {
  display: block;
}
.filter-controls {
    display: flex;
    align-items: center;
    gap: 20px;
}
.filter-controls select {
    padding: 10px 20px;
    border: 1px solid #F3F4F8;
    background-color: #F3F4F8;
    border-radius: 22px;
    width: 100%;
    max-width: 600px;
    height: 44px;
    color: rgba(56, 57, 58, 1) !important;
    line-height: normal;
    outline: none;
    font-size: 16px;
}
#reset-filters {
    color: #1290D8 !important;
    text-decoration: none !important;
    cursor: pointer;
}
#reset-filters:hover {
    text-decoration: underline !important;
}
.authorized-distributors-wrap .fs-wrap {
  border: none;
  background-color: #F3F4F8;
  border-radius: 22px;
  width: 100%;
  max-width: 600px;
  height: 44px;
  color: rgba(56, 57, 58, 1) !important;
  line-height: normal;
  outline: none;
  font-size: 16px;
  margin: 0;
}
.authorized-distributors-wrap .fs-wrap .fs-label-wrap {
  border: none;
  box-shadow: none;
}
.authorized-distributors-wrap .fs-wrap .fs-label-wrap .fs-label {
  padding: 6px 20px;
  height: 100%;
  border: none !important;
}
.authorized-distributors-wrap .fs-label-wrap .fs-arrow {
    border-left: none;
    border-top: 1px solid #38393a;
    border-right: 1px solid #38393a;
    transform: rotate(135deg);
    width: 9px;
    height: 9px;
    top: -5px;
    right: 14px;
}
.authorized-distributors-wrap .fs-wrap .fs-dropdown{
    border: none;
    box-shadow: 0px 3px 10px 1px rgba(0, 0, 0, 0.16);
    border-radius: 4px;
}
.authorized-distributors-wrap .fs-wrap .fs-optgroup-label {
  padding-top: 0 !important;
  padding-bottom: 2px !important;
}

.authorized-distributors-wrap .fs-dropdown .fs-options {
    padding: 6px 0 16px 0;
    max-height: 414px;
}

.authorized-distributors-wrap .fs-wrap .fs-optgroup {
    position: relative;
    padding-top: 16px;
    padding-bottom: 6px;
}

.authorized-distributors-wrap .fs-wrap .fs-option:hover {
  background-color: #f4f4f4;
}
.authorized-distributors-wrap .fs-wrap .fs-option.selected {
  /* color: #1290D8; */
  color: #38393a;
}
.authorized-distributors-wrap  .fs-wrap .fs-optgroup:not(:first-child)::after {
    content: '';
    position: absolute;
    left: 20px;
    right: 42px;
    top: 0;
    background-color: rgba(112, 112, 112, 0.1);
    height: 2px;
    transform: scaleY(0.5);
}
.authorized-distributors-wrap  .fs-wrap .fs-optgroup:not(:first-child) {
  padding-top: 6px !important;
}
.authorized-distributors-wrap  .fs-wrap .fs-optgroup .fs-option.selected {
  color: #1290D8 !important
}
.authorized-distributors-wrap  .fs-wrap .fs-optgroup:not(:first-child) .fs-optgroup-label {
  display: none;
}
.authorized-distributors-wrap  .fs-wrap .fs-optgroup:not(:first-child) .fs-option {
  font-family: var(--esp-font-family-trueno-semibold);
}
.i18n-zh-hans .fs-wrap .fs-optgroup:not(:first-child) .fs-option,
.i18n-ja .fs-wrap .fs-optgroup:not(:first-child) .fs-option,
.i18n-zh-hans .authorized-distributors-wrap .fs-wrap .fs-optgroup-label,
.i18n-ja .authorized-distributors-wrap .fs-wrap .fs-optgroup-label {
  font-weight: bold !important;
}
.authorized-distributors-wrap  .fs-options::-webkit-scrollbar {
  width: 8px;
}
.authorized-distributors-wrap  .fs-options::-webkit-scrollbar-track {
  -webkit-border-radius: 4px;
  -moz-border-radius: 4px;
  border-radius: 4px;
  -webkit-box-shadow: none;
  background: rgba(56, 57, 58, 0.05);
}
.authorized-distributors-wrap  .fs-options::-webkit-scrollbar-thumb {
  -webkit-box-shadow: none;
  background: rgba(56, 57, 58, 0.1);
  -webkit-border-radius: 4px;
  -moz-border-radius: 4px;
  border-radius: 4px;
}

.authorized-distributors-wrap .fs-wrap .fs-optgroup-label, 
.authorized-distributors-wrap .fs-wrap .fs-option {
    padding: 6px 42px 6px 24px;
    border-bottom: none !important;
}
.authorized-distributors-wrap .fs-wrap .fs-option {
    padding-right: 24px;
    display: flex;
    align-items: center;
    margin-right: 0 !important;
    line-height: normal;
}

/* Grid - Float Fallback for older browsers (IE9+) */
.distributors-grid {
    display: flex;
    justify-content: flex-start;
    align-items: stretch;
    flex-wrap: wrap;
    margin: 0 -43px; /* Compensate for padding */
}
/* Clearfix */
.distributors-grid::after {
    content: "";
    display: table;
    clear: both;
}

/* Distributor Card */
.distributor-card {
    background: #fff;
    padding: 0 43px;
    float: left;
    width: 33.3333%;
    min-width: 33.3333%;
    max-width: 33.3333%;
    box-sizing: border-box;
    margin-bottom: 60px;
}
@media (min-width: 1100px) {
  .i18n-zh-hans .distributor-grid {
     margin: 0 -50px;
  } 
  .i18n-zh-hans .distributor-card {
    padding: 0 50px;
  }
}


.distributor-logo {
    margin-bottom: 24px;
}
.distributor-logo img {
    display: block;
    width: 200px;
    height: auto;
}
.distributor-name {
    font-family: var(--esp-font-family-trueno-regular);
    font-size: var(--esp-font-size-h3);
    margin-bottom: 8px;
}
.distributor-address {
    line-height: 1.375;
    margin-bottom: 18px;
}
.distributor-link {
    text-decoration: none !important;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    color: #38393a !important;
}
.distributor-link:hover {
  color: #1290D8 !important;
}
.distributor-link:hover span {
  text-decoration: underline !important;
}
.distributor-link::before {
    content: ""; /* Placeholder icon */
    display: block;
    background-image: url(../images/authorizedDistributors/web.svg);
    background-position: center left;
    width: 18px;
    height: 18px;
    background-repeat: no-repeat;
    background-size: contain;
    margin-right: 8px;
}
.distributor-link::after {
    content: ">";
    margin-left: 6px;
}
.distributors-grid > p > a {
  color: #1290D8 !important;
  text-decoration: underline !important;
}

@media (max-width: 1320px) {
    .intro-wrapper .inside {
      overflow: hidden;
    }
    .authorized-distributors-wrap .fs-dropdown {
      top: 0;
      transform: translateY(-100%);
    }
}
@media (max-width: 1170px) {
    .distributor-card {
        width: 33.33%;
        min-width: 33.33%;
        max-width: 33.33%;
    }
}
@media (max-width: 768px) {
  .distributors-grid {
    margin: 0 -16px; /* Compensate for padding */
  }
  .intro-text p {
    margin-top: 16px;
  }
  .intro-text p + p {
    margin-top: 22px;
  }
  .intro-text {
    margin-bottom: 50px;
  }
  .filter-section {
    margin-bottom: 32px;
  }
    .distributor-card {
        width: 50%;
        min-width: 50%;
        max-width: 50%;
        padding: 0 16px;
        margin-bottom: 40px;
    }
    .distributor-address {
      margin-bottom: 14px;
    }
    .distributor-logo img {
      width: 180px;
    }
}
@media (max-width: 576px) {
    .distributor-card {
        width: 100%;
        min-width: 100%;
        max-width: 100%;
    }
}