/* Shop, category and Sale pages (approved AYRAERYNA category mockup, END. layout): centred title and description,
   the results row, the filter panel, the 4 / 6 column buttons. The product card itself is in shop.css; the on-photo sale
   countdown and the sold bar are printed by IGSHOP Shop Kit (its own CSS), restyled in the last section.
   Class names start with ay- so they never meet a plugin's (.ay-wa, the WhatsApp button, is taken). */

/* Hello Elementor centres .site-main at 1140px; shop pages run edge to edge. */
.woocommerce.archive .site-main { width: 100%; max-width: none; padding-inline: 0; }
.woocommerce-products-header { display: none; }          /* WooCommerce's own title block; ours is .ay-cat-head */
.woocommerce .woocommerce-notices-wrapper:empty { display: none; }

/* ---------------------------------------------------------------- title + description */
.ay-cat-head { padding: 40px var(--ay-gut) 0; text-align: center; }
.ay-cat-head h1 { margin: 0 0 14px; font-size: clamp(28px, 3.2vw, 44px); font-weight: 600; line-height: 1.1; letter-spacing: .1em; text-transform: uppercase; color: var(--ay-ink); }
.ay-cat-desc { width: 100%; margin: 0 auto; font-size: 16px; line-height: 1.7; color: var(--ay-ink-2); text-wrap: balance; }
.ay-cat-desc p { margin: 0; }

