/*
 * Swiftech Store - store benefits strip + site footer.
 *
 * Plain stylesheet rather than Vite: node_modules is not installed here, so
 * rebuilding the bundles for the footer would risk every other page.
 *
 * NOTE: this file is linked BEFORE the compiled Vite CSS, so overriding a
 * compiled component (the back-to-top button below) needs a doubled-class
 * selector to win the cascade.
 */

.sw-benefits,
.sw-footer {
    --f-red: var(--color-primary, #f51e46);
    --f-ink: #0f1419;
    --f-ink-2: #4a5462;
    --f-line: #e3e6ea;
    --f-dark: #101216;
    --f-dark-2: #191c21;
    --f-on-dark: #ffffff;
    --f-on-dark-2: #aab2bc;
    --f-on-dark-3: #828a95;
    --f-dark-line: rgba(255, 255, 255, 0.08);
    --f-dark-chip: rgba(255, 255, 255, 0.05);
}

.sw-benefits *,
.sw-footer *,
.sw-benefits *::before,
.sw-footer *::before,
.sw-footer *::after { box-sizing: border-box; }

/*
 * The compiled Bootstrap bundle ships `.ltr ul { padding-left: 2rem }` (and
 * its .rtl mirror) at 0-1-1, which outranks a single-class reset and shoved
 * every footer list 32px right of its heading. This guard pins ONLY the
 * list resets at doubled-class specificity (0-2-0). Layout properties
 * (display, grid-template, gap) deliberately stay on the single-class rules
 * below so the <=991px / <=767px / <=479px media-query overrides — which are
 * also single-class and gain nothing from being in a media query — still win.
 */
.sw-benefits__grid.sw-benefits__grid,
.sw-footer__social-list.sw-footer__social-list,
.sw-footer__links.sw-footer__links {
    margin: 0;
    padding: 0;
    list-style: none;
}

/*======================= Benefits strip =======================*/

.sw-benefits {
    margin-top: 34px;
    padding: 24px 0;
    background: #f6f7f9;
    border-top: 1px solid var(--f-line);
}

.sw-benefits__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sw-benefits__item {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 2px 22px;
    border-left: 1px solid var(--f-line);
}

.sw-benefits__item:first-child { border-left: 0; padding-left: 0; }

.sw-benefits__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: none;
    width: 42px;
    height: 42px;
    font-size: 22px;
    color: var(--f-red);
    background: rgba(245, 30, 70, 0.08);
    border-radius: 11px;
}

.sw-benefits__text {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 0;
}

.sw-benefits__text strong {
    font-size: 13.5px;
    font-weight: 600;
    color: var(--f-ink);
}

.sw-benefits__text span {
    font-size: 12px;
    line-height: 1.4;
    color: var(--f-ink-2);
}

/*======================= Footer shell =======================*/

.sw-footer {
    position: relative;
    padding-top: 54px;
    background: linear-gradient(180deg, #16181d 0%, var(--f-dark) 55%);
    color: var(--f-on-dark-2);
}

/* Thin brand accent along the footer's top edge. */
.sw-footer::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--f-red) 0%, rgba(245, 30, 70, 0.4) 45%, rgba(245, 30, 70, 0.06) 100%);
}

.sw-footer a { text-decoration: none; }

.sw-footer__grid {
    display: grid;
    grid-template-columns: 1.5fr 0.8fr 1.25fr 0.95fr 1.5fr;
    gap: 40px 28px;
    padding-bottom: 48px;
}

/*======================= Brand column =======================*/

.sw-footer__logo {
    display: inline-flex;
    align-items: center;
    /*
     * The store logo is dark artwork on transparency (measured average
     * brightness 67/255), so it would disappear on this background. A light
     * plate keeps it legible without altering the asset.
     */
    padding: 10px 14px;
    background: #fff;
    border-radius: 10px;
}

.sw-footer__logo img {
    display: block;
    width: auto;
    height: 34px;
    max-width: 200px;
    object-fit: contain;
}

.sw-footer__logo-text {
    font-size: 18px;
    font-weight: 700;
    color: var(--f-ink);
}

.sw-footer__about {
    max-width: 40ch;
    margin: 18px 0 0;
    font-size: 13.5px;
    line-height: 1.7;
    color: var(--f-on-dark-2);
}

.sw-footer__social { margin-top: 22px; }

.sw-footer__social-title {
    display: block;
    margin-bottom: 10px;
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: var(--f-on-dark-3);
}

.sw-footer__social-list {
    display: flex;
    gap: 9px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sw-footer__social-list a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    font-size: 18px;
    color: var(--f-on-dark);
    background: var(--f-dark-chip);
    border: 1px solid var(--f-dark-line);
    border-radius: 50%;
    transition: background-color 0.18s ease, border-color 0.18s ease,
        color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.sw-footer__social-list a:hover,
.sw-footer__social-list a:focus-visible {
    color: #fff;
    background: var(--f-red);
    border-color: var(--f-red);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(245, 30, 70, 0.28);
}

/*======================= Link columns =======================*/

.sw-footer__title {
    margin: 0 0 18px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--f-on-dark);
}

