/* ==========================================================================
   Theme styles, loaded after UIkit.
   Colors and fonts are set in config.php and written to :root as --cc-* variables.
   ========================================================================== */

:root {
	--cc-radius: 4px;
	--cc-header-height: 76px;
}

/* --------------------------------------------------------------------------
   Base
   -------------------------------------------------------------------------- */

html {
	font-family: var(--cc-font-body);
	font-size: 18px;
	line-height: 1.6;
	color: var(--cc-ink);
	scroll-padding-top: calc(var(--cc-header-height) + 16px);
}

body {
	background: var(--cc-white);
	color: var(--cc-ink);
}

h1, h2, h3, h4, h5, h6,
.uk-h1, .uk-h2, .uk-h3, .uk-h4, .uk-h5, .uk-h6,
.uk-heading-small {
	font-family: var(--cc-font-display);
	font-weight: 700;
	line-height: 1.1;
	color: var(--cc-primary-900);
}

h3, h4, h5, h6 {
	font-weight: 600;
}

a {
	color: var(--cc-primary-600);
}

a:hover {
	color: var(--cc-primary-900);
}

:focus-visible {
	outline: 3px solid var(--cc-primary-600);
	outline-offset: 2px;
}

.uk-light :focus-visible,
.cc-header :focus-visible {
	outline-color: var(--cc-accent);
}

.uk-section-muted,
.cc-bg-surface {
	background: var(--cc-surface);
}

.cc-skip-link {
	position: absolute;
	top: -100px;
	left: 16px;
	z-index: 1100;
	padding: 10px 16px;
	background: var(--cc-accent);
	color: var(--cc-primary-900);
	font-weight: 600;
}

.cc-skip-link:focus {
	top: 8px;
	color: var(--cc-primary-900);
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.uk-button {
	border-radius: var(--cc-radius);
	font-family: var(--cc-font-display);
	font-size: 1.05rem;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.uk-button-large {
	font-size: 1.15rem;
}

.uk-button-primary,
.uk-light .uk-button-primary {
	background: var(--cc-accent);
	border: 1px solid transparent;
	color: var(--cc-primary-900);
}

.uk-button-primary:hover,
.uk-button-primary:focus,
.uk-light .uk-button-primary:hover,
.uk-light .uk-button-primary:focus {
	background: var(--cc-accent-hover);
	color: var(--cc-primary-900);
}

.uk-button.cc-button-ghost,
.uk-light .uk-button.cc-button-ghost {
	background: transparent;
	border: 1px solid rgba(255, 255, 255, 0.5);
	color: var(--cc-white);
}

.uk-button.cc-button-ghost:hover,
.uk-light .uk-button.cc-button-ghost:hover {
	border-color: var(--cc-white);
	background: rgba(255, 255, 255, 0.1);
	color: var(--cc-white);
}

/* --------------------------------------------------------------------------
   Header and navigation
   -------------------------------------------------------------------------- */

.cc-navbar.uk-navbar-container:not(.uk-navbar-transparent) {
	background: var(--cc-primary-900);
}

.cc-header--stuck .cc-navbar {
	box-shadow: 0 2px 14px rgba(0, 0, 0, 0.28);
}

.cc-logo,
.cc-logo:hover,
.uk-light .uk-logo,
.uk-light .uk-logo:hover {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	color: var(--cc-white);
	font-family: var(--cc-font-display);
	font-size: 1.5rem;
	font-weight: 700;
	letter-spacing: 0.01em;
	text-decoration: none;
}

.cc-logo-mark {
	flex: none;
}

.cc-navbar .uk-navbar-item,
.cc-navbar .uk-navbar-nav > li > a,
.cc-navbar .uk-navbar-toggle {
	min-height: var(--cc-header-height);
}

.cc-navbar .uk-navbar-nav {
	gap: 8px;
}

.cc-navbar .uk-navbar-nav > li > a {
	padding: 0 12px;
	color: var(--cc-on-dark);
	font-family: var(--cc-font-body);
	font-size: 1rem;
	font-weight: 500;
	text-transform: none;
}

.cc-navbar .uk-navbar-nav > li > a:hover {
	color: var(--cc-white);
}

.cc-navbar .uk-navbar-nav > li.uk-active > a {
	color: var(--cc-white);
	box-shadow: inset 0 -3px 0 var(--cc-accent);
}

.cc-navbar .uk-navbar-toggle,
.cc-navbar .uk-navbar-toggle:hover {
	color: var(--cc-white);
}

#mobile-nav .uk-offcanvas-bar {
	background: var(--cc-primary-900);
}

#mobile-nav .uk-nav-default > li > a {
	color: var(--cc-on-dark);
	font-family: var(--cc-font-display);
	font-weight: 600;
}

