.imc {
    --imc-accent: #ff6a00;
    font-size: 15px;
    color: #1d2327;
}

.imc *,
.imc *::before,
.imc *::after {
    box-sizing: border-box;
}

.imc__filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 14px;
    background: #f5f6f8;
    border-radius: 8px;
    margin-bottom: 18px;
}

.imc__filters select,
.imc__filters input {
    min-height: 40px;
    padding: 8px 10px;
    border: 1px solid #cfd4da;
    border-radius: 6px;
    font: inherit;
    background: #fff;
    flex: 1 1 140px;
    min-width: 120px;
}

.imc__apply {
    flex: 0 0 auto;
    background: var(--imc-accent);
    color: #fff;
    border: 0;
    border-radius: 6px;
    padding: 0 24px;
    min-height: 40px;
    cursor: pointer;
    font-weight: 600;
}

.imc__layout {
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 22px;
    align-items: start;
}

.imc__count {
    font-size: 14px;
    color: #5f6368;
    margin-bottom: 12px;
}

.imc__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 18px;
}

.imc-card {
    display: flex;
    flex-direction: column;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    text-decoration: none;
    color: inherit;
    transition: box-shadow 0.15s, transform 0.15s;
}

.imc-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.imc-card__img {
    aspect-ratio: 4 / 3;
    background-size: cover;
    background-position: center;
    background-color: #e9ecef;
}

.imc-card__img--empty::after {
    content: "🏠";
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    font-size: 40px;
    opacity: 0.35;
}

.imc-card__body {
    padding: 12px 14px 16px;
}

.imc-card__price {
    font-size: 18px;
    font-weight: 700;
    color: var(--imc-accent);
}

.imc-card__title {
    font-size: 15px;
    font-weight: 600;
    margin: 4px 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.imc-card__meta,
.imc-card__loc {
    font-size: 13px;
    color: #5f6368;
}

.imc-card__loc {
    margin-top: 4px;
}

.imc__map {
    position: sticky;
    top: 20px;
    height: 70vh;
    min-height: 420px;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #e5e7eb;
}

.imc__pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 22px;
}

.imc__page {
    min-width: 38px;
    height: 38px;
    border: 1px solid #cfd4da;
    background: #fff;
    border-radius: 6px;
    cursor: pointer;
}

.imc__page.is-active {
    background: var(--imc-accent);
    border-color: var(--imc-accent);
    color: #fff;
}

.imc__empty {
    color: #5f6368;
    padding: 30px 0;
}

@media (max-width: 900px) {
    .imc__layout {
        grid-template-columns: 1fr;
    }

    .imc__map {
        position: relative;
        height: 320px;
        min-height: 0;
        order: -1;
    }
}
