/*
 * QRS: site chrome (header, hero, footer, forms, article lists) and the
 * layout rules for page content on the public site.
 */

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
	scroll-padding-top: 110px;
}

body {
	margin: 0;
	overflow-wrap: break-word;
}

img,
svg,
video {
	max-width: 100%;
	height: auto;
}

img {
	display: block;
}

button,
input,
select,
textarea {
	font: inherit;
	color: inherit;
}

[hidden] {
	display: none !important;
}

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

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.skip-link:focus {
	position: fixed !important;
	top: 8px;
	left: 8px;
	z-index: 1000;
	width: auto;
	height: auto;
	margin: 0;
	padding: 12px 18px;
	clip: auto;
	border-radius: 8px;
	background: #fff;
	color: var(--q-heading);
	box-shadow: 0 6px 22px rgba(18, 50, 74, .2);
}

.q-ico {
	flex: none;
}

.q-wrap {
	width: 100%;
	max-width: calc(var(--q-width) + 40px);
	margin: 0 auto;
	padding: 0 20px;
}

.q-wrap--text {
	max-width: calc(var(--q-text-width) + 40px);
}

/* Page content layout */
.q-content {
	padding: 0 20px;
}

.q-content > * {
	max-width: var(--q-text-width);
	margin-right: auto;
	margin-left: auto;
}

.q-content > * + * {
	margin-top: 1.25rem;
}

.q-content > .alignwide {
	max-width: var(--q-width);
}

.q-content > .alignfull {
	max-width: none;
	margin-right: -20px;
	margin-left: -20px;
}

.q-content > .alignfull + .alignfull,
.q-content > .alignfull:first-child {
	margin-top: 0;
}

.q-content > :first-child:not(.alignfull) {
	margin-top: calc(var(--q-space) * .7);
}

.q-content > :last-child:not(.alignfull) {
	margin-bottom: var(--q-space);
}

.q-content > h2:not(:first-child),
.q-content > h3:not(:first-child) {
	margin-top: 2em;
}

.q-content .wp-block-columns {
	margin-bottom: 0;
}

/* Header */
.q-header {
	position: relative;
	z-index: 60;
	border-bottom: 1px solid var(--q-border);
	background: var(--q-bg);
}

.q-sticky .q-header {
	position: sticky;
	top: 0;
}

.admin-bar.q-sticky .q-header {
	top: 32px;
}

.q-header.is-scrolled {
	box-shadow: 0 4px 18px rgba(18, 50, 74, .08);
}

.q-header__inner {
	display: flex;
	align-items: center;
	gap: 14px;
	min-height: 72px;
}

.q-logo {
	display: inline-flex;
	align-items: center;
	margin-right: auto;
	text-decoration: none;
}

.q-header .q-logo img.q-logo__img {
	width: auto;
	height: calc(var(--q-logo-h) * .82);
	max-width: 190px;
	object-fit: contain;
}

.q-burger {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 46px;
	padding: 0 12px;
	border: 1px solid var(--q-border);
	border-radius: 10px;
	background: var(--q-bg);
	color: var(--q-heading);
	font-family: var(--q-font-heading);
	font-size: .94rem;
	font-weight: 700;
	cursor: pointer;
	order: 3;
}

.q-burger__close,
.q-nav-open .q-burger__open {
	display: none;
}

.q-nav-open .q-burger__close {
	display: inline-flex;
}

.q-header__actions {
	display: flex;
	align-items: center;
	gap: 10px;
	order: 2;
}

.q-header__phone {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 46px;
	padding: 0 6px;
	color: var(--q-heading);
	font-family: var(--q-font-heading);
	font-weight: 800;
	text-decoration: none;
	white-space: nowrap;
}

.q-header__phone .q-ico {
	color: var(--q-secondary);
}

.q-header__phone span,
.q-header__quote {
	display: none;
	white-space: nowrap;
}

/* Menu: drawer on small screens */
.q-nav {
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	z-index: 90;
	display: flex;
	flex-direction: column;
	width: min(88vw, 360px);
	padding: 84px 22px 28px;
	background: var(--q-bg);
	box-shadow: -10px 0 40px rgba(18, 50, 74, .18);
	overflow-y: auto;
	transform: translateX(104%);
	visibility: hidden;
	transition: transform .2s ease, visibility .2s;
}

.admin-bar .q-nav {
	padding-top: 130px;
}

.q-nav-open .q-nav {
	transform: none;
	visibility: visible;
}

