.msd-directory {
	--msd-accent: #b89470;
	--msd-accent-dark: #8c6847;
	--msd-ink: #2f2b28;
	--msd-muted: #716b66;
	--msd-surface: #f7f3ef;
	--msd-border: #e5dbd1;
	--msd-radius: 5px;
	padding-block: 48px 64px;
	color: var(--msd-ink);
}

.msd-container {
	width: min(1180px, calc(100% - 40px));
	margin-inline: auto;
}

.msd-archive-header {
	position: relative;
	display: grid;
	grid-template-columns: minmax(220px, .72fr) minmax(0, 1.8fr);
	align-items: center;
	gap: clamp(28px, 4vw, 58px);
	overflow: hidden;
	margin-bottom: 28px;
	padding: clamp(26px, 4vw, 46px);
	border: 1px solid var(--msd-border);
	border-radius: var(--msd-radius);
	background: linear-gradient(135deg, #f1e8df 0%, var(--msd-surface) 52%, #fff 100%);
	box-shadow: 0 12px 34px rgb(61 48 36 / 7%);
}

.msd-archive-header::before {
	position: absolute;
	top: 22px;
	bottom: 22px;
	left: clamp(250px, 28%, 330px);
	width: 1px;
	background: linear-gradient(to bottom, transparent, #cfb79f 20%, #cfb79f 80%, transparent);
	content: "";
}

.msd-archive-title {
	position: relative;
	z-index: 1;
	margin-top: 0;
	margin-bottom: 0;
	font-size: clamp(2.5rem, 4vw, 4.4rem);
	line-height: .98;
}

.msd-archive-description {
	position: relative;
	z-index: 1;
	columns: 2 260px;
	column-gap: clamp(24px, 3vw, 42px);
	font-size: .98rem;
	line-height: 1.68;
}

.msd-archive-description > :first-child {
	margin-top: 0;
}

.msd-archive-description > :last-child {
	margin-bottom: 0;
}

.msd-filters {
	display: flex;
	flex-wrap: wrap;
	align-items: end;
	gap: 18px;
	margin: 0 0 36px;
	padding: 22px 24px;
	border: 1px solid var(--msd-border);
	border-radius: var(--msd-radius);
	background: var(--msd-surface);
	box-shadow: 0 10px 30px rgb(61 48 36 / 6%);
}

.msd-filter-field {
	display: grid;
	flex: 1 1 230px;
	gap: 7px;
	min-width: 190px;
	margin: 0;
}

.msd-filter-label {
	color: var(--msd-ink);
	font-size: .78rem;
	font-weight: 700;
	letter-spacing: .045em;
	text-transform: uppercase;
}

.msd-directory .msd-filters select {
	width: 100%;
	min-height: 46px;
	padding: 0 42px 0 14px;
	border: 1px solid #d8cabc;
	border-radius: var(--msd-radius);
	background-color: #fff;
	color: var(--msd-ink);
}

.msd-directory .msd-filter-submit {
	min-height: 46px;
	padding: 0 24px;
	border: 1px solid var(--msd-accent);
	border-radius: var(--msd-radius);
	background: var(--msd-accent);
	color: #fff;
	font-weight: 700;
	transition: background-color .2s ease, border-color .2s ease, transform .2s ease;
}

.msd-directory .msd-filter-submit:hover,
.msd-directory .msd-filter-submit:focus-visible {
	border-color: var(--msd-accent-dark);
	background: var(--msd-accent-dark);
	color: #fff;
	transform: translateY(-1px);
}

.msd-filter-reset {
	align-self: center;
	padding: 10px 4px;
	color: var(--msd-accent-dark);
	font-weight: 600;
}

.msd-archive-layout {
	display: grid;
	gap: 36px;
}

.msd-archive-layout--with-sidebar {
	grid-template-columns: minmax(0, 1fr) minmax(250px, 300px);
}

.msd-archive-results,
.msd-sidebar {
	min-width: 0;
}

.msd-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 26px;
}

.msd-archive-layout--with-sidebar .msd-grid {
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

.msd-card {
	position: relative;
	display: flex;
	min-width: 0;
	min-height: 100%;
	flex-direction: column;
	overflow: hidden;
	border: 1px solid var(--msd-border);
	border-radius: var(--msd-radius);
	background: #fff;
	box-shadow: 0 10px 30px rgb(61 48 36 / 7%);
	transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.msd-card:hover {
	transform: translateY(-3px);
	border-color: #d5c1ad;
	box-shadow: 0 16px 38px rgb(61 48 36 / 12%);
}

.msd-card--featured {
	border-color: var(--msd-accent);
	box-shadow: 0 14px 38px rgb(141 104 71 / 18%);
}

.msd-promo-badge {
	position: absolute;
	z-index: 2;
	top: 14px;
	left: 14px;
	display: inline-flex;
	align-items: center;
	min-height: 28px;
	padding: 5px 11px;
	border-radius: 999px;
	background: var(--msd-accent-dark);
	box-shadow: 0 5px 14px rgb(61 48 36 / 20%);
	color: #fff;
	font-size: .72rem;
	font-weight: 800;
	letter-spacing: .07em;
	line-height: 1;
	text-transform: uppercase;
}

.msd-card-image {
	display: flex;
	aspect-ratio: 4 / 3;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	border-bottom: 1px solid #eee7e0;
	background: #fff;
}

.msd-card-image img {
	display: block;
	width: 82%;
	height: 72%;
	max-width: none;
	object-fit: contain;
	object-position: center;
}

.msd-card-placeholder {
	display: block;
	width: 100%;
	height: 100%;
	background: linear-gradient(135deg, #f8f5f2, #eee5dc);
}

.msd-card-body {
	display: flex;
	flex: 1;
	flex-direction: column;
	align-items: flex-start;
	padding: 22px;
}

.msd-directory h2.msd-card-title {
	margin: 0 0 9px;
	font-family: Roboto, Arial, sans-serif;
	font-size: 1.3rem;
	font-weight: 800;
	letter-spacing: -.015em;
	line-height: 1.25;
}

.msd-directory .msd-card-title a {
	color: var(--msd-ink);
}

.msd-card-address {
	margin: 0 0 13px;
	color: var(--msd-muted);
	font-size: .94rem;
}

.msd-card-excerpt {
	display: -webkit-box;
	overflow: hidden;
	margin: 0 0 18px;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 3;
	color: #514b46;
	line-height: 1.55;
}

.msd-card-more {
	margin-top: auto;
	color: var(--msd-accent-dark);
	font-weight: 700;
}

.msd-sidebar .sidebar {
	width: 100%;
}

.msd-sidebar .widget {
	overflow: hidden;
	margin-bottom: 28px;
	border-radius: var(--msd-radius);
}

.msd-sidebar img {
	max-width: 100%;
	height: auto;
}

.msd-directory .navigation.pagination {
	margin-top: 38px;
}

.msd-directory .nav-links {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.msd-directory .page-numbers {
	display: inline-flex;
	min-width: 42px;
	min-height: 42px;
	align-items: center;
	justify-content: center;
	padding: 7px 12px;
	border: 1px solid var(--msd-border);
	border-radius: var(--msd-radius);
	background: #fff;
}

.msd-directory .page-numbers.current,
.msd-directory a.page-numbers:hover {
	border-color: var(--msd-accent);
	background: var(--msd-accent);
	color: #fff;
}

.msd-single-layout {
	display: grid;
	gap: 36px;
	max-width: 1180px;
	margin-inline: auto;
}

.msd-single-layout--with-sidebar {
	grid-template-columns: minmax(0, 1fr) minmax(250px, 300px);
}

.msd-entry {
	min-width: 0;
	max-width: 1040px;
	margin-inline: auto;
}

.msd-single-layout--with-sidebar .msd-entry {
	max-width: none;
	margin-inline: 0;
}

.msd-entry-header {
	display: grid;
	position: relative;
	grid-template-columns: minmax(190px, 250px) minmax(0, 1fr);
	align-items: center;
	gap: clamp(28px, 5vw, 56px);
	margin-bottom: 36px;
	padding: clamp(24px, 4vw, 44px);
	border: 1px solid var(--msd-border);
	border-radius: var(--msd-radius);
	background: var(--msd-surface);
	box-shadow: 0 14px 40px rgb(61 48 36 / 8%);
}

.msd-entry-header-art {
	position: absolute;
	z-index: 0;
	top: 0;
	right: 0;
	bottom: 0;
	width: 68%;
	border-radius: inherit;
	background-image: var(--msd-entry-header-image);
	background-position: center;
	background-size: cover;
	filter: saturate(.75) sepia(.12);
	mask-image: linear-gradient(to left, #000 0%, rgb(0 0 0 / 92%) 38%, transparent 100%);
	opacity: .18;
}

.msd-entry-header > :not(.msd-entry-header-art) {
	position: relative;
	z-index: 1;
}

.msd-entry-header--featured {
	border-color: var(--msd-accent);
}

.msd-entry-logo {
	display: flex;
	min-height: 190px;
	aspect-ratio: 1;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	border: 1px solid #eee7e0;
	border-radius: var(--msd-radius);
	background: #fff;
}

.msd-entry-logo img {
	display: block;
	width: 82%;
	height: 72%;
	max-width: none;
	object-fit: contain;
}

.msd-entry-summary {
	min-width: 0;
}

.msd-promo-badge--single {
	position: static;
	margin-bottom: 14px;
}

.msd-directory h1.msd-entry-title {
	margin-top: 0;
	margin-bottom: 18px;
	font-family: Roboto, Arial, sans-serif;
	font-size: clamp(2rem, 4vw, 3.25rem);
	font-weight: 800;
	letter-spacing: -.025em;
	line-height: 1.08;
}

.msd-contact {
	display: flex;
	flex-wrap: wrap;
	gap: 9px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.msd-contact li {
	margin: 0;
	padding: 8px 12px;
	border: 1px solid #dfd4c9;
	border-radius: 999px;
	background: #fff;
	color: #554e48;
	font-size: .92rem;
}

.msd-contact a {
	color: var(--msd-accent-dark);
	font-weight: 600;
}

.msd-entry-surface,
.msd-entry-section {
	margin-top: 28px;
	padding: clamp(22px, 4vw, 38px);
	border: 1px solid var(--msd-border);
	border-radius: var(--msd-radius);
	background: #fff;
	box-shadow: 0 10px 30px rgb(61 48 36 / 5%);
}

.msd-entry-content {
	font-size: 1.03rem;
	line-height: 1.78;
}

.msd-entry-content > :first-child,
.msd-entry-section > :first-child {
	margin-top: 0;
}

.msd-entry-content > :last-child,
.msd-entry-section > :last-child {
	margin-bottom: 0;
}

.msd-entry-section h2 {
	margin-bottom: 20px;
}

.msd-map {
	width: 100%;
	height: 400px;
	overflow: hidden;
	border-top: 1px solid var(--msd-border);
	border-radius: 0 0 var(--msd-radius) var(--msd-radius);
	background: #eee;
}

.msd-map-section {
	overflow: hidden;
	padding: 0;
}

.msd-map-section h2 {
	margin: 0;
	padding: 24px clamp(22px, 4vw, 38px);
}

.msd-map > .msd-map-link {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	padding: 20px;
	text-align: center;
}

.msd-gallery-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 12px;
}

.msd-gallery-grid a {
	display: block;
	overflow: hidden;
	border-radius: var(--msd-radius);
}

.msd-gallery-grid img {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	height: auto;
	object-fit: cover;
}

.msd-related a {
	display: grid;
	grid-template-columns: 180px 1fr;
	align-items: center;
	gap: 20px;
}

.msd-related img {
	width: 100%;
	height: auto;
	border-radius: var(--msd-radius);
}

@media (max-width: 960px) {
	.msd-archive-layout--with-sidebar,
	.msd-single-layout--with-sidebar {
		grid-template-columns: 1fr;
	}

	.msd-grid,
	.msd-archive-layout--with-sidebar .msd-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.msd-sidebar {
		margin-top: 8px;
	}
}

@media (max-width: 800px) {
	.msd-archive-header {
		grid-template-columns: 1fr;
		gap: 20px;
	}

	.msd-archive-header::before {
		display: none;
	}

	.msd-archive-description {
		columns: auto;
	}

	.msd-entry-header {
		grid-template-columns: 1fr;
	}

	.msd-entry-logo {
		width: min(250px, 100%);
	}

	.msd-gallery-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 560px) {
	.msd-container {
		width: min(100% - 28px, 1180px);
	}

	.msd-directory {
		padding-block: 32px 48px;
	}

	.msd-filters {
		display: grid;
		padding: 18px;
	}

	.msd-filter-field {
		min-width: 0;
	}

	.msd-directory .msd-filter-submit {
		width: 100%;
	}

	.msd-grid,
	.msd-archive-layout--with-sidebar .msd-grid {
		grid-template-columns: 1fr;
	}

	.msd-entry-header {
		padding: 20px;
	}

	.msd-entry-header-art {
		width: 100%;
		mask-image: linear-gradient(to top, #000 0%, rgb(0 0 0 / 70%) 45%, transparent 100%);
		opacity: .12;
	}

	.msd-entry-logo {
		width: min(210px, 100%);
		min-height: 170px;
	}

	.msd-contact {
		display: grid;
	}

	.msd-contact li {
		border-radius: 999px;
	}

	.msd-gallery-grid,
	.msd-related a {
		grid-template-columns: 1fr;
	}
}