#mobile-nav .uk-nav-default > li.uk-active > a {
	color: var(--cc-accent);
}

/* --------------------------------------------------------------------------
   Home page hero
   -------------------------------------------------------------------------- */

.cc-hero {
	position: relative;
	overflow: hidden;
	padding: clamp(64px, 11vw, 136px) 0 clamp(112px, 15vw, 208px);
	background: var(--cc-primary-900);
	/* Faint contour lines, like a topographic map */
	background-image:
		repeating-radial-gradient(
			circle at 82% 8%,
			transparent 0 46px,
			rgba(255, 255, 255, 0.045) 46px 47px
		);
}

.cc-hero__inner {
	position: relative;
	z-index: 1;
	max-width: 880px;
}

.cc-eyebrow {
	margin: 0 0 18px;
	color: var(--cc-accent);
	font-family: var(--cc-font-display);
	font-size: 1.05rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.uk-light .cc-eyebrow {
	color: var(--cc-accent);
}

.cc-hero__title {
	margin: 0;
	font-size: clamp(2.6rem, 6.4vw, 5rem);
	line-height: 1.02;
	letter-spacing: -0.005em;
}

.cc-hero__lead {
	max-width: 640px;
	margin: 24px 0 0;
	color: var(--cc-on-dark);
	font-size: 1.25rem;
}

.cc-hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
}

.cc-hero__actions:has(a) {
	margin-top: 36px;
}

.cc-hero__peaks {
	position: absolute;
	right: 0;
	bottom: -1px;
	left: 0;
	display: block;
	width: 100%;
	height: clamp(64px, 10vw, 140px);
	color: var(--cc-white);
}

/* --------------------------------------------------------------------------
   Long-form page content (editor and CSV content)
   -------------------------------------------------------------------------- */

/* Imported content brings its own wrappers. Stop them adding extra spacing. */
.cc-prose .uk-section,
.entry-content .uk-section {
	padding: 0;
}

.cc-prose .uk-container,
.entry-content .uk-container {
	max-width: none;
	padding: 0;
}

.cc-prose h2,
.entry-content h2 {
	position: relative;
	margin: 2.6em 0 0.6em;
	padding-top: 26px;
	font-size: clamp(2rem, 4vw, 2.75rem);
}

/* A small peak above each heading */
.cc-prose h2::before,
.entry-content h2::before {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	width: 30px;
	height: 16px;
	background: var(--cc-primary-600);
	clip-path: polygon(0 100%, 36% 0, 58% 52%, 72% 28%, 100% 100%);
}

.cc-prose .uk-container > h2:first-child,
.cc-prose > h2:first-child,
.entry-content > h2:first-child {
	margin-top: 0;
}

.cc-prose h3,
.entry-content h3 {
	margin: 1.7em 0 0.35em;
	font-size: 1.55rem;
}

.cc-prose p,
.cc-prose ul,
.cc-prose ol,
.entry-content p,
.entry-content ul,
.entry-content ol {
	max-width: 70ch;
}

.cc-prose ul,
.entry-content ul,
.cc-checklist ul {
	margin: 0 0 1.25em;
	padding: 0;
	list-style: none;
}

.cc-prose ul > li,
.entry-content ul > li,
.cc-checklist ul > li {
	position: relative;
	margin-top: 0.45em;
	padding-left: 1.75em;
}

