/**
 * RCS content layer — brings every inner page (login, membership account, launch pages,
 * contact, about, 404) in line with the landing page.
 *
 * CSS only: it restyles the base theme's existing markup and the markup PMPro, WPForms
 * and the launch snippets already output. No template, shortcode or snippet is changed.
 * Everything is scoped to `body.rcs-ui`, so removing the UI layer restores the old look.
 */

/* -------------------------------------------------------------------------- */
/*	Page header band
/* -------------------------------------------------------------------------- */

body.rcs-ui #site-content {
	color: var(--rcs-color-text);
	font-family: var(--rcs-font-sans);
}

body.rcs-ui .entry-header,
body.rcs-ui .archive-header {
	background: var(--rcs-color-bg-tint);
	border-bottom: 1px solid var(--rcs-color-border);
	margin-top: 0;
	padding: var(--rcs-space-7) 0 var(--rcs-space-6) !important; /* the base theme zeroes padding-top in some page states */
	text-align: left;
}

body.rcs-ui .entry-header-inner,
body.rcs-ui .archive-header-inner {
	margin-left: auto;
	margin-right: auto;
	max-width: 80rem;
	width: calc(100% - 2 * var(--rcs-gutter));
}

body.rcs-ui h1.entry-title,
body.rcs-ui .archive-title {
	color: var(--rcs-color-heading);
	font-family: var(--rcs-font-display);
	font-size: clamp(3rem, 2.2rem + 2vw, 4.4rem);
	font-weight: var(--rcs-weight-medium);
	letter-spacing: -0.02em;
	line-height: 1.1;
	margin: 0;
	text-align: left;
}

body.rcs-ui .entry-header .intro-text {
	color: var(--rcs-grey-700);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-lg);
	font-weight: var(--rcs-weight-regular);
	letter-spacing: 0;
	line-height: 1.5;
	margin: var(--rcs-space-3) 0 0;
	max-width: 60rem;
	text-align: left;
}

body.rcs-ui .entry-header .intro-text p {
	margin: 0;
}

body.rcs-ui .post-inner {
	padding-bottom: var(--rcs-space-8);
	padding-top: var(--rcs-space-7);
}

/* -------------------------------------------------------------------------- */
/*	Body copy
/* -------------------------------------------------------------------------- */

body.rcs-ui .entry-content {
	color: var(--rcs-color-text);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-base);
	letter-spacing: 0;
	line-height: var(--rcs-leading-body);
}

/* Same column as the header band, so title and text share a left edge. */
body.rcs-ui .entry-content > *:not(.alignwide):not(.alignfull):not(.alignleft):not(.alignright):not(.is-style-wide) {
	max-width: 80rem;
	width: calc(100% - 2 * var(--rcs-gutter));
}

body.rcs-ui .entry-content p,
body.rcs-ui .entry-content li {
	font-family: var(--rcs-font-sans);
	line-height: var(--rcs-leading-body);
}

body.rcs-ui .entry-content p {
	margin-bottom: var(--rcs-space-4);
	max-width: 72ch;
}

body.rcs-ui .entry-content h2,
body.rcs-ui .entry-content h3,
body.rcs-ui .entry-content h4 {
	color: var(--rcs-color-heading);
	letter-spacing: -0.015em;
	line-height: var(--rcs-leading-snug);
}

body.rcs-ui .entry-content > h2,
body.rcs-ui .entry-content > h3,
body.rcs-ui .entry-content > h4 {
	margin: var(--rcs-space-7) auto var(--rcs-space-3);
}

body.rcs-ui .entry-content h2 {
	font-family: var(--rcs-font-display);
	font-size: var(--rcs-text-2xl);
	font-weight: var(--rcs-weight-medium);
}

body.rcs-ui .entry-content h3 {
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-xl);
	font-weight: var(--rcs-weight-semibold);
}

body.rcs-ui .entry-content h4 {
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-lg);
	font-weight: var(--rcs-weight-semibold);
}

body.rcs-ui .entry-content > h2:first-child,
body.rcs-ui .entry-content > h3:first-child {
	margin-top: 0;
}

body.rcs-ui .entry-content a:not(.button):not(.wp-block-button__link):not(.rcs-btn):not([class*="pmpro_btn"]) {
	color: var(--rcs-color-link);
	text-decoration-thickness: 1px;
	text-underline-offset: 0.3rem;
}

body.rcs-ui .entry-content a:not(.button):not(.wp-block-button__link):not(.rcs-btn):not([class*="pmpro_btn"]):hover {
	color: var(--rcs-color-link-hover);
}

body.rcs-ui .entry-content blockquote,
body.rcs-ui .entry-content .wp-block-quote {
	border-color: var(--rcs-blue-600);
	border-width: 0 0 0 4px;
	color: var(--rcs-grey-700);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-base);
	padding: var(--rcs-space-1) 0 var(--rcs-space-1) var(--rcs-space-5);
}

body.rcs-ui .entry-content blockquote p {
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-base);
}

body.rcs-ui .entry-content hr,
body.rcs-ui .entry-content .wp-block-separator {
	background: var(--rcs-color-border) !important; /* base theme paints a gradient inline */
	border: 0;
	height: 1px;
	margin: var(--rcs-space-7) auto;
}

