/**
 * MEMOT theme styles — products-page.
 *
 * The rich Products marketing page: hero + industries strip.
 * Split out of theme.css so it loads only on the template(s) that need it —
 * see memot_enqueue_assets() in functions.php. Reuses the same
 * theme.json custom properties and memot-* class hooks as theme.css.
 */

/* -------------------------------------------------------------------------- *
 * Products hero — one photographic panel with the headline overlaid on the
 * image, and a floating "reach" badge in place of a generic avatar stack:
 * the number this page can honestly show off is export markets, not client
 * logos. The corner accent traces the spiral cut of a tapped rubber trunk.
 * -------------------------------------------------------------------------- */

.memot-products-hero {
	background:
		radial-gradient(60% 70% at 14% 0%, rgba(46, 158, 92, 0.16) 0%, rgba(46, 158, 92, 0) 60%),
		radial-gradient(50% 60% at 100% 100%, rgba(201, 161, 90, 0.14) 0%, rgba(201, 161, 90, 0) 60%),
		var(--wp--preset--gradient--brand-soft, linear-gradient(180deg, #e9f2ea 0%, #f5f3ee 100%));
}

/*
 * Scope this selector to `.memot-products-hero` so it beats core's
 * `.has-global-padding > .alignfull` layout rule on specificity.
 * Core sets margin-left/right via calc(); otherwise a bare
 * single-class selector pins the panel left instead of centering it.
 */
.memot-products-hero .memot-products-hero__inner {
	max-width: 1560px;
	margin-inline: auto;
	padding-inline: clamp(1.25rem, 5vw, 3rem);
}

.memot-products-hero__stage {
	position: relative;
}

.memot-products-hero__panel {
	position: relative;
	overflow: hidden;
	display: flex;
	align-items: flex-end;
	min-height: clamp(320px, 42vh, 440px);
	border-radius: clamp(20px, 2vw, 28px);
	box-shadow: var(--memot-shadow-lg);
}

.memot-products-hero__photo {
	position: absolute;
	inset: 0;
	margin: 0;
}

.memot-products-hero__photo img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

/* Scrim: a brand-green fade from the text corner, not a generic black one. */
.memot-products-hero__panel::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	background: linear-gradient(115deg, rgba(9, 30, 18, 0.88) 0%, rgba(9, 30, 18, 0.5) 38%, rgba(9, 30, 18, 0) 68%);
}

/* The signature: a dashed line tracing a tapped trunk's spiral incision,
   ending in the drop of latex it releases. */
.memot-products-hero__panel::after {
	content: "";
	position: absolute;
	top: clamp(1.5rem, 4vw, 3rem);
	left: clamp(1.5rem, 4vw, 3.5rem);
	z-index: 1;
	width: 64px;
	height: 120px;
	opacity: 0.85;
	background-repeat: no-repeat;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 120'%3E%3Cpath d='M8 4c20 16 6 36 24 50s2 34 22 60' stroke='%23C9A15A' stroke-width='2' fill='none' stroke-linecap='round' stroke-dasharray='1 8'/%3E%3Ccircle cx='54' cy='114' r='4' fill='%23C9A15A'/%3E%3C/svg%3E");
}

.memot-products-hero__copy {
	position: relative;
	z-index: 2;
	max-width: 46ch;
	padding: clamp(1.5rem, 3vw, 2.25rem);
	color: var(--wp--preset--color--paper);
}

.memot-products-hero__copy h1 {
	max-width: 26ch;
	color: var(--wp--preset--color--paper);
}

.memot-products-hero__copy .memot-lead {
	max-width: 44ch;
	color: rgba(255, 255, 255, 0.88);
}

.memot-products-hero__copy .wp-block-buttons {
	margin-top: var(--wp--preset--spacing--50);
}

.memot-products-hero__copy .wp-block-button.is-style-outline .wp-block-button__link {
	background: transparent;
	color: var(--wp--preset--color--paper);
	border: 1.5px solid rgba(255, 255, 255, 0.45);
}

.memot-products-hero__copy .wp-block-button.is-style-outline .wp-block-button__link:hover {
	background: rgba(255, 255, 255, 0.12);
	border-color: var(--wp--preset--color--paper);
}

.memot-products-hero__badge {
	position: absolute;
	z-index: 3;
	right: clamp(1rem, 3vw, 2rem);
	bottom: clamp(-1.75rem, -1vw, -1.25rem);
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0.3rem;
	padding: 1.1rem 1.35rem;
	border-radius: var(--memot-radius);
	background: var(--wp--preset--color--ink);
	color: var(--wp--preset--color--paper);
	box-shadow: var(--memot-shadow-lg);
	animation: memot-badge-float 5s ease-in-out infinite;
}

.memot-products-hero__badge .memot-icon-chip {
	width: 40px;
	height: 40px;
	margin-bottom: 0.2rem;
	background: rgba(255, 255, 255, 0.12);
	color: var(--wp--preset--color--brand-bright);
}

.memot-products-hero__badge .memot-icon-chip svg {
	width: 20px;
	height: 20px;
}

.memot-products-hero__badge-num {
	margin: 0;
	font-family: var(--wp--preset--font-family--display);
	font-weight: 800;
	font-size: 2rem;
	line-height: 1;
}

.memot-products-hero__badge-label {
	margin: 0;
	font-size: 0.75rem;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: rgba(255, 255, 255, 0.7);
}

@keyframes memot-badge-float {

	0%,
	100% {
		transform: translateY(0);
	}

	50% {
		transform: translateY(-6px);
	}
}

.memot-products-hero__stats {
	margin-top: var(--wp--preset--spacing--70);
}

@media (max-width: 781px) {

	.memot-products-hero__panel {
		min-height: 360px;
	}

	.memot-products-hero__copy {
		max-width: 100%;
		padding: 1.25rem;
	}

	.memot-products-hero__copy h1 {
		max-width: 100%;
	}

	/*
	 * The floating corner card doesn't have room to overlay the copy once the
	 * buttons wrap to two lines on narrow screens, so it drops into normal
	 * flow below the panel instead (it's already last in source order).
	 */
	.memot-products-hero__badge {
		position: static;
		width: fit-content;
		margin: 1rem 0 0 auto;
		animation: none;
	}

	.memot-products-hero__panel::after {
		display: none;
	}
}

@media (prefers-reduced-motion: reduce) {

	.memot-products-hero__badge {
		animation: none;
	}
}

/* -------------------------------------------------------------------------- *
 * Industries — single-row divided strip ("Where it goes")
 * -------------------------------------------------------------------------- */

.memot-industry-row {
	display: flex;
	margin-top: var(--wp--preset--spacing--70);
	border-top: 1px solid var(--wp--preset--color--line);
	border-bottom: 1px solid var(--wp--preset--color--line);
}

.memot-industry-tile {
	position: relative;
	flex: 1 1 0;
	min-width: 0;
	padding: var(--wp--preset--spacing--60) var(--wp--preset--spacing--40);
	border-right: 1px solid var(--wp--preset--color--line);
	transition: background-color 0.25s var(--memot-ease-out);
}

.memot-industry-tile:last-child {
	border-right: 0;
}

.memot-industry-tile::after {
	content: "";
	position: absolute;
	bottom: -1px;
	left: 0;
	width: 100%;
	height: 3px;
	background: var(--wp--preset--color--harvest);
	transform: scaleX(0);
	transform-origin: left;
	transition: transform 0.3s var(--memot-ease-out);
}

.memot-industry-tile:hover,
.memot-industry-tile:focus-visible {
	background: var(--wp--preset--color--sand);
	outline: none;
}

.memot-industry-tile:hover::after,
.memot-industry-tile:focus-visible::after {
	transform: scaleX(1);
}

.memot-industry-tile .memot-icon-chip {
	width: 40px;
	height: 40px;
	margin-bottom: var(--wp--preset--spacing--40);
	transition: transform 0.2s var(--memot-ease-out), background-color 0.2s var(--memot-ease-out), color 0.2s var(--memot-ease-out);
}

.memot-industry-tile .memot-icon-chip svg {
	width: 20px;
	height: 20px;
}

.memot-industry-tile:hover .memot-icon-chip,
.memot-industry-tile:focus-visible .memot-icon-chip {
	background: var(--wp--preset--color--brand);
	color: var(--wp--preset--color--paper);
	transform: rotate(-6deg);
}

.memot-industry-tile__title {
	margin: 0 0 0.4rem;
	font-family: var(--wp--preset--font-family--display);
	font-size: var(--wp--preset--font-size--medium);
	line-height: 1.25;
}

.memot-industry-tile__text {
	display: -webkit-box;
	margin: 0;
	overflow: hidden;
	color: var(--wp--preset--color--slate);
	font-size: 0.8125rem;
	line-height: 1.5;
	-webkit-line-clamp: 4;
	-webkit-box-orient: vertical;
}

@media (max-width: 1100px) {

	.memot-industry-row {
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		scrollbar-width: thin;
		scrollbar-color: var(--wp--preset--color--brand-bright) transparent;
	}

	.memot-industry-tile {
		flex: 0 0 clamp(9.5rem, 32vw, 12rem);
		scroll-snap-align: start;
	}
}

@media (max-width: 480px) {

	.memot-industry-tile {
		flex-basis: clamp(8.5rem, 68vw, 10.5rem);
		padding: var(--wp--preset--spacing--50) var(--wp--preset--spacing--40);
	}
}

