/* Native WooCommerce archives: category navigation stays inside the catalog. */
.shop-layout {
    --catalog-top: 24px;
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    align-items: start;
    gap: 32px;
    margin-top: 32px;
}
.admin-bar .shop-layout { --catalog-top: calc(24px + var(--wp-admin--admin-bar--height, 32px)); }
.shop-sidebar {
    position: sticky;
    top: var(--catalog-top);
    min-width: 0;
    z-index: 10;
}
.shop-categories {
    max-height: calc(100vh - var(--catalog-top) - 24px);
    max-height: calc(100dvh - var(--catalog-top) - 24px);
    overflow: auto;
    scrollbar-width: thin;
    scrollbar-color: var(--border) transparent;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}
.shop-categories summary {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 60px;
    padding: 16px 20px;
    list-style: none;
    cursor: pointer;
}
.shop-categories summary::-webkit-details-marker { display: none; }
.shop-categories-title { font-weight: 750; color: var(--navy); }
.shop-categories-current { display: none; }
.shop-categories-toggle { display: inline-flex; margin-left: auto; flex: 0 0 20px; color: var(--muted); }
.shop-categories-toggle svg { width: 20px; height: 20px; transition: transform .18s ease; }
.shop-categories[open] .shop-categories-toggle svg { transform: rotate(180deg); }
.shop-categories[open] summary { border-bottom: 1px solid var(--border); }
.shop-category-list { list-style: none; margin: 0; padding: 12px; display: grid; gap: 8px; }
.shop-category-list li { margin: 0; padding: 0; min-width: 0; }
.shop-category-link {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 52px;
    padding: 10px 12px;
    border: 1px solid transparent;
    border-radius: 10px;
    color: var(--ink);
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .18s ease, border-color .18s ease, color .18s ease;
}
.shop-category-link:hover { color: var(--blue); background: var(--page); border-color: var(--border); }
.shop-category-link[aria-current="page"] { color: var(--blue); background: color-mix(in srgb, var(--blue) 8%, var(--surface)); border-color: var(--blue); font-weight: 750; }
.shop-category-icon { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; flex: 0 0 30px; }
.shop-category-icon img { width: 30px; height: 30px; border-radius: 7px; object-fit: cover; }
.shop-category-icon svg { width: 24px; height: 24px; }
.shop-category-name { min-width: 0; overflow-wrap: anywhere; }
.shop-category-indicator { display: inline-flex; margin-left: auto; flex: 0 0 18px; }
.shop-category-indicator svg { width: 18px; height: 18px; }
.shop-categories summary:focus-visible, .shop-category-link:focus-visible { outline: 3px solid var(--blue); outline-offset: -3px; }
.shop-results { min-width: 0; display: flow-root; }
.shop-results .woocommerce-products-header {
    position: relative;
    isolation: isolate;
    margin-bottom: 24px;
    padding: 30px;
    overflow: hidden;
    border: 1px solid color-mix(in srgb,var(--navy) 44%,var(--muted));
    border-radius: 20px;
    background: radial-gradient(ellipse at 95% 0, color-mix(in srgb,color-mix(in srgb,var(--cyan) 38%,var(--ink)) 43.92%,transparent), transparent 65%), var(--navy);
    color: #fff;
}
.shop-results .woocommerce-products-header::before {
    content: '';
    position: absolute;
    z-index: -1;
    inset: 0;
    background: var(--media-network,url("../icons/ecosystem-network.svg")) center / cover no-repeat;
    opacity: .18;
    pointer-events: none;
}
.shop-results .woocommerce-products-header__title { overflow-wrap: anywhere; color: #fff; font-size: 34px; line-height: 1.35; margin: 0 0 14px; }
.shop-results .term-description, .shop-intro-copy { max-width: 65ch; color: color-mix(in srgb,var(--muted) 14%,var(--border)); font-size: 15px; line-height: 1.7; margin-bottom: 20px; }
.shop-results .term-description p { margin: 0 0 16px; }
.shop-product-search { margin: 20px 0 0; }
.shop-search-label { display: block; margin-bottom: 10px; color: color-mix(in srgb,var(--blue) 9%,var(--page)); font-size: 13px; font-weight: 600; }
.shop-search-controls { display: flex; gap: 10px; }
.shop-search-controls input[type="search"] { min-width: 0; flex: 1; width: 100%; border: 1px solid color-mix(in srgb,var(--muted) 35%,var(--border)); border-radius: 9px; background: var(--surface); padding: 12px 16px; min-height: 48px; color: var(--ink); font-size: 16px; }
.shop-search-controls input::placeholder { color: var(--muted); opacity: 1; }
.shop-search-controls button { display: inline-flex; justify-content: center; align-items: center; gap: 8px; flex: 0 0 auto; min-height: 48px; padding: 10px 20px; background: var(--cyan); color: var(--navy); border: 1px solid var(--cyan); border-radius: 9px; font-size: 14px; font-weight: 650; cursor: pointer; }
.shop-search-controls button:hover { background: color-mix(in srgb,var(--cyan) 51%,var(--surface)); border-color: color-mix(in srgb,var(--cyan) 51%,var(--surface)); }
.shop-search-controls button svg { width: 20px; height: 20px; }
.shop-search-controls :focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.shop-search-reset { display: inline-flex; align-items: center; min-height: 44px; margin-top: 8px; color: color-mix(in srgb,var(--cyan) 46%,var(--page)); font-size: 14px; text-underline-offset: 4px; }
.shop-search-reset:hover { color: #fff; }
.shop-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; padding-bottom: 18px; margin-bottom: 24px; border-bottom: 1px solid var(--border); }
.woocommerce .shop-toolbar .woocommerce-result-count { float: none; margin: 0; padding: 0; color: var(--muted); font-size: 14px; }
.woocommerce .shop-toolbar .woocommerce-ordering { float: none; margin: 0; }
.shop-toolbar .woocommerce-ordering select { border-radius: 9px; font-size: 14px; max-width: 255px; }
.woocommerce .shop-results ul.products { gap: 22px; }
.woocommerce .shop-results ul.products li.product { min-width: 0; padding: 20px; border-radius: 18px; border: 1px solid var(--border); transition: border-color .2s ease, box-shadow .2s ease; }
.woocommerce .shop-results ul.products li.product:hover, .woocommerce .shop-results ul.products li.product:focus-within { border-color: color-mix(in srgb,var(--blue) 36%,var(--border)); box-shadow: 0 12px 32px color-mix(in srgb,color-mix(in srgb,var(--blue) 36%,var(--ink)) 6.27%,transparent); }
.woocommerce .shop-results ul.products li.product a.woocommerce-loop-product__link { min-width: 0; overflow-wrap: anywhere; display: flex; flex-direction: column; flex: 1; }
.woocommerce .shop-results ul.products li.product a img { width: 100%; aspect-ratio: 1.7; object-fit: contain; border-radius: 12px; margin: 0 0 18px; background: radial-gradient(ellipse at center, color-mix(in srgb,var(--blue) 9%,var(--surface)), color-mix(in srgb,var(--page) 87%,var(--surface)) 75%); }
.shop-product-category { display: inline-flex; align-self: flex-start; max-width: 100%; overflow-wrap: anywhere; border-radius: 6px; padding: 4px 9px; margin-bottom: 12px; background: color-mix(in srgb,var(--blue) 7%,var(--surface)); color: color-mix(in srgb,var(--blue) 37%,var(--muted)); font-size: 12px; font-weight: 600; line-height: 1.7; }
.woocommerce .shop-results ul.products li.product .onsale { position: static; align-self: flex-start; margin: 0 0 12px; border-radius: 6px; }
.woocommerce .shop-results ul.products li.product .woocommerce-loop-product__title { color: var(--navy); font-size: 19px; line-height: 1.5; padding: 0; margin: 0 0 10px; }
.woocommerce .shop-results ul.products li.product .price { color: var(--blue); font-size: 25px; line-height: 1.4; font-weight: 750; margin: 0 0 12px; font-variant-numeric: tabular-nums; }
.woocommerce .shop-results ul.products li.product .price del { display: inline; color: var(--muted); font-size: 15px; font-weight: 400; opacity: 1; }
.shop-results .product-excerpt { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; font-size: 14px; line-height: 1.7; color: var(--muted); margin: 0 0 18px; }
.shop-product-actions { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; margin-top: auto; padding-top: 16px; border-top: 1px solid var(--border); }
.woocommerce .shop-product-actions .button { display: inline-flex; grid-column: 1; grid-row: 1; align-items: center; justify-content: center; min-height: 46px; margin: 0; padding: 10px 12px; border-radius: 9px; font-size: 13px; line-height: 1.6; text-align: center; width: auto; }
.shop-product-details { display: inline-flex; grid-column: 2; grid-row: 1; align-items: center; justify-content: center; min-height: 46px; border: 1px solid var(--border); padding: 10px; color: var(--ink); background: var(--surface); border-radius: 9px; font-size: 13px; line-height: 1.6; font-weight: 600; text-decoration: none; text-align: center; }
.shop-product-details:hover { border-color: var(--blue); color: var(--blue); background: var(--page); }
.shop-product-actions > .button:only-child { grid-column: 1 / -1; }
.woocommerce .shop-product-actions .button.added::after { margin-left: 6px; }
.woocommerce .shop-product-actions .added_to_cart { display: flex; justify-content: center; align-items: center; grid-column: 1 / -1; min-height: 44px; padding: 9px; background: #ecf7f3; border-radius: 8px; color: #17644c; text-decoration: underline; text-underline-offset: 3px; font-size: 14px; font-weight: 600; }
.shop-product-actions > a { min-width: 0; overflow-wrap: anywhere; }
.shop-product-actions a:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.shop-help-link { display: flex; align-items: center; gap: 10px; min-height: 50px; border-top: 1px solid var(--border); margin: 4px 12px 0; padding: 12px; color: var(--blue); font-size: 13px; line-height: 1.6; text-decoration: none; font-weight: 600; }
.shop-help-link:hover { text-decoration: underline; text-underline-offset: 4px; }
.shop-help-link svg { width: 18px; height: 18px; flex-shrink: 0; }
.shop-empty-help { padding: 28px; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); }
.shop-empty-help p { color: var(--muted); margin-bottom: 16px; }
.shop-empty-help a { display: inline-flex; align-items: center; min-height: 44px; color: var(--blue); text-underline-offset: 4px; font-weight: 600; }
.shop-results .woocommerce-pagination { margin-top: 32px; }
.shop-results .woocommerce-pagination ul { display: inline-flex; flex-wrap: wrap; max-width: 100%; gap: 8px; border: 0; }
.shop-results .woocommerce-pagination ul li { border: 0; }
.shop-results .woocommerce-pagination ul li :is(a,span) { display: grid; place-items: center; min-width: 44px; min-height: 44px; padding: 9px; border: 1px solid var(--border); border-radius: 9px; color: var(--ink); background: var(--surface); }
.shop-results .woocommerce-pagination ul li span.current { background: var(--blue); color: #fff; border-color: var(--blue); }
@media (min-width: 1001px) and (max-width: 1199px) {
    .shop-layout { grid-template-columns: 216px minmax(0, 1fr); gap: 24px; }
    .woocommerce .shop-results ul.products { grid-template-columns: repeat(min(var(--shop-columns,3),2), minmax(0, 1fr)); }
}
@media (max-width: 1000px) {
    .shop-layout { --catalog-top: 12px; grid-template-columns: minmax(0, 1fr); gap: 24px; margin-top: 24px; }
    .admin-bar .shop-layout { --catalog-top: calc(12px + var(--wp-admin--admin-bar--height, 32px)); }
    .shop-categories { box-shadow: 0 8px 24px color-mix(in srgb,var(--ink) 7.84%,transparent); }
    .shop-categories summary { display: grid; grid-template-columns: auto minmax(0, 1fr) 20px; padding: 12px 16px; min-height: 56px; }
    .shop-categories-title { font-size: 14px; }
    .shop-categories-current { display: inline; color: var(--blue); font-weight: 750; font-size: 15px; text-align: right; overflow-wrap: anywhere; }
    .shop-categories-toggle { margin-left: 0; }
    .shop-category-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .woocommerce .shop-results ul.products { grid-template-columns: repeat(min(var(--shop-columns,3),2), minmax(0, 1fr)); }
    .shop-results :is(a, button, input, select, textarea) { scroll-margin-top: calc(var(--catalog-top) + 80px); }
}
@media (max-width: 600px) {
    .admin-bar .shop-layout { --catalog-top: 12px; }
    .shop-category-list { grid-template-columns: minmax(0, 1fr); }
    .shop-results .woocommerce-products-header { padding: 24px; border-radius: 16px; }
    .shop-results .woocommerce-products-header__title { font-size: 28px; }
    .shop-search-controls { gap: 8px; }
    .shop-search-controls input[type="search"] { padding-inline: 10px; }
    .shop-search-controls button { padding-inline: 12px; }
    .shop-search-controls button svg { display: none; }
    .shop-toolbar { gap: 12px; }
    .shop-toolbar .woocommerce-ordering, .shop-toolbar .woocommerce-ordering select { width: 100%; max-width: none; }
    .shop-results .term-description, .shop-intro-copy { font-size: 16px; }
    .shop-results .product-excerpt { font-size: 16px; }
}
@media (max-width: 640px) {
    .woocommerce .shop-results ul.products { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
    .shop-category-link, .shop-categories-toggle svg, .woocommerce .shop-results ul.products li.product { transition: none; }
}

body.vnaipro-shop-not-sticky .shop-sidebar{position:static}
body.vnaipro-shop-not-sticky .shop-categories{max-height:none;overflow:visible}
