/* ============================================================
   KovaBuy shop / category listing page
============================================================ */

.sh-page { padding-top: 18px; }

.sh-crumbs { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; font: 600 13px var(--font-body); color: var(--muted); margin-bottom: 14px; }
.sh-crumbs a:hover { color: var(--black); text-decoration: underline; text-underline-offset: 3px; }
.sh-crumbs i { width: 5px; height: 5px; border-right: 1.5px solid currentColor; border-top: 1.5px solid currentColor; transform: rotate(45deg); opacity: .5; }
.sh-crumbs span { color: var(--black); font-weight: 800; }

/* category banner */
.sh-hero {
  position: relative; display: flex; align-items: center; gap: 22px; padding: 28px 32px; border-radius: 26px; overflow: hidden; isolation: isolate;
  background: linear-gradient(120deg, var(--c1, #fff3cf), var(--c2, #f0d070)); color: #111; margin-bottom: 22px;
}
.sh-hero::after { content: ''; position: absolute; inset: 0; z-index: -1; background-image: radial-gradient(rgba(17, 17, 17, .08) 1.2px, transparent 1.4px); background-size: 22px 22px; -webkit-mask-image: linear-gradient(100deg, transparent 40%, #000); mask-image: linear-gradient(100deg, transparent 40%, #000); }
.sh-hero-ico { width: 64px; height: 64px; border-radius: 20px; background: rgba(255, 255, 255, .78); display: grid; place-items: center; flex-shrink: 0; box-shadow: 0 10px 24px rgba(17, 17, 17, .1); }
.sh-hero-ico .kx-icon { width: 30px; height: 30px; }
.sh-hero h1 { font: 400 clamp(26px, 3vw, 38px)/1.05 'LXGW Marker Gothic','Syne',sans-serif;letter-spacing:0;font-synthesis:none;-webkit-text-stroke:.022em currentColor}
.sh-hero p { font: 600 15px/1.5 var(--font-body); color: rgba(17, 17, 17, .66); margin-top: 6px; }
.sh-hero-big { position: absolute; right: 22px; top: 50%; transform: translateY(-50%) rotate(-8deg); z-index: -1; color: rgba(17, 17, 17, .1); }
.sh-hero-big .kx-icon { width: 170px; height: 170px; stroke-width: 1; }

.sh-layout { display: grid; grid-template-columns: 272px minmax(0, 1fr); gap: 28px; align-items: start; }

/* ── Filters ── */
.sh-filters { position: sticky; top: calc(var(--kx-header-h, 72px) + 16px); background: #fff; border: 1px solid rgba(17, 17, 17, .07); border-radius: 22px; padding: 6px 20px 20px; max-height: calc(100vh - var(--kx-header-h, 72px) - 32px); overflow-y: auto; }
.sh-filters-head, .sh-filters-foot { display: none; }
.sh-group { padding: 18px 0; border-bottom: 1px solid rgba(17, 17, 17, .07); }
.sh-group:last-child { border-bottom: 0; }
.sh-group h3 { font: 800 13px var(--font-body); letter-spacing: .04em; text-transform: uppercase; margin-bottom: 12px; display: flex; align-items: baseline; gap: 8px; }
.sh-group h3 small { font-weight: 700; color: var(--kx-faint, #a29e97); letter-spacing: .06em; font-size: 10.5px; }
.sh-cats { display: flex; flex-direction: column; gap: 2px; }
.sh-cat { display: flex; align-items: center; gap: 11px; width: 100%; padding: 9px 10px; border-radius: 11px; border: 0; background: none; font: 600 14px var(--font-body); color: #3a3a3a; text-align: left; transition: background .15s; }
.sh-cat:hover { background: var(--bg); }
.sh-cat .kx-icon { width: 18px; height: 18px; color: var(--muted); flex-shrink: 0; }
.sh-cat b { margin-left: auto; font: 700 12px var(--font-body); color: var(--kx-faint, #a29e97); }
.sh-cat.is-on { background: var(--black); color: #fff; }
.sh-cat.is-on .kx-icon { color: var(--accent); }
.sh-cat.is-on b { color: rgba(255, 255, 255, .6); }
.sh-cat.is-empty { opacity: .5; }

.sh-price { display: flex; align-items: center; gap: 8px; }
.sh-price span { font: 600 12px var(--font-body); color: var(--muted); }
.sh-price input { width: 100%; min-width: 0; height: 42px; border: 1.5px solid rgba(17, 17, 17, .12); border-radius: 11px; padding: 0 12px; font: 700 14px var(--font-body); background: #fff; color: var(--black); transition: border-color .15s; }
.sh-price input:focus { outline: 0; border-color: var(--black); }
.sh-ranges { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 12px; }
.sh-range { height: 34px; padding: 0 13px; border-radius: 99px; border: 1.5px solid rgba(17, 17, 17, .12); background: #fff; font: 700 12.5px var(--font-body); color: #3a3a3a; transition: all .15s; }
.sh-range:hover { border-color: var(--black); }
.sh-range.is-on { background: var(--black); color: #fff; border-color: var(--black); }

.sh-check { display: flex; align-items: center; gap: 11px; padding: 8px 2px; cursor: pointer; font: 600 14px var(--font-body); color: #3a3a3a; }
.sh-check input { position: absolute; opacity: 0; pointer-events: none; }
.sh-box { width: 20px; height: 20px; border-radius: 6px; border: 1.8px solid rgba(17, 17, 17, .25); display: grid; place-items: center; flex-shrink: 0; transition: all .15s; background: #fff; }
.sh-box::after { content: ''; width: 9px; height: 5px; border-left: 2.4px solid #111; border-bottom: 2.4px solid #111; transform: rotate(-45deg) translate(1px, -1px); opacity: 0; }
.sh-check input:checked + .sh-box { background: var(--accent); border-color: var(--accent); }
.sh-check input:checked + .sh-box::after { opacity: 1; }
.sh-check input:focus-visible + .sh-box { outline: 3px solid rgba(240, 195, 60, .9); outline-offset: 2px; }

/* ── Toolbar ── */
.sh-toolbar { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.sh-count { font: 700 15px var(--font-body); color: var(--black); flex: 1; min-width: 0; }
.sh-count span { color: var(--muted); font-weight: 600; }
.sh-sort { display: flex; align-items: center; gap: 10px; font: 700 13px var(--font-body); color: var(--muted); }
.sh-sort select {
  appearance: none; -webkit-appearance: none; height: 44px; padding: 0 38px 0 16px; border-radius: 12px; border: 1.5px solid rgba(17, 17, 17, .12); background-color: #fff; color: var(--black); font: 700 14px var(--font-body); cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23111' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.sh-sort select:focus { outline: 0; border-color: var(--black); }
.sh-filter-btn { display: none; align-items: center; gap: 8px; height: 44px; padding: 0 16px; border-radius: 12px; border: 1.5px solid var(--black); background: #fff; font: 800 13.5px var(--font-body); color: var(--black); }
.sh-filter-btn .kx-icon { width: 17px; height: 17px; }
.sh-filter-btn em { font-style: normal; background: var(--accent); border-radius: 99px; min-width: 20px; height: 20px; display: inline-grid; place-items: center; font-size: 11px; padding: 0 5px; }

.sh-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.sh-chips:empty { display: none; }
.sh-chip { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 8px 0 14px; border-radius: 99px; background: #fff; border: 1.5px solid rgba(17, 17, 17, .12); font: 700 13px var(--font-body); color: var(--black); }
.sh-chip button { width: 22px; height: 22px; border-radius: 50%; border: 0; background: #efebe5; display: grid; place-items: center; color: var(--black); }
.sh-chip button:hover { background: var(--black); color: #fff; }
.sh-chip .kx-icon { width: 12px; height: 12px; stroke-width: 2.8; }
.sh-chip-clear { height: 34px; padding: 0 12px; border: 0; background: none; font: 700 13px var(--font-body); color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.sh-chip-clear:hover { color: var(--black); }

.sh-results .kc-grid { grid-template-columns: repeat(auto-fill, minmax(min(214px,100%), 1fr)); }

.sh-more { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-top: 34px; }
.sh-more p { font: 600 13px var(--font-body); color: var(--muted); }
.sh-more .kx-btn { min-width: 200px; }

.sh-suggest { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 4px; }

.sh-scrim { display: none; }

/* ── Mobile: filters become a sheet ── */
@media (max-width: 1000px) {
  .sh-layout { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .sh-filter-btn { display: inline-flex; }
  .sh-filters {
    position: fixed; z-index: 1001; top: 0; bottom: 0; left: 0; width: min(92vw, 400px); max-height: none; border-radius: 0 24px 24px 0; padding: 0;
    display: flex; flex-direction: column; transform: translateX(-104%); transition: transform .34s cubic-bezier(.3, .8, .3, 1); box-shadow: var(--kx-shadow, 0 18px 48px rgba(17, 17, 17, .16));
  }
  .sh-filters.is-open { transform: none; }
  .sh-filters-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 14px; border-bottom: 1px solid rgba(17, 17, 17, .07); }
  .sh-filters-head h2 { font:400 19px LXGW Marker Gothic,Syne,sans-serif;font-synthesis:none;-webkit-text-stroke:.022em currentColor; letter-spacing: -.035em; }
  .sh-filters-body { flex: 1; overflow-y: auto; padding: 0 20px; }
  .sh-filters-foot { display: flex; gap: 10px; padding: 14px 20px calc(14px + env(safe-area-inset-bottom)); border-top: 1px solid rgba(17, 17, 17, .07); background: #faf9f6; }
  .sh-filters-foot .kx-btn { flex: 1; height: 48px; border-radius: 14px; font-size: 13.5px; padding: 0 12px; }
  .sh-scrim { display: block; position: fixed; inset: 0; z-index: 1000; background: rgba(10, 10, 10, .52); backdrop-filter: blur(2px); opacity: 0; pointer-events: none; transition: opacity .28s; }
  .sh-scrim.is-open { opacity: 1; pointer-events: auto; }
  .sh-sort span { display: none; }
  .sh-results .kc-grid { grid-template-columns: repeat(auto-fill, minmax(min(200px,100%), 1fr)); }
}
@media (max-width: 640px) {
  .sh-page { padding-top: 12px; }
  .sh-hero { padding: 20px 18px; border-radius: 20px; gap: 14px; margin-bottom: 16px; }
  .sh-hero-ico { width: 50px; height: 50px; border-radius: 16px; }
  .sh-hero-ico .kx-icon { width: 24px; height: 24px; }
  .sh-hero p { font-size: 13.5px; }
  .sh-hero-big { display: none; }
  .sh-toolbar { gap: 10px; flex-wrap: wrap; }
  .sh-count { order: 3; flex-basis: 100%; font-size: 14px; }
  .sh-sort { margin-left: auto; }
  .sh-sort select { height: 42px; font-size: 13px; padding-left: 12px; }
  .sh-filter-btn { height: 42px; }
  .sh-results .kc-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
}

/* ── AI search banner ── */
.sh-ai { display: flex; align-items: center; gap: 16px; padding: 16px 20px; margin-bottom: 16px; border-radius: 20px; border: 1px solid rgba(240, 195, 60, .5);
  background: linear-gradient(120deg, #fff8dc 0%, #ffeee0 55%, #f4eaff 100%); position: relative; overflow: hidden; }
.sh-ai[hidden] { display: none; }
.sh-ai-orb { width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; background: conic-gradient(from 160deg, #f0c33c, #ff7a45, #e254ff, #4cc9f0, #f0c33c); position: relative; box-shadow: 0 6px 16px rgba(226, 84, 255, .25); }
.sh-ai-orb::before { content: ''; position: absolute; width: 32px; height: 32px; border-radius: 50%; background: rgba(255, 255, 255, .92); }
.sh-ai-orb .kx-icon { position: relative; width: 19px; height: 19px; stroke-width: 2.3; }
.sh-ai-main { flex: 1; min-width: 0; }
.sh-ai-main b { font: 700 15px var(--f-ui, var(--font-body)); }
.sh-ai-main em { font-style: normal; font-weight: 700; }
.sh-ai-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.sh-ai-chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 11px 0 9px; border-radius: 99px; background: rgba(255, 255, 255, .88); border: 1px solid rgba(17, 17, 17, .1); font: 500 12.5px var(--f-ui, var(--font-body)); }
.sh-ai-chip .kx-icon { width: 13px; height: 13px; color: #b88a00; }
.sh-ai-plain { font: 700 12.5px var(--f-ui, var(--font-body)); color: var(--muted); text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.sh-ai-plain:hover { color: var(--black); }
@media (max-width: 640px) { .sh-ai { flex-wrap: wrap; padding: 14px 16px; gap: 12px; } .sh-ai-plain { margin-left: 52px; } }
.sh-ai-note { margin: 6px 0 0; font: 400 14px/1.5 var(--f-body, Lato, sans-serif); color: #5a4a14; }

/* AI is still reading the search: the orb spins and the banner breathes */
.sh-ai.is-loading .sh-ai-orb { animation: shAiSpin 1.1s linear infinite; }
.sh-ai.is-loading { animation: shAiPulse 1.6s ease-in-out infinite; }
@keyframes shAiSpin { to { transform: rotate(360deg); } }
@keyframes shAiPulse { 50% { opacity: .72; } }
@media (prefers-reduced-motion: reduce) { .sh-ai.is-loading, .sh-ai.is-loading .sh-ai-orb { animation: none; } }

/* "We don't have it" card above the similar items */
.sh-nf { display: flex; align-items: center; gap: 16px; padding: 18px 20px; border-radius: 20px; background: #fff; border: 1.5px dashed rgba(17, 17, 17, .22); }
.sh-nf-ico { width: 46px; height: 46px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; background: var(--kx-bg, #f4f1ea); }
.sh-nf-ico .kx-icon { width: 21px; height: 21px; }
.sh-nf-body b { display: block; font: 400 19px 'LXGW Marker Gothic', 'Syne', sans-serif; -webkit-text-stroke: .02em currentColor; }
.sh-nf-body p { margin: 4px 0 0; font: 500 14px/1.5 var(--kx-font-b, Lato, sans-serif); color: #6d6a65; }
@media (max-width: 520px) { .sh-nf { padding: 14px 16px; gap: 12px; } .sh-nf-body b { font-size: 17px; } }

.sec-head .sec-more { align-self: center; font: 800 13px var(--kx-font-b, Lato, sans-serif); color: #111; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.sh-searching [data-plus="mini"], .sh-searching [data-gift="mini"] { display: none !important; }
