/**
 * Inoforest Creator Hero
 *
 * Contents
 * 1. Variables and layout (split, centre; stacked below 992 px)
 * 2. Greeting, title, text
 * 3. Buttons
 * 4. Numbers
 * 5. Social links
 * 6. Image, frame shapes and the shape behind
 * 7. Cards
 * 8. Smaller screens, reduced motion
 *
 * Colours read the Design System (--inoforest-color-*) with fallbacks. Rules use two classes; the Style tab's controls
 * use three, so a choice in the panel always wins.
 */

/* 1. Variables and layout ------------------------------------------------------- */
.inoforest-creator-hero {
	--ino-ch-primary: var(--inoforest-color-primary, #0b7a75);
	--ino-ch-accent: var(--inoforest-color-accent, #ff6a3d);
	--ino-ch-heading: var(--inoforest-color-heading, #0d1b2a);
	--ino-ch-text: var(--inoforest-color-text, #5a6a79);
	--ino-ch-border: var(--inoforest-color-border, #e3e9ee);
	--ino-ch-light: color-mix(in srgb, var(--ino-ch-primary) 12%, #fff);
	--ino-ch-backdrop: var(--ino-ch-light);
	--ino-ch-radius: 26px;
	--ino-ch-image-width: 520px;
	display: grid;
	grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
	align-items: center;
	gap: var(--ino-ch-gap, 60px);
}

.inoforest-creator-hero[data-layout="center"] {
	grid-template-columns: minmax(0, 1fr);
	text-align: center;
}

/* 2. Greeting, title, text -------------------------------------------------------- */
.inoforest-creator-hero .inoforest-creator-hero__greeting {
	display: block;
	margin-bottom: 10px;
	font-family: "Caveat", cursive;
	font-size: 2rem;
	line-height: 1.1;
	color: var(--ino-ch-accent);
}

.inoforest-creator-hero .inoforest-creator-hero__title {
	margin: 0 0 0.55em;
}

.inoforest-creator-hero .inoforest-creator-hero__title span {
	font-style: italic;
	color: var(--ino-ch-primary);
}

.inoforest-creator-hero .inoforest-creator-hero__text {
	max-width: 560px;
	margin: 0;
	font-size: 1.15rem;
}

.inoforest-creator-hero[data-layout="center"] .inoforest-creator-hero__text {
	margin-inline: auto;
}

/* 3. Buttons ----------------------------------------------------------------------- */
.inoforest-creator-hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	margin: 32px 0 40px;
}

.inoforest-creator-hero .inoforest-creator-hero__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 10px;
	min-height: 54px;
	padding: 14px 30px;
	font-size: 0.975rem;
	font-weight: 700;
	line-height: 1.2;
	text-align: center;
	text-decoration: none;
	color: #fff;
	background-color: var(--ino-ch-primary);
	border: 2px solid var(--ino-ch-primary);
	border-radius: 999px;
	transition: color 0.3s ease, background-color 0.3s ease, border-color 0.3s ease;
}

.inoforest-creator-hero .inoforest-creator-hero__button:hover,
.inoforest-creator-hero .inoforest-creator-hero__button:focus-visible {
	color: #fff;
	background-color: color-mix(in srgb, var(--ino-ch-primary) 80%, #000);
	border-color: color-mix(in srgb, var(--ino-ch-primary) 80%, #000);
}

/* The second button is an outline, filled on hover. */
.inoforest-creator-hero .inoforest-creator-hero__button--2 {
	color: var(--ino-ch-heading);
	background-color: transparent;
	border-color: var(--ino-ch-border);
}

.inoforest-creator-hero__button svg,
.inoforest-creator-hero__button i {
	flex: none;
	font-size: 1em;
}

.inoforest-creator-hero__button svg {
	width: 1em;
	height: 1em;
	fill: currentColor;
}

/* 4. Numbers ------------------------------------------------------------------------- */
.inoforest-creator-hero .inoforest-creator-hero__stats {
	display: flex;
	flex-wrap: wrap;
	gap: 20px 36px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.inoforest-creator-hero .inoforest-creator-hero__stat {
	display: grid;
	margin: 0;
	padding: 0;
	padding-inline-end: 36px;
	border: 0 solid var(--ino-ch-border);
	border-inline-end-width: 1px;
}

.inoforest-creator-hero .inoforest-creator-hero__stat:last-child {
	padding: 0;
	border-width: 0;
}

.inoforest-creator-hero .inoforest-creator-hero__stat-value {
	font-family: var(--inoforest-font-heading-family, inherit);
	font-size: 2.2rem;
	font-weight: 600;
	line-height: 1.1;
	color: var(--ino-ch-heading);
}

.inoforest-creator-hero .inoforest-creator-hero__stat-label {
	font-size: 0.9rem;
	color: var(--ino-ch-text);
}

/* 5. Social links ------------------------------------------------------------------------ */
.inoforest-creator-hero__social {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
	margin-top: 30px;
}

.inoforest-creator-hero .inoforest-creator-hero__social-label {
	font-weight: 600;
	color: var(--ino-ch-heading);
}

.inoforest-creator-hero .inoforest-creator-hero__social-link {
	display: grid;
	place-items: center;
	width: 42px;
	height: 42px;
	font-size: 19px;
	line-height: 1;
	color: var(--ino-ch-heading);
	text-decoration: none;
	background-color: #fff;
	border: 1px solid var(--ino-ch-border);
	border-radius: 50%;
	transition: color 0.3s ease, background-color 0.3s ease, border-color 0.3s ease;
}

.inoforest-creator-hero .inoforest-creator-hero__social-link:hover,
.inoforest-creator-hero .inoforest-creator-hero__social-link:focus-visible {
	color: #fff;
	background-color: var(--ino-ch-primary);
	border-color: var(--ino-ch-primary);
}

.inoforest-creator-hero__social-link svg {
	width: 1em;
	height: 1em;
	fill: currentColor;
}

.inoforest-creator-hero[data-layout="center"] :is(.inoforest-creator-hero__actions, .inoforest-creator-hero__stats, .inoforest-creator-hero__social) {
	justify-content: center;
}

/* 6. Image -------------------------------------------------------------------------------- */
.inoforest-creator-hero__media {
	position: relative;
	justify-self: center;
	width: min(var(--ino-ch-image-width), 100%);
}

.inoforest-creator-hero[data-layout="center"] .inoforest-creator-hero__media {
	order: -1;
	width: min(var(--ino-ch-image-width), 70%);
}

/* The shape behind: the frame's form, set off down and to the outer side. */
.inoforest-creator-hero[data-backdrop="true"] .inoforest-creator-hero__media::before {
	content: "";
	position: absolute;
	inset-block: 6% -4%;
	inset-inline: 10% -8%;
	background: var(--ino-ch-backdrop);
	border-radius: 999px 999px var(--ino-ch-radius) var(--ino-ch-radius);
}

.inoforest-creator-hero .inoforest-creator-hero__frame {
	position: relative;
	aspect-ratio: 4 / 5;
	overflow: hidden;
	background-color: color-mix(in srgb, var(--ino-ch-accent) 10%, #fff);
	border-radius: 999px 999px var(--ino-ch-radius) var(--ino-ch-radius);
}

.inoforest-creator-hero .inoforest-creator-hero__frame img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
}

.inoforest-creator-hero[data-shape="rounded"] .inoforest-creator-hero__frame,
.inoforest-creator-hero[data-shape="rounded"] .inoforest-creator-hero__media::before {
	border-radius: var(--ino-ch-radius);
}

.inoforest-creator-hero[data-shape="circle"] .inoforest-creator-hero__frame,
.inoforest-creator-hero[data-shape="circle"] .inoforest-creator-hero__media::before {
	aspect-ratio: 1;
	border-radius: 50%;
}

.inoforest-creator-hero[data-shape="circle"] .inoforest-creator-hero__media::before {
	inset: -4%;
}

/* 7. Cards ----------------------------------------------------------------------------------- */
.inoforest-creator-hero .inoforest-creator-hero__card {
	position: absolute;
	display: flex;
	align-items: center;
	gap: 12px;
	max-width: 290px;
	padding-block: 12px;
	padding-inline: 12px 18px;
	color: var(--ino-ch-text);
	text-align: start;
	text-decoration: none;
	background-color: #fff;
	border-radius: 16px;
	box-shadow: 0 18px 44px rgba(13, 27, 42, 0.12);
}

.inoforest-creator-hero__card--top-end {
	inset-block-start: 10%;
	inset-inline-end: -10%;
}

.inoforest-creator-hero__card--top-start {
	inset-block-start: 10%;
	inset-inline-start: -10%;
}

.inoforest-creator-hero__card--bottom-start {
	inset-block-end: 9%;
	inset-inline-start: -14%;
}

.inoforest-creator-hero__card--bottom-end {
	inset-block-end: 9%;
	inset-inline-end: -14%;
}

.inoforest-creator-hero .inoforest-creator-hero__badge {
	display: grid;
	flex: none;
	place-items: center;
	width: 60px;
	height: 60px;
	font-family: var(--inoforest-font-heading-family, inherit);
	font-size: 1.15rem;
	font-weight: 700;
	letter-spacing: -0.02em;
	color: #fff;
	background-color: var(--ino-ch-accent);
	border-radius: 50%;
}

.inoforest-creator-hero__thumb {
	position: relative;
	display: block;
	flex: none;
	width: 74px;
	aspect-ratio: 1;
	overflow: hidden;
	border-radius: 10px;
}

.inoforest-creator-hero .inoforest-creator-hero__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
}

.inoforest-creator-hero__play {
	position: absolute;
	inset: 0;
	display: grid;
	place-items: center;
	font-size: 26px;
	line-height: 1;
	color: #fff;
	background: color-mix(in srgb, var(--ino-ch-heading) 35%, transparent);
}

.inoforest-creator-hero__play svg {
	width: 1em;
	height: 1em;
	fill: currentColor;
}

.inoforest-creator-hero__card-body {
	min-width: 0;
}

.inoforest-creator-hero .inoforest-creator-hero__card-label {
	display: block;
	font-size: 0.75rem;
	font-weight: 700;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--ino-ch-primary);
}

.inoforest-creator-hero .inoforest-creator-hero__card-title {
	display: block;
	font-weight: 700;
	line-height: 1.3;
	color: var(--ino-ch-heading);
	overflow-wrap: anywhere;
	transition: color 0.3s ease;
}

.inoforest-creator-hero a.inoforest-creator-hero__card:hover .inoforest-creator-hero__card-title,
.inoforest-creator-hero a.inoforest-creator-hero__card:focus-visible .inoforest-creator-hero__card-title {
	color: var(--ino-ch-primary);
}

.inoforest-creator-hero .inoforest-creator-hero__card-meta {
	display: block;
	font-size: 0.8rem;
	color: var(--ino-ch-text);
}

/* 8. Smaller screens, reduced motion ------------------------------------------------------------ */
@media (max-width: 1199px) {
	.inoforest-creator-hero {
		gap: var(--ino-ch-gap, 40px);
	}

	.inoforest-creator-hero__card--bottom-start,
	.inoforest-creator-hero__card--top-start {
		inset-inline-start: -6%;
	}

	.inoforest-creator-hero__card--top-end,
	.inoforest-creator-hero__card--bottom-end {
		inset-inline-end: -4%;
	}
}

@media (max-width: 991px) {
	.inoforest-creator-hero {
		grid-template-columns: minmax(0, 1fr);
	}

	.inoforest-creator-hero__media {
		width: min(var(--ino-ch-image-width), 86%);
	}
}

@media (max-width: 767px) {
	.inoforest-creator-hero .inoforest-creator-hero__stats {
		gap: 16px 20px;
	}

	.inoforest-creator-hero .inoforest-creator-hero__stat:not(:last-child) {
		padding: 0;
		border-width: 0;
	}

	.inoforest-creator-hero .inoforest-creator-hero__stat-value {
		font-size: 1.7rem;
	}

	.inoforest-creator-hero .inoforest-creator-hero__card {
		max-width: 230px;
		padding-block: 10px;
	}

	.inoforest-creator-hero__thumb {
		width: 56px;
	}

	.inoforest-creator-hero__card--bottom-start,
	.inoforest-creator-hero__card--top-start {
		inset-inline-start: -8%;
	}

	.inoforest-creator-hero__card--top-end,
	.inoforest-creator-hero__card--bottom-end {
		inset-inline-end: -8%;
	}
}

@media (prefers-reduced-motion: reduce) {
	.inoforest-creator-hero .inoforest-creator-hero__button,
	.inoforest-creator-hero .inoforest-creator-hero__social-link,
	.inoforest-creator-hero .inoforest-creator-hero__card-title {
		transition: none;
	}
}
