﻿@charset "UTF-8";
/* =========================================================================
   English Galaxy вЂ” В«РљРёРЅРµС‚РёС‡РµСЃРєРёР№ СЃР»РѕРІР°СЂСЊВ»
   Isolated design preview for slug `main-page-design`.
   Nothing here leaks outside `.md` because every selector is prefixed.
   ========================================================================= */

/* -------------------------------------------------------------------------
   1. Design tokens
   ---------------------------------------------------------------------- */

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

@property --md-sheen {
	syntax: "<percentage>";
	initial-value: 0%;
	inherits: false;
}

/* Also on <body> so the payments plugin's modals вЂ” which render outside .md вЂ”
   can resolve these tokens. This sheet only loads on `main-page-design`. */
.md,
body.md-body {
	/* Ink & paper */
	--ink: #0b0c0f;
	--ink-2: #14161b;
	--ink-3: #22262e;
	--paper: #f5f2ea;
	--paper-2: #ece7da;
	--paper-3: #e0d9c8;

	/* Brand */
	--teal: #0e7c9a;
	--teal-deep: #08556a;
	--teal-mist: #cfe4ec;
	--flame: #ff5b22;
	--gold: #f2b841;
	--sky: #a9cfe0;

	/* Inline arrow glyph reused by button hover swaps */
	--md-arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 17 17 7M8 7h9v9'/%3E%3C/svg%3E");

	/* Semantic */
	--fg: var(--ink);
	--bg: var(--paper);
	--muted: color-mix(in srgb, var(--ink) 58%, transparent);
	--faint: color-mix(in srgb, var(--ink) 38%, transparent);
	--line: color-mix(in srgb, var(--ink) 13%, transparent);
	--line-strong: color-mix(in srgb, var(--ink) 22%, transparent);

	/* Type */
	--font: "Geologica", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
	--font-accent: var(--font);

	--fs-display: clamp(3.4rem, 12.5vw, 13rem);
	--fs-h1: clamp(2.25rem, 4vw, 3.9rem);
	--fs-h2: clamp(1.9rem, 3.6vw, 3.4rem);
	--fs-h3: clamp(1.2rem, 1.9vw, 1.7rem);
	--fs-lead: clamp(1.05rem, 1.5vw, 1.4rem);
	--fs-body: clamp(1rem, 1.05vw, 1.075rem);
	--fs-small: clamp(0.82rem, 0.9vw, 0.9rem);

	/* Rhythm */
	--wrap: 1360px;
	--gut: clamp(1.15rem, 4vw, 3.5rem);
	--sec-y: clamp(4.5rem, 11vw, 10.5rem);
	--r-xs: 10px;
	--r-sm: 16px;
	--r-md: 24px;
	--r-lg: 34px;
	--r-xl: 48px;

	/* Motion */
	--e-out: cubic-bezier(0.16, 1, 0.3, 1);
	--e-inout: cubic-bezier(0.76, 0, 0.24, 1);
	--e-spring: cubic-bezier(0.34, 1.4, 0.64, 1);
	--t-fast: 0.28s;
	--t-mid: 0.55s;
	--t-slow: 0.9s;

	/* Elevation */
	--sh-sm: 0 1px 2px rgba(11, 12, 15, 0.05), 0 6px 18px -10px rgba(11, 12, 15, 0.18);
	--sh-md: 0 2px 4px rgba(11, 12, 15, 0.04), 0 22px 48px -24px rgba(11, 12, 15, 0.28);
	--sh-lg: 0 3px 8px rgba(11, 12, 15, 0.05), 0 48px 90px -40px rgba(11, 12, 15, 0.38);
}

/* -------------------------------------------------------------------------
   2. Reset & base
   ---------------------------------------------------------------------- */

html.md-html {
	box-sizing: border-box;
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
	scrollbar-gutter: stable;
}

html.md-html *,
html.md-html *::before,
html.md-html *::after {
	box-sizing: inherit;
}

body.md-body {
	margin: 0;
	padding: 0;
	background: #f5f2ea;
	color: #0b0c0f;
	font-family: "Geologica", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
	font-size: 1rem;
	line-height: 1.6;
	font-synthesis-weight: none;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	overflow-x: hidden;
}

body.md-body.is-locked {
	overflow: hidden;
}

.md {
	position: relative;
	background: var(--bg);
	color: var(--fg);
	font-family: var(--font);
	font-size: var(--fs-body);
	overflow-x: clip;
}

.md img,
.md svg,
.md video {
	display: block;
	max-width: 100%;
}

.md img {
	height: auto;
}

:where(.md h1, .md h2, .md h3, .md h4, .md p, .md ul, .md ol, .md figure) {
	margin: 0;
	padding: 0;
}

:where(.md ul, .md ol) {
	list-style: none;
}

/* Zero-specificity resets so component modifiers always win. */
:where(.md a) {
	color: inherit;
	text-decoration: none;
}

:where(.md button) {
	font: inherit;
	color: inherit;
	background: none;
	border: 0;
	padding: 0;
	cursor: pointer;
}

.md :focus-visible {
	outline: 2px solid var(--flame);
	outline-offset: 3px;
	border-radius: 4px;
}

.md ::selection {
	background: var(--ink);
	color: var(--paper);
}

.md-sr {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0 0 0 0);
	white-space: nowrap;
	border: 0;
}

/* -------------------------------------------------------------------------
   3. Typography primitives
   ---------------------------------------------------------------------- */

.md-h1,
.md-h2,
.md-display {
	font-weight: 800;
	line-height: 0.94;
	letter-spacing: -0.042em;
	text-wrap: balance;
}

.md-display {
	font-size: var(--fs-display);
	letter-spacing: -0.05em;
	line-height: 0.82;
}

.md-h1 {
	font-size: var(--fs-h1);
}

.md-h2 {
	font-size: var(--fs-h2);
}

.md-h3 {
	font-size: var(--fs-h3);
	font-weight: 700;
	line-height: 1.18;
	letter-spacing: -0.024em;
	text-wrap: balance;
}

.md-em {
	font-family: inherit;
	font-style: normal;
	font-weight: 700;
	letter-spacing: inherit;
	color: var(--flame);
	padding-inline-end: 0;
}

.md-lead {
	font-size: var(--fs-lead);
	line-height: 1.45;
	color: var(--muted);
	max-width: 46ch;
	text-wrap: pretty;
}

.md-kicker {
	display: inline-flex;
	align-items: center;
	gap: 0.6em;
	font-size: clamp(0.68rem, 0.82vw, 0.78rem);
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--muted);
}

.md-kicker::before {
	content: "";
	width: 26px;
	height: 1px;
	background: currentColor;
	opacity: 0.5;
}

.md-kicker--dot::before {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: var(--flame);
	opacity: 1;
}

/* -------------------------------------------------------------------------
   4. Layout
   ---------------------------------------------------------------------- */

.md-wrap {
	width: 100%;
	max-width: var(--wrap);
	margin-inline: auto;
	padding-inline: var(--gut);
}

.md-section {
	position: relative;
	padding-block: var(--sec-y);
	/* Запас под фиксированный хедер для нативных прыжков по хэшу (точный довод до .md-index делает JS). */
	scroll-margin-top: clamp(84px, 11vh, 116px);
}

/* Если якорь укажет прямо на название блока — оно встаёт сразу под меню. */
.md-index {
	scroll-margin-top: clamp(84px, 11vh, 116px);
}