.q-nav-open .q-header {
	z-index: 100;
}

.q-nav-open .q-burger {
	position: fixed;
	top: 16px;
	right: 20px;
	z-index: 95;
}

.admin-bar.q-nav-open .q-burger {
	top: 62px;
}

.q-nav-open {
	overflow: hidden;
}

.q-backdrop {
	position: fixed;
	inset: 0;
	z-index: 80;
	background: rgba(18, 50, 74, .55);
}

.q-nav__list,
.q-nav__list ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

.q-nav__list li {
	margin: 0;
}

.q-nav__list a {
	display: block;
	padding: 15px 4px;
	border-bottom: 1px solid var(--q-border);
	color: var(--q-heading);
	font-family: var(--q-font-heading);
	font-size: 1.05rem;
	font-weight: var(--q-nav-weight);
	text-decoration: none;
	text-transform: var(--q-nav-transform);
}

.q-nav__list ul a {
	padding-left: 20px;
	font-size: .98rem;
	font-weight: 500;
}

.q-nav__list .current-menu-item > a,
.q-nav__list a:hover {
	color: var(--q-secondary);
}

.q-nav__extra {
	margin-top: 8px;
}

.q-btns--stack {
	flex-direction: column;
}

.q-btns--stack .q-btn {
	width: 100%;
}

@media (min-width: 560px) {
	.q-header__phone span {
		display: inline;
	}
}

@media (min-width: 1200px) {
	.q-header__inner {
		min-height: 88px;
		gap: 26px;
	}

	.q-header .q-logo img.q-logo__img {
		height: var(--q-logo-h);
		max-width: 230px;
	}

	.q-logo {
		margin-right: 0;
	}

	.q-burger,
	.q-nav__extra,
	.q-backdrop {
		display: none !important;
	}

	.q-nav {
		position: static;
		flex: 1;
		flex-direction: row;
		justify-content: flex-end;
		width: auto;
		padding: 0;
		background: none;
		box-shadow: none;
		overflow: visible;
		transform: none;
		visibility: visible;
	}

	.admin-bar .q-nav {
		padding-top: 0;
	}

	.q-nav__list {
		display: flex;
		align-items: center;
		gap: 2px;
	}

	.q-nav__list > li {
		position: relative;
	}

	.q-nav__list a {
		padding: 10px 13px;
		border: 0;
		border-radius: 8px;
		font-size: .98rem;
		white-space: nowrap;
	}

	.q-nav__list > li > a:hover {
		background: var(--q-surface);
	}

	.q-nav__list > .menu-item-has-children > a::after {
		content: "";
		display: inline-block;
		width: 7px;
		height: 7px;
		margin: 0 0 3px 8px;
		border-right: 2px solid currentColor;
		border-bottom: 2px solid currentColor;
		transform: rotate(45deg);
	}

	.q-nav__list ul {
		position: absolute;
		top: 100%;
		left: 0;
		z-index: 5;
		display: none;
		min-width: 270px;
		padding: 8px;
		border: 1px solid var(--q-border);
		border-radius: 14px;
		background: var(--q-bg);
		box-shadow: 0 14px 36px rgba(18, 50, 74, .14);
	}

	.q-nav__list li:hover > ul,
	.q-nav__list li:focus-within > ul {
		display: block;
	}

	.q-nav__list ul a {
		padding: 11px 13px;
		white-space: normal;
	}

	.q-nav__list ul a:hover {
		background: var(--q-surface);
	}

	.q-header__quote {
		display: inline-flex;
	}

	.q-header-center .q-header__inner {
		flex-wrap: wrap;
		justify-content: center;
		padding-top: 12px;
		padding-bottom: 6px;
		gap: 6px 26px;
	}

	.q-header-center .q-logo {
		width: 100%;
		justify-content: center;
	}

	.q-header-center .q-nav {
		flex: none;
	}
}

@media (max-width: 782px) {
	.admin-bar.q-sticky .q-header {
		top: 46px;
	}
}

@media (max-width: 600px) {
	.admin-bar.q-sticky .q-header {
		top: 0;
	}
}

/* Breadcrumbs */
.q-bc {
	margin-bottom: 16px;
	font-size: .86rem;
}

.q-bc ol {
	display: flex;
	flex-wrap: wrap;
	margin: 0;
	padding: 0;
	list-style: none;
}

.q-bc li {
	margin: 0;
}

.q-bc li:not(:last-child)::after {
	content: "/";
	margin: 0 8px;
	opacity: .55;
}

