/*
 * Season, roll of honour and season index blocks. Colours and spacing come from the active
 * theme's presets where it defines them (the UCD Rowing theme does), with plain fallbacks.
 */

.ucdrs-section + .ucdrs-section {
	margin-top: var(--wp--preset--spacing--60, 3rem);
}

.ucdrs-section h3 {
	margin: var(--wp--preset--spacing--40, 1.5rem) 0 0.5rem;
	font-size: var(--wp--preset--font-size--medium, 1.125rem);
}

.ucdrs-club {
	display: inline-block;
	padding: 0.1em 0.45em;
	border-radius: 3px;
	font-size: 0.7em;
	font-weight: 600;
	letter-spacing: 0.06em;
	line-height: 1.4;
	text-decoration: none;
	vertical-align: 0.15em;
	color: var(--wp--preset--color--darkest-blue, #04204c);
	background: var(--wp--preset--color--tint, #eef4fb);
}

.ucdrs-club--ucdrc,
.ucdrs-club[data-club="ucdrc"] {
	color: var(--wp--preset--color--white, #fff);
	background: var(--wp--preset--color--darkest-blue, #04204c);
}

.ucdrs-club--ucdlbc,
.ucdrs-club[data-club="ucdlbc"] {
	background: var(--wp--preset--color--light-blue, #a3ccee);
}

/* Old Collegians: an outline, so it reads as apart from the three student clubs. */
.ucdrs-club--ocbc,
.ucdrs-club[data-club="ocbc"] {
	background: transparent;
	box-shadow: inset 0 0 0 1px currentColor;
}

/* The Olympic rings beside a milestone at the Games (ucdrs_olympic_rings()), after its badges. */
.ucdrs-olympics {
	display: inline-block;
	width: auto;
	/* Large enough to read the rings, centred on the text beside them. */
	height: 1.6em;
	vertical-align: -0.45em;
}

/* On the timeline the badges sit with no space between them (ucdrs_milestone_html()). */
.ucdrs-milestone__year .ucdrs-olympics:not(:first-child) {
	margin-left: 0.4rem;
}

/* Committees side by side: UCD Rowing Club's Governing and Student Committees (ucdrs_render_committees()), or each old club's before 2026–27 (ucdrs_render_club_committees()). */
.ucdrs-committees {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr));
	gap: var(--wp--preset--spacing--50, 2rem) var(--wp--preset--spacing--60, 3rem);
	align-items: start;
}

.ucdrs-committees__season {
	margin: 0 0 var(--wp--preset--spacing--30, 1rem);
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-committees h3 {
	margin: 0 0 0.5rem;
}

/* An old club's two committees, one under the other (ucdrs_render_club_committees()). */
.ucdrs-committees h4 {
	margin: var(--wp--preset--spacing--40, 1.5rem) 0 0.5rem;
}

.ucdrs-committees h3 + h4 {
	margin-top: 1rem;
}

.ucdrs-committees dl {
	margin: 0;
}

.ucdrs-committees dl > div {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 0 1rem;
	padding: 0.6rem 0;
	border-top: 1px solid var(--wp--preset--color--tint, #eef4fb);
}

.ucdrs-committees dt {
	grid-row: span 4;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	text-transform: uppercase;
	letter-spacing: 0.08em;
	padding-top: 0.15em;
}

.ucdrs-committees__note {
	display: block;
	text-transform: none;
	letter-spacing: normal;
}

.ucdrs-committees dd {
	grid-column: 2;
	margin: 0;
	font-weight: 500;
}

.ucdrs-achievements {
	margin: 0;
	padding: 0;
	list-style: none;
}

.ucdrs-achievements li {
	padding: 0.6rem 0;
	border-top: 1px solid var(--wp--preset--color--tint, #eef4fb);
}

.ucdrs-event {
	font-weight: 500;
}

.ucdrs-crew {
	display: block;
	margin-top: 0.15rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

/* A trophy's constituent titles, one event and crew to a line. */
.ucdrs-constituents {
	margin: 0;
	padding: 0;
	list-style: none;
}

.ucdrs-constituents li + li {
	margin-top: 0.5rem;
}

.ucdrs-roll__note {
	margin: 0.75rem 0 0;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

/* Roll of honour */
.ucdrs-roll {
	overflow-x: auto;
}

.ucdrs-count {
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-roll table {
	width: 100%;
	border-collapse: collapse;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-roll th,
.ucdrs-roll td {
	padding: 0.6rem 1rem 0.6rem 0;
	border-bottom: 1px solid var(--wp--preset--color--tint, #eef4fb);
	text-align: left;
	vertical-align: top;
}

.ucdrs-roll thead th {
	font-weight: 600;
	border-bottom-color: currentColor;
}

.ucdrs-roll tbody th {
	font-weight: 500;
	white-space: nowrap;
}

/* One row per season: a narrow season column, the rest shared evenly. */
.ucdrs-roll--by-club table {
	table-layout: fixed;
}

.ucdrs-roll--by-club thead th:first-child {
	width: 5.5rem;
}

.ucdrs-roll--by-club th[scope="col"] {
	white-space: normal;
}

.ucdrs-roll--by-club td {
	overflow-wrap: break-word;
}

/* Four columns on a phone: tighter cells, so most names fit without breaking. */
@media (max-width: 600px) {
	.ucdrs-roll--by-club th,
	.ucdrs-roll--by-club td {
		padding-right: 0.5rem;
	}

	.ucdrs-roll--by-club thead th:first-child {
		width: 4.75rem;
	}
}

/* Season index */
.ucdrs-seasons {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
	gap: var(--wp--preset--spacing--50, 2.5rem) var(--wp--preset--spacing--30, 1rem); /* Rows further apart than columns, so each card reads as one. */
	margin: 0;
	padding: 0;
	list-style: none;
}

.ucdrs-seasons li {
	display: flex;
	flex-direction: column;
	gap: 0.25rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-season-link {
	font-size: var(--wp--preset--font-size--large, 1.375rem);
	font-weight: 500;
	letter-spacing: -0.02em;
	text-decoration: none;
}

.ucdrs-season-link::after {
	content: "";
	position: absolute;
	inset: 0;
}

.ucdrs-seasons li {
	position: relative;
}

/* No box: the photo (or empty panel) tops each card, as on news cards, and the season underlines on hover. */
.ucdrs-seasons li:hover .ucdrs-season-link {
	text-decoration: underline;
	text-decoration-thickness: 2px;
	text-underline-offset: 0.15em;
}

/*
 * The season's photo across the top of its card (ucdrs_season_photo()). Seasons without one get
 * an empty tint panel, so the cards line up; a theme can dress it.
 */
.ucdrs-season-card__photo {
	margin: 0 0 0.5rem;
	aspect-ratio: 3 / 2;
	overflow: hidden; /* So a photo can't stretch the frame past 3:2. */
	background: var(--wp--preset--color--tint, #eef4fb);
}

.ucdrs-season-card__photo img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.ucdrs-titles {
	margin-top: auto;
	font-weight: 600;
}

/* Write-ups and photos on a season's records. */
.ucdrs-achievements li {
	scroll-margin-top: 6rem;
}

.ucdrs-achievements li.has-photo {
	display: grid;
	grid-template-columns: 1fr minmax(9rem, 13.5rem);
	gap: var(--wp--preset--spacing--40, 1.5rem);
	align-items: start;
}

.ucdrs-achievements li:target {
	background: var(--wp--preset--color--tint, #eef4fb);
	box-shadow: -0.75rem 0 0 var(--wp--preset--color--tint, #eef4fb), 0.75rem 0 0 var(--wp--preset--color--tint, #eef4fb);
}

.ucdrs-note {
	display: block;
	max-width: 40rem;
	margin-top: 0.5rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-photo {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 4px;
}

@media (max-width: 600px) {
	.ucdrs-achievements li.has-photo {
		grid-template-columns: 1fr;
	}

	.ucdrs-print {
		max-width: 16rem;
	}
}

/* Person page */
.ucdrs-summary {
	font-size: var(--wp--preset--font-size--large, 1.375rem);
}

.ucdrs-season-label {
	display: inline-block;
	min-width: 4.5rem;
	font-weight: 600;
}

/* A captain in a crew: a solid circle with a C after their name. */
.ucdrs-captain {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 1.45em;
	height: 1.45em;
	margin-left: 0.15em;
	border-radius: 50%;
	background: var(--wp--preset--color--darkest-blue, #04204c);
	color: var(--wp--preset--color--white, #fff);
	font-size: 0.7em;
	font-weight: 600;
	line-height: 1;
	vertical-align: 0.15em;
	cursor: help;
}

/* On the navy hover card, Saffron (allowed on navy only) stands out. */
.ucdrs-hovercard__card .ucdrs-captain {
	background: var(--wp--preset--color--saffron, #f8d500);
	color: var(--wp--preset--color--darkest-blue, #04204c);
}

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

/* Seats and coaches in a crew */
.ucdrs-seat {
	font-size: 0.85em;
	font-weight: 600;
	letter-spacing: 0.02em;
	text-transform: uppercase;
}

.ucdrs-coaches {
	display: block;
	margin-top: 0.15rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-style: italic;
}

.ucdrs-venue {
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

/* Write-ups: old club records, so kept compact. */
.ucdrs-note > :first-child {
	margin-top: 0;
}

.ucdrs-note p,
.ucdrs-note blockquote,
.ucdrs-note table {
	margin: 0.5rem 0 0;
}

.ucdrs-note h4 {
	margin: 1rem 0 0;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	text-transform: uppercase;
	letter-spacing: 0.08em;
}

.ucdrs-note blockquote {
	padding-left: 1rem;
	border-left: 3px solid var(--wp--preset--color--light-blue, #a3ccee);
	font-style: italic;
}

.ucdrs-note td,
.ucdrs-note th {
	padding: 0.25rem 1rem 0.25rem 0;
	text-align: left;
	vertical-align: top;
}

.ucdrs-note iframe {
	max-width: 100%;
}

/* A linked article (ucdrs_source_lines()): the publication and date above its headline. */
.ucdrs-source__meta {
	display: block;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.ucdrs-source__title {
	font-weight: 500;
}

.ucdrs-source__arrow {
	display: inline-block;
	margin-left: 0.25em;
}

/*
 * Record photos, mounted like the crew photos in the boathouse (ucdrs_record_photos()). The lead
 * photo is a small print: a tint mat with a double ruled line, like the pencil lines on the old
 * mounts, and the event and year under it. It turns white on a linked record, whose row is
 * already tint.
 */
.ucdrs-print {
	display: block;
	padding: 0.75rem 0.75rem 0.5rem;
	background: var(--wp--preset--color--tint, #eef4fb);
	color: inherit;
	text-decoration: none;
}

.ucdrs-achievements li:target .ucdrs-print {
	background: var(--wp--preset--color--white, #fff);
}

.ucdrs-print__mat {
	display: block;
	padding: 0.375rem;
	border: 1px solid rgb(4 32 76 / 28%);
	outline: 1px solid rgb(4 32 76 / 28%);
	outline-offset: 3px;
}

.ucdrs-print .ucdrs-photo {
	border-radius: 0;
}

.ucdrs-print__label {
	display: block;
	margin-top: 0.625rem;
	font-size: 0.75rem;
	font-style: italic;
	line-height: 1.35;
	text-align: center;
}

.ucdrs-print:hover .ucdrs-print__label {
	text-decoration: underline;
}

.ucdrs-print:focus-visible,
.ucdrs-thumb-link:focus-visible {
	outline: 2px solid currentColor;
	outline-offset: 2px;
}

.ucdrs-gallery {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0.75rem 0 0;
	padding: 0;
	list-style: none;
}

.ucdrs-gallery li {
	padding: 0;
	border: 0;
}

.ucdrs-thumb-link {
	display: block;
	border-radius: 3px;
}

.ucdrs-thumb {
	display: block;
	width: 5.5rem;
	height: 5.5rem;
	object-fit: cover;
	border-radius: 3px;
}

/*
 * The mount (ucdrs_mount(), assets/mount.js): a record's photos full screen on navy, with the
 * club and event above and the crew below, as on the frames in the boathouse. The dialog fills
 * the screen and centres the mount; a click on it outside the mount closes it.
 */
dialog.ucdrs-mount {
	box-sizing: border-box;
	width: 100%;
	max-width: none;
	height: 100%;
	max-height: none;
	margin: 0;
	padding: 4rem 1rem 2rem;
	border: 0;
	background: var(--wp--preset--color--darkest-blue, #04204c);
	color: var(--wp--preset--color--white, #fff);
	overflow-y: auto;
	overscroll-behavior: contain;
}

dialog.ucdrs-mount[open] {
	display: flex;
	flex-direction: column;
	justify-content: safe center;
	align-items: center;
}

dialog.ucdrs-mount::backdrop {
	background: var(--wp--preset--color--darkest-blue, #04204c);
}

html:has(dialog.ucdrs-mount[open]) {
	overflow: hidden;
}

@media (prefers-reduced-motion: no-preference) {
	dialog.ucdrs-mount[open] {
		animation: ucdrs-mount-in 0.2s ease-out;
	}
}

@keyframes ucdrs-mount-in {
	from {
		opacity: 0;
	}
}

.ucdrs-mount a {
	color: inherit;
}

.ucdrs-mount__close {
	position: fixed;
	top: 1rem;
	right: 1rem;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 2.75rem;
	height: 2.75rem;
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
	fill: currentColor;
	cursor: pointer;
}

.ucdrs-mount__inner {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 1.5rem;
	max-width: 60rem;
	text-align: center;
}

.ucdrs-mount__club {
	margin: 0 0 0.375rem;
	color: var(--wp--preset--color--saffron, #f8d500);
	font-size: 0.875rem;
	font-weight: 500;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.ucdrs-mount .ucdrs-mount__title {
	margin: 0;
	color: inherit;
	font-size: clamp(1.5rem, 3vw, 2.125rem);
	font-weight: 500;
	letter-spacing: -0.02em;
	line-height: 1.15;
}

.ucdrs-mount__photo {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.75rem;
	margin: 0;
}

.ucdrs-mount__photo[hidden] {
	display: none;
}

/* The photo whole, as big as fits with the words above and below, inside the double line. */
.ucdrs-mount__img {
	display: block;
	box-sizing: content-box;
	width: auto;
	height: auto;
	max-width: calc(100% - 1.75rem);
	max-height: max(16rem, 100dvh - 25rem);
	padding: 0.75rem;
	border: 1px solid rgb(163 204 238 / 40%);
	outline: 1px solid rgb(163 204 238 / 40%);
	outline-offset: 4px;
}

.ucdrs-mount__photo figcaption,
.ucdrs-mount__where {
	margin: 0;
	color: var(--wp--preset--color--light-blue, #a3ccee);
	font-size: 0.75rem;
	letter-spacing: 0.04em;
}

.ucdrs-mount__nav {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	margin: -0.75rem 0;
	font-size: 0.875rem;
}

.ucdrs-mount__nav button {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 2.75rem;
	height: 2.75rem;
	padding: 0;
	border: 0;
	background: none;
	color: inherit;
	fill: currentColor;
	cursor: pointer;
}

.ucdrs-mount__close:focus-visible,
.ucdrs-mount__nav button:focus-visible {
	outline: 2px solid currentColor;
}

.ucdrs-mount__crew {
	max-width: 50rem;
	margin: 0;
	font-size: 0.9375rem;
	line-height: 1.7;
	text-wrap: balance;
}

.ucdrs-mount__rower {
	white-space: nowrap;
}

/* Seats in italics, the quiet nod to the lettering on the old mounts. */
.ucdrs-mount__crew i {
	color: var(--wp--preset--color--light-blue, #a3ccee);
}

/* Timeline: decades down the page, each milestone a dot on a line with its photo beside it. */
.ucdrs-timeline__decade + .ucdrs-timeline__decade {
	margin-top: var(--wp--preset--spacing--50, 2.5rem);
}

.ucdrs-timeline__heading {
	margin: 0 0 var(--wp--preset--spacing--40, 1.5rem);
}

.ucdrs-timeline__list {
	margin: 0 0 0 0.5rem;
	padding: 0;
	list-style: none;
	border-left: 2px solid var(--wp--preset--color--light-blue, #a3ccee);
}

.ucdrs-milestone {
	position: relative;
	display: grid;
	gap: var(--wp--preset--spacing--30, 1rem) var(--wp--preset--spacing--50, 2.5rem);
	margin: 0;
	padding: 0 0 var(--wp--preset--spacing--50, 2.5rem) var(--wp--preset--spacing--50, 2rem);
}

.ucdrs-milestone:last-child {
	padding-bottom: 0;
}

.ucdrs-milestone::before {
	content: "";
	position: absolute;
	top: 0.3rem;
	left: calc(-0.5rem - 1px);
	width: 1rem;
	height: 1rem;
	border-radius: 50%;
	background: var(--wp--preset--color--darkest-blue, #04204c);
	box-shadow: 0 0 0 3px var(--wp--preset--color--white, #fff);
}

.ucdrs-milestone__year {
	margin: 0;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 600;
	letter-spacing: 0.06em;
}

.ucdrs-milestone__year .ucdrs-club {
	margin-left: 0.35rem;
	font-size: 0.75rem;
}

/*
 * Clear of the sticky header when the timeline opens at a milestone (#milestone-<id>), and of
 * the honours tally, whose height its script sets.
 */
.ucdrs-milestone {
	scroll-margin-top: calc(6rem + var(--ucdrs-tally-height, 0px));
}

/*
 * The timeline's honours tally (includes/tally.php, assets/timeline-tally.js): a navy bar that
 * sticks above the timeline, below a theme's sticky header if it sets --ucdrs-sticky-top.
 */
.ucdrs-tally {
	position: sticky;
	z-index: 50;
	top: var(--ucdrs-sticky-top, var(--wp-admin--admin-bar--height, 0px));
	margin: 0 0 var(--wp--preset--spacing--50, 2.5rem);
	border-radius: 4px;
	background: var(--wp--preset--color--darkest-blue, #04204c);
	color: var(--wp--preset--color--white, #fff);
	box-shadow: 0 6px 20px rgb(4 32 76 / 18%);
}

.ucdrs-tally[hidden] {
	display: none;
}

.ucdrs-tally__inner {
	display: flex;
	gap: var(--wp--preset--spacing--40, 1.5rem);
	align-items: flex-end;
	padding: 1rem 1.25rem;
}

.ucdrs-tally p {
	margin: 0;
}

.ucdrs-tally__when {
	display: flex;
	flex: 0 0 auto;
	flex-direction: column;
	min-width: 7.5rem;
}

.ucdrs-tally__eyebrow {
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--wp--preset--color--light-blue, #a3ccee);
}

.ucdrs-tally__season {
	font-size: var(--wp--preset--font-size--large, 1.375rem);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

.ucdrs-tally__group {
	flex: 1 1 0;
	min-width: 0;
	padding-left: 1rem;
	border-left: 1px solid rgb(163 204 238 / 30%);
}

.ucdrs-tally__count {
	display: flex;
	gap: 0.5rem;
	align-items: center;
}

/*
 * Each count is a row of split-flap cards, as on the theme's countdown: white on Dark Blue,
 * with the hinge across the middle. Each card is two clipped halves of the same digit, plus two
 * leaves that only show while it flips (assets/timeline-tally.js). Blank cards stand in front of
 * a number with fewer digits than the final total.
 */
.ucdrs-tally__n {
	--ucdrs-flip-height: 1.3em;
	display: flex;
	gap: 0.08em;
	font-size: var(--wp--preset--font-size--x-large, 2rem);
	font-weight: 500;
	line-height: 1;
	font-variant-numeric: tabular-nums;
	color: var(--wp--preset--color--white, #fff);
	transition: color 0.3s;
}

.ucdrs-tally__card {
	position: relative;
	flex: 0 0 auto;
	width: 0.82em;
	height: var(--ucdrs-flip-height);
	border-radius: 0.1em;
	box-shadow: 0 0.06em 0.14em rgb(0 0 0 / 45%);
	perspective: 4em;
}

.ucdrs-tally__card.is-blank {
	opacity: 0.45;
}

.ucdrs-tally__half {
	position: absolute;
	left: 0;
	right: 0;
	height: 50%;
	overflow: hidden;
	background-color: var(--wp--preset--color--dark-blue, #03326c);
	backface-visibility: hidden;
}

.ucdrs-tally__half > span {
	display: block;
	height: var(--ucdrs-flip-height);
	line-height: var(--ucdrs-flip-height);
	text-align: center;
}

.ucdrs-tally__top {
	top: 0;
	border-radius: 0.1em 0.1em 0 0;
	background-image: linear-gradient(rgb(255 255 255 / 7%), rgb(255 255 255 / 2%));
	transform-origin: 50% 100%;
}

.ucdrs-tally__bottom {
	bottom: 0;
	border-radius: 0 0 0.1em 0.1em;
	transform-origin: 50% 0;
}

.ucdrs-tally__bottom > span {
	margin-top: calc(var(--ucdrs-flip-height) / -2);
}

/* The hinge: a gap between the halves, in the bar's navy, with a pin either side. */
.ucdrs-tally__card::before,
.ucdrs-tally__card::after {
	content: "";
	position: absolute;
	z-index: 3;
	top: 50%;
	transform: translateY(-50%);
}

.ucdrs-tally__card::before {
	left: 0;
	right: 0;
	height: max(1px, 0.03em);
	background-color: var(--wp--preset--color--darkest-blue, #04204c);
}

.ucdrs-tally__card::after {
	left: -0.04em;
	right: -0.04em;
	height: 0.14em;
	border-radius: 0.02em;
	background: linear-gradient(to right, var(--wp--preset--color--darkest-blue, #04204c) 0.07em, transparent 0.07em calc(100% - 0.07em), var(--wp--preset--color--darkest-blue, #04204c) calc(100% - 0.07em));
}

.ucdrs-tally__leaf {
	display: none;
	z-index: 2;
}

.ucdrs-tally__card.is-flipping .ucdrs-tally__leaf {
	display: block;
}

.ucdrs-tally__card.is-flipping .ucdrs-tally__top.ucdrs-tally__leaf {
	animation: ucdrs-tally-fall 0.25s ease-in both;
}

.ucdrs-tally__card.is-flipping .ucdrs-tally__bottom.ucdrs-tally__leaf {
	animation: ucdrs-tally-land 0.25s 0.25s ease-out both;
}

@keyframes ucdrs-tally-fall {
	to {
		transform: rotateX(-90deg);
		filter: brightness(0.7);
	}
}

@keyframes ucdrs-tally-land {
	from {
		transform: rotateX(90deg);
		filter: brightness(1.4);
	}
}

.ucdrs-tally__gain {
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 700;
	color: var(--wp--preset--color--saffron, #f8d500);
	opacity: 0;
}

/* A count that's just gone up turns Saffron (the cards' digits) and shows its gain for a moment. */
.ucdrs-tally__group.is-up .ucdrs-tally__n {
	color: var(--wp--preset--color--saffron, #f8d500);
}

.ucdrs-tally__group.is-up .ucdrs-tally__gain {
	animation: ucdrs-tally-gain 1.2s ease-out forwards;
}

@keyframes ucdrs-tally-gain {
	0% { opacity: 0; transform: translateY(4px); }
	15% { opacity: 1; transform: none; }
	75% { opacity: 1; }
	100% { opacity: 0; }
}

.ucdrs-tally__label {
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 600;
}

.ucdrs-tally__short {
	display: none;
}

.ucdrs-tally__parts {
	overflow: hidden;
	font-size: 0.75rem;
	white-space: nowrap;
	text-overflow: ellipsis;
	color: var(--wp--preset--color--light-blue, #a3ccee);
}

/* On phones and narrow columns: the season on its own line, short labels and no breakdown. */
@media (max-width: 781px) {
	.ucdrs-tally__inner {
		flex-wrap: wrap;
		gap: 0.5rem;
		padding: 0.625rem 1rem 0.75rem;
	}

	.ucdrs-tally__when {
		flex: 1 0 100%;
		flex-direction: row;
		justify-content: space-between;
		align-items: baseline;
	}

	.ucdrs-tally__season {
		font-size: var(--wp--preset--font-size--medium, 1.0625rem);
	}

	.ucdrs-tally__group {
		padding-left: 0.5rem;
	}

	.ucdrs-tally__group:nth-child(2) {
		padding-left: 0;
		border-left: 0;
	}

	/* Smaller cards, so a three-digit count fits a quarter of a phone. */
	.ucdrs-tally__n {
		font-size: 1.25rem;
	}

	/* The gain sits on the cards' top corner, as there's no room beside them. */
	.ucdrs-tally__count {
		position: relative;
		display: inline-flex;
	}

	.ucdrs-tally__gain {
		position: absolute;
		z-index: 4;
		top: -0.45rem;
		right: -0.35rem;
		padding: 0 0.25rem;
		border-radius: 999px;
		font-size: 0.6875rem;
		line-height: 1.4;
		background-color: var(--wp--preset--color--darkest-blue, #04204c);
	}

	.ucdrs-tally__label {
		font-size: 0.6875rem;
	}

	.ucdrs-tally__full,
	.ucdrs-tally__parts {
		display: none;
	}

	.ucdrs-tally__short {
		display: inline;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ucdrs-tally__n {
		transition: none;
	}

	.ucdrs-tally__card.is-flipping .ucdrs-tally__leaf {
		display: none;
	}

	.ucdrs-tally__group.is-up .ucdrs-tally__gain {
		animation: none;
	}
}

.ucdrs-milestone__more {
	margin: 0.75rem 0 0;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-milestone__more a::after {
	content: " →";
}

/* With no year before them (on a season page), badges sit flush left. */
.ucdrs-milestone__year .ucdrs-club:first-child {
	margin-left: 0;
}

/* On a season page, milestones keep their timeline look inside the season's sections. */
.ucdrs-season-milestones .ucdrs-timeline__list {
	margin-top: var(--wp--preset--spacing--40, 1.5rem);
}

.ucdrs-section .ucdrs-milestone__title {
	margin: 0.25rem 0 0;
	font-size: var(--wp--preset--font-size--large, 1.375rem);
}

.ucdrs-section .ucdrs-milestone__body > .ucdrs-milestone__title:first-child {
	margin-top: 0;
}

.ucdrs-milestone__title {
	margin: 0.25rem 0 0;
	font-size: var(--wp--preset--font-size--large, 1.375rem);
}

.ucdrs-milestone__text > :first-child {
	margin-top: 0.5rem;
}

.ucdrs-milestone__text > :last-child {
	margin-bottom: 0;
}

.ucdrs-milestone__text blockquote {
	margin: 1rem 0;
	padding-left: 1rem;
	border-left: 2px solid var(--wp--preset--color--light-blue, #a3ccee);
	font-style: italic;
}

/* Shrink to the photo: with "Expand on click" core makes the figure a flex column, which would
   stretch the photo to the column's width while max-height caps its height, distorting it. */
.ucdrs-milestone__photo-figure {
	width: fit-content;
	max-width: 100%;
	margin: 0;
}

.ucdrs-milestone__photo {
	display: block;
	align-self: flex-start;
	width: auto;
	max-width: 100%;
	height: auto;
	max-height: 22rem;
	border-radius: 4px;
}

.ucdrs-milestone__photo-figure figcaption {
	margin-top: 0.5rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	white-space: pre-line;
}

@media (min-width: 782px) {
	.ucdrs-milestone.has-photo {
		grid-template-columns: minmax(0, 1fr) minmax(0, 40%);
	}
}

/*
 * Hover card: a record's crew, beside a link to it. Opens below the link (the sticky header
 * would cover it above) on hover or keyboard focus. Touch screens have no hover, so there the
 * link just goes to the record.
 */
.ucdrs-hovercard {
	position: relative;
}

.ucdrs-hovercard__card {
	position: absolute;
	z-index: 20;
	top: calc(100% + 0.4rem);
	left: 0;
	width: max-content;
	max-width: min(22rem, 80vw);
	padding: 0.75rem 1rem;
	border-radius: 4px;
	background: var(--wp--preset--color--darkest-blue, #04204c);
	box-shadow: 0 6px 20px rgb(4 32 76 / 0.25);
	color: var(--wp--preset--color--white, #fff);
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-style: normal;
	font-weight: 400;
	line-height: 1.45;
	text-align: left;
	pointer-events: none;
	/* Hidden cards take no space, so they can't widen the page. */
	display: none;
}

.ucdrs-hovercard:hover .ucdrs-hovercard__card,
.ucdrs-hovercard:focus-within .ucdrs-hovercard__card {
	display: block;
}

@media (hover: none) {
	.ucdrs-hovercard:hover .ucdrs-hovercard__card {
		display: none;
	}
}

.ucdrs-hovercard__record,
.ucdrs-hovercard__title,
.ucdrs-hovercard__where,
.ucdrs-hovercard__line {
	display: block;
}

.ucdrs-hovercard__record + .ucdrs-hovercard__record,
.ucdrs-hovercard__record + .ucdrs-hovercard__where,
.ucdrs-hovercard__record + .ucdrs-hovercard__title {
	margin-top: 0.75rem;
	padding-top: 0.75rem;
	border-top: 1px solid rgb(163 204 238 / 0.3);
}

.ucdrs-hovercard__title {
	font-weight: 600;
}

/* The competition and year, heading the card: quieter than the events below it. */
.ucdrs-hovercard__where {
	margin-bottom: 0.4rem;
	color: var(--wp--preset--color--light-blue, #a3ccee);
	font-size: 0.8125rem;
}

.ucdrs-hovercard__title + .ucdrs-hovercard__record,
.ucdrs-hovercard__title + .ucdrs-hovercard__line,
.ucdrs-hovercard__where + .ucdrs-hovercard__line {
	margin-top: 0.4rem;
}

.ucdrs-hovercard__seat {
	display: inline-block;
	min-width: 3.5rem;
	color: var(--wp--preset--color--light-blue, #a3ccee);
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.ucdrs-hovercard__coaches {
	margin-top: 0.4rem;
	color: var(--wp--preset--color--light-blue, #a3ccee);
}

/* Fixtures: a date column beside each event, grouped under month (or season) headings. */
.ucdrs-fixtures__heading {
	margin: var(--wp--preset--spacing--50, 2.5rem) 0 0;
	font-size: var(--wp--preset--font-size--large, 1.375rem);
}

.ucdrs-fixtures__heading:first-child {
	margin-top: 0;
}

.ucdrs-fixtures__list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.ucdrs-fixture {
	display: grid;
	grid-template-columns: 9rem minmax(0, 1fr);
	gap: 0.25rem var(--wp--preset--spacing--40, 1.5rem);
	margin: 0;
	padding: var(--wp--preset--spacing--30, 1rem) 0;
	border-bottom: 1px solid var(--wp--preset--color--tint, #eef4fb);
}

.ucdrs-fixture p {
	margin: 0;
}

.ucdrs-fixture__date {
	font-weight: 600;
}

.ucdrs-fixture__category {
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.ucdrs-fixture__name {
	font-size: var(--wp--preset--font-size--medium, 1.125rem);
	font-weight: 500;
}

.ucdrs-fixture__venue {
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-fixture__squads,
.ucdrs-fixture__titles ul {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem;
	margin: 0.5rem 0 0;
	padding: 0;
	list-style: none;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-fixture__squads li {
	padding: 0.1rem 0.6rem;
	border-radius: 999px;
	background: var(--wp--preset--color--tint, #eef4fb);
}

.ucdrs-fixture__writeup {
	margin-top: 0.5rem;
}

.ucdrs-fixture__writeup > * {
	margin: 0.5rem 0 0;
}

.ucdrs-fixture__titles {
	margin-top: 0.75rem;
}

.ucdrs-fixture__titles > p {
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 600;
}

.ucdrs-fixture__titles li {
	margin: 0;
}

.ucdrs-fixture__titles li:not(:last-child)::after {
	content: " ·";
}

@media (max-width: 600px) {
	.ucdrs-fixture {
		grid-template-columns: minmax(0, 1fr);
	}
}

.ucdrs-fixture .ucdrs-fixture__tickets {
	margin-top: 0.75rem;
}

/* Pills above a Fixtures block (one event type at a time) or the Anniversaries list (one event). */
.ucdrs-fixtures__filters ul,
.ucdrs-filters ul {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0 0 var(--wp--preset--spacing--50, 2rem);
	padding: 0;
	list-style: none;
}

.ucdrs-fixtures__filters a,
.ucdrs-filters a {
	display: inline-block;
	padding: 0.35rem 1rem;
	border: 1px solid currentColor;
	border-radius: 999px;
	color: var(--wp--preset--color--darkest-blue, #04204c);
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	text-decoration: none;
}

.ucdrs-fixtures__filters a:hover,
.ucdrs-fixtures__filters a:focus-visible,
.ucdrs-filters a:hover,
.ucdrs-filters a:focus-visible {
	background: var(--wp--preset--color--tint, #eef4fb);
}

.ucdrs-fixtures__filters a[aria-current],
.ucdrs-filters a[aria-current] {
	background: var(--wp--preset--color--darkest-blue, #04204c);
	color: var(--wp--preset--color--white, #fff);
}

/* Race reports listed under a result. */
.ucdrs-fixture__reports {
	margin-top: 0.75rem;
}

.ucdrs-fixture__reports > p {
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 600;
}

.ucdrs-fixture__reports ul {
	margin: 0.25rem 0 0;
	padding: 0;
	list-style: none;
}

.ucdrs-fixture__reports a::after {
	content: " →";
}

/* The Results box at the end of a race report. */
.ucdrs-report-results {
	margin-top: var(--wp--preset--spacing--60, 3rem);
	padding: var(--wp--preset--spacing--50, 2rem);
	border-radius: 4px;
	background: var(--wp--preset--color--tint, #eef4fb);
}

.ucdrs-report-results p {
	margin: 0;
}

.ucdrs-report-results .ucdrs-report-results__label {
	margin-bottom: 0.5rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.ucdrs-report-results .ucdrs-fixture__name {
	font-size: var(--wp--preset--font-size--large, 1.375rem);
	font-weight: 500;
}

.ucdrs-report-results .ucdrs-fixture__squads li {
	background: var(--wp--preset--color--white, #fff);
}

/*
 * Rolls of honour on phones: each record becomes a stacked card (season, event and competition,
 * then the crew) instead of a table too wide to read. The column headings are hidden but still
 * read by screen readers, and the ARIA roles in the markup keep the table's meaning.
 */
@media (max-width: 600px) {
	.ucdrs-roll--list table,
	.ucdrs-roll--list tbody,
	.ucdrs-roll--list tr,
	.ucdrs-roll--list th,
	.ucdrs-roll--list td {
		display: block;
	}

	.ucdrs-roll--list thead {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip: rect(0 0 0 0);
		white-space: nowrap;
	}

	.ucdrs-roll--list tbody tr {
		padding: 0.9rem 0;
		border-bottom: 1px solid var(--wp--preset--color--tint, #eef4fb);
	}

	.ucdrs-roll--list th,
	.ucdrs-roll--list td {
		padding: 0;
		border: 0;
	}

	.ucdrs-roll--list tbody th {
		font-weight: 600;
	}

	.ucdrs-roll--list td {
		margin-top: 0.2rem;
	}

	.ucdrs-roll--list td::before {
		content: attr(data-label);
		display: inline-block;
		min-width: 5.5rem;
		font-size: 0.75rem;
		font-weight: 600;
		letter-spacing: 0.06em;
		text-transform: uppercase;
	}

	/* What's obvious without a label: the event, competition, crew and club badge. */
	.ucdrs-roll--list .ucdrs-roll__event::before,
	.ucdrs-roll--list .ucdrs-roll__competition::before,
	.ucdrs-roll--list .ucdrs-roll__crew::before,
	.ucdrs-roll--list .ucdrs-roll__club::before {
		display: none;
	}

	.ucdrs-roll--list .ucdrs-roll__event {
		font-weight: 500;
	}

	.ucdrs-roll--list .ucdrs-roll__crew {
		margin-top: 0.4rem;
	}

	.ucdrs-roll--list .ucdrs-roll__club {
		margin-top: 0.4rem;
	}
}

/* News from the old UCD Boat Club website: a note on the post, a badge on its card. */
.ucdrs-archive-note {
	margin-bottom: var(--wp--preset--spacing--50, 2rem);
	padding: 0.75rem 1rem;
	border-left: 3px solid var(--wp--preset--color--light-blue, #a3ccee);
	background: var(--wp--preset--color--tint, #eef4fb);
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-archive-badge {
	margin-left: 0.35rem;
}

/*
 * Results as badges: a medal disc for Gold, Silver and Bronze, a plain badge for placings.
 * The disc colours are decoration only; the word is always there, in navy.
 */
.ucdrs-result {
	display: inline-flex;
	align-items: center;
	gap: 0.3em;
	padding: 0.05em 0.55em;
	border-radius: 999px;
	background: var(--wp--preset--color--tint, #eef4fb);
	color: var(--wp--preset--color--darkest-blue, #04204c);
	font-size: 0.8em;
	font-weight: 600;
	line-height: 1.5;
	white-space: nowrap;
	vertical-align: 0.08em;
}

.ucdrs-result__medal {
	width: 0.8em;
	height: 0.8em;
	border-radius: 50%;
	box-shadow: inset 0 0 0 1px rgb(0 0 0 / 0.15);
}

.ucdrs-result--gold .ucdrs-result__medal {
	background: radial-gradient(circle at 35% 35%, #fff3a6, var(--wp--preset--color--saffron, #f8d500) 55%, #c9a200);
}

.ucdrs-result--silver .ucdrs-result__medal {
	background: radial-gradient(circle at 35% 35%, #fff, #c8ced6 55%, #8e97a3);
}

.ucdrs-result--bronze .ucdrs-result__medal {
	background: radial-gradient(circle at 35% 35%, #f3c9a1, #c27c3e 55%, #8a5326);
}

/* Medal results stand out a little more than placings. */
.ucdrs-result--gold,
.ucdrs-result--silver,
.ucdrs-result--bronze {
	background: var(--wp--preset--color--white, #fff);
	box-shadow: inset 0 0 0 1px var(--wp--preset--color--light-blue, #a3ccee);
}

.ucdrs-result-note {
	font-size: 0.85em;
	font-style: italic;
}

/*
 * Season pages: each competition is a section of its own, with a larger heading and a rule
 * like the table headings, so it reads as a level above the events listed under it.
 */
.ucdrs-section h3.ucdrs-competition {
	margin: var(--wp--preset--spacing--50, 2.5rem) 0 0;
	padding-bottom: 0.5rem;
	border-bottom: 1px solid currentColor;
	font-size: var(--wp--preset--font-size--large, 1.375rem);
	font-weight: 500;
}

.ucdrs-section h2 + h3.ucdrs-competition {
	margin-top: var(--wp--preset--spacing--40, 1.5rem);
}

.ucdrs-competition__count {
	margin-left: 0.4rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 400;
}

/* The heading's rule already separates the first event. */
.ucdrs-competition + .ucdrs-achievements > li:first-child {
	border-top: 0;
}

/* Lead photos all the same 3:2 shape, so a portrait photo can't stretch one record. The crop
   is taken from near the top, not the middle: crew photos have heads near the top and spare
   room (legs, the dock) at the bottom. */
.ucdrs-achievements .ucdrs-photo {
	aspect-ratio: 3 / 2;
	object-fit: cover;
	object-position: 50% 20%;
}

/* Countdown: the event on the left, days/hours/minutes (or "Racing now") on the right. Colours
   come from the block's colour settings, so the theme decides how it looks. */
.wp-block-ucdrowing-countdown.alignfull {
	padding-left: var(--wp--style--root--padding-left, 1rem);
	padding-right: var(--wp--style--root--padding-right, 1rem);
}

.ucdrs-countdown__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: var(--wp--preset--spacing--40, 1.5rem) var(--wp--preset--spacing--60, 3rem);
	max-width: var(--wp--style--global--wide-size, 1240px);
	margin-inline: auto;
}

.ucdrs-countdown__eyebrow {
	margin: 0 0 0.5rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.ucdrs-countdown__title {
	margin: 0;
	font-size: var(--wp--preset--font-size--x-large, 2rem);
}

.ucdrs-countdown__title a {
	color: inherit;
	text-decoration: none;
}

.ucdrs-countdown__title a:hover,
.ucdrs-countdown__title a:focus-visible {
	text-decoration: underline;
}

.ucdrs-countdown__when {
	margin: 0.5rem 0 0;
}

.ucdrs-countdown__side {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--wp--preset--spacing--40, 1.5rem);
}

.ucdrs-countdown__clock {
	display: flex;
	gap: var(--wp--preset--spacing--40, 1.5rem);
	margin: 0;
}

.ucdrs-countdown__number {
	display: block;
	font-size: var(--wp--preset--font-size--xx-large, 3rem);
	font-weight: 500;
	font-variant-numeric: tabular-nums;
	line-height: 1;
	letter-spacing: -0.03em;
}

.ucdrs-countdown__label {
	display: block;
	margin-top: 0.4rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.ucdrs-countdown__tickets {
	margin: 0;
}

/* Before the start, "Countdown" and the clock; while it's on, "Racing now" and no clock. */
.ucdrs-countdown__during,
.wp-block-ucdrowing-countdown.is-live .ucdrs-countdown__before,
.wp-block-ucdrowing-countdown.is-live .ucdrs-countdown__clock {
	display: none;
}

.wp-block-ucdrowing-countdown.is-live .ucdrs-countdown__during {
	display: inline;
}

/* Anniversaries: a heading, then today's featured anniversary (photo and story) beside two
   smaller ones. Colours come from the block's colour settings, so the theme decides how it looks. */
.wp-block-ucdrowing-anniversaries.alignfull {
	padding-left: var(--wp--style--root--padding-left, 1rem);
	padding-right: var(--wp--style--root--padding-right, 1rem);
}

.ucdrs-anniversaries__inner {
	max-width: var(--wp--style--global--wide-size, 1240px);
	margin-inline: auto;
}

.ucdrs-anniversaries__header {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 0.5rem var(--wp--preset--spacing--40, 1.5rem);
	margin-bottom: var(--wp--preset--spacing--50, 2rem);
}

.ucdrs-anniversaries__eyebrow {
	margin: 0 0 0.5rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.ucdrs-anniversaries__heading,
.ucdrs-anniversaries__more {
	margin: 0;
}

.ucdrs-anniversaries__items {
	display: grid;
	grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
	grid-template-rows: auto auto 1fr;
	gap: var(--wp--preset--spacing--40, 1.5rem) var(--wp--preset--spacing--60, 3rem);
}

.ucdrs-anniversary.is-featured {
	grid-row: 1 / -1;
}

.ucdrs-anniversary:not(.is-featured) + .ucdrs-anniversary {
	padding-top: var(--wp--preset--spacing--40, 1.5rem);
	border-top: 1px solid currentColor;
	border-top-color: color-mix(in srgb, currentColor 20%, transparent);
}

.ucdrs-anniversary__photo {
	margin: 0 0 var(--wp--preset--spacing--30, 1rem);
}

.ucdrs-anniversary__image {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 16 / 9;
	object-fit: cover;
}

.ucdrs-anniversary__when {
	margin: 0 0 0.35rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-anniversary__when strong {
	font-weight: 600;
}

.ucdrs-anniversary__title {
	margin: 0;
	font-size: var(--wp--preset--font-size--large, 1.375rem);
}

.ucdrs-anniversary.is-featured .ucdrs-anniversary__title {
	font-size: var(--wp--preset--font-size--x-large, 2rem);
}

.ucdrs-anniversary__title a {
	color: inherit;
	text-decoration: none;
}

.ucdrs-anniversary__title a:hover,
.ucdrs-anniversary__title a:focus-visible {
	text-decoration: underline;
}

.ucdrs-anniversary__detail,
.ucdrs-anniversary__text {
	margin: 0.35rem 0 0;
}

@media (max-width: 781px) {
	.ucdrs-anniversaries__items {
		grid-template-columns: minmax(0, 1fr);
		grid-template-rows: none;
	}

	.ucdrs-anniversary.is-featured {
		grid-row: auto;
	}

	.ucdrs-anniversary.is-featured + .ucdrs-anniversary {
		padding-top: var(--wp--preset--spacing--40, 1.5rem);
		border-top: 1px solid currentColor;
		border-top-color: color-mix(in srgb, currentColor 20%, transparent);
	}
}

/* Anniversaries list: every anniversary this year, grouped by years ago, in a two-column grid
   of short entries. Round anniversaries (25, 50, 75, 100) get a heavier rule. */
.ucdrs-anniversary-list__group,
.ucdrs-gaps__season {
	margin-top: var(--wp--preset--spacing--60, 3rem);
	padding-top: var(--wp--preset--spacing--30, 1rem);
	border-top: 1px solid currentColor;
	border-top-color: color-mix(in srgb, currentColor 20%, transparent);
}

.ucdrs-anniversary-list__group.is-round {
	border-top: 4px solid var(--wp--preset--color--darkest-blue, #04204c);
}

.ucdrs-anniversary-list__heading,
.ucdrs-gaps__heading {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0 0.75rem;
	margin: 0 0 var(--wp--preset--spacing--40, 1.5rem);
}

/* Season picker above the Anniversaries list's pills. */
.ucdrs-anniversary-list__picker {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.5rem 0.75rem;
	margin: 0 0 var(--wp--preset--spacing--40, 1.5rem);
}

.ucdrs-anniversary-list__picker label {
	font-weight: 500;
}

.ucdrs-anniversary-list__picker select {
	min-height: 2.5rem;
	padding: 0.35rem 0.75rem;
	border: 1px solid currentColor;
	border-radius: 0.25rem;
	background-color: var(--wp--preset--color--white, #fff);
	color: var(--wp--preset--color--darkest-blue, #04204c);
	font: inherit;
}

.ucdrs-anniversary-list__picker .wp-element-button {
	padding: 0.5rem 1.25rem;
}

.ucdrs-anniversary-list__season {
	font-size: var(--wp--preset--font-size--medium, 1.125rem);
	font-weight: 400;
	letter-spacing: 0;
}

.ucdrs-anniversary-list__items,
.ucdrs-gaps__items {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 22rem), 1fr));
	gap: var(--wp--preset--spacing--40, 1.5rem) var(--wp--preset--spacing--50, 2rem);
	margin: 0;
	padding: 0;
	list-style: none;
}

.ucdrs-anniversary-list__meta,
.ucdrs-gaps__meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.35rem;
	margin: 0 0 0.35rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-anniversary-list__kind {
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.ucdrs-anniversary-list__title,
.ucdrs-gaps__title {
	margin: 0;
	font-size: var(--wp--preset--font-size--medium, 1.125rem);
}

.ucdrs-anniversary-list__title a,
.ucdrs-gaps__title a,
.ucdrs-gaps__heading a {
	color: inherit;
	text-decoration: none;
}

.ucdrs-anniversary-list__title a:hover,
.ucdrs-anniversary-list__title a:focus-visible,
.ucdrs-gaps__title a:hover,
.ucdrs-gaps__title a:focus-visible,
.ucdrs-gaps__heading a:hover,
.ucdrs-gaps__heading a:focus-visible {
	text-decoration: underline;
}

.ucdrs-anniversary-list__detail,
.ucdrs-anniversary-list__text {
	margin: 0.25rem 0 0;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

/* Records to complete: the Anniversaries list's look, with what each record is missing as tags. */
.ucdrs-filters__count {
	margin-left: 0.15rem;
	opacity: 0.7;
}

/* Two rows of pills, kept together. */
.wp-block-ucdrowing-record-gaps .ucdrs-filters ul {
	margin-bottom: 0.75rem;
}

.ucdrs-gaps__summary {
	margin: 0;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-gaps__items {
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr));
}

.ucdrs-gaps__edit {
	margin-left: auto;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 400;
	letter-spacing: 0;
}

.ucdrs-gaps__tags {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem;
	margin: 0.35rem 0 0;
}

.ucdrs-gaps__tag {
	padding: 0.05rem 0.5rem;
	border: 1px solid currentColor;
	border-radius: 999px;
	font-size: 0.75rem;
}

/* A fixture's preview (usually its crews), folded under a "Crews" toggle in the Fixtures list
   and the countdown. Colours follow the surrounding text, so it works on white and on navy. */
.ucdrs-fixture__preview {
	margin-top: 0.5rem;
}

.ucdrs-fixture__preview > summary {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	font-size: var(--wp--preset--font-size--small, 0.875rem);
	font-weight: 600;
	cursor: pointer;
	list-style: none;
}

.ucdrs-fixture__preview > summary::-webkit-details-marker {
	display: none;
}

/* A chevron that points down when closed and up when open. */
.ucdrs-fixture__preview > summary::after {
	content: "";
	width: 0.45em;
	height: 0.45em;
	margin-top: -0.2em;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
}

.ucdrs-fixture__preview[open] > summary::after {
	margin-top: 0.2em;
	transform: rotate(-135deg);
}

.ucdrs-fixture__preview > summary:hover,
.ucdrs-fixture__preview > summary:focus-visible {
	text-decoration: underline;
}

.ucdrs-fixture__preview-body {
	margin-top: 0.5rem;
	padding-left: var(--wp--preset--spacing--30, 1rem);
	border-left: 2px solid currentColor;
	border-left-color: color-mix(in srgb, currentColor 25%, transparent);
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-fixture__preview .ucdrs-fixture__preview-body > * {
	margin: 0.5rem 0 0;
}

.ucdrs-fixture__preview .ucdrs-fixture__preview-body > :first-child {
	margin-top: 0;
}

/* A preview written as a crew list (ucdrs_crew_list_html()): squads as small headings, then a
   row per event, its name beside its crews, one crew to a line. Seat labels are small and faded
   so the names stand out. Colours follow the surrounding text, for white and navy alike. */
.ucdrs-fixture__preview .ucdrs-fixture__preview-body.has-crews {
	padding-left: 0;
	border-left: 0;
}

.ucdrs-crews {
	font-size: var(--wp--preset--font-size--small, 0.875rem);
}

.ucdrs-fixture__preview .ucdrs-crews p {
	margin: 0;
}

.ucdrs-fixture__preview .ucdrs-crews .ucdrs-crews__squad {
	margin: var(--wp--preset--spacing--40, 1.5rem) 0 0.5rem;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.ucdrs-fixture__preview .ucdrs-crews .ucdrs-crews__squad:first-child {
	margin-top: 0.25rem;
}

.ucdrs-crews__event {
	display: grid;
	grid-template-columns: 6.5rem minmax(0, 1fr);
	gap: 0.15rem var(--wp--preset--spacing--30, 1rem);
	padding: 0.6rem 0;
	border-top: 1px solid currentColor;
	border-top-color: color-mix(in srgb, currentColor 12%, transparent);
}

.ucdrs-fixture__preview .ucdrs-crews .ucdrs-crews__event-name {
	font-size: var(--wp--preset--font-size--medium, 1.0625rem);
	font-weight: 500;
	line-height: 1.4;
}

.ucdrs-fixture__preview .ucdrs-crews .ucdrs-crews__crew {
	display: flex;
	gap: 0.5rem;
	line-height: 1.6;
}

.ucdrs-fixture__preview .ucdrs-crews .ucdrs-crews__crew + .ucdrs-crews__crew {
	margin-top: 0.25rem;
}

.ucdrs-crews__tag {
	flex: none;
	align-self: start;
	margin-top: 0.15rem;
	padding: 0 0.4rem;
	border-radius: 4px;
	background: color-mix(in srgb, currentColor 10%, transparent);
	font-size: 0.7rem;
	font-weight: 600;
	line-height: 1.6;
}

.ucdrs-crews__rowers {
	display: flex;
	flex-wrap: wrap;
	gap: 0 0.9rem;
}

.ucdrs-crews__rower {
	white-space: nowrap;
}

.ucdrs-crews__rower .ucdrs-seat {
	margin-right: 0.15rem;
	font-size: 0.7rem;
	letter-spacing: 0.04em;
	opacity: 0.7;
}

.ucdrs-fixture__preview .ucdrs-crews .ucdrs-crews__text {
	margin: 0.5rem 0;
}

@media (max-width: 600px) {
	.ucdrs-crews__event {
		grid-template-columns: minmax(0, 1fr);
	}
}
