/*
 * aieo/brand-azindex, layout aurenne (Brands B, B3): the designer's brands index (brands-b). The head, «In focus» on the
 * brands' area colours (C2@2: var(--wp--custom--rooster--area--<area>) and --on-<area>, each with the contract's
 * fallback), the toolbar (the chips are the category chips' sheet, aieo-category-chips-button), the letters sticky
 * under the header (var(--rooster-sticky-top), the theme's), the letters' sections and the brand cards. The palette's
 * tokens, no colour of its own. Loaded only where it renders.
 */
.aieo-brands { padding-bottom: clamp(56px, 7vw, 104px); }

/* The head: the h1, the number of brands beside it, the line under it. */
.aieo-brands__head { padding-bottom: var(--wp--preset--spacing--6); }
.aieo-brands__heading { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 14px; }
.aieo-brands__title { margin: 0; font-size: clamp(2.5rem, 1.6rem + 3.4vw, 4.75rem); }
.aieo-brands__total { margin: 0; color: var(--wp--preset--color--muted, currentColor); font-size: var(--wp--preset--font-size--md); font-variant-numeric: tabular-nums; }
.aieo-brands__lead { margin: var(--wp--preset--spacing--3) 0 0; max-width: 56ch; color: var(--wp--preset--color--muted, currentColor); }

