/* ==========================================================================
   REPDOT Jazz home. Loaded only on pages using the Jazz template.
   Motion rules: transform and opacity only, paused when off-screen, and
   switched off for visitors who prefer reduced motion.
   ========================================================================== */

/* Section-by-section scrolling: gentle snap, desktop-sized screens only. */
@media (min-width: 900px) and (min-height: 620px) {
	html:has(body.is-jazz) {
		scroll-snap-type: y proximity;
		scroll-behavior: smooth;
	}
}

.is-jazz .site-main {
	display: block;
}

.jz {
	position: relative;
	display: flex;
	align-items: center;
	min-height: 100vh;
	min-height: 100svh;
	padding: 110px 0 96px;
	overflow: hidden;
	color: var(--rd-ink);
	background: var(--rd-white);
	scroll-snap-align: start;
	isolation: isolate;
}

.jz__inner {
	position: relative;
	z-index: 1;
}

.jz--soft { background: var(--rd-soft); }

.jz--dark,
.jz--band,
.jz--cta {
	color: var(--rd-white);
	background: linear-gradient(120deg, #1d0705 0%, #3d0f09 55%, #5a150c 100%);
}

.jz--accent {
	color: var(--rd-white);
	background: linear-gradient(135deg, var(--rd-primary-dark), var(--rd-accent));
}

.jz__title {
	max-width: 17em;
	margin: 0 0 0.45em;
	font-size: clamp(2rem, 3.6vw + 0.6rem, 3.75rem);
	line-height: 1.08;
	letter-spacing: -0.01em;
}

.jz__lead {
	max-width: 44em;
	margin: 0 0 2rem;
	font-size: clamp(1.05rem, 0.5vw + 0.95rem, 1.3rem);
	line-height: 1.6;
	opacity: 0.88;
}

.jz__tag {
	margin: 2.5rem 0 0;
	font-size: clamp(1.1rem, 1vw + 0.9rem, 1.5rem);
	font-weight: 500;
	color: var(--rd-primary);
}

/* ---------- Hero ---------- */
.jz--hero {
	color: var(--rd-white);
	background: linear-gradient(120deg, #1d0705 0%, #3d0f09 55%, #5a150c 100%);
	padding-top: 150px;
}

.jz-hero__media,
.jz-band__media {
	position: absolute;
	inset: 0;
	z-index: -1;
}

.jz-hero__zoom {
	position: absolute;
	inset: 0;
	transform-origin: 70% 44%;
	animation: jz-zoom 48s ease-in-out infinite alternate;
	will-change: transform;
}

.jz-hero__img,
.jz-hero-net {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
}

.jz-hero__img { object-fit: cover; object-position: center; }

.jz-hero__shade {
	position: absolute;
	inset: 0;
	background: linear-gradient(90deg, rgba(48, 11, 7, 0.86) 0%, rgba(66, 16, 9, 0.66) 55%, rgba(82, 20, 10, 0.4) 100%);
}

.jz-hero__title {
	max-width: 9em;
	margin: 0 0 0.35em;
	font-size: clamp(2.5rem, 5.6vw + 0.5rem, 5.25rem);
	line-height: 1.04;
	letter-spacing: -0.015em;
}

.jz-hero__sub {
	max-width: 36em;
	margin: 0 0 2.25rem;
	font-size: clamp(1.1rem, 0.7vw + 1rem, 1.4rem);
	line-height: 1.55;
	opacity: 0.92;
}

.jz-hero__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 20px 36px;
}

.jz-hero-net .jz-edges line { stroke: rgba(255, 205, 175, 0.2); stroke-width: 1; }
.jz-n { fill: #ffd9c2; animation: jz-twinkle var(--t, 4s) ease-in-out var(--d, 0s) infinite; }
.jz-p { fill: #ffe9dc; }
.jz-core { fill: #fff; transform-box: fill-box; transform-origin: center; animation: jz-core 2.4s ease-in-out infinite; }

.jz-r {
	fill: none;
	stroke: rgba(255, 190, 150, 0.55);
	stroke-width: 1.5;
	opacity: 0;
	transform-box: fill-box;
	transform-origin: center;
	animation: jz-ripple 7.2s ease-out var(--d, 0s) infinite;
}

@keyframes jz-zoom { to { transform: scale(1.07); } }
@keyframes jz-twinkle { 0%, 100% { opacity: 0.25; } 50% { opacity: 1; } }
@keyframes jz-core { 0%, 100% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.5); opacity: 0.7; } }
@keyframes jz-ripple { 0% { transform: scale(0.3); opacity: 0.7; } 100% { transform: scale(5.5); opacity: 0; } }

/* ---------- Next-section chevron ---------- */
.jz-next {
	position: absolute;
	left: 50%;
	bottom: 26px;
	z-index: 2;
	width: 40px;
	height: 40px;
	margin-left: -20px;
	border: 1px solid currentColor;
	border-radius: 50%;
	color: inherit;
	opacity: 0.55;
	transition: opacity 0.2s ease;
}

.jz-next::before {
	position: absolute;
	top: 12px;
	left: 14px;
	width: 10px;
	height: 10px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	content: "";
	transform: rotate(45deg);
	animation: jz-bob 2.2s ease-in-out infinite;
}

.jz-next:hover,
.jz-next:focus-visible { opacity: 1; }

@keyframes jz-bob { 0%, 100% { transform: translateY(0) rotate(45deg); } 50% { transform: translateY(5px) rotate(45deg); } }

/* ---------- Cards, steps, lists ---------- */
.jz-cards {
	display: grid;
	gap: 24px;
	margin: 0;
	padding: 0;
	list-style: none;
}

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

.jz-card {
	padding: 30px 28px;
	background: var(--rd-white);
	border: 1px solid var(--rd-line);
	border-radius: 12px;
	box-shadow: 0 24px 48px -32px rgba(0, 0, 0, 0.2);
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.jz--soft .jz-card { background: var(--rd-white); }

.jz-card:hover {
	transform: translateY(-4px);
	box-shadow: 0 30px 56px -30px rgba(0, 0, 0, 0.28);
}

.jz-card h3 { margin: 0 0 0.5em; font-size: 1.25rem; }
.jz-card p { margin: 0; color: var(--rd-muted); line-height: 1.6; }

.jz-card__more {
	display: inline-block;
	margin-top: 18px;
	font-weight: 500;
	color: var(--rd-primary);
	text-decoration: none;
}

.jz-card__more::after { content: " \2192"; }

.jz-steps {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 28px;
	margin: 2.5rem 0 0;
	padding: 0;
	list-style: none;
}

.jz-steps li {
	padding-top: 22px;
	border-top: 2px solid rgba(255, 190, 150, 0.35);
}

.jz-steps__n {
	display: block;
	margin-bottom: 14px;
	font-size: 2.4rem;
	font-weight: 300;
	line-height: 1;
	color: #ffb48f;
}

.jz-steps h3 { margin: 0 0 0.4em; font-size: 1.35rem; }
.jz-steps p { margin: 0; opacity: 0.85; line-height: 1.6; }

.jz-split {
	display: grid;
	grid-template-columns: 1.1fr 1fr;
	gap: 64px;
	align-items: center;
}

.jz-checks {
	margin: 0;
	padding: 0;
	list-style: none;
}

.jz-checks li {
	position: relative;
	margin: 0 0 16px;
	padding-left: 40px;
	font-size: 1.15rem;
	line-height: 1.5;
}

.jz-checks li::before {
	position: absolute;
	top: 2px;
	left: 0;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: rgba(255, 190, 150, 0.22);
	content: "";
}

.jz-checks li::after {
	position: absolute;
	top: 8px;
	left: 8px;
	width: 5px;
	height: 9px;
	border-right: 2px solid #ffb48f;
	border-bottom: 2px solid #ffb48f;
	content: "";
	transform: rotate(40deg);
}

.jz-checks--dark li::before { background: color-mix(in srgb, var(--rd-primary) 14%, #fff); }
.jz-checks--dark li::after { border-color: var(--rd-primary); }

.jz-leadbox {
	padding: 40px 36px;
	text-align: center;
	background: rgba(255, 255, 255, 0.12);
	border: 1px solid rgba(255, 255, 255, 0.3);
	border-radius: 16px;
}

.button--light { color: var(--rd-primary-dark); background: var(--rd-white); }
.button--light:hover { color: var(--rd-primary-dark); background: #fbeee8; }
.jz-leadbox__note { margin: 18px 0 0; font-size: 0.95rem; opacity: 0.85; }

.jz-proof { padding: 36px; background: var(--rd-soft); border-radius: 16px; }
.jz-proof__text { margin: 0 0 1.25rem; font-size: 1.2rem; line-height: 1.55; }
.jz-proof .link-arrow { color: var(--rd-primary); }
.jz-proof .link-arrow:hover { color: var(--rd-primary-dark); }

/* ---------- FAQ ---------- */
.jz-faq { max-width: 860px; }

.jz-faq__item {
	margin: 0 0 12px;
	background: var(--rd-white);
	border: 1px solid var(--rd-line);
	border-radius: 10px;
}

.jz-faq__item summary {
	padding: 20px 24px;
	font-size: 1.1rem;
	font-weight: 500;
	cursor: pointer;
}

.jz-faq__item p { margin: 0; padding: 0 24px 22px; color: var(--rd-muted); line-height: 1.65; }

/* ---------- Network band + flow diagram ---------- */
.jz--band { background: #1d0705; }

.jz-band__img {
	position: absolute;
	top: 0;
	left: 0;
	width: 115%;
	max-width: none;
	height: 100%;
	object-fit: cover;
	animation: jz-drift 70s linear infinite alternate;
	will-change: transform;
}

@keyframes jz-drift { to { transform: translateX(-13%); } }

.jz-flow { display: block; width: 100%; max-width: 1100px; margin: 24px auto 0; overflow: visible; }
.jz-flow__paths path { stroke: rgba(255, 190, 150, 0.4); stroke-width: 1.5; stroke-dasharray: 3 7; }
.jz-flow__hub { fill: var(--rd-primary); stroke: rgba(255, 225, 205, 0.7); stroke-width: 2; }
.jz-flow__hubtext { fill: #fff; font: 700 17px var(--rd-font); letter-spacing: 0.12em; }
.jz-flow__ring { fill: none; stroke: rgba(255, 190, 150, 0.55); stroke-width: 1.5; opacity: 0; transform-box: fill-box; transform-origin: center; animation: jz-ripple-s 4.8s ease-out infinite; }
.jz-flow__ring--2 { animation-delay: 2.4s; }
.jz-flow__src rect, .jz-flow__src,
.jz-flow__dest rect { fill: rgba(255, 255, 255, 0.09); stroke: rgba(255, 205, 175, 0.55); stroke-width: 1; }
.jz-flow__srctext, .jz-flow__dest text { fill: #fff; font: 500 17px var(--rd-font); }
.jz-flow__pulses circle { fill: #ffe3d0; }

@keyframes jz-ripple-s { 0% { transform: scale(1); opacity: 0.6; } 100% { transform: scale(2.6); opacity: 0; } }

/* ---------- CTA ---------- */
.jz-cta { text-align: center; }
.jz-cta .jz__title,
.jz-cta .jz__lead { margin-inline: auto; }

/* ---------- Section dots ---------- */
.jz-dots {
	position: fixed;
	top: 50%;
	right: 18px;
	z-index: 40;
	display: none;
	flex-direction: column;
	gap: 6px;
	padding: 10px 6px;
	background: rgba(24, 7, 5, 0.42);
	border-radius: 20px;
	transform: translateY(-50%);
}

.jz-dots button {
	position: relative;
	width: 22px;
	height: 22px;
	padding: 0;
	background: none;
	border: 0;
	cursor: pointer;
}

.jz-dots button::before {
	position: absolute;
	inset: 6px;
	border: 1.5px solid #fff;
	border-radius: 50%;
	content: "";
	transition: background-color 0.2s ease, transform 0.2s ease;
}

.jz-dots button[aria-current="true"]::before { background: #fff; transform: scale(1.25); }

.jz-dots button::after {
	position: absolute;
	top: 50%;
	right: 30px;
	padding: 6px 10px;
	font: 500 13px var(--rd-font);
	white-space: nowrap;
	color: #fff;
	background: rgba(24, 7, 5, 0.9);
	border-radius: 4px;
	content: attr(data-label);
	opacity: 0;
	pointer-events: none;
	transform: translateY(-50%);
	transition: opacity 0.15s ease;
}

.jz-dots button:hover::after,
.jz-dots button:focus-visible::after { opacity: 1; }

@media (min-width: 900px) {
	.jz-dots { display: flex; }
}

/* ---------- Reveal on scroll (only once JS is running) ---------- */
.jz-js [data-reveal] > * {
	opacity: 0;
	transform: translateY(26px);
	transition: opacity 0.6s ease, transform 0.6s ease;
}

.jz-js .jz.is-in [data-reveal] > * { opacity: 1; transform: none; }
.jz-js .jz.is-in [data-reveal] > :nth-child(2) { transition-delay: 0.1s; }
.jz-js .jz.is-in [data-reveal] > :nth-child(3) { transition-delay: 0.2s; }
.jz-js .jz.is-in [data-reveal] > :nth-child(4) { transition-delay: 0.3s; }
.jz-js .jz.is-in [data-reveal] > :nth-child(5) { transition-delay: 0.4s; }

.jz-js .jz-card.is-pending { transition-delay: 0s; }

/* Pause every animation in sections that are not on screen. */
.jz-js .jz:not(.is-in) *,
.jz-js .jz:not(.is-in) *::before { animation-play-state: paused !important; }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
	.jz-cards--4 { grid-template-columns: repeat(2, 1fr); }
	.jz-steps { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 899px) {
	.jz { min-height: 0; padding: 96px 0 84px; }
	.jz--hero { min-height: 100svh; padding-top: 130px; }
	.jz-split { grid-template-columns: 1fr; gap: 32px; }
	.jz-cards--3 { grid-template-columns: 1fr; }
	.jz-next { display: none; }
	.jz-hero__shade { background: linear-gradient(180deg, rgba(48, 11, 7, 0.82), rgba(66, 16, 9, 0.7)); }
	.jz-flow__srctext, .jz-flow__dest text, .jz-flow__hubtext { font-size: 22px; }
}

@media (max-width: 560px) {
	.jz-cards--4,
	.jz-steps { grid-template-columns: 1fr; }
}

/* ---------- Reduced motion: everything static ---------- */
@media (prefers-reduced-motion: reduce) {
	html:has(body.is-jazz) { scroll-behavior: auto; scroll-snap-type: none; }
	.jz-js [data-reveal] > * { opacity: 1; transform: none; transition: none; }
}

/* ---------- Polish: progress line, stats, source ring, hero parallax ---------- */
.jz-progress {
	position: fixed;
	inset: 0 0 auto 0;
	height: 3px;
	z-index: 60;
	background: var(--rd-accent, #c4260a);
	transform: scaleX(0);
	transform-origin: 0 50%;
	pointer-events: none;
	will-change: transform;
}

.jz-stats {
	display: flex;
	flex-wrap: wrap;
	gap: 14px 44px;
	margin: 1.8rem 0 0;
	padding: 0;
	list-style: none;
}

.jz-stats li { display: flex; flex-direction: column; gap: 2px; min-width: 7.5em; }
.jz-stats strong { font-size: clamp(2rem, 2.2vw + 1.2rem, 3rem); line-height: 1; font-weight: 700; color: var(--rd-primary); font-variant-numeric: tabular-nums; }
.jz-stats span { font-size: 0.95rem; opacity: 0.8; }

.jz-flow__srcring {
	fill: none;
	stroke: rgba(255, 200, 170, 0.7);
	stroke-width: 1.5;
	opacity: 0;
	transform-box: fill-box;
	transform-origin: center;
	pointer-events: none;
}

.jz-flow__src, .jz-flow__srctext { cursor: pointer; }
.jz-flow:hover .jz-flow__srcring,
.jz-flow:focus-within .jz-flow__srcring { animation: jz-srcpulse 1.6s ease-out infinite; }

@keyframes jz-srcpulse {
	0% { opacity: 0.8; transform: scale(1); }
	100% { opacity: 0; transform: scale(1.35, 1.9); }
}

.jz-hero-net { will-change: transform; }

@media (prefers-reduced-motion: reduce) {
	.jz-progress { display: none; }
	.jz-flow__srcring { animation: none !important; opacity: 0 !important; }
}

.jz-stats--big { gap: 20px 56px; margin-top: 2rem; }
.jz-stats--big strong { font-size: clamp(2.6rem, 4vw + 1rem, 5rem); }
.jz-stats--big span { font-size: 1.05rem; max-width: 14em; }
.jz-sample-badge {
	display: inline-block;
	margin: 0 0 0.5rem;
	padding: 6px 12px;
	border: 1px dashed var(--rd-primary);
	border-radius: 8px;
	font-size: 0.9rem;
	color: var(--rd-primary);
	background: rgba(196, 38, 10, 0.06);
}

/* ---------- Hub: processing matrix and orbits (opacity/transform only) ---------- */
.jz-flow__matrix circle { fill: #fff; opacity: 0.12; animation: jz-matrix 3.2s ease-in-out infinite; }
.jz-flow__orbit circle { fill: #ffe3d0; }
.jz-flow__orbit { transform-origin: 600px 230px; }
.jz-flow__orbit--a { animation: jz-spin 9s linear infinite; }
.jz-flow__orbit--b { animation: jz-spin 13s linear infinite reverse; opacity: 0.8; }
.jz-flow__hubtext { paint-order: stroke; stroke: var(--rd-primary); stroke-width: 5px; stroke-linejoin: round; }

@keyframes jz-matrix {
	0%, 100% { opacity: 0.1; }
	40% { opacity: 0.55; }
}
@keyframes jz-spin { to { transform: rotate(360deg); } }

/* Outgoing pulses read as "enriched": a little larger and brighter than the incoming ones. */
.jz-flow__pulses circle { fill: #ffe3d0; }

@media (prefers-reduced-motion: reduce) {
	.jz-flow__matrix circle, .jz-flow__orbit { animation: none !important; }
	.jz-flow__matrix circle { opacity: 0.4; }
}

.jz-leadbox__pdf { display: inline-block; margin: 14px 0 0 18px; color: #fff; font-weight: 600; text-decoration: underline; text-underline-offset: 4px; }
.jz-leadbox__pdf:hover, .jz-leadbox__pdf:focus-visible { text-decoration-thickness: 2px; }

/* Let the end of the page (copyright and scroll-to-top) be a snap target, so the
   footer can always be scrolled fully into view on the Jazz home page. */
.is-jazz .site-footer { scroll-snap-align: end; }
