/* The redesigned shop page (shops::shop_v2) and its reviews page; the product list is products::listing_v2. */
.sp-alert { margin: 16px 0 0; padding: 10px 14px; border-radius: var(--gz-radius-md); background: var(--gz-info-50); color: var(--gz-info); font-size: 13px; }
.sp-alert.is-danger { background: var(--gz-danger-50); color: var(--gz-danger); }

/* ---- the shop's top: a full-width band from the very top of the page, the glass header sitting on it, the shop's
   details right under the header (as wide as the page's column). With the seller's cover photo filling the band,
   a glass over it: clear at the top, whiter and more blurred towards the bottom, so the details stay readable ---- */
.sp-hero {
    --sp-head: 82px; /* the site header's height */
    position: relative; margin-top: calc(-1 * var(--sp-head)); padding-top: var(--sp-head); overflow: hidden;
    background: linear-gradient(180deg, var(--gz-brand-50) 0%, var(--gz-surface) 100%);
}
.sp-cover { position: absolute; inset: 0; background: center / cover no-repeat; }
.sp-hero.has-cover::after {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    /* a long, even ramp into the page's white, so the photo fades away instead of ending */
    background: linear-gradient(180deg,
        rgba(255, 255, 255, 0) 0,
        rgba(255, 255, 255, .18) var(--sp-head),
        rgba(255, 255, 255, .45) calc(var(--sp-head) + 60px),
        rgba(255, 255, 255, .82) calc(var(--sp-head) + 120px),
        rgba(255, 255, 255, .94) calc(var(--sp-head) + 180px),
        var(--gz-surface) 100%);
    -webkit-backdrop-filter: saturate(150%) blur(20px); backdrop-filter: saturate(150%) blur(20px);
    -webkit-mask-image: linear-gradient(180deg, transparent 0, transparent calc(var(--sp-head) - 40px), rgba(0, 0, 0, .6) calc(var(--sp-head) + 30px), #000 calc(var(--sp-head) + 110px));
    mask-image: linear-gradient(180deg, transparent 0, transparent calc(var(--sp-head) - 40px), rgba(0, 0, 0, .6) calc(var(--sp-head) + 30px), #000 calc(var(--sp-head) + 110px));
}
.sp-card { position: relative; z-index: 1; padding-top: 50px; padding-bottom: 28px; }
/* with a cover photo the details sit lower, where the glass has already turned white */
.sp-hero.has-cover .sp-card { padding-top: 130px; }
.sp-alert { margin: 0 0 14px; }
/* no cover photo: a soft glow in the colours of the logo (ShopPalette), fading into the page */
.sp-hero.has-palette {
    background:
        radial-gradient(55% 90% at 88% 10%, rgba(var(--sp-c1), .32), transparent 70%),
        radial-gradient(45% 80% at 30% 0%, rgba(var(--sp-c2), .24), transparent 72%),
        radial-gradient(60% 70% at 55% 60%, rgba(var(--sp-c1), .12), transparent 75%),
        linear-gradient(180deg, rgba(var(--sp-c1), .08) 0%, var(--gz-surface) 100%);
}
.sp-hero.has-palette::after {
    content: ""; position: absolute; right: 0; bottom: 0; left: 0; height: 90px; pointer-events: none;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0), var(--gz-surface));
}
.sp-top { display: flex; align-items: center; gap: 16px; }
.sp-logo {
    position: relative; flex-shrink: 0; width: 88px; height: 88px; border: 1px solid var(--gz-border); border-radius: 50%;
    background: #fff; box-shadow: 0 6px 18px rgba(28, 18, 36, .08);
}
/* a soft shadow in the logo's own colour (ShopPalette) */
.sp-hero.has-tint .sp-logo { border-color: rgba(var(--sp-c1), .25); box-shadow: 0 10px 28px rgba(var(--sp-c1), .35), 0 2px 6px rgba(var(--sp-c1), .2); }
.sp-logo img { display: block; width: 100%; height: 100%; border-radius: inherit; object-fit: cover; }
.sp-logo .sc-online { position: absolute; right: 4px; bottom: 4px; }
.sp-logo.is-small { width: 56px; height: 56px; }
.sp-names { flex: 1; min-width: 0; }
.sp-title { margin: 0; font-size: 22px; font-weight: 900; line-height: 1.6; }
.sp-sub { display: flex; flex-wrap: wrap; align-items: center; margin: 2px 0 0; color: var(--gz-ink-3); font-size: 13px; }
.sp-sub span:not(:empty) ~ span:not(:empty)::before {
    content: ""; display: inline-block; width: 3px; height: 3px; margin: 0 8px; border-radius: 50%; background: var(--gz-ink-4); vertical-align: middle;
}
/* the badges stay in one row and scroll sideways when there are many */
.sp-badges { display: flex; flex-wrap: nowrap; gap: 6px; margin-top: 10px; overflow-x: auto; scrollbar-width: none; }
.sp-badges::-webkit-scrollbar { display: none; }
.sp-badges > * { flex-shrink: 0; }
.sp-chip { display: inline-flex; align-items: center; gap: 4px; height: 26px; padding: 0 10px; border-radius: var(--gz-radius-pill); font-size: 12px; font-weight: 700; }
.sp-chip.is-green { background: var(--gz-success-50); color: var(--gz-success); }
.sp-chip .gzi { font-size: 15px; }
.sp-actions { display: flex; flex-shrink: 0; align-items: center; gap: 8px; }
.sp-btn {
    position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 46px; padding: 0 20px;
    border: 1px solid var(--gz-border-strong); border-radius: var(--gz-radius-pill); background: var(--gz-surface);
    color: var(--gz-ink) !important; font: 700 14px var(--gz-font); white-space: nowrap; cursor: pointer; transition: background var(--gz-fast);
}
.sp-btn:hover { background: var(--gz-surface-2); }
.sp-btn .gzi { font-size: 19px; }
.sp-btn.is-primary { border-color: var(--gz-brand-500); background: var(--gz-brand-500); color: #fff !important; }
.sp-btn.is-primary:hover { background: var(--gz-brand-600); }
.sp-btn.is-icon { width: 46px; padding: 0; }
/* share and report: glass, so they sit lightly on a cover photo too */
.sp-hero .sp-btn.is-icon, .sp-hero .sp-btn.is-glass {
    border-color: rgba(255, 255, 255, .7); background: rgba(255, 255, 255, .5);
    -webkit-backdrop-filter: saturate(160%) blur(12px); backdrop-filter: saturate(160%) blur(12px); box-shadow: 0 2px 10px rgba(28, 18, 36, .08);
}
.sp-hero .sp-btn.is-icon:hover, .sp-hero .sp-btn.is-glass:hover { background: rgba(255, 255, 255, .8); }
/* share and report matter less than the chat: smaller and quieter */
.sp-actions .sp-btn.is-icon, .sp-actions .sp-btn.is-glass { height: 36px; box-shadow: none; }
.sp-actions .sp-btn.is-icon { width: 36px; }
.sp-actions .sp-btn.is-icon .gzi { font-size: 16px; }
.sp-btn.is-glass { gap: 4px; padding: 0 12px; color: var(--gz-ink-3) !important; font-size: 12px; font-weight: 600; }
.sp-btn.is-glass .gzi { font-size: 15px; }
.sp-btn .loader-container { display: none; }
.sp-btn.loading .loader-container { display: inline-flex; position: absolute; }
.sp-btn.loading .gzi { opacity: 0; }

.sp-stats { display: flex; flex-wrap: wrap; gap: 12px 0; margin: 20px 0 0; padding: 0; list-style: none; }
.sp-stats li { display: flex; flex-direction: column; gap: 2px; padding: 0 22px; border-inline-start: 1px solid var(--gz-border); }
.sp-stats li:first-child { padding-inline-start: 0; border: 0; }
.sp-stats b { display: inline-flex; align-items: center; gap: 4px; color: var(--gz-ink); font-size: 18px; font-weight: 900; }
.sp-stats b.is-green { color: var(--gz-success); }
.sp-stats b.is-danger { color: var(--gz-danger); }
.sp-stats span { color: var(--gz-ink-3); font-size: 12px; }
/* the performance meter as the first figure */
.sp-stats .gz-meter-text b { color: var(--gz-meter-color); font-size: 18px; }
.sp-stats .gz-meter { gap: 10px; }
.sp-tone.is-good { color: var(--gz-success) !important; }
.sp-tone.is-fair { color: var(--gz-warning) !important; }
.sp-tone.is-poor { color: var(--gz-danger) !important; }
.sp-star { color: var(--gz-star); fill: var(--gz-star); font-size: 17px; }
.sp-bio {
    display: -webkit-box; margin: 16px 0 0; overflow: hidden; color: var(--gz-ink-2); font-size: 13.5px; line-height: 2;
    -webkit-box-orient: vertical; -webkit-line-clamp: 2; cursor: pointer;
}
.sp-bio.is-open { display: block; cursor: auto; }
.sp-warn { margin: 14px 0 0; padding: 10px 12px; border-radius: var(--gz-radius-md); background: var(--gz-warning-50); color: var(--gz-ink-2); font-size: 12.5px; line-height: 1.9; }

/* ---- tabs ---- */
.sp-tabs { display: flex; gap: 22px; margin: 4px 0 0; border-bottom: 1px solid var(--gz-border); }
.sp-tab {
    position: relative; padding: 12px 2px; border: 0; background: none; color: var(--gz-ink-3) !important;
    font: 700 14.5px var(--gz-font); white-space: nowrap; cursor: pointer;
}
.sp-tab:hover { color: var(--gz-ink) !important; }
.sp-tab.is-active { color: var(--gz-ink) !important; }
.sp-tab.is-active::after { content: ""; position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; border-radius: 2px; background: var(--gz-brand-500); }

.sp-section { margin-top: 24px; }
.sp-section-title { margin: 0 0 12px; font-size: 17px; font-weight: 800; }
.sp .lv-list { margin-top: 28px; }

/* the shop's main categories: tinted tiles, a click filters the list */
.sp-cats { position: relative; }
.sp-cats-track { display: flex; gap: 12px; padding: 2px 2px 6px; overflow-x: auto; scrollbar-width: none; }
.sp-cats-track::-webkit-scrollbar { display: none; }
.sp-cat { display: flex; flex: 0 0 auto; flex-direction: column; align-items: center; gap: 8px; width: 96px; color: var(--gz-ink-2) !important; transition: opacity var(--gz-fast); }
/* plain and alike: a light tile with a thin edge; the chosen one gets the brand edge */
.sp-cat-media {
    display: flex; align-items: center; justify-content: center; width: 88px; height: 88px; overflow: hidden;
    border: 1px solid var(--gz-border); border-radius: var(--gz-radius-lg); background: var(--gz-surface-2);
    transition: border-color var(--gz-fast), transform var(--gz-fast);
}
.sp-cat-media img { width: 78%; height: 78%; object-fit: contain; mix-blend-mode: multiply; }
.sp-cat:hover .sp-cat-media { border-color: var(--gz-border-strong); transform: translateY(-2px); }
.sp-cat-title { display: -webkit-box; overflow: hidden; font-size: 12.5px; font-weight: 600; line-height: 1.6; text-align: center; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.sp-cat.is-active .sp-cat-media { border: 2px solid var(--gz-brand-500); background: var(--gz-brand-50); }
.sp-cat.is-active .sp-cat-title { color: var(--gz-brand-700); font-weight: 800; }
.sp-cat.is-pending { opacity: .45; filter: grayscale(1); pointer-events: none; }

/* ---- buyer reviews ---- */
.sp-reviews.pb-rail { --pb-per: 3.3; }
.sp-review {
    display: flex; flex-direction: column; gap: 10px; height: 100%; padding: 16px; border: 1px solid var(--gz-border);
    border-radius: var(--gz-radius-lg); background: var(--gz-surface);
}
.sp-review-head { display: flex; align-items: center; gap: 10px; }
.sp-review-avatar {
    display: inline-flex; flex-shrink: 0; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%;
    background: var(--gz-brand-50); color: var(--gz-brand-600); font-size: 15px; font-weight: 800;
}
.sp-review-who { display: flex; flex: 1; flex-direction: column; min-width: 0; }
.sp-review-who b { overflow: hidden; font-size: 13.5px; white-space: nowrap; text-overflow: ellipsis; }
.sp-review-who small { color: var(--gz-ink-4); font-size: 11.5px; }
.sp-stars { display: inline-flex; flex-shrink: 0; gap: 1px; }
.sp-stars .gzi { font-size: 14px; color: var(--gz-border-strong); fill: var(--gz-border-strong); }
.sp-stars .gzi.is-on { color: var(--gz-star); fill: var(--gz-star); }
.sp-review-text { margin: 0; color: var(--gz-ink-2); font-size: 13.5px; line-height: 2; white-space: pre-line; }
.sp-reviews .sp-review-text { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 4; }
.sp-review-points { display: flex; flex-direction: column; gap: 3px; margin: 0; padding: 0; list-style: none; font-size: 12.5px; }
.sp-review-points li { position: relative; padding-inline-start: 16px; color: var(--gz-ink-2); }
.sp-review-points li::before { position: absolute; right: 0; font-weight: 900; }
.sp-review-points .is-plus::before { content: "+"; color: var(--gz-success); }
.sp-review-points .is-minus::before { content: "−"; color: var(--gz-danger); }
.sp-review-product {
    display: flex; align-items: center; gap: 8px; margin-top: auto; padding: 8px; border-radius: var(--gz-radius-md);
    background: var(--gz-surface-2); color: var(--gz-ink-2) !important; font-size: 12.5px;
}
.sp-review-product img { flex-shrink: 0; width: 36px; height: 36px; border-radius: var(--gz-radius-sm); object-fit: cover; background: #fff; }
.sp-review-product span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.sp-review-product small { flex-shrink: 0; margin-inline-start: auto; color: var(--gz-ink-3); font-size: 11.5px; }

/* the reviews page */
.sp-xp-head { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.sp-xp-head > div { flex: 1; min-width: 0; }
.sp-xp-head .lv-subtitle { display: flex; align-items: center; gap: 4px; }
.sp-reviews-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; }
.sp-reviews-loader { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 14px; }
.sp-reviews-loader[hidden] { display: none; }
.sp-reviews-loader span {
    height: 150px; border-radius: var(--gz-radius-lg); background: linear-gradient(90deg, var(--gz-surface-2), var(--gz-surface-3), var(--gz-surface-2));
    background-size: 200% 100%; animation: lv-shimmer 1.4s linear infinite;
}

/* ---- about ---- */
.sp-about { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 16px; margin-top: 20px; align-items: start; }
.sp-about-main, .sp-about-side { display: flex; flex-direction: column; gap: 16px; }
/* the performance card: the shop, a large level meter, the figures behind it */
.sp-perf { padding: 0; overflow: hidden; }
.sp-perf-head { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--gz-border); }
.sp-perf-head img { width: 40px; height: 40px; border-radius: var(--gz-radius-sm); object-fit: cover; }
.sp-perf-head span { display: flex; flex-direction: column; }
.sp-perf-head b { font-size: 14px; }
.sp-perf-head small { color: var(--gz-ink-3); font-size: 12px; }
.sp-perf-meter { display: flex; justify-content: center; padding: 26px 18px 24px; }
.sp-perf-parts { display: grid; grid-auto-columns: minmax(0, 1fr); grid-auto-flow: column; margin: 0; padding: 14px 8px 18px; border-top: 1px solid var(--gz-border); list-style: none; }
.sp-perf-parts li { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 0 6px; text-align: center; }
.sp-perf-parts li + li { border-inline-start: 1px solid var(--gz-border); }
.sp-perf-parts b { font-size: 18px; font-weight: 900; }
.sp-perf-parts span { color: var(--gz-ink-3); font-size: 11.5px; line-height: 1.6; }
.sp-box { padding: 20px; border: 1px solid var(--gz-border); border-radius: var(--gz-radius-lg); background: var(--gz-surface); }
.sp-about-text { margin: 0; color: var(--gz-ink-2); font-size: 14px; line-height: 2.1; white-space: pre-line; }
.sp-facts { display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; list-style: none; color: var(--gz-ink-2); font-size: 13.5px; line-height: 1.9; }
.sp-facts li { display: flex; gap: 10px; }
.sp-facts .gzi { flex-shrink: 0; margin-top: 4px; font-size: 18px; color: var(--gz-brand-500); }
.sp-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.sp-link {
    display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border: 1px solid var(--gz-border-strong);
    border-radius: var(--gz-radius-pill); color: var(--gz-ink-2) !important; font-size: 13px; font-weight: 600;
}
.sp-link .gzi { font-size: 18px; }
.sp-gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.sp-gallery-item { display: block; overflow: hidden; border-radius: var(--gz-radius-md); background: var(--gz-surface-2); aspect-ratio: 1; }
.sp-gallery-item img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .3s var(--gz-ease); }
.sp-gallery-item:hover img { transform: scale(1.04); }

/* ---- phones and tablets ---- */
@media (max-width: 991.98px) {
    .sp-hero { --sp-head: 56px; }

    .sp-card { padding-top: 22px; padding-bottom: 16px; }
    .sp-hero.has-cover .sp-card { padding-top: 100px; }
    /* phones: everything centred and stacked: logo, name, the line under it, then the badges in one scrolling row */
    .sp-top { flex-direction: column; gap: 10px; text-align: center; }
    .sp-names { width: 100%; }
    .sp-logo { width: 76px; height: 76px; }
    .sp-title { font-size: 18px; }
    .sp-sub { justify-content: center; font-size: 12px; }
    .sp-badges { margin: 10px -15px 0; padding: 0 15px; }
    /* centred while they fit, scrolling from the start once they do not */
    .sp-badges > :first-child { margin-inline-start: auto; }
    .sp-badges > :last-child { margin-inline-end: auto; }
    .sp-actions { width: 100%; margin-top: 4px; }
    .sp-actions .sp-btn.is-primary { flex: 1; }
    .sp-btn { height: 44px; }
    .sp-btn.is-icon { width: 44px; }
    .sp-bio { text-align: center; }
    /* the figures: just three, small, in one quiet band (sales and product count stay on desktop) */
    .sp-stats {
        display: grid; grid-auto-columns: minmax(0, 1fr); grid-auto-flow: column; margin-top: 14px; padding: 10px 4px;
        border-radius: var(--gz-radius-md); background: rgba(255, 255, 255, .6); border: 1px solid var(--gz-border);
    }
    .sp-stats .sp-stat-extra { display: none; }
    .sp-stats li, .sp-stats li:first-child { align-items: center; justify-content: center; padding: 0 6px; text-align: center; }
    .sp-stats li:first-child { border: 0; }
    .sp-stats b, .sp-stats .gz-meter-text b { font-size: 14.5px; }
    .sp-stats span { font-size: 11px; }
    .sp-star { font-size: 14px; }
    .sp-stats .gz-meter { gap: 6px; }
    .sp-stats .gz-meter-bars { height: 18px; }
    /* the tabs stick under the header; the filter bar sticks under the tabs */
    .sp-tabs {
        position: sticky; top: 56px; z-index: 1019; justify-content: space-around; gap: 0; margin: 4px -15px 0; padding: 0 15px;
        background: rgba(255, 255, 255, .94); -webkit-backdrop-filter: saturate(180%) blur(14px); backdrop-filter: saturate(180%) blur(14px);
    }
    .sp-tab { flex: 1; font-size: 13.5px; text-align: center; }
    /* the bar stays in its place (the tabs stick instead); filters and sort float at the bottom (.lv-dock) */
    .sp .lv-bar { position: static; }
    .sp .lv-bar::before { display: none; }
    .sp .lv-chip.is-filters, .sp .lv-sort { display: none; }
    .sp .lv-bar.is-away { transform: none; }
    .sp-reviews.pb-rail { --pb-per: 1.2; }
    .sp-cat { width: 80px; }
    .sp-cat-media { width: 72px; height: 72px; }
    .sp-about { grid-template-columns: minmax(0, 1fr); }
    .sp-box { padding: 16px; }
    .sp-reviews-grid, .sp-reviews-loader { grid-template-columns: minmax(0, 1fr); }
    .sp-xp-head .sp-btn { display: none; }
}
