/**
 * Flowmez homepage sections.
 * Scoped to .flowmez-home so nothing leaks onto other pages.
 * Tokens, .fz-container and the footer live in flowmez-base.css.
 */

/* Let the template run edge to edge inside GeneratePress' wrappers.
   functions.php already strips .grid-container/.container from #page;
   these rules are the safety net for every GP container mode. */
.flowmez-home #page,
.flowmez-home #page.grid-container,
.flowmez-home #content,
.flowmez-home .site-content,
.flowmez-home .content-area,
.flowmez-home .site-main,
.flowmez-home .entry-content {
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0;
	border: 0;
}

/* GP switches .site-content to flex in some layout modes. */
.flowmez-home .site-content {
	display: block;
}

/* Boxed / one-container modes add their own background and shadow. */
.flowmez-home #page,
.flowmez-home .site-content,
.flowmez-home .site-main {
	background: none;
	box-shadow: none;
}

.flowmez-home .fz-page {
	font-family: var(--fz-font-body);
	color: var(--fz-text);
	background: var(--fz-bg);
	line-height: 1.65;
}

.flowmez-home .fz-page > * {
	width: 100%;
}

.flowmez-home .fz-page h1,
.flowmez-home .fz-page h2,
.flowmez-home .fz-page h3 {
	font-family: var(--fz-font-head);
	color: var(--fz-text);
	line-height: 1.2;
	margin: 0;
}

.flowmez-home .fz-page p {
	margin: 0;
}

.flowmez-home .fz-page ul,
.flowmez-home .fz-page ol {
	list-style: none;
	margin: 0;
	padding: 0;
}

.fz-text-primary {
	color: var(--fz-primary);
}


/* ---------- Shared section furniture ---------- */

.fz-section {
	padding: 84px 0;
}

.fz-section--alt {
	background: var(--fz-alt);
}

.fz-section__head {
	text-align: center;
	max-width: 660px;
	margin: 0 auto 48px;
}

.fz-section__title {
	font-size: clamp(28px, 3.4vw, 38px);
	font-weight: 700;
}

.fz-section__title--left {
	text-align: left;
	margin-bottom: 26px;
}

.fz-grid {
	display: grid;
	gap: 26px;
}

.fz-grid--3 {
	grid-template-columns: repeat(3, 1fr);
}

.fz-grid--6 {
	grid-template-columns: repeat(6, 1fr);
	gap: 18px;
}


/* ---------- Buttons & links ---------- */

.fz-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 9px;
	padding: 13px 24px;
	border-radius: 10px;
	font-family: var(--fz-font-body);
	font-size: 15px;
	font-weight: 600;
	text-decoration: none;
	border: 1px solid transparent;
	cursor: pointer;
	transition: background-color .18s ease, color .18s ease, border-color .18s ease, transform .18s ease;
}

.fz-btn:hover {
	transform: translateY(-1px);
}

.fz-btn--primary {
	background: var(--fz-primary);
	color: #fff;
}

.fz-btn--primary:hover,
.fz-btn--primary:focus {
	background: var(--fz-primary-dark);
	color: #fff;
}

.fz-btn--ghost {
	background: #fff;
	color: var(--fz-text);
	border-color: var(--fz-border);
}

.fz-btn--ghost:hover,
.fz-btn--ghost:focus {
	border-color: var(--fz-primary);
	color: var(--fz-primary-dark);
}

.fz-btn--white {
	background: #fff;
	color: var(--fz-primary-dark);
	flex-shrink: 0;
}

.fz-btn--white:hover,
.fz-btn--white:focus {
	background: #eff6ff;
	color: var(--fz-primary-dark);
}

.fz-link {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	font-size: 14px;
	font-weight: 600;
	color: var(--fz-primary);
	text-decoration: none;
}

.fz-link:hover svg,
.fz-btn:hover .fz-btn__arrow {
	transform: translateX(3px);
}

.fz-link svg,
.fz-btn__arrow {
	transition: transform .18s ease;
}


/* ---------- Icon chips ---------- */

.fz-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	border-radius: 11px;
	flex-shrink: 0;
}

.fz-icon--lg {
	width: 52px;
	height: 52px;
	border-radius: 13px;
}

.fz-icon--round {
	width: 62px;
	height: 62px;
	border-radius: 50%;
}

