/*
	Heading - "Line" and "No line" block styles, picked in the heading's Styles panel
	Default keeps the theme's line (midland_health_2022.css: every heading inside a Kadence
	column gets a peach bar). "Line" shows it anywhere and follows the text alignment;
	"No line" removes it and the room left for it.

	Older section rules hide the line with up to 5 classes (e.g. .faq-section), so the
	properties here use !important - only inside these two style classes.
*/

/* ---------- Line ---------- */

.wp-block-heading.is-style-mh-line {
	position: relative;
	padding-bottom: 10px !important;
}
.wp-block-heading.is-style-mh-line::after {
	content: "" !important;
	display: block !important;
	position: absolute;
	bottom: 0;
	left: 0;
	right: auto;
	width: 50%;
	height: 3px;
	border-radius: 2em;
	background-color: var(--global-palette1, #f4a582);
	transform: none;
}
:is(h1, h2).wp-block-heading.is-style-mh-line::after {
	height: 5px;
}

/* Follows the heading's alignment */
.wp-block-heading.is-style-mh-line.has-text-align-center::after {
	left: 50%;
	transform: translateX(-50%);
}
.wp-block-heading.is-style-mh-line.has-text-align-right::after {
	left: auto;
	right: 0;
}

/* ---------- No line ---------- */

.wp-block-heading.is-style-mh-no-line {
	padding-bottom: 0 !important;
}
.wp-block-heading.is-style-mh-no-line::after {
	display: none !important;
}

/* ---------- Editor ----------
	midland_health_2022.css doesn't load in the editor, so show the default line on
	headings inside Kadence columns there too - the styles can then be compared. */

.editor-styles-wrapper .kt-inside-inner-col .wp-block-heading:not(.is-style-mh-line, .is-style-mh-no-line) {
	position: relative;
	padding-bottom: 10px;
}
.editor-styles-wrapper .kt-inside-inner-col .wp-block-heading:not(.is-style-mh-line, .is-style-mh-no-line)::after {
	content: "";
	position: absolute;
	bottom: 0;
	left: 0;
	width: 50%;
	height: 3px;
	border-radius: 2em;
	background-color: var(--global-palette1, #f4a582);
}
.editor-styles-wrapper .kt-inside-inner-col :is(h1, h2).wp-block-heading:not(.is-style-mh-line, .is-style-mh-no-line)::after {
	height: 5px;
}
