/* Footer Builder — driven by CSS variables + data attributes */

.fb-footer {
    --fb-bg: #0f172a;
    --fb-text: #cbd5e1;
    --fb-heading: #ffffff;
    --fb-link: #94a3b8;
    --fb-link-hover: #ffffff;
    --fb-max-width: 1320px;
    --fb-pad-y: 48px;
    --fb-gap: 32px;
    --fb-cols: 4;
    --fb-border: none;
    --fb-overlay: rgba(0,0,0,.7);
    --fb-radius-top: 0px;

    position: relative;
    width: 100%;
    background: var(--fb-bg);
    color: var(--fb-text);
    border-top: var(--fb-border);
    border-top-left-radius: var(--fb-radius-top);
    border-top-right-radius: var(--fb-radius-top);
    margin-top: 40px;
    overflow: hidden;
}

.fb-footer[data-fb-bg-mode="image"] {
    background-size: var(--fb-bg-size, cover);
    background-position: var(--fb-bg-position, center);
    background-attachment: var(--fb-bg-attach, scroll);
    background-repeat: no-repeat;
}
/* Image filter (blur + brightness) — applied to a layer behind content */
.fb-footer[data-fb-bg-mode="image"]::before {
    content: '';
    position: absolute; inset: 0;
    background-image: inherit;
    background-size: var(--fb-bg-size, cover);
    background-position: var(--fb-bg-position, center);
    background-attachment: var(--fb-bg-attach, scroll);
    background-repeat: no-repeat;
    filter: blur(var(--fb-bg-blur, 0px)) brightness(var(--fb-bg-brightness, 100%));
    z-index: 0;
    pointer-events: none;
    /* Only show when blur or brightness customized (avoid double-rendering) */
    opacity: 0;
}
.fb-footer[data-fb-bg-mode="image"][style*="--fb-bg-blur:"]:not([style*="--fb-bg-blur:0px"])::before,
.fb-footer[data-fb-bg-mode="image"][style*="--fb-bg-brightness:"]:not([style*="--fb-bg-brightness:100%"])::before {
    opacity: 1;
}

.fb-overlay {
    position: absolute; inset: 0;
    background: var(--fb-overlay, rgba(0,0,0,.7));
    pointer-events: none;
    z-index: 0;
}

.fb-inner {
    max-width: var(--fb-max-width);
    margin: 0 auto;
    padding-inline: 24px;
    box-sizing: border-box;
    position: relative;
    z-index: 1;
}
/* Boxed: clamp inner to user's max-width — clearly narrower than viewport */
.fb-footer[data-fb-container="boxed"] .fb-inner {
    max-width: var(--fb-max-width);
}
/* Full: edge-to-edge, only minimal viewport padding */
.fb-footer[data-fb-container="full"] .fb-inner {
    max-width: 100%;
    padding-inline: clamp(16px, 4vw, 48px);
}
/* App badges band */
.fb-app-band {
    padding: 28px 0;
    background: rgba(255,255,255,.04);
    border-bottom: 1px solid rgba(255,255,255,.06);
    text-align: center;
}
.fb-app-band__title {
    color: var(--fb-heading); font-size: 16px; font-weight: 700;
    margin: 0 0 16px;
}
.fb-app-badges {
    display: flex; gap: 12px; flex-wrap: wrap;
    justify-content: center;
}