.cc-prose ul > li::before,
.entry-content ul > li::before,
.cc-checklist ul > li::before {
	content: "";
	position: absolute;
	top: 0.34em;
	left: 0;
	width: 1.05em;
	height: 1.05em;
	background: var(--cc-primary-600);
	-webkit-mask: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M3.5 10.5l4.2 4.2L16.5 5.5' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
	mask: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M3.5 10.5l4.2 4.2L16.5 5.5' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}

/* --------------------------------------------------------------------------
   Designed page sections
   -------------------------------------------------------------------------- */

.cc-section {
	padding-top: clamp(56px, 8vw, 104px);
	padding-bottom: clamp(56px, 8vw, 104px);
}

.cc-section__header {
	max-width: 720px;
	margin-bottom: 48px;
}

.cc-section__title {
	margin: 0 0 16px;
	font-size: clamp(2.1rem, 4.4vw, 3.1rem);
}

.cc-section__intro {
	color: var(--cc-muted);
	font-size: 1.1rem;
}

.cc-section__intro > :last-child {
	margin-bottom: 0;
}

.cc-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 52px;
	height: 52px;
	margin-bottom: 18px;
	border-radius: var(--cc-radius);
	background: var(--cc-primary-800);
	color: var(--cc-accent);
}

/* Cards */
.cc-card {
	height: 100%;
	box-sizing: border-box;
	padding: 28px;
	border: 1px solid var(--cc-line);
	border-top: 4px solid var(--cc-primary-600);
	border-radius: var(--cc-radius);
	background: var(--cc-white);
	transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}

.cc-card:hover {
	border-top-color: var(--cc-accent);
	box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
	transform: translateY(-3px);
}

.cc-card__title,
.cc-feature__title,
.cc-step__title {
	margin: 0 0 10px;
	font-size: 1.55rem;
}

.cc-card__body > :last-child,
.cc-feature__body > :last-child,
.cc-step__body > :last-child {
	margin-bottom: 0;
}

/* Features */
.cc-feature .cc-icon {
	width: 44px;
	height: 44px;
	margin-bottom: 14px;
}

/* Steps: each step sits a little higher than the last, like a climb */
.cc-step__number {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	margin-bottom: 18px;
	background: var(--cc-primary-800);
	clip-path: polygon(50% 0, 100% 100%, 0 100%);
	color: var(--cc-accent);
	font-family: var(--cc-font-display);
	font-size: 1.3rem;
	font-weight: 700;
	line-height: 1;
	padding-top: 14px;
	box-sizing: border-box;
}

@media (min-width: 960px) {
	.cc-steps > .cc-step:nth-child(3n + 1) {
		margin-top: 64px;
	}

	.cc-steps > .cc-step:nth-child(3n + 2) {
		margin-top: 32px;
	}
}

/* FAQ */
.cc-faq {
	border-top: 1px solid var(--cc-line);
}

.cc-faq > .cc-faq__item {
	margin-top: 0;
	border-bottom: 1px solid var(--cc-line);
}

.cc-faq .uk-accordion-title {
	display: block;
	padding: 20px 0;
	color: var(--cc-primary-900);
	text-decoration: none;
}

.cc-faq .uk-accordion-title:hover {
	color: var(--cc-primary-600);
}

.cc-faq__question {
	display: inline;
	margin: 0;
	color: inherit;
	font-size: 1.4rem;
}

.cc-faq .uk-accordion-content {
	margin-top: 0;
	padding-bottom: 22px;
}

/* Closing call to action */
.cc-cta {
	background: var(--cc-primary-800);
}

.cc-cta__title {
	margin: 0 0 12px;
	font-size: clamp(2.2rem, 5vw, 3.5rem);
}

