/* ==========================================================================
   Hero widget  (.aew-hero)
   Colours/spacing marked "control" are overridden by the widget's Style tab.
   ========================================================================== */

.aew-hero {
	--aew-accent: var(--aew-red);          /* control: Brand colour */
	--aew-accent-dark: var(--aew-red-dark);/* control: Brand colour — hover */
	--aew-gutter: 24px;                    /* control: Side gap */
	--aew-grid-color: rgba(255, 255, 255, 0.04);
	--aew-grid-size: 70px;
	--aew-divider: rgba(255, 255, 255, 0.14);
	--aew-sep: rgba(255, 255, 255, 0.2);

	position: relative;
	display: flex;
	flex-direction: column;
	justify-content: center;
	min-height: 100vh;
	padding: 110px 0 80px;
	overflow: hidden;
	isolation: isolate;
	box-sizing: border-box;
	background-color: var(--aew-ink);
	color: var(--aew-white);
	font-family: var(--aew-font);
	-webkit-font-smoothing: antialiased;
}

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

/* ---- Background layers ---- */

.aew-hero__media {
	position: absolute;
	inset: 0;
	z-index: -1;
}

.aew-hero__media picture {
	display: block;
	width: 100%;
	height: 100%;
}

.aew-hero__bg-img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
	object-position: center center;
}

.aew-hero__overlay {
	position: absolute;
	inset: 0;
	background-image: linear-gradient(90deg, rgba(6, 6, 7, 0.94) 0%, rgba(6, 6, 7, 0.2) 100%);
}

.aew-hero__grid {
	display: none;
	position: absolute;
	inset: 0;
	pointer-events: none;
	background-image:
		linear-gradient(to right, var(--aew-grid-color) 1px, transparent 1px),
		linear-gradient(to bottom, var(--aew-grid-color) 1px, transparent 1px);
	background-size: var(--aew-grid-size) var(--aew-grid-size);
}

.aew-hero--grid .aew-hero__grid {
	display: block;
}

.aew-hero__bar {
	display: none;
	position: absolute;
	top: 0;
	bottom: 0;
	left: 0;
	width: 3px;
	background: var(--aew-accent);
	opacity: 0.55;
}

.aew-hero--bar .aew-hero__bar {
	display: block;
}

/* ---- Content ---- */

.aew-hero__inner {
	position: relative;
	width: calc(100% - (var(--aew-gutter) * 2));
	max-width: 1076px;
	margin-inline: auto;
}

.aew-hero__eyebrow {
	display: flex;
	align-items: center;
	gap: 14px;
	margin: 0 0 22px;
	font-size: 11.2px;
	font-weight: 700;
	letter-spacing: 1.2px;
	line-height: 1.4;
	text-transform: uppercase;
}

.aew-hero__eyebrow-line {
	flex: none;
	display: block;
	width: 35px;
	height: 2px;
	background: var(--aew-accent);
}

.aew-hero__eyebrow-text {
	color: var(--aew-accent);
}

.aew-hero .aew-hero__title {
	margin: 0 0 16px;
	padding: 0;
	font-family: inherit;
	font-size: 62.4px;
	font-weight: 700;
	line-height: 1.12;
	letter-spacing: normal;
	text-transform: none;
}

.aew-hero__title-line,
.aew-hero__title-accent {
	display: block;
}

.aew-hero__title-line {
	color: #fff;
}

.aew-hero__title-accent {
	color: var(--aew-accent);
}

.aew-hero__subtitle {
	margin: 0 0 10px;
	font-size: 18.4px;
	font-weight: 400;
	line-height: 1.4;
	color: #f2f2f3;
}

.aew-hero__desc {
	max-width: 520px;
	margin: 0 0 34px;
	font-size: 12.25px;
	font-weight: 400;
	line-height: 1.7;
	color: var(--aew-muted);
}

/* ---- Buttons ---- */

.aew-hero__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 14px;
	margin: 0 0 56px;
}