/* In focus. */
.aieo-brands__focus { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--wp--preset--spacing--3); margin: 0 0 var(--wp--preset--spacing--7); padding: 0; list-style: none; }
.aieo-brands__focus > li { display: grid; margin: 0; }
.aieo-brands__fc.is-area-lacquer { --aieo-area: var(--wp--custom--rooster--area--lacquer, var(--wp--preset--color--accent)); --aieo-area-ink: var(--wp--custom--rooster--area--on-lacquer, oklch(from var(--aieo-area) clamp(0, (.62 - l) * 999, 1) 0 0)); }
.aieo-brands__fc.is-area-plum { --aieo-area: var(--wp--custom--rooster--area--plum, var(--wp--preset--color--accent-2)); --aieo-area-ink: var(--wp--custom--rooster--area--on-plum, oklch(from var(--aieo-area) clamp(0, (.62 - l) * 999, 1) 0 0)); }
.aieo-brands__fc.is-area-coral { --aieo-area: var(--wp--custom--rooster--area--coral, var(--wp--preset--color--ornament)); --aieo-area-ink: var(--wp--custom--rooster--area--on-coral, oklch(from var(--aieo-area) clamp(0, (.62 - l) * 999, 1) 0 0)); }
.aieo-brands__fc.is-area-blush { --aieo-area: var(--wp--custom--rooster--area--blush, var(--wp--preset--color--subtle)); --aieo-area-ink: var(--wp--custom--rooster--area--on-blush, oklch(from var(--aieo-area) clamp(0, (.62 - l) * 999, 1) 0 0)); }
.aieo-brands__fc.is-area-nude { --aieo-area: var(--wp--custom--rooster--area--nude, var(--wp--preset--color--subtle)); --aieo-area-ink: var(--wp--custom--rooster--area--on-nude, oklch(from var(--aieo-area) clamp(0, (.62 - l) * 999, 1) 0 0)); }
.aieo-brands__fc {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	min-height: 220px;
	overflow: hidden;
	background: var(--aieo-area);
	color: var(--aieo-area-ink, currentColor);
	text-decoration: none;
}
.aieo-brands__fc.has-picture { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.aieo-brands__fc-pic { order: 2; overflow: hidden; }
.aieo-brands__fc-img { display: block; width: 100%; height: 100%; object-fit: cover; transition: scale 600ms cubic-bezier(.2, .7, .2, 1); }
.aieo-brands__fc:hover .aieo-brands__fc-img { scale: 1.04; }
.aieo-brands__fc-text { display: grid; align-content: space-between; gap: var(--wp--preset--spacing--4); padding: var(--wp--preset--spacing--5); }
.aieo-brands__fc-kicker { font-size: var(--wp--preset--font-size--xs); font-weight: 600; letter-spacing: var(--wp--custom--rooster--tracking--wide, 0.08em); text-transform: uppercase; opacity: .8; }
.aieo-brands__fc-name { display: block; font-size: var(--wp--preset--font-size--xl); font-weight: 650; line-height: 1.1; }
.aieo-brands__fc-line { display: block; margin-top: 6px; font-size: var(--wp--preset--font-size--sm); }
.aieo-brands__fc-go { display: inline-flex; align-items: center; gap: 8px; font-size: var(--wp--preset--font-size--sm); font-weight: 600; }
.aieo-brands__fc-arrow { width: 16px; height: 16px; flex: none; transition: translate 240ms cubic-bezier(.2, .7, .2, 1); }
.aieo-brands__fc:hover .aieo-brands__fc-arrow { translate: 4px 0; }
.aieo-brands__fc:focus-visible { outline: 2px solid var(--wp--preset--color--fg, currentColor); outline-offset: 2px; box-shadow: none; }

/* The toolbar. */
.aieo-brands__tools { display: flex; flex-wrap: wrap; align-items: center; gap: var(--wp--preset--spacing--3) var(--wp--preset--spacing--5); padding-bottom: var(--wp--preset--spacing--4); }
.aieo-brands__search { position: relative; flex: 1 1 280px; max-width: 420px; }
.aieo-brands__search-icon { position: absolute; left: 14px; top: 50%; translate: 0 -50%; width: 18px; height: 18px; color: var(--wp--preset--color--muted, currentColor); pointer-events: none; }
.aieo-brands .aieo-brands__q {
	box-sizing: border-box;
	width: 100%;
	min-height: 48px;
	margin: 0;
	padding: 0 14px 0 42px;
	border: 1px solid var(--wp--preset--color--line, color-mix(in srgb, currentColor 16%, transparent));
	border-radius: var(--wp--custom--rooster--shape--control, 0);
	background: var(--wp--preset--color--bg, Canvas);
	color: var(--wp--preset--color--fg, CanvasText);
	font: inherit;
	font-size: max(16px, var(--wp--preset--font-size--md, 1rem)); /* iOS zooms a field below 16 px (FE-F4). */
}
.aieo-brands .aieo-brands__q::placeholder { color: var(--wp--preset--color--muted, currentColor); opacity: 1; }
.aieo-brands .aieo-brands__q:hover { border-color: var(--wp--preset--color--fg, currentColor); }
.aieo-brands .aieo-brands__q:focus-visible { border-color: var(--wp--preset--color--fg, currentColor); box-shadow: var(--wp--custom--rooster--focus-ring); outline: none; }
.aieo-brands__chips { min-width: 0; max-width: 100%; } /* a flex item: never wider than the row, whatever its chips */
.aieo-brands__chips .aieo-subcats__list { gap: 6px; }
.aieo-brands__chips .aieo-subcats__chip { cursor: pointer; font-family: inherit; }
.aieo-brands__chips.aieo-subcats .aieo-subcats__chip[aria-pressed="true"] {
	border-color: var(--wp--preset--color--fg, CanvasText);
	background: var(--wp--preset--color--fg, CanvasText);
	color: var(--wp--preset--color--bg, Canvas);
}
.aieo-brands__chips .aieo-subcats__chip[aria-pressed="true"] .aieo-subcats__count { color: inherit; opacity: .75; }
.aieo-brands__chip-icon { align-self: center; width: 16px; height: 16px; flex: none; }
.aieo-brands__chips [aria-pressed="true"] .aieo-brands__chip-icon:not(.rooster-icon) { fill: currentColor; }
.aieo-brands__own { display: flex; align-items: stretch; gap: 6px; }
.aieo-brands__own::before { content: ""; width: 1px; margin: 6px; background: var(--wp--preset--color--line, currentColor); }

/* The letters, under the header. */
.aieo-brands__az {
	position: sticky;
	top: var(--rooster-sticky-top, 0px);
	z-index: 5;
	border-block: 1px solid var(--wp--preset--color--line, currentColor);
	background: var(--wp--preset--color--bg, Canvas);
}
.aieo-brands__az-list { display: flex; justify-content: space-between; margin: 0; padding: 0; list-style: none; }
.aieo-brands__az-list > li { flex: 1 1 0; display: grid; margin: 0; }
.aieo-brands__az a,
.aieo-brands__az span {
	position: relative;
	display: grid;
	place-items: center;
	min-width: 32px;
	min-height: 48px;
	color: var(--wp--preset--color--fg, currentColor);
	font-size: var(--wp--preset--font-size--sm);
	font-weight: 600;
	text-decoration: none;
	transition: background-color 160ms, color 160ms;
}
.aieo-brands__az span,
.aieo-brands__az a[aria-disabled="true"] { color: var(--wp--preset--color--muted, currentColor); font-weight: 400; opacity: .55; }
.aieo-brands__az a[aria-disabled="true"] { pointer-events: none; }
.aieo-brands__az a::after { content: ""; position: absolute; left: 20%; right: 20%; bottom: -1px; height: 2px; background: var(--wp--preset--color--fg, currentColor); transform: scaleX(0); transition: transform 240ms cubic-bezier(.2, .7, .2, 1); }
.aieo-brands__az a:hover { background: color-mix(in srgb, currentColor 6%, transparent); }
.aieo-brands__az a[aria-current="true"]::after { transform: scaleX(1); }
.aieo-brands__az a:focus-visible { outline: 2px solid var(--wp--preset--color--fg, currentColor); outline-offset: -4px; box-shadow: none; }

/* The count and «Show all». */
.aieo-brands__count { margin: var(--wp--preset--spacing--4) 0 0; color: var(--wp--preset--color--muted, currentColor); font-size: var(--wp--preset--font-size--sm); font-variant-numeric: tabular-nums; }
.aieo-brands__count b { color: var(--wp--preset--color--fg, currentColor); font-weight: 600; }
.aieo-brands__all { min-height: 24px; margin-left: 10px; padding: 0; border: 0; background: none; color: var(--wp--preset--color--fg, currentColor); font: inherit; font-weight: 600; text-decoration: underline; text-underline-offset: .2em; cursor: pointer; }
.aieo-brands__all[hidden] { display: none; }

/* The letters' sections: the big letter stays in view while its brands scroll. */
.aieo-brands__letter {
	display: grid;
	grid-template-columns: 120px minmax(0, 1fr);
	gap: var(--wp--preset--spacing--4);
	padding-block: var(--wp--preset--spacing--5);
	border-bottom: 1px solid var(--wp--preset--color--line, currentColor);
	scroll-margin-top: calc(var(--rooster-sticky-top, 0px) + 66px);
}
.aieo-brands__letter[hidden] { display: none; }
.aieo-brands .aieo-brands__glyph {
	position: sticky;
	top: calc(var(--rooster-sticky-top, 0px) + 72px);
	align-self: start;
	display: grid;
	gap: 6px;
	margin: 0;
	font-size: clamp(3rem, 2rem + 3vw, 4.5rem);
	line-height: .8;
}
.aieo-brands__n { color: var(--wp--preset--color--muted, currentColor); font-size: var(--wp--preset--font-size--xs); font-weight: 400; letter-spacing: 0; line-height: 1.4; font-variant-numeric: tabular-nums; }
.aieo-brands__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(264px, 1fr)); gap: var(--wp--preset--spacing--3); margin: 0; padding: 0; list-style: none; }