.md-section--ink {
	background: var(--ink);
	color: var(--paper);
	--fg: var(--paper);
	--muted: color-mix(in srgb, #f5f2ea 62%, transparent);
	--faint: color-mix(in srgb, #f5f2ea 40%, transparent);
	--line: color-mix(in srgb, #f5f2ea 16%, transparent);
	--line-strong: color-mix(in srgb, #f5f2ea 28%, transparent);
}

.md-section--tint {
	background: var(--paper-2);
}

.md-head {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: clamp(1.2rem, 3vw, 3rem);
	margin-bottom: clamp(2.4rem, 5vw, 4.5rem);
}

.md-head__copy {
	max-width: 22ch;
}

.md-head__aside {
	max-width: 38ch;
	color: var(--muted);
	font-size: var(--fs-body);
	text-wrap: pretty;
}

/* В методике заголовок длиннее: держим его слева стопкой, мелкий текст — справа. */
#method .md-head__copy {
	max-width: 11em;
}

#method .md-head__aside {
	max-width: 22em;
	margin-left: auto;
}

.md-center {
	display: flex;
	justify-content: center;
	margin-top: clamp(2.2rem, 4vw, 3.6rem);
}

/* Section index label, e.g. В«02 / РњРµС‚РѕРґРёРєР°В» */
.md-index {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	font-size: clamp(0.86rem, 1.05vw, 0.98rem);
	font-weight: 700;
	letter-spacing: 0.13em;
	text-transform: uppercase;
	color: color-mix(in srgb, var(--ink) 72%, transparent);
	margin-bottom: clamp(1.4rem, 3vw, 2.4rem);
	padding-bottom: 0.9rem;
	border-bottom: 1px solid var(--line);
}

.md-section--ink .md-index {
	color: color-mix(in srgb, #f5f2ea 82%, transparent);
	border-bottom-color: color-mix(in srgb, #f5f2ea 16%, transparent);
}

.md-index__num {
	font-variant-numeric: tabular-nums;
	color: var(--flame);
}

/* -------------------------------------------------------------------------
   5. Ambient layers вЂ” grain, mesh, shapes
   ---------------------------------------------------------------------- */

.md-grain {
	position: fixed;
	inset: 0;
	z-index: 9;
	pointer-events: none;
	opacity: 0.4;
	mix-blend-mode: multiply;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.32'/%3E%3C/svg%3E");
	background-size: 160px 160px;
}

.md-shapes {
	position: absolute;
	inset: 0;
	overflow: hidden;
	pointer-events: none;
	z-index: 0;
}

.md-shape {
	position: absolute;
	will-change: transform;
	transform: translate3d(var(--px, 0px), var(--py, 0px), 0);
	transition: transform 0.9s var(--e-out);
}

.md-shape__i {
	display: block;
	width: 100%;
	height: 100%;
	animation: md-drift var(--dur, 16s) var(--e-inout) infinite alternate;
	animation-delay: var(--delay, 0s);
}

.md-shape--circle .md-shape__i {
	border-radius: 50%;
}

.md-shape--half .md-shape__i {
	border-radius: 999px 999px 0 0;
}

.md-shape--quarter .md-shape__i {
	border-radius: 100% 0 0 0;
}

.md-shape--ring .md-shape__i {
	border-radius: 50%;
	background: none !important;
	border: 2px solid currentColor;
}

.md-shape--pill .md-shape__i {
	border-radius: 999px;
}

@keyframes md-drift {
	from {
		transform: translate3d(0, 0, 0) rotate(0deg);
	}
	to {
		transform: translate3d(0, -26px, 0) rotate(var(--rot, 12deg));
	}
}

/* -------------------------------------------------------------------------
   6. Reveal system
   ---------------------------------------------------------------------- */

.md-reveal {
	opacity: 0;
	transform: translate3d(0, 26px, 0);
	transition:
		opacity 0.85s var(--e-out) var(--d, 0s),
		transform 0.85s var(--e-out) var(--d, 0s),
		filter 0.85s var(--e-out) var(--d, 0s);
	filter: blur(6px);
}

.md-reveal.is-in {
	opacity: 1;
	transform: none;
	filter: none;
}

/* Word-by-word masked headline reveal */
.md-word {
	display: inline-block;
	overflow: hidden;
	vertical-align: bottom;
	padding-block: 0.06em;
	margin-block: -0.06em;
}

.md-word__i {
	display: inline-block;
	transform: translate3d(0, 105%, 0) rotate(3deg);
	transition:
		transform 1.05s var(--e-out),
		opacity 1.05s var(--e-out);
	transition-delay: calc(var(--i) * 55ms + var(--base, 0ms));
	opacity: 0;
}

.is-in .md-word__i,
.md-lines.is-in .md-word__i {
	transform: none;
	opacity: 1;
}

/* -------------------------------------------------------------------------
   7. Buttons
   ---------------------------------------------------------------------- */

.md-btn {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 0.7em;
	padding: 1.05em 1.85em;
	border-radius: 999px;
	font-size: clamp(0.9rem, 1vw, 1rem);
	font-weight: 600;
	letter-spacing: -0.012em;
	line-height: 1;
	white-space: nowrap;
	cursor: pointer;
	isolation: isolate;
	overflow: hidden;
	transform: translate3d(var(--mx, 0px), var(--my, 0px), 0);
	transition:
		transform 0.5s var(--e-out),
		color 0.4s var(--e-out),
		border-color 0.4s var(--e-out),
		box-shadow 0.4s var(--e-out);
}

.md-btn::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -2;
	border-radius: inherit;
	background: var(--btn-bg, var(--ink));
	transition: background 0.4s var(--e-out);
}

/* Liquid fill that rises from the bottom on hover */
.md-btn::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	border-radius: inherit;
	background: var(--btn-fill, var(--flame));
	transform: translate3d(0, 101%, 0);
	transition: transform 0.62s var(--e-out);
}

.md-btn:hover::after,
.md-btn:focus-visible::after {
	transform: translate3d(0, 0, 0);
}

.md-btn__label {
	position: relative;
	display: inline-block;
	z-index: 1;
}

.md-btn__arrow {
	position: relative;
	z-index: 1;
	display: grid;
	place-items: center;
	width: 1.5em;
	height: 1.5em;
	border-radius: 50%;
	background: color-mix(in srgb, currentColor 16%, transparent);
	overflow: hidden;
}

.md-btn__arrow svg {
	width: 0.75em;
	height: 0.75em;
	transition: transform 0.45s var(--e-out);
}

.md-btn:hover .md-btn__arrow svg {
	transform: translate3d(120%, -120%, 0);
}

.md-btn__arrow::after {
	content: "";
	position: absolute;
	inset: 0;
	background: currentColor;
	-webkit-mask: var(--md-arrow) center / 0.75em 0.75em no-repeat;
	mask: var(--md-arrow) center / 0.75em 0.75em no-repeat;
	transform: translate3d(-120%, 120%, 0);
	transition: transform 0.45s var(--e-out) 0.06s;
}

.md-btn:hover .md-btn__arrow::after {
	transform: none;
}

.md-btn--primary {
	--btn-bg: var(--ink);
	--btn-fill: var(--flame);
	color: var(--paper);
}

.md-btn--flame {
	--btn-bg: var(--flame);
	--btn-fill: var(--ink);
	color: #fff;
}

.md-btn--light {
	--btn-bg: var(--paper);
	--btn-fill: var(--flame);
	color: var(--ink);
}

.md-btn--light:hover {
	color: #fff;
}

.md-btn--ghost {
	--btn-bg: transparent;
	--btn-fill: var(--ink);
	color: var(--fg);
	box-shadow: inset 0 0 0 1px var(--line-strong);
}

.md-btn--ghost:hover,
.md-btn--ghost:focus-visible {
	color: var(--paper);
	box-shadow: inset 0 0 0 1px transparent;
}

.md-section--ink .md-btn--ghost {
	--btn-fill: var(--paper);
}

.md-section--ink .md-btn--ghost:hover {
	color: var(--ink);
}

.md-btn--sm {
	padding: 0.85em 1.35em;
	font-size: 0.86rem;
}

.md-btn--lg {
	padding: 1.25em 2.4em;
	font-size: clamp(1rem, 1.2vw, 1.12rem);
}

.md-btn--block {
	width: 100%;
}

/* Text link with sweeping underline */
.md-link {
	position: relative;
	display: inline-block;
	font-weight: 600;
	padding-bottom: 2px;
}

.md-link::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: 0;
	width: 100%;
	height: 1px;
	background: currentColor;
	transform-origin: right;
	transform: scaleX(1);
	transition: transform 0.42s var(--e-out);
}

.md-link:hover::after {
	transform-origin: left;
	animation: md-sweep 0.6s var(--e-out);
}

@keyframes md-sweep {
	0% {
		transform: scaleX(1);
		transform-origin: right;
	}
	49% {
		transform: scaleX(0);
		transform-origin: right;
	}
	50% {
		transform: scaleX(0);
		transform-origin: left;
	}
	100% {
		transform: scaleX(1);
		transform-origin: left;
	}
}

.md-icon-btn {
	display: grid;
	place-items: center;
	width: 52px;
	height: 52px;
	border-radius: 50%;
	box-shadow: inset 0 0 0 1px var(--line-strong);
	transition:
		background 0.4s var(--e-out),
		color 0.4s var(--e-out),
		transform 0.4s var(--e-spring),
		box-shadow 0.4s var(--e-out);
}

.md-icon-btn svg {
	width: 17px;
	height: 17px;
}

.md-icon-btn:hover:not(:disabled) {
	background: var(--ink);
	color: var(--paper);
	box-shadow: inset 0 0 0 1px var(--ink);
	transform: scale(1.06);
}

.md-icon-btn:disabled {
	opacity: 0.3;
	cursor: not-allowed;
}

/* -------------------------------------------------------------------------
   8. Custom cursor (pointer-fine devices only)
   ---------------------------------------------------------------------- */

.md-cursor {
	position: fixed;
	top: 0;
	left: 0;
	z-index: 999;
	pointer-events: none;
	display: none;
	mix-blend-mode: difference;
	opacity: 0;
	transition: opacity 0.35s var(--e-out);
}

.md-cursor.is-live {
	opacity: 1;
}

.md-cursor__dot,
.md-cursor__ring {
	position: absolute;
	top: 0;
	left: 0;
	border-radius: 50%;
	transform: translate3d(-50%, -50%, 0);
}

.md-cursor__dot {
	width: 7px;
	height: 7px;
	background: #fff;
	transition: opacity 0.3s var(--e-out);
}

.md-cursor__ring {
	width: 38px;
	height: 38px;
	border: 1px solid rgba(255, 255, 255, 0.75);
	transition:
		width 0.42s var(--e-out),
		height 0.42s var(--e-out),
		background 0.42s var(--e-out),
		opacity 0.3s var(--e-out);
}

.md-cursor.is-hot .md-cursor__ring {
	width: 68px;
	height: 68px;
	background: rgba(255, 255, 255, 0.12);
}

.md-cursor.is-hot .md-cursor__dot {
	opacity: 0;
}

@media (hover: hover) and (pointer: fine) {
	.md-has-cursor .md-cursor {
		display: block;
	}
}

/* -------------------------------------------------------------------------
   9. Intro curtain
   ---------------------------------------------------------------------- */

.md-intro {
	position: fixed;
	inset: 0;
	z-index: 200;
	display: grid;
	place-items: center;
	background: var(--ink);
	color: var(--paper);
	transition:
		clip-path 1s var(--e-inout),
		opacity 0.4s linear 0.75s;
	clip-path: inset(0 0 0 0);
}

.md-intro__mark {
	font-size: clamp(1.7rem, 6.2vw, 4.6rem);
	font-weight: 800;
	letter-spacing: -0.05em;
	line-height: 1.18;
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: flex-end;
	gap: 0.06em;
	max-width: min(92vw, 18ch);
	overflow: hidden;
	padding-top: 0.08em;
	padding-bottom: 0.22em;
}

.md-intro__mark span {
	display: inline-block;
	animation: md-intro-up 0.8s var(--e-out) both;
	animation-delay: calc(var(--i) * 45ms);
}

.md-intro__gap {
	width: 0.32em;
}

@keyframes md-intro-up {
	from {
		transform: translate3d(0, 110%, 0);
		opacity: 0;
	}
	to {
		transform: none;
		opacity: 1;
	}
}

.md-intro__bar {
	position: absolute;
	left: 50%;
	bottom: clamp(2rem, 6vh, 4rem);
	translate: -50% 0;
	width: min(220px, 40vw);
	height: 2px;
	background: color-mix(in srgb, #f5f2ea 22%, transparent);
	overflow: hidden;
}

.md-intro__bar::after {
	content: "";
	display: block;
	height: 100%;
	width: 100%;
	background: var(--flame);
	transform-origin: left;
	animation: md-intro-bar 1.05s var(--e-inout) both;
}

@keyframes md-intro-bar {
	from {
		transform: scaleX(0);
	}
	to {
		transform: scaleX(1);
	}
}

.md-intro.is-done {
	clip-path: inset(0 0 100% 0);
	opacity: 0;
	pointer-events: none;
}

/* -------------------------------------------------------------------------
   10. Header
   ---------------------------------------------------------------------- */

.md-header {
	position: fixed;
	top: clamp(0.6rem, 1.6vw, 1.15rem);
	left: 50%;
	translate: -50% 0;
	z-index: 100;
	width: min(calc(100% - 2 * var(--gut)), var(--wrap));
	transition: translate 0.6s var(--e-out);
}

.md-header__inner {
	display: flex;
	align-items: center;
	gap: clamp(0.7rem, 2vw, 1.6rem);
	padding: 0.55rem 0.55rem 0.55rem 1.15rem;
	border-radius: 999px;
	background: color-mix(in srgb, var(--paper) 72%, transparent);
	backdrop-filter: blur(18px) saturate(180%);
	-webkit-backdrop-filter: blur(18px) saturate(180%);
	box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ink) 8%, transparent);
	transition:
		background 0.5s var(--e-out),
		box-shadow 0.5s var(--e-out),
		padding 0.5s var(--e-out);
}

/* Over the dark overlay the frosted pill reads as a grey slab — drop it. */
/* Needs to outrank `.md-header.is-stuck .md-header__inner`. */
body.md-menu-open .md-header .md-header__inner {
	background: transparent;
	backdrop-filter: none;
	-webkit-backdrop-filter: none;
	box-shadow: none;
	color: var(--paper);
}

body.md-menu-open .md-burger {
	background: color-mix(in srgb, var(--paper) 14%, transparent);
}

.md-header.is-stuck .md-header__inner {
	background: color-mix(in srgb, var(--paper) 88%, transparent);
	box-shadow:
		inset 0 0 0 1px color-mix(in srgb, var(--ink) 10%, transparent),
		var(--sh-md);
}

.md-logo {
	display: inline-flex;
	align-items: center;
	gap: clamp(0.45rem, 0.8vw, 0.65rem);
	flex: 0 0 auto;
}

.md-logo__mark {
	width: clamp(29px, 2.9vw, 35px);
	height: auto;
	flex: 0 0 auto;
	border-radius: 27%;
	box-shadow:
		0 1px 2px rgba(11, 12, 15, 0.14),
		0 10px 20px -12px rgba(11, 12, 15, 0.55);
	transition: transform 0.5s var(--e-out);
}

.md-logo:hover .md-logo__mark {
	transform: rotate(-6deg) scale(1.06);
}

.md-logo__text {
	display: inline-flex;
	align-items: baseline;
	gap: 0.22em;
	font-size: clamp(1rem, 1.1vw, 1.12rem);
	line-height: 1;
	white-space: nowrap;
}

.md-logo__en {
	font-weight: 800;
	letter-spacing: -0.042em;
}

.md-logo__gx {
	font-family: inherit;
	font-style: normal;
	font-weight: 700;
	font-size: 1em;
	letter-spacing: -0.042em;
	padding-inline-end: 0;
}

.md-logo--lg {
	gap: clamp(0.55rem, 1vw, 0.8rem);
}

.md-logo--lg .md-logo__mark {
	width: clamp(38px, 3.6vw, 46px);
}

.md-logo--lg .md-logo__text {
	font-size: clamp(1.15rem, 1.4vw, 1.35rem);
}

.md-nav {
	display: flex;
	align-items: center;
	gap: clamp(0.1rem, 0.7vw, 0.5rem);
	margin-inline: auto;
}

.md-nav__link {
	position: relative;
	padding: 0.6em 0.95em;
	border-radius: 999px;
	font-size: 0.86rem;
	font-weight: 500;
	letter-spacing: -0.008em;
	color: var(--muted);
	white-space: nowrap;
	transition: color 0.35s var(--e-out);
	z-index: 1;
}

.md-nav__link:hover,
.md-nav__link.is-active {
	color: var(--ink);
}

/* Shared pill that slides between links */
.md-nav__pill {
	position: absolute;
	top: 0;
	left: 0;
	height: 100%;
	border-radius: 999px;
	background: color-mix(in srgb, var(--ink) 7%, transparent);
	opacity: 0;
	transform: translate3d(var(--x, 0px), 0, 0);
	width: var(--w, 0px);
	transition:
		transform 0.5s var(--e-out),
		width 0.5s var(--e-out),
		opacity 0.3s var(--e-out);
	pointer-events: none;
	z-index: 0;
}

.md-nav:hover .md-nav__pill,
.md-nav__pill.is-on {
	opacity: 1;
}

.md-header__cta {
	flex: 0 0 auto;
}

.md-burger {
	display: none;
	width: 46px;
	height: 46px;
	border-radius: 50%;
	background: var(--ink);
	position: relative;
	flex: 0 0 auto;
}

.md-burger span {
	position: absolute;
	left: 50%;
	translate: -50% 0;
	width: 17px;
	height: 1.6px;
	background: var(--paper);
	border-radius: 2px;
	transition: all 0.45s var(--e-out);
}

.md-burger span:nth-child(1) {
	top: 19px;
}

.md-burger span:nth-child(2) {
	bottom: 19px;
	width: 11px;
	left: calc(50% - 3px);
}

.md-burger.is-open span:nth-child(1) {
	top: 22px;
	rotate: 45deg;
}

.md-burger.is-open span:nth-child(2) {
	bottom: 22.4px;
	width: 17px;
	left: 50%;
	rotate: -45deg;
}

/* Mobile overlay menu */
.md-menu {
	position: fixed;
	inset: 0;
	z-index: 99;
	background: var(--ink);
	color: var(--paper);
	display: flex;
	flex-direction: column;
	justify-content: center;
	padding: clamp(5rem, 14vh, 8rem) var(--gut) clamp(2rem, 6vh, 4rem);
	clip-path: circle(0% at calc(100% - 46px) 46px);
	transition: clip-path 0.8s var(--e-inout);
	pointer-events: none;
	overflow-y: auto;
}

.md-menu.is-open {
	clip-path: circle(150% at calc(100% - 46px) 46px);
	pointer-events: auto;
}

.md-menu__nav {
	display: flex;
	flex-direction: column;
	gap: 0.15em;
}

.md-menu__nav a {
	font-size: clamp(1.9rem, 9vw, 3.1rem);
	font-weight: 700;
	letter-spacing: -0.04em;
	line-height: 1.1;
	opacity: 0;
	transform: translate3d(0, 30px, 0);
	transition:
		opacity 0.6s var(--e-out),
		transform 0.6s var(--e-out);
	transition-delay: calc(var(--i) * 45ms + 0.15s);
}

.md-menu.is-open .md-menu__nav a {
	opacity: 1;
	transform: none;
}