/* Short brand underline beneath each heading; hidden once the
   columns collapse into accordions. */
.sw-footer__title::after {
    content: "";
    display: block;
    width: 22px;
    height: 2px;
    margin-top: 9px;
    background: var(--f-red);
    border-radius: 2px;
}

.sw-footer__title button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0;
    font: inherit;
    letter-spacing: inherit;
    text-transform: inherit;
    color: inherit;
    text-align: left;
    background: none;
    border: 0;
    cursor: default;
}

/* The chevron is only meaningful once the columns collapse. */
.sw-footer__title button > i { display: none; }

.sw-footer__links {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sw-footer__links a {
    display: inline-block;
    font-size: 13.5px;
    line-height: 1.45;
    color: var(--f-on-dark-2);
    transition: color 0.17s ease;
}

.sw-footer__links a:hover,
.sw-footer__links a:focus-visible {
    color: var(--f-on-dark);
    text-decoration: underline;
    text-decoration-color: var(--f-red);
    text-decoration-thickness: 1.5px;
    text-underline-offset: 5px;
}

/*======================= Contact column =======================*/

.sw-footer__contact li {
    display: flex;
    align-items: center;
    gap: 11px;
    font-size: 13.5px;
    line-height: 1.5;
    color: var(--f-on-dark-2);
}

/* Icon chip in front of each contact row. */
.sw-footer__ci {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: none;
    width: 32px;
    height: 32px;
    font-size: 16px;
    color: var(--f-red);
    background: var(--f-dark-chip);
    border: 1px solid var(--f-dark-line);
    border-radius: 9px;
}

/* Address rows can run long; keep the chip on the first line. */
.sw-footer__contact li:has(> span:last-child) { align-items: flex-start; }

.sw-footer__contact a {
    color: var(--f-on-dark);
    transition: color 0.17s ease;
}

.sw-footer__contact a:hover,
.sw-footer__contact a:focus-visible { color: var(--f-red); }

.sw-footer__chat {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.sw-chat {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 1 1 auto;
    gap: 8px;
    min-height: 40px;
    padding: 8px 15px;
    font-size: 13px;
    font-weight: 600;
    color: var(--f-on-dark);
    background: var(--f-dark-chip);
    border: 1px solid var(--f-dark-line);
    border-radius: 9px;
    transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

/* Brand-coloured glyphs at rest, full brand fill on hover. */
.sw-chat svg { flex: none; transition: color 0.18s ease; }
.sw-chat--whatsapp svg { color: #2fd366; }
.sw-chat--viber svg { color: #9186f7; }

.sw-chat--whatsapp:hover,
.sw-chat--whatsapp:focus-visible {
    color: #fff;
    /* Darkened from WhatsApp's own green: white 13px text needs 4.5:1. */
    background: #0f7a3d;
    border-color: #0f7a3d;
}

.sw-chat--viber:hover,
.sw-chat--viber:focus-visible {
    color: #fff;
    /* Darkened from Viber's purple: white 13px text needs 4.5:1. */
    background: #6152d9;
    border-color: #6152d9;
}

.sw-chat:hover svg,
.sw-chat:focus-visible svg { color: #fff; }

/*======================= Bottom bar =======================*/

.sw-footer__bottombar {
    background: #0c0e11;
    border-top: 1px solid var(--f-dark-line);
}

.sw-footer__bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px 18px;
    padding: 16px 0;
}

.sw-footer__copy,
.sw-footer__copy p {
    margin: 0;
    font-size: 12.5px;
    color: var(--f-on-dark-3);
}

.sw-footer__copy a { color: var(--f-on-dark-2); transition: color 0.17s ease; }
.sw-footer__copy a:hover { color: var(--f-red); }

.sw-footer__bottom-right {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px 16px;
}

.sw-footer__pay {
    display: inline-flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.sw-footer__pay-label {
    font-size: 11.5px;
    font-weight: 600;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--f-on-dark-3);
}

.sw-footer__pay-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    font-size: 12px;
    font-weight: 500;
    color: var(--f-on-dark-2);
    background: var(--f-dark-chip);
    border: 1px solid var(--f-dark-line);
    border-radius: 999px;
}

.sw-footer__pay-chip > i {
    font-size: 14px;
    color: var(--f-red);
}

.sw-footer__legal {
    position: relative;
    font-size: 12.5px;
    color: var(--f-on-dark-3);
    transition: color 0.17s ease;
}

/* Separator dot between the payment chips and the policy link. */
.sw-footer__pay + .sw-footer__legal::before {
    content: "\2022";
    margin-inline-end: 14px;
    color: var(--f-dark-line);
}

.sw-footer__legal:hover,
.sw-footer__legal:focus-visible { color: var(--f-on-dark); }

/*======================= Focus states =======================*/

.sw-footer a:focus-visible,
.sw-footer button:focus-visible {
    outline: 2px solid var(--f-red);
    outline-offset: 3px;
}

/*======================= Back-to-top button =======================*/
/*
 * Restyles the compiled .scroll-to-top component: white plate with a soft
 * shadow, red progress ring (unchanged), and a red fill on hover. Doubled
 * class beats the compiled rules that load after this file.
 */

.scroll-to-top.scroll-to-top::after {
    background: #fff;
    box-shadow: 0 6px 18px rgba(15, 20, 25, 0.22);
    transition: background-color 0.18s ease;
}

.scroll-to-top.scroll-to-top:hover::after,
.scroll-to-top.scroll-to-top:focus-visible::after {
    background: var(--color-primary, #f51e46);
}

.scroll-to-top.scroll-to-top:hover .top-arrow svg path,
.scroll-to-top.scroll-to-top:focus-visible .top-arrow svg path {
    fill: #fff;
}

.scroll-to-top.scroll-to-top:focus-visible {
    outline: 2px solid var(--color-primary, #f51e46);
    outline-offset: 3px;
}

/*======================= Responsive =======================*/

/* Between full desktop and tablet the five columns no longer fit cleanly:
   the brand block takes its own row and the four link groups share one. */
@media (max-width: 1199px) {
    .sw-footer__grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 36px 28px;
    }

    .sw-footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 991px) {
    .sw-benefits__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 0; }
    .sw-benefits__item:nth-child(odd) { border-left: 0; padding-left: 0; }

    .sw-footer__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 32px 28px;
    }
}

@media (max-width: 767px) {
    .sw-benefits { margin-top: 24px; padding: 18px 0; }
    /* No room for dividers once the strip stacks; without this, even items
       kept a stray border flush against their icon chip. */
    .sw-benefits__item { padding: 2px 0; border-left: 0; }

    .sw-footer { padding-top: 40px; }

    .sw-footer__grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
        padding-bottom: 26px;
    }

    .sw-footer__brand { padding-bottom: 26px; }

    /* Collapsible groups. Logo, description, social and copyright stay open. */
    .sw-footer__col {
        border-top: 1px solid var(--f-dark-line);
    }

    .sw-footer__title { margin: 0; }
    .sw-footer__title::after { display: none; }

    .sw-footer__title button {
        padding: 16px 0;
        cursor: pointer;
    }

    .sw-footer__title button > i {
        display: block;
        font-size: 13px;
        color: var(--f-on-dark-3);
        transition: transform 0.2s ease;
    }

    .sw-footer__col.is-open .sw-footer__title button > i { transform: rotate(180deg); }

    .sw-footer__links,
    .sw-footer__chat { display: none; }

    .sw-footer__col.is-open .sw-footer__links { display: flex; padding-bottom: 18px; }
    .sw-footer__col.is-open .sw-footer__chat { display: flex; padding-bottom: 18px; margin-top: 0; }

    .sw-footer__links a { padding: 5px 0; }

    .sw-footer__bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        padding: 16px 0 18px;
    }

    .sw-footer__pay + .sw-footer__legal::before { content: none; margin: 0; }
}

@media (max-width: 479px) {
    .sw-benefits__grid { grid-template-columns: minmax(0, 1fr); }
    .sw-footer__logo img { height: 30px; }
}

@media (prefers-reduced-motion: reduce) {
    .sw-footer *,
    .sw-benefits *,
    .scroll-to-top.scroll-to-top,
    .scroll-to-top.scroll-to-top::after {
        transition: none !important;
    }
}

/*======================= DARK THEME (appended) =======================*/
/*
 * Everything below is gated behind [data-theme="dark"]; light mode is
 * untouched by construction. The footer itself is dark by design and
 * stays dark in both themes, so this is a small delta: chip fills and
 * hairlines get slightly stronger so they read against the dark page,
 * the benefits strip flips from a light grey band to a dark one, and
 * the back-to-top plate goes dark.
 */

/* Stronger chip fills / hairlines on the already-dark surfaces. */
[data-theme="dark"] .sw-benefits,
[data-theme="dark"] .sw-footer {
    --f-dark-chip: rgba(255, 255, 255, 0.07);
    --f-dark-line: rgba(255, 255, 255, 0.12);
}

/* Benefits strip: the light band becomes a dark band. Flipping the
   light-ink tokens here lets the existing text rules pick up dark
   values through the same vars, and border-top follows --f-line on
   its own (the light rule already reads it). */
[data-theme="dark"] .sw-benefits {
    --f-ink: #e8ebef;
    --f-ink-2: #a6adb8;
    --f-line: #2a303a;
    background: #14171c;
}

[data-theme="dark"] .sw-benefits__icon {
    background: rgba(245, 30, 70, 0.14);
}

/* Back-to-top: dark plate with a deeper shadow. */
[data-theme="dark"] .scroll-to-top.scroll-to-top::after {
    background: #1e232a;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5);
}

/* Re-assert the red hover/focus fill under the dark gate: the dark
   base rule above ties the light :hover rule on specificity (0-3-1)
   and, appended later, would otherwise win by source order and kill
   the fill. Values are identical to the light rules above. */
[data-theme="dark"] .scroll-to-top.scroll-to-top:hover::after,
[data-theme="dark"] .scroll-to-top.scroll-to-top:focus-visible::after {
    background: var(--color-primary, #f51e46);
}
