/**
 * Base
 *
 * Loads on every page. Sections were separate files until the
 * October 2026 merge; their old names are kept in the section headers.
 */


/* ==========================================================================
   Reset
   ========================================================================== */

/* --- Reset --- */

/*
 * Use a more-intuitive box-sizing model.
 */
*,
*::before,
*::after {
	box-sizing: border-box;
}

/*
 * Improve text rendering
 */
body {
	-webkit-font-smoothing: antialiased;
}

/*
 * Improve media defaults
 */
img,
picture,
video,
canvas,
svg {
	display: block;
	height: auto;
	max-width: 100%;
}

/*
 * Remove built-in form typography styles
 */
input,
button,
textarea,
select {
	font: inherit;
}


/*
 * Visible, consistent keyboard focus (WCAG 2.4.7) in every browser and
 * scheme. The ring is drawn just outside the element, on the surface
 * around it, so it uses that surface's text color (--ring, set where each
 * surface paints its scheme below). A button carrying its own scheme, like
 * Give Now in the header, still gets the header's ring color. Zero
 * specificity: components can restyle it, but shouldn't remove it.
 */
:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
	outline:        2px solid var(--ring, currentColor);
	outline-offset: 2px;
}


/* ==========================================================================
   Layout
   ========================================================================== */

@media (prefers-reduced-motion: no-preference) {
	html {
		scroll-behavior: smooth;
	}
}

:where(.wp-site-blocks) {
	display:        flex;
	flex-direction: column;
	min-height:     100dvh;

	& > * {
		margin-block-start: 0 !important;
	}

	> main {
		flex-grow: 1;
	}
}

:is(main, div:where(.wp-block-post-content.is-root-container)):has(> :first-child:not(header, .alignfull)) {
	padding-block-start: var(--wp--custom--spacing--xx-large);
}

:is(main, div:where(.wp-block-post-content.is-root-container)):has(> :last-child:not(footer, .alignfull)) {
	padding-block-end: var(--wp--custom--spacing--xx-large);
}

/* 
:where(.wp-block-columns) {
	gap: var(--wp--custom--root--block-gap);
}
 */

:where(.wp-block-separator) {
	margin-block: var(--wp--custom--spacing--x-large);
	border-block-start-color: var(--border);
	border-block-start-style: solid;
	border-block-start-width: 1px;
}

:where(.wp-block-details) summary {
	list-style: none;
}

/* Safari before 18.4 ignores list-style on summary and draws its own
   triangle next to the theme's chevron; hide it everywhere. */
summary::-webkit-details-marker {
	display: none;
}

/**
 * Full-width sections
 */
:is(header, footer, section, aside).alignfull {
	--global-padding-inline: max(
		var(--wp--custom--root--padding-inline),
		var(--wp--custom--layout--wide-gutter)
	);
	margin-block-start: 0;
	padding-inline:     var(--global-padding-inline);

	/* Remove inline padding from nested full-width section */
	.alignfull {
		padding-inline: unset;
	}
}

:is(main, div:where(.wp-block-post-content.is-root-container)) > :is(header, footer, section, aside) {
	padding-block: var(--wp--custom--spacing--large);

	@media all and (min-width: 40rem) {
		padding-block: var(--wp--custom--spacing--x-large);

		:is(.page-type-action, .single-post, .post-type-post, .single-event, .single-job) & {
			padding-block-end: var(--wp--custom--spacing--medium);
		}
	}
}


/* ==========================================================================
   Schemes
   ==========================================================================
 *
 * A scheme sets five colors; components only ever read them:
 *
 *   --bg        background
 *   --fg        text
 *   --bg-hover  hover fill (outline buttons); text on it uses --bg
 *   --fg-hover  hover color for links, cards and menu items
 *   --border    borders and dividers
 *
 * The default scheme is set on :root, so everything inherits a full set,
 * and a nested scheme only has to restate its own five. Components never
 * redefine these; they set their own backgrounds with :where() so a
 * scheme class on the same element always wins.
 */

body {
	background-color: var(--bg);
	color: var(--fg);
}

:root,
.has-default-scheme {
	--bg:       var(--wp--custom--color--background);
	--fg:       var(--wp--custom--color--text);
	--bg-hover: var(--wp--custom--color--brand--dark);
	--fg-hover: var(--wp--custom--color--link-hover);
	--border:   var(--wp--custom--color--border);
}

