.track-grid,
.gallery {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 22px;
	align-items: start;
}
.track-card > img,
.gallery img {
	width: 100%;
	height: auto;
	aspect-ratio: 1.82;
	object-fit: cover;
}
.track-card {
	border-bottom: 1px solid var(--line);
}
.track-card summary,
.questions summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	list-style: none;
}
summary::-webkit-details-marker {
	display: none;
}
.track-card summary {
	padding-block: 15px;
}
.track-card h3 {
	font: 400 clamp(26px, 2.2vw, 36px) / 1.1 var(--display);
	text-transform: uppercase;
}
summary span {
	font: 400 28px / 1 var(--body);
	transition: transform 0.2s;
}
details[open] > summary span {
	transform: rotate(45deg);
}
.track-card details p,
.questions details p {
	padding: 0 0 20px;
	line-height: 1.55;
}
.history {
	background: var(--night);
	color: var(--paper);
	padding-block: clamp(48px, 6vw, 100px);
}
.story-grid,
.visit-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	align-items: center;
	gap: clamp(35px, 7vw, 115px);
}
.story-grid figure img {
	width: 100%;
	height: auto;
	aspect-ratio: 1.4;
	object-fit: cover;
}
figcaption {
	margin-top: 8px;
	font: 600 13px var(--body);
	color: var(--pale);
}
.history h2 {
	margin-bottom: 24px;
}
.history p + p {
	margin-top: 12px;
}
.history .section-label,
.visit .section-label {
	color: var(--lime);
}
.history .section-label i,
.visit .section-label i {
	background: repeating-linear-gradient(
		90deg,
		var(--lime) 0 4px,
		transparent 4px 7px
	);
}
.trail {
	--wheel-size: clamp(144px, 13vw, 220px);
	--wheel-overrun: 0;
	--axle: calc(100vw - var(--wheel-size) * (0.5 - var(--wheel-overrun)) - 8px);
	--unprinted: 0px;
	height: calc(var(--wheel-size) + 30px);
	position: relative;
	overflow: hidden;
	isolation: isolate;
	background:
		#774526 url("../assets/terra-solta.webp") center / 248px auto repeat;
}
.trail-imprint {
	position: absolute;
	inset: 0;
	display: grid;
	place-items: center;
	padding: 0 calc(var(--wheel-size) * (1 - var(--wheel-overrun)) + 12px) 0
		var(--gutter);
	clip-path: inset(0 var(--unprinted) 0 0);
	background:
		url("../assets/terra-marcada.webp") left center / auto 100% repeat-x;
}
.trail-imprint span {
	width: min(100%, 1180px);
	height: 100%;
	font-size: 0;
	background:
		url("../assets/marca-na-argila.webp") center / 100% 100% no-repeat;
	mask-image: linear-gradient(to right, transparent, black 8% 92%, transparent);
}
.trail canvas {
	width: 100%;
	height: 100%;
	background: linear-gradient(to top, rgb(53 36 24 / 0.45), transparent 22px);
	position: absolute;
	inset: 0;
	z-index: 1;
}
.trail img {
	position: absolute;
	bottom: 8px;
	left: 0;
	width: var(--wheel-size);
	height: var(--wheel-size);
	z-index: 2;
	transform: translate3d(calc(var(--axle) - 50%), 0, 0)
		rotate(var(--turn, 0rad));
}
.gallery {
	gap: 20px 22px;
}
.gallery a {
	position: relative;
	display: block;
	overflow: hidden;
	background: var(--ink);
	color: var(--white);
}
.gallery img {
	aspect-ratio: 1.6;
	transition: transform 0.3s;
}
.gallery a:hover img {
	transform: scale(1.025);
}
.gallery a > span {
	position: absolute;
	inset: auto 0 0;
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 28px 16px 12px;
	background: linear-gradient(transparent, var(--overlay));
	font: 700 18px var(--narrow);
}
.gallery .icon {
	width: 15px;
	height: 15px;
}
.text-link {
	min-height: 40px;
	border-bottom: 1px solid var(--ink);
}
.text-link:hover,
.footer-row > a:last-child:hover {
	text-decoration: underline;
}
.visit {
	padding-block: clamp(52px, 6.4vw, 100px);
	background: var(--olive) url("../assets/terrain.svg") center / cover;
	color: var(--paper);
}
.visit-grid {
	align-items: start;
}
address {
	font: 400 21px / 1.45 var(--body);
	margin: 22px 0;
}
.questions > h3 {
	font: 400 30px var(--display);
	text-transform: uppercase;
	margin-bottom: 15px;
}
.questions details {
	border-block-start: 1px solid var(--pale);
}
.questions details:last-child {
	border-block-end: 1px solid var(--pale);
}
.questions summary {
	padding: 17px 0;
	font: 600 18px var(--body);
}
footer {
	padding-block: 28px;
}
.footer-row > span {
	color: var(--muted);
	font-size: 14px;
}
dialog {
	width: min(900px, calc(100% - 32px));
	max-height: 94dvh;
	border: 0;
	padding: 14px;
	background: var(--night);
	color: var(--paper);
}
dialog::backdrop {
	background: var(--overlay);
}
.viewer-top,
.viewer-bottom {
	display: flex;
	align-items: center;
	gap: 8px;
}
.viewer-top {
	justify-content: space-between;
	margin-bottom: 10px;
}
.viewer-bottom {
	margin-top: 10px;
}
.viewer-bottom p {
	margin-right: auto;
}
#viewer-image {
	max-height: 70dvh;
	width: 100%;
	object-fit: contain;
}
.viewer-top span {
	font: 700 16px var(--narrow);
}
@media (max-width: 800px) {
	.track-grid,
	.gallery {
		gap: 14px;
	}
	.story-grid,
	.visit-grid {
		gap: 28px;
	}
	.visit-actions {
		align-items: flex-start;
	}
}
@media (max-width: 680px) {
	.track-grid,
	.story-grid,
	.visit-grid {
		grid-template-columns: minmax(0, 1fr);
	}
	.track-grid {
		gap: 28px;
	}
	.story-grid,
	.visit-grid {
		gap: 32px;
	}
	.gallery {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 10px;
	}
	.gallery img {
		aspect-ratio: 1.12;
	}
	.gallery a > span {
		padding: 24px 8px 8px;
		font-size: 15px;
	}
	.gallery a > span .icon {
		display: none;
	}
	.trail {
		--wheel-size: clamp(116px, 29vw, 144px);
		--wheel-overrun: 0.94;
		height: calc(var(--wheel-size) + 24px);
	}
	.trail-imprint {
		background:
			url("../assets/marca-na-argila-movel.webp") center / 100% 100% no-repeat;
	}
	.trail-imprint span {
		background: none;
	}
	.footer-row > .brand {
		width: 100%;
	}
	.footer-row {
		gap: 16px;
	}
	address {
		font-size: 19px;
	}
}
