/* =========================================================================
   Product category pages (approved design "category.html").
   Loaded on category pages only, after site.css. Product cards reuse the
   .as-card styles from site.css.
   ========================================================================= */

/* Neutralise parent theme button skins inside the page. */
.as-site.as-site :where(.as-cat) :is(button, [type=button], [type=submit]) {
	background: none;
	border: 0;
	border-radius: 0;
	color: inherit;
	padding: 0;
	font: inherit;
	white-space: normal;
	text-transform: none;
	letter-spacing: inherit;
	transition: border-color .15s ease, background-color .15s ease, color .15s ease;
}

.as-cat { --as-line-3: #F2F4F7; }
.as-crumbs { font-size: 13px; color: var(--as-muted); display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
.as-crumbs [aria-current] { color: var(--as-ink); font-weight: 600; }

/* ---------- Breadcrumb + banner ---------- */
.as-cat__intro { padding-top: 16px; padding-bottom: 18px; display: flex; flex-direction: column; gap: 14px; }
.as-cat__intro .woocommerce-notices-wrapper:empty { display: none; }
.as-cat__banner { background: #FFF4DE; border-radius: var(--as-radius); padding: 18px 24px; display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; }
.as-cat__bannermain { display: flex; gap: 16px; align-items: center; flex: 1 1 520px; min-width: 0; }
.as-cat__icon { width: 60px; height: 60px; flex: none; border-radius: var(--as-radius); background: #fff; display: flex; align-items: center; justify-content: center; border: 2px solid var(--as-gold-ink); box-sizing: border-box; }
.as-cat__titles { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.as-site.as-site .as-cat__title { margin: 0; font-size: 26px; font-weight: 700; line-height: 1.2; color: var(--as-ink); }
.as-cat__stats { color: var(--as-badge-ink); font-weight: 600; font-size: 13px; }
.as-cat__introtext { color: var(--as-muted); font-size: 13px; }
.as-site.as-site .as-cat__bulk { height: 44px; padding: 0 18px; border-radius: var(--as-radius); border: 1px solid var(--as-gold-ink); color: var(--as-badge-ink); font-weight: 600; display: flex; align-items: center; background: #fff; cursor: pointer; }
.as-site.as-site .as-cat__bulk:hover { background: var(--as-gold-soft); color: var(--as-badge-ink); }

/* ---------- Locked scope + applied filters ---------- */
.as-cat__chips { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 14px; }
.as-cat__chiplist { display: contents; }
.as-cat__lock { display: flex; align-items: center; gap: 6px; height: 34px; padding: 0 10px; border-radius: var(--as-radius); background: var(--as-blue); color: #fff; font-size: 13px; font-weight: 600; box-sizing: border-box; }
.as-cat__lock span { font-weight: 400; color: var(--as-field); }
.as-site.as-site .as-chip { display: flex; align-items: center; gap: 6px; height: 34px; padding: 0 10px; border: 1px solid var(--as-gold); background: var(--as-gold-soft); color: var(--as-badge-ink); border-radius: var(--as-radius); font-weight: 600; font-size: 13px; cursor: pointer; box-sizing: border-box; }
.as-site.as-site .as-chip:hover { background: var(--as-badge-bg); color: var(--as-badge-ink); }
.as-chip span { font-weight: 500; }
.as-site.as-site .as-chip-clear { color: var(--as-gold-ink); font-weight: 600; text-decoration: underline; min-height: 34px; cursor: pointer; }

/* ---------- Layout ---------- */
.as-cat__layout { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.as-cat__filters { flex: 1 1 260px; max-width: 300px; min-width: 0; border: 1px solid var(--as-line); border-radius: var(--as-radius); font-size: 13px; box-sizing: border-box; background: #fff; }
@media (min-width: 900px) {
	.as-cat__filters { position: sticky; top: 16px; max-height: calc(100vh - 32px); overflow-y: auto; align-self: flex-start; scrollbar-width: thin; }
	.as-cat__filtersbtn { display: none !important; }
}
.as-cat__results { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }

/* Filters panel */
.as-cat__fhead { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-bottom: 1px solid var(--as-line); }
.as-cat__fhead > span:first-child { font-weight: 700; font-size: 15px; }
.as-cat__fcount { font-size: 12px; color: var(--as-muted-2); }
.as-cat__ftitle { display: block; font-weight: 700; font-size: 14px; margin: 0 0 4px; }
.as-cat__tree { padding: 12px 10px 10px; border-bottom: 1px solid var(--as-line-3); }
.as-cat__tree .as-cat__ftitle { padding: 0 6px 6px; margin: 0; }
.as-cat__tree ul { list-style: none; margin: 0; padding: 0; }
.as-cat__node { display: flex; align-items: center; }
.as-site.as-site .as-cat__chev { width: 28px; height: 32px; flex: none; color: var(--as-muted-3); font-size: 14px; text-align: center; cursor: pointer; transition: transform .15s ease; }
.as-site.as-site .as-cat__chev[aria-expanded="true"] { transform: rotate(90deg); color: var(--as-navy); }
.as-cat__chev-sp { width: 28px; flex: none; }
.as-site.as-site .as-cat__link { flex: 1 1 auto; display: flex; justify-content: space-between; gap: 8px; padding: 5px 6px; border-radius: var(--as-radius); font-size: 13px; color: var(--as-text); font-weight: 500; line-height: 1.35; }
.as-site.as-site .as-cat__link:hover { background: var(--as-bg-soft); color: var(--as-navy); }
.as-cat__link small { color: var(--as-muted-3); font-weight: 400; font-size: 13px; }
.as-cat__link.is-zero { color: var(--as-muted-3); }
.as-cat__sub { margin: 0 0 4px 22px !important; padding: 0 0 0 6px !important; border-left: 2px solid var(--as-line-3); }

.as-cat__group { padding: 12px 16px; border-bottom: 1px solid var(--as-line-3); display: flex; flex-direction: column; gap: 2px; }
.as-cat__opt { display: flex; align-items: center; gap: 10px; min-height: 32px; cursor: pointer; color: var(--as-ink); }
.as-cat__opt.is-zero { color: var(--as-muted-3); }
.as-cat__opt.is-on { font-weight: 600; }
.as-cat__opt span { flex: 1 1 auto; }
.as-cat__opt small { font-size: 12px; color: var(--as-muted-3); }
.as-site.as-site .as-cat__fld { height: 34px; border: 1px solid var(--as-field); border-radius: var(--as-radius); padding: 0 10px; font-size: 13px; box-sizing: border-box; background: #fff; color: var(--as-ink); width: 100%; box-shadow: none; }
.as-cat__fld:focus { outline: 2px solid var(--as-gold); outline-offset: 0; border-color: var(--as-gold); }
.as-cat__bsearch { margin-bottom: 6px; }
.as-site.as-site .as-cat__more-btn { align-self: flex-start; padding: 4px 0; color: var(--as-gold-ink); font-weight: 600; font-size: 13px; cursor: pointer; }
.as-cat__range { display: flex; gap: 6px; align-items: center; margin-top: 6px; }
.as-site.as-site .as-cat__range .as-cat__fld { width: 0; flex: 1 1 auto; padding: 0 8px; }
.as-cat__range > span { color: var(--as-muted-2); }
.as-site.as-site .as-cat__go { height: 34px; border-radius: var(--as-radius); background: var(--as-blue); color: #fff; padding: 0 10px; font-weight: 600; cursor: pointer; flex: none; }
.as-site.as-site .as-cat__go:hover { background: var(--as-navy); color: #fff; }
.as-cat__spec { padding: 12px 16px; background: var(--as-bg-soft); border-radius: 0 0 var(--as-radius) var(--as-radius); display: flex; flex-direction: column; gap: 6px; }
.as-cat__spectitle { font-weight: 700; font-size: 13px; color: var(--as-muted); }
.as-cat__specs { display: flex; flex-wrap: wrap; gap: 6px; }
.as-cat__specs span { border: 1px dashed var(--as-field); border-radius: var(--as-radius); padding: 4px 8px; font-size: 12px; color: var(--as-muted-2); }
.as-cat__specnote { font-size: 11px; color: var(--as-muted-2); }

/* Mobile: filters behind a button */
.as-site.as-site .as-cat__filtersbtn { display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 16px; border: 1px solid var(--as-field); border-radius: var(--as-radius); background: #fff; color: var(--as-navy); font-weight: 700; cursor: pointer; width: 100%; justify-content: center; }
@media (max-width: 899px) {
	.as-cat__filters { max-width: none; flex-basis: 100%; display: none; }
	.as-cat__filters.is-open { display: block; }
}

/* ---------- Sub-category tiles + carousels ---------- */
.as-cat__tiles { display: flex; flex-direction: column; gap: 8px; }
.as-cat__rowhead { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.as-cat__h3 { font-weight: 700; font-size: 15px; }
.as-carousel__nav { display: flex; align-items: center; gap: 8px; }
.as-carousel__pos { font-size: 12px; color: var(--as-muted-2); white-space: nowrap; }
.as-site.as-site .as-arrow { width: 36px; height: 36px; border-radius: var(--as-radius); font-size: 18px; border: 1px solid var(--as-field); background: #fff; color: var(--as-navy); text-align: center; line-height: 1; cursor: pointer; }
.as-site.as-site .as-arrow--lg { width: 40px; height: 40px; }
.as-site.as-site .as-arrow:disabled { border-color: var(--as-line); background: var(--as-bg-soft); color: var(--as-field); cursor: default; }
.as-carousel__nav:not(.is-on) { visibility: hidden; }
.as-cat__tilegrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.as-site.as-site .as-cat__tile { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--as-radius); text-align: left; min-height: 64px; background: #fff; color: var(--as-ink); border: 1px solid var(--as-line); box-sizing: border-box; transition: border-color .15s ease, box-shadow .15s ease; }
.as-site.as-site .as-cat__tile:hover { border-color: var(--as-navy); box-shadow: 0 6px 18px rgba(11, 31, 58, .08); color: var(--as-ink); }
.as-cat__tileimg { width: 40px; height: 40px; flex: none; border-radius: var(--as-radius); background: var(--as-bg-soft); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.as-cat__tileimg img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.as-cat__tiletxt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.as-cat__tiletxt b { font-weight: 700; font-size: 13px; line-height: 1.3; }
.as-cat__tiletxt small { font-size: 12px; opacity: .75; }

/* ---------- Toolbar ---------- */
.as-cat__toolbar { border: 1px solid var(--as-line); border-radius: var(--as-radius); padding: 10px 14px; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }
.as-cat__showing { color: var(--as-muted); }
.as-cat__showing b { color: var(--as-ink); }
.as-cat__tools { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.as-cat__sort { color: var(--as-muted); display: flex; align-items: center; gap: 8px; margin: 0; font-weight: 400; }
.as-site.as-site .as-cat__sort select { height: 40px; border: 1px solid var(--as-field); border-radius: var(--as-radius); padding: 0 10px; background: #fff; font-size: 14px; font-family: inherit; color: var(--as-ink); width: auto; }
.as-cat__view { display: flex; border: 1px solid var(--as-field); border-radius: var(--as-radius); overflow: hidden; }
.as-site.as-site .as-cat__view button { height: 40px; padding: 0 14px; background: #fff; color: var(--as-text); cursor: pointer; }
.as-site.as-site .as-cat__view button[aria-pressed="true"] { background: var(--as-blue); color: #fff; font-weight: 600; }

/* ---------- Product grid ---------- */
.as-cat__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
.as-lcard .as-card__brand { letter-spacing: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.as-lcard__type, .as-lcard__meta { font-size: 12px; color: var(--as-muted); }
.as-lcard__cmp { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--as-text); min-height: 28px; cursor: pointer; margin: 0; font-weight: 400; }
.as-lcard__actions { display: flex; gap: 6px; margin-top: auto; }
.as-site.as-site .as-lcard__actions .as-card__cta { flex: 1 1 auto; margin-top: 0; }
.as-site.as-site .as-lcard__quote { height: 40px; padding: 0 12px; border-radius: var(--as-radius); font-weight: 600; border: 1px solid var(--as-field); background: #fff; color: var(--as-navy); cursor: pointer; flex: none; }
.as-site.as-site .as-lcard__quote:hover { border-color: var(--as-navy); background: var(--as-blue-soft); color: var(--as-navy); }
.as-site.as-site .as-lcard__quote.is-primary { flex: 1 1 auto; border: 0; background: var(--as-blue); color: #fff; }
.as-site.as-site .as-lcard__quote.is-primary:hover { background: var(--as-navy); color: #fff; }
.as-lcard .added_to_cart { display: none; }

/* List view */
.as-cat__tablewrap { border: 1px solid var(--as-line); border-radius: var(--as-radius); overflow-x: auto; }
.as-cat__table { width: 100%; border-collapse: collapse; min-width: 820px; font-size: 13px; margin: 0; }
.as-cat__table th { background: var(--as-bg-soft); text-align: left; color: var(--as-muted); font-size: 12px; padding: 10px; font-weight: 700; border: 0; }
.as-cat__table th:first-child, .as-cat__table td:first-child { padding-left: 14px; }
.as-cat__table td { padding: 10px; border: 0; border-top: 1px solid var(--as-line-3); vertical-align: middle; background: #fff; }
.as-site.as-site .as-cat__table td a { font-weight: 600; color: var(--as-ink); }
.as-site.as-site .as-cat__table td a:hover { color: var(--as-navy); text-decoration: underline; }
.as-cat__table .as-mono { font-size: 11px; color: var(--as-muted-2); }
.as-cat__table .is-price { font-weight: 700; white-space: nowrap; }
.as-cat__table .is-mrp { color: var(--as-muted-2); white-space: nowrap; }
.as-cat__table .is-off { color: var(--as-gold-ink); font-weight: 600; white-space: nowrap; }

/* Empty state */
.as-cat__none { border: 1px dashed var(--as-field); border-radius: var(--as-radius); padding: 44px 24px; display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.as-cat__none b { font-size: 18px; }
.as-cat__none span { color: var(--as-muted); }
.as-site.as-site .as-cat__none .as-btn { height: 44px; padding: 0 18px; border-radius: var(--as-radius); background: var(--as-blue); color: #fff; font-weight: 600; cursor: pointer; }

/* Pagination */
.as-cat__pages { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 6px; }
.as-site.as-site .as-cat__pg { min-width: 44px; height: 44px; padding: 0 10px; border-radius: var(--as-radius); border: 1px solid var(--as-line); background: #fff; color: var(--as-ink); display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; font-size: 14px; cursor: pointer; }
.as-site.as-site a.as-cat__pg:hover, .as-site.as-site button.as-cat__pg:hover:not(:disabled) { border-color: var(--as-navy); color: var(--as-navy); }
.as-site.as-site .as-cat__pg.is-on { border: 0; background: var(--as-blue); color: #fff; font-weight: 700; }
.as-cat__pg--wide { padding: 0 14px !important; }
.as-site.as-site .as-cat__pg.is-off, .as-site.as-site .as-cat__pg:disabled { color: var(--as-field); cursor: default; }
.as-site.as-site .as-cat__pg--gap { border: 0; background: none; min-width: 32px; color: var(--as-muted-2); cursor: default; }

/* Compare bar */
.as-cat__cmpbar { position: sticky; bottom: 0; z-index: 5; margin: 16px -24px 0; background: var(--as-blue); color: #fff; padding: 12px 24px; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; border-radius: var(--as-radius) var(--as-radius) 0 0; }
.as-cat__cmplist { display: flex; flex-wrap: wrap; gap: 8px; }
.as-cat__cmpitem { display: flex; align-items: center; gap: 6px; background: #3D6A99; border-radius: var(--as-radius); padding: 6px 6px 6px 10px; font-size: 12px; max-width: 240px; }
.as-cat__cmpitem > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.as-site.as-site .as-cat__cmpitem button { width: 28px; height: 28px; flex: none; border-radius: var(--as-radius); color: var(--as-field); font-size: 16px; text-align: center; cursor: pointer; }
.as-site.as-site .as-cat__cmpitem button:hover { color: #fff; background: rgba(255, 255, 255, .12); }
.as-cat__cmpact { margin-left: auto; display: flex; gap: 8px; }
.as-site.as-site .as-cat__cmpclear { height: 44px; padding: 0 14px; border: 1px solid #8FB0D3; border-radius: var(--as-radius); color: #fff; cursor: pointer; }
.as-site.as-site .as-cat__cmpgo { height: 44px; padding: 0 18px; border-radius: var(--as-radius); background: var(--as-navy); color: #fff; font-weight: 700; cursor: pointer; }
.as-site.as-site .as-cat__cmpgo:disabled { background: #3D6A99; color: var(--as-field); cursor: default; }

/* Compare pop-up */
.as-cmpmodal__box { max-width: 1040px; }
.as-cmpmodal__body { padding: 0 24px 24px; overflow-x: auto; }
.as-cmpmodal__body table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 560px; margin: 0; }
.as-cmpmodal__body th, .as-cmpmodal__body td { border: 0; border-top: 1px solid var(--as-line-3); padding: 9px 10px; text-align: left; vertical-align: top; background: #fff; }
.as-cmpmodal__body th { color: var(--as-muted); font-weight: 600; width: 160px; }
.as-cmpmodal__body thead td { border-top: 0; }
.as-cmpmodal__img { width: 100%; max-width: 140px; aspect-ratio: 1 / 1; background: var(--as-bg-soft); border-radius: var(--as-radius); display: flex; align-items: center; justify-content: center; overflow: hidden; margin-bottom: 8px; }
.as-cmpmodal__img img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.as-site.as-site .as-cmpmodal__body thead a { font-weight: 700; color: var(--as-ink); line-height: 1.35; }

/* ---------- Below the listing ---------- */
.as-cat__more { padding-top: 40px; padding-bottom: 56px; display: flex; flex-direction: column; gap: 36px; }
.as-cat__sec { display: flex; flex-direction: column; gap: 14px; }
.as-cat__cards5 { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.as-lcard--deal .as-card__media { height: 140px; }
.as-cat__help { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; align-items: stretch; }
.as-cat__guide { border: 1px solid var(--as-line); border-radius: var(--as-radius); padding: 20px 22px; display: flex; flex-direction: column; gap: 8px; }
.as-cat__eyebrow { font-size: 12px; font-weight: 700; color: var(--as-gold-ink); letter-spacing: .08em; }
.as-site.as-site .as-cat__h2 { margin: 0; font-size: 20px; font-weight: 700; line-height: 1.3; color: var(--as-ink); }
.as-cat__guide p { margin: 0; color: var(--as-muted); white-space: pre-line; }
.as-site.as-site .as-cat__guidelink { font-weight: 600; color: var(--as-gold-ink); margin-top: auto; }
.as-cat__askbox { background: var(--as-blue); border-radius: var(--as-radius); padding: 20px 22px; display: flex; flex-direction: column; gap: 8px; color: #fff; }
.as-cat__askbox > span { color: #DCE6F2; }
.as-cat__askbox .as-cat__asktitle { font-size: 18px; font-weight: 700; color: #fff; }
.as-site.as-site .as-cat__askbtn { align-self: flex-start; margin-top: auto; height: 44px; padding: 0 18px; border-radius: var(--as-radius); background: var(--as-navy); color: #fff; font-weight: 700; display: flex; align-items: center; cursor: pointer; }
.as-site.as-site .as-cat__askbtn:hover { background: var(--as-navy-ink); color: #fff; }
.as-cat__help.is-solo .as-cat__askbox { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px 16px; }
.as-cat__help.is-solo .as-cat__askbtn { margin: 0 0 0 auto; }

.as-cat__othergrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.as-cat__ocard { background: #fff; border: 1px solid var(--as-line); border-radius: var(--as-radius); padding: 18px; display: flex; flex-direction: column; gap: 12px; min-height: 180px; box-sizing: border-box; transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease; position: relative; }
.as-cat__ocard:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(11, 31, 58, .12); border-color: var(--as-navy); }
.as-cat__ohead { display: flex; justify-content: space-between; align-items: flex-start; }
.as-cat__oicon { width: 56px; height: 56px; border-radius: var(--as-radius); background: var(--as-bg-soft); border: 1px solid var(--as-line); display: flex; align-items: center; justify-content: center; }
.as-cat__obadge { background: var(--as-bg-soft); color: var(--as-muted); font-size: 12px; font-weight: 600; padding: 4px 8px; border-radius: var(--as-radius); }
.as-site.as-site .as-cat__oname { font-weight: 700; font-size: 16px; line-height: 1.3; color: var(--as-ink); }
.as-site.as-site .as-cat__oname::after { content: ''; position: absolute; inset: 0; } /* whole card clickable */
.as-site.as-site .as-cat__oshop { margin-top: auto; font-weight: 700; font-size: 13px; color: var(--as-navy); }

/* ---------- Smaller screens ---------- */
@media (max-width: 899px) {
	.as-cat__tilegrid, .as-cat__othergrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 599px) {
	.as-cat__banner { padding: 16px; }
	.as-site.as-site .as-cat__title { font-size: 22px; }
	.as-cat__bulk { width: 100%; justify-content: center; }
	.as-cat__grid, .as-cat__cards5 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.as-cat__grid .as-card, .as-cat__cards5 .as-card { padding: 10px; }
	.as-lcard__actions { flex-direction: column; }
	.as-site.as-site .as-lcard__quote { width: 100%; }
	.as-cat__cmpbar { margin: 16px -16px 0; padding: 10px 16px; }
	.as-cat__cmpact { width: 100%; }
	.as-cat__cmpact button { flex: 1 1 auto; }
	.as-cat__help { grid-template-columns: minmax(0, 1fr); }
	.as-cat__othergrid { grid-template-columns: minmax(0, 1fr); }
	.as-cat__toolbar { padding: 10px; }
	.as-cat__tools { width: 100%; justify-content: space-between; }
}
