/* ==========================================================================
   VARIANT 3 — azulete blue, whitewash, geranium red and sierra pine;
   Newsreader and Source Sans 3; split hero (text beside the photo). Loaded after the shared stylesheets,
   so it only overrides. Colours come from tokens.css.
   ========================================================================== */

/* ---- Header: whitewash ---------------------------------------------------- */
.da-header {
	background: rgba(250, 248, 243, 0.97);
}

@supports (backdrop-filter: blur(8px)) {
	.da-header {
		background: rgba(250, 248, 243, 0.9);
	}
}

/* ---- Headings: Newsreader at a regular weight ----------------------------- */
h1,
h2,
h3,
.da-hero__title {
	font-weight: 500;
	letter-spacing: -0.01em;
	font-variation-settings: normal;
}

/* ---- Split hero ---------------------------------------------------------- */
.da-hero--split {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	align-items: stretch;
	min-height: 0;
	background: var(--da-surface);
	color: var(--da-ink);
}

.da-hero--split .da-hero__inner {
	order: 1;
	align-self: center;
	padding-block: clamp(3rem, 2rem + 5vw, 6.5rem) clamp(2.5rem, 2rem + 3vw, 4.5rem);
}

.da-hero--split .da-hero__media {
	position: relative;
	inset: auto;
	z-index: 0;
	order: 2;
	aspect-ratio: 4 / 3;
	border-top: 6px solid var(--da-terracotta);
}

.da-hero--split .da-hero__media::after {
	display: none;
}

/* The Mijas headline is a full sentence: one size below variant 2, on a wider measure,
   so the sub-copy and the buttons stay in the first screen. */
.da-hero--split .da-hero__title {
	max-width: 18ch;
	color: var(--da-ink);
	font-size: var(--da-fs-2xl);
	line-height: 1.08;
}

.da-hero--split .da-hero__text {
	color: var(--da-text);
}

.da-hero--split .da-hero__note {
	color: var(--da-text-muted);
}

.da-hero--split .da-eyebrow--light {
	color: var(--da-sage-strong);
}

.da-hero--split .da-btn--primary:hover {
	background: var(--da-blue);
	border-color: var(--da-blue);
	color: var(--da-white);
}

.da-hero--split .da-btn--ghost-light {
	border-color: var(--da-blue);
	color: var(--da-blue);
}

.da-hero--split .da-btn--ghost-light:hover {
	background: var(--da-blue);
	border-color: var(--da-blue);
	color: var(--da-white);
}

/* No hero photo yet: one column, no empty half. */
.da-hero--split:not(:has(.da-hero__media > *)) .da-hero__media {
	display: none;
}

@media (min-width: 960px) {
	.da-hero--split:not(:has(.da-hero__media > *)) {
		grid-template-columns: minmax(0, 1fr);
	}

	.da-hero--split {
		grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
		min-height: calc(86vh - var(--da-header-h));
		min-height: calc(86svh - var(--da-header-h));
	}

	.da-hero--split .da-hero__inner {
		width: auto;
		max-width: none;
		margin: 0;
		padding-inline: max(var(--da-gutter), calc((100vw - var(--da-container)) / 2 + var(--da-gutter))) clamp(2rem, 1rem + 3vw, 4.5rem);
	}

	.da-hero--split .da-hero__media {
		aspect-ratio: auto;
		border-top: 0;
		border-left: 6px solid var(--da-terracotta);
	}
}

/* ---- Homepage sections that would leave an empty half (as on variant 2) 
   Two sections have no photo slot ("The practical side of a new life", and
   "New developments" while no project is published): their text uses the
   full width. Two have a photo slot ("What could your life … look like?",
   "A budget in context"): while the slot has no photo, the text takes its
   place; once a photo is set, the shared two-column layout applies again by
   itself (the rules below only match a figure without an image). */

/* "The practical side of a new life": heading and introduction across the
   top, the guides in two columns below. */
@media (min-width: 960px) {
	.da-teasers .da-teasers__layout {
		grid-template-columns: minmax(0, 1fr);
		gap: var(--da-space-7);
	}

	.da-teasers .da-teasers__head {
		position: static;
		display: grid;
		grid-template-columns: 7fr 5fr;
		gap: var(--da-grid-gap);
		align-items: end;
	}

	.da-teasers .da-teasers__head .da-heading {
		margin-bottom: 0;
	}

	.da-teasers .da-teasers__list {
		display: grid;
		grid-template-columns: 1fr 1fr;
		column-gap: var(--da-grid-gap);
	}
}

/* "What could your life … look like?" without a photo: heading and
   introduction on the left, the guides on the right. */
.da-propertyed__grid:not(:has(.da-propertyed__figure img)) .da-propertyed__figure {
	display: none;
}