body.rcs-ui .entry-content hr::before,
body.rcs-ui .entry-content hr::after {
	display: none;
}

/* Editor list used on the About page for institutions. */
body.rcs-ui .entry-content ul.is-style-rcs-plain {
	border-top: 1px solid var(--rcs-color-border);
	list-style: none;
	margin-left: auto;
	padding: 0;
}

body.rcs-ui .entry-content ul.is-style-rcs-plain li {
	border-bottom: 1px solid var(--rcs-color-border);
	color: var(--rcs-blue-900);
	font-family: var(--rcs-font-display);
	font-size: var(--rcs-text-xl);
	font-weight: var(--rcs-weight-medium);
	margin: 0;
	padding: var(--rcs-space-4) 0;
}

/* -------------------------------------------------------------------------- */
/*	Buttons: block buttons, launch-snippet `.button` links, form submits
/* -------------------------------------------------------------------------- */

body.rcs-ui #site-content .button,
body.rcs-ui #site-content button:not(.rcs-nav-toggle):not(.pmpro_btn-plain):not([class*="toggle"]),
body.rcs-ui #site-content input[type="submit"],
body.rcs-ui #site-content input[type="button"],
body.rcs-ui #site-content .wp-block-button__link,
body.rcs-ui #site-content .wp-block-file__button {
	background: var(--rcs-color-action);
	border: 2px solid var(--rcs-color-action);
	border-radius: var(--rcs-radius-md);
	color: var(--rcs-color-on-action);
	display: inline-block;
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-base);
	font-weight: var(--rcs-weight-semibold);
	letter-spacing: 0;
	line-height: 1.2;
	padding: 1.3rem var(--rcs-space-5);
	text-decoration: none;
	text-transform: none;
	transition: background-color var(--rcs-duration) var(--rcs-ease), border-color var(--rcs-duration) var(--rcs-ease);
}

body.rcs-ui #site-content .button:hover,
body.rcs-ui #site-content .button:focus,
body.rcs-ui #site-content button:not(.rcs-nav-toggle):not(.pmpro_btn-plain):not([class*="toggle"]):hover,
body.rcs-ui #site-content input[type="submit"]:hover,
body.rcs-ui #site-content input[type="button"]:hover,
body.rcs-ui #site-content .wp-block-button__link:hover,
body.rcs-ui #site-content .wp-block-button__link:focus {
	background: var(--rcs-color-action-hover);
	border-color: var(--rcs-color-action-hover);
	color: var(--rcs-color-on-action);
	text-decoration: none;
}

body.rcs-ui #site-content .is-style-outline .wp-block-button__link {
	background: var(--rcs-white);
	border-color: var(--rcs-blue-700);
	color: var(--rcs-blue-700);
}

body.rcs-ui #site-content .is-style-outline .wp-block-button__link:hover,
body.rcs-ui #site-content .is-style-outline .wp-block-button__link:focus {
	background: var(--rcs-blue-100);
	color: var(--rcs-blue-700);
}

body.rcs-ui #site-content a:focus-visible,
body.rcs-ui #site-content button:focus-visible,
body.rcs-ui #site-content input[type="submit"]:focus-visible {
	box-shadow: var(--rcs-shadow-focus);
	outline: 2px solid transparent;
}

/* -------------------------------------------------------------------------- */
/*	Form fields
/* -------------------------------------------------------------------------- */

body.rcs-ui #site-content label {
	color: var(--rcs-grey-900);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-sm);
	font-weight: var(--rcs-weight-medium);
	letter-spacing: 0;
}

body.rcs-ui #site-content input[type="text"],
body.rcs-ui #site-content input[type="email"],
body.rcs-ui #site-content input[type="password"],
body.rcs-ui #site-content input[type="tel"],
body.rcs-ui #site-content input[type="url"],
body.rcs-ui #site-content input[type="number"],
body.rcs-ui #site-content input[type="search"],
body.rcs-ui #site-content select,
body.rcs-ui #site-content textarea {
	background: var(--rcs-white);
	border: 1px solid var(--rcs-grey-500);
	border-radius: var(--rcs-radius-md);
	color: var(--rcs-grey-900);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-base);
	letter-spacing: 0;
}

body.rcs-ui #site-content input:focus,
body.rcs-ui #site-content select:focus,
body.rcs-ui #site-content textarea:focus {
	border-color: var(--rcs-blue-600);
	box-shadow: 0 0 0 3px var(--rcs-blue-200);
	outline: 2px solid transparent;
}

/* -------------------------------------------------------------------------- */
/*	Paid Memberships Pro — colours and type only; layout and behaviour untouched
/* -------------------------------------------------------------------------- */

body.rcs-ui {
	--pmpro--color--accent: #1a5fa0;
	--pmpro--color--accent--variation: #124e82;
	--pmpro--color--base: #ffffff;
	--pmpro--color--contrast: #15202b;
	--pmpro--color--border--variation: #c9d1d9;
	--pmpro--base--border-radius: 0.8rem;
}