.md-menu__foot {
	margin-top: auto;
	padding-top: clamp(2rem, 5vh, 3rem);
	display: flex;
	flex-direction: column;
	gap: 1rem;
	opacity: 0;
	transition: opacity 0.5s var(--e-out) 0.45s;
}

.md-menu.is-open .md-menu__foot {
	opacity: 1;
}

/* Scroll progress hairline */
.md-progress {
	position: fixed;
	top: 0;
	left: 0;
	height: 2px;
	width: 100%;
	transform-origin: left;
	transform: scaleX(0);
	background: linear-gradient(90deg, var(--teal), var(--flame));
	z-index: 101;
	pointer-events: none;
}

@supports (animation-timeline: scroll()) {
	.md-progress {
		animation: md-progress linear;
		animation-timeline: scroll(root block);
	}

	@keyframes md-progress {
		to {
			transform: scaleX(1);
		}
	}
}

/* -------------------------------------------------------------------------
   11. Hero
   ---------------------------------------------------------------------- */

.md-hero {
	position: relative;
	min-height: min(980px, 100svh);
	display: flex;
	align-items: center;
	padding-block: clamp(7.5rem, 16vh, 11rem) clamp(3rem, 8vh, 6rem);
	overflow: hidden;
	isolation: isolate;
}

.md-hero__glow {
	position: absolute;
	z-index: 0;
	inset: -28% -18% -8% -12%;
	background:
		radial-gradient(48% 42% at 72% 34%, color-mix(in srgb, var(--teal) 24%, transparent) 0%, transparent 68%),
		radial-gradient(38% 34% at 18% 74%, color-mix(in srgb, var(--gold) 22%, transparent) 0%, transparent 70%),
		radial-gradient(32% 30% at 88% 84%, color-mix(in srgb, var(--flame) 16%, transparent) 0%, transparent 72%);
	filter: blur(20px);
	pointer-events: none;
}

.md-hero__grid {
	position: relative;
	z-index: 2;
	display: grid;
	grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.24fr);
	align-items: center;
	gap: clamp(1.2rem, 3.5vw, 3rem);
	width: 100%;
}

.md-hero__copy {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: clamp(1.05rem, 1.7vw, 1.45rem);
	min-width: 0;
}

.md-hero__title {
	font-size: var(--fs-h1);
	font-weight: 800;
	line-height: 0.94;
	letter-spacing: -0.044em;
	text-wrap: balance;
	/* Negative leading lets glyphs spill outside the box — pad it back. */
	margin-block: 0.12em 0.1em;
}

.md-hero__title-line {
	display: block;
}

.md-hero__title .md-em {
	color: var(--flame);
}

.md-checks {
	display: grid;
	gap: 0.7rem;
	max-width: 48ch;
}

.md-checks li {
	display: flex;
	align-items: flex-start;
	gap: 0.75rem;
	font-size: clamp(0.94rem, 1vw, 1.02rem);
	line-height: 1.4;
	opacity: 0;
	transform: translate3d(0, 12px, 0);
	transition:
		opacity 0.6s var(--e-out),
		transform 0.6s var(--e-out);
	transition-delay: calc(var(--i) * 90ms + 0.75s);
}

.md-hero.is-ready .md-checks li {
	opacity: 1;
	transform: none;
}

.md-check-ico {
	flex: 0 0 auto;
	width: 21px;
	height: 21px;
	margin-top: 1px;
	border-radius: 50%;
	background: var(--teal);
	display: grid;
	place-items: center;
}

.md-check-ico svg {
	width: 11px;
	height: 11px;
	stroke: #fff;
	stroke-width: 2.6;
	fill: none;
	stroke-linecap: round;
	stroke-linejoin: round;
	stroke-dasharray: 20;
	stroke-dashoffset: 20;
	transition: stroke-dashoffset 0.5s var(--e-out);
	transition-delay: calc(var(--i) * 90ms + 0.95s);
}

.md-hero.is-ready .md-check-ico svg {
	stroke-dashoffset: 0;
}

.md-hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	padding-top: 0.4rem;
}

/* Cycling phrase chip */
.md-phrase {
	display: inline-flex;
	flex-direction: column;
	gap: 0.15rem;
	padding: 0.8rem 1.2rem;
	border-radius: var(--r-sm);
	background: color-mix(in srgb, var(--paper) 65%, transparent);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
	box-shadow: inset 0 0 0 1px var(--line);
	min-height: 68px;
	justify-content: center;
	max-width: max-content;
}

.md-phrase__row {
	display: flex;
	align-items: center;
	gap: 0.55rem;
}

.md-phrase__wave {
	display: flex;
	align-items: flex-end;
	gap: 2px;
	height: 13px;
}

.md-phrase__wave i {
	display: block;
	width: 2.5px;
	border-radius: 2px;
	background: var(--teal);
	height: 30%;
	animation: md-wave 1.1s var(--e-inout) infinite alternate;
	animation-delay: calc(var(--i) * 110ms);
}

.md-phrase__wave--flame i {
	background: var(--flame);
}

@keyframes md-wave {
	from {
		height: 22%;
	}
	to {
		height: 100%;
	}
}

@keyframes md-spin {
	to {
		--md-angle: 360deg;
	}
}

@keyframes md-rotate {
	to {
		rotate: 360deg;
	}
}

.md-phrase__en {
	font-weight: 700;
	font-size: clamp(0.95rem, 1.1vw, 1.08rem);
	letter-spacing: -0.02em;
}

.md-phrase__ru {
	font-size: 0.84rem;
	color: var(--muted);
}

.md-phrase__en,
.md-phrase__ru {
	transition:
		opacity 0.45s var(--e-out),
		transform 0.45s var(--e-out);
}

.md-phrase.is-swapping .md-phrase__en,
.md-phrase.is-swapping .md-phrase__ru {
	opacity: 0;
	transform: translate3d(0, -8px, 0);
}

/* Hero portrait */
.md-hero__media {
	position: relative;
	display: flex;
	justify-content: center;
	align-items: center;
	width: 100%;
	overflow: visible;
}

.md-portrait {
	position: relative;
	width: 100%;
	display: grid;
	place-items: center;
	overflow: visible;
	/* Блок уменьшен на 10% по высоте и ширине. */
	scale: 0.9;
}

/* Круги hero: синий диск запечён в фото и движется с автором в параллаксе —
   отдельный статичный диск убран, чтобы не двоилось. Остались пунктирное кольцо
   и слабый светлый ореол, как в «Авторе курса». Плашку md-phrase не трогаем. */
.md-portrait__ring {
	position: absolute;
	z-index: 1;
	top: 50%;
	left: 50%;
	width: 100%;
	aspect-ratio: 1;
	translate: -50% -50%;
	border-radius: 50%;
	border: 1px dashed var(--line-strong);
	animation: md-rotate 40s linear infinite;
	pointer-events: none;
}

/* Второй круг слабее цветом — светлая полоса вокруг запечённого диска, как ореол в «Авторе курса». */
.md-portrait__halo {
	position: absolute;
	z-index: 0;
	top: 50%;
	left: 50%;
	width: 94%;
	aspect-ratio: 1;
	translate: -50% -50%;
	border-radius: 50%;
	background: radial-gradient(
		circle at 50% 42%,
		color-mix(in srgb, var(--teal-mist) 70%, transparent) 68%,
		transparent 72%
	);
	pointer-events: none;
}

.md-portrait__stage {
	position: relative;
	z-index: 2;
	width: 100%;
	transform: translate3d(var(--px, 0px), var(--py, 0px), 0);
	transition: transform 1s var(--e-out);
}

.md-portrait__img {
	position: relative;
	z-index: 2;
	width: 100%;
	filter: drop-shadow(0 28px 40px rgba(11, 12, 15, 0.18));
	opacity: 0;
	transform: translate3d(0, 40px, 0) scale(0.96);
	transition:
		opacity 1.1s var(--e-out) 0.35s,
		transform 1.2s var(--e-out) 0.35s;
}

.md-hero.is-ready .md-portrait__img {
	opacity: 1;
	transform: none;
}

/* Плашка с фразами сдвинута левее нижнего края круга (скрин 1), чтобы не перекрывать преподавателя. */
.md-portrait .md-phrase {
	position: absolute;
	z-index: 4;
	left: 2%;
	bottom: 5%;
	translate: 0;
	margin: 0;
	background: color-mix(in srgb, var(--paper) 94%, transparent);
	box-shadow:
		0 10px 28px -16px rgba(11, 12, 15, 0.35),
		inset 0 0 0 1px var(--line);
}

/* Scroll cue */
.md-cue {
	position: absolute;
	left: 50%;
	bottom: clamp(1rem, 3vh, 2rem);
	translate: -50% 0;
	z-index: 3;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.55rem;
	font-size: 0.68rem;
	font-weight: 600;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	color: var(--faint);
}

.md-cue__rail {
	width: 1px;
	height: 46px;
	background: var(--line-strong);
	overflow: hidden;
	position: relative;
}

.md-cue__rail::after {
	content: "";
	position: absolute;
	inset: 0;
	background: var(--flame);
	animation: md-cue 2.1s var(--e-inout) infinite;
}

@keyframes md-cue {
	0% {
		transform: translateY(-100%);
	}
	60%,
	100% {
		transform: translateY(100%);
	}
}

/* -------------------------------------------------------------------------
   12. Marquee
   ---------------------------------------------------------------------- */

.md-marquee {
	position: relative;
	z-index: 2;
	overflow: hidden;
	padding-block: clamp(0.9rem, 1.6vw, 1.35rem);
	background: var(--ink);
	color: var(--paper);
	border-block: 1px solid var(--ink);
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
	mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.md-marquee__track {
	display: flex;
	width: max-content;
	gap: clamp(1.6rem, 3vw, 3rem);
	animation: md-marquee 34s linear infinite;
}

.md-marquee:hover .md-marquee__track {
	animation-play-state: paused;
}

.md-marquee__track span {
	display: inline-flex;
	align-items: center;
	gap: clamp(1.6rem, 3vw, 3rem);
	font-size: clamp(0.85rem, 1.15vw, 1.05rem);
	font-weight: 600;
	letter-spacing: -0.015em;
	white-space: nowrap;
}

.md-marquee__track span::after {
	content: "";
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--flame);
	flex: 0 0 auto;
}

@keyframes md-marquee {
	to {
		transform: translate3d(-50%, 0, 0);
	}
}

/* -------------------------------------------------------------------------
   13. Pain вЂ” sticky card deck
   ---------------------------------------------------------------------- */

.md-pain__layout {
	display: grid;
	grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
	gap: clamp(2rem, 5vw, 5rem);
	align-items: start;
}

.md-pain__aside {
	position: sticky;
	top: clamp(7rem, 18vh, 11rem);
}

.md-pain__aside > * + * {
	margin-top: 1.4rem;
}

.md-pain__count {
	display: block;
	font-size: clamp(1.08rem, 1.5vw, 1.32rem);
	font-weight: 600;
	letter-spacing: -0.02em;
	line-height: 1.35;
	text-transform: none;
	color: var(--ink);
	max-width: 16em;
}

.md-pain__count .md-em {
	font-weight: 800;
}

.md-pain__stack {
	display: grid;
	gap: clamp(1rem, 2vw, 1.4rem);
	padding-bottom: 12vh;
}

.md-pain__card {
	position: sticky;
	top: calc(clamp(7rem, 18vh, 11rem) + var(--i) * 14px);
	display: flex;
	align-items: center;
	gap: clamp(1rem, 2.2vw, 1.8rem);
	padding: clamp(1.3rem, 2.4vw, 2rem);
	border-radius: var(--r-lg);
	background: var(--paper);
	box-shadow:
		inset 0 0 0 1px var(--line),
		var(--sh-md);
	cursor: pointer;
	transition:
		transform 0.6s var(--e-out),
		box-shadow 0.5s var(--e-out);
}

.md-pain__card:hover {
	box-shadow:
		inset 0 0 0 1px var(--line-strong),
		var(--sh-lg);
}

.md-pain__card.is-picked {
	box-shadow:
		inset 0 0 0 1.5px var(--flame),
		var(--sh-md);
}

.md-pain__card.is-picked:hover {
	box-shadow:
		inset 0 0 0 1.5px var(--flame),
		var(--sh-lg);
}

.md-pain__num {
	flex: 0 0 auto;
	display: grid;
	place-items: center;
	width: clamp(48px, 5.4vw, 64px);
	aspect-ratio: 1;
	border-radius: 50%;
	background: var(--tone, var(--teal-mist));
	font-size: clamp(1rem, 1.4vw, 1.2rem);
	font-weight: 800;
	letter-spacing: -0.03em;
	color: var(--ink);
	font-variant-numeric: tabular-nums;
}

.md-pain__card h3 {
	font-size: clamp(1.1rem, 1.85vw, 1.6rem);
	font-weight: 700;
	line-height: 1.16;
	letter-spacing: -0.028em;
	text-wrap: balance;
}

@supports (animation-timeline: view()) {
	.md-pain__card {
		animation: md-deck linear both;
		animation-timeline: view();
		animation-range: exit -10% exit 90%;
	}

	@keyframes md-deck {
		to {
			transform: scale(0.93) translateY(-8px);
			filter: brightness(0.97);
		}
	}
}

/* -------------------------------------------------------------------------
   14. Empathy band
   ---------------------------------------------------------------------- */

.md-empathy {
	position: relative;
	overflow: hidden;
}

