/*
 * 6Q section library.
 *
 * Rules of the road:
 * 1. Every class is named for its purpose, never its position on a page.
 * 2. Colours, type sizes and spacing come from the tokens below.
 * 3. Pages carry no CSS of their own. If a page needs something new, add it here as a reusable class.
 * 4. Everything is scoped to .sixq-* so it cannot disturb the older q6-* pages.
 * 5. Vertical alignment goes on columns (align-self), never on .wp-block-columns:
 *    WordPress core sets align-items on the columns block with !important.
 */

/* ---------- Tokens ---------- */
:root {
	--sixq-accent: #F4DC09;
	--sixq-accent-ink: #231F20;
	--sixq-ink: #191516;
	--sixq-text: #353535;
	--sixq-muted: #6B7280;
	--sixq-eyebrow: #9A7F00;
	--sixq-teal: #0BA0C0;
	--sixq-deep: #1D5F75;
	--sixq-on-deep: #D5E3EA;
	--sixq-link: #046086;
	--sixq-link-hover: #034A68;
	--sixq-surface: #F7FAFB;
	--sixq-line: #E3E8EB;

	--sixq-font: 'Open Sans', Arial, sans-serif;
	--sixq-h1: clamp(30px, 4.2vw, 46px);
	--sixq-h2: clamp(26px, 3.2vw, 36px);
	--sixq-h3: 21px;
	--sixq-lead: clamp(17px, 1.6vw, 19px);
	--sixq-body: 16px;
	--sixq-small: 15px;

	--sixq-wrap: 1120px;
	--sixq-wrap-narrow: 960px; /* wide enough for the page heading on one line at 46px */
	--sixq-wrap-faq: 800px;
	--sixq-gutter: 16px;
	--sixq-space: clamp(48px, 6vw, 72px);
	--sixq-header-height: 92.8px;
}

/* ---------- Site chrome ---------- */
/* Footer social links: LinkedIn only. The links are in the footer widget (Appearance > Widgets); remove the others there when convenient. */
.site-footer .q6-social a:not([href*="linkedin"]) { display: none; }

/* ---------- Landing template chrome ---------- */
body.sixq-page #page.grid-container { max-width: 100%; }
body.sixq-page .site-main { margin: 0; }
body.sixq-page .inside-article { padding: 0; }
body.sixq-page .entry-content { margin: 0; }

.sixq-band {
	background: #fff var(--sixq-band-image, none) center bottom / cover no-repeat;
	width: 100%;
	height: max(230px, 17.9vw); /* the graphic is 1792 x 321 */
}

/* Transparent header over the hero band on wide screens; solid again once scrolled. */
@media (min-width: 981px) {
	body.sixq-page #masthead.site-header {
		background: transparent;
		margin-bottom: calc(var(--sixq-header-height) * -1);
	}
	body.sixq-page #masthead.site-header:not(.is-scrolled) .main-nav > ul > li > a { color: #fff; }
	body.sixq-page #masthead.site-header:not(.is-scrolled) .main-nav > ul > li.q6-native-login > a { border-color: #fff; }
	body.sixq-page #masthead.site-header.is-scrolled {
		background: #fff;
		box-shadow: 0 1px 6px rgba(0, 0, 0, .12);
	}
}

/* ---------- Section base ---------- */
.sixq-section {
	font-family: var(--sixq-font);
	font-size: var(--sixq-body);
	line-height: 1.6;
	color: var(--sixq-text);
	background: #fff;
	margin: 0;
	padding: 0;
}
.entry-content > .sixq-section { margin-bottom: 0; }
/* GeneratePress gives every group block an inner container with 40px padding, a 1240px cap and auto margins. Sections manage their own width and spacing. */
.site-main .sixq-section .wp-block-group__inner-container { padding: 0; max-width: none; margin-left: 0; margin-right: 0; width: 100%; }
.sixq-section *,
.sixq-section *::before,
.sixq-section *::after { box-sizing: border-box; }

.sixq-section .sixq-wrap {
	max-width: var(--sixq-wrap);
	margin: 0 auto;
	padding: var(--sixq-space) var(--sixq-gutter);
}
.sixq-section .sixq-wrap-narrow { max-width: var(--sixq-wrap-narrow); }
.sixq-section .sixq-wrap-faq { max-width: var(--sixq-wrap-faq); }

/* ---------- Type ---------- */
.sixq-section :is(h1, h2, h3) {
	font-family: var(--sixq-font);
	color: var(--sixq-ink);
	margin: 0 0 16px;
	padding: 0;
}
.sixq-section h1 { font-size: var(--sixq-h1); font-weight: 700; line-height: 1.15; }
.sixq-section h2 { font-size: var(--sixq-h2); font-weight: 700; line-height: 1.2; }
.sixq-section h3 { font-size: var(--sixq-h3); font-weight: 600; line-height: 1.3; margin-bottom: 10px; }
.sixq-section p { font-size: inherit; margin: 0 0 16px; }
.sixq-section p:last-child { margin-bottom: 0; }
.sixq-section strong { color: var(--sixq-ink); }
.sixq-section a:not(.wp-block-button__link) { color: var(--sixq-link); }
.sixq-section a:not(.wp-block-button__link):hover { color: var(--sixq-link-hover); }
.sixq-section img { max-width: 100%; height: auto; display: block; }
.sixq-section figure { margin: 0; }

