/* MM Brands – brand overview grid + brand detail page */

.mm-brand-list [hidden] { display: none !important; }

.mm-brand-filter { margin: 0 0 24px; }
.mm-brand-filter-input {
	width: 100%;
	max-width: 360px;
	padding: 10px 14px;
	border: 1px solid rgba(0, 0, 0, .2);
	border-radius: 3px;
	box-sizing: border-box;
}

.mm-brand-grid {
	--mm-cols: 4;
	display: grid;
	grid-template-columns: repeat(var(--mm-cols), 1fr);
	gap: 30px 24px;
	margin: 0;
	padding: 0;
	list-style: none;
}
.mm-cols-1 .mm-brand-grid { --mm-cols: 1; }
.mm-cols-2 .mm-brand-grid { --mm-cols: 2; }
.mm-cols-3 .mm-brand-grid { --mm-cols: 3; }
.mm-cols-4 .mm-brand-grid { --mm-cols: 4; }
.mm-cols-5 .mm-brand-grid { --mm-cols: 5; }
.mm-cols-6 .mm-brand-grid { --mm-cols: 6; }

.mm-brand-item { margin: 0; padding: 0; text-align: center; }
.mm-brand-item a {
	display: block;
	text-decoration: none;
	color: inherit;
	transition: transform .2s ease;
}
.mm-brand-item a:hover { transform: translateY(-3px); }

.mm-brand-thumb {
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	border: 1px solid rgba(0, 0, 0, .08);
	background: #fff;
}
.mm-brand-thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: contain;
}
.mm-brand-name {
	display: block;
	margin-top: 10px;
	font-weight: 600;
	line-height: 1.3;
}

/* Brand detail page */
.mm-brand-header {
	display: flex;
	gap: 32px;
	align-items: center;
	margin: 0 0 40px;
}
.mm-brand-header .mm-brand-logo { flex: 0 0 220px; max-width: 220px; }
.mm-brand-header .mm-brand-logo img { width: 100%; height: auto; }
.mm-brand-header h1 { margin-top: 0; }
.mm-brand-pagination { margin-top: 30px; text-align: center; }

@media (max-width: 989px) {
	.mm-cols-5 .mm-brand-grid, .mm-cols-6 .mm-brand-grid { --mm-cols: 4; }
}
@media (max-width: 767px) {
	.mm-brand-grid { --mm-cols: 2 !important; gap: 20px 14px; }
	.mm-brand-header { flex-direction: column; text-align: center; }
}