.md-empathy__glow {
	position: absolute;
	left: -15%;
	right: -15%;
	bottom: -35%;
	height: 95%;
	background: radial-gradient(50% 50% at 50% 50%, color-mix(in srgb, var(--teal) 42%, transparent), transparent 70%);
	filter: blur(30px);
	pointer-events: none;
}

.md-empathy__grid {
	position: relative;
	z-index: 2;
	display: grid;
	grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
	gap: clamp(1.2rem, 3vw, 3rem);
	align-items: center;
}

.md-big-num {
	display: block;
	width: max-content;
	max-width: 100%;
	overflow: visible;
	padding-inline: 0.06em 0.1em;
	font-size: clamp(5.2rem, 14vw, 12.5rem);
	font-weight: 800;
	line-height: 0.9;
	letter-spacing: -0.04em;
	font-variant-numeric: tabular-nums;
	background: linear-gradient(165deg, #ff9a62 0%, var(--flame) 48%, #e24a12 88%, #c43508 100%);
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

.md-empathy__copy h2 .md-em {
	color: var(--flame);
}

.md-empathy__copy > * + * {
	margin-top: 1.2rem;
}

.md-empathy__copy p {
	font-size: clamp(1.02rem, 1.35vw, 1.22rem);
	line-height: 1.55;
	color: var(--muted);
	max-width: 52ch;
	text-wrap: pretty;
}

/* -------------------------------------------------------------------------
   15. Method вЂ” sticky media + stepped list
   ---------------------------------------------------------------------- */

.md-method__layout {
	display: grid;
	grid-template-columns: minmax(0, 0.74fr) minmax(0, 1.16fr);
	gap: clamp(1.6rem, 4vw, 4.5rem);
	align-items: start;
}

.md-method__steps {
	position: relative;
	z-index: 1;
	display: grid;
	gap: clamp(0.45rem, 1vw, 0.75rem);
	max-width: 28rem;
}

.md-step {
	position: relative;
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: clamp(0.85rem, 1.6vw, 1.2rem);
	padding: 0.85rem 1.05rem;
	border-radius: var(--r-md);
	cursor: default;
	transition:
		background 0.55s var(--e-out),
		box-shadow 0.55s var(--e-out),
		transform 0.55s var(--e-out);
}

.md-step.is-active {
	background: var(--paper);
	box-shadow:
		inset 0 0 0 1px var(--line),
		var(--sh-sm);
}

.md-step__n {
	display: grid;
	place-items: center;
	width: clamp(38px, 4vw, 46px);
	aspect-ratio: 1;
	border-radius: 50%;
	box-shadow: inset 0 0 0 1px var(--line-strong);
	font-size: 0.86rem;
	font-weight: 700;
	font-variant-numeric: tabular-nums;
	transition:
		background 0.5s var(--e-out),
		color 0.5s var(--e-out),
		box-shadow 0.5s var(--e-out);
}

.md-step.is-active .md-step__n {
	background: var(--ink);
	color: var(--paper);
	box-shadow: inset 0 0 0 1px var(--ink);
}

.md-step__tag {
	display: inline-block;
	font-size: 0.68rem;
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--flame);
	margin-bottom: 0.35rem;
}

.md-step h3 {
	font-size: clamp(1.08rem, 1.6vw, 1.4rem);
	font-weight: 700;
	line-height: 1.2;
	letter-spacing: -0.026em;
}

.md-step p {
	margin-top: 0.45rem;
	color: var(--muted);
	font-size: clamp(0.92rem, 1vw, 1rem);
	line-height: 1.5;
	max-width: 44ch;
	text-wrap: pretty;
}

.md-method__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: stretch;
	gap: 0.6rem;
	margin-top: clamp(1.4rem, 3vw, 2.2rem);
}

.md-method__actions .md-btn {
	box-sizing: border-box;
	padding: 0.95em 1.4em;
}

/* Inset-кольцо ghost съедает 2px высоты — бордер в box, чтобы совпасть с primary. */
.md-method__actions .md-btn--ghost {
	box-shadow: none;
	border: 1px solid var(--line-strong);
}

.md-method__actions .md-btn--ghost:hover,
.md-method__actions .md-btn--ghost:focus-visible {
	border-color: transparent;
	box-shadow: none;
}

.md-method__media {
	position: sticky;
	top: clamp(7rem, 16vh, 10rem);
	z-index: 0;
	display: grid;
	place-items: center;
	padding: clamp(1.5rem, 3vw, 2.5rem);
	/* Keeps the blob and disc from bleeding past the media column. */
	isolation: isolate;
}

.md-method__disc {
	position: absolute;
	inset: 6% 4%;
	border-radius: 50%;
	background: radial-gradient(circle at 50% 40%, var(--teal-mist), transparent 68%);
}

.md-method__blob {
	position: absolute;
	inset: 12% 8%;
	background: var(--teal);
	opacity: 0.14;
	border-radius: 62% 38% 46% 54% / 55% 48% 52% 45%;
	animation: md-blob 16s var(--e-inout) infinite alternate;
}

@keyframes md-blob {
	to {
		border-radius: 42% 58% 60% 40% / 45% 60% 40% 55%;
		rotate: 18deg;
	}
}

.md-method__phone {
	position: relative;
	z-index: 2;
	width: min(100%, 598px);
	filter: drop-shadow(0 42px 60px rgba(11, 12, 15, 0.2));
}

@supports (animation-timeline: view()) {
	.md-method__phone {
		animation: md-phone-lift linear both;
		animation-timeline: view();
		animation-range: entry 0% cover 60%;
	}

	@keyframes md-phone-lift {
		from {
			transform: translateY(48px) scale(0.94) rotate(-3deg);
		}
		to {
			transform: none;
		}
	}
}

/* -------------------------------------------------------------------------
   16. Await вЂ” bento grid
   ---------------------------------------------------------------------- */

.md-bento {
	display: grid;
	grid-template-columns: repeat(6, 1fr);
	gap: clamp(0.75rem, 1.4vw, 1.15rem);
}

.md-bento__item {
	position: relative;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	min-height: clamp(200px, 22vw, 290px);
	padding: clamp(1.35rem, 2.4vw, 2.1rem);
	border-radius: var(--r-lg);
	background: var(--paper);
	box-shadow: inset 0 0 0 1px var(--line);
	isolation: isolate;
	transition:
		transform 0.6s var(--e-out),
		box-shadow 0.6s var(--e-out),
		color 0.6s var(--e-out);
}

/* Wash of colour that wipes in on hover. The tone is dropped toward ink so the
   white copy stays legible — the pale mist and sky tones cannot carry it raw. */
.md-bento__item::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: color-mix(
		in srgb,
		var(--tone, var(--teal)) var(--tone-strength, 52%),
		var(--ink)
	);
	clip-path: circle(0% at 50% 100%);
	transition: clip-path 0.72s var(--e-out);
}

.md-bento__item:hover {
	transform: translateY(-5px);
	color: #fff;
	box-shadow:
		inset 0 0 0 1px transparent,
		var(--sh-lg);
}

.md-bento__item:hover::before {
	clip-path: circle(142% at 50% 100%);
}

.md-bento__item:hover p {
	color: color-mix(in srgb, #fff 88%, transparent);
}

.md-bento__item:hover .md-bento__n {
	color: color-mix(in srgb, #fff 26%, transparent);
}

/* Pale tones need a heavier ink share than the already-saturated flame. */
.md-bento__item:nth-child(1) {
	grid-column: span 4;
	/* Крупная карточка «50 уроков»: hover почти чёрный, с лёгким холодным оттенком. */
	--tone-strength: 18%;
}

.md-bento__item:nth-child(2) {
	grid-column: span 2;
	--tone-strength: 54%;
}

.md-bento__item:nth-child(3) {
	grid-column: span 2;
	--tone-strength: 46%;
}

.md-bento__item:nth-child(4) {
	grid-column: span 4;
	--tone-strength: 62%;
}

.md-bento__n {
	position: absolute;
	top: clamp(0.7rem, 1.5vw, 1.2rem);
	right: clamp(1.1rem, 2.2vw, 1.9rem);
	font-size: clamp(2.8rem, 5.4vw, 4.8rem);
	font-weight: 800;
	line-height: 1;
	letter-spacing: -0.06em;
	color: color-mix(in srgb, var(--ink) 8%, transparent);
	font-variant-numeric: tabular-nums;
	transition: color 0.6s var(--e-out);
}

.md-bento__item h3 {
	/* Keeps long titles clear of the ghost numeral in the top-right. */
	padding-right: clamp(2.6rem, 9%, 4rem);
	font-size: clamp(1.15rem, 2vw, 1.75rem);
	font-weight: 700;
	line-height: 1.14;
	letter-spacing: -0.03em;
	text-wrap: balance;
}

.md-bento__item p {
	margin-top: 0.6rem;
	font-size: 0.94rem;
	line-height: 1.5;
	color: var(--muted);
	max-width: 40ch;
	transition: color 0.6s var(--e-out);
	text-wrap: pretty;
}

.md-quote {
	margin-top: clamp(2rem, 4vw, 3.2rem);
	padding: clamp(2.4rem, 5vw, 4.2rem) clamp(1.6rem, 4vw, 3.4rem) clamp(1.6rem, 3vw, 2.6rem);
	border-radius: var(--r-lg);
	background: var(--ink);
	color: var(--paper);
	text-align: center;
}

.md-quote > p {
	font-size: clamp(1.2rem, 2.6vw, 2.15rem);
	font-weight: 700;
	line-height: 1.16;
	letter-spacing: -0.035em;
	text-wrap: balance;
}

.md-quote .md-em {
	color: var(--flame);
}

.md-quote__live {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 0.45rem 1.1rem;
	margin-top: clamp(1.1rem, 2.4vw, 1.8rem);
	padding: 0;
	border: 0;
	background: none;
	box-shadow: none;
}

.md-quote__live .md-phrase__en {
	font-weight: 700;
	font-size: clamp(0.92rem, 1.15vw, 1.08rem);
	letter-spacing: -0.02em;
	color: var(--paper);
}

.md-quote__live .md-phrase__ru {
	font-size: 0.88rem;
	font-weight: 500;
	color: color-mix(in srgb, #f5f2ea 86%, transparent);
}

.md-quote__live .md-phrase__en,
.md-quote__live .md-phrase__ru {
	transition:
		opacity 0.45s var(--e-out),
		transform 0.45s var(--e-out);
}

.md-quote__live.is-swapping .md-phrase__en,
.md-quote__live.is-swapping .md-phrase__ru {
	opacity: 0;
	transform: translate3d(0, -8px, 0);
}

/* -------------------------------------------------------------------------
   17. Levels
   ---------------------------------------------------------------------- */

.md-levels {
	position: relative;
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: clamp(0.9rem, 1.8vw, 1.5rem);
	align-items: stretch;
}

/* An open or closing card grows on its own — stretch resumes only after close. */
.md-levels:has(.is-open),
.md-levels:has(.is-collapsing) {
	align-items: start;
}

.md-levels__rail {
	position: absolute;
	top: 34px;
	left: 8%;
	right: 8%;
	height: 2px;
	background: var(--line-strong);
	border-radius: 2px;
	pointer-events: none;
}

.md-level {
	position: relative;
	display: flex;
	flex-direction: column;
	padding: clamp(1.4rem, 2.4vw, 2.1rem);
	border-radius: var(--r-lg);
	background: var(--paper);
	box-shadow: inset 0 0 0 1px var(--line);
	cursor: pointer;
	transition:
		transform 0.55s var(--e-out),
		box-shadow 0.55s var(--e-out);
}

.md-level:hover,
.md-level.is-open {
	transform: translateY(-4px);
	box-shadow:
		inset 0 0 0 1.5px var(--flame),
		var(--sh-md);
}

.md-level__head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 0.75rem;
	margin-bottom: 1.15rem;
}

.md-level__badge {
	align-self: flex-start;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	min-width: 0;
	padding: 0.55em 1em;
	border-radius: 999px;
	background: var(--ink);
	color: var(--paper);
	font-size: 0.85rem;
	font-weight: 700;
	letter-spacing: -0.01em;
	transition: background 0.35s var(--e-out);
}

.md-level__meta {
	display: flex;
	flex-direction: column;
	align-items: stretch;
	gap: 0.38rem;
	flex: 0 0 auto;
	width: max-content;
	padding-top: 0.12rem;
}

.md-level__step {
	font-size: 0.68rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--ink);
	line-height: 1;
	white-space: nowrap;
	transition: color 0.35s var(--e-out);
}

.md-level__pills {
	display: flex;
	align-items: center;
	width: 100%;
	gap: 0.22rem;
}

.md-level__pills i {
	flex: 1 1 0;
	display: block;
	min-width: 0;
	height: 0.38rem;
	border-radius: 999px;
	box-sizing: border-box;
	background: transparent;
	border: 1.5px solid var(--ink);
	transition:
		background 0.35s var(--e-out),
		border-color 0.35s var(--e-out);
}

.md-level__pills i.is-on {
	background: var(--ink);
	border-color: var(--ink);
}

.md-level:hover .md-level__badge,
.md-level.is-open .md-level__badge,
.md-level.is-collapsing .md-level__badge {
	background: var(--flame);
}

.md-level:hover .md-level__step,
.md-level.is-open .md-level__step,
.md-level.is-collapsing .md-level__step {
	color: var(--flame);
}

.md-level:hover .md-level__pills i,
.md-level.is-open .md-level__pills i,
.md-level.is-collapsing .md-level__pills i {
	border-color: var(--flame);
}

.md-level:hover .md-level__pills i.is-on,
.md-level.is-open .md-level__pills i.is-on,
.md-level.is-collapsing .md-level__pills i.is-on {
	background: var(--flame);
	border-color: var(--flame);
}

.md-level__lead {
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--ink);
	margin-bottom: 0.5rem;
}

