/* ==========================================================================
   PayTHOR product visuals (inc/visuals/*.php)
   Shared UI primitives first, then one block per visual.

   Motion contract (assets/js/site.js):
   - .is-inview   added once when the visual first enters the viewport;
                  drives staged entrances (.ptr-step, delay = --s).
   - .is-playing  present while the visual is on screen; loops pause
                  otherwise. Without JS everything is visible and static
                  entrances are skipped. Reduced motion stops all loops.
   ========================================================================== */

.ptr-visual {
	position: relative;
	margin: 0;
	color: var(--ptr-text);
	font-size: 0.875rem;
	line-height: 1.4;
}

.ptr-visual *,
.ptr-visual *::before,
.ptr-visual *::after {
	box-sizing: border-box;
}

.ptr-visual ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

.ptr-visual code {
	font-family: var(--wp--preset--font-family--mono);
}

.ptr-js .ptr-visual:not(.is-playing),
.ptr-js .ptr-visual:not(.is-playing) * {
	animation-play-state: paused !important;
}

/* Staged entrance */
@media (prefers-reduced-motion: no-preference) {
	.ptr-js .ptr-visual:not(.is-inview) .ptr-step {
		opacity: 0;
		transform: translate3d(0, 0.75rem, 0);
	}

	.ptr-js .ptr-visual .ptr-step {
		transition:
			opacity 0.55s var(--ptr-ease) calc(var(--s, 0) * 140ms + 100ms),
			transform 0.7s var(--ptr-ease) calc(var(--s, 0) * 140ms + 100ms);
	}
}

/* ---------- Primitives ---------- */
.ptr-ui-card {
	position: relative;
	padding: 1rem 1.1rem;
	border: 1px solid var(--ptr-line);
	border-radius: var(--ptr-radius);
	background: #fff;
	box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset, var(--ptr-shadow);
}

.ptr-ui-label {
	display: flex;
	align-items: center;
	gap: 0.4rem;
	color: var(--ptr-muted);
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.6875rem;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
}

.ptr-ui-label .ptr-i {
	color: var(--ptr-emerald);
	font-size: 1.05rem;
}

.ptr-ui-field {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	padding: 0.6rem 0.75rem;
	border: 1px solid var(--wp--preset--color--slate-200);
	border-radius: 0.6rem;
	background: #fff;
	color: var(--ptr-ink);
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.75rem;
	letter-spacing: 0.04em;
}

