/*
 * contact.css — the Yhteystiedot page (D5).
 *
 * Three editorial moments: the contact split (e-mail + phone set large — on
 * this page they ARE the content), Henkilöstö with a real film frame, and the
 * form on a pale band. Replaces the old flat contact-card stack that left the
 * right half of a desktop screen empty.
 */

/* ---- 1 · Contact split ---- */
.contact-split {
	display: grid;
	gap: var(--s-12);
}

.contact-split__badge {
	margin: 0 0 var(--s-8);
	max-width: none;
}

/* E-mail and phone as display-size rows: label left small, value big serif. */
.contact-hero {
	margin: 0;
	max-width: none;
}

.contact-hero__row {
	padding-block: var(--s-6);
	border-top: 1px solid var(--line);
}

.contact-hero__row:last-child {
	border-bottom: 1px solid var(--line);
}

.contact-hero__row dt {
	font-size: var(--fs-small);
	font-weight: 600;
	letter-spacing: var(--tracking-eyebrow);
	text-transform: uppercase;
	color: var(--text-muted);
}

.contact-hero__row dd {
	margin: var(--s-2) 0 0;
}

.contact-hero__link {
	font-family: var(--font-display);
	font-size: clamp(1.625rem, 3.8vw, 3.25rem);
	font-weight: 500;
	line-height: var(--lh-heading);
	color: var(--ink);
	text-decoration: none;
	overflow-wrap: anywhere; /* a long address must never widen the page */
	transition: color var(--dur-fast) var(--ease);
}

.contact-hero__link:hover {
	color: var(--koivu);
}

/* ---- Hours panel (pale, quiet) ---- */
.hours-panel {
	padding: clamp(var(--s-6), 3vw, var(--s-8));
	background: var(--bg-alt);
	border-radius: var(--radius);
}

.hours-panel__title {
	margin: 0 0 var(--s-4);
	font-family: var(--font-display);
	font-size: 1.25rem;
	font-weight: 500;
}

.hours-panel__list {
	margin: 0;
	max-width: none;
}

.hours-panel__row {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: var(--s-2) var(--s-4);
	padding-block: var(--s-3);
	border-top: 1px solid var(--line);
}

.hours-panel__row dt {
	color: var(--text-muted);
	font-size: var(--fs-small);
}

.hours-panel__row dd {
	margin: 0;
	font-family: var(--font-display);
	font-size: 1.0625rem;
	color: var(--ink);
}

.hours-panel__note {
	margin: var(--s-4) 0 0;
	font-size: var(--fs-small);
	color: var(--text-muted);
}

/* ---- Office card: the real door, its glass carrying the same hours ---- */
.office-card {
	margin-top: var(--s-8);
	background: var(--card);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	overflow: hidden;
	box-shadow: var(--shadow-card);
}

.office-card__photo {
	width: 100%;
	aspect-ratio: 3 / 2;
	object-fit: cover;
}

.office-card__body {
	padding: var(--s-6);
}

.office-card__title {
	margin: 0 0 var(--s-2);
	font-family: var(--font-display);
	font-size: 1.25rem;
	font-weight: 500;
}

.office-card__text {
	margin: 0 0 var(--s-2);
	font-size: var(--fs-small);
	color: var(--text-muted);
	max-width: none;
}

.office-card__text:last-child {
	margin-bottom: 0;
}

/* ---- 2 · Henkilöstö ---- */
.team {
	border-top: 1px solid var(--line);
}

.team__head {
	display: grid;
	gap: var(--s-4);
	margin-bottom: var(--s-12);
}

.team__title {
	margin: 0;
	font-family: var(--font-display);
	font-size: var(--fs-h2);
	font-weight: 500;
}

.team__lead {
	margin: 0;
	max-width: 55ch;
	color: var(--text-muted);
}

/*
 * PLACEHOLDER MARKING — delete together with .team__initials--pending once
 * the 7.9.2026 shoot's portraits are in (brief 04 §5). Same reasoning as the
 * testimonial placeholder note: a reviewer must not mistake initials for a
 * finished design decision, so the page says plainly that photos are coming.
 * Understated on purpose — a note to the client, not a broken page.
 */
.team__photo-note {
	margin: 0;
	max-width: 55ch;
	padding-left: var(--s-4);
	border-left: 2px solid var(--koivu);
	font-size: var(--fs-small);
	line-height: var(--lh-body);
	color: var(--muted);
}

/* The real team, from their own film — the section opens with people. */
.team__photo {
	margin: 0 0 var(--s-16);
}

.team__photo img {
	width: 100%;
	aspect-ratio: 21 / 9;
	object-fit: cover;
	border-radius: var(--radius);
}

