/* kudikiuprekes.lt - listing (category) v2. Page additions on top of home.css (tokens, header, footer, .pc cards). 2026-09-23 */
/* metric-matched fallback so the Nunito swap does not move the layout (CLS) - same as product.css */
@font-face { font-family: "Nunito Fallback"; src: local("Arial"), local("Liberation Sans"), local("Helvetica"), local("Roboto"); size-adjust: 86%; ascent-override: 117.5%; descent-override: 41%; line-gap-override: 0%; }
body.lv-page { --font: "Nunito", "Nunito Fallback", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
/* same container as the header (.wrap / --wrap) so the edges line up on wide screens */
.lv-wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
.lv { padding-bottom: 8px; }

/* ---------- breadcrumbs ---------- */
.lv-crumbs { padding-top: 12px; font-size: 13px; }
.v2 .lv-crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; white-space: nowrap; }
.lv-crumbs ol::-webkit-scrollbar { display: none; }
.lv-crumbs li { display: inline-flex; align-items: center; color: var(--muted); }
.lv-crumbs li + li::before { content: ""; width: 6px; height: 6px; margin: 0 8px; border-right: 1.5px solid #b3bcc3; border-top: 1.5px solid #b3bcc3; transform: rotate(45deg); flex: none; }
.lv-crumbs a { color: var(--ink-soft); font-weight: 600; display: inline-flex; align-items: center; min-height: 32px; }
.lv-crumbs [aria-current] { color: var(--ink); font-weight: 700; }

/* ---------- head ---------- */
.lv-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; padding-top: 6px; }
.lv-head h1 { font-size: clamp(24px, 6vw, 36px); font-weight: 800; letter-spacing: -.01em; }
.lv-h1-suffix { color: var(--ink-soft); font-weight: 700; font-size: .7em; }
.lv-count { margin: 0; color: var(--muted); font-weight: 700; font-size: 14px; }