.md-level > p {
	color: var(--muted);
	line-height: 1.5;
	font-size: 0.98rem;
	text-wrap: pretty;
}

.md-level__result {
	margin-top: 0.9rem;
	font-size: clamp(1.02rem, 1.35vw, 1.2rem);
	font-weight: 700;
	line-height: 1.24;
	letter-spacing: -0.024em;
	color: var(--ink) !important;
}

.md-level__body {
	display: grid;
	grid-template-rows: 0fr;
	transition: grid-template-rows 0.6s var(--e-out);
}

.md-level.is-open .md-level__body {
	grid-template-rows: 1fr;
}

.md-level__body > div {
	overflow: hidden;
}

.md-level__list {
	display: grid;
	gap: 0.6rem;
	padding-top: 1.1rem;
}

.md-level__list li {
	position: relative;
	padding-left: 1.5rem;
	font-size: 0.93rem;
	line-height: 1.45;
	color: var(--muted);
}

.md-level__list li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0.55em;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--teal);
	opacity: 0.45;
}

.md-level__more {
	margin-top: auto;
	padding-top: 1.2rem;
	align-self: flex-start;
	display: inline-flex;
	align-items: center;
	gap: 0.55rem;
	font-size: 0.88rem;
	font-weight: 600;
	color: var(--ink);
	pointer-events: none;
	transition: color 0.35s var(--e-out);
}

.md-level__more i {
	display: grid;
	place-items: center;
	width: 26px;
	height: 26px;
	border-radius: 50%;
	box-shadow: inset 0 0 0 1px var(--line-strong);
	font-style: normal;
	font-size: 1rem;
	line-height: 1;
	transition:
		transform 0.45s var(--e-spring),
		background 0.4s var(--e-out),
		color 0.4s var(--e-out),
		box-shadow 0.4s var(--e-out);
}

.md-level:hover .md-level__more,
.md-level.is-open .md-level__more {
	color: var(--flame);
}

.md-level:hover .md-level__more i,
.md-level.is-open .md-level__more i {
	background: var(--flame);
	color: #fff;
	box-shadow: none;
}

.md-level.is-open .md-level__more i {
	transform: rotate(135deg);
}

/* -------------------------------------------------------------------------
   18. Cinema / open lesson
   ---------------------------------------------------------------------- */

.md-cinema {
	position: relative;
	margin-top: clamp(2rem, 4vw, 3.4rem);
	border-radius: var(--r-xl);
	overflow: hidden;
	background: var(--ink);
	box-shadow: var(--sh-lg);
	aspect-ratio: 16 / 8.2;
}

.md-cinema img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transform: scale(1.06);
	transition: transform 1.2s var(--e-out);
}

.md-cinema:hover img {
	transform: scale(1.11);
}

.md-cinema::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(11, 12, 15, 0.18), rgba(11, 12, 15, 0.42));
	pointer-events: none;
}

.md-play {
	position: absolute;
	inset: 0;
	z-index: 3;
	display: grid;
	place-items: center;
	width: 100%;
	height: 100%;
}

.md-play__core {
	position: relative;
	display: grid;
	place-items: center;
	width: clamp(78px, 9vw, 112px);
	aspect-ratio: 1;
	border-radius: 50%;
	background: var(--paper);
	color: var(--ink);
	box-shadow: var(--sh-md);
	transition:
		transform 0.5s var(--e-spring),
		background 0.4s var(--e-out),
		color 0.4s var(--e-out);
}

.md-play__core svg {
	width: 26%;
	height: 26%;
	margin-left: 8%;
	fill: currentColor;
}

.md-play:hover .md-play__core {
	transform: scale(1.09);
	background: var(--flame);
	color: #fff;
}

.md-play__core::before,
.md-play__core::after {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: 50%;
	border: 1px solid rgba(245, 242, 234, 0.6);
	animation: md-ripple 2.8s var(--e-out) infinite;
}

.md-play__core::after {
	animation-delay: 1.4s;
}

@keyframes md-ripple {
	from {
		transform: scale(1);
		opacity: 0.85;
	}
	to {
		transform: scale(1.85);
		opacity: 0;
	}
}

.md-cinema__meta {
	position: absolute;
	z-index: 3;
	left: clamp(1rem, 2.4vw, 2rem);
	bottom: clamp(1rem, 2.4vw, 2rem);
	display: flex;
	align-items: center;
	gap: 0.6rem;
	padding: 0.6rem 1rem;
	border-radius: 999px;
	background: rgba(11, 12, 15, 0.42);
	backdrop-filter: blur(12px);
	-webkit-backdrop-filter: blur(12px);
	box-shadow: inset 0 0 0 1px rgba(245, 242, 234, 0.18);
	color: var(--paper);
	font-size: 0.8rem;
	font-weight: 600;
}

.md-cinema__meta i {
	width: 7px;
	height: 7px;
	border-radius: 50%;
	background: var(--flame);
	animation: md-pulse 1.8s var(--e-inout) infinite;
}

@keyframes md-pulse {
	50% {
		opacity: 0.25;
	}
}

@supports (animation-timeline: view()) {
	.md-cinema {
		animation: md-cinema-open linear both;
		animation-timeline: view();
		animation-range: entry 6% cover 46%;
	}

	@keyframes md-cinema-open {
		from {
			clip-path: inset(6% 12% 6% 12% round 60px);
			transform: scale(0.94);
		}
		to {
			clip-path: inset(0 0 0 0 round 48px);
			transform: none;
		}
	}
}

/* -------------------------------------------------------------------------
   19. Author
   ---------------------------------------------------------------------- */

.md-author__grid {
	display: grid;
	grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
	gap: clamp(2rem, 5vw, 5rem);
	align-items: center;
}

.md-author__media {
	position: relative;
	display: grid;
	place-items: center;
}

.md-author__ring {
	position: absolute;
	inset: 4%;
	border-radius: 50%;
	border: 1px dashed var(--line-strong);
	animation: md-rotate 40s linear infinite;
}

.md-author__disc {
	position: absolute;
	inset: 12%;
	border-radius: 50%;
	background: radial-gradient(circle at 46% 38%, var(--teal-mist), transparent 70%);
}

.md-author__img {
	position: relative;
	z-index: 2;
	width: min(100%, 480px);
	filter: drop-shadow(0 36px 54px rgba(11, 12, 15, 0.2));
}

.md-author__copy > * + * {
	margin-top: 1.05rem;
}

.md-author__copy p {
	color: var(--muted);
	line-height: 1.55;
	max-width: 50ch;
	text-wrap: pretty;
}

.md-facts {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin-top: 1.3rem;
}

.md-facts span {
	display: inline-flex;
	align-items: center;
	gap: 0.45rem;
	padding: 0.5em 0.95em;
	border-radius: 999px;
	font-size: 0.82rem;
	font-weight: 600;
	box-shadow: inset 0 0 0 1px var(--line-strong);
}

.md-facts span::before {
	content: "";
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--teal);
}

.md-stats {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: clamp(0.6rem, 1.6vw, 1.4rem);
	margin-top: clamp(1.6rem, 3vw, 2.4rem);
	padding-top: clamp(1.4rem, 3vw, 2rem);
	border-top: 1px solid var(--line);
}

.md-stat b {
	display: block;
	font-size: clamp(1.9rem, 3.6vw, 3.1rem);
	font-weight: 800;
	line-height: 1;
	letter-spacing: -0.05em;
	font-variant-numeric: tabular-nums;
	color: var(--ink);
}

.md-stat > span {
	display: block;
	margin-top: 0.35rem;
	font-size: 0.8rem;
	line-height: 1.3;
	color: var(--muted);
}

/* -------------------------------------------------------------------------
   20. Reviews
   ---------------------------------------------------------------------- */

.md-slider {
	position: relative;
	overflow-x: auto;
	overflow-y: hidden;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
	-ms-overflow-style: none;
	cursor: grab;
}

.md-slider::-webkit-scrollbar {
	display: none;
}

.md-slider.is-dragging {
	cursor: grabbing;
	scroll-snap-type: none;
}

.md-slider__track {
	display: flex;
	align-items: stretch;
	gap: clamp(0.8rem, 1.5vw, 1.25rem);
	width: max-content;
	padding-block: 0.5rem;
}

.md-slider__track:has(.is-open),
.md-slider__track:has(.is-collapsing) {
	align-items: flex-start;
}

.md-review {
	scroll-snap-align: start;
	display: flex;
	flex-direction: column;
	flex: 0 0 auto;
	width: clamp(280px, 32vw, 420px);
	padding: clamp(1.4rem, 2.4vw, 2rem);
	border-radius: var(--r-lg);
	background: var(--paper);
	box-shadow: inset 0 0 0 1px var(--line);
	cursor: pointer;
	transition:
		transform 0.55s var(--e-out),
		box-shadow 0.55s var(--e-out);
}

.md-review:hover,
.md-review.is-open {
	transform: translateY(-4px);
	box-shadow:
		inset 0 0 0 1.5px var(--flame),
		var(--sh-md);
}

.md-review__top {
	display: flex;
	align-items: center;
	gap: 0.8rem;
	margin-bottom: 1.1rem;
}

.md-avatar {
	display: grid;
	place-items: center;
	width: 46px;
	aspect-ratio: 1;
	border-radius: 50%;
	background: var(--tone, var(--teal));
	color: #fff;
	font-weight: 700;
	font-size: 1.05rem;
}

.md-review__top h3 {
	font-size: 1.05rem;
	font-weight: 700;
	letter-spacing: -0.02em;
}

.md-stars {
	display: flex;
	gap: 2px;
	margin-top: 2px;
}

.md-stars svg {
	width: 12px;
	height: 12px;
	fill: var(--gold);
}

.md-review__text {
	color: var(--muted);
	line-height: 1.55;
	font-size: 0.96rem;
	text-wrap: pretty;
}

.md-review.is-open .md-review__preview {
	display: none;
}

.md-review--short {
	cursor: default;
}

.md-review__full {
	display: grid;
	grid-template-rows: 0fr;
	transition: grid-template-rows 0.6s var(--e-out);
}

.md-review.is-open .md-review__full {
	grid-template-rows: 1fr;
}

.md-review__full > div {
	overflow: hidden;
}

.md-review__full p + p {
	margin-top: 0.7rem;
}

.md-review__more {
	margin-top: auto;
	padding-top: 1.2rem;
	align-self: flex-start;
	font-size: 0.86rem;
	font-weight: 600;
	color: var(--teal);
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	pointer-events: none;
	transition: color 0.35s var(--e-out);
}

.md-review:hover .md-review__more,
.md-review.is-open .md-review__more {
	color: var(--flame);
}

.md-slider__nav {
	display: flex;
	gap: 0.6rem;
}

.md-slider__dots {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 0.45rem;
	margin-top: clamp(1.1rem, 2.2vw, 1.7rem);
}

.md-slider__dots[hidden] {
	display: none;
}

.md-slider__dot {
	width: 8px;
	height: 8px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: color-mix(in srgb, var(--ink) 18%, transparent);
	cursor: pointer;
	transition:
		width 0.45s var(--e-out),
		background 0.35s var(--e-out),
		border-radius 0.45s var(--e-out);
}

.md-slider__dot.is-active {
	width: 22px;
	border-radius: 99px;
	background: var(--flame);
}

/* Стык 08/09: обе секции на одном tint, поэтому --sec-y снизу отзывов
   и сверху FAQ складываются в двойной зазор — оставляем половину. */
#reviews.md-section {
	padding-bottom: calc(var(--sec-y) / 2);
}

#faq.md-section {
	padding-top: calc(var(--sec-y) / 2);
}

/* -------------------------------------------------------------------------
   21. Tariffs
   ---------------------------------------------------------------------- */

.md-tariffs {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: clamp(0.9rem, 1.8vw, 1.5rem);
	align-items: stretch;
	overflow: visible;
	padding: 18px 6px 10px;
}

.md-tariff {
	position: relative;
	display: flex;
	flex-direction: column;
	padding: clamp(1.5rem, 2.6vw, 2.3rem);
	border-radius: var(--r-lg);
	background: var(--paper);
	box-shadow: inset 0 0 0 1px var(--line);
	cursor: pointer;
	transition:
		transform 0.55s var(--e-out),
		box-shadow 0.55s var(--e-out),
		background 0.55s var(--e-out);
}

.md-tariff:hover {
	transform: translateY(-5px);
	box-shadow:
		inset 0 0 0 1.5px var(--flame),
		var(--sh-md);
}

.md-tariff:hover .md-btn::after {
	transform: translate3d(0, 0, 0);
}

.md-tariff:hover .md-btn--ghost {
	color: var(--paper);
	box-shadow: inset 0 0 0 1px transparent;
}

.md-tariff:hover .md-btn__arrow svg {
	transform: translate3d(120%, -120%, 0);
}

.md-tariff:hover .md-btn__arrow::after {
	transform: none;
}

/* The aurora lives between the ink fill and the copy: a layer placed behind the
   card is hidden by its own opaque background, and forcing it forward floods
   the fill instead. `isolation` keeps both pseudo layers inside this card. */