/* ---------------------------------------------------------------- results row */
.ay-tb { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 34px var(--ay-gut) 16px; }
.ay-tb-l, .ay-tb-r { display: flex; align-items: center; gap: 22px; }
.ay-tb-filter { height: 38px; padding: 0 16px; border: 1px solid var(--ay-line-2); border-radius: 0; background: #fff; font: 600 11.5px/1 var(--ay-sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ay-ink); cursor: pointer; transition: border-color .2s; }
.ay-tb-filter:hover, .ay-tb-filter[aria-expanded="true"] { border-color: var(--ay-ink); background: #fff; color: var(--ay-ink); }
.ay-tb-count { margin: 0; font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ay-muted); }
.ay-tb-sort { position: relative; display: flex; align-items: center; gap: 8px; margin: 0; font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ay-muted); }
.ay-tb-sort select { appearance: none; -webkit-appearance: none; width: auto; margin: 0; padding: 6px 22px 6px 0; border: 0; background: none; font: 600 11.5px/1.2 var(--ay-sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ay-ink); cursor: pointer; }
.ay-tb-sort svg { position: absolute; right: 0; pointer-events: none; }
.ay-tb-cols { display: flex; gap: 6px; }
.ay-tb-cols button { width: 30px; height: 28px; padding: 0; border: 0; border-radius: 0; background: var(--ay-wash); font: 400 12px/1 var(--ay-sans); color: var(--ay-ink-2); cursor: pointer; }
.ay-tb-cols .is-on { background: var(--ay-ink); color: #fff; }

/* ---------------------------------------------------------------- filter panel */
.ay-filters { margin-bottom: 18px; padding: 8px var(--ay-gut) 28px; border-top: 1px solid var(--ay-line); border-bottom: 1px solid var(--ay-line); background: #fff; }
.ay-filters[hidden] { display: none; }
.ay-f-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 28px clamp(24px, 4vw, 64px); padding-top: 22px; }
.ay-filters h3 { margin: 0 0 14px; font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--ay-ink); }
.ay-f-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ay-f-chip { position: relative; margin: 0; }
.ay-f-chip input, .ay-f-row input { position: absolute; opacity: 0; pointer-events: none; }
.ay-f-chip span { display: grid; place-items: center; min-width: 44px; height: 40px; padding: 0 10px; border: 1px solid var(--ay-line-2); font-size: 13.5px; color: var(--ay-ink); cursor: pointer; }
.ay-f-chip input:checked + span { background: var(--ay-ink); border-color: var(--ay-ink); color: #fff; }
.ay-f-chip input:focus-visible + span, .ay-f-row input:focus-visible + span { outline: 2px solid var(--ay-ink); outline-offset: 2px; }
.ay-f-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.ay-f-col { position: relative; display: flex; align-items: center; gap: 10px; margin: 0; font-size: 14px; color: var(--ay-ink); cursor: pointer; }
.ay-f-col input { position: absolute; opacity: 0; pointer-events: none; }
.ay-f-col i { flex: none; width: 22px; height: 22px; box-sizing: border-box; border: 1px solid var(--ay-line-2); border-radius: 50%; }
.ay-f-col input:checked + i { outline: 2px solid var(--ay-ink); outline-offset: 2px; }
.ay-f-col input:focus-visible + i { outline: 2px solid var(--ay-ink); outline-offset: 4px; }
.ay-f-row { position: relative; display: block; margin: 0 0 10px; font-size: 14px; color: var(--ay-ink); cursor: pointer; }
.ay-f-row span { position: relative; display: block; padding-left: 28px; line-height: 18px; }
.ay-f-row span::before { content: ""; position: absolute; left: 0; top: 0; width: 18px; height: 18px; box-sizing: border-box; border: 1px solid var(--ay-line-2); background: #fff; }
.ay-f-row input:checked + span::before { background: var(--ay-ink); border-color: var(--ay-ink); }
.ay-f-row input:checked + span::after { content: ""; position: absolute; left: 6px; top: 3px; width: 5px; height: 9px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.ay-f-act { display: flex; justify-content: flex-end; align-items: center; gap: 20px; margin-top: 24px; }
.ay-f-clear { font-size: 13px; text-decoration: underline; text-underline-offset: 4px; color: var(--ay-ink-2); }
.ay-f-apply { min-height: 44px; padding: 0 24px; border: 1px solid var(--ay-ink); border-radius: 0; background: var(--ay-ink); font: 600 12px/1 var(--ay-sans); letter-spacing: .1em; text-transform: uppercase; color: #fff; cursor: pointer; }
.ay-f-apply:hover { background: var(--ay-hover); color: #fff; }

/* ---------------------------------------------------------------- grid columns (the 4 / 6 buttons) */
body.woocommerce.archive ul.products[data-cols="6"] { grid-template-columns: repeat(6, minmax(0, 1fr)); }
ul.products[data-cols="6"] li.product .qav-sizes { left: 4px; right: 4px; bottom: 8px; gap: 3px; }
ul.products[data-cols="6"] li.product .qav-sizes .qav-size { padding: 2px 3px; font-size: 9.5px; }
ul.products[data-cols="6"] li.product .woocommerce-loop-product__title { font-size: 12.5px; }

/* ---------------------------------------------------------------- sale states on the card
   Shop Kit prints the countdown (.archive-countdown-wrapper) straight after the photo and positions it from the bottom of
   the whole card. Here the wrapper is a zero-height line at the photo's bottom edge and the panel hangs 40px above it,
   just over the size boxes: a frosted dark panel for a sale with an end date, red (.92) for a flash sale. The units-sold
   bar (.qav-sold-bar) sits under the price. */
.woocommerce ul.products li.product .archive-countdown-wrapper { position: relative; bottom: auto; left: auto; right: auto; z-index: 3; height: 0; padding: 0; }
.woocommerce ul.products li.product .archive-countdown-wrapper > .wc-sale-countdown {
	position: absolute; left: 8%; right: 8%; bottom: 40px; width: auto; margin: 0; padding: 6px 12px; border-radius: 8px; color: #fff;
	/* sale with an end date: frosted glass, the photo shows through blurred; a fine light edge and a soft text shadow keep
	   the white numbers readable over pale kurung (Ain, 5 Nov). */
	background: rgba(17, 17, 17, .36); -webkit-backdrop-filter: blur(16px) saturate(1.5); backdrop-filter: blur(16px) saturate(1.5);
	box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .3); text-shadow: 0 1px 3px rgba(0, 0, 0, .45);
}
.woocommerce ul.products li.product .archive-countdown-wrapper > .wc-sale-countdown.flash-sale { background: rgba(220, 38, 38, .92); box-shadow: none; text-shadow: none; }
.woocommerce ul.products li.product .qav-sold-bar { margin: 6px 10px 0; }
ul.products[data-cols="6"] li.product .archive-countdown-wrapper > .wc-sale-countdown { bottom: 36px; left: 5%; right: 5%; flex-direction: column; gap: 4px; padding: 6px 4px; }

@media (max-width: 900px) {
	.ay-cat-head { padding: 26px 16px 0; }
	.ay-cat-head h1 { margin-bottom: 10px; }
	.ay-cat-desc { font-size: 15px; line-height: 1.65; }
	.ay-tb { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 20px 16px 12px; }
	.ay-tb-l, .ay-tb-r { display: contents; }
	.ay-tb-filter { width: 100%; height: 44px; }
	.ay-tb-count { grid-column: 1 / -1; grid-row: 1; text-align: center; }
	.ay-tb-sort { height: 44px; padding: 0 14px; border: 1px solid var(--ay-line-2); justify-content: space-between; }
	.ay-tb-sort span { display: none; }
	.ay-tb-sort select { width: 100%; }
	.ay-tb-sort svg { right: 14px; }
	.ay-tb-cols { display: none; }
	.ay-f-grid { grid-template-columns: 1fr; gap: 22px; }
	.ay-f-act { justify-content: space-between; }
	body.woocommerce.archive ul.products[data-cols="6"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.woocommerce ul.products li.product .archive-countdown-wrapper > .wc-sale-countdown { left: 4%; right: 4%; bottom: 30px; padding: 5px 6px; gap: 6px; }
}

/* No products match the chosen filters: plain centred text instead of WooCommerce's blue notice box. */
.woocommerce .woocommerce-no-products-found .woocommerce-info { margin: 0; padding: 56px var(--ay-gut) 72px; border: 0; background: none; color: var(--ay-muted); text-align: center; font-size: 14px; }
.woocommerce .woocommerce-no-products-found .woocommerce-info::before { display: none; }
