.location {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    background-color: rgb(var(--color-umber));
    border-radius: 5px;
    padding: 3rem;
}

.location {
    display: flex;
    flex-direction: column
}

.location__info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
    flex: 1 1 auto;
    min-width: 0;
}

.location__tag {
    display: inline-flex;
    align-items: center;
    height: 37px;
    padding: 10px 16px;
    border: 1px solid rgb(var(--color-mist));
    border-radius: 20px;
    color: rgb(var(--color-mist));
    font-family: var(--font-brand);
    font-weight: 700;
    font-size: var(--font-size-label);
    line-height: var(--line-height-medium);
}

.location__title {
    margin: 0;
    color: rgb(var(--color-mist));
    font-family: var(--font-brand);
    font-weight: 400;
    font-size: var(--font-size-h2);
    line-height: var(--line-height-small);
}

.location__socials {
    display: flex;
    gap: 1.25rem;
}

    .location__socials a {
        color: rgb(var(--color-mist));
    }

        .location__socials a:hover {
            opacity: .7;
        }

.location__contact {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    /* the design puts a larger gap between the name block and the contact details */
    margin-top: 1.5rem;
}

.location__contact-details {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 30px;
}

.location__link {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    min-height: 44px;
    padding: 0;
    border: none;
    background: none;
    color: rgb(var(--color-mist));
    font-family: var(--font-brand);
    font-size: var(--font-size-body);
    line-height: var(--line-height-large);
    text-align: left;
    text-decoration: underline;
}

    .location__link:hover,
    .location__link:focus-visible {
        color: rgb(var(--color-mist));
        opacity: .7;
    }

    .location__link:focus-visible {
        outline: 2px solid rgb(var(--color-mist));
        outline-offset: 2px;
    }

    .location__link--mail::before,
    .location__link--phone::before {
        content: '';
        flex: 0 0 auto;
        width: 24px;
        height: 24px;
        background-color: rgb(var(--color-mist));
        mask-size: 24px 24px;
        mask-position: center;
        mask-repeat: no-repeat;
    }

    .location__link--mail::before {
        mask-image: url('/img/mail.svg');
    }

    .location__link--phone::before {
        mask-image: url('/img/phone.svg');
    }

.location__image-wrapper {
    flex: 0 0 auto;
}

.location__image {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

@media print, screen and (min-width: 768px) {
    .location {
        flex-direction: row;
        align-items: stretch;
    }

    .location__image-wrapper {
        align-self: stretch;
    }

    .location__image {
        width: auto;
        height: 100%;
    }
}