.sixq-section .sixq-eyebrow {
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 1.2px;
	text-transform: uppercase;
	color: var(--sixq-eyebrow);
}
.sixq-section .sixq-lead { font-size: var(--sixq-lead); }
.sixq-section .sixq-note { font-size: var(--sixq-small); color: var(--sixq-muted); }
.sixq-section .sixq-more a { font-size: var(--sixq-small); font-weight: 700; text-decoration: none; }

/* Yellow rule under a heading. */
.sixq-section .sixq-ruled::after {
	content: "";
	display: block;
	width: 120px;
	height: 3px;
	border-radius: 2px;
	background: var(--sixq-accent);
	margin-top: 14px;
}

/* Centred blocks. */
.sixq-section .sixq-center { text-align: center; }
.sixq-section .sixq-center .sixq-ruled::after { margin-left: auto; margin-right: auto; }
.sixq-section .sixq-center p { max-width: 760px; margin-left: auto; margin-right: auto; }
.sixq-section .sixq-center .wp-block-buttons { justify-content: center; }

/* Text on teal or deep teal. */
.sixq-section.sixq-on-dark,
.sixq-section.sixq-on-dark :is(h1, h2, h3, p, li, strong) { color: #fff; }

/* Dotted background. */
.sixq-section.sixq-pattern { background: var(--sixq-surface) var(--sixq-pattern-image, none) repeat; }

/* ---------- Buttons ---------- */
.sixq-section .wp-block-buttons { gap: 14px; margin: 24px 0 12px; align-items: center; }
.sixq-section .wp-block-button .wp-block-button__link {
	font-family: var(--sixq-font);
	text-decoration: none;
	transition: background-color .15s, color .15s;
}
.sixq-section .wp-block-button.sixq-btn .wp-block-button__link {
	background: var(--sixq-accent);
	color: var(--sixq-accent-ink);
	border: 0;
	border-radius: 4px;
	padding: 15px 28px;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.3;
	letter-spacing: .4px;
	text-transform: uppercase;
}
.sixq-section .wp-block-button.sixq-btn .wp-block-button__link:hover {
	background: var(--sixq-accent-ink);
	color: #fff;
}
.sixq-section .wp-block-button.sixq-btn-outline .wp-block-button__link {
	background: transparent;
	color: #fff;
	border: 1px solid #fff;
	border-radius: 3px;
	padding: 14px 20px;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.3;
	text-transform: none;
}
.sixq-section .wp-block-button.sixq-btn-outline .wp-block-button__link:hover {
	background: #fff;
	color: var(--sixq-accent-ink);
}

/* ---------- Lists with yellow dots ---------- */
.sixq-section ul.sixq-dots {
	list-style: none;
	margin: 6px 0 0;
	padding: 0;
	font-size: var(--sixq-small);
	color: var(--sixq-ink);
}
.sixq-section ul.sixq-dots li {
	position: relative;
	margin: 0 0 10px;
	padding-left: 21px;
}
.sixq-section ul.sixq-dots li:last-child { margin-bottom: 0; }
.sixq-section ul.sixq-dots li::before {
	content: "";
	position: absolute;
	left: 0;
	top: .55em;
	width: 9px;
	height: 9px;
	border-radius: 50%;
	background: var(--sixq-accent);
}

/* ---------- Columns ---------- */
.sixq-section .wp-block-columns { gap: 32px; margin: 0; }
.sixq-section .sixq-cols-3 { margin-top: 36px; }
.sixq-section .sixq-cols-3 p { font-size: var(--sixq-small); }
.sixq-section .sixq-split { gap: 48px; }
.sixq-section .sixq-split > .wp-block-column { align-self: center; }
.sixq-section .sixq-col-media img { margin: 0 auto; }

/* ---------- Headline ---------- */
.sixq-headline .sixq-wrap { padding-top: 56px; padding-bottom: 64px; }
.sixq-section.sixq-headline .sixq-lead { max-width: 700px; }
/* Button and price note on one line; they wrap onto two lines only when the screen is too narrow. */
.sixq-headline .wp-block-buttons { display: inline-flex; margin: 24px 0 0; vertical-align: middle; }
.sixq-headline .sixq-note { display: inline-block; margin: 24px 0 0 16px; vertical-align: middle; }

/* ---------- Photo with text card ---------- */
.sixq-section.sixq-photo {
	position: relative;
	overflow: hidden;
	background: var(--sixq-surface);
}
.sixq-photo .sixq-photo-img {
	position: absolute;
	inset: 0;
	margin: 0;
	z-index: 0;
}
.sixq-photo .sixq-photo-img img {
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
	object-position: center right;
}
.sixq-photo .sixq-photo-img::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(90deg, rgba(255, 255, 255, .6) 0%, rgba(255, 255, 255, .3) 38%, rgba(255, 255, 255, 0) 60%);
}
.sixq-photo .sixq-wrap {
	position: relative;
	z-index: 1;
	display: flex;
	align-items: center;
	min-height: 560px;
	padding-top: 56px;
	padding-bottom: 56px;
}
.sixq-section .sixq-card {
	max-width: 520px;
	background: rgba(255, 255, 255, .88);
	border-radius: 6px;
	padding: 36px 36px 32px;
}
.sixq-section .sixq-card h2 { font-size: clamp(24px, 2.8vw, 32px); }
.sixq-section .sixq-card .sixq-ruled::after { width: 80px; }

