/* Optional editorial timeline. Content remains editable Core blocks. */
.agency-history {
	--history-ink: var(--wp--preset--color--ink, #152432);
	--history-gold: var(--wp--preset--color--accent-light, #ffd639);
	--history-paper: var(--wp--preset--color--canvas, #faf7ef);
	box-sizing: border-box;
	padding: clamp(48px, 7vw, 88px) 24px 48px;
	background: var(--history-ink);
	color: var(--history-paper);
	border-bottom: 1px solid color-mix(in srgb, var(--history-paper) 18%, transparent);
}
.agency-history *, .agency-history *::before { box-sizing: border-box; }
.agency-history > .agency-history__inner { max-width: 1240px; margin-inline: auto; }
.agency-history .agency-history__eyebrow {
	margin: 0 0 20px;
	color: var(--history-gold);
	font-size: 13px;
	letter-spacing: .12em;
}
.agency-history .agency-history__intro { max-width: 820px; margin-bottom: 42px; }
.agency-history .agency-history__intro h2 {
	margin: 0 0 20px;
	color: inherit;
	font-size: clamp(28px, 3.5vw, 46px);
	line-height: 1.3;
	text-wrap: balance;
}
.agency-history .agency-history__intro > p:last-child {
	margin: 0;
	max-width: 680px;
	font-size: 16px;
	line-height: 1.8;
	color: color-mix(in srgb, var(--history-paper) 78%, var(--history-ink));
}
.agency-history .agency-history__rail {
	display: flex;
	gap: 0;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scrollbar-width: thin;
	scrollbar-color: var(--history-gold) transparent;
	padding: 4px 0 12px;
	margin: 0;
}
.agency-history .agency-history__tab {
	position: relative;
	flex: 1 0 92px;
	min-height: 76px;
	padding: 10px 12px 28px;
	border: 0;
	border-bottom: 1px solid color-mix(in srgb, var(--history-paper) 26%, transparent);
	border-radius: 0;
	background: transparent;
	color: color-mix(in srgb, var(--history-paper) 70%, var(--history-ink));
	font: inherit;
	font-size: 19px;
	font-variant-numeric: tabular-nums;
	cursor: pointer;
	touch-action: manipulation;
}
.agency-history .agency-history__tab::before {
	content: "";
	position: absolute;
	bottom: -5px;
	left: calc(50% - 5px);
	width: 10px;
	height: 10px;
	border: 1px solid currentColor;
	border-radius: 50%;
	background: var(--history-ink);
}
.agency-history .agency-history__tab[aria-selected="true"] { color: var(--history-gold); font-weight: 700; }
.agency-history .agency-history__tab[aria-selected="true"]::before { background: var(--history-gold); }
.agency-history .agency-history__items { margin: 30px 0 0; }
.agency-history .agency-history__item {
	display: grid;
	grid-template-columns: minmax(150px, .55fr) 1fr;
	column-gap: 64px;
	align-content: start;
	min-height: 230px;
	margin: 0;
	padding: 24px 0;
}
.agency-history .agency-history__item + .agency-history__item { border-top: 1px solid color-mix(in srgb, var(--history-paper) 18%, transparent); }
.agency-history.is-enhanced .agency-history__item { border-top: 0; }
.agency-history .agency-history__item[hidden] { display: none !important; }
.agency-history .agency-history__year {
	grid-row: span 2;
	margin: 0;
	color: var(--history-gold);
	font-family: var(--wp--preset--font-family--body, sans-serif);
	font-size: clamp(64px, 8vw, 108px);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
	letter-spacing: -.04em;
	line-height: 1;
}
.agency-history .agency-history__item h3 { margin: 0 0 16px; color: inherit; font-size: 28px; line-height: 1.4; }
.agency-history .agency-history__item > p:last-child { margin: 0; max-width: 660px; font-size: 17px; line-height: 1.85; text-wrap: pretty; }
.agency-history .agency-history__tab:focus-visible,
.agency-history .agency-history__item:focus-visible { outline: 2px solid var(--history-gold); outline-offset: -3px; }
@media (hover: hover) {
	.agency-history .agency-history__tab:hover { color: var(--history-gold); }
}
@media (prefers-reduced-motion: no-preference) {
	.agency-history.is-enhanced .agency-history__item:not([hidden]) { animation: agency-history-reveal 240ms ease-out; }
}
@keyframes agency-history-reveal { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
@media (max-width: 600px) {
	.agency-history { padding: 44px 20px 36px; }
	.agency-history .agency-history__intro { margin-bottom: 28px; }
	.agency-history .agency-history__tab { flex-basis: 76px; font-size: 17px; min-height: 68px; }
	.agency-history .agency-history__items { margin-top: 14px; }
	.agency-history .agency-history__item { grid-template-columns: 1fr; min-height: 300px; padding: 24px 0; }
	.agency-history .agency-history__year { grid-row: auto; margin-bottom: 24px; font-size: 64px; }
	.agency-history .agency-history__item h3 { font-size: 24px; margin-bottom: 12px; }
	.agency-history .agency-history__item > p:last-child { font-size: 16px; }
}
