.type-choice-cards {
	display: grid;
	gap: 16px;
}

.type-choice-cards__separator {
	align-self: center;
	color: var(--color-raspberry);
	font-family: 'Hey August', sans-serif;
	font-size: 3rem;
	font-weight: 400;
	justify-self: center;
	line-height: 1;
	text-align: center;
}

.type-choice-card {
	background: var(--color-white);
	border: 3px solid transparent;
	border-radius: 16px;
	box-sizing: border-box;
	box-shadow: 6px 6px var(--color-eggshell);
	color: inherit;
	cursor: pointer;
	display: flex;
	flex-direction: column;
	font: inherit;
	gap: 12px;
	list-style: none;
	min-width: 0;
	padding: 24px;
	position: relative;
	text-align: left;
	transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
	width: 100%;
}

.type-choice-card--active {
	border-color: var(--color-raspberry);
	transform: translateY(-2px);
}

.type-choice-card:hover,
.type-choice-card:focus-visible {
	border-color: var(--color-raspberry);
	transform: translateY(-2px);
}

.type-choice-card:hover .type-choice-card__title,
.type-choice-card:focus-visible .type-choice-card__title {
	color: var(--color-raspberry);
}

.type-choice-card--active .type-choice-card__title {
	color: var(--color-raspberry);
}

/* Selected badge, mirroring the charity/donation card checkmark. These cards are
   buttons (not radios), so the --active modifier drives it, not :has(:checked). */
.type-choice-card__check {
	align-items: center;
	background: var(--color-raspberry);
	border-radius: 50%;
	color: var(--color-white);
	display: flex;
	height: 26px;
	justify-content: center;
	opacity: 0;
	position: absolute;
	right: 12px;
	top: 12px;
	transform: scale(0.5);
	transition: opacity 150ms ease, transform 180ms cubic-bezier(.34, 1.56, .64, 1);
	width: 26px;
}

.type-choice-card--active .type-choice-card__check {
	opacity: 1;
	transform: scale(1);
}

.type-choice-card__check svg {
	height: 14px;
	width: 14px;
}

.type-choice-card__image-wrapper {
	align-items: center;
	background-color: var(--color-nude);
	border-radius: 50%;
	display: flex;
	height: 48px;
	justify-content: center;
	margin-bottom: 8px;
	overflow: visible;
	width: 48px;
}

.type-choice-card__image {
	height: 64px;
	object-fit: contain;
	width: 64px;
}

.type-choice-card__tagline {
	color: var(--color-praline);
	font-size: 0.875rem;
	font-weight: 400;
	line-height: 1.4;
	margin-bottom: -4px;
}

.type-choice-card__title {
	color: var(--color-carbone);
	font-size: 1.5rem;
	font-weight: 700;
}

.type-choice-card__description {
	color: var(--color-carbone);
	line-height: 1.5;
	opacity: 0.65;
	overflow-wrap: anywhere;
}

.type-choice-events-section {
	margin-top: 32px;
}

.type-choice-events-section[hidden] {
	display: none;
}

.type-choice-events-section__divider {
	border: 0;
	border-top: 1px solid var(--color-caramel);
	margin: 0 0 24px;
}

.type-choice-events-section__title {
	color: var(--color-carbone);
	font-size: 1.25rem;
	font-weight: 700;
	margin: 0 0 16px;
}

/* Replayed by the controller each time the block wakes up (including on a card
   switch) to draw the eye to the freshly revealed occasions. */
@keyframes type-choice-title-flash {
	0% { transform: scale(1); color: var(--color-carbone); }
	25% { transform: scale(1.03); color: var(--color-raspberry); }
	60% { transform: scale(1); color: var(--color-raspberry); }
	100% { transform: scale(1); color: var(--color-carbone); }
}

.type-choice-events-section__title--flash {
	animation: type-choice-title-flash 0.7s ease-in-out;
	transform-origin: left center;
}

@media (prefers-reduced-motion: reduce) {
	.type-choice-events-section {
		transition: none;
	}

	.type-choice-events-section__title--flash {
		animation: none;
	}

	.type-choice-card__check {
		transition: none;
	}
}

.type-choice-card__events {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	padding: 0 8px 8px;
}

.type-choice-card__events[hidden] {
	display: none;
}

.type-choice-card__event {
	background-color: var(--color-white);
	border: 1px solid #d9d9d9;
	border-radius: 999px;
	color: var(--color-carbone);
	cursor: pointer;
	font-family: var(--body-regular-m-ff);
	font-size: var(--body-regular-m-fs);
	font-weight: var(--body-bold-m-fw);
	line-height: var(--body-regular-m-lh);
	max-width: 100%;
	overflow-wrap: anywhere;
	padding: 6px 12px;
	text-decoration: none;
	text-align: center;
	transition: background-color 0.3s ease-in-out, border-color 0.3s ease-in-out, color 0.3s ease-in-out;
}

.type-choice-card__event:hover,
.type-choice-card__event:focus-visible,
.type-choice-card__event:has(.type-choice-card__event-input:checked) {
	background-color: var(--color-white);
	border-color: var(--color-raspberry);
	color: var(--color-raspberry);
}

.type-choice-card__event:has(.type-choice-card__event-input:focus-visible) {
	outline: 2px solid var(--color-raspberry);
	outline-offset: 2px;
}

.type-choice-card__event-input {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	border: 0;
	clip: rect(0 0 0 0);
	overflow: hidden;
	white-space: nowrap;
}

.type-choice-card__event--disabled {
	cursor: not-allowed;
	opacity: 0.55;
}

.type-choice-card__event--disabled:hover,
.type-choice-card__event--disabled:focus-visible {
	background-color: var(--color-white);
	border-color: #d9d9d9;
	color: var(--color-carbone);
}

.type-choice-card:disabled,
.type-choice-card[disabled] {
	cursor: not-allowed;
	opacity: 0.7;
}

.type-choice-card:disabled:hover,
.type-choice-card:disabled:focus-visible {
	border-color: transparent;
	transform: none;
}

.type-choice-card:disabled:hover .type-choice-card__title,
.type-choice-card:disabled:focus-visible .type-choice-card__title {
	color: var(--color-carbone);
}

.type-choice-card__badge {
	background-color: var(--color-nude);
	border-radius: 999px;
	color: var(--color-carbone);
	font-size: 0.75rem;
	font-weight: 600;
	margin-top: 4px;
	padding: 2px 10px;
	width: fit-content;
}

/* Small-screen variant: drop the description and pack image + tagline + title
   into a two-row grid where the image spans both text rows. */
@media screen and (max-width: 719px) {
	.type-choice-card {
		align-items: center;
		column-gap: 16px;
		display: grid;
		grid-template-areas:
			"image tagline"
			"image title";
		grid-template-columns: auto 1fr;
		row-gap: 4px;
	}

	.type-choice-card__image-wrapper {
		grid-area: image;
		margin-bottom: 0;
	}

	.type-choice-card__tagline {
		align-self: end;
		grid-area: tagline;
		margin-bottom: 0;
	}

	.type-choice-card__title {
		align-self: start;
		grid-area: title;
	}

	.type-choice-card__description {
		display: none;
	}
}

@media screen and (min-width: 720px) {
	.type-choice-cards {
		grid-template-columns: 1fr auto 1fr;
		gap: 16px;
	}

	.type-choice-card {
		padding: 32px;
	}
}
