/*
 * CTA band (about-1, shop-product, shop-cart): one sentence on the left, the button on the right.
 * default: white panel with the soft shadow that closes a page (about 231px at 1440, the button aligned with the
 * first line, the text on a 968px column inside the 1220px panel). dark: full-width black band (button centred, the
 * text on the content width). Both use the theme's yellow primary button; on the black band its hover turns white.
 * Narrow screens: the button wraps below the text.
 * The original theme: block settings only, no rt-* classes (cta-band.wp.njk); this file styles the reference.
 */
:where(.rt-cta-band) {
	box-sizing: border-box;
	padding: var(--rt-spacing-section-small) var(--rt-spacing-40);
	background-color: var(--rt-color-base);
	box-shadow: var(--rt-cta-band-shadow);
	color: var(--rt-color-contrast);
}

:where(section.rt-cta-band--dark) {
	padding-inline: max(var(--rt-layout-root-padding-start, var(--rt-spacing-40)), (100% - var(--rt-layout-content, 71.25rem)) / 2);
	background-color: var(--rt-color-contrast);
	box-shadow: none;
	color: var(--rt-color-base);
}

/* The white panel overlaps what is around it, as the original theme's pattern margins: up into the section above by marginTop,
   and over the footer by marginBottom (-5.875rem unless the pattern sets one; -4.25rem on tablets, -2.5rem on phones) */
.rt-cta-band.rt-cta-band--default {
	margin-block: var(--rt-cta-band-margin-top, 0) var(--rt-cta-band-margin-bottom, -5.875rem);
}

@media (max-width: 64rem) {
	.rt-cta-band.rt-cta-band--default {
		margin-block-end: -4.25rem;
	}
}

@media (max-width: 37.5rem) {
	.rt-cta-band.rt-cta-band--default {
		margin-block-end: -2.5rem;
	}
}

section.rt-cta-band--dark {
	/* The primary button's black hover would vanish on the band */
	--rt-button-hover-bg: var(--rt-color-base);
	--rt-button-hover-color: var(--rt-color-contrast);
	--rt-button-hover-border: var(--rt-color-base);
}

:where(.rt-cta-band__inner) {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	justify-content: space-between;
	gap: var(--rt-spacing-40) var(--rt-spacing-50);
	max-width: 60.5rem;
	margin-inline: auto;
}

:where(.rt-cta-band--dark .rt-cta-band__inner) {
	align-items: center;
	max-width: none;
}

/* Roboto 18/26 in the reference; the theme's body font. Its width is the paragraph's Width setting (Fixed) in the original theme. */
:where(.rt-cta-band__text) {
	flex: 0 1 33.3125rem;
	margin: 0;
}

.rt-cta-band__text {
	color: inherit;
	font-size: var(--rt-font-size-base-plus);
	line-height: 1.4444;
}

/* The white panel's sentence in the text colour (the original theme's paragraph has no colour of its own) */
.rt-cta-band--default .rt-cta-band__text {
	color: var(--rt-color-body);
}

/* panel "cream" (cta-band-team): the panel on the cream colour; boldText: the sentence bold */
.rt-cta-band.rt-cta-band--cream {
	background-color: var(--rt-color-cream);
}

.rt-cta-band--bold .rt-cta-band__text {
	font-weight: var(--rt-font-weight-bold);
}

/* 24/36, up to 621px */
:where(.rt-cta-band--dark .rt-cta-band__text) {
	flex-basis: 38.8125rem;
}

.rt-cta-band--dark .rt-cta-band__text {
	font-size: var(--rt-font-size-large);
	line-height: 1.5;
}

:where(.rt-cta-band__actions) {
	display: flex;
	flex-wrap: wrap;
	gap: var(--rt-spacing-30);
}

@media (max-width: 37.5rem) {
	.rt-cta-band--dark .rt-cta-band__text {
		font-size: var(--rt-font-size-medium);
	}
}