.q-bc a {
	color: inherit;
}

/* Hero */
.q-hero {
	padding: 40px 0 48px;
	background: var(--q-surface);
}

.q-hero--white {
	background: var(--q-bg);
	border-bottom: 1px solid var(--q-border);
}

.q-hero--dark {
	background: var(--q-dark);
	color: var(--q-on-dark);
}

.q-hero--dark h1 {
	color: #fff;
}

.q-hero__grid {
	display: grid;
	gap: 30px;
	align-items: center;
}

.q-hero__grid > * {
	min-width: 0;
}

.q-hero h1 {
	margin-bottom: .4em;
}

.q-hero__lead {
	max-width: 620px;
	margin-bottom: 0;
	font-size: 1.14em;
}

.q-hero--simple .q-hero__text {
	max-width: 820px;
}

.q-hero__media {
	position: relative;
	padding: 0 14px 14px 0;
}

.q-hero__media::before {
	content: "";
	position: absolute;
	inset: 14px 0 0 14px;
	border-radius: 26px;
	background: var(--q-primary);
	opacity: .28;
}

.q-hero__media img {
	position: relative;
	width: 100%;
	aspect-ratio: 3 / 2;
	border-radius: 22px;
	object-fit: cover;
	box-shadow: 0 18px 44px rgba(18, 50, 74, .16);
}

.q-hero-none {
	padding-top: 22px;
}

.q-hero--article h1 {
	font-size: calc(var(--q-h1-size) * .86);
}

.q-article__meta {
	margin: 0;
	font-size: .92rem;
}

.q-article__image {
	margin-top: calc(var(--q-space) * .5) !important;
	max-width: 960px !important;
}

.q-article__image img {
	width: 100%;
	aspect-ratio: 16 / 9;
	border-radius: 20px;
	object-fit: cover;
}

@media (min-width: 1000px) {
	.q-hero {
		padding: 68px 0 76px;
	}

	.q-hero--split .q-hero__grid {
		grid-template-columns: minmax(0, 1.06fr) minmax(0, .94fr);
		gap: 60px;
	}

	.q-hero--home .q-hero__media img {
		aspect-ratio: 4 / 3.3;
	}
}

/* Footer call-to-action band */
.q-band--footer {
	border-top: 4px solid var(--q-primary);
}

.q-band--footer h2 {
	margin-bottom: .3em;
}

.q-band--footer p {
	margin-bottom: 0;
}

/* Footer */
.q-footer {
	border-top: 1px solid rgba(255, 255, 255, .14);
	background: var(--q-dark);
	color: var(--q-on-dark);
	font-size: .95rem;
}

.q-footer a {
	color: #fff;
	text-decoration: none;
}

.q-footer a:hover {
	text-decoration: underline;
}

.q-footer strong {
	color: #fff;
}

.q-footer__grid {
	display: grid;
	gap: 34px;
	padding-top: 56px;
	padding-bottom: 44px;
}

.q-footer__grid > * {
	min-width: 0;
}

.q-footer h2 {
	margin-bottom: 14px;
	font-size: 1rem;
	font-weight: 700;
	letter-spacing: .03em;
	color: #fff;
}

.q-footer ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

.q-footer__col li {
	margin-bottom: 10px;
}

.q-logo--plate {
	margin-bottom: 18px;
	padding: 10px 14px;
	border-radius: 12px;
	background: #fff;
}

.q-footer .q-logo img.q-logo__img {
	width: auto;
	height: 52px;
	max-width: 200px;
	object-fit: contain;
}

.q-footer .q-logo:not(.q-logo--plate) {
	margin-bottom: 18px;
}

.q-social {
	display: flex;
	gap: 8px;
	padding: 0 !important;
	list-style: none !important;
	margin-top: 16px !important;
}

.q-social li {
	margin: 0;
}

.q-social a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	border: 1px solid rgba(255, 255, 255, .3);
	border-radius: 50%;
}

.q-content .q-social a {
	border-color: var(--q-border);
	color: var(--q-secondary);
}

.q-contact-list {
	margin-top: 0;
	margin-bottom: 0;
	padding: 0;
	list-style: none;
}

.q-contact-list li {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin-bottom: 14px;
}

.q-contact-list .q-ico {
	margin-top: 4px;
	color: var(--q-primary);
}

.q-contact-list strong,
.q-contact-list span > span,
.q-contact-list span > a {
	display: block;
}

