/* ===== ВИДЖЕТ ВЫБОРА ГОРОДА ===== */
.city-widget {
    position: relative;
    width: 100%;
}

/* Поле ввода */
.city-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    border-radius: 2px;
}

.city-input {
    flex: 1;
    padding: 20px 50px 20px 20px;
    border: none;
    background: rgba(255, 255, 255, 0.6);
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 130%;
    letter-spacing: -0.02em;
    color: #252525;
    outline: none;
    min-width: 0;
    width: 100%;
    height: 64px;
    border-radius: 2px;
    transition: background 0.2s;
}

.city-input:focus {
    background: rgba(255, 255, 255, 0.8);
}

.city-input.error {
    background: rgba(145, 30, 69, 0.1);
}

.city-input::placeholder {
    color: rgba(37, 37, 37, 0.5);
}

/* Кнопка очистки */
.city-clear-btn {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    border: none;
    background: transparent;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(37, 37, 37, 0.4);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s, background 0.2s;
    padding: 0;
}

.city-clear-btn.visible {
    opacity: 1;
    visibility: visible;
}

.city-clear-btn:hover {
    background: rgba(0, 0, 0, 0.05);
    color: rgba(37, 37, 37, 0.7);
}

.city-clear-btn svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
    display: block;
}

/* Список подсказок */
.city-suggestions {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: #ffffff;
    border-radius: 2px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    max-height: 200px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
    padding: 8px 0;
}

.city-suggestions.open {
    display: block;
}

/* Стилизация скролла */
.city-suggestions::-webkit-scrollbar {
    width: 4px;
}

.city-suggestions::-webkit-scrollbar-track {
    background: transparent;
}

.city-suggestions::-webkit-scrollbar-thumb {
    background: rgba(37, 37, 37, 0.2);
    border-radius: 2px;
}

/* Элемент подсказки */
.city-suggestion-item {
    padding: 10px 20px;
    cursor: pointer;
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 130%;
    letter-spacing: -0.02em;
    color: #252525;
    transition: background 0.15s;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.city-suggestion-item:hover {
    background: rgba(0, 0, 0, 0.05);
}

.city-suggestion-item.active {
    background: rgba(0, 0, 0, 0.05);
}

.city-suggestion-item .highlight {
    font-weight: 600;
    color: #252525;
}

.city-suggestion-item .city-check {
    color: #911e45;
    font-weight: 600;
    font-size: 14px;
    opacity: 0;
    transition: opacity 0.2s;
}

.city-suggestion-item .city-check.visible {
    opacity: 1;
}

/* Сообщение об ошибке */
.city-error {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    font-size: 13px;
    line-height: 130%;
    color: #911e45;
    margin-top: 6px;
    display: none;
    align-items: center;
    gap: 4px;
}

.city-error.visible {
    display: flex;
}

/* Скрытый select */
.city-widget select {
    display: none;
}

/* ===== АДАПТИВ ===== */
@media (max-width: 960px) {
    .city-input {
        height: 5.2cqw;
        padding: 1.5cqw 4.5cqw 1.5cqw 1.5cqw;
        font-size: 1.5cqw;
    }

    .city-clear-btn {
        width: 2.5cqw;
        height: 2.5cqw;
        right: 1cqw;
    }

    .city-clear-btn svg {
        width: 1.8cqw;
        height: 1.8cqw;
    }

    .city-suggestions {
        max-height: 20cqw;
    }

    .city-suggestion-item {
        padding: 1cqw 1.5cqw;
        font-size: 1.5cqw;
    }

    .city-error {
        font-size: 1.2cqw;
    }
}

@media (max-width: 575px) {
    .city-input {
        height: 11.7cqw;
        padding: 3.7cqw 10cqw 3.7cqw 3.7cqw;
        font-size: 3.2cqw;
    }

    .city-clear-btn {
        width: 6cqw;
        height: 6cqw;
        right: 2cqw;
    }

    .city-clear-btn svg {
        width: 4cqw;
        height: 4cqw;
    }

    .city-suggestions {
        max-height: 40cqw;
        padding: 1.5cqw 0;
    }

    .city-suggestion-item {
        padding: 2.5cqw 3.7cqw;
        font-size: 3.2cqw;
    }

    .city-error {
        font-size: 2.5cqw;
        margin-top: 1.5cqw;
    }
}