/**
 * Pływające akcje na podstronach.
 * Wartości są skopiowane z oryginalnego komponentu strony głównej.
 */
.tofaa-floating-actions {
    position: fixed;
    right: 28px;
    bottom: 28px;
    z-index: 100;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.tofaa-floating-actions .tofaa-float {
    width: 62px;
    height: 62px;
    min-width: 62px;
    min-height: 62px;
    padding: 0;
    position: relative;
    display: grid;
    place-items: center;
    border: 1px solid rgba(124,79,160,.20);
    border-radius: 50%;
    background: #B083BC;
    color: #7C4FA0;
    box-shadow: 0 9px 22px rgba(65,30,71,.18);
    cursor: pointer;
    text-decoration: none;
    appearance: none;
    transition: transform .2s ease, opacity .25s ease, visibility .25s ease;
}

.tofaa-floating-actions .tofaa-float:hover,
.tofaa-floating-actions .tofaa-float:focus-visible {
    color: #F8EAE1;
    transform: translateY(-2px);
    outline: none;
}

.tofaa-floating-actions .tofaa-float svg {
    width: 31px;
    height: 31px;
    display: block;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.tofaa-floating-actions .tofaa-floating-cart,
.tofaa-floating-actions a.tofaa-floating-cart:link,
.tofaa-floating-actions a.tofaa-floating-cart:visited,
.tofaa-floating-actions a.tofaa-floating-cart:active {
    background: #B083BC;
    color: #7C4FA0 !important;
    text-decoration: none;
}

.tofaa-floating-actions .tofaa-floating-cart:hover,
.tofaa-floating-actions .tofaa-floating-cart:focus,
.tofaa-floating-actions .tofaa-floating-cart:focus-visible {
    color: #F8EAE1 !important;
}

.tofaa-floating-actions .tofaa-floating-cart svg,
.tofaa-floating-actions .tofaa-floating-cart svg path,
.tofaa-floating-actions .tofaa-floating-cart svg circle {
    fill: none !important;
    stroke: currentColor !important;
}

.tofaa-floating-actions .tofaa-floating-cart .tofaa-cart-count {
    min-width: 21px;
    height: 21px;
    padding: 0 5px;
    position: absolute;
    top: -4px;
    right: -4px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 999px;
    background: #ABB538;
    color: #fffdfb;
    font-size: 11px;
    font-weight: 800;
    line-height: 1;
}

.tofaa-floating-actions .tofaa-cart-count[hidden] {
    display: none;
}

.tofaa-floating-actions .tofaa-back-to-top {
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
}

.tofaa-floating-actions .tofaa-back-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.tofaa-floating-actions .tofaa-back-to-top.is-visible:hover,
.tofaa-floating-actions .tofaa-back-to-top.is-visible:focus-visible {
    transform: translateY(-2px);
}

@media (max-width: 620px) {
    .tofaa-floating-actions {
        right: 14px;
        bottom: 14px;
        gap: 10px;
    }

    .tofaa-floating-actions .tofaa-float {
        width: 54px;
        height: 54px;
        min-width: 54px;
        min-height: 54px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .tofaa-floating-actions .tofaa-float {
        transition: none;
    }
}

/* ============================================================
   V2 — pływające akcje: zielone tło, czarny kontur i wyższa pozycja
   ============================================================ */

.tofaa-floating-actions {
    bottom: 58px !important;
}

.tofaa-floating-actions .tofaa-float,
.tofaa-floating-actions a.tofaa-floating-cart,
.tofaa-floating-actions a.tofaa-floating-cart:link,
.tofaa-floating-actions a.tofaa-floating-cart:visited,
.tofaa-floating-actions a.tofaa-floating-cart:active {
    border: 1px solid #171717 !important;
    background: #d1d635 !important;
    background-color: #d1d635 !important;
    color: #7C4FA0 !important;
    box-shadow: 0 10px 0 rgba(124, 79, 160, .18) !important;
    transition:
        transform .25s ease,
        box-shadow .25s ease,
        opacity .25s ease,
        visibility .25s ease !important;
}

.tofaa-floating-actions .tofaa-float:hover,
.tofaa-floating-actions .tofaa-float:focus-visible,
.tofaa-floating-actions a.tofaa-floating-cart:hover,
.tofaa-floating-actions a.tofaa-floating-cart:focus,
.tofaa-floating-actions a.tofaa-floating-cart:focus-visible {
    border-color: #171717 !important;
    background: #d1d635 !important;
    background-color: #d1d635 !important;
    color: #7C4FA0 !important;
    transform: translateY(-4px) !important;
    box-shadow: 0 14px 0 rgba(124, 79, 160, .22) !important;
    outline: none !important;
}

@media (max-width: 620px) {
    .tofaa-floating-actions {
        bottom: 44px !important;
    }
}


/* ============================================================
   V3 — wyłącznie strzałka „w górę” jak CTA katalogu
   Pływający koszyk zachowuje dotychczasowy wygląd i animację.
   ============================================================ */

.tofaa-floating-actions .tofaa-back-to-top.is-visible {
    border: 1px solid #171717 !important;
    background: #d1d635 !important;
    background-color: #d1d635 !important;
    color: #7C4FA0 !important;
    box-shadow: 0 10px 0 rgba(124, 79, 160, .18) !important;
    transform: translateY(0) !important;
    transition:
        transform .25s ease,
        box-shadow .25s ease,
        opacity .25s ease,
        visibility .25s ease !important;
}

.tofaa-floating-actions .tofaa-back-to-top.is-visible:hover,
.tofaa-floating-actions .tofaa-back-to-top.is-visible:focus-visible {
    border-color: #171717 !important;
    background: #d1d635 !important;
    background-color: #d1d635 !important;
    color: #7C4FA0 !important;
    box-shadow: 0 14px 0 rgba(124, 79, 160, .22) !important;
    transform: translateY(-4px) !important;
    outline: none !important;
}

.tofaa-floating-actions .tofaa-back-to-top.is-visible:active {
    box-shadow: 0 12px 0 rgba(124, 79, 160, .20) !important;
    transform: translateY(-2px) !important;
}


/* ============================================================
   V4 — licznik produktów na pływającym koszyku
   ============================================================ */
.tofaa-floating-actions .tofaa-floating-cart .tofaa-cart-count,
.tofaa-floating-actions a.tofaa-floating-cart .tofaa-cart-count {
    border: 1px solid #171717 !important;
    background: #d1d635 !important;
    background-color: #d1d635 !important;
    color: #7C4FA0 !important;
    box-sizing: border-box !important;
}

/* ============================================================
   V5 — pływający koszyk identyczny na wszystkich podstronach
   Jak wersja ze strony głównej: czarny cień i efekt wciskania.
   ============================================================ */
body .tofaa-floating-actions--global a.tofaa-floating-cart,
body .tofaa-floating-actions--global a.tofaa-floating-cart:link,
body .tofaa-floating-actions--global a.tofaa-floating-cart:visited {
    border: 1px solid #171717 !important;
    background: #d1d635 !important;
    background-color: #d1d635 !important;
    color: #7C4FA0 !important;
    box-shadow: 0 8px 0 #171717 !important;
    transform: translateY(0) !important;
    filter: none !important;
    transition:
        transform .18s cubic-bezier(.2, .8, .2, 1),
        box-shadow .18s cubic-bezier(.2, .8, .2, 1) !important;
}

body .tofaa-floating-actions--global a.tofaa-floating-cart:hover,
body .tofaa-floating-actions--global a.tofaa-floating-cart:focus,
body .tofaa-floating-actions--global a.tofaa-floating-cart:focus-visible {
    border-color: #171717 !important;
    background: #d1d635 !important;
    background-color: #d1d635 !important;
    color: #7C4FA0 !important;
    box-shadow: 0 2px 0 #171717 !important;
    transform: translateY(6px) !important;
    outline: none !important;
}

body .tofaa-floating-actions--global a.tofaa-floating-cart:active {
    box-shadow: 0 0 0 #171717 !important;
    transform: translateY(8px) !important;
}

body .tofaa-floating-actions--global a.tofaa-floating-cart svg,
body .tofaa-floating-actions--global a.tofaa-floating-cart svg path,
body .tofaa-floating-actions--global a.tofaa-floating-cart svg circle {
    color: #7C4FA0 !important;
    stroke: #7C4FA0 !important;
}
