/* netrhyme.com: the few styles the kit does not have. Prefix nrs-. */

/* "Coming" label next to a feature that is being built. */
.nrs-soon {
	display: inline-block;
	margin-inline-start: 0.35em;
	padding: 0.1em 0.55em;
	border-radius: 999px;
	background: color-mix(in srgb, var(--wp--preset--color--accent) 12%, transparent);
	color: var(--wp--preset--color--accent);
	font-size: 0.72em;
	font-weight: 600;
	letter-spacing: 0.02em;
	line-height: 1.6;
	vertical-align: 0.12em;
	white-space: nowrap;
}

.is-style-wprk-dark .nrs-soon {
	background: rgb(255 255 255 / 0.14);
	color: inherit;
}

/* Pictures of sample pages: a thin frame so a white page does not melt into a white section. */
.nrs-shot img {
	border: 1px solid color-mix(in srgb, var(--wp--preset--color--dark) 12%, transparent);
	border-radius: var(--wp--custom--radius--md, 10px);
	box-shadow: var(--wp--custom--shadow--md);
	object-position: top;
}

.nrs-center {
	text-align: center;
}

/* Long forms read better in one narrow column. */
.wp-block-group.nrs-narrow {
	max-width: 46rem !important;
	margin-inline: auto !important;
}

.nrs-wordmark {
	font-weight: 700;
	letter-spacing: -0.01em;
}

/* Long forms: section titles inside the brief, and tick boxes that wrap on phones. */
.wprk-form h3 {
	margin-block: var(--wp--preset--spacing--50) var(--wp--preset--spacing--20);
}

.wprk-form h3:first-of-type {
	margin-block-start: 0;
}

.wprk-form .wpcf7-checkbox {
	display: flex;
	flex-wrap: wrap;
	gap: 0.4em 1.2em;
}

.wprk-form .wpcf7-list-item {
	margin: 0;
}

.wprk-form .wpcf7-list-item label,
.wprk-form .wpcf7-acceptance label {
	font-weight: 400;
}

/* Legal pages: one readable column with clear section headings. */
.nrs-legal h2 {
	font-size: var(--wp--preset--font-size--large);
	margin-block: var(--wp--preset--spacing--50) var(--wp--preset--spacing--20);
}

/* ==========================================================================
   Colour and motion for netrhyme.com
   Three brand hues: violet (primary), cyan (accent) and a magenta that only
   appears inside gradients. Everything that moves stops for visitors who ask
   their device for reduced motion.
   ========================================================================== */

