#the_best .the-best-container {
    max-width: var(--main-container-width);
    margin: auto;
}

#the_best td.price {
    font-style: italic;
    color: #666;
}

#the_best_controls_container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
    align-items: end;
    margin-bottom: 20px;
    padding: 20px;
    background: var(--main-panel-bgcolor);
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
}
#the_best_controls_container > *:last-child {
    grid-column: 1 / -1;
}

#the_best_controls_container > button:last-child {
    justify-self: right;
}

.the_best__item {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

#the_best_controls_container[data-packet-type="0"] .the_best_statefrom_item {
    display: none;
}

#the_best_controls_container[data-packet-type="2"] .the_best_townfrom_item {
    display: none;
}

.the_best__label {
    font-size: 13px;
    font-weight: bold;
    line-height: 1.3;
    color: #6b7280;
    letter-spacing: 0.01em;
    text-align: left;
}
.ss-main {
    border-radius: 8px;
}

.the_best__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 !important;
    padding: 6px 16px !important;
}

#the_best_controls_container.the-best-mobile {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 16px;
}
#the_best_controls_container.the-best-mobile[data-packet-type="0"] > button,
#the_best_controls_container.the-best-mobile[data-packet-type="2"] > button {
    width: 100%;
    grid-column: span 1;
}

.the-best-mobile .the_best__button {
    width: 100%;
    height: 48px;
    font-size: 16px;
}

.the-best-mobile__select.ss-main {
    min-height: 48px !important;
}

.the-best-mobile__select.ss-main .ss-values {
    font-size: 16px !important;
}

.the-best-mobile__select .ss-content {
    border-radius: 8px !important;
}

.the-best-mobile__select .ss-option {
    padding: 10px 12px !important;
    min-height: 48px !important;
    font-size: 14px !important;
}

.the-best-mobile__select .ss-search {
    padding: 10px !important;
}

.the-best-mobile__select .ss-search input {
    padding: 8px 12px !important;
    font-size: 14px !important;
}