/* WordPress-specific additions to the FSIM design. */

/* Keep the fixed header below the admin toolbar when logged in. */
.admin-bar .site-header { top: 32px; }
.admin-bar .login-card { margin-top: 0; }
@media screen and (max-width: 782px) {
	.admin-bar .site-header { top: 46px; }
}
@media screen and (max-width: 600px) {
	#wpadminbar { position: fixed; }
}

.screen-reader-text {
	border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%);
	height: 1px; margin: -1px; overflow: hidden; padding: 0; position: absolute !important;
	width: 1px; word-wrap: normal !important;
}

/* ---------------------------------------------------------------
   Pages written with normal blocks (Default template)
   --------------------------------------------------------------- */
.entry-content > * + * { margin-top: 1.1em; }
.entry-content h2 { font: 700 var(--h2, 34px)/1.15 var(--font-body); color: var(--ink); margin-top: 1.8em; }
.entry-content h3 { font: 600 var(--h3, 24px)/1.25 var(--font-body); color: var(--ink); margin-top: 1.6em; }
.entry-content img { max-width: 100%; height: auto; border-radius: 4px; }
.entry-content figure { margin-inline: 0; }
.entry-content figcaption { font-size: 14px; color: var(--muted); margin-top: 8px; }
.entry-content ul, .entry-content ol { padding-left: 1.25em; }
.entry-content ul:not([class]) { list-style: disc; }
.entry-content ol:not([class]) { list-style: decimal; }
.entry-content blockquote { border-left: 3px solid var(--teal-800); margin-inline: 0; padding-left: 24px; font-size: 1.15em; color: var(--ink); }
.entry-content .alignleft { float: left; margin: 0 24px 16px 0; }
.entry-content .alignright { float: right; margin: 0 0 16px 24px; }
.entry-content .aligncenter { margin-inline: auto; display: block; }
.entry-content .wp-block-button__link,
.entry-content .wp-element-button {
	background: var(--teal-800); color: #fff; min-height: 48px;
	font: 600 var(--button, 16px)/1 var(--font-condensed); letter-spacing: .07em; text-transform: uppercase;
	border-radius: 2px; padding: 0 24px; display: inline-flex; align-items: center; text-decoration: none;
}
.entry-content .wp-block-button__link:hover { background: var(--teal-900); color: #fff; }
.entry-content table { border-collapse: collapse; width: 100%; }
.entry-content th, .entry-content td { border-bottom: 1px solid var(--line); padding: 12px 8px; text-align: left; }

.fsim-post-list article { border-bottom: 1px solid var(--line); padding-block: 32px; }
.fsim-post-list article h2 { margin-top: 4px; }
.fsim-post-list article h2 a { color: var(--ink); text-decoration: none; }
.nav-links { display: flex; gap: 12px; margin-top: 40px; }
.nav-links .page-numbers { min-width: 44px; min-height: 44px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line-strong); text-decoration: none; }
.nav-links .page-numbers.current { background: var(--teal-800); color: #fff; border-color: var(--teal-800); }

/* ---------------------------------------------------------------
   Form plugins (Gravity Forms, WPForms, Contact Form 7, Fluent Forms,
   Ninja Forms, Formidable). Place the plugin's form/shortcode inside the
   page's <div class="form-card"> (replacing the preview wizard) and it
   will pick up the site's field styling.
   --------------------------------------------------------------- */
.form-card :is(.gform_wrapper, .wpforms-container, .wpcf7, .fluentform, .nf-form-cont, .frm_forms) {
	--gf-color-primary: var(--teal-800);
	font: 400 17px/1.5 var(--font-body);
	color: var(--text);
	margin: 0;
}
.form-card :is(.gform_wrapper, .wpforms-container, .wpcf7, .fluentform, .nf-form-cont, .frm_forms) :is(label, legend, .gfield_label, .wpforms-field-label, .ff-el-input--label label, .nf-field-label label, .frm_primary_label) {
	font: 600 17px/1.4 var(--font-body);
	color: var(--ink);
	margin-bottom: 8px;
}
.form-card :is(.gform_wrapper, .wpforms-container, .wpcf7, .fluentform, .nf-form-cont, .frm_forms) :is(input:not([type=radio]):not([type=checkbox]):not([type=submit]):not([type=button]):not([type=file]), select, textarea) {
	border: 1px solid var(--line-strong) !important;
	width: 100% !important;
	max-width: 100% !important;
	min-height: 52px;
	font: 400 17px/1.3 var(--font-body) !important;
	color: var(--ink) !important;
	background: #fff !important;
	border-radius: 2px !important;
	padding: 12px 16px !important;
	box-shadow: none !important;
}
.form-card :is(.gform_wrapper, .wpforms-container, .wpcf7, .fluentform, .nf-form-cont, .frm_forms) textarea { min-height: 140px; resize: vertical; }
.form-card :is(.gform_wrapper, .wpforms-container, .wpcf7, .fluentform, .nf-form-cont, .frm_forms) :is(input, select, textarea):focus {
	border-color: var(--teal-800) !important;
	outline: 0 !important;
	box-shadow: 0 0 0 3px #009dad40 !important;
}
.form-card :is(.gform_wrapper, .wpforms-container, .wpcf7, .fluentform, .nf-form-cont, .frm_forms) :is(input[type=radio], input[type=checkbox]) {
	width: 20px; height: 20px; accent-color: var(--teal-800);
}
.form-card :is(.gform_wrapper, .wpforms-container, .wpcf7, .fluentform, .nf-form-cont, .frm_forms) :is(input[type=submit], button[type=submit], .gform_button, .gform_next_button, .wpforms-submit, .wpcf7-submit, .ff-btn-submit, .frm_button_submit) {
	background: var(--teal-800) !important;
	color: #fff !important;
	min-height: 48px;
	font: 600 var(--button, 16px)/1 var(--font-condensed) !important;
	letter-spacing: .07em;
	text-transform: uppercase;
	border: 1.5px solid transparent !important;
	border-radius: 2px !important;
	padding: 0 24px !important;
	cursor: pointer;
	box-shadow: none !important;
}
.form-card :is(.gform_wrapper, .wpforms-container, .wpcf7, .fluentform, .nf-form-cont, .frm_forms) :is(input[type=submit], button[type=submit], .gform_button, .wpforms-submit, .wpcf7-submit, .ff-btn-submit, .frm_button_submit):hover {
	background: var(--teal-900) !important;
}
.form-card :is(.gform_previous_button) {
	background: #fff !important; color: var(--teal-800) !important; border: 1.5px solid var(--teal-800) !important;
}
.form-card :is(.gfield_description, .wpforms-field-description, .ff-el-help-message, .nf-field-description, .frm_description) {
	font-size: 15px; color: var(--muted);
}
.form-card :is(.gfield_validation_message, .validation_message, .wpforms-error, .wpcf7-not-valid-tip, .error.text-danger, .nf-error-msg, .frm_error) {
	color: var(--error) !important; font-size: 15px; background: none !important; border: 0 !important; padding: 4px 0 0 !important;
}
.form-card .gf_progressbar_percentage,
.form-card .wpforms-page-indicator-page-progress { background: var(--teal-800) !important; }

/* 2.1.3: keep the building in the same place in the home hero on any window shape.
   The photo is square and scaled to the hero width; place it so the roofline sits
   about 61% down the hero instead of pinning the photo to the top. */
@media (min-width: 800px) {
	.home-hero {
		--fsim-hero-h: max(730px, min(86vh, 930px));
	}
	.home-hero .hero-photo picture,
	.home-hero .hero-photo img {
		object-position: 50% min(0px, max(calc(var(--fsim-hero-h) - 100vw), calc(var(--fsim-hero-h) * 0.61 - 100vw * 0.35)));
	}
}