html, 
body,
.has-very-light-scheme,
header.wp-block-template-part,
:where(.wp-block-group).is-style-fill:not([class*="-scheme"]) {
	--bg:       var(--wp--custom--color--brand--very-light);
	--fg:       var(--wp--custom--color--text);
	--bg-hover: var(--wp--custom--color--brand--dark);
	--fg-hover: var(--wp--custom--color--brand--dark);
	--border:   var(--wp--custom--color--brand--light);
}

.has-light-scheme,
body:is(.page, .post-type-page, .blog, .archive) :is(.page-header.alignfull, .site-breadcrumbs) {
	--bg:       var(--wp--custom--color--brand--light);
	--fg:       var(--wp--custom--color--brand--very-dark);
	--bg-hover: var(--wp--custom--color--brand--very-dark);
	--fg-hover: var(--wp--custom--color--brand--dark);
	--border:   var(--wp--custom--color--brand--base);
}

.has-brand-scheme {
	--bg:       var(--wp--custom--color--brand--base);
	--fg:       var(--wp--custom--color--text-inverse);
	--bg-hover: var(--wp--custom--color--background);
	--fg-hover: var(--wp--custom--color--brand--very-light);
	--border:   var(--wp--custom--color--brand--dark);
}

.has-dark-scheme {
	--bg:       var(--wp--custom--color--brand--dark);
	--fg:       var(--wp--custom--color--text-inverse);
	--bg-hover: var(--wp--custom--color--brand--very-light);
	--fg-hover: var(--wp--custom--color--brand--light);
	--border:   var(--wp--custom--color--brand--base);
}

.has-very-dark-scheme,
body:is(.page.home) :is(.page-header.alignfull, .site-breadcrumbs) {
	--bg:       var(--wp--custom--color--brand--very-dark);
	--fg:       var(--wp--custom--color--text-inverse);
	--bg-hover: var(--wp--custom--color--brand--very-light);
	--fg-hover: var(--wp--custom--color--brand--light);
	--border:   var(--wp--custom--color--brand--dark);
}

/* Anything carrying a scheme paints it */
:is(header, footer, section, aside).wp-block-template-part,
[class*="-scheme"],
:where(.wp-block-group).is-style-fill,
:is(.page-header, .site-breadcrumbs) {
	background-color: var(--bg);
	color:            var(--fg);
}

/* Focus ring color for each surface (see the focus rule in Reset). Buttons
   and menu items carrying their own scheme don't reset it, so their ring
   keeps the color of the surface they sit on. */
:root,
:is(header, footer, section, aside).wp-block-template-part,
[class*="-scheme"]:not(.wp-block-button, .wp-block-navigation-item, .wp-block-navigation-submenu),
:where(.wp-block-group).is-style-fill,
:is(.page-header, .site-breadcrumbs) {
	--ring: var(--fg);
}

/* Text links in dark and colored schemes use the scheme's text color; the
   site link color (dark green) doesn't contrast with them (WCAG 1.4.3).
   Links stay underlined, so they're still distinguishable. */
:is(.has-brand-scheme, .has-dark-scheme, .has-very-dark-scheme, .has-give-scheme) a:where(:not(.wp-element-button)) {
	color: var(--fg);

	&:hover {
		color: var(--fg-hover);
	}
}


/* ==========================================================================
   Box
   ==========================================================================
 *
 * Shared by any group styled as a box (Fill, Outline, or a scheme) —
 * cards, features, and plain groups alike. One padding variable,
 * --box-padding, set with :where() so components and modifiers override it.
 */

:where(.wp-block-group:is(.is-style-fill, .is-style-outline, [class*="-scheme"])) {
	--box-padding: var(--wp--custom--spacing--medium);
}

:where(.wp-block-group).is-style-fill:not(.card, .feature, .is-feature) {
	padding: var(--box-padding);
}

:where(.wp-block-group).is-style-outline {
	border: 1px solid var(--border);
}

/* Tag or label pulled above the heading in any box */
:where(.wp-block-group):is(.card, .feature, .is-feature) :is(.is-label, .is-tag):first-of-type {
	order: -1;
}


/* ==========================================================================
   Typography
   ========================================================================== */

/* --- Typography & Links --- */

strong, b {
	font-weight: 700;
}

/* Core makes Post Title links inline-blocks, which wraps an icon after the
   title onto its own line. Inline keeps it with the last word. */
.wp-block-post-title a {
	display: inline;
}

/**
 * Link styles
 * Consistent underline treatment across all link types
 */