body.rcs-ui .pmpro,
body.rcs-ui .pmpro p,
body.rcs-ui .pmpro li,
body.rcs-ui .pmpro td,
body.rcs-ui .pmpro th,
body.rcs-ui .pmpro label,
body.rcs-ui .pmpro legend,
body.rcs-ui .pmpro a {
	font-family: var(--rcs-font-sans);
	letter-spacing: 0;
}

body.rcs-ui .pmpro h2,
body.rcs-ui .pmpro h3,
body.rcs-ui .pmpro .pmpro_card_title {
	color: var(--rcs-color-heading);
	font-family: var(--rcs-font-sans);
	font-weight: var(--rcs-weight-semibold);
	letter-spacing: -0.01em;
}

body.rcs-ui .pmpro .pmpro_card {
	border: 1px solid var(--rcs-color-border);
	border-radius: var(--rcs-radius-lg);
	box-shadow: none;
}

/* The base theme pads every <section> by 5rem; PMPro nests several per page. */
body.rcs-ui .pmpro section,
body.rcs-ui .pmpro .pmpro_section {
	margin: 0 0 var(--rcs-space-6);
	padding: 0;
}

body.rcs-ui .pmpro h2,
body.rcs-ui .pmpro h3 {
	margin: 0 0 var(--rcs-space-3);
}

body.rcs-ui .pmpro table {
	font-size: var(--rcs-text-sm);
}

/* -------------------------------------------------------------------------- */
/*	PMPro Membership Account page — presentation only, PMPro's own markup
/* -------------------------------------------------------------------------- */

body.rcs-ui .pmpro .pmpro_section_title {
	color: var(--rcs-color-heading);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-lg);
	font-weight: var(--rcs-weight-semibold);
	letter-spacing: 0;
	margin: 0 0 var(--rcs-space-3);
}

/* Profile card: identity band, then label/value rows. */
body.rcs-ui #pmpro_account-profile .pmpro_card_title {
	align-items: center;
	background: var(--rcs-color-bg-tint);
	border-bottom: 1px solid var(--rcs-color-border);
	display: flex;
	font-family: var(--rcs-font-display);
	font-size: var(--rcs-text-xl);
	font-weight: var(--rcs-weight-medium);
	gap: var(--rcs-space-4);
	letter-spacing: -0.01em;
	margin: 0;
	padding: var(--rcs-space-5);
}

body.rcs-ui #pmpro_account-profile .pmpro_card_title img {
	border: 2px solid var(--rcs-white);
	border-radius: 50%;
	box-shadow: 0 0 0 1px var(--rcs-color-border-strong);
	flex: none;
	height: 5.6rem;
	margin: 0;
	width: 5.6rem;
}

body.rcs-ui #pmpro_account-profile .pmpro_card_content {
	padding: 0 var(--rcs-space-5);
}

body.rcs-ui #pmpro_account-profile .pmpro_list {
	list-style: none;
	margin: 0;
	padding: 0;
}

body.rcs-ui #pmpro_account-profile .pmpro_list li {
	border-bottom: 1px solid var(--rcs-color-border);
	color: var(--rcs-grey-900);
	column-gap: 0.5rem;
	display: flex;
	flex-wrap: wrap;
	font-size: var(--rcs-text-sm);
	line-height: 1.5;
	margin: 0;
	overflow-wrap: anywhere;
	padding: var(--rcs-space-3) 0;
}

body.rcs-ui #pmpro_account-profile .pmpro_list li:last-child {
	border-bottom: 0;
}

/* The label: muted, fixed column on wide screens, its own line on narrow ones. */
body.rcs-ui #pmpro_account-profile .pmpro_list li > strong {
	color: var(--rcs-color-text-muted);
	flex: 0 0 100%;
	font-weight: var(--rcs-weight-medium);
}

@media (min-width: 700px) {

	body.rcs-ui #pmpro_account-profile .pmpro_list li > strong {
		flex-basis: 30rem;
	}
}

/* Card actions: quiet buttons instead of a grey bar of pipes. */
body.rcs-ui .pmpro .pmpro_card_actions {
	align-items: center;
	background: var(--rcs-white);
	border-top: 1px solid var(--rcs-color-border);
	display: flex;
	flex-wrap: wrap;
	gap: var(--rcs-space-2);
	padding: var(--rcs-space-4) var(--rcs-space-5);
}

body.rcs-ui .pmpro .pmpro_card_action_separator {
	display: none;
}

body.rcs-ui .pmpro .pmpro_card_actions .pmpro_card_action a:not(#rcs-x) {
	background: var(--rcs-white);
	border: 1px solid var(--rcs-color-border-strong);
	border-radius: var(--rcs-radius-md);
	color: var(--rcs-blue-700);
	display: inline-block;
	font-size: var(--rcs-text-sm);
	font-weight: var(--rcs-weight-semibold);
	line-height: 1.2;
	padding: 0.9rem var(--rcs-space-4);
	text-decoration: none;
}

body.rcs-ui .pmpro .pmpro_card_actions .pmpro_card_action a:not(#rcs-x):hover,
body.rcs-ui .pmpro .pmpro_card_actions .pmpro_card_action a:not(#rcs-x):focus {
	background: var(--rcs-blue-50);
	border-color: var(--rcs-blue-700);
	color: var(--rcs-blue-800);
}

/* Log out sits apart from the profile actions. */
body.rcs-ui #pmpro_account-profile .pmpro_card_action:last-child {
	margin-left: auto;
}

