﻿.houses {
    position: relative;
}

.houses__list {
    --list-margin: 0;
    --list-padding: 0;
    list-style: none;
    display: flex;
    flex-direction: column;
}

.houses__header {
    margin: 45px 0;
    display: grid;
    align-items: center;
    grid-template-columns: repeat(1, 1fr);
    gap: 33px 22px;
}

.houses__splitter {
    margin: 0 0 7px;
}

.houses__headline {
    margin: 0;
    font-size: var(--heading-5-font-size);
    line-height: var(--heading-5-line-height);
    display: flex;
    justify-content: space-between;
}

.houses__toggler {
    grid-row: -1;
}

.houses__counter {
    font-weight: var(--font-weight-regular);
    font-size: 12px;
    line-height: 26px;
    white-space: nowrap;
    padding-left: 10px;
}

@media (min-width: 600px) {
    .houses {
        padding: 0 0 50px;
    }

    .houses__list {
        display: grid;
        gap: 25px;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .houses__header {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .houses__splitter {
        grid-row: 1;
        grid-column: 1 / -1;
    }

    .houses__headline {
        grid-row: 2;
    }

    .houses__toggler {
        grid-row: 2;
    }

        .houses__toggler .toggler {
            width: 250px;
        }

    .houses__counter {
        position: absolute;
        bottom: 10px;
        left: 50%;
        font-size: 17px;
        padding-left: 0;
        transform: translateX(-50%);
    }
}

@media (min-width: 1024px) {
    .houses__list {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .houses__headline {
        font-size: var(--heading-3-font-size);
        line-height: var(--heading-3-line-height);
    }
}

@media (min-width: 1350px) {
    .houses__list {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

/* House */
.house {
    margin: 0 0 var(--grid-gap);
    display: flex;
}

.house__link {
    box-shadow: 0px 3px 25px rgba(190, 190, 190, 0.15);
    border-radius: 4px 4px 0 0;
    font-size: 14px;
    line-height: 22px;
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    transition: box-shadow ease 200ms;
    color: var(--color-secondary-3);
}

    .house__link:hover {
        color: var(--color-secondary-3);
        box-shadow: 0px 3px 15px rgba(190, 190, 190, 0.5);
    }

.house__cta {
    color: var(--color-primary);
    grid-column: 1 / -1;
    font-weight: var(--font-weight-medium);
    padding-right: 25px;
    position: relative;
}

    .house__cta::after {
        content: '';
        display: block;
        position: absolute;
        right: 0;
        top: 3px;
        height: 20px;
        width: 19px;
        transform: rotate(-90deg);
        background: center / 7px auto no-repeat url('/gfx/icons/dropdown_arrow.svg'), -999em / 7px auto no-repeat url('/gfx/icons/dropdown_arrow_hover.svg');
        background-color: var(--color-skin-light);
    }

.house__link:hover .house__cta {
    color: var(--color-primary);
}

    .house__link:hover .house__cta::after {
        color: var(--color-primary);
        background-color: var(--color-primary);
        background-position: -999em, center;
    }

.house__text {
    background-color: var(--color-white);
    border: 1px solid rgba(226, 226, 226, 1);
    padding: 25px;
    flex-grow: 1;
    align-content: flex-start;
    display: grid;
    grid-template-columns: auto 30px;
    grid-template-rows: minmax(0, auto) 0fr;
    gap: 0 20px;
}

.house__name {
    --h3-font-size: 18px;
    --h3-line-height: 24px;
    color: var(--color-secondary);
    margin: 0;
    grid-column: 1;
    overflow-wrap: break-word;
    -webkit-hyphens: auto;
    hyphens: auto;
}

.house__address {
    grid-column: 1;
    grid-row: 2;
    overflow-wrap: break-word;
    -webkit-hyphens: auto;
    hyphens: auto;
    margin: 5px 0 0;
    min-height: 50px;
}

.house__logos {
    grid-column: 2;
    grid-row: 1 / span 2;
}

.house__logo {
    margin: 0 0 15px;
}

.house__image {
    margin: 0;
    height: 240px;
    object-fit: cover;
    border-radius: 4px 4px 0 0;
}

@media (min-width: 600px) {
    .house__image {
        height: 245px;
    }
}

@media (min-width: 900px) {
    .house__image {
        height: 230px;
    }
}

.house__specs {
    --list-margin: 0;
    --list-padding: 0;
    --paragraph-spacing: 25px;
    grid-column: 1 / -1;
    list-style: none;
    border-top: 1px solid rgb(234, 234, 234);
}

.house__specs-item {
    border-bottom: 1px solid rgb(234, 234, 234);
    padding: 5px 0;
    display: flex;
    justify-content: space-between;
}

.house__specs-title,
.house__specs-data {
    min-width: 90px;
}

.house__specs-data {
    color: var(--color-secondary);
    text-align: right;
}
