/* Purple Mouthed Section Headers: the photo header on Tastes, Travels, and Tales.
   Uses the theme's own colours and fonts (with fallbacks). */

.pmx-section {
	--pmx-wine: var(--pm-wine, #541c34);
	--pmx-butter: var(--pm-butter, #fef9cf);
	--pmx-neon: var(--pm-neon, #d8f043);
	--pmx-heading: var(--pm-heading, Montserrat, "Helvetica Neue", Helvetica, Arial, sans-serif);
	--pmx-body: var(--pm-body, Figtree, "Helvetica Neue", Helvetica, Arial, sans-serif);
	--pmx-overlap: 54px;
	color: var(--pmx-wine);
}

/* Photo with the butter panel sitting on its bottom edge, like the homepage */
.pmx-hero { position: relative; min-height: 608px; display: flex; align-items: flex-end; background: var(--pmx-wine); }
.pmx-hero__photo { position: absolute; inset: 0; margin: 0; overflow: hidden; }
.pmx-hero__photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; display: block; }

.pmx-panel {
	position: relative; z-index: 1; box-sizing: border-box;
	width: min(560px, 90%);
	margin: 0 0 calc(-1 * var(--pmx-overlap)) var(--pm-gutter, 5vw);
	padding: clamp(28px, 2.7vw, 40px) clamp(28px, 3vw, 44px);
	background: rgba(254, 249, 207, 0.95);
	box-shadow: 0 0 0 1px var(--pmx-wine);
	display: flex; flex-direction: column; gap: 16px;
}
.pmx-panel > * { margin: 0 !important; }

.pmx-kicker { font-family: var(--pmx-heading); font-weight: 700; font-size: 13px; line-height: 1.4; letter-spacing: 0.16em; text-transform: uppercase; }
.pmx-kicker a { color: inherit; text-decoration: none; }

.pmx-title {
	font-family: var(--pmx-heading) !important; font-weight: 700 !important;
	font-size: clamp(28px, 2.9vw, 40px) !important; line-height: 1.06 !important; letter-spacing: 0 !important;
	text-transform: uppercase; text-wrap: balance; color: inherit;
}
.pmx-mark {
	text-decoration: underline; text-decoration-color: var(--pmx-neon);
	text-decoration-thickness: 0.38em; text-underline-offset: -0.18em; text-decoration-skip-ink: none;
}

.pmx-intro { font-family: var(--pmx-body); font-size: clamp(17px, 1.35vw, 19px); line-height: 1.5; text-wrap: pretty; }
.pmx-intro p { margin: 0 0 0.8em; }
.pmx-intro p:last-child { margin-bottom: 0; }

/* Tastes · Travels · Tales · All stories */
.pmx-cats { padding: calc(var(--pmx-overlap) + clamp(32px, 3.6vw, 52px)) var(--pm-gutter, 5vw) 0; }
.pmx-cats ul {
	list-style: none; margin: 0; padding: 0;
	display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 0 0.7em;
	font-family: var(--pmx-heading); font-weight: 600; font-size: clamp(16px, 1.56vw, 22px);
	letter-spacing: 0.16em; text-transform: uppercase; line-height: 1.5; text-wrap: balance;
}
.pmx-cats li { display: inline-flex; align-items: center; gap: 0.7em; }
.pmx-cats li + li::before { content: "·"; }
.pmx-cats a {
	display: inline-flex; align-items: center; min-height: 44px; color: inherit;
	text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 0.35em;
	text-decoration-color: color-mix(in srgb, currentColor 40%, transparent);
}
.pmx-cats a:hover, .pmx-cats a:focus-visible { text-decoration-color: currentColor; }
.pmx-cats a[aria-current="page"] { font-weight: 700; text-decoration-color: currentColor; text-decoration-thickness: 2px; }

/* Phones and small tablets: photo on top, panel underneath */
@media (max-width: 849px) {
	.pmx-hero { display: block; min-height: 0; }
	.pmx-hero__photo { position: static; }
	.pmx-hero__photo img { height: 320px; }
	.pmx-panel {
		width: 100%; margin: 0; padding: 40px 24px 44px;
		background: var(--pmx-butter); box-shadow: none; border-bottom: 1px solid var(--pmx-wine);
	}
	.pmx-title { font-size: 30px !important; }
	.pmx-cats { padding: 24px 24px 0; }
	.pmx-cats ul { font-size: 14px; letter-spacing: 0.1em; }
}