a,
:is(.wp-block-site-title, .wp-block-post-title) a {
	text-decoration:           var(--wp--custom--root--text-decoration);
	text-decoration-thickness: var(--wp--custom--root--thickness);
	text-underline-offset:     var(--wp--custom--root--underline-offset);
	text-decoration-skip-ink:  none;

	@media (hover: hover) {
		&:hover {
			text-decoration-thickness: var(--wp--custom--root--thickness-hover);
		}
	}
}

.wp-block-site-title a {
	color: inherit;
}

/*
@reference https://carbondesignsystem.com/elements/typography/
16/20 1.25
19/25 1.3157894737
24/30 1.25
36/40 1.1111111111
48/50 1.04166666667
*/

:where(main, .wp-block-post-content.is-root-container) :is(h1, h2) {
	letter-spacing: -0.01em;
}

/* Set line height for headings */
h1 {
	line-height: var(--wp--custom--line-height--xx-large);
}

h2 {
	line-height: var(--wp--custom--line-height--x-large);
}

h3 {
	line-height: var(--wp--custom--line-height--large);
}


/* Modify line height when preset font size is selected */
:is(
	.wp-block-paragraph,
	.wp-block-heading,
	.wp-block-quote
) {
	&.has-small-font-size {
		line-height: var(--wp--custom--line-height--small);
	}
	&.has-medium-font-size {
		line-height: var(--wp--custom--line-height--medium);
	}
	&.has-large-font-size {
		line-height: var(--wp--custom-line-height--large);
	}
	&.has-x-large-font-size {
		line-height: var(--wp--custom--line-height--x-large);
	}
	&.has-xx-large-font-size {
		line-height: var(--wp--custom--line-height--xx-large);
	}
}

.wp-block-post-excerpt.has-x-large-font-size .wp-block-post-excerpt__excerpt {
	line-height: var(--wp--custom--line-height--x-large);
}

:is(.is-layout-flow) h4 + * {
	margin-block-start: var(--wp--custom--spacing--x-small);
}


:is(main, div:where(.wp-block-post-content.is-root-container)) .is-layout-constrained > h3 + * {
	margin-block-start: var(--wp--custom--spacing--x-small);
}


/**
 * Display modifier function
 */
:where(.is-display) {
	--display-base:       1em;
	--display-multiplier: 1;
}

:is(.wp-block-paragraph, .wp-block-heading).is-display {
	font-size: min(
		calc((var(--display-base) * 1.25) * var(--display-multiplier)),
		var(--wp--custom--font-size--xx-large)
	) !important;

	&.has-small-font-size {
		--display-base: var(--wp--custom--font-size--small);
	}
	&.has-medium-font-size {
		--display-base: var(--wp--custom--font-size--medium);
	}
	&.has-large-font-size {
		--display-base: var(--wp--custom--font-size--large);
	}
	&.has-x-large-font-size {
		--display-base: var(--wp--custom--font-size--x-large);
	}
}


/**
 * Caption
 */
.wp-element-caption {
	color: var(--wp--custom--color--gray--base);
}

/**
 * Quote
 */
.wp-block-quote {
	& cite {
		font-size:          var(--wp--custom--font-size--small);
		margin-block-start: var(--wp--custom--spacing--x-large);
	}
}

.wp-block-heading.is-section-heading {
	margin-block-start:  var(--wp--custom--spacing--xx-large);
	margin-block-end:    var(--wp--custom--spacing--large);
	padding-block-start: var(--wp--custom--spacing--small);
	border-top:          calc(var(--wp--custom--root--thickness-hover)/2) solid currentColor;

	:is(section.alignfull, .wp-block-column) > &:first-child {
		margin-block-start: 0;
	}
}

.is-subsection-heading {
	margin-block-start:  var(--wp--custom--spacing--large);
	margin-block-end:    var(--wp--custom--spacing--medium);
	padding-block-start: var(--wp--custom--spacing--x-small);
	border-top:          1px solid currentColor;
	font-size:           var(--wp--custom--font-size--small);
	font-weight:         normal;
	text-transform:      uppercase;
	letter-spacing:      0.025em;
}

.is-section-label,
.is-kicker,
.wp-block-heading.is-style-label {
	font-size:      var(--wp--custom--font-size--medium);
	font-weight:    400;
	text-transform: uppercase;
	letter-spacing: 0.0125em;
	line-height: 1;
}

.is-tag,
.is-breadcrumbs, .breadcrumbs, .breadcrumb {
	font-size:      var(--wp--custom--font-size--small);
	font-weight:    600;
	text-transform: uppercase;
	letter-spacing: 0.0125em;
	line-height: 1.05;

	& a {
		color: inherit;
	}
}