body.rcs-ui #pmpro_account-profile .pmpro_card_action:last-child a:not(#rcs-x) {
	border-color: transparent;
	color: var(--rcs-grey-700);
}

/* Memberships: one compact row per level inside a single bordered list. */
body.rcs-ui #pmpro_account-membership .pmpro_section_content {
	border: 1px solid var(--rcs-color-border);
	border-radius: var(--rcs-radius-lg);
	overflow: hidden;
}

body.rcs-ui #pmpro_account-membership .pmpro_card {
	align-items: center;
	border: 0;
	border-bottom: 1px solid var(--rcs-color-border);
	border-radius: 0;
	display: flex;
	flex-direction: row; /* PMPro cards are a column by default */
	flex-wrap: wrap;
	gap: var(--rcs-space-2) var(--rcs-space-4);
	justify-content: space-between;
	margin: 0;
	padding: var(--rcs-space-3) var(--rcs-space-5);
}

body.rcs-ui #pmpro_account-membership .pmpro_card:last-child {
	border-bottom: 0;
}

body.rcs-ui #pmpro_account-membership .pmpro_card_title {
	flex: 1 1 0;
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-base);
	font-weight: var(--rcs-weight-semibold);
	margin: 0;
	min-width: 0;
	padding: 0;
	text-align: left;
	width: auto;
}

/* Level details (cost, expiry) drop to their own line when PMPro has any to show… */
body.rcs-ui #pmpro_account-membership .pmpro_card_content {
	flex-basis: 100%;
	order: 3;
	padding: 0;
}

/* …and take no space at all when the list is empty, which is the usual case here. */
body.rcs-ui #pmpro_account-membership .pmpro_card_content:not(:has(li)) {
	display: none;
}

body.rcs-ui #pmpro_account-membership .pmpro_card_actions {
	background: transparent;
	border: 0;
	flex: none;
	padding: 0;
	width: auto;
}

body.rcs-ui #pmpro_account-membership .pmpro_card_actions .pmpro_card_action a:not(#rcs-x) {
	border-color: transparent;
	color: var(--rcs-grey-700);
	font-weight: var(--rcs-weight-medium);
	padding: 0.7rem var(--rcs-space-3);
}

body.rcs-ui #pmpro_account-membership .pmpro_card_actions .pmpro_card_action a:not(#rcs-x):hover,
body.rcs-ui #pmpro_account-membership .pmpro_card_actions .pmpro_card_action a:not(#rcs-x):focus {
	background: var(--rcs-danger-50);
	border-color: var(--rcs-danger-700);
	color: var(--rcs-danger-700);
}

/* -------------------------------------------------------------------------- */
/*	WPForms — the block writes its colours as inline custom properties
/* -------------------------------------------------------------------------- */

body.rcs-ui .wpforms-container {
	--wpforms-button-background-color: #1a5fa0 !important;
	--wpforms-button-border-color: #1a5fa0 !important;
	--wpforms-button-text-color: #ffffff !important;
	--wpforms-button-border-radius: 8px !important;
	--wpforms-field-border-radius: 8px !important;
	--wpforms-field-border-color: #5f6c79 !important;
	--wpforms-field-text-color: #15202b !important;
	--wpforms-label-color: #15202b !important;
	--wpforms-label-sublabel-color: #4f5d6b !important;
	font-family: var(--rcs-font-sans);
	margin-bottom: 0;
	margin-top: 0;
}

body.rcs-ui .wpforms-container .wpforms-field-label,
body.rcs-ui .wpforms-container input,
body.rcs-ui .wpforms-container textarea,
body.rcs-ui .wpforms-container select,
body.rcs-ui .wpforms-container button {
	font-family: var(--rcs-font-sans) !important;
}

/* -------------------------------------------------------------------------- */
/*	Contact template
/* -------------------------------------------------------------------------- */

.rcs-contact {
	display: grid;
	gap: var(--rcs-space-7);
	grid-template-columns: minmax(0, 1fr);
}

.rcs-contact__heading {
	color: var(--rcs-color-heading);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-lg);
	font-weight: var(--rcs-weight-semibold);
	letter-spacing: 0;
	margin: 0 0 var(--rcs-space-3);
}

.rcs-contact__list {
	border-top: 1px solid var(--rcs-color-border);
	font-style: normal;
	list-style: none;
	margin: 0;
	padding: 0;
}

.rcs-contact__list li {
	border-bottom: 1px solid var(--rcs-color-border);
	margin: 0;
	padding: var(--rcs-space-4) 0;
}

.rcs-contact__term {
	color: var(--rcs-color-text-muted);
	display: block;
	font-size: var(--rcs-text-sm);
}

.rcs-contact__value {
	color: var(--rcs-grey-900);
	font-size: var(--rcs-text-lg);
	overflow-wrap: anywhere;
}

a.rcs-contact__value {
	color: var(--rcs-color-link);
}

.rcs-contact__form {
	background: var(--rcs-white);
	border: 1px solid var(--rcs-color-border);
	border-radius: var(--rcs-radius-lg);
	padding: var(--rcs-space-5);
}

