/* ============================================ */
/* ГОРОДСКОЙ СЕЛЕКТОР - ИСПРАВЛЕННЫЕ СТИЛИ       */
/* ============================================ */

.city-selector {
    position: relative;
    font-family: GeologicaRoman, sans-serif;
    flex-shrink: 0;
}

.city-selector__button {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    background: #f3f4f6;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    font-size: 14px;
    color: #333;
    white-space: nowrap;
    font-weight: 500;
    font-family: GeologicaRoman, sans-serif;
    height: 40px;
}

.city-selector__button:hover {
    background: #e4e7eb;
}

.city-selector.active .city-selector__button {
    background: #1f1f1f;
    color: #fff;
}

.city-selector.active .city-selector__button-arrow path {
    stroke: #fff;
}

.city-selector__button svg {
    flex-shrink: 0;
}

.city-selector__button-text {
    text-align: left;
    max-width: 130px;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 13px;
}

.city-selector__button-arrow {
    flex-shrink: 0;
}

.city-selector.active .city-selector__button-arrow {
    transform: rotate(180deg);
}

.city-selector__dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    background: #f3f4f6;
    border-radius: 24px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.12);
    z-index: 30;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    width: 680px;
    max-height: 480px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.city-selector.active .city-selector__dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.city-selector__search {
    position: relative;
    padding: 12px 16px;
    border-bottom: 1px solid #e8e8e8;
    background: #fff;
    flex-shrink: 0;
    z-index: 3;
    border-radius: 24px 24px 0 0;
}

.city-selector__search-input {
    width: 100%;
    padding: 10px 14px 10px 38px;
    border: 1px solid #e8e8e8;
    border-radius: 12px;
    font-size: 14px;
    outline: none;
    background: #f3f4f6;
    font-family: GeologicaRoman, sans-serif;
    color: #1f1f1f;
    height: 44px;
}

.city-selector__search-input:focus {
    border-color: #42ae45;
    background: #fff;
}

.city-selector__search-icon {
    position: absolute;
    left: 28px;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
}

.city-selector__content {
    display: flex;
    flex: 1;
    min-height: 320px;
    overflow: hidden;
    background: #fff;
    border-radius: 0 0 24px 24px;
}

.city-selector__column-header {
    padding: 14px 16px 10px;
    font-size: 11px;
    font-weight: 600;
    color: #9ca3af;
    text-transform: uppercase;
    border-bottom: 1px solid #f0f0f0;
    position: sticky;
    top: 0;
    z-index: 2;
    background: inherit;
}

.city-selector__districts {
    width: 190px;
    border-right: 1px solid #f0f0f0;
    overflow-y: auto;
    flex-shrink: 0;
    background: #fafafa;
}

.city-selector__district-item {
    padding: 10px 16px;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-left: 3px solid transparent;
}

.city-selector__district-item:hover {
    background: #fff;
    color: #1f1f1f;
    border-left-color: #42ae45;
}

.city-selector__district-item.active {
    background: #f3f4f6;
    color: #1f1f1f;
    font-weight: 600;
    border-left-color: #42ae45;
}

.city-selector__oblasts {
    width: 210px;
    border-right: 1px solid #f0f0f0;
    overflow-y: auto;
    flex-shrink: 0;
    background: #fdfdfd;
}

.city-selector__oblast-item {
    padding: 10px 16px;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-left: 3px solid transparent;
}

.city-selector__oblast-item:hover {
    background: #fff;
    color: #1f1f1f;
    border-left-color: #42ae45;
}

.city-selector__oblast-item.active {
    background: #f3f4f6;
    color: #1f1f1f;
    font-weight: 600;
    border-left-color: #42ae45;
}

.city-selector__cities {
    flex: 1;
    overflow-y: auto;
    min-width: 220px;
    background: #fff;
}

.city-selector__city-item {
    display: block;
    padding: 9px 18px;
    color: #444;
    text-decoration: none;
    font-size: 14px;
    border-left: 3px solid transparent;
    cursor: pointer;
}

.city-selector__city-item:hover {
    background: #f3f4f6;
    color: #1f1f1f;
    border-left-color: #42ae45;
}

.city-selector__city-item.active {
    background: #e8f5e9;
    color: #42ae45;
    font-weight: 600;
    border-left-color: #42ae45;
}

/* БЛОК КОНТАКТОВ */
.header__contacts.actvie {
    display: flex !important;
    flex-direction: column;
    gap: 2px;
    opacity: 1 !important;
    visibility: visible !important;
    padding: 8px 12px !important;
    background-color: #f3f4f6 !important;
    border-radius: 24px !important;
    border: 10px solid #fff !important;
}

.header__contacts.actvie .header-p-wr {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header__contacts.actvie .header__tel {
    font-family: Geometria, sans-serif;
    font-size: 17px;
    font-weight: 700;
    line-height: 20px;
    color: #42ae45 !important;
    text-decoration: none;
    white-space: nowrap;
}

.header__contacts.actvie .header__phone p {
    font-size: 12px;
    font-weight: 600;
    color: #676767;
    margin: 0;
    line-height: 1.2;
}

/* МОБИЛЬНЫЕ */
@media (max-width: 768px) {
    .city-selector__dropdown {
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%) scale(0.95);
        width: 95vw;
        max-width: 450px;
        max-height: 80vh;
        border-radius: 16px;
    }
    .city-selector.active .city-selector__dropdown {
        transform: translate(-50%, -50%) scale(1);
    }
    .city-selector__content {
        flex-direction: column;
    }
    .city-selector__districts,
    .city-selector__oblasts {
        width: 100%;
        max-height: 35%;
        border-right: none;
        border-bottom: 1px solid #f0f0f0;
        overflow-x: auto;
        overflow-y: hidden;
        display: flex;
    }
    .city-selector__district-item,
    .city-selector__oblast-item {
        white-space: nowrap;
        border-left: none;
        border-bottom: 3px solid transparent;
        flex-shrink: 0;
    }
    .city-selector__district-item.active,
    .city-selector__oblast-item.active {
        border-left: none;
        border-bottom-color: #42ae45;
    }
}

@media (max-width: 576px) {
    .city-selector__button {
        padding: 4px 10px;
        height: 32px;
        border-radius: 12px;
    }
    .city-selector__button-text {
        max-width: 80px;
        font-size: 12px;
    }
}