.cc-cta__lead {
	margin: 0 auto 28px;
	max-width: 560px;
	color: var(--cc-on-dark);
	font-size: 1.2rem;
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.cc-footer {
	background: var(--cc-primary-900);
	color: var(--cc-on-dark);
}

.cc-footer__tagline {
	max-width: 420px;
	margin-top: 14px;
	color: var(--cc-on-dark);
}

.cc-footer__heading {
	margin: 0 0 12px;
	color: var(--cc-accent);
	font-size: 1.1rem;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

.uk-light .cc-footer__heading {
	color: var(--cc-accent);
}

.cc-footer__links a {
	color: var(--cc-on-dark);
	text-decoration: none;
}

.cc-footer__links a:hover {
	color: var(--cc-white);
	text-decoration: underline;
}

.cc-footer__bottom {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px 24px;
	margin-top: 48px;
	padding-top: 22px;
	border-top: 1px solid rgba(255, 255, 255, 0.18);
	font-size: 0.9rem;
}

.cc-footer__bottom p {
	margin: 0;
}

.uk-light .cc-footer__top {
	color: var(--cc-on-dark);
	text-decoration: none;
}

.uk-light .cc-footer__top:hover {
	color: var(--cc-white);
}

/* --------------------------------------------------------------------------
   Inner pages
   -------------------------------------------------------------------------- */

main:focus {
	outline: none;
}

.cc-logo-image {
	display: block;
	max-height: calc(var(--cc-header-height) - 24px);
	width: auto;
}

.cc-hero--compact {
	padding-top: clamp(56px, 8vw, 96px);
	padding-bottom: clamp(104px, 13vw, 176px);
}

.cc-page-header {
	padding: clamp(44px, 7vw, 88px) 0;
	background: var(--cc-primary-900);
	background-image:
		repeating-radial-gradient(
			circle at 92% 0%,
			transparent 0 46px,
			rgba(255, 255, 255, 0.045) 46px 47px
		);
}

.cc-page-header .cc-eyebrow {
	margin-bottom: 10px;
}

.cc-page-header__title {
	margin: 0;
	max-width: 880px;
	font-size: clamp(2.4rem, 5.4vw, 4rem);
	line-height: 1.04;
}

.cc-page-header__back {
	margin: 0 0 18px;
}

.uk-light .cc-page-header__back a {
	color: var(--cc-on-dark);
	text-decoration: none;
}

.uk-light .cc-page-header__back a:hover {
	color: var(--cc-white);
}

/* Linked image tiles */
.cc-strip > .uk-container {
	padding-top: clamp(40px, 6vw, 72px);
	padding-bottom: 8px;
}

.cc-strip__tile {
	display: flex;
	align-items: flex-end;
	min-height: 220px;
	padding: 24px;
	box-sizing: border-box;
	background: var(--cc-primary-800);
	text-decoration: none;
}

.cc-strip__tile::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(to top, rgba(0, 0, 0, 0.65), rgba(0, 0, 0, 0.05));
	transition: opacity 0.15s ease;
}

.cc-strip__tile:hover::after {
	opacity: 0.75;
}

.cc-strip__title {
	position: relative;
	z-index: 1;
	color: var(--cc-white);
	font-family: var(--cc-font-display);
	font-size: 1.55rem;
	font-weight: 700;
	line-height: 1.15;
}

/* Contact page */
.cc-contact-form {
	margin-top: 32px;
}

.cc-contact-card {
	padding: 28px;
	border-radius: var(--cc-radius);
	background: var(--cc-surface);
}

.cc-contact-card__title {
	margin: 0 0 16px;
	font-size: 1.55rem;
}

.cc-contact-details > li {
	display: flex;
	gap: 12px;
}

.cc-contact-details address {
	margin: 0;
	font-style: normal;
}

.uk-light .cc-contact-details a {
	color: var(--cc-on-dark);
}

.cc-footer__legal {
	margin-left: 12px;
}

.uk-light .cc-footer__legal {
	color: var(--cc-on-dark);
}

/* --------------------------------------------------------------------------
   Motion preference
   -------------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
	.uk-button,
	.cc-card {
		transition: none;
	}

	.cc-card:hover {
		transform: none;
	}
}