/* Inside the form card the content column rules above do not apply. */
body.rcs-ui .rcs-contact__form.entry-content > * {
	max-width: none !important;
	width: 100% !important;
}

body.rcs-ui .rcs-contact__form.entry-content > :first-child {
	margin-top: 0;
}

body.rcs-ui .rcs-contact__form.entry-content > :last-child {
	margin-bottom: 0;
}

@media (min-width: 900px) {

	.rcs-contact--split {
		grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
	}

	.rcs-contact__form {
		padding: var(--rcs-space-6);
	}
}

/* -------------------------------------------------------------------------- */
/*	404 and search
/* -------------------------------------------------------------------------- */

body.rcs-ui .error404 #site-content,
body.rcs-ui.error404 #site-content {
	padding-top: var(--rcs-space-8);
}

body.rcs-ui.error404 .entry-title {
	font-family: var(--rcs-font-display);
	font-size: clamp(3rem, 2.2rem + 2vw, 4.4rem);
	font-weight: var(--rcs-weight-medium);
	letter-spacing: -0.02em;
}

body.rcs-ui.error404 .intro-text {
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-lg);
}

/* -------------------------------------------------------------------------- */
/*	FAQ accordion on the launch pages (Responsive Accordion plugin): colours only
/* -------------------------------------------------------------------------- */

/*
 * The plugin prints `#wpsm_accordion_N … !important` rules with the old theme's cream.
 * `:not(#rcs-x)` lifts these selectors to the same ID-level specificity so they win
 * without touching the plugin's saved settings.
 */
body.rcs-ui .wpsm_panel:not(#rcs-x) {
	background: var(--rcs-white) !important;
	border: 1px solid var(--rcs-color-border) !important;
	border-radius: var(--rcs-radius-md) !important;
	box-shadow: none !important;
	margin-bottom: var(--rcs-space-3) !important;
	overflow: hidden;
}