.lv-desc { margin-top: 8px; max-width: 60em; color: var(--ink-soft); font-size: 15px; }
.lv-desc-text p { margin: 0 0 6px; }
.lv-desc.is-long:not(.is-open) .lv-desc-text { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lv-desc.is-long:not(.is-open) .lv-desc-text p { margin: 0; }
@media (min-width: 768px) { .lv-desc.is-long:not(.is-open) .lv-desc-text { -webkit-line-clamp: 3; } }
.lv-more { background: none; border: 0; padding: 0 4px; margin-left: -4px; min-height: 44px; color: var(--link); font-weight: 800; cursor: pointer; }
.lv-more:hover { text-decoration: underline; }

/* ---------- sub-category chips: scroll + edge fade on mobile, wrapped on desktop ---------- */
.lv-subcats { margin: 12px calc(-1 * var(--gutter)) 0; }
.v2 ul.lv-chips {
    display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; overscroll-behavior-x: contain;
    margin: 0; padding: 4px var(--gutter) 6px;
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 var(--gutter), #000 calc(100% - 40px), transparent);
            mask-image: linear-gradient(to right, transparent 0, #000 var(--gutter), #000 calc(100% - 40px), transparent);
}
.lv-chips::-webkit-scrollbar { display: none; }
.lv-chips li { flex: none; }
.lv-chips .chip { min-height: 44px; background: var(--surface); }
.lv-chips .chip.is-current { background: var(--primary); border-color: var(--primary); color: #fff !important; }

/* ---------- admin strip ---------- */
.lv-admin { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; margin-top: 12px; padding: 6px 14px; border-radius: var(--r-sm); background: var(--lilac); font-size: 13px; font-weight: 700; color: var(--ink-soft); }
.lv-admin a { display: inline-flex; align-items: center; min-height: 36px; font-weight: 800; }

/* ---------- layout ---------- */
.lv-layout { display: block; margin-top: 12px; }
.lv-main { min-width: 0; }

/* ---------- toolbar ---------- */
.lv-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 0; position: relative; z-index: 5; }
.lv-filter-btn { gap: 8px; flex: 1 1 0; max-width: 50%; }
.lv-filter-btn svg { flex: none; }
.lv-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: var(--pill); background: var(--accent); color: var(--ink); font-size: 12px; font-weight: 800; }
.lv-sort { position: relative; flex: 1 1 0; display: flex; justify-content: flex-end; }
.lv-sort summary { list-style: none; width: 100%; justify-content: space-between; gap: 6px; padding-left: 16px; padding-right: 14px; font-size: 14px; }
.lv-sort summary::-webkit-details-marker { display: none; }
.lv-sort summary svg { transform: rotate(90deg); transition: transform .15s ease; flex: none; }
.lv-sort[open] summary svg { transform: rotate(-90deg); }
.lv-sort-k { display: none; color: var(--ink-soft); font-weight: 600; }
.lv-sort-v { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.v2 .lv-sort-menu {
    position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; min-width: 220px; padding: 6px;
    background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow-lg); border: 1px solid var(--line);
}
.lv-sort-menu a { display: flex; align-items: center; min-height: 44px; padding: 8px 14px; border-radius: var(--r-sm); color: var(--ink) !important; font-weight: 700; font-size: 15px; }
.lv-sort-menu a:hover { background: var(--sky); text-decoration: none; }
.lv-sort-menu a.is-current { background: var(--sky); color: var(--primary) !important; }
.lv-sort-menu a.is-current::after { content: ""; width: 6px; height: 11px; margin-left: auto; border-right: 2.5px solid currentColor; border-bottom: 2.5px solid currentColor; transform: rotate(45deg) translateY(-2px); }

/* ---------- active filter pills ---------- */
.lv-pills-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 2px 0 10px; }
.v2 ul.lv-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.lv-pill { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 6px 12px 6px 16px; border-radius: var(--pill); background: var(--sky); border: 1px solid #cfe9f6; color: var(--primary) !important; font-weight: 700; font-size: 14px; }
.lv-pill:hover { background: #d9f0fb; text-decoration: none !important; }
.lv-clear { display: inline-flex; align-items: center; min-height: 44px; font-weight: 800; font-size: 14px; }

/* ---------- grid ---------- */
.v2 ul.lv-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.lv-item { min-width: 0; }
/* legacy sizes: half = one product slot (col-md-4), full = two slots (col-md-8) */
.lv-banner { grid-column: span 1; min-width: 0; border-radius: var(--r); overflow: hidden; background: var(--surface); box-shadow: var(--shadow-sm); display: flex; align-items: center; justify-content: center; }
.lv-banner.is-full { grid-column: span 2; }
.lv-banner a { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }
.lv-banner img { display: block; width: 100%; height: 100%; object-fit: contain; }
.lv-banner.hide-mobile { display: none; }
.lv-empty { padding: 32px 20px; border-radius: var(--r-lg); background: var(--butter); text-align: center; }
.lv-empty p { margin: 4px 0; }

/* card additions (listing only) */
.lv .pc { position: relative; }
.lv .pc-body { padding: 10px 10px 12px; }
.lv .pc-title { font-size: 13.5px; }
.lv .pc-now { font-size: 17px; }
.pc-fav {
    position: absolute; top: 6px; right: 6px; z-index: 2;
    display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0;
    border: 0; border-radius: 50%; background: rgba(255, 255, 255, .92); color: var(--ink-soft) !important; cursor: pointer;
    box-shadow: var(--shadow-sm);
}
.pc-fav:hover { color: #d6336c !important; text-decoration: none !important; }
.pc-fav.is-on { color: #d6336c !important; }
.pc-fav.is-on { background: var(--blush); box-shadow: 0 0 0 2px #f6c6d3; }
.pc-fav[disabled] { opacity: .6; }
.pc-sold {
    position: absolute; left: 10px; bottom: 10px;
    padding: 3px 10px; border-radius: var(--pill); background: rgba(54, 54, 54, .82); color: #fff; font-weight: 800; font-size: 12px;
}
.pc.is-out .pc-media img { opacity: .55; filter: grayscale(.35); }

/* ---------- pagination / load more ---------- */
.lv-pager-wrap { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 24px 0 8px; }
.lv-loadmore { min-width: 220px; }
.lv-loadmore[aria-busy="true"] { opacity: .7; cursor: progress; }
.v2 .lv-pager ul { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.lv-pg {
    display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 44px; padding: 0 10px;
    border-radius: var(--pill); background: var(--surface); border: 1px solid var(--line);
    color: var(--ink) !important; font-weight: 800; font-size: 15px;
}
a.lv-pg:hover { background: var(--sky); border-color: #cfe9f6; text-decoration: none !important; }
.lv-pg.is-current { background: var(--primary); border-color: var(--primary); color: #fff !important; }
.lv-pg.is-gap { background: transparent; border-color: transparent; min-width: 24px; padding: 0; color: var(--muted) !important; }
.lv-pg.is-off { opacity: .35; }
.lv-pager-info { margin: 0; color: var(--muted); font-size: 13px; font-weight: 600; }

/* ---------- SEO text ---------- */
.lv-seo { padding-top: 28px; padding-bottom: 12px; }
.lv-seo h2 { font-size: 20px; font-weight: 800; margin-bottom: 8px; }
.lv-seo-body { max-width: 60em; color: var(--ink-soft); font-size: 15px; overflow-wrap: anywhere; }
.lv-seo-body img { border-radius: var(--r-sm); }

/* ---------- filters: mobile/tablet bottom sheet ---------- */
.lv-filters { display: none; }
.lv-filters:target, .lv-filters.is-open { display: block; position: fixed; inset: 0; z-index: 65; }
.lv-sheet-backdrop { position: absolute; inset: 0; background: rgba(30, 45, 60, .45); }
.lv-sheet {
    position: absolute; left: 0; right: 0; bottom: 0; max-height: 88vh; max-height: 88dvh;
    display: flex; flex-direction: column;
    background: var(--surface); border-radius: var(--r-lg) var(--r-lg) 0 0; box-shadow: var(--shadow-lg);
    animation: lvUp .22s ease-out;
}
@keyframes lvUp { from { transform: translateY(100%); } to { transform: none; } }
.lv-sheet-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 8px 6px 20px; border-bottom: 1px solid var(--line); }
.lv-sheet-head h2 { font-size: 20px; font-weight: 800; }
.lv-sheet-body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 4px 20px 12px; }
.lv-sheet-foot { display: flex; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--surface); }
.lv-sheet-foot .btn { flex: 1; }
.lv-sheet-foot .btn-primary { flex: 2; }
.lv-sheet-foot .btn-primary[aria-busy="true"] { opacity: .75; }
body.lv-sheet-open { overflow: hidden; }

.lv-group { border-bottom: 1px solid var(--line); }
.lv-group:last-child { border-bottom: 0; }
.lv-group summary {
    list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 8px;
    min-height: 52px; cursor: pointer; font-weight: 800; font-size: 16px;
}
.lv-group summary::-webkit-details-marker { display: none; }
.lv-group summary svg { transform: rotate(90deg); transition: transform .15s ease; color: var(--muted); flex: none; }
.lv-group[open] summary svg { transform: rotate(-90deg); }
.v2 ul.lv-opts { padding-bottom: 10px; }
.v2 ul.lv-opts-scroll { max-height: 300px; overflow-y: auto; overscroll-behavior: contain; margin-right: -8px; padding-right: 8px; }
.lv-opt, .lv-opts-scroll label { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 2px 0; cursor: pointer; font-size: 15px; }
.lv-opt input, .lv-opts-scroll input { flex: none; width: 22px; height: 22px; margin: 0; accent-color: var(--primary); }
.lv-opt > span, .lv-opts-scroll label > span { flex: 1; min-width: 0; overflow-wrap: anywhere; line-height: 1.3; }
.lv-opt > .lv-opt-n { flex: none; min-width: 28px; padding: 1px 8px; border-radius: var(--pill); background: var(--bg); border: 1px solid var(--line); color: var(--muted); font-size: 12px; font-weight: 700; text-align: center; }
.lv-opt:hover > span:first-of-type, .lv-opts-scroll label:hover > span { color: var(--primary); }

/* ---------- >= 480px ---------- */
@media (min-width: 480px) {
    .lv-sort-k { display: inline; }
    .lv-filter-btn { flex: 0 0 auto; }
    .lv-sort { flex: 0 1 auto; }
    .lv-sort summary { width: auto; }
}

/* ---------- >= 768px ---------- */
@media (min-width: 768px) {
    .v2 ul.lv-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
    .lv-banner.hide-mobile { display: flex; }
    .lv .pc-title { font-size: 14px; }
    .lv .pc-now { font-size: 18px; }
    .lv .pc-body { padding: 10px 12px 12px; }
    .lv-sheet { left: auto; top: 0; width: min(420px, 90vw); max-height: none; border-radius: var(--r-lg) 0 0 var(--r-lg); animation-name: lvIn; }
    @keyframes lvIn { from { transform: translateX(100%); } to { transform: none; } }
}

/* ---------- >= 1024px: sticky sidebar ---------- */
@media (min-width: 1024px) {
    .lv-subcats { margin-left: 0; margin-right: 0; }
    .v2 ul.lv-chips { flex-wrap: wrap; justify-content: center; overflow: visible; padding-left: 0; padding-right: 0; -webkit-mask-image: none; mask-image: none; }
    .lv-layout { display: grid; grid-template-columns: 256px minmax(0, 1fr); gap: 28px; align-items: start; }
    .lv-layout.no-side { grid-template-columns: minmax(0, 1fr); }
    .lv-filters, .lv-filters:target, .lv-filters.is-open { display: block; inset: auto; position: sticky; top: var(--lv-sticky, 90px); z-index: 1; }
    .lv-sheet-backdrop, .lv-sheet-head .icon-btn { display: none; }
    .lv-sheet { position: static; width: auto; max-height: calc(100vh - var(--lv-sticky, 90px) - 16px); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); animation: none; }
    .lv-sheet-head { padding: 12px 16px 8px; }
    .lv-sheet-head h2 { font-size: 18px; }
    .lv-sheet-body { padding: 0 16px 8px; }
    .lv-sheet-foot { padding: 10px 12px; border-radius: 0 0 var(--r-lg) var(--r-lg); }
    .js .lv-sheet-foot .btn-primary { display: none; }
    .lv-filter-btn { display: none; }
    .lv-toolbar { justify-content: flex-end; padding-top: 0; }
    body.lv-sheet-open { overflow: auto; }
    .v2 ul.lv-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .v2 .no-side ul.lv-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1200px) {
    .v2 ul.lv-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1440px) {
    /* container is capped at --wrap (1280): 4 columns next to the sidebar, 5 without it */
    .v2 .no-side ul.lv-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
    .lv-sheet { animation: none !important; }
}

/* custom lists (sale/new/popular/search) - search empty state */
.lv-empty .lv-tips { max-width: 520px; margin: 12px auto 18px; padding-left: 20px; text-align: left; }
.lv-empty .lv-tips li { margin: 4px 0; }
.v2 .lv-empty ul.lv-chips { flex-wrap: wrap; justify-content: center; margin-top: 10px; overflow: visible; -webkit-mask-image: none; mask-image: none; }
/* brand pages (/visi-gamintojai?brand=) - logo above the H1 */
.lv-head .lv-brand-logo { display: block; flex-basis: 100%; width: 160px; max-width: 160px; height: 80px; object-fit: contain; object-position: left center; }