.team__list {
	display: grid;
	gap: var(--s-12) var(--s-8);
	margin: 0;
	padding: 0;
	max-width: none;
	list-style: none;
}

/*
 * A person is a row with a mark, not a boxed card: nine boxes would read as a
 * product grid. The initials stand in until real portraits arrive (A9).
 */
.team__member {
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: var(--s-4);
	align-items: start;
	padding-top: var(--s-6);
	border-top: 1px solid var(--line);
}

.team__initials {
	display: grid;
	place-items: center;
	width: 56px;
	height: 56px;
	border-radius: 50%;
	background: var(--bg-alt);
	border: 1px solid var(--line);
	font-family: var(--font-display);
	font-size: 1.0625rem;
	color: var(--koivu);
}

/*
 * Dashed while it is a waiting slot, matching the placeholder quote cards —
 * one visual language for "this is not finished yet" across the site.
 *
 * The border COLOUR has to be restated, not just the style: the base rule's
 * --line is rgba(61,41,18,0.12), which against the tan fill renders the dash
 * pattern completely invisible — the rule would compute as "dashed" while
 * showing nothing, which reads as working to the next person to touch it.
 * --muted is the quietest token that actually resolves the dashes.
 */
.team__initials--pending {
	border-style: dashed;
	border-color: var(--muted);
}

/* The real portrait, once the slot is filled — same 56px mark, so the row
   rhythm is identical before and after the shoot. */
.team__portrait {
	width: 56px;
	height: 56px;
	border-radius: 50%;
	object-fit: cover;
}

.team__name {
	margin: 0;
	font-family: var(--font-display);
	font-size: 1.25rem;
	font-weight: 500;
	/*
	 * A person's name is NEVER hyphenated or balanced: the global h1–h3
	 * text-wrap: balance split "Kaisa Näreranta" across two lines, and with
	 * hyphenation on that became "Kai-sa". Names break at spaces or not at all.
	 */
	text-wrap: normal;
	-webkit-hyphens: manual; /* Safari still needs the prefix. */
	hyphens: manual;
}

/*
 * Job titles may hyphenate. Finnish ones are long compounds
 * ("Kiinteistöassistentti") and the global overflow-wrap would otherwise snap
 * one at an arbitrary point; the page declares lang="fi", which is what makes
 * proper Finnish hyphenation patterns apply.
 */
.team__role {
	margin: 2px 0 0;
	color: var(--ink);
	-webkit-hyphens: auto; /* Safari still needs the prefix. */
	hyphens: auto;
}

.team__quals {
	margin: 2px 0 0;
	font-size: var(--fs-small);
	color: var(--muted);
}

.team__contact {
	margin: var(--s-2) 0 0;
	font-size: var(--fs-small);
	display: flex;
	flex-wrap: wrap;
	gap: var(--s-2) var(--s-4);
	max-width: none;
}

/* (The form band — pale band, intro left, white panel right — lives in
   components/form-band.css, shared with Tarjouspyyntö.) */

/* ---- Wide screens ---- */
@media (min-width: 700px) {
	.team__list {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (min-width: 900px) {
	/* Asymmetric 7/5: the channels carry the weight, the aside supports.
	   Centered vertically — the aside is taller, and a top-aligned short
	   column left a dead corner under the phone number. */
	.contact-split {
		grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
		gap: clamp(var(--s-12), 6vw, var(--s-24));
		align-items: center;
	}

	.team__head {
		grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
		align-items: end;
	}

	.team__lead {
		justify-self: end;
		text-align: right;
	}

}

/*
 * Three people per row only once a column is genuinely wide enough for a
 * Finnish job title next to the initials mark. At 1024 it was not, and the
 * titles broke mid-word.
 */
@media (min-width: 1240px) {
	.team__list {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

/* ---- Toimiston sijainti (map) ----
 *
 * Their page runs the map at roughly half the width beside the contact panel.
 * Our right column is the narrow one (hours + office card), so the map gets a
 * band of its own instead of being squeezed into it: same 16px radius as their
 * frame, and a ratio rather than a fixed height so it never letterboxes on a
 * phone. See the privacy note in page-yhteystiedot.php before shipping this.
 */
.office-map {
	padding-block: 0 var(--s-16);
}

.office-map__frame {
	overflow: hidden; /* clips the iframe's square corners to the radius */
	border: 1px solid var(--line);
	border-radius: var(--radius);
	line-height: 0; /* kills the inline-frame descender gap */
}

.office-map__frame iframe {
	display: block;
	width: 100%;
	height: 100%;
	aspect-ratio: 4 / 3;
	border: 0;
}

@media (min-width: 768px) {
	.office-map__frame iframe {
		aspect-ratio: 21 / 9;
	}
}