.ptr-ui-field > span {
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.ptr-ui-field--split {
	justify-content: space-between;
	color: var(--ptr-muted);
}

.ptr-network {
	width: auto;
	height: 1rem;
	border-radius: 0 !important;
}

.ptr-mock-logo {
	display: block;
	width: auto;
	max-width: 100%;
	height: 1.1rem;
	border-radius: 0 !important;
	filter: brightness(0);
	opacity: 0.74;
}

/* Official full-colour provider logos (paythor/visual option "color"): shown
   as supplied, with no tint or transparency. --ptr-mock-k (inline) scales the
   height so each logo keeps the visual weight of the mark the slot was drawn for. */
.ptr-mock-logo--color {
	height: calc(1.1rem * var(--ptr-mock-k, 1));
	filter: none;
	opacity: 1;
}

/* Boosted logos (paythor_mock_logo_boost()): if a column's max-width caps
   them, scale down proportionally instead of squeezing. */
.ptr-mock-logo--fit {
	object-fit: contain;
}

.ptr-symbol {
	display: block;
	width: 100%;
	height: auto;
	border-radius: 0 !important;
}

.ptr-live {
	position: relative;
	display: inline-block;
	width: 0.45rem;
	height: 0.45rem;
	margin-left: auto;
	border-radius: 999px;
	background: var(--ptr-accent);
}

.ptr-live::after {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: inherit;
	background: inherit;
	animation: ptrLive 1.8s var(--ptr-ease) infinite;
}

@keyframes ptrLive {
	from { transform: scale(1); opacity: 0.6; }
	to { transform: scale(3); opacity: 0; }
}

.ptr-status {
	display: inline-flex;
	align-items: center;
	gap: 0.3rem;
	padding: 0.15rem 0.5rem;
	border-radius: 999px;
	font-size: 0.6875rem;
	font-style: normal;
	font-weight: 700;
	white-space: nowrap;
}

.ptr-status::before {
	content: "";
	width: 0.35rem;
	height: 0.35rem;
	border-radius: 999px;
	background: currentColor;
}

.ptr-status--approved { background: var(--wp--preset--color--emerald-50); color: #047857; }
.ptr-status--refund { background: #eef2ff; color: #4338ca; }
.ptr-status--pending { background: #fffbeb; color: #b45309; }

.ptr-window {
	overflow: hidden;
	border: 1px solid var(--ptr-line-strong);
	border-radius: var(--ptr-radius);
	background: #fff;
	box-shadow: var(--ptr-shadow-lg);
}

.ptr-window__bar {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding: 0.6rem 0.85rem;
	border-bottom: 1px solid var(--ptr-line);
	background: var(--ptr-surface-muted);
}

.ptr-window__dots {
	display: flex;
	gap: 0.35rem;
}

.ptr-window__dots i {
	width: 0.6rem;
	height: 0.6rem;
	border-radius: 999px;
	background: var(--wp--preset--color--slate-300);
}

.ptr-window__url {
	display: inline-flex;
	align-items: center;
	gap: 0.3rem;
	margin: 0 auto;
	padding: 0.2rem 0.75rem;
	border-radius: 0.4rem;
	background: #fff;
	box-shadow: 0 0 0 1px var(--ptr-line);
	color: var(--ptr-muted);
	font-size: 0.6875rem;
	font-weight: 600;
}

.ptr-window__url .ptr-i {
	color: var(--ptr-emerald);
	font-size: 0.85rem;
}

.ptr-mono {
	font-family: var(--wp--preset--font-family--mono);
	font-variant-numeric: tabular-nums;
}

/* Brand swatches (checkout, white-label) */
.ptr-swatches {
	display: none;
	align-items: center;
	justify-content: center;
	gap: 0.6rem;
	margin-top: 1.5rem;
}

.ptr-js .ptr-swatches {
	display: flex;
}

.ptr-swatches__label {
	margin-right: 0.35rem;
	color: var(--ptr-muted);
	font-size: 0.8125rem;
	font-weight: 600;
}

.ptr-swatch {
	position: relative;
	width: 1.75rem;
	height: 1.75rem;
	padding: 0;
	border: 2px solid #fff;
	border-radius: 999px;
	background: var(--c);
	box-shadow: 0 0 0 1px var(--ptr-line-strong);
	cursor: pointer;
	transition: transform var(--ptr-fast) var(--ptr-ease), box-shadow var(--ptr-fast) ease;
}

.ptr-swatch:hover {
	transform: scale(1.12);
}

.ptr-swatch[aria-pressed="true"] {
	box-shadow: 0 0 0 2px var(--c);
}

.ptr-swatches--dark .ptr-swatches__label {
	color: rgba(209, 250, 229, 0.7);
}

.ptr-swatches--dark .ptr-swatch {
	border-color: var(--ptr-deep);
	box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.2);
}

.ptr-swatches--dark .ptr-swatch[aria-pressed="true"] {
	box-shadow: 0 0 0 2px var(--c);
}

.ptr-brandable {
	transition: --brand 0.4s ease;
}

/* ==========================================================================
   Orchestration (hero)
   ========================================================================== */

/* Animation: one transaction at a time, as a chain of events driven by
   assets/js/site.js ("Hero orchestration"); nothing here runs on its own clock.
   1. .is-sending on the figure: Pay is pressed, a pulse runs along the wire.
   2. Wire animation ends: .is-routing (hub rings) and .is-flowing on the next
      route's pulse, which travels from the hub to that provider card.
   3. Pulse animation ends (its head reaches the card) = arrival, the only
      trigger for the data change: .is-current / .is-on / .is-lit move to that
      transaction, so checkout values, Pay amount, provider card, route line and
      "Routed to" all change together.
   4. Hold, then step 1 toward the next provider; after the last, the first.
   The markup ships with the first transaction completed, which is also the
   static state without JS or with reduced motion. */

.ptr-orch__stage {
	position: relative;
	display: grid;
	grid-template-columns: minmax(14.5rem, 16.5rem) minmax(2.5rem, 0.6fr) 12.5rem minmax(4rem, 1fr) minmax(9rem, 11rem);
	align-items: center;
	padding: clamp(1.5rem, 3vw, 2.75rem);
	border: 1px solid var(--ptr-line);
	border-radius: var(--ptr-radius-xl);
	background:
		radial-gradient(28rem 18rem at 50% 50%, rgba(133, 248, 196, 0.22), transparent 70%),
		rgba(255, 255, 255, 0.72);
	box-shadow: var(--ptr-shadow-lg);
	-webkit-backdrop-filter: blur(8px);
	backdrop-filter: blur(8px);
}

.ptr-orch__checkout {
	display: grid;
	gap: 0.6rem;
	padding: 1.15rem;
}

.ptr-orch__amount {
	color: var(--ptr-ink);
	font-size: 1.75rem;
	font-weight: 800;
	letter-spacing: -0.03em;
}

.ptr-orch__amount small {
	color: var(--ptr-muted);
	font-size: 0.6em;
}

.ptr-orch__pay {
	padding: 0.65rem;
	border-radius: 0.6rem;
	background: var(--ptr-emerald);
	color: #fff;
	font-size: 0.8125rem;
	font-weight: 700;
	text-align: center;
	box-shadow: 0 6px 14px -6px rgba(0, 105, 72, 0.6);
}

.ptr-orch.is-sending .ptr-orch__pay {
	animation: ptrPress 0.4s var(--ptr-ease-std);
}

@keyframes ptrPress {
	0%, 100% { transform: none; box-shadow: 0 6px 14px -6px rgba(0, 105, 72, 0.6); }
	45% { transform: scale(0.96); box-shadow: 0 2px 6px -4px rgba(0, 105, 72, 0.6); }
}

/* Checkout values and "Routed to": one stacked copy per transaction in one grid
   cell, so nothing changes size; only .is-current is visible. The outgoing copy
   (.was-current) drifts up as the new one settles from below. */
.ptr-orch__swap {
	display: grid;
}

.ptr-ui-field.ptr-orch__swap {
	display: grid;
	align-items: center;
}

.ptr-orch__swap > span,
.ptr-orch__ticker > span {
	grid-area: 1 / 1;
	opacity: 0;
	transform: translate3d(0, 0.3em, 0);
	transition: opacity 0.25s var(--ptr-ease-std), transform 0.35s var(--ptr-ease-std);
}

.ptr-orch__swap > span.was-current,
.ptr-orch__ticker > span.was-current {
	transform: translate3d(0, -0.3em, 0);
}

.ptr-orch__swap > span.is-current,
.ptr-orch__ticker > span.is-current {
	opacity: 1;
	transform: none;
	transition-delay: 0.1s;
}

.ptr-orch__card {
	display: flex;
	align-items: center;
	gap: 0.6rem;
	min-width: 0;
}

/* Same-width slot for every card mark, so the masked number never shifts or clips. */
.ptr-orch__card .ptr-network {
	flex: none;
	width: 1.75rem;
	object-fit: contain;
	object-position: left center;
}

.ptr-orch__wire {
	position: relative;
	height: 2px;
	overflow: hidden;
	background: var(--wp--preset--color--slate-200);
}

.ptr-orch__wire span {
	position: absolute;
	top: 0;
	left: 0;
	width: 35%;
	height: 100%;
	background: linear-gradient(90deg, transparent, var(--ptr-accent), transparent);
	transform: translateX(-100%);
}

.ptr-orch.is-sending .ptr-orch__wire span {
	animation: ptrOrchWire 0.7s var(--ptr-ease-std) 0.2s both;
}

@keyframes ptrWire {
	0% { transform: translateX(-100%); }
	35%, 100% { transform: translateX(300%); }
}

@keyframes ptrOrchWire {
	from { transform: translateX(-100%); }
	to { transform: translateX(300%); }
}

.ptr-orch__hub {
	display: grid;
	justify-items: center;
	gap: 0.75rem;
	text-align: center;
}

.ptr-orch__core {
	position: relative;
	display: grid;
	place-items: center;
	width: 5.5rem;
	height: 5.5rem;
	padding: 1.15rem;
	border-radius: 1.5rem;
	background: linear-gradient(150deg, #04412c, var(--ptr-deep));
	box-shadow: 0 0 0 1px rgba(133, 248, 196, 0.25) inset, 0 20px 40px -12px rgba(2, 44, 34, 0.55);
}

.ptr-orch__core .ptr-symbol {
	position: relative;
	z-index: 1;
	filter: brightness(1.15) saturate(1.2);
}

.ptr-orch__ring {
	position: absolute;
	inset: 0;
	border: 1px solid rgba(16, 185, 129, 0.5);
	border-radius: inherit;
	opacity: 0;
}

.ptr-orch.is-routing .ptr-orch__ring {
	animation: ptrRing 1.4s var(--ptr-ease);
}

.ptr-orch.is-routing .ptr-orch__ring--2 {
	animation-delay: 0.25s;
}

@keyframes ptrRing {
	0% { transform: scale(1); opacity: 0.8; }
	100% { transform: scale(1.7); opacity: 0; }
}

.ptr-orch__hub-title {
	margin: 0;
	color: var(--ptr-ink);
	font-weight: 800;
	font-size: 0.9375rem;
}

.ptr-orch__hub-title span {
	display: block;
	color: var(--ptr-emerald);
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.6875rem;
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

.ptr-orch__chips {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 0.3rem;
}

.ptr-orch__chips li {
	display: inline-flex;
	align-items: center;
	gap: 0.25rem;
	padding: 0.2rem 0.5rem;
	border: 1px solid var(--ptr-line);
	border-radius: 999px;
	background: #fff;
	color: var(--wp--preset--color--slate-600);
	font-size: 0.6875rem;
	font-weight: 600;
}

.ptr-orch__chips .ptr-i {
	color: var(--ptr-emerald);
	font-size: 0.85rem;
}

.ptr-orch__fan {
	display: block;
	align-self: center;
	width: 100%;
	height: calc(6 * 3.4rem);
	overflow: visible;
}

.ptr-orch__path,
.ptr-orch__pulse {
	fill: none;
}

.ptr-orch__path {
	vector-effect: non-scaling-stroke;
}

.ptr-orch__path {
	stroke: #dbe3ea;
	stroke-width: 1.5;
	transition: stroke 0.45s ease, stroke-width 0.45s ease;
}

.ptr-orch__path.is-lit {
	stroke: #34d399;
	stroke-width: 2;
}

/* The travelling flow. Its animation ends exactly when the head of the dash
   reaches the provider card (dash 14 long: offset -86 puts it at 86-100). */
.ptr-orch__pulse {
	stroke: var(--ptr-accent);
	stroke-width: 2.5;
	stroke-linecap: round;
	stroke-dasharray: 14 100;
	stroke-dashoffset: 14;
	opacity: 0;
}

.ptr-orch__pulse.is-flowing {
	opacity: 1;
	animation: ptrOrchFlow 0.6s cubic-bezier(0.45, 0, 0.25, 1);
}

@keyframes ptrOrchFlow {
	from { stroke-dashoffset: 14; }
	to { stroke-dashoffset: -86; }
}

.ptr-orch__providers {
	display: grid;
	grid-template-rows: repeat(6, 3.4rem);
}

.ptr-orch__providers li {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem;
	margin: 0.3rem 0;
	padding: 0 0.85rem;
	border: 1px solid var(--ptr-line);
	border-radius: 0.75rem;
	background: #fff;
	box-shadow: var(--ptr-shadow-sm);
	transition: transform 0.4s var(--ptr-ease-std);
}

.ptr-orch__providers li.is-on {
	transform: scale(1.025);
}

.ptr-orch__providers li::before {
	content: "";
	position: absolute;
	inset: -1px;
	border: 1px solid var(--ptr-accent);
	border-radius: inherit;
	box-shadow: 0 10px 24px -10px rgba(16, 185, 129, 0.55);
	opacity: 0;
	transition: opacity 0.3s ease;
	pointer-events: none;
}

.ptr-orch__providers li.is-on::before {
	opacity: 1;
}

.ptr-orch__providers .ptr-mock-logo {
	height: 0.95rem;
	max-width: 5rem;
}

.ptr-orch__providers .ptr-mock-logo--color {
	height: calc(0.95rem * var(--ptr-mock-k, 1));
}

.ptr-orch__ok {
	display: inline-flex;
	align-items: center;
	gap: 0.15rem;
	color: #047857;
	font-size: 0.6875rem;
	font-weight: 700;
	opacity: 0;
	transition: opacity 0.3s ease;
}

.ptr-orch__providers li.is-on .ptr-orch__ok {
	opacity: 1;
}

.ptr-orch__ok .ptr-i {
	font-size: 0.95rem;
}

.ptr-orch__more {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: 0.5rem 1.5rem;
	margin: 1rem 0.5rem 0;
	color: var(--ptr-muted);
	font-size: 0.8125rem;
	font-weight: 500;
}

.ptr-orch__ticker {
	position: relative;
	display: inline-grid;
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.75rem;
}

.ptr-orch__ticker > span::before {
	content: "";
	display: inline-block;
	width: 0.45rem;
	height: 0.45rem;
	margin-right: 0.5rem;
	border-radius: 999px;
	background: var(--ptr-accent);
}

.ptr-orch__ticker b {
	color: var(--ptr-ink);
}

@media (max-width: 1100px) {
	.ptr-orch__stage {
		grid-template-columns: minmax(13.5rem, 15rem) minmax(1.5rem, 0.5fr) 11rem minmax(3rem, 1fr) minmax(8.5rem, 10rem);
	}
}

@media (max-width: 900px) {
	.ptr-orch__stage {
		grid-template-columns: minmax(0, 1fr);
		justify-items: center;
		gap: 0;
		padding: 1.5rem 1.25rem;
	}

	.ptr-orch__checkout {
		width: min(100%, 19rem);
	}

	.ptr-orch__wire {
		width: 2px;
		height: 2.25rem;
	}

	.ptr-orch__wire span {
		width: 100%;
		height: 40%;
		background: linear-gradient(180deg, transparent, var(--ptr-accent), transparent);
		transform: translateY(-100%);
	}

	.ptr-orch.is-sending .ptr-orch__wire span {
		animation-name: ptrOrchWireV;
	}

	@keyframes ptrOrchWireV {
		from { transform: translateY(-100%); }
		to { transform: translateY(260%); }
	}

	/* No fan in the stacked layout, but it stays rendered (invisibly) so the
	   flow's arrival event drives the sequence exactly as on wide screens. */
	.ptr-orch__fan {
		position: absolute;
		top: 0;
		left: 0;
		width: 1px;
		height: 1px;
		overflow: hidden;
		visibility: hidden;
		pointer-events: none;
	}

	.ptr-orch__providers {
		grid-template-columns: repeat(3, minmax(0, 1fr));
		grid-template-rows: none;
		gap: 0.5rem;
		width: 100%;
		margin-top: 1.5rem;
	}

	.ptr-orch__providers li {
		justify-content: center;
		height: 3rem;
		margin: 0;
	}

	.ptr-orch__ok {
		display: none;
	}

	.ptr-orch__more {
		justify-content: center;
		text-align: center;
	}
}

/* ==========================================================================
   Orbit (one integration, entire payment universe)
   ========================================================================== */

.ptr-orbit__stage {
	position: relative;
	width: min(100%, 34rem);
	aspect-ratio: 1;
	margin-inline: auto;
	container-type: inline-size;
}

.ptr-orbit__stage::before {
	content: "";
	position: absolute;
	inset: 18%;
	border-radius: 999px;
	background: radial-gradient(closest-side, rgba(133, 248, 196, 0.45), transparent);
}

.ptr-orbit__ring {
	position: absolute;
	inset: 0;
	animation: ptrSpin 90s linear infinite;
}

.ptr-orbit__ring--outer {
	--r: 44cqw;
	animation-duration: 140s;
	animation-direction: reverse;
}

.ptr-orbit__ring--inner {
	--r: 27cqw;
}

.ptr-orbit__ring::before {
	content: "";
	position: absolute;
	left: 50%;
	top: 50%;
	width: calc(var(--r) * 2);
	height: calc(var(--r) * 2);
	border: 1px dashed rgba(0, 105, 72, 0.22);
	border-radius: 999px;
	transform: translate(-50%, -50%);
}

.ptr-orbit__ring li {
	position: absolute;
	left: 50%;
	top: 50%;
	width: 0;
	height: 0;
	transform: rotate(var(--a)) translateX(var(--r));
}

.ptr-orbit__chip {
	position: absolute;
	left: 0;
	top: 0;
	display: grid;
	place-items: center;
	width: clamp(4rem, 19cqw, 6.75rem);
	height: clamp(1.9rem, 8.5cqw, 2.85rem);
	padding: 0 0.6rem;
	border: 1px solid var(--ptr-line);
	border-radius: 999px;
	background: #fff;
	box-shadow: var(--ptr-shadow);
	translate: -50% -50%;
	animation: ptrCounter 90s linear infinite;
}

.ptr-orbit__ring--outer .ptr-orbit__chip {
	animation-name: ptrCounterRev;
	animation-duration: 140s;
}

.ptr-orbit__chip .ptr-mock-logo {
	height: clamp(0.65rem, 2.9cqw, 0.95rem);
}

.ptr-orbit__chip .ptr-mock-logo--color {
	height: calc(clamp(0.65rem, 2.9cqw, 0.95rem) * var(--ptr-mock-k, 1));
}

@keyframes ptrSpin {
	to { transform: rotate(360deg); }
}

@keyframes ptrCounter {
	from { transform: rotate(calc(var(--a) * -1)); }
	to { transform: rotate(calc(var(--a) * -1 - 360deg)); }
}

@keyframes ptrCounterRev {
	from { transform: rotate(calc(var(--a) * -1)); }
	to { transform: rotate(calc(var(--a) * -1 + 360deg)); }
}

/* Static fallback: counter-rotation must still keep chips upright. */
@media (prefers-reduced-motion: reduce) {
	.ptr-orbit__ring { animation: none; }
	.ptr-orbit__chip { animation: none; transform: rotate(calc(var(--a) * -1)); }
}

.ptr-orbit__core {
	position: absolute;
	left: 50%;
	top: 50%;
	display: grid;
	justify-items: center;
	align-content: center;
	gap: 0.3rem;
	width: 26cqw;
	height: 26cqw;
	padding: 4.5cqw;
	border-radius: 999px;
	background: linear-gradient(150deg, #04412c, var(--ptr-deep));
	box-shadow: 0 0 0 1px rgba(133, 248, 196, 0.3) inset, 0 0 0 3cqw rgba(16, 185, 129, 0.08), 0 30px 60px -20px rgba(2, 44, 34, 0.6);
	transform: translate(-50%, -50%);
}

.ptr-orbit__core .ptr-symbol {
	width: 9cqw;
}

.ptr-orbit__core-label {
	color: var(--ptr-mint);
	font-family: var(--wp--preset--font-family--mono);
	font-size: clamp(0.55rem, 2.3cqw, 0.75rem);
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	white-space: nowrap;
}


/* ==========================================================================
   Routing decision
   ========================================================================== */

.ptr-route__flow {
	display: grid;
	justify-items: stretch;
	width: min(100%, 31rem);
	margin-inline: auto;
}

.ptr-route__tx {
	display: grid;
	gap: 0.4rem;
}

.ptr-route__amount {
	color: var(--ptr-ink);
	font-size: 1.6rem;
	font-weight: 800;
	letter-spacing: -0.03em;
}

.ptr-route__amount small {
	color: var(--ptr-muted);
	font-size: 0.6em;
}

.ptr-route__meta {
	display: flex;
	gap: 0.5rem;
}

.ptr-route__meta span {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	padding: 0.25rem 0.55rem;
	border-radius: 0.4rem;
	background: var(--ptr-surface-muted);
	color: var(--wp--preset--color--slate-600);
	font-size: 0.75rem;
	font-weight: 600;
}

.ptr-route__meta .ptr-network {
	height: 0.6rem;
}

.ptr-route__link {
	position: relative;
	justify-self: center;
	width: 2px;
	height: 1.75rem;
	overflow: hidden;
	background: var(--wp--preset--color--emerald-200);
}

.ptr-route__link span {
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, transparent, var(--ptr-accent), transparent);
	animation: ptrDrip 1.6s linear infinite;
}

@keyframes ptrDrip {
	from { transform: translateY(-100%); }
	to { transform: translateY(100%); }
}

.ptr-route__engine {
	display: grid;
	gap: 0.75rem;
	background: linear-gradient(150deg, #04412c, var(--ptr-deep));
	border-color: transparent;
}

.ptr-route__engine .ptr-ui-label {
	color: var(--ptr-mint);
}

.ptr-route__engine .ptr-ui-label .ptr-i {
	color: var(--ptr-mint);
}

.ptr-route__rules {
	display: grid;
	gap: 0.4rem;
}

.ptr-route__rules li {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.55rem 0.7rem;
	border-radius: 0.55rem;
	background: rgba(255, 255, 255, 0.06);
	color: #fff;
	font-size: 0.8125rem;
	font-weight: 600;
}

.ptr-route__rules li > .ptr-i {
	color: var(--ptr-mint);
}

.ptr-route__tick {
	display: grid;
	place-items: center;
	width: 1.2rem;
	height: 1.2rem;
	margin-left: auto;
	border-radius: 999px;
	background: var(--ptr-accent);
	color: var(--ptr-deep);
	transform: scale(0);
	transition: transform 0.4s var(--ptr-ease);
}

.ptr-route__rules li:nth-child(1) .ptr-route__tick { transition-delay: 0.9s; }
.ptr-route__rules li:nth-child(2) .ptr-route__tick { transition-delay: 1.15s; }

.ptr-visual.is-inview .ptr-route__tick,
html:not(.ptr-js) .ptr-route__tick {
	transform: scale(1);
}

.ptr-route__tick .ptr-i {
	font-size: 0.85rem;
	font-weight: 700;
}

.ptr-route__channels {
	display: grid;
	gap: 0.6rem;
}

.ptr-route__legend,
.ptr-route__channels li {
	display: grid;
	grid-template-columns: 5.5rem minmax(0, 1fr) minmax(0, 1fr);
	align-items: center;
	gap: 0.85rem;
}

.ptr-route__legend {
	color: var(--ptr-muted);
	font-size: 0.6875rem;
	font-weight: 600;
}

.ptr-route__legend span:first-child {
	grid-column: 2;
}

.ptr-route__channels ul {
	display: grid;
	gap: 0.4rem;
}

.ptr-route__channels li {
	position: relative;
	padding: 0.55rem 0.6rem;
	border: 1px solid transparent;
	border-radius: 0.6rem;
	transition: border-color 0.5s ease 1.6s, background-color 0.5s ease 1.6s;
}

.ptr-route__logo .ptr-mock-logo {
	height: 0.85rem;
}

.ptr-route__logo .ptr-mock-logo--color {
	height: calc(0.85rem * var(--ptr-mock-k, 1));
}

.ptr-meter {
	position: relative;
	height: 0.4rem;
	overflow: hidden;
	border-radius: 999px;
	background: var(--wp--preset--color--slate-100);
}

.ptr-meter i {
	position: absolute;
	inset: 0 auto 0 0;
	width: var(--v);
	border-radius: inherit;
	background: var(--ptr-accent);
	transition: width 1s var(--ptr-ease) 1.2s;
}

.ptr-meter--cost i {
	background: #f59e0b;
}

.ptr-js .ptr-visual:not(.is-inview) .ptr-meter i {
	width: 0;
}

.ptr-route__channels li.is-winner {
	border-color: var(--ptr-accent);
	background: var(--wp--preset--color--emerald-50);
}

.ptr-js .ptr-visual:not(.is-inview) .ptr-route__channels li.is-winner {
	border-color: transparent;
	background: transparent;
}

.ptr-route__badge {
	position: absolute;
	right: -0.5rem;
	top: -0.6rem;
	display: inline-flex;
	align-items: center;
	gap: 0.2rem;
	padding: 0.15rem 0.5rem;
	border-radius: 999px;
	background: var(--ptr-emerald);
	color: #fff;
	font-size: 0.6875rem;
	font-weight: 700;
	box-shadow: 0 6px 14px -6px rgba(0, 105, 72, 0.7);
	transition: opacity 0.4s ease 1.9s, transform 0.5s var(--ptr-ease) 1.9s;
}

.ptr-route__badge .ptr-i {
	font-size: 0.85rem;
}

.ptr-js .ptr-visual:not(.is-inview) .ptr-route__badge {
	opacity: 0;
	transform: translateY(4px);
}

/* ==========================================================================
   Security (hosted pages & tokenization)
   ========================================================================== */

.ptr-secure {
	display: grid;
	gap: 1rem;
	width: min(100%, 34rem);
	margin-inline: auto;
}

.ptr-secure__flow {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 1.5rem minmax(0, 1fr) 1.5rem minmax(0, 1fr);
	align-items: center;
}

.ptr-secure__node {
	display: grid;
	justify-items: center;
	gap: 0.55rem;
	padding: 1.15rem 0.6rem;
	overflow: hidden;
	text-align: center;
}

.ptr-secure__node .ptr-ui-label {
	justify-content: center;
	font-size: 0.625rem;
	text-align: center;
}

.ptr-secure__icon {
	display: grid;
	place-items: center;
	width: 2.5rem;
	height: 2.5rem;
	border-radius: 0.75rem;
	background: var(--wp--preset--color--emerald-50);
	color: var(--ptr-emerald);
}

.ptr-secure__icon .ptr-i {
	font-size: 1.35rem;
}

.ptr-secure__pan,
.ptr-secure__token {
	font-size: 0.625rem;
	white-space: nowrap;
}

.ptr-secure__pan {
	color: #b45309;
}

.ptr-secure__token {
	padding: 0.15rem 0.45rem;
	border-radius: 0.35rem;
	background: var(--wp--preset--color--emerald-50);
	color: #047857;
}

.ptr-secure__node--vault {
	background: linear-gradient(150deg, #04412c, var(--ptr-deep));
	border-color: transparent;
}

.ptr-secure__node--vault .ptr-ui-label {
	color: var(--ptr-mint);
}

.ptr-secure__node--vault .ptr-secure__icon {
	background: rgba(133, 248, 196, 0.14);
	color: var(--ptr-mint);
}

.ptr-secure__scan {
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, transparent 40%, rgba(133, 248, 196, 0.2) 50%, transparent 60%);
	background-size: 100% 250%;
	animation: ptrScan 3s linear infinite;
	pointer-events: none;
}

@keyframes ptrScan {
	from { background-position: 0 100%; }
	to { background-position: 0 -150%; }
}

.ptr-secure__arrow {
	position: relative;
	height: 2px;
	margin-inline: 0.2rem;
	background: var(--wp--preset--color--emerald-200);
}

.ptr-secure__arrow::after {
	content: "";
	position: absolute;
	right: -1px;
	top: 50%;
	width: 0.45rem;
	height: 0.45rem;
	border-top: 2px solid var(--wp--preset--color--emerald-300);
	border-right: 2px solid var(--wp--preset--color--emerald-300);
	transform: translateY(-50%) rotate(45deg);
}

.ptr-secure__zt {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	padding: 0.7rem;
	border: 1px dashed rgba(0, 105, 72, 0.3);
	border-radius: 0.75rem;
	color: var(--wp--preset--color--slate-600);
	font-size: 0.8125rem;
}

.ptr-secure__zt .ptr-i {
	color: var(--ptr-emerald);
}

.ptr-secure__zt b {
	color: var(--ptr-ink);
}

.ptr-secure__certs {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0.6rem;
}

.ptr-secure__certs li {
	display: grid;
	gap: 0.4rem;
	padding: 0.85rem 1rem;
	border: 1px solid var(--ptr-line);
	border-radius: 0.75rem;
	background: #fff;
}

.ptr-secure__cert {
	color: var(--ptr-ink);
	font-weight: 800;
	font-size: 0.875rem;
}

.ptr-secure__certs .ptr-status {
	width: fit-content;
}

@media (max-width: 560px) {
	.ptr-secure__flow {
		grid-template-columns: minmax(0, 1fr);
		justify-items: center;
	}

	.ptr-secure__node { width: 100%; }

	.ptr-secure__arrow {
		width: 2px;
		height: 1.25rem;
	}

	.ptr-secure__arrow::after {
		right: auto;
		left: 50%;
		top: auto;
		bottom: -1px;
		transform: translateX(-50%) rotate(135deg);
	}

	.ptr-secure__certs { grid-template-columns: minmax(0, 1fr); }
}

/* ==========================================================================
   Merchant panel (dashboard)
   ========================================================================== */

.ptr-dash .ptr-window {
	font-size: 0.75rem;
}

.ptr-dash__body {
	display: grid;
	grid-template-columns: 10.5rem minmax(0, 1fr);
	min-height: 24rem;
}

.ptr-dash__side {
	display: grid;
	align-content: start;
	gap: 0.15rem;
	padding: 0.9rem 0.6rem;
	border-right: 1px solid var(--ptr-line);
	background: var(--ptr-surface-muted);
}

.ptr-dash__brand {
	display: flex;
	align-items: center;
	gap: 0.45rem;
	margin: 0 0 0.85rem 0.4rem;
	color: var(--ptr-ink);
	font-weight: 800;
	font-size: 0.8125rem;
}

.ptr-dash__brand .ptr-symbol {
	width: 1.1rem;
}

.ptr-dash__nav {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.45rem 0.55rem;
	border-radius: 0.5rem;
	color: var(--wp--preset--color--slate-600);
	font-weight: 600;
}

.ptr-dash__nav .ptr-i {
	font-size: 1rem;
	color: var(--wp--preset--color--slate-400);
}

.ptr-dash__nav.is-current {
	background: #fff;
	box-shadow: var(--ptr-shadow-sm), 0 0 0 1px var(--ptr-line);
	color: var(--ptr-ink);
}

.ptr-dash__nav.is-current .ptr-i {
	color: var(--ptr-emerald);
}

.ptr-dash__main {
	display: grid;
	align-content: start;
	gap: 0.9rem;
	padding: 1rem 1.1rem;
	min-width: 0;
}

.ptr-dash__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.ptr-dash__title {
	display: block;
	color: var(--ptr-ink);
	font-size: 1rem;
	font-weight: 800;
}

.ptr-dash__sub {
	color: var(--ptr-muted);
	font-size: 0.6875rem;
}

.ptr-pill-live {
	display: inline-flex;
	align-items: center;
	gap: 0.45rem;
	padding: 0.25rem 0.6rem;
	border-radius: 999px;
	background: var(--wp--preset--color--emerald-50);
	color: #047857;
	font-size: 0.6875rem;
	font-weight: 700;
}

.ptr-pill-live .ptr-live {
	margin: 0;
}

.ptr-dash__kpis {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 0.6rem;
}

.ptr-dash__kpi {
	display: grid;
	gap: 0.15rem;
	padding: 0.7rem 0.8rem;
	border: 1px solid var(--ptr-line);
	border-radius: 0.65rem;
}

.ptr-dash__kpi span {
	color: var(--ptr-muted);
	font-size: 0.6875rem;
	font-weight: 600;
}

.ptr-dash__kpi b {
	color: var(--ptr-ink);
	font-size: 1.05rem;
	letter-spacing: -0.02em;
	font-variant-numeric: tabular-nums;
}

.ptr-dash__kpi em {
	color: var(--ptr-muted);
	font-size: 0.6875rem;
	font-style: normal;
	font-weight: 600;
}

.ptr-dash__kpi em.is-up {
	color: #047857;
}

.ptr-dash__chart {
	height: 6.5rem;
	padding: 0.4rem 0;
}

.ptr-dash__chart svg {
	display: block;
	width: 100%;
	height: 100%;
	overflow: visible;
}

.ptr-dash__grid line {
	stroke: var(--ptr-line);
	stroke-dasharray: 3 4;
	vector-effect: non-scaling-stroke;
}

.ptr-dash__area {
	fill: url(#ptrDashFill);
}

.ptr-dash__line {
	fill: none;
	stroke: var(--ptr-accent);
	stroke-width: 2;
	stroke-dasharray: 100;
	stroke-dashoffset: 0;
	transition: stroke-dashoffset 1.6s var(--ptr-ease) 0.4s;
}

.ptr-js .ptr-visual:not(.is-inview) .ptr-dash__line {
	stroke-dashoffset: 100;
}

.ptr-dash__table {
	display: grid;
}

.ptr-dash__row {
	display: grid;
	grid-template-columns: 4.75rem minmax(0, 1fr) 5.5rem 5.5rem;
	align-items: center;
	gap: 0.5rem;
	padding: 0.5rem 0.4rem;
	border-bottom: 1px solid var(--ptr-line);
	color: var(--ptr-ink);
	font-size: 0.6875rem;
}

.ptr-dash__row:last-child {
	border-bottom: 0;
}

.ptr-dash__row--head {
	color: var(--ptr-muted);
	font-weight: 600;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	font-size: 0.625rem;
}

.ptr-dash__row:nth-child(2) {
	border-radius: 0.4rem;
	animation: ptrNewRow 6s ease infinite 1.2s;
}

@keyframes ptrNewRow {
	0% { background: rgba(16, 185, 129, 0.18); }
	30%, 100% { background: transparent; }
}

.ptr-dash__prov .ptr-mock-logo {
	height: 0.75rem;
	max-width: 4.5rem;
}

.ptr-dash__prov .ptr-mock-logo--color {
	height: calc(0.75rem * var(--ptr-mock-k, 1));
}

@media (prefers-reduced-motion: no-preference) {
	.ptr-js .ptr-dash:not(.is-inview) .ptr-dash__row:not(.ptr-dash__row--head) {
		opacity: 0;
		transform: translateX(-0.5rem);
	}

	.ptr-dash .ptr-dash__row:not(.ptr-dash__row--head) {
		transition: opacity 0.5s var(--ptr-ease), transform 0.5s var(--ptr-ease);
		transition-delay: calc(var(--r, 0) * 90ms + 0.5s);
	}
}

@media (max-width: 640px) {
	.ptr-dash__body { grid-template-columns: minmax(0, 1fr); }
	.ptr-dash__side { display: none; }
	.ptr-dash__kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.ptr-dash__kpi:nth-child(3) { display: none; }
	.ptr-dash__row { grid-template-columns: minmax(0, 1fr) 4.75rem 4.75rem; }
	.ptr-dash__row > :first-child { display: none; }
}

/* ==========================================================================
   Hosted payment page
   ========================================================================== */

.ptr-hpp {
	--brand: #00855d;
}

.ptr-hpp__stage {
	position: relative;
	padding: 1.75rem 2.25rem 3.25rem 1rem;
}

.ptr-hpp__page {
	display: grid;
	grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
	min-height: 19rem;
}

.ptr-hpp__summary {
	display: grid;
	align-content: start;
	gap: 0.55rem;
	padding: 1.25rem;
	border-right: 1px solid var(--ptr-line);
	background: color-mix(in srgb, var(--brand) 6%, #fff);
	transition: background-color 0.4s ease;
}

.ptr-hpp__brand {
	display: flex;
	align-items: center;
	gap: 0.45rem;
	margin-bottom: 0.75rem;
	color: var(--ptr-ink);
	font-weight: 800;
}

.ptr-hpp__brand i {
	width: 1.35rem;
	height: 1.35rem;
	border-radius: 0.45rem;
	background: var(--brand);
	transition: background-color 0.4s ease;
}

.ptr-hpp__total {
	color: var(--ptr-ink);
	font-size: 1.6rem;
	font-weight: 800;
	letter-spacing: -0.03em;
}

.ptr-hpp__total small {
	color: var(--ptr-muted);
	font-size: 0.6em;
}

.ptr-hpp__line {
	display: flex;
	justify-content: space-between;
	color: var(--ptr-muted);
	font-size: 0.75rem;
}

.ptr-hpp__form {
	display: grid;
	align-content: start;
	gap: 0.55rem;
	padding: 1.25rem;
}

.ptr-hpp__pay {
	padding: 0.7rem;
	border-radius: 0.6rem;
	background: var(--brand);
	color: #fff;
	font-weight: 700;
	font-size: 0.8125rem;
	text-align: center;
	box-shadow: 0 8px 18px -8px var(--brand);
	transition: background-color 0.4s ease, box-shadow 0.4s ease;
}

.ptr-hpp__or {
	position: relative;
	display: block;
	color: var(--ptr-muted);
	font-size: 0.6875rem;
	text-align: center;
}

.ptr-hpp__or::before {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	top: 50%;
	height: 1px;
	background: var(--ptr-line);
}

.ptr-hpp__or span {
	position: relative;
	padding: 0 0.5rem;
	background: #fff;
}

.ptr-hpp__wallet {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.4rem;
	padding: 0.6rem;
	border: 1px solid var(--wp--preset--color--slate-200);
	border-radius: 0.6rem;
	color: var(--ptr-ink);
	font-weight: 700;
	font-size: 0.75rem;
}

.ptr-hpp__secure {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.3rem;
	margin-top: 0.25rem;
	color: var(--ptr-muted);
	font-size: 0.6875rem;
}

.ptr-hpp__secure .ptr-i {
	color: var(--ptr-emerald);
	font-size: 0.9rem;
}

.ptr-hpp__note {
	position: absolute;
	display: flex;
	align-items: center;
	gap: 0.45rem;
	padding: 0.55rem 0.8rem;
	border: 1px solid var(--ptr-line);
	border-radius: 0.75rem;
	background: #fff;
	box-shadow: var(--ptr-shadow);
	color: var(--wp--preset--color--slate-600);
	font-size: 0.75rem;
	white-space: nowrap;
	animation: ptrFloat 6s ease-in-out infinite;
}

.ptr-hpp__note b {
	color: var(--ptr-ink);
}

.ptr-hpp__note .ptr-i {
	display: grid;
	place-items: center;
	width: 1.6rem;
	height: 1.6rem;
	border-radius: 0.5rem;
	background: var(--wp--preset--color--emerald-50);
	color: var(--ptr-emerald);
	font-size: 1rem;
}

.ptr-hpp__note--bin {
	top: 0.25rem;
	right: 0;
}

.ptr-hpp__note--wallet {
	bottom: 0.4rem;
	right: 1.5rem;
	animation-delay: -3s;
}

.ptr-hpp__link {
	position: absolute;
	left: 0;
	bottom: 0;
	display: grid;
	gap: 0.4rem;
	width: 15.5rem;
	animation: ptrFloat 7s ease-in-out infinite -1.5s;
}

.ptr-hpp__url {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.5rem;
	padding: 0.45rem 0.6rem;
	border-radius: 0.5rem;
	background: var(--ptr-surface-muted);
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.6875rem;
	color: var(--ptr-ink);
}

.ptr-hpp__url b {
	color: var(--brand);
	font-family: var(--wp--preset--font-family--body);
	transition: color 0.4s ease;
}

.ptr-hpp__hint {
	color: var(--ptr-muted);
	font-size: 0.6875rem;
}

@keyframes ptrFloat {
	0%, 100% { transform: translateY(0); }
	50% { transform: translateY(-6px); }
}

@media (max-width: 640px) {
	.ptr-hpp__stage {
		display: grid;
		gap: 0.75rem;
		padding: 0;
	}

	.ptr-hpp__page { grid-template-columns: minmax(0, 1fr); }
	.ptr-hpp__summary { border-right: 0; border-bottom: 1px solid var(--ptr-line); }

	.ptr-hpp__note,
	.ptr-hpp__link {
		position: static;
		width: auto;
		animation: none;
	}
}

/* ==========================================================================
   Unify (before / after)
   ========================================================================== */

.ptr-unify__toggle {
	display: flex;
	width: fit-content;
	margin: 0 auto 1.25rem;
	padding: 0.3rem;
	border: 1px solid var(--ptr-line);
	border-radius: 999px;
	background: #fff;
	box-shadow: var(--ptr-shadow-sm);
}

html:not(.ptr-js) .ptr-unify__toggle {
	display: none;
}

.ptr-unify__toggle button {
	padding: 0.45rem 1rem;
	border: 0;
	border-radius: 999px;
	background: transparent;
	color: var(--wp--preset--color--slate-600);
	font: inherit;
	font-size: 0.8125rem;
	font-weight: 700;
	cursor: pointer;
	transition: background-color var(--ptr-base) ease, color var(--ptr-base) ease;
}

.ptr-unify__toggle button[aria-pressed="true"] {
	background: var(--ptr-deep);
	color: #fff;
}

.ptr-unify__toggle button[data-state="before"][aria-pressed="true"] {
	background: #7c2d12;
}

.ptr-unify__stage {
	position: relative;
	width: 100%;
	aspect-ratio: 640 / 380;
	border: 1px solid var(--ptr-line);
	border-radius: var(--ptr-radius-xl);
	background:
		radial-gradient(circle at 1px 1px, rgba(15, 23, 42, 0.08) 1px, transparent 0) 0 0 / 20px 20px,
		#fff;
	box-shadow: var(--ptr-shadow-lg);
	container-type: inline-size;
}

.ptr-unify__lines {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
}

.ptr-unify__lines path {
	fill: none;
	stroke-width: 2;
	transition: opacity 0.45s ease;
}

.ptr-unify__before path {
	stroke: #f59e0b;
	stroke-dasharray: 5 6;
	animation: ptrDash 1.2s linear infinite;
}

.ptr-unify__before path:nth-child(2n) { stroke: #f97316; }
.ptr-unify__before path:nth-child(3n) { stroke: #ef4444; }

.ptr-unify__after path {
	stroke: var(--ptr-accent);
	stroke-dasharray: 6 8;
	animation: ptrDash 0.9s linear infinite;
}

.ptr-unify__after .ptr-unify__trunk {
	stroke-width: 3;
}

@keyframes ptrDash {
	to { stroke-dashoffset: -22; }
}

.ptr-unify.is-after .ptr-unify__before,
.ptr-unify.is-before .ptr-unify__after {
	opacity: 0;
}

.ptr-unify__before,
.ptr-unify__after {
	transition: opacity 0.45s ease;
}

.ptr-unify__you,
.ptr-unify__hub,
.ptr-unify__targets li,
.ptr-unify__count {
	position: absolute;
	transform: translate(-50%, -50%);
}

.ptr-unify__you {
	left: calc(85 / 640 * 100%);
	top: 50%;
	display: grid;
	justify-items: center;
	gap: 0.35cqw;
	width: 20cqw;
	padding: 2.4cqw 1cqw;
	border-radius: 2cqw;
	background: var(--ptr-deep);
	color: #fff;
	font-size: clamp(0.55rem, 2cqw, 0.8125rem);
	font-weight: 700;
	text-align: center;
	box-shadow: 0 16px 30px -14px rgba(2, 44, 34, 0.7);
}

.ptr-unify__you .ptr-i {
	color: var(--ptr-mint);
	font-size: clamp(1rem, 4.2cqw, 1.6rem);
}

.ptr-unify__hub {
	left: calc(300 / 640 * 100%);
	top: 50%;
	width: 10cqw;
	height: 10cqw;
	padding: 2.2cqw;
	border-radius: 2.6cqw;
	background: linear-gradient(150deg, #04412c, var(--ptr-deep));
	box-shadow: 0 0 0 1.6cqw rgba(16, 185, 129, 0.12), 0 14px 30px -12px rgba(2, 44, 34, 0.6);
	transition: opacity 0.45s ease, transform 0.45s var(--ptr-ease);
}

.ptr-unify.is-before .ptr-unify__hub {
	opacity: 0;
	transform: translate(-50%, -50%) scale(0.6);
}

.ptr-unify__targets li {
	left: calc(540 / 640 * 100%);
	top: calc(var(--y) / 380 * 100%);
	display: grid;
	place-items: center;
	width: 21cqw;
	height: 7.4cqw;
	border: 1px solid var(--ptr-line);
	border-radius: 1.6cqw;
	background: #fff;
	box-shadow: var(--ptr-shadow-sm);
	transition: border-color 0.45s ease;
}

.ptr-unify.is-before .ptr-unify__targets li {
	border-color: #fed7aa;
}

.ptr-unify__targets .ptr-mock-logo {
	height: clamp(0.55rem, 2.4cqw, 0.95rem);
	max-width: 15cqw;
}

.ptr-unify__targets .ptr-mock-logo--color {
	height: calc(clamp(0.55rem, 2.4cqw, 0.95rem) * var(--ptr-mock-k, 1));
}

.ptr-unify__count {
	left: 50%;
	top: auto;
	bottom: 0;
	padding: 0.35rem 0.85rem;
	border-radius: 999px;
	font-size: clamp(0.625rem, 2cqw, 0.8125rem);
	font-weight: 600;
	white-space: nowrap;
	transform: translate(-50%, 50%);
	transition: opacity 0.45s ease;
}

.ptr-unify__count b {
	font-size: 1.15em;
}

.ptr-unify__count--before {
	background: #fff7ed;
	color: #9a3412;
	box-shadow: 0 0 0 1px #fed7aa;
}

.ptr-unify__count--after {
	background: var(--ptr-deep);
	color: var(--ptr-mint);
}

.ptr-unify.is-after .ptr-unify__count--before,
.ptr-unify.is-before .ptr-unify__count--after {
	opacity: 0;
}

/* ==========================================================================
   B2B hierarchy
   ========================================================================== */

.ptr-tree__wrap {
	display: grid;
	gap: 1.25rem;
}

.ptr-tree__portal {
	display: grid;
	gap: 0.75rem;
}

.ptr-tree__portal ul {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 0.4rem;
}

.ptr-tree__portal li {
	display: flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.5rem 0.6rem;
	border-radius: 0.55rem;
	background: var(--ptr-surface-muted);
	color: var(--ptr-ink);
	font-weight: 600;
	font-size: 0.8125rem;
}

.ptr-tree__portal li .ptr-i {
	color: var(--ptr-emerald);
	font-size: 1.05rem;
}

/* Admin portal switches: <button role="switch">, flipped in sequence by
   site.js and clickable. Track colour and thumb move together (350 ms). */
.ptr-toggle {
	position: relative;
	display: block;
	width: 1.9rem;
	height: 1.1rem;
	margin: 0 0 0 auto;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: var(--wp--preset--color--slate-300);
	font: inherit;
	cursor: pointer;
	-webkit-appearance: none;
	appearance: none;
	-webkit-tap-highlight-color: transparent;
	transition: background-color 0.35s var(--ptr-ease), box-shadow 0.2s ease;
}

/* Larger hit area without changing the layout. */
.ptr-toggle::before {
	content: "";
	position: absolute;
	inset: -0.45rem -0.4rem;
}

.ptr-toggle::after {
	content: "";
	position: absolute;
	left: 0.15rem;
	top: 0.15rem;
	width: 0.8rem;
	height: 0.8rem;
	border-radius: 999px;
	background: #fff;
	box-shadow: var(--ptr-shadow-sm);
	transition: transform 0.35s var(--ptr-ease);
}

.ptr-toggle:hover {
	box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.12);
}

.ptr-toggle:focus-visible {
	outline: 2px solid var(--ptr-accent);
	outline-offset: 2px;
}

.ptr-toggle.is-on {
	background: var(--ptr-accent);
}

.ptr-toggle.is-on::after {
	transform: translateX(0.8rem);
}

/* Entrance: the switches turn on one after another when the visual first
   appears. Once the live loop starts (.is-live) every change is immediate. */
.ptr-tree__portal:not(.is-live) li:nth-child(1) .ptr-toggle,
.ptr-tree__portal:not(.is-live) li:nth-child(1) .ptr-toggle::after { transition-delay: 0.6s; }
.ptr-tree__portal:not(.is-live) li:nth-child(2) .ptr-toggle,
.ptr-tree__portal:not(.is-live) li:nth-child(2) .ptr-toggle::after { transition-delay: 0.75s; }
.ptr-tree__portal:not(.is-live) li:nth-child(3) .ptr-toggle,
.ptr-tree__portal:not(.is-live) li:nth-child(3) .ptr-toggle::after { transition-delay: 0.9s; }
.ptr-tree__portal:not(.is-live) li:nth-child(4) .ptr-toggle,
.ptr-tree__portal:not(.is-live) li:nth-child(4) .ptr-toggle::after { transition-delay: 1.05s; }

@media (prefers-reduced-motion: reduce) {
	.ptr-toggle::after { transition-duration: 0.01s; }
}

.ptr-js .ptr-visual:not(.is-inview) .ptr-toggle.is-on {
	background: var(--wp--preset--color--slate-300);
}

.ptr-js .ptr-visual:not(.is-inview) .ptr-toggle.is-on::after {
	transform: none;
}

.ptr-tree__chart {
	display: grid;
	justify-items: center;
}

.ptr-tree__node {
	position: relative;
	z-index: 1;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.6rem 0.85rem;
	border: 1px solid var(--ptr-line);
	border-radius: 0.75rem;
	background: #fff;
	box-shadow: var(--ptr-shadow-sm);
	color: var(--ptr-ink);
	font-size: 0.75rem;
	white-space: nowrap;
	transition: transform var(--ptr-base) var(--ptr-ease), border-color var(--ptr-base) ease, box-shadow var(--ptr-base) ease;
}

.ptr-tree__node:hover {
	transform: translateY(-2px);
	border-color: var(--ptr-accent);
	box-shadow: var(--ptr-shadow-hover);
}

.ptr-tree__node .ptr-i {
	color: var(--ptr-emerald);
	font-size: 1.1rem;
}

.ptr-tree__node span {
	display: grid;
}

.ptr-tree__node small {
	color: var(--ptr-muted);
	font-size: 0.6875rem;
}

.ptr-tree__node--hq {
	padding: 0.8rem 1.15rem;
	border-color: transparent;
	background: linear-gradient(150deg, #04412c, var(--ptr-deep));
	color: #fff;
	font-size: 0.9375rem;
	box-shadow: 0 16px 30px -14px rgba(2, 44, 34, 0.7);
}

.ptr-tree__node--hq .ptr-i,
.ptr-tree__node--hq small {
	color: var(--ptr-mint);
}

.ptr-tree__node--sub {
	padding: 0.45rem 0.6rem;
	font-size: 0.6875rem;
	color: var(--wp--preset--color--slate-600);
}

.ptr-tree__node--sub .ptr-i {
	font-size: 0.95rem;
}

/* Connector lines */
.ptr-tree__level {
	position: relative;
	display: flex;
	justify-content: center;
	padding-top: 1.5rem !important;
}

.ptr-tree__chart > .ptr-tree__level::before,
.ptr-tree__branch > .ptr-tree__level::before {
	content: "";
	position: absolute;
	left: 50%;
	top: 0;
	width: 2px;
	height: 1.5rem;
	background: var(--wp--preset--color--emerald-200);
}

.ptr-tree__level > li {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 1.5rem 0.4rem 0;
}

.ptr-tree__level > li::before {
	content: "";
	position: absolute;
	left: 50%;
	top: 0;
	width: 2px;
	height: 1.5rem;
	background: var(--wp--preset--color--emerald-200);
}

.ptr-tree__level > li::after {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 2px;
	background: var(--wp--preset--color--emerald-200);
}

.ptr-tree__level > li:first-child::after { left: 50%; }
.ptr-tree__level > li:last-child::after { right: 50%; }
.ptr-tree__level > li:only-child::after { display: none; }

.ptr-tree__level--subs {
	padding-top: 1.5rem !important;
}

@media (max-width: 760px) {
	.ptr-tree__portal ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.ptr-tree {
	container-type: inline-size;
}

/* The tree adapts to its own width (it sits in narrow columns on tablets). */
@container (max-width: 640px) {
	.ptr-tree__node--sub span { display: none; }
	.ptr-tree__node--sub { padding: 0.5rem; }
	.ptr-tree__level > li { padding-inline: 0.25rem; }
}

@container (max-width: 400px) {
	.ptr-tree__node { font-size: 0.6875rem; padding: 0.5rem 0.6rem; }
	.ptr-tree__portal li { font-size: 0.75rem; }
}

/* ==========================================================================
   White-label
   ========================================================================== */

.ptr-wl {
	--brand: #10b981;
}

.ptr-wl__stage {
	position: relative;
	width: 100%;
	aspect-ratio: 16 / 10.5;
	container-type: inline-size;
	font-size: clamp(0.55rem, 1.55cqw, 0.8125rem);
}

.ptr-wl__web {
	position: absolute;
	left: 0;
	top: 0;
	width: 74%;
	font-size: inherit;
}

.ptr-wl__web .ptr-window__url {
	font-size: 0.85em;
}

.ptr-wl__web-body {
	display: grid;
	gap: 1.4em;
	padding: 1.4em 1.6em 1.8em;
}

.ptr-wl__top {
	display: flex;
	align-items: center;
	justify-content: space-between;
}

.ptr-wl__logo {
	display: inline-flex;
	align-items: center;
	gap: 0.5em;
	color: var(--ptr-ink);
	font-weight: 800;
	font-size: 1.1em;
}

.ptr-wl__logo i {
	width: 1.5em;
	height: 1.5em;
	border-radius: 0.45em;
	background: var(--brand);
	transition: background-color 0.4s ease;
}

.ptr-wl__avatar {
	width: 1.8em;
	height: 1.8em;
	border-radius: 999px;
	background: var(--wp--preset--color--slate-200);
}

.ptr-wl__hero {
	display: grid;
	gap: 0.2em;
	padding: 1.2em 1.4em;
	border-radius: 0.9em;
	background: var(--brand);
	color: rgba(255, 255, 255, 0.85);
	transition: background-color 0.4s ease;
}

.ptr-wl__hero b {
	color: #fff;
	font-size: 2em;
	letter-spacing: -0.03em;
}

.ptr-wl__bars {
	display: flex;
	align-items: flex-end;
	gap: 0.6em;
	height: 7em;
}

.ptr-wl__bars i {
	flex: 1;
	height: var(--h);
	border-radius: 0.3em 0.3em 0 0;
	background: color-mix(in srgb, var(--brand) 35%, #e2e8f0);
	transition: background-color 0.4s ease;
}

.ptr-wl__bars i:nth-child(4n) {
	background: var(--brand);
}

.ptr-wl__phone {
	position: absolute;
	right: 2%;
	top: 8%;
	display: grid;
	align-content: start;
	gap: 1em;
	width: 27%;
	aspect-ratio: 9 / 18;
	padding: 2.2em 1em 1em;
	border: 0.5em solid #0b1220;
	border-radius: 2.4em;
	background: #fff;
	box-shadow: var(--ptr-shadow-lg);
}

.ptr-wl__notch {
	position: absolute;
	left: 50%;
	top: 0.5em;
	width: 34%;
	height: 1em;
	border-radius: 999px;
	background: #0b1220;
	transform: translateX(-50%);
}

.ptr-wl__phone .ptr-wl__logo {
	font-size: 0.95em;
}

.ptr-wl__card {
	display: grid;
	gap: 0.2em;
	padding: 1em;
	border-radius: 0.9em;
	background: linear-gradient(140deg, var(--brand), color-mix(in srgb, var(--brand) 55%, #0b1220));
	color: rgba(255, 255, 255, 0.8);
	transition: background 0.4s ease;
}

.ptr-wl__card b {
	color: #fff;
	font-size: 1.4em;
}

.ptr-wl__btn {
	padding: 0.7em;
	border-radius: 0.7em;
	background: color-mix(in srgb, var(--brand) 12%, #fff);
	color: color-mix(in srgb, var(--brand) 70%, #0b1220);
	font-weight: 700;
	text-align: center;
	transition: background-color 0.4s ease, color 0.4s ease;
}

.ptr-wl__list {
	display: grid;
	gap: 0.55em;
}

.ptr-wl__list i {
	height: 1.6em;
	border-radius: 0.5em;
	background: var(--wp--preset--color--slate-100);
}

.ptr-wl__plugin {
	position: absolute;
	left: 6%;
	bottom: 0;
	display: grid;
	gap: 0.8em;
	width: 38%;
	padding: 1.2em 1.3em;
	font-size: inherit;
	border-radius: 1em;
	animation: ptrFloat 7s ease-in-out infinite;
}

.ptr-wl__plugin .ptr-ui-label {
	font-size: 0.85em;
}

.ptr-wl__radio {
	display: flex;
	align-items: center;
	gap: 0.6em;
	padding: 0.8em;
	border: 1px solid var(--brand);
	border-radius: 0.7em;
	color: var(--ptr-ink);
	transition: border-color 0.4s ease;
}

.ptr-wl__radio i {
	width: 1em;
	height: 1em;
	border: 0.3em solid var(--brand);
	border-radius: 999px;
	transition: border-color 0.4s ease;
}

.ptr-wl__pbtn {
	padding: 0.75em;
	border-radius: 0.7em;
	background: var(--brand);
	color: #fff;
	font-weight: 700;
	text-align: center;
	transition: background-color 0.4s ease;
}

/* ==========================================================================
   Developer (SDKs, plugins, REST API, webhooks)
   ========================================================================== */

.ptr-dev__grid {
	display: grid;
	grid-template-columns: minmax(0, 1.15fr) minmax(1.5rem, 0.35fr) 8.5rem minmax(1.5rem, 0.35fr) minmax(0, 1.15fr);
	align-items: center;
}

.ptr-dev__col {
	display: grid;
	gap: 0.75rem;
}

.ptr-dev__group {
	display: grid;
	gap: 0.65rem;
}

.ptr-dev__chips {
	display: flex;
	flex-wrap: wrap;
	gap: 0.35rem;
}

.ptr-dev__chips span {
	padding: 0.3rem 0.6rem;
	border-radius: 0.45rem;
	background: var(--ptr-surface-muted);
	box-shadow: 0 0 0 1px var(--ptr-line) inset;
	color: var(--ptr-ink);
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.6875rem;
	font-weight: 600;
	transition: background-color var(--ptr-fast) ease, color var(--ptr-fast) ease;
}

.ptr-dev__chips span:hover {
	background: var(--ptr-deep);
	color: var(--ptr-mint);
}

.ptr-dev__wire {
	position: relative;
	height: 2px;
	overflow: hidden;
	background: var(--wp--preset--color--emerald-200);
}

.ptr-dev__wire span {
	position: absolute;
	inset: 0;
	width: 50%;
	background: linear-gradient(90deg, transparent, var(--ptr-accent), transparent);
	animation: ptrWire 2.2s linear infinite;
}

.ptr-dev__wire--back span {
	animation-delay: 1.1s;
}

.ptr-dev__api {
	display: grid;
	justify-items: center;
	gap: 0.3rem;
	padding: 1.25rem 0.75rem;
	border-radius: 1.25rem;
	background: linear-gradient(150deg, #04412c, var(--ptr-deep));
	color: rgba(209, 250, 229, 0.7);
	font-size: 0.6875rem;
	text-align: center;
	box-shadow: 0 0 0 1px rgba(133, 248, 196, 0.2) inset, 0 20px 40px -14px rgba(2, 44, 34, 0.6);
}

.ptr-dev__api .ptr-symbol {
	width: 2.25rem;
	margin-bottom: 0.35rem;
}

.ptr-dev__api b {
	color: #fff;
	font-size: 0.9375rem;
}

.ptr-dev__hooks {
	display: grid;
	gap: 0.65rem;
}

.ptr-dev__hooks ul {
	display: grid;
	gap: 0.4rem;
}

.ptr-dev__hooks li {
	display: flex;
	align-items: center;
	gap: 0.45rem;
	padding: 0.5rem 0.55rem;
	border: 1px solid var(--ptr-line);
	border-radius: 0.55rem;
	color: var(--ptr-ink);
	font-size: 0.75rem;
	font-weight: 600;
	animation: ptrHook 6s ease infinite;
	animation-delay: calc(var(--i) * 2s);
}

.ptr-dev__hooks li > .ptr-i {
	color: var(--ptr-emerald);
	font-size: 1rem;
}

.ptr-dev__hooks .ptr-status {
	margin-left: auto;
}

@keyframes ptrHook {
	0%, 100% { border-color: var(--ptr-line); background: #fff; }
	6%, 22% { border-color: var(--ptr-accent); background: var(--wp--preset--color--emerald-50); }
	33% { border-color: var(--ptr-line); background: #fff; }
}

@media (max-width: 860px) {
	.ptr-dev__grid {
		grid-template-columns: minmax(0, 1fr);
		justify-items: center;
	}

	.ptr-dev__col,
	.ptr-dev__hooks { width: 100%; }

	.ptr-dev__wire {
		width: 2px;
		height: 1.5rem;
	}

	.ptr-dev__wire span {
		width: 100%;
		height: 50%;
		background: linear-gradient(180deg, transparent, var(--ptr-accent), transparent);
		animation-name: ptrDrip;
	}

	.ptr-dev__api { width: 10rem; }
}

/* ==========================================================================
   On dark sections: tone shared primitives.
   ========================================================================== */

.ptr-section--dark .ptr-visual {
	color: rgba(226, 232, 240, 0.78);
}

.ptr-section--dark .ptr-swatches__label {
	color: rgba(209, 250, 229, 0.7);
}

@media (max-width: 480px) {
	.ptr-route__legend,
	.ptr-route__channels li {
		grid-template-columns: 4.25rem minmax(0, 1fr) minmax(0, 1fr);
		gap: 0.5rem;
	}

	.ptr-route__legend { font-size: 0.625rem; }
	.ptr-route__meta { flex-wrap: wrap; }
}

/* ==========================================================================
   Developer console (Developers page hero): abstract, text-free code window
   ========================================================================== */

.ptr-console {
	position: relative;
	max-width: 34rem;
	margin: 0 0 1.5rem auto;
	padding: 0 0 1.75rem 1.75rem;
}

.ptr-console__window {
	overflow: hidden;
	border: 1px solid var(--ptr-line);
	border-radius: 1rem;
	background: #fff;
	box-shadow: 0 24px 48px -28px rgba(2, 44, 34, 0.28), 0 6px 14px -8px rgba(15, 23, 42, 0.08);
}

.ptr-console__code {
	display: grid;
	gap: 0.85rem;
	margin: 0;
	padding: 1.5rem 1.5rem 1.75rem 0;
	list-style: none;
	counter-reset: ptr-line;
}

.ptr-console__code li {
	display: flex;
	align-items: center;
	gap: 0.45rem;
	padding-left: calc(3rem + var(--indent, 0) * 1.25rem);
	position: relative;
	counter-increment: ptr-line;
}

/* Line-number gutter, drawn as short ticks rather than digits. */
.ptr-console__code li::before {
	content: "";
	position: absolute;
	left: 1.25rem;
	width: 0.75rem;
	height: 0.3rem;
	border-radius: 999px;
	background: var(--wp--preset--color--slate-200, #e2e8f0);
}

.ptr-console__tok {
	display: block;
	width: var(--w);
	height: 0.55rem;
	border-radius: 999px;
}

.ptr-console__tok--a { background: rgba(0, 105, 72, 0.55); }
.ptr-console__tok--b { background: rgba(16, 185, 129, 0.35); }
.ptr-console__tok--c { background: rgba(15, 23, 42, 0.18); }
.ptr-console__tok--d { background: rgba(15, 23, 42, 0.09); }

.ptr-console__chip {
	position: absolute;
	left: 0;
	bottom: 0;
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding: 0.75rem 1rem 0.75rem 0.75rem;
	border: 1px solid var(--ptr-line);
	border-radius: 0.875rem;
	background: #fff;
	box-shadow: 0 16px 32px -22px rgba(2, 44, 34, 0.35);
}

.ptr-console__chip .ptr-symbol {
	width: 2.25rem;
	height: 2.25rem;
	border-radius: 0.6rem;
}

.ptr-console__chip-lines {
	display: grid;
	gap: 0.4rem;
}

.ptr-console__chip-lines i {
	display: block;
	width: 5.5rem;
	height: 0.45rem;
	border-radius: 999px;
	background: rgba(15, 23, 42, 0.12);
}

.ptr-console__chip-lines i + i {
	width: 3.5rem;
	background: rgba(15, 23, 42, 0.07);
}

.ptr-console__status {
	width: 0.55rem;
	height: 0.55rem;
	border-radius: 999px;
	background: var(--ptr-accent);
	box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.15);
}

@media (max-width: 860px) {
	.ptr-console {
		margin: 1rem 0 0;
		max-width: 30rem;
	}
}