:root {
	--nrs-violet: var(--wp--preset--color--primary);
	--nrs-cyan: #22d3ee;
	--nrs-magenta: #e83e8c;
	--nrs-grad: linear-gradient(100deg, var(--nrs-cyan) 0%, #8b5cf6 45%, var(--nrs-magenta) 100%);
}

/* Words in a heading painted with the brand gradient. */
.nrs-gradient-text {
	font-style: italic;
	padding-inline-end: 0.06em;
	background: var(--nrs-grad);
	background-size: 200% 100%;
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	-webkit-text-fill-color: transparent;
}

/* Aurora: three soft blobs of colour drifting behind a dark section, under a faint grid. */
.nrs-aurora {
	isolation: isolate;
	overflow: hidden;
	position: relative;
}

.nrs-aurora::after {
	background:
		radial-gradient(38rem 26rem at 12% 18%, color-mix(in srgb, #8b5cf6 55%, transparent), transparent 70%),
		radial-gradient(32rem 24rem at 88% 22%, color-mix(in srgb, var(--nrs-magenta) 40%, transparent), transparent 70%),
		radial-gradient(40rem 28rem at 60% 105%, color-mix(in srgb, var(--nrs-cyan) 38%, transparent), transparent 70%);
	content: "";
	filter: blur(10px) saturate(1.2);
	inset: -20%;
	opacity: 0.75;
	pointer-events: none;
	position: absolute;
	z-index: -2;
}

/* The faint grid, fading towards the edges. Sits on top of the colour, behind the words. */
.nrs-aurora.nrs-hero::before {
	background-image:
		linear-gradient(rgb(255 255 255 / 0.06) 1px, transparent 1px),
		linear-gradient(90deg, rgb(255 255 255 / 0.06) 1px, transparent 1px);
	background-size: 56px 56px;
	content: "";
	inset: 0;
	-webkit-mask-image: radial-gradient(ellipse 70% 70% at 50% 40%, #000 30%, transparent 80%);
	mask-image: radial-gradient(ellipse 70% 70% at 50% 40%, #000 30%, transparent 80%);
	pointer-events: none;
	position: absolute;
	z-index: -1;
}

@keyframes nrs-aurora-drift {
	0% {
		transform: translate3d(0, 0, 0) rotate(0deg) scale(1);
	}

	50% {
		transform: translate3d(4%, -3%, 0) rotate(8deg) scale(1.08);
	}

	100% {
		transform: translate3d(-3%, 4%, 0) rotate(-6deg) scale(1.02);
	}
}

@keyframes nrs-shimmer {
	from {
		background-position: 0% 50%;
	}

	to {
		background-position: 100% 50%;
	}
}

@keyframes nrs-float {
	0%,
	100% {
		transform: translateY(0) rotate(-1.2deg);
	}

	50% {
		transform: translateY(-12px) rotate(0.4deg);
	}
}

@keyframes nrs-spin {
	to {
		--nrs-turn: 360deg;
	}
}

@property --nrs-turn {
	inherits: false;
	initial-value: 0deg;
	syntax: "<angle>";
}

@media (prefers-reduced-motion: no-preference) {
	.nrs-aurora::after {
		animation: nrs-aurora-drift 18s ease-in-out infinite alternate;
	}

	.nrs-gradient-text {
		animation: nrs-shimmer 6s ease-in-out infinite alternate;
	}

	.nrs-hero .wprk-hero-1__image {
		animation: nrs-float 7s ease-in-out infinite;
	}
}

/* Hero: the sample page floats in a glass frame with a coloured glow. */
.nrs-hero .wprk-hero-1__image {
	border-radius: var(--wp--custom--radius--lg, 16px);
	box-shadow:
		0 30px 80px -20px color-mix(in srgb, #8b5cf6 70%, transparent),
		0 0 0 1px rgb(255 255 255 / 0.12);
	overflow: hidden;
}

.nrs-hero .wprk-hero-1__image img {
	object-position: top;
}

/* Main buttons: the gradient, with a soft glow on hover. Outline buttons stay plain. */
.wp-block-button:not(.is-style-outline):not(.is-style-wprk-text) > .wp-block-button__link {
	background-image: linear-gradient(100deg, var(--nrs-violet), #9333ea 50%, var(--nrs-magenta));
	background-size: 160% 100%;
	border: 0;
	color: #fff;
	transition: background-position 0.4s ease, box-shadow 0.3s ease, transform 0.2s ease;
}

.wp-block-button:not(.is-style-outline):not(.is-style-wprk-text) > .wp-block-button__link:is(:hover, :focus-visible) {
	background-position: 100% 0;
	box-shadow: 0 10px 30px -8px color-mix(in srgb, var(--nrs-magenta) 65%, transparent);
	transform: translateY(-1px);
}

/* Cards in sections marked nrs-glow lift and pick up a gradient edge on hover. */
.nrs-glow .wprk-card {
	transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.nrs-glow .wprk-card:is(:hover, :focus-within) {
	box-shadow: 0 22px 50px -18px color-mix(in srgb, #8b5cf6 45%, transparent);
	transform: translateY(-4px);
}

/* Card icons sit in a small gradient tile. */
.wprk-card__icon {
	box-sizing: content-box;
	display: inline-flex;
	width: fit-content;
	background: var(--nrs-grad);
	border-radius: 12px;
	color: #fff;
	padding: 0.5rem;
}

.wprk-card .wprk-card__icon {
	color: #fff !important;
}

.wprk-card .wprk-card__icon svg {
	fill: #fff !important;
}

/* The step numbers and the plan prices carry the gradient too. */
.wprk-step-1__number {
	background: var(--nrs-grad);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	-webkit-text-fill-color: transparent;
	font-weight: 800;
}

/* The featured plan: a slowly turning gradient border. */
.wprk-price-1__featured {
	border-color: transparent !important;
	isolation: isolate;
	position: relative;
}

.wprk-price-1__featured::before {
	background: conic-gradient(from var(--nrs-turn), var(--nrs-cyan), #8b5cf6, var(--nrs-magenta), var(--nrs-cyan));
	border-radius: inherit;
	content: "";
	inset: -2px;
	-webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
	-webkit-mask-composite: xor;
	mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
	padding: 2px;
	pointer-events: none;
	position: absolute;
	z-index: 1;
}

@media (prefers-reduced-motion: no-preference) {
	.wprk-price-1__featured::before {
		animation: nrs-spin 6s linear infinite;
	}
}

.wprk-price-1__flag {
	background: var(--nrs-grad) !important;
	border: 0 !important;
	color: #fff !important;
}