.md-tariff--hero {
	isolation: isolate;
	background: var(--ink);
	color: var(--paper);
	--muted: color-mix(in srgb, #f5f2ea 62%, transparent);
	--faint: color-mix(in srgb, #f5f2ea 42%, transparent);
	--line: color-mix(in srgb, #f5f2ea 16%, transparent);
	--line-strong: color-mix(in srgb, #f5f2ea 26%, transparent);
	box-shadow: var(--sh-lg);
}

/* The recommended plan keeps its ink fill on hover — the aurora just breathes harder. */
.md-tariff--hero:hover {
	box-shadow:
		var(--sh-lg),
		0 26px 60px -30px color-mix(in srgb, var(--flame) 85%, transparent);
}

.md-tariff--hero > *:not(.md-tariff__flag) {
	position: relative;
	z-index: 1;
}

/* Masked conic ring: the gradient only survives inside the border band. */
.md-tariff--hero::before {
	content: "";
	position: absolute;
	z-index: 2;
	inset: -2px;
	border-radius: inherit;
	padding: 2px;
	background: conic-gradient(
		from var(--md-angle),
		var(--teal),
		var(--sky),
		var(--gold),
		var(--flame),
		var(--teal)
	);
	-webkit-mask:
		linear-gradient(#000 0 0) content-box,
		linear-gradient(#000 0 0);
	mask:
		linear-gradient(#000 0 0) content-box,
		linear-gradient(#000 0 0);
	-webkit-mask-composite: xor;
	mask-composite: exclude;
	animation: md-spin 6s linear infinite;
	transition: padding 0.45s var(--e-out);
	pointer-events: none;
}

.md-tariff--hero:hover::before {
	padding: 3px;
}

/* Slow colour drift across the ink fill. `clip-path` trims the blur bleed to the
   card's rounded box, which `overflow` cannot do without cutting the ring and flag. */
.md-tariff--hero::after {
	content: "";
	position: absolute;
	z-index: 0;
	inset: 0;
	border-radius: inherit;
	background: conic-gradient(
		from var(--md-angle),
		var(--teal),
		var(--sky),
		var(--gold),
		var(--flame),
		var(--teal)
	);
	filter: blur(46px);
	clip-path: inset(0 round var(--r-lg));
	opacity: 0.24;
	animation: md-spin 11s linear infinite;
	transition: opacity 0.5s var(--e-out);
	pointer-events: none;
}

.md-tariff--hero:hover::after {
	opacity: 0.38;
}

.md-tariff__flag {
	position: absolute;
	top: -1px;
	right: clamp(1.2rem, 2.4vw, 2rem);
	translate: 0 -50%;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	padding: 0.45em 0.9em;
	border-radius: 999px;
	background: var(--flame);
	color: #fff;
	font-size: 0.74rem;
	font-weight: 700;
	letter-spacing: 0.02em;
	box-shadow: var(--sh-sm);
	white-space: nowrap;
}

.md-tariff__top {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 1rem;
	margin-bottom: 0.9rem;
}

.md-tariff__idx {
	font-size: 0.76rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	color: var(--faint);
	font-variant-numeric: tabular-nums;
}

.md-tariff h3 {
	font-size: clamp(1.35rem, 2.2vw, 1.9rem);
	font-weight: 800;
	letter-spacing: -0.034em;
	line-height: 1.05;
}

.md-tariff__audience {
	margin-top: 0.5rem;
	font-size: 0.92rem;
	line-height: 1.45;
	color: var(--muted);
	min-height: 2.6em;
	text-wrap: pretty;
}

.md-tariff__summary {
	margin-top: 0.9rem;
	font-size: 0.86rem;
	font-weight: 600;
	letter-spacing: -0.01em;
	padding: 0.5em 0.85em;
	border-radius: 999px;
	align-self: flex-start;
	box-shadow: inset 0 0 0 1px var(--line-strong);
}

.md-tariff__price {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.6rem;
	margin-top: clamp(1.2rem, 2.4vw, 1.7rem);
	padding-top: clamp(1.2rem, 2.4vw, 1.7rem);
	border-top: 1px solid var(--line);
}

.md-tariff__price--range {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	align-items: start;
	gap: 0.85rem 1rem;
}

.md-tariff__price-side {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0.28rem;
	min-width: 0;
}

.md-tariff__price-label {
	font-size: 0.68rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: var(--faint);
}

.md-tariff__price strong {
	font-size: clamp(1.9rem, 3.2vw, 2.7rem);
	font-weight: 800;
	letter-spacing: -0.045em;
	line-height: 1;
	font-variant-numeric: tabular-nums;
}

.md-tariff__price--range strong {
	font-size: clamp(1.35rem, 2.2vw, 2.05rem);
}

.md-tariff__price del {
	font-size: 1rem;
	color: var(--faint);
	text-decoration-thickness: 1.5px;
	font-variant-numeric: tabular-nums;
}

.md-tariff__list {
	display: grid;
	gap: 0.65rem;
	margin-top: clamp(1.2rem, 2.2vw, 1.6rem);
	margin-bottom: clamp(1.4rem, 2.6vw, 2rem);
}

.md-tariff__list li {
	display: flex;
	align-items: flex-start;
	gap: 0.65rem;
	font-size: 0.93rem;
	line-height: 1.4;
}

.md-tariff__list svg {
	flex: 0 0 auto;
	width: 16px;
	height: 16px;
	margin-top: 3px;
	stroke: var(--teal);
	stroke-width: 2.6;
	fill: none;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.md-tariff--hero .md-tariff__list svg {
	stroke: var(--gold);
}

.md-tariff__cta {
	margin-top: auto;
}

.md-tariff__renew {
	display: block;
	width: fit-content;
	max-width: 100%;
	margin: 0.85rem auto 0;
	padding: 0.2em 0.35em;
	text-align: center;
	font-size: 0.9rem;
	font-weight: 600;
	letter-spacing: -0.01em;
	line-height: 1.3;
	color: var(--ink);
	text-decoration: none;
	cursor: pointer;
	position: relative;
	z-index: 2;
	transition: color 0.35s var(--e-out);
}

.md-tariff__renew:hover,
.md-tariff__renew:focus-visible {
	color: var(--flame);
}

.md-tariff--hero .md-tariff__renew {
	color: var(--paper);
}

.md-tariff--hero .md-tariff__renew:hover,
.md-tariff--hero .md-tariff__renew:focus-visible {
	color: var(--flame);
}

.md-tariff__note {
	margin-top: 0.9rem;
	font-size: 0.78rem;
	color: var(--faint);
	text-align: center;
}

.md-guarantees {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: clamp(0.8rem, 2vw, 2rem);
	margin-top: clamp(2rem, 4vw, 3rem);
	padding-top: clamp(1.6rem, 3vw, 2.2rem);
	border-top: 1px solid var(--line);
}

.md-guarantees div {
	display: inline-flex;
	align-items: center;
	gap: 0.55rem;
	font-size: 0.88rem;
	color: var(--muted);
}

.md-guarantees svg {
	width: 17px;
	height: 17px;
	stroke: var(--teal);
	stroke-width: 2;
	fill: none;
	stroke-linecap: round;
	stroke-linejoin: round;
}

/* -------------------------------------------------------------------------
   22. FAQ
   ---------------------------------------------------------------------- */

.md-faq__layout {
	display: grid;
	grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
	gap: clamp(2rem, 5vw, 5rem);
	align-items: start;
}

.md-faq {
	display: grid;
	border-top: 1px solid var(--line);
}

.md-faq__item {
	border-bottom: 1px solid var(--line);
}

.md-faq__q {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem;
	width: 100%;
	padding: clamp(1.15rem, 2.2vw, 1.6rem) 0;
	text-align: left;
	font-size: clamp(1rem, 1.5vw, 1.28rem);
	font-weight: 600;
	line-height: 1.25;
	letter-spacing: -0.024em;
	transition: color 0.4s var(--e-out);
}

.md-faq__q:hover {
	color: var(--flame);
}

.md-faq__q:hover .md-faq__sign {
	background: var(--flame);
	box-shadow: none;
	color: #fff;
}

.md-faq__q:hover .md-faq__sign::before,
.md-faq__q:hover .md-faq__sign::after {
	background: #fff;
}

.md-faq__sign {
	position: relative;
	flex: 0 0 auto;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	box-shadow: inset 0 0 0 1px var(--line-strong);
	transition:
		background 0.45s var(--e-out),
		box-shadow 0.45s var(--e-out),
		rotate 0.5s var(--e-out);
}

.md-faq__sign::before,
.md-faq__sign::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	translate: -50% -50%;
	background: currentColor;
	border-radius: 2px;
	transition:
		opacity 0.4s var(--e-out),
		background 0.4s var(--e-out);
}

.md-faq__sign::before {
	width: 12px;
	height: 1.6px;
}

.md-faq__sign::after {
	width: 1.6px;
	height: 12px;
}

.md-faq__item.is-open .md-faq__sign {
	background: var(--ink);
	box-shadow: inset 0 0 0 1px var(--ink);
	rotate: 135deg;
}

.md-faq__item.is-open .md-faq__sign::before,
.md-faq__item.is-open .md-faq__sign::after {
	background: var(--paper);
}

.md-faq__item.is-open .md-faq__sign::after {
	opacity: 0;
}

.md-faq__item.is-open .md-faq__q:hover .md-faq__sign {
	background: var(--flame);
	box-shadow: none;
}

.md-faq__item.is-open .md-faq__q:hover .md-faq__sign::before,
.md-faq__item.is-open .md-faq__q:hover .md-faq__sign::after {
	background: #fff;
}

.md-faq__a {
	display: grid;
	grid-template-rows: 0fr;
	transition: grid-template-rows 0.6s var(--e-out);
}

.md-faq__item.is-open .md-faq__a {
	grid-template-rows: 1fr;
}

.md-faq__a > div {
	overflow: hidden;
}

.md-faq__a p,
.md-faq__a ul {
	color: var(--muted);
	line-height: 1.6;
	max-width: 62ch;
	text-wrap: pretty;
}

.md-faq__a > div > *:first-child {
	padding-top: 0.2rem;
}

.md-faq__a > div > *:last-child {
	padding-bottom: clamp(1.15rem, 2.2vw, 1.6rem);
}

.md-faq__a p + p,
.md-faq__a p + ul,
.md-faq__a ul + p {
	margin-top: 0.7rem;
}

.md-faq__a li {
	position: relative;
	padding-left: 1.35rem;
}

.md-faq__a li + li {
	margin-top: 0.35rem;
}

.md-faq__a li::before {
	content: "";
	position: absolute;
	left: 0.2rem;
	top: 0.62em;
	width: 5px;
	height: 5px;
	border-radius: 50%;
	background: var(--teal);
}

.md-faq__aside {
	position: sticky;
	top: clamp(7rem, 16vh, 10rem);
	padding: clamp(1.5rem, 2.8vw, 2.2rem);
	border-radius: var(--r-lg);
	background: var(--paper);
	box-shadow: inset 0 0 0 1px var(--line);
	text-align: center;
}

.md-faq__aside .md-img {
	width: min(100%, 300px);
	margin-inline: auto;
}

.md-faq__aside h3 {
	margin-top: 0.8rem;
	font-size: clamp(1.1rem, 1.8vw, 1.45rem);
	font-weight: 700;
	letter-spacing: -0.028em;
	text-wrap: balance;
}

.md-faq__aside p {
	margin-top: 0.6rem;
	margin-bottom: 1.3rem;
	color: var(--muted);
	font-size: 0.94rem;
	text-wrap: pretty;
}

/* -------------------------------------------------------------------------
   23. Final CTA + footer
   ---------------------------------------------------------------------- */

.md-final {
	position: relative;
	overflow: hidden;
	background: var(--ink);
	color: var(--paper);
	padding-block: clamp(4.5rem, 11vw, 9rem);
	text-align: center;
}

.md-final__glow {
	position: absolute;
	inset: auto -10% -60% -10%;
	height: 120%;
	background: radial-gradient(50% 50% at 50% 50%, color-mix(in srgb, var(--teal) 40%, transparent), transparent 70%);
	filter: blur(30px);
	pointer-events: none;
}

.md-final__inner {
	position: relative;
	z-index: 2;
	display: grid;
	justify-items: center;
	gap: 1.4rem;
}

.md-final h2 {
	font-size: clamp(2.3rem, 7vw, 6rem);
	font-weight: 800;
	line-height: 0.94;
	letter-spacing: -0.05em;
	max-width: 16ch;
	text-wrap: balance;
}

.md-final h2 .md-em {
	color: var(--flame);
}

.md-final p {
	color: color-mix(in srgb, #f5f2ea 66%, transparent);
	font-size: var(--fs-lead);
	max-width: 40ch;
	text-wrap: pretty;
}

.md-footer {
	background: var(--ink);
	color: var(--paper);
	padding-block: clamp(2.5rem, 5vw, 4rem) clamp(1.5rem, 3vw, 2.5rem);
	border-top: 1px solid color-mix(in srgb, #f5f2ea 12%, transparent);
}

.md-footer__grid {
	display: grid;
	grid-template-columns: minmax(0, 1.2fr) repeat(2, minmax(0, 1fr));
	gap: clamp(1.8rem, 4vw, 3.5rem);
}

.md-footer__brand p {
	margin-top: 0.9rem;
	color: color-mix(in srgb, #f5f2ea 58%, transparent);
	font-size: 0.92rem;
	max-width: 34ch;
}

.md-footer__brand .md-logo__mark {
	box-shadow:
		0 0 0 1px color-mix(in srgb, #f5f2ea 16%, transparent),
		0 14px 28px -14px rgba(0, 0, 0, 0.8);
}

.md-footer h4 {
	font-size: 0.72rem;
	font-weight: 600;
	letter-spacing: 0.14em;
	text-transform: uppercase;
	color: color-mix(in srgb, #f5f2ea 44%, transparent);
	margin: 0 0 1rem;
}

.md-footer ul {
	display: grid;
	gap: 0.6rem;
}

.md-footer li a {
	font-size: 0.93rem;
	color: color-mix(in srgb, #f5f2ea 74%, transparent);
	transition: color 0.35s var(--e-out);
}

.md-footer li a:hover,
.md-footer li a:focus-visible {
	color: var(--flame);
}

.md-footer__icon-list a:hover svg,
.md-footer__icon-list a:focus-visible svg {
	color: var(--flame);
}

.md-footer__social {
	display: flex;
	align-items: center;
	gap: 0.65rem;
	margin-top: 1.25rem;
}

.md-footer__social a {
	display: grid;
	place-items: center;
	width: 2.5rem;
	height: 2.5rem;
	border-radius: 50%;
	color: #fff;
	box-shadow: inset 0 0 0 1px color-mix(in srgb, #f5f2ea 22%, transparent);
	transition:
		background 0.35s var(--e-out),
		box-shadow 0.35s var(--e-out);
}

.md-footer__social a:hover,
.md-footer__social a:focus-visible {
	background: var(--flame);
	box-shadow: none;
}

.md-footer__brand .md-footer__icon-list {
	margin-top: 1.15rem;
}

.md-footer__social svg {
	width: 1.1rem;
	height: 1.1rem;
	max-width: none;
}

.md-footer__icon-list a {
	display: flex;
	align-items: center;
	gap: 0.65rem;
}

.md-footer__icon-list svg {
	width: 1.15rem;
	height: 1.15rem;
	flex: 0 0 auto;
	color: #fff;
	max-width: none;
}

.md-footer__icon-list .md-brand-ico {
	fill: currentColor;
}

/* Speaking club — full-width wordmark that fills orange left-to-right on hover. */
.md-footer__club {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.2em;
	width: 100%;
	margin-top: clamp(2.5rem, 6vw, 4.5rem);
	padding-block: 0.06em;
	border-radius: var(--r-md);
	overflow: hidden;
	font-size: clamp(2.4rem, 10.4vw, 8.2rem);
	color: color-mix(in srgb, #f5f2ea 34%, transparent);
	text-decoration: none;
	isolation: isolate;
}

.md-footer__club-fill {
	position: absolute;
	inset: 0;
	z-index: 0;
	background: var(--flame);
	transform: scaleX(0);
	transform-origin: left center;
	transition: transform 0.7s var(--e-out);
	pointer-events: none;
}

.md-footer__club-tg {
	position: relative;
	z-index: 1;
	display: grid;
	place-items: center;
	width: 0.7em;
	height: 0.7em;
	flex: 0 0 auto;
	opacity: 0.72;
	color: currentColor;
	transform: translate3d(0, 0.04em, 0);
	overflow: visible;
	transition:
		opacity 0.4s var(--e-out),
		color 0.45s var(--e-out);
}

.md-footer__club-tg svg {
	width: 100%;
	height: 100%;
	max-width: none;
	fill: currentColor;
}

.md-footer__club-text {
	position: relative;
	z-index: 1;
	font-family: var(--font);
	font-size: 0.75em;
	font-weight: 800;
	letter-spacing: -0.055em;
	line-height: 0.92;
	white-space: nowrap;
	transition: color 0.45s var(--e-out);
}

/* Visible at rest so the wordmark reads as a link on touch devices too. */
.md-footer__club-icon {
	position: relative;
	z-index: 1;
	display: grid;
	place-items: center;
	width: 0.48em;
	height: 0.48em;
	flex: 0 0 auto;
	opacity: 0.62;
	color: currentColor;
	transform: translate3d(0, 0.02em, 0);
	transition:
		opacity 0.4s var(--e-out) 0.12s,
		color 0.45s var(--e-out),
		transform 0.5s var(--e-out) 0.12s;
}

.md-footer__club-icon svg {
	width: 100%;
	height: 100%;
	max-width: none;
	stroke: currentColor;
}

.md-footer__club:hover,
.md-footer__club:focus-visible {
	color: #fff;
}

.md-footer__club:hover .md-footer__club-fill,
.md-footer__club:focus-visible .md-footer__club-fill {
	transform: scaleX(1);
}

.md-footer__club:hover .md-footer__club-icon,
.md-footer__club:focus-visible .md-footer__club-icon,
.md-footer__club:hover .md-footer__club-tg,
.md-footer__club:focus-visible .md-footer__club-tg {
	opacity: 1;
	color: #fff;
}

.md-footer__club:hover .md-footer__club-icon,
.md-footer__club:focus-visible .md-footer__club-icon {
	transform: translate3d(0.06em, -0.04em, 0);
}

.md-footer__club:focus-visible {
	outline: 2px solid var(--flame);
	outline-offset: 4px;
}

.md-footer__copy {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	text-align: center;
	gap: 1rem;
	margin-top: clamp(1.5rem, 3vw, 2.5rem);
	padding-top: clamp(1.2rem, 2.4vw, 1.8rem);
	border-top: 1px solid color-mix(in srgb, #f5f2ea 12%, transparent);
	font-size: 0.84rem;
	color: color-mix(in srgb, #f5f2ea 50%, transparent);
}

/* -------------------------------------------------------------------------
   23b. Back to top
   ---------------------------------------------------------------------- */

.md-totop {
	position: fixed;
	right: clamp(1rem, 2.4vw, 2rem);
	bottom: clamp(1rem, 2.4vw, 2rem);
	z-index: 80;
	display: grid;
	place-items: center;
	width: clamp(48px, 4.2vw, 58px);
	aspect-ratio: 1;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: var(--flame);
	color: #fff;
	cursor: pointer;
	opacity: 0;
	visibility: hidden;
	transform: translate3d(0, 18px, 0) scale(0.85);
	box-shadow: 0 18px 34px -16px color-mix(in srgb, var(--flame) 85%, transparent);
	transition:
		opacity 0.45s var(--e-out),
		visibility 0.45s var(--e-out),
		transform 0.55s var(--e-spring),
		background 0.35s var(--e-out),
		box-shadow 0.45s var(--e-out);
}

.md-totop.is-visible {
	opacity: 1;
	visibility: visible;
	transform: none;
}

.md-totop:hover,
.md-totop:focus-visible {
	background: var(--ink);
	box-shadow: 0 22px 40px -16px rgba(11, 12, 15, 0.6);
}

.md-totop.is-visible:hover,
.md-totop.is-visible:focus-visible {
	transform: translate3d(0, -3px, 0);
}

.md-totop:focus-visible {
	outline: 2px solid var(--flame);
	outline-offset: 3px;
}

.md-totop svg {
	width: 42%;
	height: 42%;
	stroke: currentColor;
}

/* -------------------------------------------------------------------------
   24. Video modal (matches the plugin's markup contract)
   ---------------------------------------------------------------------- */

.md .pm-video-modal {
	position: fixed;
	inset: 0;
	z-index: 300;
	display: none;
	place-items: center;
	padding: var(--gut);
}

.md .pm-video-modal.is-open,
.md .pm-video-modal[aria-hidden="false"] {
	display: grid;
}

.md .pm-video-modal__backdrop {
	position: absolute;
	inset: 0;
	background: rgba(6, 7, 9, 0.82);
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
}

.md .pm-video-modal__dialog {
	position: relative;
	width: min(1100px, 100%);
	border-radius: var(--r-md);
	overflow: hidden;
	box-shadow: var(--sh-lg);
	animation: md-modal-in 0.5s var(--e-out) both;
}

@keyframes md-modal-in {
	from {
		opacity: 0;
		transform: translateY(24px) scale(0.97);
	}
}

.md .pm-video-modal__player {
	width: 100%;
	aspect-ratio: 16 / 9;
	background: #000;
	display: block;
}

.md .pm-video-modal__close {
	position: absolute;
	top: 0.75rem;
	right: 0.75rem;
	z-index: 2;
	display: grid;
	place-items: center;
	width: 42px;
	height: 42px;
	border-radius: 50%;
	background: rgba(11, 12, 15, 0.6);
	color: #fff;
	font-size: 1.4rem;
	line-height: 1;
	backdrop-filter: blur(8px);
	transition: background 0.35s var(--e-out);
}

.md .pm-video-modal__close:hover {
	background: var(--flame);
}

/* -------------------------------------------------------------------------
   25. Responsive

   Tiers:
     >= 1280px   full desktop
     tablet landscape (see query) — same desktop grids, condensed rhythm
     phone / tablet portrait — stacked

   Do not stack on max-width: 1180px or 1024px. iPad landscape CSS widths are
   1024 · 1080 · 1112 · 1133 · 1180 · 1194 — a 1180px stack is exactly the
   iPad Air / 10th-gen sideways, which is what the client rejected.

   Integer 1023/1024 (not 1023.98): WebKit rounds fractional media queries
   and would apply both the condensed and the stacked tier at 1024px.

   Landscape + min-height also keeps desktop grids when Safari chrome or
   page zoom reports a width slightly under 1024. Phone landscape is still
   stacked via max-height: 500px (iPhone landscape is ~390–440px tall).
   ---------------------------------------------------------------------- */

/* ---- Tablet landscape: keep the desktop layout, tighten the rhythm ------ */
@media (min-width: 1024px) and (max-width: 1279px),
	(orientation: landscape) and (min-width: 768px) and (max-width: 1279px) and (min-height: 501px) {
	.md,
	body.md-body {
		--gut: clamp(1.6rem, 3.6vw, 3rem);
		/* Landscape tablets are only 744–834px tall: desktop section padding
		   would push every block more than a screen apart. */
		--sec-y: clamp(3.5rem, 8.5vw, 8rem);
		--fs-h1: clamp(2.15rem, 3.8vw, 3.35rem);
		--fs-h2: clamp(1.8rem, 3.1vw, 2.7rem);
		--fs-lead: clamp(1rem, 1.35vw, 1.18rem);
		--r-lg: 28px;
		--r-xl: 38px;
	}

	/* The full nav only clears the logo and the CTA once its type condenses. */
	.md-header__inner {
		flex-wrap: nowrap;
		gap: 0.4rem;
		padding-left: 0.85rem;
		padding-right: 0.45rem;
	}

	.md-nav {
		gap: 0;
		flex-shrink: 1;
		min-width: 0;
	}

	.md-nav__link {
		padding: 0.55em 0.48em;
		font-size: 0.74rem;
	}

	.md-header__cta {
		padding: 0.85em 1.15em;
		font-size: 0.82rem;
	}

	.md-hero {
		min-height: 0;
		padding-block: clamp(6rem, 13vh, 8rem) clamp(2.4rem, 6vh, 4rem);
	}

	.md-hero__glow {
		inset: -34% -24% -14% -16%;
	}

	.md-hero__grid {
		grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.15fr);
		gap: clamp(1.2rem, 2.8vw, 2.4rem);
	}

	.md-hero__media {
		aspect-ratio: auto;
		padding: 0;
		box-sizing: border-box;
	}

	.md-portrait {
		width: min(100%, 70vh, 640px);
	}

	.md-checks {
		gap: 0.45rem;
	}

	.md-head {
		margin-bottom: clamp(1.8rem, 3.4vw, 2.6rem);
	}

	.md-pain__layout,
	.md-method__layout,
	.md-author__grid,
	.md-faq__layout,
	.md-empathy__grid {
		gap: clamp(1.8rem, 3.6vw, 3.2rem);
	}

	.md-method__media {
		max-width: 520px;
		margin-inline: auto;
	}

	.md-bento {
		gap: 0.65rem;
	}

	.md-stats {
		grid-template-columns: repeat(4, minmax(0, 1fr));
		gap: 0.8rem;
	}

	.md-tariff,
	.md-level {
		padding: clamp(1.15rem, 1.8vw, 1.55rem);
	}

	.md-tariff h3 {
		font-size: 1.32rem;
	}

	.md-tariff__price strong {
		font-size: 1.85rem;
	}

	.md-tariff__price--range strong {
		font-size: 1.45rem;
	}

	.md-tariff__audience,
	.md-tariff__list li {
		font-size: 0.84rem;
	}

	.md-cinema {
		aspect-ratio: 16 / 8.6;
	}

	.md-final h2 {
		font-size: clamp(2.4rem, 5.4vw, 4.4rem);
	}

	.md-footer__grid {
		grid-template-columns: minmax(0, 1.2fr) repeat(2, minmax(0, 1fr));
	}
}

/* ---- Below 820: two cards, the third spans the full row ---------------- */
@media (max-width: 819px) {
	.md-tariffs,
	.md-levels {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.md-levels__rail {
		display: none;
	}

	.md-tariffs > .md-tariff:last-child,
	.md-levels > .md-level:last-child {
		grid-column: 1 / -1;
		width: 100%;
		max-width: none;
		justify-self: stretch;
	}
}

/* ---- Below 620: one card per row --------------------------------------- */
@media (max-width: 619px) {
	.md-tariffs,
	.md-levels {
		grid-template-columns: minmax(0, 1fr);
	}

	.md-tariffs > .md-tariff:last-child,
	.md-levels > .md-level:last-child {
		grid-column: auto;
	}
}

/* ---- Phone and tablet portrait: single column -------------------------- */
@media (max-width: 1023px) and (orientation: portrait),
	(max-width: 767px),
	(max-height: 500px) {
	.md-nav {
		display: none;
	}

	.md-burger {
		display: block;
		margin-left: auto;
	}

	.md-header__cta {
		display: none;
	}

	.md-hero__grid {
		grid-template-columns: 1fr;
		gap: clamp(2rem, 6vw, 3rem);
	}

	.md-hero__media {
		order: -1;
		aspect-ratio: auto;
		max-width: 560px;
		margin-inline: auto;
		padding: 0;
	}

	.md-hero {
		min-height: 0;
		padding-block: clamp(6.5rem, 14vh, 9rem) clamp(3rem, 8vh, 5rem);
	}

	/* Percent-placed accents land on the copy once the hero stacks. */
	.md-hero .md-shapes {
		display: none;
	}

	.md-cue {
		display: none;
	}

	.md-author__grid,
	.md-faq__layout,
	.md-method__layout,
	.md-pain__layout,
	.md-empathy__grid {
		grid-template-columns: 1fr;
	}

	/* Must stay positioned: these are the containing block for their absolute
	   decorative layers. Going static lets those layers escape and cover the
	   whole section, painting over the copy. */
	.md-pain__aside,
	.md-method__media,
	.md-faq__aside {
		position: relative;
		top: auto;
	}

	.md-method__media {
		order: -1;
		max-width: 560px;
		margin-inline: auto;
	}

	.md-author__media {
		max-width: 400px;
		margin-inline: auto;
	}

	.md-bento__item:nth-child(n) {
		grid-column: span 3;
	}
}

@media (max-width: 860px) {
	.md-footer__grid {
		grid-template-columns: 1fr 1fr;
	}

	.md-footer__brand {
		grid-column: 1 / -1;
	}

	.md-stats {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 1.2rem;
	}

	.md-bento__item:nth-child(n) {
		grid-column: span 6;
		min-height: 0;
	}

	.md-pain__card {
		position: static;
		gap: 1rem;
	}

	.md-pain__stack {
		padding-bottom: 0;
	}

	.md-cinema {
		aspect-ratio: 16 / 11;
		border-radius: var(--r-lg);
	}

	.md-review {
		width: min(78vw, 340px);
	}
}

@media (max-width: 620px) {
	.md {
		--r-lg: 26px;
		--r-xl: 30px;
	}

	.md-head {
		flex-direction: column;
		align-items: flex-start;
	}

	#method .md-head__aside {
		margin-left: 0;
	}

	.md-hero__actions .md-btn {
		flex: 1 1 auto;
	}

	.md-phrase {
		max-width: min(92%, 22rem);
		width: auto;
	}

	.md-quote__live {
		flex-direction: column;
		align-items: center;
		text-align: center;
		gap: 0.35rem;
		padding: 0;
	}

	.md-quote__live .md-phrase__wave {
		margin-bottom: 0.15rem;
	}

	.md-portrait .md-phrase {
		bottom: 5%;
		width: max-content;
		max-width: min(88%, 20rem);
	}

	.md-footer__grid {
		grid-template-columns: 1fr;
	}

	.md-guarantees {
		flex-direction: column;
		align-items: center;
		gap: 0.7rem;
	}

	.md-tariff__audience {
		min-height: 0;
	}

	.md-slider__nav {
		display: none;
	}
}

/* -------------------------------------------------------------------------
   26. Motion preferences
   ---------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
	html.md-html {
		scroll-behavior: auto;
	}

	.md *,
	.md *::before,
	.md *::after {
		animation-duration: 0.001ms !important;
		animation-iteration-count: 1 !important;
		transition-duration: 0.001ms !important;
	}

	.md-reveal,
	.md-word__i,
	.md-checks li,
	.md-portrait__img {
		opacity: 1 !important;
		transform: none !important;
		filter: none !important;
	}

	.md-intro {
		display: none;
	}

	.md-cursor {
		display: none !important;
	}
}

/* -------------------------------------------------------------------------
   27. Payments plugin modals
   Purely cosmetic re-skin of pm-payments-integration's checkout and
   level-selector dialogs. Scoped to body.md-body so no other page is touched,
   and no plugin markup, class names or behaviour are changed.
   ---------------------------------------------------------------------- */

body.md-body .pm-modal-backdrop {
	background: color-mix(in srgb, var(--ink) 62%, transparent);
	-webkit-backdrop-filter: blur(14px) saturate(120%);
	backdrop-filter: blur(14px) saturate(120%);
}

body.md-body .pm-modal-content {
	padding: clamp(1.4rem, 3vw, 2.2rem);
	border: 0;
	border-radius: var(--r-lg);
	background: var(--paper);
	box-shadow:
		inset 0 0 0 1px var(--line),
		0 40px 90px -30px rgba(11, 12, 15, 0.55);
	font-family: var(--font);
	color: var(--ink);
	/* Reserve the gutter up front so content does not reflow when the bar appears. */
	scrollbar-gutter: stable;
	scrollbar-width: thin;
	scrollbar-color: color-mix(in srgb, var(--ink) 26%, transparent) transparent;
}

/* A pill that floats inside the dialog instead of the OS bar clinging to its edge.
   The transparent border plus content-box clip is what insets the thumb. */
body.md-body .pm-modal-content::-webkit-scrollbar {
	width: 12px;
}

body.md-body .pm-modal-content::-webkit-scrollbar-track {
	margin: clamp(1rem, 2.4vw, 1.6rem) 0;
	background: transparent;
}

body.md-body .pm-modal-content::-webkit-scrollbar-thumb {
	border: 4px solid transparent;
	border-radius: 999px;
	background: color-mix(in srgb, var(--ink) 24%, transparent);
	background-clip: content-box;
	transition: background 0.3s var(--e-out);
}

body.md-body .pm-modal-content::-webkit-scrollbar-thumb:hover {
	background: color-mix(in srgb, var(--ink) 46%, transparent);
	background-clip: content-box;
}

body.md-body .pm-modal-content::-webkit-scrollbar-corner {
	background: transparent;
}

body.md-body .pm-modal-content h3 {
	margin: 0 0 clamp(1rem, 2vw, 1.4rem);
	font-size: clamp(1.45rem, 2.6vw, 2rem);
	font-weight: 800;
	line-height: 1.06;
	letter-spacing: -0.035em;
	color: var(--ink);
}

body.md-body .pm-modal-close {
	top: clamp(1rem, 2vw, 1.5rem);
	right: clamp(1rem, 2vw, 1.5rem);
	width: 38px;
	height: 38px;
	background: transparent;
	box-shadow: inset 0 0 0 1px var(--line-strong);
	color: var(--ink);
	transition:
		background 0.35s var(--e-out),
		color 0.35s var(--e-out);
}

body.md-body .pm-modal-close:hover {
	background: var(--ink);
	color: var(--paper);
}

body.md-body .pm-checkout-summary {
	gap: 0.5rem;
	padding: clamp(0.9rem, 2vw, 1.2rem);
	margin-bottom: clamp(1rem, 2vw, 1.4rem);
	border: 0;
	border-radius: var(--r-sm);
	background: var(--ink);
}

body.md-body .pm-checkout-summary-row span {
	font-size: 0.82rem;
	color: color-mix(in srgb, var(--paper) 62%, transparent);
}

body.md-body .pm-checkout-summary-row strong {
	font-size: 1rem;
	font-weight: 700;
	color: var(--paper);
}

body.md-body .pm-payment-method-label {
	font-size: 0.76rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--faint);
}

body.md-body .pm-payment-method-card {
	gap: 0.35rem;
	padding: clamp(0.9rem, 2vw, 1.15rem) 0.75rem;
	border: 0;
	border-radius: var(--r-sm);
	background: color-mix(in srgb, var(--ink) 3%, transparent);
	box-shadow: inset 0 0 0 1px var(--line);
	color: var(--ink);
	transition:
		box-shadow 0.35s var(--e-out),
		background 0.35s var(--e-out);
}

body.md-body .pm-payment-method-card:hover:not(.is-disabled),
body.md-body .pm-payment-method-card:focus-visible:not(.is-disabled) {
	background: transparent;
	box-shadow: inset 0 0 0 1.5px var(--line-strong);
}

body.md-body .pm-payment-method-card.is-active {
	background: transparent;
	box-shadow: inset 0 0 0 2px var(--flame);
}

body.md-body .pm-payment-method-icon {
	font-size: 1.5rem;
	color: var(--teal);
}

body.md-body .pm-payment-method-title {
	font-size: 0.95rem;
	font-weight: 700;
}

body.md-body .pm-payment-method-desc,
body.md-body .pm-payment-method-hint {
	font-size: 0.8rem;
	color: var(--muted);
}

body.md-body #pm-checkout-form input[type="text"],
body.md-body #pm-checkout-form input[type="email"],
body.md-body #pm-checkout-form select {
	padding: 0.85rem 1rem;
	border: 0;
	border-radius: var(--r-sm);
	background: color-mix(in srgb, var(--ink) 3%, transparent);
	box-shadow: inset 0 0 0 1px var(--line);
	font-family: var(--font);
	font-size: 0.95rem;
	color: var(--ink);
	transition: box-shadow 0.3s var(--e-out);
}

body.md-body #pm-checkout-form input[type="text"]:focus,
body.md-body #pm-checkout-form input[type="text"]:focus-visible,
body.md-body #pm-checkout-form input[type="email"]:focus,
body.md-body #pm-checkout-form input[type="email"]:focus-visible,
body.md-body #pm-checkout-form select:focus,
body.md-body #pm-checkout-form select:focus-visible {
	box-shadow: inset 0 0 0 2px var(--flame);
	outline: none;
}

body.md-body .pm-checkbox {
	font-size: 0.85rem !important;
	color: var(--muted);
}

body.md-body .pm-checkbox input[type="checkbox"] {
	accent-color: var(--teal);
}

body.md-body .pm-policy-links-text a {
	color: var(--teal);
	text-decoration-thickness: 1px;
	text-underline-offset: 2px;
	transition: color 0.3s var(--e-out);
}

body.md-body .pm-policy-links-text a:hover,
body.md-body .pm-policy-links-text a:focus-visible {
	color: var(--flame);
}

/* The orange lives on a swept pseudo-layer, so unlocking the consent checkbox
   can paint the button in rather than snapping the colour. */
body.md-body .pm-submit-btn {
	position: relative;
	isolation: isolate;
	overflow: hidden;
	min-height: 56px;
	border-radius: 999px;
	background: transparent;
	color: #fff;
	font-family: var(--font);
	font-size: 0.98rem;
	font-weight: 700;
	letter-spacing: 0;
	text-transform: none;
	box-shadow: 0 14px 30px -14px color-mix(in srgb, var(--flame) 80%, transparent);
	transition:
		transform 0.35s var(--e-out),
		color 0.4s var(--e-out) 0.1s,
		box-shadow 0.45s var(--e-out);
}

body.md-body .pm-submit-btn::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: var(--flame);
	transform-origin: left center;
	transition: transform 0.6s var(--e-out);
}

body.md-body .pm-submit-btn:hover:not(:disabled):not(.is-locked) {
	transform: translateY(-2px);
	filter: none;
	box-shadow: 0 20px 38px -16px color-mix(in srgb, var(--flame) 85%, transparent);
}

body.md-body .pm-submit-btn.is-locked {
	color: color-mix(in srgb, var(--ink) 60%, transparent);
	box-shadow: inset 0 0 0 1.5px var(--line-strong);
	cursor: not-allowed;
	opacity: 1;
	transform: none;
	transition:
		color 0.35s var(--e-out),
		box-shadow 0.45s var(--e-out);
}

body.md-body .pm-submit-btn.is-locked::before {
	transform: scaleX(0);
}

body.md-body .pm-submit-btn.is-unlocking {
	animation: pm-unlock-pop 0.55s var(--e-out) 0.1s;
}

@keyframes pm-unlock-pop {
	0% {
		transform: scale(1);
	}

	45% {
		transform: scale(1.025);
	}

	100% {
		transform: scale(1);
	}
}

body.md-body .pm-level-option-btn {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: clamp(0.95rem, 2vw, 1.2rem) 1.15rem;
	border: 0;
	border-radius: var(--r-sm);
	background: color-mix(in srgb, var(--ink) 3%, transparent);
	box-shadow: inset 0 0 0 1px var(--line);
	font-family: var(--font);
	font-size: 1rem;
	font-weight: 700;
	color: var(--ink);
	text-align: left;
	transition:
		box-shadow 0.35s var(--e-out),
		transform 0.35s var(--e-out);
}

body.md-body .pm-level-option-btn:hover,
body.md-body .pm-level-option-btn:focus-visible {
	transform: translateX(3px);
	box-shadow: inset 0 0 0 2px var(--flame);
}

body.md-body .pm-level-option-btn__name {
	min-width: 0;
}

body.md-body .pm-level-option-btn__meta {
	display: grid;
	justify-items: end;
	gap: 0.12rem;
	flex: 0 0 auto;
	text-align: right;
}

body.md-body .pm-level-option-btn__price {
	font-size: 0.95rem;
	font-weight: 700;
	letter-spacing: -0.02em;
	white-space: nowrap;
}

body.md-body .pm-level-option-btn__term {
	font-size: 0.78rem;
	font-weight: 500;
	color: var(--muted);
	white-space: nowrap;
}

body.md-body .pm-status-box {
	border-radius: var(--r-sm);
	font-size: 0.85rem;
}

body.md-body .pm-success-title {
	font-weight: 800;
	letter-spacing: -0.03em;
	color: var(--ink);
}

body.md-body .pm-success-close-btn {
	border-radius: 999px;
}