body.rcs-ui .wpsm_panel:not(#rcs-x) > .wpsm_panel-heading,
body.rcs-ui .wpsm_panel:not(#rcs-x) .acc-a,
body.rcs-ui .wpsm_panel:not(#rcs-x) .ac_open_cl_icon,
body.rcs-ui .wpsm_panel:not(#rcs-x) .ac_title_class {
	background-color: var(--rcs-white) !important;
	border-color: var(--rcs-white) !important;
	color: var(--rcs-blue-900) !important;
}

body.rcs-ui .wpsm_panel:not(#rcs-x) .wpsm_panel-title a {
	color: var(--rcs-blue-900) !important;
	font-family: var(--rcs-font-sans) !important;
	font-size: var(--rcs-text-base) !important;
	font-weight: var(--rcs-weight-semibold);
}

body.rcs-ui .wpsm_panel:not(#rcs-x) > .wpsm_panel-heading:hover,
body.rcs-ui .wpsm_panel:not(#rcs-x) > .wpsm_panel-heading:hover .acc-a,
body.rcs-ui .wpsm_panel:not(#rcs-x) > .wpsm_panel-heading:hover .ac_open_cl_icon,
body.rcs-ui .wpsm_panel:not(#rcs-x) > .wpsm_panel-heading:hover .ac_title_class {
	background-color: var(--rcs-blue-50) !important;
	border-color: var(--rcs-blue-50) !important;
}

body.rcs-ui .wpsm_panel:not(#rcs-x) .wpsm_panel-body {
	background-color: var(--rcs-white) !important;
	border: 0 !important;
	border-top: 1px solid var(--rcs-color-border) !important;
	color: var(--rcs-grey-900) !important;
	font-family: var(--rcs-font-sans) !important;
	font-size: var(--rcs-text-base) !important;
	line-height: var(--rcs-leading-body);
}

body.rcs-ui .wpsm_panel:not(#rcs-x) .wpsm_panel-body p,
body.rcs-ui .wpsm_panel:not(#rcs-x) .wpsm_panel-body li {
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-base);
}

/* -------------------------------------------------------------------------- */
/*	Collapsible sections (Details block) — e.g. "Application settings" on launch pages
/* -------------------------------------------------------------------------- */

body.rcs-ui .entry-content details {
	background: var(--rcs-white);
	border: 1px solid var(--rcs-color-border);
	border-radius: var(--rcs-radius-md);
	margin-bottom: var(--rcs-space-3);
	margin-top: 0;
	overflow: hidden;
}

body.rcs-ui .entry-content details > summary {
	color: var(--rcs-blue-900);
	cursor: pointer;
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-base);
	font-weight: var(--rcs-weight-semibold);
	padding: var(--rcs-space-4) var(--rcs-space-5);
}

body.rcs-ui .entry-content details > summary:hover {
	background: var(--rcs-blue-50);
}

body.rcs-ui .entry-content details > summary:focus-visible {
	box-shadow: inset 0 0 0 3px var(--rcs-color-focus);
	outline: 2px solid transparent;
}

body.rcs-ui .entry-content details[open] > summary {
	border-bottom: 1px solid var(--rcs-color-border);
}

body.rcs-ui .entry-content details > *:not(summary) {
	margin: var(--rcs-space-4) var(--rcs-space-5);
	max-width: none;
	width: auto;
}

/* -------------------------------------------------------------------------- */
/*	Tables: block tables and WP Data Access (DataTables) output
/* -------------------------------------------------------------------------- */

body.rcs-ui .entry-content .dataTables_wrapper,
body.rcs-ui .entry-content .wp-block-table {
	font-family: var(--rcs-font-sans);
	overflow-x: auto; /* wide tables scroll inside themselves, never the page */
}

body.rcs-ui .entry-content table {
	border: 1px solid var(--rcs-color-border);
	border-collapse: collapse;
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-sm);
	margin-bottom: var(--rcs-space-3);
	margin-top: 0;
}

body.rcs-ui .entry-content table th,
body.rcs-ui .entry-content table td {
	border: 1px solid var(--rcs-color-border);
	color: var(--rcs-grey-900);
	font-family: var(--rcs-font-sans);
	line-height: 1.45;
	padding: var(--rcs-space-2) var(--rcs-space-3);
	text-align: left;
	vertical-align: top;
}

body.rcs-ui .entry-content table thead th {
	background: var(--rcs-grey-100);
	border-bottom: 2px solid var(--rcs-color-border-strong);
	color: var(--rcs-blue-900);
	font-weight: var(--rcs-weight-semibold);
}

body.rcs-ui .entry-content table tfoot th {
	background: var(--rcs-white);
	color: var(--rcs-color-text-muted);
	font-weight: var(--rcs-weight-medium);
}

body.rcs-ui .entry-content table tbody tr:nth-child(even) td {
	background: var(--rcs-grey-50);
}

/* -------------------------------------------------------------------------- */
/*	WP Data Access tables (DataTables): the reference and settings tables on the
/*	application pages. Presentation only. Sorting, search, paging and responsive
/*	behaviour belong to the plugin and are untouched.
/* -------------------------------------------------------------------------- */

body.rcs-ui .wpda_publication_container {
	color: var(--rcs-grey-900);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-sm);
	margin-bottom: var(--rcs-space-5);
}

/* Inside a collapsible section, keep the table off the edges of the panel. */
body.rcs-ui .entry-content details > .wpda_publication_container {
	margin: var(--rcs-space-4) var(--rcs-space-5) !important;
}

/* One bordered card holding the controls, the table and the footer line. */
body.rcs-ui .wpda_publication_container .dataTables_wrapper {
	background: var(--rcs-white);
	border: 1px solid var(--rcs-color-border);
	border-radius: var(--rcs-radius-md);
	font-family: var(--rcs-font-sans);
	max-width: 100%;
	overflow-x: auto; /* a wide table scrolls inside its card, never the page */
	width: auto;
}

body.rcs-ui .wpda_publication_container .dataTables_wrapper::after {
	clear: both;
	content: "";
	display: block;
}

/* DataTables writes a pixel width measured while the section was still closed. */
body.rcs-ui .wpda_publication_container table.dataTable,
body.rcs-ui .wpda_publication_container .dataTables_scrollHeadInner,
body.rcs-ui .wpda_publication_container .dataTables_scrollHeadInner table {
	border: 0;
	margin: 0 !important;
	max-width: none;
	width: 100% !important;
}

body.rcs-ui .wpda_publication_container table.dataTable th,
body.rcs-ui .wpda_publication_container table.dataTable td {
	border: 0;
	border-bottom: 1px solid var(--rcs-color-border);
	color: var(--rcs-grey-900);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-sm);
	line-height: 1.45;
	padding: 1rem var(--rcs-space-4);
	text-align: left;
	vertical-align: top;
}

body.rcs-ui .wpda_publication_container table.dataTable thead th {
	background-color: var(--rcs-grey-100);
	border-bottom: 1px solid var(--rcs-color-border-strong);
	color: var(--rcs-blue-900);
	font-weight: var(--rcs-weight-semibold);
	white-space: nowrap;
}

/* Room for the sort arrows the plugin draws. */
body.rcs-ui .wpda_publication_container table.dataTable thead th.sorting,
body.rcs-ui .wpda_publication_container table.dataTable thead th.sorting_asc,
body.rcs-ui .wpda_publication_container table.dataTable thead th.sorting_desc {
	cursor: pointer;
	padding-right: 3rem;
}

body.rcs-ui .wpda_publication_container table.dataTable thead th:focus-visible {
	box-shadow: inset 0 0 0 3px var(--rcs-color-focus);
	outline: 2px solid transparent;
}

body.rcs-ui .wpda_publication_container table.dataTable tbody tr,
body.rcs-ui .wpda_publication_container table.dataTable.stripe tbody tr.even,
body.rcs-ui .wpda_publication_container table.dataTable tbody tr:nth-child(even) td {
	background-color: var(--rcs-white);
}

body.rcs-ui .wpda_publication_container table.dataTable.stripe tbody tr.odd,
body.rcs-ui .wpda_publication_container table.dataTable.stripe tbody tr.odd td {
	background-color: var(--rcs-grey-50);
}

body.rcs-ui .wpda_publication_container table.dataTable tbody tr:hover td {
	background-color: var(--rcs-blue-50);
}

body.rcs-ui .wpda_publication_container table.dataTable tbody tr:last-child td {
	border-bottom: 0;
}

/*
 * Numeric columns (the plugin adds this class to header and cells): equal-width digits, but
 * left-aligned. These tables stretch to the card, and right-aligned numbers end up far from
 * their heading.
 */
body.rcs-ui .wpda_publication_container table.dataTable .wpda_format_number {
	font-variant-numeric: tabular-nums;
	text-align: left;
}

/*
 * The plugin repeats the header row as a table footer. It is only useful when per-column
 * search boxes are switched on, so hide it unless it holds a form control.
 */
body.rcs-ui .wpda_publication_container table.dataTable tfoot:not(:has(input, select)),
body.rcs-ui .wpda_publication_container .dataTables_scrollFoot:not(:has(input, select)) {
	display: none;
}

/* Controls above the table. */
body.rcs-ui .wpda_publication_container .dataTables_length,
body.rcs-ui .wpda_publication_container .dataTables_filter {
	color: var(--rcs-color-text-muted);
	font-size: var(--rcs-text-xs);
	margin: 0;
	padding: var(--rcs-space-3) var(--rcs-space-4);
}

body.rcs-ui .wpda_publication_container .dataTables_wrapper label {
	color: var(--rcs-color-text-muted);
	font-size: var(--rcs-text-xs);
	font-weight: var(--rcs-weight-medium);
	margin: 0;
}

body.rcs-ui #site-content .wpda_publication_container .dataTables_filter input,
body.rcs-ui #site-content .wpda_publication_container .dataTables_length select {
	border: 1px solid var(--rcs-grey-500);
	border-radius: var(--rcs-radius-sm);
	display: inline-block;
	font-size: var(--rcs-text-sm);
	margin: 0 0 0 var(--rcs-space-2);
	max-width: 22rem;
	padding: 0.5rem 1rem;
	width: auto;
}

body.rcs-ui #site-content .wpda_publication_container .dataTables_length select {
	margin: 0 var(--rcs-space-1);
	padding-right: 2.4rem;
}

