/* Hellweg Passt dazu: Gestaltung des Vorschlagsblocks neben dem seitlichen Warenkorb (BBF Ajaxcart). */

/* Ab 1921px ist die Seite auf 1920px begrenzt, der Warenkorb sitzt dann am Seitenrand. */
:root {
    --hw-passt-rand: 0px;
    --hw-korb-zoom: 1;
}

@media (min-width: 1921px) {
    :root {
        --hw-passt-rand: calc((100vw - 1920px) / 2);
    }
}

@media (min-width: 901px) {
    /* Eigene schwebende Karte links neben dem Warenkorb, gleiche Oberkante, gleiche Rundung, nur so hoch wie ihr Inhalt. */
    html body li.cart-icon-dropdown.bbf-sc-pos-right .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) {
        top: 14px;
        bottom: auto;
        right: calc(var(--hw-passt-rand) / var(--hw-korb-zoom) + var(--bbf-sc-width, 400px) + 26px);
        zoom: var(--hw-korb-zoom);
        width: 320px;
        min-width: 0;
        max-height: calc(100vh / var(--hw-korb-zoom) - 28px);
        border: 0;
        border-radius: 16px;
        background: #fff;
        box-shadow: 0 18px 55px rgba(15, 23, 42, 0.18);
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__head {
        padding: 18px 20px 8px;
        border-bottom: 0;
        background: transparent;
        font-size: 15px;
        font-weight: 800;
        letter-spacing: 0.01em;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__count {
        display: none;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__list {
        padding: 0 10px 10px;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__card {
        grid-template-columns: 72px minmax(0, 1fr) auto;
        grid-template-areas: "media title title" "media price action";
        align-items: center;
        column-gap: 12px;
        row-gap: 6px;
        margin: 0;
        padding: 10px;
        border: 0;
        border-radius: 12px;
        background: transparent;
        box-shadow: none;
        transition: background-color 0.15s ease;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__card + .bbf-sidecart-crosssell__card {
        margin-top: 2px;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__media {
        width: 72px;
        height: 72px;
        border: 0;
        border-radius: 10px;
        background: #f4f5f7;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__img {
        width: 100%;
        height: 100%;
        mix-blend-mode: multiply;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__title {
        align-self: end;
        font-size: 13px;
        font-weight: 600;
        line-height: 1.3;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__price {
        align-self: start;
        padding-top: 5px;
        font-size: 14px;
        font-weight: 800;
        white-space: nowrap;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__btn {
        align-self: start;
        min-width: 0;
        min-height: 30px;
        padding: 5px 13px;
        font-size: 12px;
        font-weight: 700;
        white-space: nowrap;
        transition: transform 0.15s cubic-bezier(0.23, 1, 0.32, 1), background-color 0.15s ease;
    }

    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__btn:active {
        transform: scale(0.97);
    }
}

@media (min-width: 901px) and (hover: hover) and (pointer: fine) {
    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__card:hover,
    html body .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) .bbf-sidecart-crosssell__card:focus-within {
        transform: none;
        background: #f6f7f9;
        box-shadow: none;
    }
}

/* Zwischen 901 und 1180px ist neben dem Warenkorb wenig Platz, die Karte wird schmaler. */
@media (min-width: 901px) and (max-width: 1180px) {
    html body li.cart-icon-dropdown.bbf-sc-pos-right .bbf-sidecart-crosssell:not(.bbf-sidecart-crosssell--mobile) {
        width: min(320px, calc(100vw - var(--bbf-sc-width, 400px) - 52px));
    }
}

/* Groesse: Der BBF-Warenkorb hat feste kleine Schriften (11 bis 14px). Auf grossen Bildschirmen wird er samt "Passt dazu" im Ganzen vergroessert. */
@media (min-width: 1200px) and (min-height: 760px) {
    :root {
        --hw-korb-zoom: 1.12;
    }
}

@media (min-width: 901px) {
    html body li.cart-icon-dropdown.bbf-sc-pos-right:not(.bbf-sc-mode-modal) .bbf-sidebasket-container {
        zoom: var(--hw-korb-zoom);
        right: calc(var(--hw-passt-rand) / var(--hw-korb-zoom)) !important;
    }
}

/* PayPal im seitlichen Warenkorb: Zeigt PayPal nur einen Knopf (ohne "Spaeter Bezahlen"), rueckt das PayPal-Modul ihn 1,6px nach rechts. */
html body #ppc-miniCart-horizontal-container .ppc-standalone-buttons:only-child {
    padding-left: 0;
}