.aew-hero__btn {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 15px 29px;
	border: 1px solid var(--aew-accent);
	border-radius: 0;
	font-size: 11.2px;
	font-weight: 700;
	letter-spacing: 1px;
	line-height: 1.2;
	text-transform: uppercase;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.aew-hero__btn--primary {
	background-color: var(--aew-accent);
	color: #fff;
}

.aew-hero__btn--primary:hover,
.aew-hero__btn--primary:focus-visible {
	background-color: var(--aew-accent-dark);
	border-color: var(--aew-accent-dark);
	color: #fff;
}

.aew-hero__btn--secondary {
	background-color: transparent;
	color: #fff;
}

.aew-hero__btn--secondary:hover,
.aew-hero__btn--secondary:focus-visible {
	background-color: var(--aew-accent);
	color: #fff;
}

.aew-hero__btn:focus-visible,
.aew-hero__scroll:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 3px;
}

.aew-hero__btn-icon {
	display: inline-flex;
	font-size: 11px;
	line-height: 1;
	transition: transform 0.2s ease;
}

.aew-hero__btn-icon i,
.aew-hero__btn-icon svg {
	width: 1em;
	height: 1em;
	fill: currentColor;
	color: inherit;
}

.aew-hero__btn--primary:hover .aew-hero__btn-icon {
	transform: translateX(3px);
}

/* ---- Stats ---- */

.aew-hero__stats-wrap {
	max-width: 782px;
	padding-top: 36px;
	border-top: 1px solid var(--aew-divider);
}

.aew-hero__stats {
	display: grid;
	grid-auto-flow: column;
	grid-auto-columns: 1fr;
	margin: 0;
	padding: 0;
	list-style: none;
}

.aew-hero__stat {
	min-width: 0;
	margin: 0;
	padding: 0 0 0 21px;
	border-left: 1px solid var(--aew-sep);
}

.aew-hero__stat:first-child {
	padding-left: 0;
	border-left: 0;
}

.aew-hero__stat-value,
.aew-hero__stat-label {
	display: block;
}

.aew-hero__stat-value {
	font-size: 14px;
	line-height: 1.4;
	color: #fff;
}

.aew-hero__stat-label {
	margin-top: 1px;
	font-size: 10.1px;
	font-weight: 700;
	letter-spacing: 0.8px;
	line-height: 1.4;
	text-transform: uppercase;
	color: var(--aew-accent);
}

/* ---- Scroll hint ---- */

.aew-hero .aew-hero__scroll {
	position: absolute;
	bottom: 20px;
	left: 50%;
	z-index: 2;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	margin: 0;
	padding: 6px 10px;
	border: 0;
	border-radius: 0;
	background: none;
	color: rgba(255, 255, 255, 0.65);
	cursor: pointer;
	transform: translateX(-50%);
	transition: color 0.2s ease;
}

.aew-hero .aew-hero__scroll:hover,
.aew-hero .aew-hero__scroll:focus-visible {
	background: none;
	color: #fff;
}

.aew-hero__scroll-text {
	font-family: Georgia, "Times New Roman", serif;
	font-size: 10px;
	letter-spacing: 3px;
	line-height: 1;
	text-transform: uppercase;
	/* letter-spacing adds space after the last letter; pull it back so the word sits centred over the chevron */
	margin-right: -3px;
}

.aew-hero__scroll-chevron {
	display: block;
	width: 8px;
	height: 8px;
	border-right: 1.5px solid currentColor;
	border-bottom: 1.5px solid currentColor;
	transform: rotate(45deg);
}

/* ---- Responsive ---- */

@media (max-width: 767px) {
	.aew-hero__stats {
		grid-auto-flow: row;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		row-gap: 24px;
	}

	/* two columns: separator only in front of the right-hand item of each row */
	.aew-hero__stat:nth-child(odd) {
		padding-left: 0;
		border-left: 0;
	}

	.aew-hero__stat:nth-child(even) {
		padding-left: 21px;
		border-left: 1px solid var(--aew-sep);
	}
}

@media (max-width: 480px) {
	.aew-hero__actions {
		flex-direction: column;
		align-items: stretch;
	}

	.aew-hero__btn {
		justify-content: center;
	}
}

@media (prefers-reduced-motion: reduce) {
	.aew-hero__btn,
	.aew-hero__btn-icon,
	.aew-hero .aew-hero__scroll {
		transition: none;
	}

	.aew-hero__btn--primary:hover .aew-hero__btn-icon {
		transform: none;
	}
}