/* The table starts under the controls with a rule of its own. */
body.rcs-ui .wpda_publication_container .dataTables_wrapper > table.dataTable,
body.rcs-ui .wpda_publication_container .dataTables_wrapper > .dataTables_scroll {
	border-top: 1px solid var(--rcs-color-border);
	clear: both;
}

/* Footer line: "Showing 1 to 6 of 6 entries" and the pager. */
body.rcs-ui .wpda_publication_container .dataTables_info,
body.rcs-ui .wpda_publication_container .dataTables_paginate {
	color: var(--rcs-color-text-muted);
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-xs);
	margin: 0;
	padding: var(--rcs-space-3) var(--rcs-space-4);
}

body.rcs-ui .wpda_publication_container .dataTables_info {
	border-top: 1px solid var(--rcs-color-border);
	float: none;
}

body.rcs-ui .wpda_publication_container .dataTables_paginate {
	padding-top: 0;
}

/* A pager with a single page is noise. */
body.rcs-ui .wpda_publication_container .dataTables_paginate:not(:has(span .paginate_button + .paginate_button)) {
	display: none;
}

/* The DataTables sheet shipped with the plugin sets gradients with !important. */
body.rcs-ui .wpda_publication_container .dataTables_paginate .paginate_button {
	background: none !important;
	border: 1px solid transparent !important;
	border-radius: var(--rcs-radius-sm);
	box-shadow: none !important;
	color: var(--rcs-grey-700) !important;
	font-size: var(--rcs-text-xs);
	margin-left: 0.2rem;
	padding: 0.4rem 1rem;
}

body.rcs-ui .wpda_publication_container .dataTables_paginate .paginate_button:hover {
	background: var(--rcs-blue-50) !important;
	border-color: var(--rcs-blue-200) !important;
	color: var(--rcs-blue-800) !important;
}

body.rcs-ui .wpda_publication_container .dataTables_paginate .paginate_button.current,
body.rcs-ui .wpda_publication_container .dataTables_paginate .paginate_button.current:hover {
	background: var(--rcs-white) !important;
	border-color: var(--rcs-color-border-strong) !important;
	color: var(--rcs-blue-900) !important;
	font-weight: var(--rcs-weight-semibold);
}

body.rcs-ui .wpda_publication_container .dataTables_paginate .paginate_button.disabled,
body.rcs-ui .wpda_publication_container .dataTables_paginate .paginate_button.disabled:hover {
	background: none !important;
	border-color: transparent !important;
	color: var(--rcs-grey-500) !important;
	cursor: default;
	opacity: 0.55;
}

body.rcs-ui .wpda_publication_container .dataTables_empty {
	color: var(--rcs-color-text-muted);
	padding: var(--rcs-space-5) !important;
	text-align: center !important;
}

@media (max-width: 600px) {

	body.rcs-ui .entry-content details > .wpda_publication_container {
		margin: var(--rcs-space-3) !important;
	}

	body.rcs-ui .wpda_publication_container .dataTables_length,
	body.rcs-ui .wpda_publication_container .dataTables_filter,
	body.rcs-ui .wpda_publication_container .dataTables_paginate {
		float: none;
		text-align: left;
	}

	body.rcs-ui .wpda_publication_container table.dataTable th,
	body.rcs-ui .wpda_publication_container table.dataTable td {
		padding: 0.8rem var(--rcs-space-3);
	}
}

