/**
 * Opt-in styled heading — add class "dawnsol-styled-heading" to any h1–h6.
 */

.dawnsol-styled-heading {
	--ds-heading-accent: var(--dawnsol-color-green, #2f8364);
	--ds-heading-accent-light: var(--dawnsol-color-green-light, #3ecf9a);
	--ds-heading-color: var(--dawnsol-color-green-dark, #06140f);

	position: relative;
	display: block;
	width: fit-content;
	max-width: 100%;
	margin: 0 0 1rem;
	padding-bottom: 0.75rem;
	font-size: var(--dawnsol-section-heading-mobile, 28px);
	font-weight: 600;
	line-height: 1.12;
	letter-spacing: -0.035em;
	color: var(--ds-heading-color);
	text-transform: uppercase;
}

.dawnsol-styled-heading::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: 0;
	width: min(6rem, 42%);
	height: 3px;
	border-radius: 999px;
	background: linear-gradient(
		90deg,
		var(--ds-heading-accent) 0%,
		var(--ds-heading-accent-light) 70%,
		transparent 100%
	);
}

.dawnsol-styled-heading--center {
	width: 100%;
	margin-inline: auto;
	text-align: center;
}

.dawnsol-styled-heading--center::after {
	left: 50%;
	transform: translateX(-50%);
	width: min(5rem, 30%);
}

.dawnsol-styled-heading--light {
	--ds-heading-color: #fff;
}

.dawnsol-styled-heading--light::before {
	box-shadow: 0 0 24px rgba(62, 207, 154, 0.5);
}

@media (min-width: 641px) {
	.dawnsol-styled-heading {
		font-size: var(--dawnsol-section-heading-tablet, 36px);
	}
}

@media (min-width: 1025px) {
	.dawnsol-styled-heading {
		font-size: var(--dawnsol-section-heading-desktop, 46px);
	}
}