/* A brand's card. */
.aieo-brands__card { position: relative; margin: 0; border: 1px solid var(--wp--preset--color--line, currentColor); background: var(--wp--preset--color--bg, Canvas); transition: border-color 160ms; }
.aieo-brands__card[hidden] { display: none; }
.aieo-brands__card:hover,
.aieo-brands__card:focus-within { border-color: var(--wp--preset--color--fg, currentColor); }
.aieo-brands__link {
	display: grid;
	grid-template-columns: 56px minmax(0, 1fr);
	gap: var(--wp--preset--spacing--3);
	align-items: center;
	min-height: 88px;
	padding: var(--wp--preset--spacing--3) 52px var(--wp--preset--spacing--3) var(--wp--preset--spacing--3);
	color: inherit;
	text-decoration: none;
}
.aieo-brands__link:focus-visible { outline: 2px solid var(--wp--preset--color--fg, currentColor); outline-offset: -2px; box-shadow: none; }
.aieo-brands__mk {
	box-sizing: border-box;
	display: grid;
	place-items: center;
	width: 56px;
	aspect-ratio: 1;
	overflow: hidden;
	border: 1px solid var(--wp--preset--color--fg, currentColor);
	font-size: var(--wp--preset--font-size--sm);
	font-weight: 700;
	letter-spacing: .08em;
	transition: background-color 200ms, color 200ms;
}
.aieo-brands__mk.has-logo { padding: 6px; }
.aieo-brands__mk img { width: 100%; height: 100%; object-fit: contain; }
.aieo-brands__card:hover .aieo-brands__mk:not(.has-logo) { background: var(--wp--preset--color--fg, CanvasText); color: var(--wp--preset--color--bg, Canvas); }
.aieo-brands__card.is-out .aieo-brands__mk { border-color: var(--wp--preset--color--line, currentColor); color: var(--wp--preset--color--muted, currentColor); }
.aieo-brands__text { display: grid; gap: 2px; min-width: 0; font-size: var(--wp--preset--font-size--sm); }
.aieo-brands__name { font-size: var(--wp--preset--font-size--md); font-weight: 600; line-height: 1.25; }
.aieo-brands__name mark { background: var(--wp--custom--rooster--area--blush, var(--wp--preset--color--subtle)); color: var(--wp--custom--rooster--area--on-blush, inherit); }
.aieo-brands__meta,
.aieo-brands__cats { color: var(--wp--preset--color--muted, currentColor); font-size: var(--wp--preset--font-size--xs); font-variant-numeric: tabular-nums; }
.aieo-brands__soon { color: var(--wp--preset--color--warning-ink, currentColor); font-weight: 600; }
.aieo-brands__tags { position: absolute; top: -1px; left: -1px; display: flex; gap: 2px; }
.aieo-brands__tag { padding: 2px 6px; background: var(--wp--preset--color--fg, CanvasText); color: var(--wp--preset--color--bg, Canvas); font-size: 10px; font-weight: 600; letter-spacing: var(--wp--custom--rooster--tracking--wide, 0.08em); line-height: 1.4; text-transform: uppercase; }
.aieo-brands__card .aieo-brands__fav { position: absolute; top: 4px; right: 4px; }