/* -------------------------------------------------------------------------- */
/*	Editor block styles used on the About page (selectable in the block editor)
/* -------------------------------------------------------------------------- */

/* Lead paragraph: "Large" font size preset on a paragraph. */
body.rcs-ui .entry-content p.is-style-rcs-lead {
	color: var(--rcs-blue-900);
	font-size: var(--rcs-text-xl);
	line-height: 1.45;
	max-width: 64ch;
}

/* List → Steps: a genuine sequence, so it is numbered. */
body.rcs-ui .entry-content ol.is-style-rcs-steps {
	border-top: 1px solid var(--rcs-color-border);
	counter-reset: rcs-step;
	list-style: none;
	margin-left: auto;
	padding: 0;
}

body.rcs-ui .entry-content ol.is-style-rcs-steps > li {
	border-bottom: 1px solid var(--rcs-color-border);
	counter-increment: rcs-step;
	margin: 0;
	min-height: 6.4rem;
	padding: var(--rcs-space-4) 0 var(--rcs-space-4) 6.4rem;
	position: relative;
}

body.rcs-ui .entry-content ol.is-style-rcs-steps > li::before {
	color: var(--rcs-blue-600);
	content: counter(rcs-step);
	font-family: var(--rcs-font-display);
	font-size: var(--rcs-text-2xl);
	font-weight: var(--rcs-weight-medium);
	left: 0.4rem;
	line-height: 1;
	position: absolute;
	top: var(--rcs-space-4);
}

body.rcs-ui .entry-content ol.is-style-rcs-steps > li strong {
	color: var(--rcs-blue-900);
	display: block;
	font-weight: var(--rcs-weight-semibold);
}

/* List → Checks. */
body.rcs-ui .entry-content ul.is-style-rcs-checks {
	list-style: none;
	margin-left: auto;
	padding: 0;
}

body.rcs-ui .entry-content ul.is-style-rcs-checks > li {
	margin: 0 0 var(--rcs-space-2);
	padding-left: 3rem;
	position: relative;
}

body.rcs-ui .entry-content ul.is-style-rcs-checks > li::before {
	border-bottom: 2px solid var(--rcs-blue-600);
	border-right: 2px solid var(--rcs-blue-600);
	content: "";
	height: 1.1rem;
	left: 0.5rem;
	position: absolute;
	top: 0.6rem;
	transform: rotate(45deg);
	width: 0.6rem;
}

/* Media & Text → Application: image beside the description, one bordered panel each. */
body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app {
	align-items: start;
	border: 1px solid var(--rcs-color-border);
	border-radius: var(--rcs-radius-lg);
	gap: 0;
	grid-template-columns: minmax(0, 32%) minmax(0, 1fr);
	margin-bottom: var(--rcs-space-5);
	margin-top: 0;
	overflow: hidden;
}

body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app .wp-block-media-text__media {
	align-self: stretch;
	background: var(--rcs-blue-50);
	margin: 0;
	min-height: 24rem;
	position: relative;
}

/* Fill the whole column, however tall the text beside it grows. */
body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app .wp-block-media-text__media img {
	display: block;
	height: 100%;
	inset: 0;
	max-width: none;
	object-fit: cover;
	position: absolute;
	width: 100%;
}

body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app .wp-block-media-text__content {
	padding: var(--rcs-space-5);
}

body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app .wp-block-media-text__content > * {
	margin-left: 0;
	margin-right: 0;
	max-width: none;
	width: auto;
}

body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app h3 {
	font-family: var(--rcs-font-sans);
	font-size: var(--rcs-text-xl);
	font-weight: var(--rcs-weight-semibold);
	margin: 0 0 var(--rcs-space-3);
}

body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app li,
body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app p {
	font-size: var(--rcs-text-sm);
}

@media (max-width: 700px) {

	body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app {
		grid-template-columns: minmax(0, 1fr);
	}

	body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app .wp-block-media-text__media {
		min-height: 20rem;
	}

	body.rcs-ui .entry-content .wp-block-media-text.is-style-rcs-app .wp-block-media-text__content {
		grid-column: 1;
		grid-row: 2;
	}
}

/* Group → Panel: a tinted box for a short, self-contained statement. */
body.rcs-ui .entry-content .wp-block-group.is-style-rcs-panel {
	background: var(--rcs-color-bg-tint);
	border: 1px solid var(--rcs-color-border);
	border-radius: var(--rcs-radius-lg);
	padding: var(--rcs-space-5);
}

body.rcs-ui .entry-content .wp-block-group.is-style-rcs-panel > * {
	margin-left: 0;
	margin-right: 0;
	max-width: none;
	width: auto;
}

body.rcs-ui .entry-content .wp-block-group.is-style-rcs-panel > :first-child {
	margin-top: 0;
}

body.rcs-ui .entry-content .wp-block-group.is-style-rcs-panel > :last-child {
	margin-bottom: 0;
}
