.ag-shop-toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 32px;
	width: 100%;
	margin: 0 0 28px;
}

.woocommerce .ag-shop-toolbar .page-title {
	flex: 0 0 auto;
	margin: 0;
}

.ag-product-search {
	position: relative;
	z-index: 12;
	flex: 0 1 440px;
	width: min(440px, 48vw);
}

.ag-product-search__form {
	position: relative;
}

.woocommerce .ag-product-search__form input[type="search"] {
	width: 100%;
	height: 48px;
	margin: 0;
	padding: 0 46px 0 44px;
	border: 1px solid var(--line-strong, rgba(200, 205, 220, .18));
	border-radius: var(--radius-sm, 10px);
	outline: none;
	background: rgba(255, 255, 255, .025);
	color: var(--ink, #f3efe6);
	font: 500 .92rem/1 var(--font-body, system-ui);
	transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.woocommerce .ag-product-search__form input[type="search"]::placeholder {
	color: var(--ink-faint, #6f7682);
	opacity: 1;
}

.woocommerce .ag-product-search__form input[type="search"]::-webkit-search-cancel-button {
	-webkit-appearance: none;
	appearance: none;
}

.woocommerce .ag-product-search__form input[type="search"]:hover {
	background: rgba(255, 255, 255, .04);
}

.woocommerce .ag-product-search__form input[type="search"]:focus {
	border-color: var(--gold, #f5c842);
	background: rgba(7, 7, 12, .85);
	box-shadow: 0 0 0 3px var(--gold-faint, rgba(245, 200, 66, .08));
}

.ag-product-search__icon {
	position: absolute;
	left: 15px;
	top: 50%;
	z-index: 2;
	width: 19px;
	height: 19px;
	transform: translateY(-50%);
	color: var(--silver-dim, #828d9c);
	pointer-events: none;
}

.ag-product-search__icon svg {
	width: 100%;
	height: 100%;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.8;
	stroke-linecap: round;
}

.ag-product-search__clear {
	position: absolute;
	right: 7px;
	top: 50%;
	width: 34px;
	height: 34px;
	padding: 0;
	transform: translateY(-50%);
	border: 0;
	border-radius: 50%;
	background: transparent;
	color: var(--silver, #c5cfdb);
	font: 300 1.4rem/1 sans-serif;
	cursor: pointer;
}

.ag-product-search__clear:hover,
.ag-product-search__clear:focus-visible {
	background: var(--gold-faint, rgba(245, 200, 66, .08));
	color: var(--gold-bright, #ffe089);
}

.ag-product-search__results {
	position: absolute;
	right: 0;
	top: calc(100% + 8px);
	width: min(680px, calc(100vw - 48px));
	max-height: min(520px, 65vh);
	overflow-y: auto;
	border: 1px solid var(--line-strong, rgba(200, 205, 220, .18));
	border-radius: var(--radius-sm, 10px);
	background: rgba(10, 10, 17, .98);
	box-shadow: 0 24px 64px rgba(0, 0, 0, .5);
	backdrop-filter: blur(18px);
}

.ag-product-search__result-list {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	padding: 8px;
}

.ag-product-search__result {
	display: grid;
	grid-template-columns: 64px minmax(0, 1fr);
	align-items: center;
	gap: 12px;
	min-width: 0;
	padding: 8px;
	border-radius: 8px;
	color: var(--ink-soft, #b9bcc2);
}

.ag-product-search__result:hover,
.ag-product-search__result:focus-visible {
	background: var(--gold-faint, rgba(245, 200, 66, .08));
	color: var(--ink, #f3efe6);
}

.ag-product-search__result img {
	width: 64px;
	height: 64px;
	object-fit: cover;
	border-radius: 7px;
	background: var(--bg-3, #11111d);
}

.ag-product-search__result-copy {
	display: flex;
	min-width: 0;
	flex-direction: column;
	gap: 2px;
}

.ag-product-search__result-copy strong {
	overflow: hidden;
	color: var(--ink, #f3efe6);
	font-size: .9rem;
	font-weight: 600;
	line-height: 1.3;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.ag-product-search__result-meta {
	overflow: hidden;
	color: var(--ink-faint, #6f7682);
	font: 500 .64rem/1.3 var(--font-mono, monospace);
	letter-spacing: .06em;
	text-overflow: ellipsis;
	text-transform: uppercase;
	white-space: nowrap;
}

.ag-product-search__result-price {
	color: var(--gold, #f5c842);
	font-size: .78rem;
}

.ag-product-search__message,
.ag-product-search__all {
	display: block;
	margin: 0;
	padding: 16px 18px;
	text-align: center;
}

.ag-product-search__message {
	color: var(--ink-faint, #6f7682);
}

.ag-product-search__all {
	border-top: 1px solid var(--line, rgba(200, 205, 220, .1));
	color: var(--gold, #f5c842);
	font-size: .84rem;
	font-weight: 600;
}

@media (max-width: 700px) {
	.ag-shop-toolbar {
		display: block;
		margin-bottom: 24px;
	}

	.woocommerce .ag-shop-toolbar .page-title {
		margin-bottom: 14px;
	}

	.ag-product-search {
		width: 100%;
	}

	.woocommerce .ag-product-search__form input[type="search"] {
		height: 46px;
		font-size: .9rem;
	}

	.ag-product-search__results {
		left: 0;
		right: 0;
		width: auto;
		max-height: 52vh;
	}

	.ag-product-search__result-list {
		grid-template-columns: 1fr;
	}

	.ag-product-search__result {
		grid-template-columns: 56px minmax(0, 1fr);
		padding: 7px;
	}

	.ag-product-search__result img {
		width: 56px;
		height: 56px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.woocommerce .ag-product-search__form input[type="search"] {
		transition: none;
	}
}

/* ============================================================
   v1.3.0 — Light shop toolbar: search + category chips
   Scoped to the white shop canvas (.woo-wrap).
   ============================================================ */

.woo-wrap .ag-shop-toolbar {
	flex-wrap: wrap;
	align-items: flex-end;
	gap: 20px 32px;
	margin-bottom: 34px;
}

/* Search field on white */
.woocommerce .woo-wrap .ag-product-search__form input[type="search"] {
	height: 50px;
	border: 1px solid rgba(16, 19, 24, 0.20);
	background: #ffffff;
	color: #101318;
	font-size: .95rem;
}

.woocommerce .woo-wrap .ag-product-search__form input[type="search"]::placeholder {
	color: #626b78;
}

.woocommerce .woo-wrap .ag-product-search__form input[type="search"]:hover {
	border-color: rgba(16, 19, 24, 0.34);
	background: #ffffff;
}

.woocommerce .woo-wrap .ag-product-search__form input[type="search"]:focus {
	border-color: #8a6300;
	background: #ffffff;
	box-shadow: 0 0 0 3px rgba(138, 99, 0, .14);
}

.woo-wrap .ag-product-search__icon {
	color: #626b78;
}

.woo-wrap .ag-product-search__clear {
	color: #39404a;
}

.woo-wrap .ag-product-search__clear:hover,
.woo-wrap .ag-product-search__clear:focus-visible {
	background: rgba(16, 19, 24, .06);
	color: #101318;
}

/* Suggestion dropdown on white */
.woo-wrap .ag-product-search__results {
	border: 1px solid rgba(16, 19, 24, .14);
	background: #ffffff;
	box-shadow: 0 24px 64px rgba(16, 19, 24, .18);
	backdrop-filter: none;
}

.woo-wrap .ag-product-search__result {
	color: #39404a;
}

.woo-wrap .ag-product-search__result:hover,
.woo-wrap .ag-product-search__result:focus-visible {
	background: rgba(16, 19, 24, .05);
	color: #101318;
}

.woo-wrap .ag-product-search__result img {
	background: #f2f3f5;
}

.woo-wrap .ag-product-search__result-copy strong {
	color: #101318;
}

.woo-wrap .ag-product-search__result-meta {
	color: #626b78;
}

.woo-wrap .ag-product-search__result-price {
	color: #101318;
	font-weight: 700;
}

.woo-wrap .ag-product-search__message {
	color: #626b78;
}

.woo-wrap .ag-product-search__all {
	border-top: 1px solid rgba(16, 19, 24, .12);
	color: #8a6300;
}

/* --- Category chips --- */
.ag-cat-filter {
	display: flex;
	flex: 0 0 100%;
	flex-wrap: wrap;
	gap: 10px;
	margin: 4px 0 0;
}

.woo-wrap .ag-cat-filter__chip {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 9px 18px;
	border: 1px solid rgba(16, 19, 24, 0.16);
	border-radius: 999px;
	background: #ffffff;
	color: #39404a;
	font: 600 .9rem/1 var(--font-body, system-ui);
	white-space: nowrap;
	transition: border-color .2s ease, background .2s ease, color .2s ease;
}

.woo-wrap .ag-cat-filter__chip:hover,
.woo-wrap .ag-cat-filter__chip:focus-visible {
	border-color: rgba(16, 19, 24, 0.42);
	background: #f6f7f9;
	color: #101318;
}

.woo-wrap .ag-cat-filter__chip.is-active {
	border-color: #101318;
	background: #101318;
	color: #ffffff;
}

.woo-wrap .ag-cat-filter__count {
	color: #7a828d;
	font-size: .76rem;
	font-weight: 600;
}

.woo-wrap .ag-cat-filter__chip.is-active .ag-cat-filter__count {
	color: rgba(255, 255, 255, 0.68);
}

@media (max-width: 700px) {
	.woo-wrap .ag-shop-toolbar {
		display: flex;
	}

	.ag-cat-filter {
		margin-top: 14px;
		overflow-x: auto;
		flex-wrap: nowrap;
		padding-bottom: 4px;
		-webkit-overflow-scrolling: touch;
		scrollbar-width: none;
	}

	.ag-cat-filter::-webkit-scrollbar {
		display: none;
	}
}