/* ---------- Worked example on teal ---------- */
.sixq-section.sixq-example { background: var(--sixq-teal); }
.sixq-example .sixq-wrap { padding-top: 64px; padding-bottom: 0; }
.sixq-example .sixq-split > .wp-block-column { align-self: flex-end; }
.sixq-example .sixq-col-text { padding-bottom: 64px; }
.sixq-example .sixq-col-text p { font-size: 17px; }
.sixq-example .sixq-col-media img { width: 280px; }

/* ---------- Features beside a screenshot ---------- */
/* The screenshot sits on the section's bottom edge; the text keeps the normal bottom spacing. */
.sixq-features .sixq-wrap { padding-bottom: 0; }
.sixq-features .sixq-split > .wp-block-column { align-self: flex-end; }
.sixq-features .sixq-col-text { padding-bottom: var(--sixq-space); }
.sixq-features .sixq-col-media img { width: 100%; max-width: 420px; }

@media (min-width: 782px) {
	.sixq-example .wp-block-columns > .wp-block-column.sixq-col-media { flex: 0 1 300px; }
	.sixq-features .wp-block-columns > .wp-block-column.sixq-col-media { flex: 0 1 420px; }
}

/* ---------- FAQ ---------- */
.sixq-faq details.wp-block-details {
	background: var(--sixq-surface);
	border: 1px solid var(--sixq-line);
	border-radius: 6px;
	padding: 18px 22px;
	margin: 0 0 20px;
}
.sixq-faq .sixq-center { margin-bottom: 28px; }
.sixq-faq details.wp-block-details summary {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 16px;
	list-style: none;
	cursor: pointer;
	font-size: 17px;
	font-weight: 600;
	color: var(--sixq-ink);
}
.sixq-faq details.wp-block-details summary::-webkit-details-marker { display: none; }
.sixq-faq details.wp-block-details summary::after {
	content: "+";
	flex: 0 0 auto;
	font-size: 24px;
	line-height: 1;
	color: var(--sixq-teal);
	transition: transform .15s;
}
.sixq-faq details.wp-block-details[open] summary::after { transform: rotate(45deg); }
.sixq-faq details.wp-block-details p { font-size: var(--sixq-small); margin: 12px 0 0; }
.sixq-faq .sixq-footnote { font-size: var(--sixq-small); text-align: center; margin-top: 28px; }

/* ---------- Final call to action ---------- */
.sixq-section.sixq-cta {
	position: relative;
	overflow: hidden;
	background: var(--sixq-deep);
}
/* The trend line is 1440 x 90 and scales with the width (6.25vw tall), so the dots stay round. The wrap keeps clear of it. */
.sixq-cta .sixq-wrap { position: relative; z-index: 1; padding-top: 80px; padding-bottom: calc(48px + 6.25vw); }
.sixq-cta h2 { font-size: clamp(28px, 3.4vw, 38px); line-height: 1.15; }
.sixq-section.sixq-cta p { font-size: 17px; color: var(--sixq-on-deep); max-width: 560px; }
.sixq-section.sixq-cta::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 6.25vw;
	pointer-events: none;
	background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 90' preserveAspectRatio='xMidYMax meet'%3E%3Cpolyline points='0,60 300,70 620,36 900,52 1200,20 1440,34' fill='none' stroke='%23F4DC09' stroke-width='3'/%3E%3Ccircle cx='300' cy='70' r='7' fill='%23F4DC09'/%3E%3Ccircle cx='620' cy='36' r='7' fill='%23F4DC09'/%3E%3Ccircle cx='900' cy='52' r='7' fill='%23F4DC09'/%3E%3Ccircle cx='1200' cy='20' r='7' fill='%23F4DC09'/%3E%3C/svg%3E") center bottom / 100% auto no-repeat;
}

/* ---------- Small screens ---------- */
@media (max-width: 781px) {
	.sixq-photo .sixq-wrap { min-height: 0; }
	.sixq-section .sixq-card { padding: 28px 24px; }
	.sixq-example .sixq-split > .wp-block-column { align-self: center; }
	.sixq-example .sixq-col-text { padding-bottom: 0; order: -1; }
	.sixq-example .sixq-wrap { padding-top: 48px; }
	.sixq-features .sixq-col-text { padding-bottom: 32px; }
}