/* Nothing matches. */
.aieo-brands__none { padding-block: var(--wp--preset--spacing--7); text-align: center; }
.aieo-brands__none[hidden] { display: none; }
.aieo-brands__none-title { margin: 0 0 var(--wp--preset--spacing--3); font-size: var(--wp--preset--font-size--xl); }
.aieo-brands__none p { margin: 0 auto var(--wp--preset--spacing--4); max-width: 46ch; color: var(--wp--preset--color--muted, currentColor); }
.aieo-brands__none .aieo-brands__reset { justify-content: center; }

@media (max-width: 1023px) {
	.aieo-brands__focus { grid-template-columns: minmax(0, 1fr); }
	.aieo-brands__fc { min-height: 160px; }
	.aieo-brands__letter { grid-template-columns: 72px minmax(0, 1fr); }
	.aieo-brands__az-list { overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; justify-content: flex-start; }
	/* In a group with the page's side padding the row runs to the screen's edges. */
	.has-global-padding > .aieo-brands .aieo-brands__az { margin-inline: calc(-1 * var(--wp--style--root--padding-left, 0px)) calc(-1 * var(--wp--style--root--padding-right, 0px)); }
	.has-global-padding > .aieo-brands .aieo-brands__az-list { padding-inline: var(--wp--style--root--padding-left, 0px) var(--wp--style--root--padding-right, 0px); }
	.aieo-brands__az-list::-webkit-scrollbar { display: none; }
	.aieo-brands__az-list > li { flex: none; }
	.aieo-brands__az a,
	.aieo-brands__az span { min-width: 44px; }
}
@media (max-width: 767px) {
	.aieo-brands__head { padding-bottom: var(--wp--preset--spacing--5); }
	.aieo-brands__search { flex-basis: 100%; max-width: none; }
	.aieo-brands__chips { flex: 1 1 100%; }
	.aieo-brands__chips .aieo-subcats__list { flex-wrap: nowrap; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; padding-block: 4px; }
	.has-global-padding > .aieo-brands .aieo-brands__chips .aieo-subcats__list { margin-inline: calc(-1 * var(--wp--style--root--padding-left, 0px)) calc(-1 * var(--wp--style--root--padding-right, 0px)); padding-inline: var(--wp--style--root--padding-left, 0px) var(--wp--style--root--padding-right, 0px); }
	.aieo-brands__chips .aieo-subcats__list::-webkit-scrollbar { display: none; }
	.aieo-brands__chips .aieo-subcats__list > li { flex: none; }
	.aieo-brands__letter { grid-template-columns: minmax(0, 1fr); gap: var(--wp--preset--spacing--3); }
	.aieo-brands .aieo-brands__glyph { position: static; display: flex; align-items: baseline; gap: 12px; font-size: 2.5rem; }
	.aieo-brands__grid { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
	.aieo-brands__fc-img,
	.aieo-brands__fc-arrow,
	.aieo-brands__az a::after,
	.aieo-brands__mk { transition: none; }
}
@media (forced-colors: active) {
	.aieo-brands__az a[aria-current="true"]::after { background: Highlight; }
	.aieo-brands__chips .aieo-subcats__chip[aria-pressed="true"] { border-color: Highlight; }
}