.q-hours span {
	display: block;
}

.q-hours__tz {
	font-size: .9em;
	opacity: .85;
}

.q-footer__legal {
	border-top: 1px solid rgba(255, 255, 255, .14);
	font-size: .82rem;
	line-height: 1.55;
}

.q-footer__legal .q-wrap {
	padding-top: 20px;
	padding-bottom: 6px;
}

.q-footer__legal p {
	margin-bottom: 12px;
	opacity: .9;
}

.q-footer__bar {
	border-top: 1px solid rgba(255, 255, 255, .14);
	font-size: .86rem;
}

.q-footer__bar .q-wrap {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 24px;
	padding-top: 16px;
	padding-bottom: 16px;
}

.q-footer__bar p {
	margin: 0;
}

.q-footer__legalnav ul {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 20px;
}

.q-footer__legalnav li {
	margin: 0;
}

@media (min-width: 700px) {
	.q-footer__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (min-width: 1000px) {
	.q-footer__grid--4 {
		grid-template-columns: 1.3fr .9fr .9fr 1.2fr;
		gap: 44px;
	}

	.q-footer__grid--3 {
		grid-template-columns: 1.4fr 1fr 1.2fr;
		gap: 56px;
	}
}

/* Mobile call / quote bar */
.q-mobilebar {
	position: fixed;
	right: 0;
	bottom: 0;
	left: 0;
	z-index: 55;
	display: flex;
	gap: 10px;
	padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
	border-top: 1px solid var(--q-border);
	background: var(--q-bg);
	box-shadow: 0 -6px 22px rgba(18, 50, 74, .1);
}

.q-mobilebar a {
	display: inline-flex;
	flex: 1;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 50px;
	border: 2px solid var(--q-heading);
	border-radius: var(--q-btn-radius);
	color: var(--q-heading);
	font-family: var(--q-font-heading);
	font-weight: 800;
	text-decoration: none;
}

.q-mobilebar a.q-mobilebar__quote {
	flex: 1.5;
	border-color: var(--q-btn);
	background: var(--q-btn);
	color: var(--q-btn-text);
}

.q-has-mobilebar {
	padding-bottom: calc(72px + env(safe-area-inset-bottom));
}

@media (min-width: 783px) {
	.q-mobilebar {
		display: none;
	}

	.q-has-mobilebar {
		padding-bottom: 0;
	}
}

/* Quote form */
.q-form-card {
	padding: 26px 22px;
	border: var(--q-card-border) solid var(--q-border);
	border-top: 5px solid var(--q-primary);
	border-radius: var(--q-card-radius);
	background: var(--q-bg);
	box-shadow: var(--q-card-shadow);
	scroll-margin-top: 120px;
}

.q-form-card__title {
	margin-bottom: .3em;
	font-size: var(--q-h3-size);
}

.q-form-card__intro {
	font-size: .96em;
}

.q-form__row {
	display: grid;
	gap: 0 18px;
}

.q-form__row > * {
	min-width: 0;
}

.q-field {
	margin: 0 0 16px;
}

.q-field label {
	display: block;
	margin-bottom: 6px;
	font-size: .94rem;
	font-weight: 600;
	color: var(--q-heading);
}

.q-req {
	color: #B3261E;
}

.q-form input[type="text"],
.q-form input[type="tel"],
.q-form input[type="email"],
.q-form select,
.q-form textarea,
.q-search input[type="search"],
.q-comments input[type="text"],
.q-comments input[type="email"],
.q-comments input[type="url"],
.q-comments textarea {
	width: 100%;
	min-height: 54px;
	padding: 12px 14px;
	border: 1.5px solid #9FB4BF;
	border-radius: 10px;
	background: #fff;
	font-size: 1.05rem;
	line-height: 1.3;
	color: var(--q-heading);
}

.q-form textarea {
	min-height: 96px;
	resize: vertical;
}

.q-form input:focus,
.q-form select:focus,
.q-form textarea:focus {
	border-color: var(--q-secondary);
	outline: 3px solid var(--q-focus);
	outline-offset: 1px;
}

.q-hint {
	display: block;
	margin-top: 6px;
	font-size: .84rem;
}

.q-consent {
	margin: 4px 0 18px;
	font-size: .86rem;
	line-height: 1.5;
}

.q-consent label {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	cursor: pointer;
}

.q-consent input {
	flex: none;
	width: 24px;
	height: 24px;
	margin: 2px 0 0;
	accent-color: var(--q-secondary);
}

.q-form__submit {
	margin: 0;
}

.q-form__submit .q-btn {
	width: 100%;
}

.q-hp {
	position: absolute !important;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.q-alert {
	margin: 0 0 16px;
	padding: 14px 18px;
	border-radius: 10px;
	font-weight: 600;
}

.q-alert--ok {
	border: 1px solid #A9D7BC;
	background: #EAF7EF;
	color: #14532D;
}

.q-alert--err {
	border: 1px solid #EFBDB8;
	background: #FDF0EE;
	color: #8C1D18;
}

@media (min-width: 640px) {
	.q-form__row {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.q-form-card {
		padding: 34px 32px;
	}
}

/* Article lists */
.q-archive {
	padding-top: calc(var(--q-space) * .7);
	padding-bottom: var(--q-space);
}

.q-posts {
	display: grid;
	gap: 24px;
}

.q-post {
	display: flex;
	flex-direction: column;
	min-width: 0;
	border: var(--q-card-border) solid var(--q-border);
	border-radius: var(--q-card-radius);
	overflow: hidden;
	background: var(--q-bg);
	box-shadow: var(--q-card-shadow);
}

.q-post__thumb img {
	width: 100%;
	aspect-ratio: 3 / 2;
	object-fit: cover;
}

.q-post__body {
	padding: 22px;
}

.q-post__title {
	margin-bottom: .3em;
	font-size: var(--q-h4-size);
	line-height: 1.3;
}

.q-post__title a {
	color: var(--q-heading);
	text-decoration: none;
}

.q-post__title a:hover {
	text-decoration: underline;
}

.q-post__meta {
	margin-bottom: .6em;
	font-size: .86rem;
}

.q-post__excerpt {
	font-size: .96em;
}

.q-with-sidebar {
	display: grid;
	gap: 40px;
}

.q-with-sidebar > * {
	min-width: 0;
}

.q-sidebar .widget {
	margin-bottom: 26px;
	padding: 20px;
	border: 1px solid var(--q-border);
	border-radius: 14px;
}

.q-sidebar .widget-title {
	font-size: var(--q-h5-size);
}

.q-search {
	display: flex;
	gap: 10px;
	margin-bottom: 28px;
}

.q-search input {
	flex: 1;
	min-width: 0;
}

.pagination,
.comments-pagination {
	margin-top: 34px;
}

.nav-links {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px;
}

.page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 46px;
	height: 46px;
	padding: 0 14px;
	border: 1px solid var(--q-border);
	border-radius: 10px;
	color: var(--q-heading);
	font-weight: 600;
	text-decoration: none;
}

.page-numbers.current {
	border-color: var(--q-dark);
	background: var(--q-dark);
	color: var(--q-on-dark);
}

@media (min-width: 700px) {
	.q-posts--grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.q-posts--list .q-post {
		flex-direction: row;
	}

	.q-posts--list .q-post__thumb {
		flex: 0 0 36%;
	}

	.q-posts--list .q-post__thumb img {
		height: 100%;
	}
}

@media (min-width: 1000px) {
	.q-posts--grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.q-with-sidebar {
		grid-template-columns: minmax(0, 1fr) 300px;
		align-items: start;
	}

	.q-with-sidebar .q-posts--grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

/* Comments */
.q-comments {
	padding: 40px 0 var(--q-space);
}

.q-comments__list,
.q-comments__list ol {
	margin: 0 0 24px;
	padding: 0;
	list-style: none;
}

.q-comments .comment-body {
	margin-bottom: 14px;
	padding: 18px;
	border: 1px solid var(--q-border);
	border-radius: 12px;
}

.q-comments label {
	display: block;
	margin-bottom: 6px;
	font-weight: 600;
}

.q-comments .submit {
	min-height: 52px;
	padding: 12px 26px;
	border: 0;
	border-radius: var(--q-btn-radius);
	background: var(--q-btn);
	color: var(--q-btn-text);
	font-weight: 700;
	cursor: pointer;
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	* {
		transition: none !important;
	}
}

@media print {
	.q-header,
	.q-footer,
	.q-mobilebar,
	.q-band--footer {
		display: none !important;
	}
}

/* Wide shortcode output inside page sections */
.is-layout-constrained > .q-posts,
.is-layout-constrained > .q-areas {
	max-width: var(--q-width);
}

.q-content > .q-posts,
.q-content > .q-areas {
	max-width: var(--q-width);
}
