.eheim-fan-shop-suggestions {
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid #e5e5e5;
}

.eheim-fan-shop-suggestions.is-offcanvas {
    margin-top: 1rem;
    padding: 0.75rem 0 0;
}

.eheim-fan-shop-suggestions__headline {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.eheim-fan-shop-suggestions__list {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.eheim-fan-shop-suggestions__item {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr) auto;
    gap: 0.75rem;
    align-items: center;
    padding: 0.65rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.eheim-fan-shop-suggestions__item:last-child {
    border-bottom: 0;
}

.eheim-fan-shop-suggestions__info {
    min-width: 0;
}

.eheim-fan-shop-suggestions__image {
    width: 64px;
    height: 64px;
    object-fit: contain;
}

.eheim-fan-shop-suggestions__image-placeholder {
    width: 64px;
    height: 64px;
    background: #f5f5f5;
}

.eheim-fan-shop-suggestions__name {
    display: block;
    color: inherit;
    text-decoration: none;
    font-weight: 500;
    margin-bottom: 0.2rem;
    overflow-wrap: anywhere;
}

.eheim-fan-shop-suggestions__name:hover {
    text-decoration: underline;
}

.eheim-fan-shop-suggestions__price {
    font-size: 0.95rem;
}

.eheim-fan-shop-suggestions__action .btn {
    white-space: nowrap;
}

/* Theme sets .modal.show { min-width: 600px } which breaks mobile.
   Override only for this plugin modal. */
.modal.eheim-fan-shop-size-modal,
.modal.eheim-fan-shop-size-modal.show {
    min-width: 0 !important;
    min-height: 0 !important;
    width: 100% !important;
    max-width: 100vw !important;
    padding: 0.75rem !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
}

.modal.eheim-fan-shop-size-modal .modal-dialog {
    width: 100% !important;
    max-width: 480px !important;
    min-width: 0 !important;
    margin: 0 auto !important;
    box-sizing: border-box !important;
}

.modal.eheim-fan-shop-size-modal .modal-content {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow: hidden;
    box-sizing: border-box !important;
}

.modal.eheim-fan-shop-size-modal .modal-header,
.modal.eheim-fan-shop-size-modal .modal-body,
.modal.eheim-fan-shop-size-modal .modal-footer {
    padding-left: 1rem;
    padding-right: 1rem;
    box-sizing: border-box;
    max-width: 100%;
}

.modal.eheim-fan-shop-size-modal .modal-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-end;
    align-items: stretch;
}

.modal.eheim-fan-shop-size-modal .form-select {
    max-width: 100%;
    box-sizing: border-box;
}

.eheim-fan-shop-size-modal__error.is-hidden {
    display: none !important;
}

.eheim-fan-shop-size-modal__form {
    display: flex;
    flex: 0 1 auto;
    min-width: 0;
    margin: 0;
    max-width: 100%;
}

.eheim-fan-shop-size-modal__form .btn,
.modal.eheim-fan-shop-size-modal .modal-footer > .btn {
    white-space: normal;
    text-align: center;
    max-width: 100%;
    box-sizing: border-box;
}

@media (max-width: 575.98px) {
    .eheim-fan-shop-suggestions__item {
        grid-template-columns: 56px minmax(0, 1fr);
        grid-template-areas:
            "media info"
            "action action";
        align-items: start;
    }

    .eheim-fan-shop-suggestions__media {
        grid-area: media;
    }

    .eheim-fan-shop-suggestions__info {
        grid-area: info;
    }

    .eheim-fan-shop-suggestions__action {
        grid-area: action;
    }

    .eheim-fan-shop-suggestions__image,
    .eheim-fan-shop-suggestions__image-placeholder {
        width: 56px;
        height: 56px;
    }

    .eheim-fan-shop-suggestions__action .btn {
        width: 100%;
        white-space: normal;
    }

    .modal.eheim-fan-shop-size-modal,
    .modal.eheim-fan-shop-size-modal.show {
        padding: 0.5rem !important;
    }

    .modal.eheim-fan-shop-size-modal .modal-dialog {
        max-width: 100% !important;
    }

    .modal.eheim-fan-shop-size-modal .modal-footer {
        flex-direction: column-reverse;
        justify-content: stretch;
    }

    .modal.eheim-fan-shop-size-modal .modal-footer > .btn,
    .eheim-fan-shop-size-modal__form {
        width: 100%;
        flex: 1 1 100%;
    }

    .eheim-fan-shop-size-modal__form .btn {
        width: 100%;
    }
}