.has-separator-before {
	padding-block-start: var(--wp--custom--spacing--medium);
	border-block-start:  1px solid var(--border);
	margin-block-start:  var(--wp--custom--spacing--large);
	margin-block-end:    var(--wp--custom--spacing--large);
}

.has-separator-after {
	padding-block-end: var(--wp--custom--spacing--medium);
	border-block-end:  1px solid var(--border);
	margin-block-start:  var(--wp--custom--spacing--large);
	margin-block-end:    var(--wp--custom--spacing--large);
}

.has-divider-before {
	padding-block-start: var(--wp--custom--root--block-gap);
	border-block-start:  var(--wp--custom--root--thickness-hover) solid currentColor;
	margin-block-start:  var(--wp--custom--spacing--large);
}

.has-divider-after {
	padding-block-end: var(--wp--custom--root--thickness-hover);
	border-block-end:  var(--wp--custom--root--thickness-hover) solid currentColor;
	margin-block-end:  var(--wp--custom--root--block-gap);
}

.is-jumbo {
	font-size: clamp(2.25rem, 1.125rem + 5.625vw, 4.5rem);
}

:is(.wp-block-heading, .wp-block-post-title).has-x-large-font-size {
	letter-spacing: -0.025em;
}


/* ==========================================================================
   Post Meta
   ========================================================================== */

/**
 * Post metadata
 * Adds labels and consistent styling to post meta elements
 */
.meta .wp-block-post-date:before {
	content: "Published";
}

.meta .wp-block-post-date.wp-block-post-date__modified-date:before {
	content: "Updated";
}

.meta .wp-block-post-date:before,
.meta .wp-block-post-author__byline,
.meta .wp-block-post-terms__prefix {
	display:     block;
	font-size:   var(--wp--custom--font-size--small);
	line-height: var(--wp--custom--line-height--small);
}

.meta .wp-block-post-date a,
.meta .wp-block-post-author a,
.meta .wp-block-post-terms a {
	color: inherit;
}


/* ==========================================================================
   Forms
   ========================================================================== */

form {
	* + * {
		margin-block-start: var(--wp--custom--spacing--x-small);
	}

	& input + :is(label, [type="submit"]) {
		margin-block-start: var(--wp--custom--spacing--medium);
	}

	:is(label, input, button, select) {
		display: block;
	}

	& label {
		font-weight: 600;
	}

	& input,
	& select {
		padding: var(--wp--custom--spacing--medium);
		inline-size: 100%;
		max-inline-size: var(--wp--style--global--content-size);
		border: 1px solid var(--wp--custom--color--border);
	}

	& label > input[type="checkbox"] {
		display: inline;
		inline-size: auto;
	}

	& select {
		border-radius: 0;
		-webkit-appearance: none;
	}

	:is(button, input)[type="submit"] {
		-webkit-appearance: none;

		padding-block: var(--wp--custom--button--padding-block);
		padding-inline: var(--wp--custom--button--padding-inline);
		border: none;
		font-weight: var(--wp--custom--button--font-weight);
		background-color: var(--wp--custom--color--link);
		color: var(--wp--custom--color--text-inverse);
		cursor: pointer;

		@media (hover: hover) {
			&:hover {
				background-color: var(--wp--custom--color--link-hover);
			}
		}
	}
}

/* Blocks */

.wp-block-query-pagination {
	gap:       0.375em;
	flex-wrap: wrap;

	&.is-layout-flex {
		gap: 0.375em;
	}

	:is(a, span) {
		--bg: var(--wp--custom--color--brand--very-light);
		--bg-hover: var(--wp--custom--color--brand--light);
		--fg: var(--wp--custom--color--link);
		--fg-hover: var(--wp--custom--color--link-hover);
		display: inline-block;
		padding-block: var(--wp--custom--button--padding-block);
		padding-inline: var(--wp--custom--button--padding-block);
		background-color: var(--bg);
		color: var(--fg);
		font-weight: var(--wp--custom--button--font-weight);
		line-height: 1;
		
	}

	& a:hover {
		background-color: var(--bg-hover);
		color: var(--fg-hover);
	}

	.wp-block-query-pagination-numbers { /* div */
		display: contents;	
	}
	:is(.wp-block-query-pagination-next,.wp-block-query-pagination-previous) { /* <a> */



		margin-inline: unset !important;
		text-decoration: unset;
	}
}

.wp-block-search__input {
	max-inline-size: 100%;
}

/* No "read more" link on excerpts */
.wp-block-post-excerpt__more-text,
.wp-block-post-excerpt__more-link {
	display: none;
}