/* Pure CSS store badges — Apple / Google / Bazaar branded pills */
.fb-store-badge {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 8px 18px; min-width: 160px;
    background: #000;
    color: #fff !important;
    text-decoration: none;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,.15);
    transition: transform .15s, filter .15s, box-shadow .15s;
}
.fb-store-badge:hover { transform: translateY(-2px); filter: brightness(1.15); box-shadow: 0 8px 20px rgba(0,0,0,.25); }
.fb-store-badge i { font-size: 26px; line-height: 1; }
.fb-store-badge__text { display: flex; flex-direction: column; line-height: 1.2; text-align: start; }
.fb-store-badge__text small { font-size: 9.5px; opacity: .7; letter-spacing: .04em; text-transform: uppercase; }
.fb-store-badge__text strong { font-size: 14px; font-weight: 700; }
.fb-store-badge--bazaar { background: linear-gradient(135deg, #1cb13a 0%, #0e7a26 100%); border-color: rgba(255,255,255,.2); }

/* Made with / powered by line */
.fb-made-with, .fb-powered-by {
    margin-inline-end: auto;
    font-size: 11.5px;
    opacity: .65;
    color: var(--fb-text);
}
.fb-made-with a, .fb-powered-by a { color: var(--fb-link-hover); text-decoration: none; }
.fb-made-with a:hover, .fb-powered-by a:hover { text-decoration: underline; }
.fb-powered-by .fb-heart { color: #ec4899; }

/* Back-to-top — floating mode */
.fb-back-to-top {
    position: fixed;
    bottom: var(--fb-btt-desktop, 20px);
    width: var(--fb-btt-size, 44px);
    height: var(--fb-btt-size, 44px);
    background: var(--bs-primary, #7367f0);
    color: #fff; border: 0; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    box-shadow: 0 6px 20px rgba(0,0,0,.18);
    cursor: pointer;
    opacity: 0; visibility: hidden; transform: translateY(10px);
    transition: opacity .25s, transform .25s, visibility .25s;
    z-index: 999;
    font-size: 18px;
}
.fb-back-to-top--start { inset-inline-start: 20px; }
.fb-back-to-top--end   { inset-inline-end: 20px; }
.fb-back-to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.fb-back-to-top:hover { filter: brightness(1.1); transform: translateY(-2px); }
@media (max-width: 991.98px) {
    .fb-back-to-top { bottom: var(--fb-btt-mobile, 80px); width: 40px; height: 40px; font-size: 16px; }
}

/* Back-to-top — inline link mode (rendered inside bottom bar) */
.fb-back-to-top-inline {
    color: var(--fb-link); text-decoration: none;
    font-size: 13px; font-weight: 500;
    display: inline-flex; align-items: center; gap: 6px;
    transition: color .15s;
}
.fb-back-to-top-inline:hover { color: var(--fb-link-hover); }
.fb-back-to-top-inline i { font-size: 12px; opacity: .8; }

/* ── Newsletter band ── */
.fb-newsletter {
    padding: 28px 0;
    background: rgba(255,255,255,.04);
    border-bottom: 1px solid rgba(255,255,255,.06);
}
.fb-newsletter .fb-inner {
    display: flex; align-items: center; gap: 24px;
    flex-wrap: wrap;
}
.fb-newsletter__text { flex: 1; min-width: 220px; }
.fb-newsletter__title { color: var(--fb-heading); font-size: 18px; font-weight: 700; margin: 0 0 4px; }
.fb-newsletter__desc { color: var(--fb-text); font-size: 13px; margin: 0; opacity: .85; }
.fb-newsletter__form { display: flex; gap: 8px; flex: 1; max-width: 480px; min-width: 260px; }
.fb-newsletter__input {
    flex: 1; min-width: 0;
    padding: 12px 16px;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.1);
    color: #fff; font-size: 14px;
    border-radius: 999px;
    outline: 0;
}
.fb-newsletter__input::placeholder { color: rgba(255,255,255,.5); }
.fb-newsletter__input:focus { border-color: var(--fb-link-hover); background: rgba(255,255,255,.12); }
.fb-newsletter__btn {
    padding: 12px 24px;
    background: var(--bs-primary, #7367f0);
    color: #fff;
    border: 0; border-radius: 999px;
    font-weight: 600; cursor: pointer;
    transition: filter .15s, transform .12s;
    font-size: 14px;
    flex-shrink: 0;
}
.fb-newsletter__btn:hover { filter: brightness(1.1); transform: translateY(-1px); }

/* ── Main columns ── */
.fb-main { padding: var(--fb-pad-y) 0; }
.fb-cols {
    display: grid;
    grid-template-columns: repeat(var(--fb-cols, 4), 1fr);
    gap: var(--fb-gap);
}

.fb-col__title {
    color: var(--fb-heading);
    font-size: 15px; font-weight: 700;
    margin: 0 0 16px;
    letter-spacing: -.01em;
    position: relative;
    padding-bottom: 10px;
}
.fb-col__title::after {
    content: '';
    position: absolute; bottom: 0; inset-inline-start: 0;
    width: 28px; height: 2px;
    background: var(--bs-primary, #7367f0);
    border-radius: 2px;
}

/* About */
.fb-logo { max-height: 40px; margin-bottom: 14px; display: block; }
.fb-logo-text { display: block; font-size: 18px; font-weight: 700; color: var(--fb-heading); margin-bottom: 12px; }
.fb-about__text { color: var(--fb-text); font-size: 13px; line-height: 1.8; margin: 0; opacity: .9; }

/* Links list */
.fb-links { list-style: none; margin: 0; padding: 0; }
.fb-links li { margin-bottom: 8px; }
.fb-links li a {
    color: var(--fb-link); text-decoration: none;
    font-size: 13.5px;
    transition: color .15s, padding-inline-start .15s;
    display: inline-block;
}
.fb-links li a:hover {
    color: var(--fb-link-hover);
    padding-inline-start: 4px;
}

/* Contact */
.fb-contact { list-style: none; margin: 0; padding: 0; }
.fb-contact li {
    display: flex; align-items: center; gap: 10px;
    color: var(--fb-text); font-size: 13.5px;
    margin-bottom: 10px;
    line-height: 1.6;
}
.fb-contact li i {
    width: 20px; text-align: center;
    color: var(--fb-link-hover); opacity: .8;
    flex-shrink: 0;
}
.fb-contact a { color: var(--fb-text); text-decoration: none; }
.fb-contact a:hover { color: var(--fb-link-hover); }

/* Socials */
.fb-socials {
    display: flex; gap: 8px; flex-wrap: wrap;
    margin-top: 14px;
}
.fb-social {
    width: 38px; height: 38px;
    border-radius: 10px;
    background: rgba(255,255,255,.06);
    color: var(--fb-link-hover);
    display: inline-flex; align-items: center; justify-content: center;
    text-decoration: none;
    transition: all .15s;
    font-size: 16px;
}
.fb-social:hover {
    background: var(--bs-primary, #7367f0);
    color: #fff; transform: translateY(-2px);
}

/* Text */
.fb-text { color: var(--fb-text); font-size: 13.5px; line-height: 1.8; margin: 0; }

/* Payments */
.fb-payments { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.fb-payments img { height: 36px; width: auto; opacity: .85; transition: opacity .15s; }
.fb-payments img:hover { opacity: 1; }

/* Trust badges */
.fb-trust { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.fb-trust img { height: 80px; width: auto; }

/* ── Bottom bar ── */
.fb-bottombar {
    padding: 16px 0;
    background: rgba(0,0,0,.15);
    --fb-border-color: rgba(255,255,255,.06);
}
.fb-bottombar__inner {
    display: flex; align-items: center; gap: 16px;
    flex-wrap: wrap;
}
.fb-copyright {
    color: var(--fb-text);
    font-size: 12.5px; opacity: .8;
    flex: 1; min-width: 0;
}
.fb-bottombar__cluster {
    display: flex; align-items: center; gap: 16px;
    flex-wrap: wrap;
    margin-inline-start: auto;
}
.fb-trust--inline img { height: 50px; }
.fb-payments--inline img { height: 26px; opacity: .7; }

/* Light bg variant — when bg is light, flip default colors */
.fb-footer[style*="--fb-bg:#fff"],
.fb-footer[style*="--fb-bg:#ffffff"],
.fb-footer[style*="--fb-bg:#f8fafc"] {
    --fb-text: #475569;
    --fb-heading: #0f172a;
    --fb-link: #64748b;
    --fb-link-hover: #0f172a;
}
.fb-footer[style*="--fb-bg:#ff"] .fb-newsletter,
.fb-footer[style*="--fb-bg:#f8"] .fb-newsletter { background: rgba(0,0,0,.03); border-color: rgba(0,0,0,.06); }
.fb-footer[style*="--fb-bg:#ff"] .fb-newsletter__input,
.fb-footer[style*="--fb-bg:#f8"] .fb-newsletter__input {
    background: #fff; border-color: rgba(0,0,0,.1); color: #1f2937;
}
.fb-footer[style*="--fb-bg:#ff"] .fb-newsletter__input::placeholder,
.fb-footer[style*="--fb-bg:#f8"] .fb-newsletter__input::placeholder { color: rgba(0,0,0,.4); }
.fb-footer[style*="--fb-bg:#ff"] .fb-social,
.fb-footer[style*="--fb-bg:#f8"] .fb-social { background: rgba(0,0,0,.05); }
.fb-footer[style*="--fb-bg:#ff"] .fb-bottombar,
.fb-footer[style*="--fb-bg:#f8"] .fb-bottombar { background: rgba(0,0,0,.02); --fb-border-color: rgba(0,0,0,.06); }

/* ── Responsive ── */
@media (max-width: 991.98px) {
    .fb-cols { grid-template-columns: repeat(2, 1fr); gap: 24px; }
    .fb-newsletter .fb-inner { gap: 16px; }
}
@media (max-width: 575.98px) {
    .fb-cols { grid-template-columns: 1fr; gap: 24px; }
    .fb-main { padding: 32px 0; }
    .fb-newsletter { padding: 20px 0; }
    .fb-newsletter__form { width: 100%; }
    .fb-bottombar__inner { flex-direction: column; align-items: flex-start; gap: 12px; }
    .fb-bottombar__cluster { margin-inline-start: 0; }
    .fb-trust--inline img { height: 40px; }
}
