/**
 * Styles for the Dreamcloud section blocks.
 *
 * Loaded on the front end per block, and in full inside the editor canvas.
 * Mobile first: every layout starts as a single column and widens at 600px
 * and 900px.
 *
 * @package Dreamcloud
 */

/* -----------------------------------------------------------------------------
 * Tokens
 * -------------------------------------------------------------------------- */

.dc-slider,
.dc-section,
.dc-lightbox {
	--dc-primary: var(--wp--preset--color--accent, #c8191e);
	/* A fixed darker shade of the accent, for hover and pressed states. */
	--dc-primary-hover: #a01418;
	/* Stands in for the primary where red is too dim to read, i.e. on charcoal. */
	--dc-secondary: var(--wp--preset--color--accent-2, #5aa5e6);
	--dc-dark: var(--wp--preset--color--accent-4, #101214);
	--dc-ink: var(--wp--preset--color--contrast, #16181a);
	--dc-muted: var(--wp--preset--color--contrast-2, #4d5257);
	--dc-line: var(--wp--preset--color--accent-5, #c0c2c4);
	--dc-surface: var(--wp--preset--color--base, #fff);
	--dc-container: var(--wp--style--global--wide-size, 1320px);
	--dc-gutter: clamp(1rem, 4vw, 2.5rem);
	--dc-radius: 12px;
}

/* -----------------------------------------------------------------------------
 * Hero slider
 * -------------------------------------------------------------------------- */

/*
 * The hero is designed to sit flush against the header, so the theme's default
 * block gap is removed here. The margin controls in the sidebar still win,
 * because those land on the element as an inline style.
 */
.wp-site-blocks > .wp-block-dreamcloud-hero-slider,
.wp-site-blocks .wp-block-dreamcloud-hero-slider:first-child,
.editor-styles-wrapper .wp-block-dreamcloud-hero-slider:first-child {
	margin-block-start: 0;
}

/*
 * Full width bands stack straight onto each other. The block gap would open a
 * strip of page background between two sections, which reads as a seam rather
 * than as spacing - each band already carries its own generous padding.
 */
.dc-slider + .dc-slider,
.dc-slider + .dc-section,
.dc-section + .dc-slider,
.dc-section + .dc-section {
	margin-block-start: 0;
}

/*
 * The home body is a plain group rather than a section block, so it misses the
 * rule above and the block gap opens a strip of page background under the hero.
 */
.dc-slider + .dc-home,
.dc-home + .dc-slider {
	margin-block-start: 0;
}

.dc-slider {
	position: relative;
	overflow: hidden;
	background-color: var(--dc-dark);
}

.dc-slider__viewport {
	position: relative;
	min-height: var(--dc-slider-height-mobile, 460px);
}

.dc-slider__track {
	position: relative;
	display: grid;
	min-height: inherit;
}

/*
 * All slides share one grid cell so the slider keeps the height of its tallest
 * slide and never jumps between transitions.
 */
.dc-slider__track > .dc-slide {
	grid-area: 1 / 1;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.6s ease;
	pointer-events: none;
}

.dc-slider__track > .dc-slide.is-active {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

/*
 * Without JS the first slide is still readable. Scoped to the pre-init state so
 * it cannot fight the .is-active rule once the script has run - both selectors
 * carry the same specificity, and this one comes last.
 */
.dc-slider:not([data-dc-slider-ready]) .dc-slider__track > .dc-slide:first-child {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.dc-slide {
	position: relative;
	min-height: var(--dc-slider-height-mobile, 460px);
	overflow: hidden;
}

.dc-slide__image {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: var(--dc-slide-focal-x, 50%) var(--dc-slide-focal-y, 50%);
}

.dc-slider__arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	z-index: 3;
	display: none;
	place-items: center;
	width: 48px;
	height: 48px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(16, 18, 20, 0.45);
	color: #fff;
	cursor: pointer;
	transition: background-color 0.18s ease;
}

.dc-slider__arrow svg {
	width: 22px;
	height: 22px;
}

.dc-slider__arrow:hover,
.dc-slider__arrow:focus-visible {
	background: var(--dc-primary);
}

.dc-slider__arrow--prev {
	inset-inline-start: clamp(0.5rem, 2vw, 1.5rem);
}

.dc-slider__arrow--next {
	inset-inline-end: clamp(0.5rem, 2vw, 1.5rem);
}

.dc-slider__dots {
	position: absolute;
	inset-inline: 0;
	bottom: clamp(1rem, 3vw, 1.75rem);
	z-index: 3;
	display: flex;
	justify-content: center;
	gap: 0.5rem;
}

.dc-slider__dot {
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	background: none;
	cursor: pointer;
	display: grid;
	place-items: center;
}

.dc-slider__dot span {
	display: block;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.45);
	transition: background-color 0.18s ease, transform 0.18s ease;
}

.dc-slider__dot.is-active span {
	background: var(--dc-primary);
	transform: scale(1.35);
}

/* -----------------------------------------------------------------------------
 * Sections shared by the video and news grids
 * -------------------------------------------------------------------------- */

/*
 * The light or dark theme colours the whole band rather than the container the
 * block happens to sit in. The spread shadow carries the colour out past both
 * edges no matter how deeply the block is nested, and the clip keeps it from
 * bleeding into whatever sits above and below.
 */
.dc-section {
	--dc-section-bg: var(--dc-surface);
	padding-block: clamp(2rem, 2vw, 3rem);
	background-color: var(--dc-section-bg);
	box-shadow: 0 0 0 100vmax var(--dc-section-bg);
	clip-path: inset(0 -100vmax);
	color: var(--dc-ink);
}

.dc-section.is-theme-dark {
	--dc-section-bg: var(--dc-dark);
	color: #fff;
}

/*
 * Headings inherit their colour now that theme.json no longer pins them to
 * `contrast`, but links are still coloured explicitly and Global Styles can put
 * a colour back on headings. Both are forced light here so a dark band cannot
 * end up with near-black text on it. `:not(.has-text-color)` leaves a
 * deliberate per-block colour alone; the three dark neutrals are remapped
 * below instead.
 */
.dc-section.is-theme-dark :where(h1, h2, h3, h4, h5, h6):not(.has-text-color),
.dc-section.is-theme-dark :where(h1, h2, h3, h4, h5, h6):not(.has-text-color) a,
.dc-section.is-theme-dark a:where(:not(.wp-element-button)):not(.has-text-color) {
	color: #fff;
}

.dc-section.is-theme-dark .has-contrast-color,
.dc-section.is-theme-dark .has-contrast-2-color,
.dc-section.is-theme-dark .has-contrast-3-color {
	color: rgba(255, 255, 255, 0.78);
}

/* The default button is near black, which is invisible on a charcoal band. */
.dc-section.is-theme-dark .wp-element-button:not(.has-background),
.dc-section.is-theme-dark .wp-block-button__link:not(.has-background) {
	background-color: #fff;
	border-color: #fff;
	color: var(--dc-dark);
}

.dc-section.is-theme-dark .wp-element-button:not(.has-background):hover,
.dc-section.is-theme-dark .wp-element-button:not(.has-background):focus,
.dc-section.is-theme-dark .wp-block-button__link:not(.has-background):hover,
.dc-section.is-theme-dark .wp-block-button__link:not(.has-background):focus {
	background-color: var(--dc-line);
	border-color: var(--dc-line);
	color: var(--dc-dark);
}

.dc-section__inner {
	max-width: var(--dc-container);
	margin-inline: auto;
	padding-inline: var(--dc-gutter);
}

/*
 * A section stacked inside a content column, rather than as a full width band.
 * The column already supplies the page gutter and the band background, so the
 * section drops both and keeps only the space that separates it from the next.
 */
/*
 * The band paints its background with a 100vmax box shadow so it can bleed past
 * its container. Inside a column that would flood the whole page, so the bleed
 * is switched off here and the surrounding group supplies the colour instead.
 */
.dc-section.dc-section--column {
	padding-block: 0 clamp(2rem, 4vw, 3rem);
	background-color: transparent;
	box-shadow: none;
	clip-path: none;
}

.dc-section--column .dc-section__inner {
	max-width: none;
	padding-inline: 0;
}

.dc-section--column .dc-section__header {
	margin-block-end: clamp(1.25rem, 2.5vw, 1.75rem);
}

/* The title competes with the page masthead at band size, so it steps down. */
.dc-section--column .dc-section__title {
	font-size: clamp(1.25rem, 2vw, 1.5rem);
	letter-spacing: 0.01em;
	text-transform: uppercase;
}

.dc-section--column .dc-section__icon {
	width: 1.875rem;
	height: 1.875rem;
}

.dc-section--column .dc-section__icon svg {
	width: 1rem;
	height: 1rem;
}

.dc-section--column .dc-section__view-all {
	min-height: 36px;
	padding-inline: 0.9rem;
	font-size: 0.6875rem;
}

/*
 * The rule under the header ties the title to the grid below it and gives the
 * section a masthead feel rather than a title floating in space.
 */
.dc-section__header {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 0.5rem 2rem;
	margin-block-end: clamp(2rem, 4vw, 3rem);
	padding-block-end: clamp(1rem, 2vw, 1.5rem);
	border-block-end: 1px solid var(--dc-line);
}

.dc-section.is-theme-dark .dc-section__header {
	border-block-end-color: rgba(255, 255, 255, 0.16);
}

.dc-section__heading {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	min-width: 0;
}

/* The badge is a fixed square: the glyph inside scales, the box never does. */
.dc-section__icon {
	display: grid;
	place-items: center;
	flex: 0 0 auto;
	width: 2.25rem;
	height: 2.25rem;
	border-radius: 8px;
	background-color: var(--dc-primary);
	color: #fff;
}

.dc-section__icon svg {
	width: 1.25rem;
	height: 1.25rem;
}

/* Utility sections take amber, so they read as tools rather than headlines. */
.dc-section__icon--bars,
.dc-section__icon--grid,
.dc-section__icon--bolt {
	background-color: var(--wp--preset--color--accent-3, #d64b00);
}

.dc-section__title {
	margin: 0;
	font-family: var(--wp--preset--font-family--heading, inherit);
	font-size: clamp(1.75rem, 3.5vw, 2.75rem);
	font-weight: 700;
	line-height: 1.1;
	letter-spacing: -0.025em;
	text-wrap: balance;
}

.dc-section.is-theme-dark .dc-section__title {
	color: #fff;
}

/*
 * An outlined pill rather than a text link. It sits opposite a heavy section
 * title, so it needs a defined edge to hold its own without competing on
 * weight - the fill only arrives on hover.
 */
.dc-section__view-all {
	display: inline-flex;
	align-items: center;
	min-height: 44px;
	padding-inline: 1.25rem;
	border: 1px solid currentColor;
	border-radius: 999px;
	font-size: 0.8125rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	text-decoration: none;
	color: var(--dc-primary);
	white-space: nowrap;
	transition: background-color 0.18s ease, color 0.18s ease,
		border-color 0.18s ease;
}

/* Amber reads on charcoal where the primary red goes muddy. */
.dc-section.is-theme-dark .dc-section__view-all {
	color: var(--wp--preset--color--accent-3, #d64b00);
}

.dc-section__view-all:hover,
.dc-section__view-all:focus-visible {
	background-color: var(--dc-primary);
	border-color: var(--dc-primary);
	color: #fff;
}

.dc-section.is-theme-dark .dc-section__view-all:hover,
.dc-section.is-theme-dark .dc-section__view-all:focus-visible {
	background-color: var(--wp--preset--color--accent-3, #d64b00);
	border-color: var(--wp--preset--color--accent-3, #d64b00);
	color: var(--dc-dark);
}

.dc-section__empty {
	margin: 0;
	padding: 2rem;
	border: 1px dashed var(--dc-line);
	border-radius: var(--dc-radius);
	text-align: center;
	color: var(--dc-muted);
}

.dc-section.is-theme-dark .dc-section__empty {
	border-color: rgba(255, 255, 255, 0.24);
	color: rgba(255, 255, 255, 0.7);
}

.dc-grid {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: clamp(1.75rem, 3vw, 2.5rem) clamp(1.25rem, 2.5vw, 2rem);
	grid-template-columns: 1fr;
}

.dc-card {
	margin: 0;
	min-width: 0;
}

.dc-card__media {
	position: relative;
	display: block;
	overflow: hidden;
	border-radius: var(--dc-radius);
	background-color: var(--dc-line);
	aspect-ratio: 16 / 9;
}

.dc-card__image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.35s ease;
}

.dc-card__image--placeholder {
	background: linear-gradient(135deg, var(--dc-primary), var(--dc-dark));
}

/*
 * Self hosted videos stand in for a poster image: the browser paints the first
 * frame from the metadata. It is decoration, so clicks fall through to the
 * card link behind it.
 */
.dc-video-preview {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	pointer-events: none;
	background-color: var(--dc-dark, #101214);
}

.dc-card__title {
	display: block;
	margin: 0;
	font-family: var(--wp--preset--font-family--heading, inherit);
	font-size: clamp(1.0625rem, 1.4vw, 1.25rem);
	font-weight: 700;
	line-height: 1.3;
	letter-spacing: -0.015em;
	text-wrap: pretty;
}

.dc-card__meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.4rem;
	margin: 0;
	font-size: 0.8125rem;
	font-variant-numeric: tabular-nums;
	letter-spacing: 0.01em;
	color: var(--dc-muted);
}

.dc-section.is-theme-dark .dc-card__meta {
	color: rgba(255, 255, 255, 0.7);
}

/* -----------------------------------------------------------------------------
 * Intro section
 * -------------------------------------------------------------------------- */

.dc-intro__content {
	display: flex;
	flex-direction: column;
	gap: clamp(0.75rem, 1.5vw, 1.25rem);
}

/*
 * Narrow caps the introduction near 65 characters, which is where longer
 * paragraphs stay comfortable to read. Wide is for short, poster-like copy.
 */
.dc-intro.is-width-narrow .dc-intro__content {
	max-width: 46rem;
}

.dc-intro.is-align-center .dc-intro__content {
	margin-inline: auto;
	text-align: center;
}

.dc-intro__eyebrow {
	margin: 0;
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	line-height: 1.2;
	text-transform: uppercase;
	color: var(--dc-primary);
}

.dc-section.is-theme-dark .dc-intro__eyebrow {
	color: var(--dc-secondary, #5aa5e6);
}

.dc-intro__heading {
	margin: 0;
	font-family: var(--wp--preset--font-family--heading, inherit);
	font-size: clamp(2rem, 5vw, 3.5rem);
	font-weight: 700;
	line-height: 1.05;
	letter-spacing: -0.03em;
	text-wrap: balance;
}

.dc-section.is-theme-dark .dc-intro__heading {
	color: #fff;
}

.dc-intro__lede {
	margin: 0;
	font-size: clamp(1.0625rem, 1.6vw, 1.3125rem);
	line-height: 1.6;
	color: var(--dc-muted);
	text-wrap: pretty;
}

.dc-section.is-theme-dark .dc-intro__lede {
	color: rgba(255, 255, 255, 0.78);
}

.dc-intro__extra:not(:empty) {
	margin-block-start: clamp(2rem, 4vw, 3rem);
}

.dc-intro.is-align-center .dc-intro__extra {
	text-align: center;
}

.dc-intro.is-align-center .dc-intro__extra .wp-block-buttons {
	justify-content: center;
}

/* The editor canvas has no server render, so the empty area still needs height. */
.dc-intro--editor .dc-intro__extra {
	min-height: 1px;
}

/* -----------------------------------------------------------------------------
 * Video cards
 * -------------------------------------------------------------------------- */

.dc-card--video .dc-card__link {
	display: flex;
	flex-direction: column;
	gap: 1rem;
	text-decoration: none;
	color: inherit;
}

.dc-card--video .dc-card__body {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
}

.dc-play {
	position: absolute;
	inset: 0;
	margin: auto;
	width: 64px;
	height: 64px;
	display: grid;
	place-items: center;
	border-radius: 50%;
	background: var(--dc-primary);
	color: #fff;
	box-shadow: 0 10px 30px rgba(200, 25, 30, 0.35);
	transition: transform 0.25s ease, background-color 0.25s ease;
}

.dc-play__icon {
	width: 28px;
	height: 28px;
	/* Nudged right so the triangle reads as centred inside the circle. */
	margin-inline-start: 3px;
}

.dc-card--video .dc-card__link:hover .dc-play,
.dc-card--video .dc-card__link:focus-visible .dc-play {
	transform: scale(1.1);
	background: var(--dc-primary-hover, #a01418);
}

.dc-card--video .dc-card__link:hover .dc-card__image,
.dc-card--video .dc-card__link:focus-visible .dc-card__image {
	transform: scale(1.05);
}

.dc-card--video .dc-card__link:hover .dc-card__title,
.dc-card--video .dc-card__link:focus-visible .dc-card__title {
	text-decoration: underline;
	text-underline-offset: 3px;
}

.dc-card__duration {
	position: absolute;
	inset-block-end: 0.6rem;
	inset-inline-end: 0.6rem;
	padding: 0.15rem 0.45rem;
	border-radius: 4px;
	background: rgba(12, 14, 16, 0.82);
	color: #fff;
	font-size: 0.75rem;
	font-weight: 600;
	letter-spacing: 0.02em;
}

/* -----------------------------------------------------------------------------
 * News cards
 * -------------------------------------------------------------------------- */

.dc-card--news {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.dc-card--news .dc-card__body {
	display: flex;
	flex-direction: column;
	gap: 0.55rem;
}

.dc-card__eyebrow {
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	line-height: 1.2;
	text-transform: uppercase;
	color: var(--dc-primary);
}

/* The red drops below 3:1 on charcoal, so the eyebrow lightens on dark. */
.dc-section.is-theme-dark .dc-card__eyebrow {
	color: var(--dc-secondary, #5aa5e6);
}

.dc-card--news .dc-card__title a {
	color: inherit;
	text-decoration: none;
}

.dc-card--news .dc-card__title a:hover,
.dc-card--news .dc-card__title a:focus-visible {
	text-decoration: underline;
	text-underline-offset: 3px;
}

.dc-card--news:hover .dc-card__image {
	transform: scale(1.05);
}

.dc-card__excerpt {
	margin: 0;
	font-size: 0.9375rem;
	line-height: 1.6;
	color: var(--dc-muted);
	text-wrap: pretty;
}

.dc-section.is-theme-dark .dc-card__excerpt {
	color: rgba(255, 255, 255, 0.78);
}

.dc-card__meta-sep {
	color: var(--dc-line);
}

/* -----------------------------------------------------------------------------
 * List layout
 *
 * One item per line - thumbnail first, then the text - shared by the news and
 * video sections so a narrow column reads the same whichever it holds.
 *
 * The column count is set in a media query further down. These selectors carry
 * a second class so the single column wins wherever they end up in the cascade.
 * -------------------------------------------------------------------------- */

.dc-grid.dc-grid--list {
	grid-template-columns: 1fr;
	gap: 0;
}

/*
 * A rule between rows rather than a gap: at this density the cards read as one
 * list, and the line is what separates two neighbouring thumbnails.
 */
.dc-grid--list > .dc-card + .dc-card {
	margin-block-start: 0.9rem;
	padding-block-start: 0.9rem;
	border-block-start: 1px solid var(--dc-line);
}

.dc-section.is-theme-dark .dc-grid--list > .dc-card + .dc-card {
	border-block-start-color: rgba(255, 255, 255, 0.14);
}

.dc-grid--list .dc-card--news,
.dc-grid--list .dc-card--video .dc-card__link {
	flex-direction: row;
	align-items: flex-start;
	gap: 0.85rem;
}

/*
 * A flex basis rather than a grid track, so a card with its featured image
 * switched off gives the text the full width instead of leaving a gap.
 */
.dc-grid--list .dc-card__media {
	flex: 0 0 var(--dc-thumb, 7.5rem);
	width: var(--dc-thumb, 7.5rem);
}

.dc-grid--list .dc-card__body {
	flex: 1 1 auto;
	min-width: 0;
	gap: 0.3rem;
}

/* The type steps down: a row headline sits beside its thumbnail, not above it. */
.dc-grid--list .dc-card__title {
	font-size: 0.9375rem;
	line-height: 1.35;
	letter-spacing: -0.005em;
}

.dc-grid--list .dc-card__excerpt {
	font-size: 0.8125rem;
	line-height: 1.5;
}

.dc-grid--list .dc-card__meta {
	font-size: 0.75rem;
}

/* The badge is sized for a full width poster; on a thumbnail it would bury it. */
.dc-grid--list .dc-play {
	width: 34px;
	height: 34px;
	box-shadow: 0 4px 12px rgba(200, 25, 30, 0.35);
}

.dc-grid--list .dc-play__icon {
	width: 15px;
	height: 15px;
	margin-inline-start: 2px;
}

.dc-grid--list .dc-card__duration {
	inset-block-end: 0.3rem;
	inset-inline-end: 0.3rem;
	padding: 0.05rem 0.3rem;
	font-size: 0.6875rem;
}

/* -----------------------------------------------------------------------------
 * Ranked list
 * -------------------------------------------------------------------------- */

.dc-rank__legend {
	margin: 0 0 0.4rem;
	text-align: end;
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--dc-muted);
}

.dc-section.is-theme-dark .dc-rank__legend {
	color: rgba(255, 255, 255, 0.6);
}

.dc-rank {
	list-style: none;
	margin: 0;
	padding: 0;
}

.dc-rank__row {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding-block: 0.5rem;
	border-block-start: 1px solid var(--dc-line);
}

.dc-rank__row:first-child {
	border-block-start: 0;
}

.dc-section.is-theme-dark .dc-rank__row {
	border-block-start-color: rgba(255, 255, 255, 0.12);
}

/* A fixed track, so the names line up whether the rank is 1 or 25. */
.dc-rank__number {
	flex: 0 0 1.75rem;
	text-align: center;
	font-size: 0.8125rem;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	color: var(--dc-muted);
}

.dc-section.is-theme-dark .dc-rank__number {
	color: rgba(255, 255, 255, 0.55);
}

/* The podium takes the accent, so the head of the board reads first. */
.dc-rank__row:nth-child(-n + 3) .dc-rank__number {
	color: var(--dc-primary);
}

.dc-section.is-theme-dark .dc-rank__row:nth-child(-n + 3) .dc-rank__number {
	color: var(--wp--preset--color--accent-3, #d64b00);
}

.dc-rank__body {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 0.1rem;
	color: inherit;
	text-decoration: none;
}

a.dc-rank__body:hover .dc-rank__name,
a.dc-rank__body:focus-visible .dc-rank__name {
	text-decoration: underline;
	text-underline-offset: 3px;
}

.dc-rank__name {
	font-size: 0.9375rem;
	font-weight: 600;
	line-height: 1.3;
	/* Long names break rather than push the points column off the card. */
	overflow-wrap: anywhere;
}

.dc-rank__meta {
	font-size: 0.75rem;
	letter-spacing: 0.02em;
	color: var(--dc-muted);
}

.dc-section.is-theme-dark .dc-rank__meta {
	color: rgba(255, 255, 255, 0.62);
}

.dc-rank__value {
	flex: 0 0 auto;
	font-size: 0.8125rem;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	color: var(--dc-ink);
}

.dc-section.is-theme-dark .dc-rank__value {
	color: #fff;
}

/* -----------------------------------------------------------------------------
 * Panels
 *
 * The boxed look the home page is built from. Colours are mixed from
 * currentColor so one panel reads as raised on the charcoal body and as inset
 * on a light one, with the charcoal values left as the fallback.
 *
 * These live here rather than in theme.css so the editor canvas, which loads
 * this file in full, previews the page the way visitors see it.
 * -------------------------------------------------------------------------- */

.dc-panel {
	padding: clamp(1rem, 2vw, 1.25rem);
	border: 1px solid rgba(255, 255, 255, 0.09);
	border-color: color-mix(in srgb, currentColor 14%, transparent);
	border-radius: var(--dc-radius, 12px);
	background-color: rgba(255, 255, 255, 0.045);
	background-color: color-mix(in srgb, currentColor 6%, transparent);
}

/*
 * A section inside a panel already sits on the panel's padding, so it drops the
 * trailing space it would otherwise use to clear the next section in a column.
 */
.dc-panel .dc-section--column {
	padding-block: 0;
}

/*
 * The board the article and ranking panels sit on. In the design the left of
 * the page reads as one surface holding several cards, rather than as cards
 * floating on the page background, so it takes a lighter fill than the panels
 * inside it and lets their borders stay the stronger line.
 */
/*
 * A panel whose contents have not been decided yet. It keeps the height the
 * design gives it so the row beside it does not collapse, and carries no
 * heading on purpose: naming it would be deciding what goes in it.
 */
.dc-panel--slot {
	min-height: 18rem;
}

.dc-home__box {
	padding: clamp(0.75rem, 1.5vw, 1rem);
	border: 1px solid rgba(255, 255, 255, 0.07);
	border-color: color-mix(in srgb, currentColor 11%, transparent);
	border-radius: var(--dc-radius, 12px);
	background-color: rgba(255, 255, 255, 0.022);
	background-color: color-mix(in srgb, currentColor 3%, transparent);
}

/* For a core heading standing in for a section title, in a panel with no block. */
.dc-panel__title {
	margin-block: 0 clamp(1.25rem, 2.5vw, 1.75rem);
	padding-block-end: clamp(1rem, 2vw, 1.5rem);
	border-block-end: 1px solid rgba(255, 255, 255, 0.16);
	border-block-end-color: color-mix(in srgb, currentColor 22%, transparent);
	font-family: var(--wp--preset--font-family--heading, inherit);
	font-size: clamp(1.25rem, 2vw, 1.5rem);
	font-weight: 700;
	line-height: 1.1;
	letter-spacing: 0.01em;
	text-transform: uppercase;
}

.dc-panel__text {
	margin-block: 0;
	color: rgba(255, 255, 255, 0.78);
	color: color-mix(in srgb, currentColor 78%, transparent);
}

/*
 * An embed with no URL yet saves an empty wrapper, which collapses to nothing.
 * In the canvas that would leave the editor with no target to click, so the
 * slot is drawn as a dashed placeholder there and stays invisible to visitors.
 */
.editor-styles-wrapper .dc-panel__embed .wp-block-embed__wrapper {
	min-height: 152px;
	border: 1px dashed rgba(255, 255, 255, 0.28);
	border-color: color-mix(in srgb, currentColor 30%, transparent);
	border-radius: 8px;
}

/* -----------------------------------------------------------------------------
 * Announcement / sponsor band
 * -------------------------------------------------------------------------- */

.dc-promo__eyebrow {
	margin: 0;
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--wp--preset--color--accent-3, #d64b00);
}

.dc-promo__title {
	margin: 0;
	text-wrap: balance;
}

.dc-promo__text {
	margin: 0;
	color: rgba(255, 255, 255, 0.78);
	color: color-mix(in srgb, currentColor 78%, transparent);
}

.dc-promo__media {
	margin: 0;
}

/* Capped rather than free standing, so a tall upload cannot stretch the band. */
.dc-promo__media img {
	display: block;
	width: 100%;
	max-height: 150px;
	object-fit: cover;
	border-radius: 8px;
}

/* -----------------------------------------------------------------------------
 * Video lightbox
 * -------------------------------------------------------------------------- */

.dc-lightbox[hidden] {
	display: none;
}

.dc-lightbox {
	position: fixed;
	inset: 0;
	z-index: 999999;
	display: grid;
	place-items: center;
	padding: clamp(1rem, 4vw, 3rem);
}

.dc-lightbox__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(8, 10, 12, 0.88);
	border: 0;
}

.dc-lightbox__panel {
	position: relative;
	width: min(100%, 1100px);
}

.dc-lightbox__frame {
	position: relative;
	aspect-ratio: 16 / 9;
	background: #000;
	border-radius: var(--dc-radius, 12px);
	overflow: hidden;
}

.dc-lightbox__video {
	width: 100%;
	height: 100%;
	border: 0;
	display: block;
}

.dc-lightbox__close {
	position: absolute;
	top: -52px;
	inset-inline-end: 0;
	width: 44px;
	height: 44px;
	display: grid;
	place-items: center;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.14);
	color: #fff;
	cursor: pointer;
}

.dc-lightbox__close:hover,
.dc-lightbox__close:focus-visible {
	background: var(--dc-primary, #c8191e);
}

.dc-lightbox__close svg {
	width: 22px;
	height: 22px;
}

.dc-lightbox-open,
.dc-lightbox-open body {
	overflow: hidden;
}

/*
 * Repeated from theme.css because that file is front-end only, and the grids are
 * previewed inside the editor canvas.
 */
.dc-card .screen-reader-text {
	border: 0;
	clip-path: inset(50%);
	height: 1px;
	margin: -1px;
	overflow: hidden;
	padding: 0;
	position: absolute;
	white-space: nowrap;
	width: 1px;
}

/* -----------------------------------------------------------------------------
 * Focus visibility
 * -------------------------------------------------------------------------- */

.dc-slider a:focus-visible,
.dc-slider button:focus-visible,
.dc-section a:focus-visible,
.dc-lightbox button:focus-visible {
	outline: 3px solid var(--dc-primary, #c8191e);
	outline-offset: 3px;
	border-radius: 4px;
}

/* -----------------------------------------------------------------------------
 * Breakpoints
 * -------------------------------------------------------------------------- */

@media (min-width: 600px) {
	.dc-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (min-width: 900px) {
	.dc-slider__viewport,
	.dc-slide {
		min-height: var(--dc-slider-height, 620px);
	}

	.dc-slider__arrow {
		display: grid;
	}

	.dc-grid {
		grid-template-columns: repeat(
			var(--dc-columns, 4),
			minmax(0, 1fr)
		);
	}
}

@media (prefers-reduced-motion: reduce) {
	.dc-slider__track > .dc-slide,
	.dc-card__image,
	.dc-play,
	.dc-section__view-all svg {
		transition: none;
	}
}

/* -----------------------------------------------------------------------------
 * Editor canvas
 * -------------------------------------------------------------------------- */

/*
 * The full-bleed clip would cut the top and bottom of the editor's own block
 * selection outline, so inside the canvas the band just fills the block. The
 * block is already full width there, so the preview still matches.
 */
.editor-styles-wrapper .dc-section {
	box-shadow: none;
	clip-path: none;
}

.dc-slider--editor {
	overflow: visible;
}

.dc-slider--editor .dc-slider__editor-track {
	display: flex;
	flex-direction: column;
	gap: 1rem;
}

.dc-slider--editor .dc-slide {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
	min-height: 380px;
	background-size: cover;
	background-position: var(--dc-slide-focal-x, 50%) var(--dc-slide-focal-y, 50%);
	border-radius: 8px;
}

.dc-slide__hint {
	position: absolute;
	inset-block-end: 0.75rem;
	inset-inline-start: 0.75rem;
	padding: 0.35rem 0.75rem;
	border-radius: 4px;
	background: rgba(12, 14, 16, 0.75);
	color: #fff;
	font-size: 0.75rem;
}