@media (min-width: 960px) {
	.da-propertyed__grid:not(:has(.da-propertyed__figure img)) {
		grid-template-columns: minmax(0, 1fr);
	}

	.da-propertyed__grid:not(:has(.da-propertyed__figure img)) .da-propertyed__body {
		display: grid;
		grid-template-columns: 5fr 7fr;
		column-gap: var(--da-space-9);
		align-items: start;
	}

	.da-propertyed__grid:not(:has(.da-propertyed__figure img)) .da-propertyed__body > .da-heading,
	.da-propertyed__grid:not(:has(.da-propertyed__figure img)) .da-propertyed__body > .da-lede {
		grid-column: 1;
	}

	.da-propertyed__grid:not(:has(.da-propertyed__figure img)) .da-propertyed__body > .da-teasers__list {
		grid-column: 2;
		grid-row: 1 / span 2;
	}

	.da-propertyed__grid:not(:has(.da-propertyed__figure img)) .da-propertyed__body > .da-propertyed__more {
		grid-column: 2;
	}
}

/* "A budget in context" without a photo: the heading, €300,000 and
   introduction on the left, centred against the list of areas on the right;
   the note and the button under the list. The two flexible rows above and
   below the left block share the list's spare height equally. */
.da-budget__grid:not(:has(.da-budget__figure img)) .da-budget__figure {
	display: none;
}

@media (min-width: 960px) {
	.da-budget__grid:not(:has(.da-budget__figure img)) {
		grid-template-columns: minmax(0, 1fr);
	}

	.da-budget__grid:not(:has(.da-budget__figure img)) .da-budget__body {
		display: grid;
		grid-template-columns: 5fr 6fr;
		grid-template-rows: 1fr auto auto auto 1fr auto auto;
		column-gap: var(--da-space-9);
		align-items: start;
	}

	.da-budget__grid:not(:has(.da-budget__figure img)) .da-budget__body > .da-eyebrow {
		grid-column: 1;
		grid-row: 2;
	}

	.da-budget__grid:not(:has(.da-budget__figure img)) .da-budget__body > .da-budget__title {
		grid-column: 1;
		grid-row: 3;
	}

	.da-budget__grid:not(:has(.da-budget__figure img)) .da-budget__body > .da-budget__intro {
		grid-column: 1;
		grid-row: 4;
	}

	.da-budget__grid:not(:has(.da-budget__figure img)) .da-budget__body > .da-budget__types {
		grid-column: 2;
		grid-row: 1 / 6;
		margin-top: 0;
	}

	.da-budget__grid:not(:has(.da-budget__figure img)) .da-budget__body > .da-budget__footnote {
		grid-column: 2;
		grid-row: 6;
	}

	.da-budget__grid:not(:has(.da-budget__figure img)) .da-budget__body > .da-btn {
		grid-column: 2;
		grid-row: 7;
		justify-self: start;
	}
}

/* "New developments" while no project is published: heading across the top,
   then the text and the list of details in three columns. */
@media (min-width: 960px) {
	.da-dev-pending {
		grid-template-columns: minmax(0, 1fr);
		gap: var(--da-space-6);
	}

	.da-dev-pending .da-heading__title {
		max-width: none;
	}

	.da-dev-pending__body > .da-lede {
		max-width: 60ch;
	}

	.da-dev-pending__list {
		grid-template-columns: repeat(3, 1fr);
	}
}

/* ---- Key figures (Living page): four figures in a row --------------------
   The list keeps every word of the text; the value is set large above its
   description, and the dash between them is kept for screen readers only. */
.da-keyfigures {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: var(--da-space-5);
	margin: var(--da-space-7) 0;
	padding: var(--da-space-6) 0;
	list-style: none;
	border-top: 1px solid var(--da-rule);
	border-bottom: 1px solid var(--da-rule);
}

.da-keyfigures > li {
	margin: 0;
	padding: 0;
	color: var(--da-text-muted);
	font-size: var(--da-fs-sm);
	line-height: 1.45;
}

.da-keyfigures > li::before {
	content: none;
}

.da-prose .da-keyfigures {
	padding-left: 0; /* aligned with the text column (no list indent) */
}

.da-keyfigures > li + li {
	margin-top: 0; /* the grid gap spaces the figures (no list spacing from .da-prose) */
}

.da-keyfigures__value {
	display: block;
	margin-bottom: var(--da-space-2);
	color: var(--da-ink);
	font-family: var(--da-font-serif);
	font-size: var(--da-fs-lg);
	font-weight: 500;
	line-height: 1.05;
}

.da-keyfigures__sep {
	position: absolute;
	width: 1px;
	height: 1px;
	overflow: hidden;
	clip-path: inset(50%);
	white-space: nowrap;
}

@media (min-width: 960px) {
	.da-keyfigures {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}
}