.fz-icon--blue   { background: #dbeafe; color: #2563eb; }
.fz-icon--green  { background: #d1fae5; color: #059669; }
.fz-icon--purple { background: #ede9fe; color: #7c3aed; }
.fz-icon--orange { background: #ffedd5; color: #ea580c; }
.fz-icon--amber  { background: #fef3c7; color: #d97706; }
.fz-icon--rose   { background: #ffe4e6; color: #e11d48; }
.fz-icon--sky    { background: #e0f2fe; color: #0284c7; }


/* ---------- Placeholders ---------- */

.fz-placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	aspect-ratio: 4 / 3;
	background: repeating-linear-gradient(45deg, #f1f5f9, #f1f5f9 12px, #e8eef6 12px, #e8eef6 24px);
	border: 1px dashed #cbd5e1;
	border-radius: var(--fz-radius);
	color: #94a3b8;
	font-size: 13px;
	text-align: center;
	padding: 16px;
}

.fz-placeholder--wide {
	aspect-ratio: 16 / 9;
	border-radius: 0;
	border: 0;
}


/* ---------- Section 1: Hero ---------- */

.fz-hero {
	position: relative;
	padding: 78px 0 48px;
	overflow: hidden;
}

.fz-hero__bg {
	position: absolute;
	top: -180px;
	right: -160px;
	width: 900px;
	height: 720px;
	background: radial-gradient(circle at 40% 45%, #eff6ff 0%, #f5f9ff 55%, rgba(255, 255, 255, 0) 72%);
	border-radius: 50%;
	pointer-events: none;
}

.fz-hero__inner {
	position: relative;
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 56px;
	align-items: center;
}

.fz-hero__title {
	font-size: clamp(36px, 5vw, 54px);
	font-weight: 800;
	letter-spacing: -.02em;
	margin-bottom: 22px;
}

.fz-hero__text {
	color: var(--fz-muted);
	font-size: 16.5px;
	max-width: 470px;
}

.fz-hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	margin-top: 32px;
}

.fz-hero__image {
	width: 100%;
	height: auto;
	display: block;
}


/* ---------- Section 2: Trusted By / Stats ---------- */

.fz-stats {
	padding-bottom: 20px;
}

.fz-stats__card {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 20px;
	background: #fff;
	border: 1px solid var(--fz-border);
	border-radius: 16px;
	box-shadow: var(--fz-shadow);
	padding: 26px 30px;
}

.fz-stat {
	display: flex;
	align-items: center;
	gap: 14px;
}

.fz-stat + .fz-stat {
	border-left: 1px solid var(--fz-border);
	padding-left: 20px;
}

.fz-stat__text {
	display: flex;
	flex-direction: column;
	line-height: 1.3;
}

.fz-stat__value {
	font-family: var(--fz-font-head);
	font-size: 24px;
	font-weight: 700;
}

.fz-stat__label {
	font-size: 13.5px;
	color: var(--fz-muted);
}


/* ---------- Section 3: What You'll Learn ---------- */

.fz-card {
	background: #fff;
	border: 1px solid var(--fz-border);
	border-radius: var(--fz-radius);
	padding: 30px 28px;
	transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}

.fz-card:hover {
	box-shadow: var(--fz-shadow);
	border-color: #cbd5e1;
	transform: translateY(-3px);
}

.fz-card__title {
	font-size: 18px;
	font-weight: 600;
	margin: 20px 0 10px;
}

.fz-card__title a {
	color: var(--fz-text);
	text-decoration: none;
}

.fz-card__title a:hover {
	color: var(--fz-primary-dark);
}

.fz-card__text {
	color: var(--fz-muted);
	font-size: 14.5px;
}


/* ---------- Section 4: Featured Categories ---------- */

.fz-cat {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
	text-align: center;
	padding: 26px 14px;
	border-radius: var(--fz-radius);
	text-decoration: none;
	transition: transform .2s ease, box-shadow .2s ease;
}

.fz-cat:hover {
	transform: translateY(-4px);
	box-shadow: var(--fz-shadow);
}

.fz-cat__icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	border-radius: 12px;
	background: rgba(255, 255, 255, .75);
}

.fz-cat__title {
	font-family: var(--fz-font-head);
	font-size: 14px;
	font-weight: 600;
	color: var(--fz-text);
}

.fz-cat--blue   { background: #eff6ff; } .fz-cat--blue   .fz-cat__icon { color: #2563eb; }
.fz-cat--green  { background: #ecfdf5; } .fz-cat--green  .fz-cat__icon { color: #059669; }
.fz-cat--amber  { background: #fffbeb; } .fz-cat--amber  .fz-cat__icon { color: #d97706; }
.fz-cat--purple { background: #f5f3ff; } .fz-cat--purple .fz-cat__icon { color: #7c3aed; }
.fz-cat--rose   { background: #fff1f2; } .fz-cat--rose   .fz-cat__icon { color: #e11d48; }
.fz-cat--sky    { background: #f0f9ff; } .fz-cat--sky    .fz-cat__icon { color: #0284c7; }


/* ---------- Section 5: Latest Articles ---------- */

.fz-post {
	background: #fff;
	border: 1px solid var(--fz-border);
	border-radius: var(--fz-radius);
	overflow: hidden;
	display: flex;
	flex-direction: column;
	transition: box-shadow .2s ease, transform .2s ease;
}

.fz-post:hover {
	box-shadow: var(--fz-shadow);
	transform: translateY(-3px);
}

.fz-post__media {
	display: block;
	line-height: 0;
	background: #f1f5f9;
}

.fz-post__media img {
	width: 100%;
	height: 210px;
	object-fit: cover;
	display: block;
}

.fz-post__body {
	padding: 22px 22px 24px;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	flex: 1;
}

.fz-post__title {
	font-size: 17px;
	font-weight: 600;
	margin-bottom: 10px;
}

.fz-post__title a {
	color: var(--fz-text);
	text-decoration: none;
}

.fz-post__title a:hover {
	color: var(--fz-primary-dark);
}

.fz-post__excerpt {
	color: var(--fz-muted);
	font-size: 14px;
	margin-bottom: 16px;
	flex: 1;
}

.fz-empty {
	text-align: center;
	color: var(--fz-muted);
}


/* ---------- Section 6: Why Flowmez ---------- */

.fz-why__inner {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 56px;
	align-items: center;
}

.fz-why__list {
	display: flex;
	flex-direction: column;
	gap: 15px;
}

.fz-why__list li {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 15.5px;
	font-weight: 500;
	color: #334155;
}

.fz-check {
	flex-shrink: 0;
}

.fz-why__image {
	width: 100%;
	height: auto;
	display: block;
}


/* ---------- Section 7: Simple Process ---------- */

.fz-steps__list {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	align-items: start;
	gap: 52px;
}

.fz-step {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	gap: 8px;
}

.fz-step__label {
	margin-top: 8px;
	font-size: 12px;
	font-weight: 700;
	letter-spacing: .12em;
	text-transform: uppercase;
	color: var(--fz-primary);
}

.fz-step__title {
	font-size: 18px;
	font-weight: 600;
}

/* Arrow sits in the gap between two steps. */
.fz-step__arrow {
	position: absolute;
	right: -39px;
	top: 18px;
	display: flex;
	color: #cbd5e1;
}


/* ---------- Section 8: Newsletter ---------- */

.fz-newsletter-wrap {
	padding: 0 0 84px;
}

.fz-newsletter {
	display: flex;
	align-items: center;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 32px;
	background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
	border-radius: 18px;
	padding: 42px 46px;
	color: #fff;
}

.fz-newsletter__copy {
	display: flex;
	align-items: center;
	gap: 22px;
	max-width: 560px;
}

.fz-newsletter__icon {
	flex-shrink: 0;
	display: flex;
}

.fz-newsletter__title {
	font-size: 24px;
	font-weight: 700;
	color: #fff;
	margin-bottom: 8px;
}

.fz-newsletter__text {
	font-size: 14.5px;
	color: rgba(255, 255, 255, .88);
}

.fz-newsletter__note {
	font-size: 13px;
	color: rgba(255, 255, 255, .8);
}


/* ---------- WPForms inside the newsletter band ----------
   WPForms ships its own stylesheet; these rules reshape it into the
   inline input + white button from the design. The !important flags
   are needed to win against WPForms' own selectors. */

.fz-newsletter .wpforms-container,
.fz-newsletter .wpforms-container-full {
	margin: 0 !important;
	max-width: 100%;
}

.fz-newsletter .wpforms-form {
	display: flex;
	align-items: flex-start;
	gap: 10px;
}

.fz-newsletter .wpforms-field-container {
	flex: 1;
	min-width: 260px;
}

.fz-newsletter .wpforms-field {
	padding: 0 !important;
	margin: 0 !important;
}

/* Keep the label for screen readers, hide it visually. */
.fz-newsletter .wpforms-field-label,
.fz-newsletter .wpforms-field-sublabel,
.fz-newsletter .wpforms-field-description {
	position: absolute !important;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Input and button share one fixed height with border-box sizing, so the
   input's border can't make it taller than the borderless button. */
.fz-newsletter .wpforms-form input[type="email"],
.fz-newsletter .wpforms-form input[type="text"],
.fz-newsletter .wpforms-form button[type="submit"] {
	box-sizing: border-box !important;
	height: 50px !important;
	min-height: 50px !important;
	line-height: normal !important;
	margin: 0 !important;
}

.fz-newsletter .wpforms-form input[type="email"],
.fz-newsletter .wpforms-form input[type="text"] {
	width: 100% !important;
	max-width: 100% !important;
	padding: 0 16px !important;
	border-radius: 10px !important;
	border: 1px solid rgba(255, 255, 255, .35) !important;
	background: #fff !important;
	color: var(--fz-text) !important;
	font-family: var(--fz-font-body) !important;
	font-size: 14.5px !important;
	box-shadow: none !important;
}

.fz-newsletter .wpforms-form input::placeholder {
	color: #94a3b8;
}

.fz-newsletter .wpforms-form input:focus {
	outline: 2px solid rgba(255, 255, 255, .85) !important;
	outline-offset: 1px;
}

.fz-newsletter .wpforms-submit-container {
	padding: 0 !important;
	margin: 0 !important;
}

.fz-newsletter .wpforms-form button[type="submit"] {
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	padding: 0 28px !important;
	border: 1px solid transparent !important;
	border-radius: 10px !important;
	background: #fff !important;
	color: var(--fz-primary-dark) !important;
	font-family: var(--fz-font-body) !important;
	font-size: 15px !important;
	font-weight: 600 !important;
	line-height: 1.4 !important;
	cursor: pointer;
	transition: background-color .18s ease, transform .18s ease;
}

.fz-newsletter .wpforms-form button[type="submit"]:hover {
	background: #eff6ff !important;
	transform: translateY(-1px);
}

/* Validation + confirmation messages need to read on the blue band. */
.fz-newsletter .wpforms-form label.wpforms-error,
.fz-newsletter .wpforms-form .wpforms-error-container {
	color: #fff !important;
	background: rgba(15, 23, 42, .28);
	border-radius: 8px;
	padding: 6px 10px;
	margin-top: 8px !important;
	font-size: 13px;
}

.fz-newsletter .wpforms-confirmation-container-full,
.fz-newsletter .wpforms-confirmation-container {
	background: rgba(255, 255, 255, .16) !important;
	border: 1px solid rgba(255, 255, 255, .3) !important;
	border-radius: 10px;
	color: #fff !important;
	margin: 0 !important;
	padding: 14px 18px !important;
}

.fz-newsletter .wpforms-confirmation-container p {
	color: #fff !important;
	margin: 0 !important;
}


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

@media (max-width: 1024px) {

	.fz-grid--6 {
		grid-template-columns: repeat(3, 1fr);
	}

	.fz-stats__card {
		grid-template-columns: repeat(2, 1fr);
		row-gap: 24px;
	}

	.fz-stat + .fz-stat {
		border-left: 0;
		padding-left: 0;
	}

	.fz-stat:nth-child(2n) {
		border-left: 1px solid var(--fz-border);
		padding-left: 20px;
	}
}

@media (max-width: 900px) {

	.fz-section {
		padding: 60px 0;
	}

	.fz-hero {
		padding-top: 52px;
		text-align: center;
	}

	.fz-hero__inner,
	.fz-why__inner {
		grid-template-columns: 1fr;
		gap: 40px;
	}

	.fz-hero__text {
		margin-left: auto;
		margin-right: auto;
	}

	.fz-hero__actions {
		justify-content: center;
	}

	.fz-hero__media,
	.fz-why__media {
		max-width: 520px;
		margin: 0 auto;
	}

	.fz-grid--3 {
		grid-template-columns: repeat(2, 1fr);
	}

	.fz-steps__list {
		grid-template-columns: 1fr;
		gap: 34px;
		max-width: 420px;
		margin: 0 auto;
	}

	/* Doc shows the steps stacked with a downward arrow on mobile. */
	.fz-step__arrow {
		right: auto;
		top: auto;
		bottom: -30px;
		left: 50%;
		transform: translateX(-50%) rotate(90deg);
	}

	.fz-newsletter {
		padding: 34px 28px;
		flex-direction: column;
		align-items: flex-start;
	}

	.fz-newsletter__form {
		width: 100%;
	}

	.fz-newsletter .wpforms-field-container {
		min-width: 0;
	}
}

@media (max-width: 640px) {

	.fz-section {
		padding: 48px 0;
	}

	.fz-grid--3,
	.fz-grid--6,
	.fz-stats__card {
		grid-template-columns: 1fr;
	}

	.fz-stat + .fz-stat,
	.fz-stat:nth-child(2n) {
		border-left: 0;
		padding-left: 0;
	}

	.fz-newsletter__copy {
		flex-direction: column;
		align-items: flex-start;
		gap: 16px;
	}

	.fz-newsletter .wpforms-form {
		flex-direction: column;
		align-items: stretch;
	}

	.fz-newsletter .wpforms-form button[type="submit"] {
		width: 100%;
	}
}
