/* BananaRama: публичный сайт. Светлая тема, токены из docs/seo/brand-notes.md */

@font-face {
	font-family: 'Unbounded';
	src: url('/fonts/unbounded-cyrillic-wght-normal.woff2') format('woff2-variations');
	font-weight: 200 900;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
	font-family: 'Unbounded';
	src: url('/fonts/unbounded-latin-wght-normal.woff2') format('woff2-variations');
	font-weight: 200 900;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
	font-family: 'Onest';
	src: url('/fonts/onest-cyrillic-wght-normal.woff2') format('woff2-variations');
	font-weight: 100 900;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
	font-family: 'Onest';
	src: url('/fonts/onest-latin-wght-normal.woff2') format('woff2-variations');
	font-weight: 100 900;
	font-style: normal;
	font-display: swap;
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
	--bg: #FFF8EC;
	--surface: #FFFFFF;
	--surface-alt: #FFEFD2;
	--primary: #FFC220;
	--primary-deep: #E39A00;
	--primary-tint: #FFE6A6;
	--ink: #1B2340;
	--muted: #5F6479;
	--accent: #4A4FD1;
	--accent-tint: #E4E5FA;
	--border: #EADFC8;

	--font-display: 'Unbounded', 'Segoe UI', system-ui, sans-serif;
	--font-text: 'Onest', 'Segoe UI', system-ui, sans-serif;

	--fs-display: clamp(2.3rem, 1.5rem + 3.4vw, 4.15rem);
	--fs-h2: clamp(1.7rem, 1.25rem + 1.9vw, 2.7rem);
	--fs-h3: clamp(1.1rem, 1.02rem + 0.4vw, 1.35rem);
	--fs-lead: clamp(1.05rem, 1rem + 0.5vw, 1.28rem);
	--fs-base: 1.0625rem;
	--fs-sm: 0.9375rem;
	--fs-xs: 0.8125rem;

	--s-1: 4px;
	--s-2: 8px;
	--s-3: 12px;
	--s-4: 16px;
	--s-5: 24px;
	--s-6: 32px;
	--s-7: 48px;
	--s-8: 64px;
	--s-9: 96px;

	--r-sm: 10px;
	--r: 18px;
	--r-lg: 28px;
	--r-xl: 40px;

	--shell: 1180px;
	--header-h: 72px;
	--section-y: clamp(40px, 4.5vw, 56px);
}

*,
*::before,
*::after {
	box-sizing: border-box;
}

html {
	overflow-x: clip;
	-webkit-text-size-adjust: 100%;
	scroll-behavior: smooth;
	scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
	margin: 0;
	background: var(--bg);
	color: var(--ink);
	font-family: var(--font-text);
	font-size: var(--fs-base);
	line-height: 1.6;
	font-synthesis-weight: none;
	-webkit-font-smoothing: antialiased;
}

img,
video,
svg {
	max-width: 100%;
}

h1, h2, h3 {
	font-family: var(--font-display);
	font-weight: 700;
	line-height: 1.08;
	letter-spacing: -0.02em;
	margin: 0;
	text-wrap: balance;
}

h1 {
	font-size: var(--fs-display);
	letter-spacing: -0.035em;
}

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

h3 {
	font-size: var(--fs-h3);
	letter-spacing: -0.01em;
}

p {
	margin: 0;
}

a {
	color: var(--accent);
	text-decoration-thickness: 1px;
	text-underline-offset: 3px;
}

a:hover {
	color: var(--ink);
}

ul, ol {
	margin: 0;
	padding: 0;
}

:focus-visible {
	outline: 2px solid var(--accent);
	outline-offset: 2px;
	border-radius: 4px;
}

.skip-link {
	position: absolute;
	left: -9999px;
	top: 0;
	z-index: 100;
	background: var(--ink);
	color: var(--bg);
	padding: 12px 20px;
	border-radius: 0 0 var(--r) 0;
}

.skip-link:focus {
	left: 0;
	color: var(--bg);
}

.shell {
	width: 100%;
	max-width: var(--shell);
	margin: 0 auto;
	padding-inline: clamp(16px, 4vw, 40px);
}

.section {
	padding-block: var(--section-y);
}

.section--tight {
	padding-block: clamp(20px, 2.5vw, 32px);
}

.section--alt {
	background: var(--surface-alt);
}

/*
	Стыки секций: поле не складывается дважды. Внутри заливки (.section--alt) полное поле (не меньше 40 px),
	кремовая сторона у границы заливки и вторая из двух кремовых секций берут только небольшой зазор.
*/
.section:not(.section--alt) + .section:not(.section--alt),
.section--alt + .section--alt {
	padding-top: calc(var(--section-y) * 0.3);
}

.section--tight + .section {
	padding-top: calc(var(--section-y) * 0.75);
}

/* Второй блок в той же секции (две белые секции подряд сливались бы) */
.section__next {
	margin-top: calc(var(--section-y) * 2);
}

/* Заливка, которая кончается карточками: у карточек свои внутренние поля, снизу хватает минимума в 40 px */
.section.section--alt.section--cards-end {
	padding-bottom: 40px;
}

/* Финальный призыв: чернильная плашка сама отделяет блок, внешние поля минимальные */
.section:has(+ .section--cta) {
	padding-bottom: calc(var(--section-y) * 0.6);
}

.section:not(.section--alt) + .section.section--cta {
	padding-top: 0;
}

.section__head {
	max-width: 62ch;
	margin-bottom: clamp(24px, 3vw, 40px);
}

.section__head p {
	margin-top: var(--s-4);
	color: var(--muted);
	font-size: var(--fs-lead);
}

/* --- Кнопки ------------------------------------------------------------- */

.btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 14px 26px;
	border: 2px solid var(--ink);
	border-radius: 999px;
	font-family: var(--font-text);
	font-size: var(--fs-base);
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.btn--primary {
	background: var(--primary);
	color: var(--ink);
	box-shadow: 0 4px 0 var(--primary-deep);
}

.btn--primary:hover {
	background: var(--primary-tint);
	color: var(--ink);
	transform: translateY(2px);
	box-shadow: 0 2px 0 var(--primary-deep);
}

/* Кнопка мессенджера MAX: фирменный градиент вместо жёлтого и прозрачного */
.btn--max {
	background: linear-gradient(90deg, #3D8BFF, #7A4DFF);
	color: #FFFFFF;
	box-shadow: 0 4px 0 #2B3392;
}

.btn--max:hover {
	color: #FFFFFF;
	filter: brightness(1.08);
	transform: translateY(2px);
	box-shadow: 0 2px 0 #2B3392;
}

.btn__icon {
	flex: none;
	width: 18px;
	height: 18px;
}

.btn--ghost {
	background: transparent;
	color: var(--ink);
}

.btn--ghost:hover {
	background: var(--surface);
	color: var(--ink);
}

.btn--ink {
	background: var(--ink);
	color: var(--bg);
	border-color: var(--ink);
}

.btn--ink:hover {
	background: #2A3357;
	color: var(--bg);
}

.btn--sm {
	padding: 9px 18px;
	font-size: var(--fs-sm);
	border-width: 2px;
}

.btn--primary:focus-visible {
	outline-color: var(--ink);
}

/* --- Шапка -------------------------------------------------------------- */

.site-header {
	position: sticky;
	top: 0;
	z-index: 60;
	background: rgba(255, 248, 236, 0.92);
	backdrop-filter: blur(10px);
	border-bottom: 1px solid transparent;
	transition: border-color 0.2s ease, padding 0.2s ease;
}

.site-header.is-scrolled {
	border-bottom-color: var(--border);
}

.site-header__inner {
	display: flex;
	align-items: center;
	gap: var(--s-5);
	min-height: var(--header-h);
	padding-block: 10px;
	transition: min-height 0.2s ease;
}

.site-header.is-scrolled .site-header__inner {
	min-height: 58px;
}

.brand {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	color: var(--ink);
	text-decoration: none;
	flex: none;
}

.brand__mark {
	display: block;
	transition: transform 0.25s ease;
}

.brand:hover .brand__mark {
	transform: rotate(-8deg);
}

.brand__name {
	font-family: var(--font-display);
	font-weight: 700;
	font-size: 1rem;
	letter-spacing: -0.03em;
}

.site-header.is-scrolled .brand__mark {
	width: 32px;
	height: 32px;
}

.site-menu {
	display: flex;
	align-items: center;
	gap: var(--s-5);
	margin-left: auto;
}

.site-menu__actions {
	display: flex;
	align-items: center;
	gap: var(--s-2);
}

.nav-toggle {
	display: none;
	margin-left: auto;
	align-items: center;
	gap: 10px;
	padding: 8px 16px 8px 12px;
	background: var(--surface);
	border: 2px solid var(--ink);
	border-radius: 999px;
	font-family: var(--font-text);
	font-size: var(--fs-sm);
	font-weight: 600;
	color: var(--ink);
	cursor: pointer;
}

.nav-toggle__bars,
.nav-toggle__bars::before,
.nav-toggle__bars::after {
	display: block;
	width: 18px;
	height: 2px;
	background: var(--ink);
	border-radius: 2px;
}

.nav-toggle__bars {
	position: relative;
}

.nav-toggle__bars::before,
.nav-toggle__bars::after {
	content: '';
	position: absolute;
	left: 0;
}

.nav-toggle__bars::before {
	top: -6px;
}

.nav-toggle__bars::after {
	top: 6px;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bars {
	background: transparent;
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before {
	top: 0;
	transform: rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after {
	top: 0;
	transform: rotate(-45deg);
}

.nav-list {
	display: flex;
	align-items: center;
	gap: var(--s-1);
	list-style: none;
}

.nav-group__summary {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 9px 16px;
	border-radius: 999px;
	font-weight: 600;
	font-size: var(--fs-sm);
	cursor: pointer;
	list-style: none;
	user-select: none;
}

.nav-group__summary::-webkit-details-marker {
	display: none;
}

.nav-group__summary::after {
	content: '';
	width: 6px;
	height: 6px;
	margin-top: -3px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	opacity: 0.55;
	transition: transform 0.2s ease;
}

.nav-group__summary:hover {
	background: var(--surface-alt);
}

.nav-group[open] > .nav-group__summary {
	background: var(--surface-alt);
}

.nav-group[open] > .nav-group__summary::after {
	transform: rotate(-135deg);
	margin-top: 3px;
}

.nav-group__panel {
	list-style: none;
}

.nav-group__link {
	display: block;
	padding: 10px 14px;
	border-radius: 14px;
	color: var(--ink);
	text-decoration: none;
}

.nav-group__link:hover {
	background: var(--surface-alt);
	color: var(--ink);
}

.nav-group__label {
	display: block;
	font-weight: 600;
}

.nav-group__hint {
	display: block;
	font-size: var(--fs-xs);
	color: var(--muted);
}

/* Пять групп меню и три кнопки помещаются в строку только от 1200 px, ниже бургер */
@media (min-width: 1200px) {
	.nav-group {
		position: relative;
	}

	.nav-group__panel {
		position: absolute;
		top: calc(100% + 12px);
		left: 0;
		z-index: 70;
		min-width: 288px;
		padding: 8px;
		background: var(--surface);
		border: 1px solid var(--border);
		border-radius: 22px;
		box-shadow: 0 24px 48px -28px rgba(27, 35, 64, 0.55);
	}

	.nav-group__summary,
	.site-menu__actions .btn {
		white-space: nowrap;
	}

	/* Три кнопки мессенджеров и пять групп меню: до 1400 px строка помещается только с компактным логотипом и кнопками */
	.site-menu__actions {
		gap: var(--s-2);
	}

	.site-menu__actions .btn {
		padding: 9px 14px;
	}

	.site-header__inner {
		gap: var(--s-4);
	}
}

@media (min-width: 1200px) and (max-width: 1399.98px) {
	.site-header .brand__name {
		font-size: 1rem;
	}

	.site-header .brand__mark {
		width: 32px;
		height: 32px;
	}
}

@media (max-width: 1199.98px) {
	.nav-toggle {
		display: inline-flex;
	}

	/* Класс js ставит inline-скрипт в <head> синхронно: без него (JS выключен) меню открыто обычным блоком */
	html:not(.js) .nav-toggle {
		display: none;
	}

	/* Логотип и переключатель остаются над открытой панелью, чтобы её можно было закрыть */
	.brand,
	.nav-toggle {
		position: relative;
		z-index: 2;
	}

	.site-header__inner {
		flex-wrap: wrap;
	}

	.site-menu {
		flex-direction: column;
		align-items: stretch;
		gap: var(--s-4);
		width: 100%;
		margin-left: 0;
		padding-block: var(--s-4);
	}

	html:not(.js) .site-header {
		position: static;
	}

	html.js .site-menu {
		position: fixed;
		top: 0;
		right: 0;
		z-index: 1;
		width: min(380px, 100%);
		height: 100dvh;
		padding: calc(var(--header-h) + 16px) clamp(16px, 4vw, 24px) var(--s-8);
		overflow-y: auto;
		background: var(--bg);
		border-left: 1px solid var(--border);
		clip-path: inset(0 0 0 100%);
		visibility: hidden;
		transition: clip-path 0.25s ease, visibility 0.25s;
	}

	html.js .site-menu.is-open {
		clip-path: inset(0);
		visibility: visible;
	}

	.nav-list {
		flex-direction: column;
		align-items: stretch;
		gap: 2px;
	}

	.nav-group__summary {
		justify-content: space-between;
		font-size: var(--fs-base);
		padding: 12px 14px;
	}

	.nav-group__panel {
		padding: 4px 0 10px 10px;
		border-left: 2px solid var(--border);
		margin-left: 14px;
	}

	.site-menu__actions {
		flex-direction: column;
		align-items: stretch;
		gap: var(--s-3);
		padding-top: var(--s-4);
		border-top: 1px solid var(--border);
	}

	.site-menu__actions .btn {
		padding: 13px 20px;
		font-size: var(--fs-base);
	}
}

/* Узкие телефоны: логотип и переключатель в одну строку, подпись «Меню» остаётся для скринридеров */
@media (max-width: 400px) {
	.site-header__inner {
		gap: var(--s-3);
	}

	.brand__name {
		font-size: 1.05rem;
	}

	.nav-toggle {
		justify-content: center;
		width: 44px;
		height: 44px;
		padding: 0;
	}

	.nav-toggle__label {
		position: absolute;
		width: 1px;
		height: 1px;
		overflow: hidden;
		clip: rect(0 0 0 0);
		white-space: nowrap;
	}
}

body.nav-open {
	overflow: hidden;
}

/* --- Первый экран ------------------------------------------------------- */

.hero {
	padding-block: clamp(32px, 4.5vw, 64px) clamp(32px, 4vw, 56px);
}

.hero__grid {
	display: grid;
	gap: clamp(32px, 5vw, 64px);
	align-items: center;
}

@media (min-width: 940px) {
	.hero__grid {
		grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
	}
}

.hero__accent {
	margin-top: var(--s-5);
	max-width: 22ch;
	padding-left: var(--s-4);
	border-left: 4px solid var(--primary);
	font-family: var(--font-display);
	font-size: var(--fs-h3);
	line-height: 1.3;
	color: var(--ink);
}

.hero__accent + .hero__lead {
	margin-top: var(--s-4);
}

.hero__lead {
	margin-top: var(--s-5);
	font-size: var(--fs-lead);
	color: var(--muted);
	max-width: 46ch;
}

.hero__actions {
	display: flex;
	flex-wrap: wrap;
	gap: var(--s-3);
	margin-top: var(--s-6);
}

.hero__trust {
	display: flex;
	flex-wrap: wrap;
	gap: var(--s-2) var(--s-5);
	margin-top: var(--s-6);
	list-style: none;
	font-size: var(--fs-sm);
	color: var(--muted);
}

.hero__trust li {
	display: flex;
	align-items: center;
	gap: 8px;
}

.hero__trust li::before {
	content: '';
	width: 9px;
	height: 9px;
	border-radius: 3px;
	background: var(--primary);
	border: 1.5px solid var(--ink);
	flex: none;
}

.hero__trust--lg {
	gap: var(--s-3) var(--s-5);
	font-size: var(--fs-base);
	font-weight: 500;
	color: var(--ink);
}

.hero__trust--lg li {
	align-items: flex-start;
	gap: 10px;
}

.hero__trust--lg li::before {
	width: 12px;
	height: 12px;
	margin-top: calc((1.6em - 12px) / 2);
	border-radius: 4px;
}

@media (min-width: 560px) {
	.hero__trust--lg {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

/* Коллаж первого экрана: три карточки «промпт → результат» и маскот */

.collage {
	position: relative;
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: clamp(12px, 2vw, 20px);
}

.collage__card {
	background: var(--surface);
	border: 2px solid var(--ink);
	border-radius: var(--r-lg);
	padding: 10px;
	box-shadow: 8px 8px 0 var(--primary);
}

.collage__card:nth-child(2) {
	box-shadow: 8px 8px 0 var(--accent-tint);
	transform: rotate(1.4deg);
}

.collage__card:nth-child(3) {
	grid-column: span 2;
	box-shadow: 8px 8px 0 var(--surface-alt);
	transform: rotate(-0.8deg);
}

.collage__prompt {
	display: block;
	padding: 10px 12px 8px;
	font-size: var(--fs-sm);
	color: var(--ink);
}

.collage__prompt b {
	display: block;
	margin-bottom: 2px;
	color: var(--muted);
	font-size: var(--fs-xs);
	font-weight: 600;
}

/* Маскот на левом верхнем углу первой карточки: промпты внизу карточек он не закрывает */
.collage {
	--mascot: clamp(64px, 8vw, 104px);
}

.collage__mascot {
	position: absolute;
	top: -28px;
	left: -28px;
	z-index: 1;
	width: var(--mascot);
	height: auto;
	pointer-events: none;
}

@media (max-width: 560px) {
	.collage__mascot {
		top: -18px;
		left: -8px;
		width: 60px;
	}
}

/* --- Лента моделей ------------------------------------------------------ */

.engines {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--s-3) var(--s-4);
	padding: var(--s-5) 0;
	border-block: 1px solid var(--border);
}

.engines__label {
	font-size: var(--fs-sm);
	color: var(--muted);
	margin-right: var(--s-2);
}

.chip {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 7px 16px;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: 999px;
	font-size: var(--fs-sm);
	font-weight: 600;
}

.chip--accent {
	background: var(--accent-tint);
	border-color: transparent;
	color: var(--ink);
}

/* --- Сетка возможностей ------------------------------------------------- */

/*
	Ряд 1: создание по описанию (картинка и видео, 16:9). Ряд 2: работа с готовым фото
	(редактирование «было → стало» и оживление того же кадра, три кадра 9:16 одной высоты). Ряд 3: ассистент.
*/
.bento {
	--bento-gap: clamp(14px, 1.8vw, 22px);
	--bento-pad: clamp(18px, 2vw, 26px);
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: var(--bento-gap);
}

.bento__card {
	display: flex;
	flex-direction: column;
	gap: var(--s-3);
	min-width: 0;
	padding: var(--bento-pad);
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
}

.bento__card--lead {
	border: 2px solid var(--ink);
	box-shadow: 10px 10px 0 var(--primary);
}

.bento__icon {
	width: 64px;
	height: 64px;
	border-radius: var(--r);
	flex: none;
}

.bento__icon--sm {
	width: 44px;
	height: 44px;
	border-radius: 12px;
}

.bento__title-row {
	display: flex;
	align-items: center;
	gap: var(--s-3);
}

/* Медиа сразу под текстом: если карточка в ряду выше соседней, свободное место уходит вниз, а не в середину */
.bento__text {
	color: var(--muted);
	font-size: var(--fs-sm);
}

.bento__more {
	align-self: flex-start;
	font-weight: 600;
	font-size: var(--fs-sm);
	text-decoration: none;
	border-bottom: 2px solid var(--accent-tint);
	padding-bottom: 2px;
}

.bento__more:hover {
	border-bottom-color: var(--primary);
}

.bento__media {
	margin-top: var(--s-1);
}

/* Пара «было → стало»: два кадра 9:16 и стрелка между ними */
.bento__pair {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 24px minmax(0, 1fr);
	gap: 10px;
	align-items: center;
}

.bento__pair-arrow {
	position: relative;
	display: block;
	width: 100%;
	height: 2px;
	margin-top: -28px;
	background: var(--ink);
}

.bento__pair-arrow::after {
	content: '';
	position: absolute;
	right: 0;
	top: 50%;
	width: 8px;
	height: 8px;
	border-top: 2px solid var(--ink);
	border-right: 2px solid var(--ink);
	transform: translateY(-50%) rotate(45deg);
}

/* Широкая карточка ассистента: текст и скриншот в «окне» с затуханием снизу */
.bento__card--assistant {
	display: grid;
	gap: var(--s-5) clamp(24px, 4vw, 56px);
	align-items: center;
}

.bento__body {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: var(--s-3);
}

.bento__list {
	display: grid;
	gap: var(--s-2);
	list-style: none;
	font-size: var(--fs-sm);
}

.bento__list li {
	display: flex;
	gap: 10px;
}

.bento__list li::before {
	content: '';
	flex: none;
	width: 8px;
	height: 8px;
	margin-top: 8px;
	border-radius: 2px;
	background: var(--primary);
	border: 1.5px solid var(--ink);
}

.bento__card--assistant .bento__more {
	margin-top: var(--s-2);
}

.bento__shot {
	position: relative;
	max-height: 420px;
	overflow: hidden;
	padding-top: 26px;
	background: var(--surface);
	border: 2px solid var(--ink);
	border-radius: var(--r);
}

.bento__shot::before {
	content: '';
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	z-index: 1;
	height: 26px;
	border-bottom: 1.5px solid var(--border);
	background:
		radial-gradient(circle at 16px 50%, var(--primary-deep) 4px, transparent 4.5px),
		radial-gradient(circle at 30px 50%, var(--border) 4px, transparent 4.5px),
		radial-gradient(circle at 44px 50%, var(--border) 4px, transparent 4.5px),
		var(--surface-alt);
}

.bento__shot::after {
	content: '';
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	height: 110px;
	background: linear-gradient(rgba(255, 255, 255, 0), var(--surface));
	pointer-events: none;
}

.bento__shot .example__media {
	border-radius: 0;
}

.example--top .example__media {
	object-position: top;
}

/* Широкий скриншот в высокой карточке: вписать целиком по ширине, а не срезать начала строк */
.example--contain .example__media {
	object-fit: contain;
	object-position: top;
	background: #f1f2f7;
}

/* Мобильный: одна колонка, пара «было → стало» остаётся рядом, видео оживления не шире 320 px по центру */
@media (max-width: 759px) {
	.bento__card--lead {
		box-shadow: 6px 6px 0 var(--primary);
	}

	.bento__card--animate .example {
		max-width: 320px;
		margin-inline: auto;
	}

	.bento__shot {
		max-height: 360px;
	}
}

@media (min-width: 760px) {
	.bento__card--assistant {
		grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	}
}

/*
	Планшет: ряд 1 генерация и видео рядом; редактирование на всю ширину (пара по центру);
	оживление на всю ширину, видео справа от текста. Все три кадра 9:16 одной ширины --frame-w.
*/
@media (min-width: 760px) and (max-width: 999px) {
	.bento {
		--frame-w: 260px;
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.bento__card--edit,
	.bento__card--animate,
	.bento__card--assistant {
		grid-column: 1 / -1;
	}

	.bento__pair {
		grid-template-columns: var(--frame-w) 40px var(--frame-w);
		justify-content: center;
	}

	.bento__card--animate {
		display: grid;
		grid-template-columns: minmax(0, 1fr) var(--frame-w);
		grid-template-rows: auto auto 1fr;
		column-gap: var(--s-6);
		align-content: start;
	}

	.bento__card--animate .bento__media {
		grid-column: 2;
		grid-row: 1 / 4;
		margin-top: 0;
	}

	.bento__card--animate .bento__more {
		align-self: start;
	}
}

/*
	Десктоп: 12 колонок. Ряд 1: генерация 1-6 + видео 7-12; ряд 2: редактирование 1-8 + оживление 9-12; ряд 3: ассистент.
	--frame-w равна ширине содержимого карточки в 4 колонки (оживление), такой же ширины оба кадра пары,
	поэтому три кадра 9:16 одной высоты. 100cqw это ширина сетки (.bento — контейнер), 2px это рамки карточки.
*/
@media (min-width: 1000px) {
	.bento {
		container-type: inline-size;
		grid-template-columns: repeat(12, minmax(0, 1fr));
	}

	.bento__card {
		--frame-w: calc((100cqw - 11 * var(--bento-gap)) / 3 + 3 * var(--bento-gap) - 2 * var(--bento-pad) - 2px);
	}

	.bento__card--lead {
		grid-column: 1 / 7;
		grid-row: 1;
	}

	.bento__card--video {
		grid-column: 7 / 13;
		grid-row: 1;
	}

	.bento__card--edit {
		grid-column: 1 / 9;
		grid-row: 2;
	}

	.bento__card--animate {
		grid-column: 9 / 13;
		grid-row: 2;
	}

	.bento__card--assistant {
		grid-column: 1 / -1;
		grid-row: 3;
	}

	.bento__pair {
		grid-template-columns: var(--frame-w) minmax(24px, 48px) var(--frame-w);
		justify-content: center;
	}

	.bento__card--animate .example {
		width: var(--frame-w);
		max-width: 100%;
	}

	/* Кадры первого и второго ряда на общей нижней линии: разница в длине заголовков и текстов уходит в небольшой зазор над кадрами */
	.bento__card--lead .bento__media,
	.bento__card--video .bento__media,
	.bento__card--edit .bento__media,
	.bento__card--animate .bento__media {
		margin-top: auto;
	}
}

/* --- Компонент примера -------------------------------------------------- */

.example {
	margin: 0;
}

.example__media {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: var(--example-ratio, 4 / 3);
	object-fit: cover;
	border-radius: var(--r);
	background: var(--surface-alt);
}

.example__media--empty {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 6px;
	padding: 16px;
	text-align: center;
	background: var(--surface-alt);
	border: 2px dashed var(--primary-deep);
	color: var(--muted);
}

.example__slot {
	font-weight: 600;
	color: var(--ink);
	font-size: var(--fs-sm);
}

.example__slot-file {
	font-size: var(--fs-xs);
	word-break: break-all;
	opacity: 0.75;
}

.example__caption {
	margin-top: var(--s-2);
	font-size: var(--fs-xs);
	color: var(--muted);
}

.example__frame {
	position: relative;
}

.is-zoomable {
	cursor: zoom-in;
}

.is-zoomable[controls] {
	cursor: auto;
}

/* Общее :focus-visible скругляет рамку на 4px, у кадров скругление своё */
.example__media.is-zoomable:focus-visible {
	border-radius: var(--r);
}

.inset__source .example__media.is-zoomable:focus-visible,
.sources__item.is-zoomable:focus-visible {
	border-radius: 11px;
}

.bento__shot .example__media.is-zoomable:focus-visible {
	border-radius: 0;
}

/* Кнопка звука у видео примера (создаёт public.js) */
.example__sound {
	position: absolute;
	right: 10px;
	bottom: 10px;
	z-index: 2;
	display: grid;
	place-items: center;
	width: 40px;
	height: 40px;
	padding: 0;
	border: 1.5px solid var(--ink);
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.82);
	color: var(--ink);
	cursor: pointer;
	transition: opacity 0.2s ease, background-color 0.2s ease;
}

.example__sound svg {
	width: 20px;
	height: 20px;
}

.example__sound[aria-pressed="true"] {
	background: var(--primary);
}

.example__sound[aria-pressed="true"] .example__sound-off,
.example__sound[aria-pressed="false"] .example__sound-on {
	display: none;
}

/* Нативные контролы (отказ автозапуска, reduced motion) уже дают звук, а кнопка легла бы на них */
.example__frame:has(video[controls]) .example__sound {
	display: none;
}

@media (min-width: 760px) {
	.example__sound {
		width: 36px;
		height: 36px;
	}

	.example__sound svg {
		width: 18px;
		height: 18px;
	}
}

@media (hover: hover) {
	.example__sound {
		opacity: 0;
	}

	.example__frame:hover .example__sound,
	.example__sound:focus-visible,
	.example__sound[aria-pressed="true"] {
		opacity: 1;
	}
}

@media (hover: none) {
	.example__sound {
		opacity: 0.85;
	}
}

/* --- Лайтбокс ----------------------------------------------------------- */

.lightbox {
	width: 100%;
	max-width: none;
	height: 100%;
	max-height: none;
	margin: 0;
	--lightbox-h: calc(90vh - 48px);
	--lightbox-h: calc(90dvh - 48px);
	padding: 16px 72px;
	border: 0;
	background: transparent;
	color: var(--surface);
	overflow: hidden;
}

.lightbox[open] {
	display: flex;
	align-items: center;
	justify-content: center;
}

.lightbox::backdrop {
	background: rgba(27, 35, 64, 0.88);
}

html.lightbox-open {
	overflow: hidden;
}

.lightbox__figure {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: var(--s-3);
	width: 100%;
	max-height: 100%;
	margin: 0;
}

.lightbox__media {
	display: block;
	max-width: 100%;
	max-height: var(--lightbox-h);
	width: auto;
	height: auto;
	object-fit: contain;
	border-radius: var(--r);
	background: var(--ink);
}

/* Размер видео известен до загрузки метаданных: пропорция из атрибутов кадра на странице */
.lightbox__media--video {
	width: min(100%, calc(var(--lightbox-h) * var(--lightbox-ratio, 16 / 9)));
	aspect-ratio: var(--lightbox-ratio, 16 / 9);
}

.lightbox__caption {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 6px 10px;
	max-width: 60ch;
	font-size: var(--fs-sm);
	line-height: 1.4;
	text-align: center;
}

.lightbox__caption:empty {
	display: none;
}

.lightbox__label {
	padding: 1px 10px;
	border: 1px solid var(--ink);
	border-radius: 999px;
	background: var(--primary);
	color: var(--ink);
	font-size: var(--fs-xs);
	font-weight: 600;
}

.lightbox__btn {
	position: absolute;
	display: grid;
	place-items: center;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 2px solid var(--ink);
	border-radius: 50%;
	background: var(--surface);
	color: var(--ink);
	cursor: pointer;
}

.lightbox__btn:hover {
	background: var(--primary);
}

.lightbox__btn:focus-visible {
	outline: 3px solid var(--primary);
	outline-offset: 3px;
	border-radius: 50%;
}

.lightbox__btn svg {
	width: 20px;
	height: 20px;
}

.lightbox__close {
	top: 16px;
	right: 16px;
}

.lightbox__nav {
	top: 50%;
	transform: translateY(-50%);
}

.lightbox__nav--prev {
	left: 16px;
}

.lightbox__nav--next {
	right: 16px;
}

.lightbox--single .lightbox__nav {
	display: none;
}

@media (max-width: 759px) {
	.lightbox {
		--lightbox-h: calc(100vh - 196px);
		--lightbox-h: calc(100dvh - 196px);
		padding: 68px 12px 80px;
	}

	.lightbox__nav {
		top: auto;
		bottom: 16px;
		transform: none;
	}

	.lightbox__nav--prev {
		left: calc(50% - 56px);
	}

	.lightbox__nav--next {
		right: calc(50% - 56px);
	}

	.lightbox--single {
		--lightbox-h: calc(100vh - 132px);
		padding-bottom: 16px;
	}
}

@media (prefers-reduced-motion: no-preference) {
	.lightbox[open] .lightbox__figure {
		animation: lightbox-in 0.2s ease-out;
	}
}

@keyframes lightbox-in {
	from {
		opacity: 0;
		transform: scale(0.96);
	}
}

/* --- Шторка «до/после» -------------------------------------------------- */

.compare {
	margin: 0;
}

.compare__frame {
	position: relative;
	aspect-ratio: var(--compare-ratio, 1 / 1);
	border: 2px solid var(--ink);
	border-radius: var(--r-lg);
	overflow: hidden;
	background: var(--surface-alt);
	touch-action: pan-y;
}

.compare__img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.compare__img--empty {
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 16px;
	text-align: center;
	font-size: var(--fs-xs);
	color: var(--muted);
	background: var(--surface-alt);
	border: 2px dashed var(--primary-deep);
	word-break: break-all;
}

/* «До» слева от ручки, «после» справа: позиция считается от левого края */
.compare__reveal {
	position: absolute;
	inset: 0;
	clip-path: inset(0 0 0 var(--compare-pos, 50%));
}

.compare__labels {
	display: flex;
	justify-content: space-between;
	gap: var(--s-3);
	margin-top: var(--s-2);
}

.compare__handle {
	position: absolute;
	top: 0;
	bottom: 0;
	left: var(--compare-pos, 50%);
	width: 3px;
	margin-left: -1.5px;
	background: var(--surface);
	pointer-events: none;
}

.compare__handle::after {
	content: '';
	position: absolute;
	top: 50%;
	left: 50%;
	width: 46px;
	height: 46px;
	transform: translate(-50%, -50%);
	border-radius: 50%;
	background: var(--primary);
	border: 2px solid var(--ink);
}

.compare__range {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	margin: 0;
	opacity: 0;
	cursor: ew-resize;
	appearance: none;
	background: transparent;
}

.compare__frame:has(.compare__range:focus-visible) {
	outline: 3px solid var(--accent);
	outline-offset: 3px;
}

.compare__caption {
	margin-top: var(--s-3);
	font-size: var(--fs-sm);
	color: var(--muted);
}

html:not(.js) .compare__frame {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 2px;
	aspect-ratio: auto;
}

html:not(.js) .compare__reveal {
	position: static;
	clip-path: none;
}

html:not(.js) .compare__handle,
html:not(.js) .compare__range {
	display: none;
}

html:not(.js) .compare__img {
	height: auto;
	aspect-ratio: var(--compare-ratio, 1 / 1);
}

/* --- Как это работает --------------------------------------------------- */

.steps__title {
	margin-bottom: clamp(24px, 3vw, 40px);
}

.steps__list {
	display: grid;
	gap: clamp(16px, 2vw, 24px);
	grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
	list-style: none;
	counter-reset: steps;
}

.steps__item {
	position: relative;
	padding: clamp(22px, 2.4vw, 30px);
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
}

.steps__num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 44px;
	height: 44px;
	margin-bottom: var(--s-4);
	border-radius: 14px;
	background: var(--primary);
	border: 2px solid var(--ink);
	font-family: var(--font-display);
	font-weight: 700;
	font-size: 1.1rem;
}

.steps__item-text {
	margin-top: var(--s-2);
	color: var(--muted);
	font-size: var(--fs-sm);
}

/* --- Таблица моделей ---------------------------------------------------- */

.models-wrap {
	overflow-x: auto;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
}

.models {
	width: 100%;
	min-width: 640px;
	border-collapse: separate;
	border-spacing: 0;
}

.models th,
.models td {
	padding: 16px 18px;
	text-align: left;
	vertical-align: top;
	border-bottom: 1px solid var(--border);
	font-size: var(--fs-sm);
}

.models thead th {
	background: var(--surface-alt);
	font-family: var(--font-text);
	font-weight: 600;
	font-size: var(--fs-xs);
	color: var(--muted);
}

.models tbody tr:last-child th,
.models tbody tr:last-child td {
	border-bottom: 0;
}

.models__name {
	font-weight: 600;
	font-size: var(--fs-base);
	white-space: normal;
}

.models__tag {
	display: table;
	max-width: 100%;
	margin-top: 6px;
	padding: 3px 10px;
	border-radius: 12px;
	background: var(--primary-tint);
	font-size: var(--fs-xs);
	font-weight: 600;
	line-height: 1.35;
	white-space: normal;
}

.models__price {
	font-variant-numeric: tabular-nums;
}

.models__row--current th,
.models__row--current td {
	background: var(--primary-tint);
	border-bottom-color: var(--primary);
}

.models__tag--current {
	background: var(--primary);
	color: var(--ink);
}

@media (max-width: 760px) {
	.models-wrap {
		overflow: visible;
		background: none;
		border: 0;
		border-radius: 0;
	}

	.models,
	.models tbody,
	.models tr,
	.models th,
	.models td {
		display: block;
		border: 0;
	}

	.models {
		min-width: 0;
	}

	.models thead {
		display: none;
	}

	.models tr {
		margin-bottom: var(--s-4);
		background: var(--surface);
		border: 1px solid var(--border);
		border-radius: var(--r);
		padding: 8px 4px;
	}

	.models tr.models__row--current {
		background: var(--primary-tint);
		border-color: var(--primary);
	}

	.models td {
		display: flex;
		flex-wrap: wrap;
		justify-content: space-between;
		gap: 4px var(--s-4);
		padding: 8px 16px;
	}

	.models td > * {
		min-width: 0;
		max-width: 100%;
	}

	.models td::before {
		content: attr(data-label);
		color: var(--muted);
		font-size: var(--fs-xs);
		flex: none;
	}

	.models th {
		padding: 10px 16px 4px;
	}
}

/* --- Тарифы ------------------------------------------------------------- */

.pricing {
	display: grid;
	gap: clamp(16px, 2vw, 24px);
	grid-template-columns: minmax(0, 1fr);
}

.pricing__packs {
	display: grid;
	gap: clamp(16px, 2vw, 24px);
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.pack {
	padding: clamp(22px, 2.4vw, 30px);
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
}

.pack__note {
	margin-top: var(--s-2);
	color: var(--muted);
	font-size: var(--fs-sm);
}

.pack__list {
	margin-top: var(--s-4);
	list-style: none;
}

.pack__row {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: 2px var(--s-4);
	padding: 10px 0;
	border-top: 1px solid var(--border);
	align-items: baseline;
}

.pack__qty {
	font-weight: 600;
}

.pack__price {
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

.pack__unit {
	grid-column: 1 / -1;
	font-size: var(--fs-xs);
	color: var(--muted);
}

.pricing__subs {
	display: grid;
	gap: clamp(16px, 2vw, 24px);
	grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.plan {
	display: flex;
	flex-direction: column;
	gap: var(--s-3);
	padding: clamp(22px, 2.4vw, 30px);
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
}

.plan--accent {
	border: 2px solid var(--ink);
	box-shadow: 10px 10px 0 var(--primary-tint);
}

.plan__price {
	font-size: var(--fs-sm);
	color: var(--muted);
}

.plan__amount {
	display: block;
	font-family: var(--font-display);
	font-size: clamp(1.7rem, 1.4rem + 1vw, 2.2rem);
	font-weight: 700;
	color: var(--ink);
	letter-spacing: -0.03em;
}

.plan__year {
	font-size: var(--fs-sm);
	color: var(--muted);
}

.plan__features {
	list-style: none;
	display: grid;
	gap: var(--s-2);
	margin-bottom: auto;
	font-size: var(--fs-sm);
}

.plan__features li {
	display: flex;
	gap: 10px;
}

.plan__features li::before {
	content: '';
	flex: none;
	width: 8px;
	height: 8px;
	margin-top: 9px;
	border-radius: 2px;
	background: var(--primary);
	border: 1.5px solid var(--ink);
}

.plan .btn {
	margin-top: var(--s-4);
}

/* --- Блок до/после и врезки --------------------------------------------- */

.split {
	display: grid;
	gap: clamp(28px, 4vw, 56px);
	align-items: center;
}

@media (min-width: 900px) {
	.split {
		grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
	}

	.split--reverse > :first-child {
		order: 2;
	}
}

.split__text p {
	margin-top: var(--s-4);
	color: var(--muted);
	font-size: var(--fs-lead);
}

/* Колонки текста разной высоты: выравнивание по верху, цена сразу под заголовком */
.split--top {
	align-items: start;
}

.split--top .split__text h3 + p {
	margin-top: var(--s-2);
}

/* Пример на проде ещё не загружен (feature-visual не выведен): текст занимает всю ширину */
.hero__grid > :only-child,
.split > :only-child {
	grid-column: 1 / -1;
}

/* --- Блок для продавцов: исходное фото → набор карточек ---------------- */

.market__head {
	display: grid;
	gap: var(--s-5) clamp(28px, 4vw, 56px);
	margin-bottom: clamp(24px, 3vw, 40px);
}

@media (min-width: 900px) {
	.market__head {
		grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
		align-items: end;
	}
}

.market__title-row {
	display: flex;
	align-items: center;
	gap: var(--s-4);
}

.market__icon {
	flex: none;
	width: 56px;
	height: 56px;
}

.market__intro p {
	margin-top: var(--s-4);
	color: var(--muted);
	font-size: var(--fs-lead);
	max-width: 52ch;
}

.market__details .split__list {
	margin-top: 0;
}

.market__details .split__actions {
	margin-top: var(--s-5);
}

/* Лента «шаг 1 → шаг 2 → шаг 3»: исходник и четыре результата одной ширины, выровнены по нижнему краю */
.market__strip {
	--market-gap: clamp(12px, 1.4vw, 18px);
	display: grid;
	grid-template-columns: minmax(0, 1fr) 128px minmax(0, 4fr);
	gap: var(--market-gap);
	align-items: end;
}

.market__strip:focus-visible {
	outline: 2px solid var(--accent);
	outline-offset: 6px;
	border-radius: var(--r);
}

.market__step {
	min-width: 0;
}

.market__step-title {
	margin-bottom: 10px;
	font-size: var(--fs-sm);
	font-weight: 600;
	line-height: 1.35;
	color: var(--ink);
}

/* Подписи шагов 1 и 3 в строке одной высоты (до двух строк), текст прижат к низу: общая базовая линия */
.market__step .market__step-title {
	display: flex;
	align-items: flex-end;
	min-height: 2.7em;
}

.market__results {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: var(--market-gap);
}

.market__item {
	min-width: 0;
}

.market__item--accent .example__caption {
	display: inline-block;
	padding: 2px 10px;
	border: 1.5px solid var(--ink);
	border-radius: 999px;
	background: var(--primary);
	color: var(--ink);
	font-weight: 600;
}

.market__connector {
	display: flex;
	flex-direction: column;
	gap: var(--s-3);
	align-self: center;
	min-width: 0;
}

.market__connector .market__step-title {
	margin-bottom: 0;
	font-size: var(--fs-xs);
}

.market__arrow {
	position: relative;
	display: block;
	width: 100%;
	height: 2px;
	background: var(--ink);
}

.market__arrow::after {
	content: '';
	position: absolute;
	right: 0;
	top: 50%;
	width: 10px;
	height: 10px;
	border-top: 2px solid var(--ink);
	border-right: 2px solid var(--ink);
	transform: translateY(-50%) rotate(45deg);
}

/* Планшет и мобильный: нативная горизонтальная лента со снапом, следующая карточка выглядывает из-за края */
@media (max-width: 1000px) {
	.market__strip {
		--market-card: min(40vw, 240px);
		--market-gap: 14px;
		display: flex;
		align-items: flex-end;
		overflow-x: auto;
		overscroll-behavior-x: contain;
		scroll-snap-type: x mandatory;
		padding: 4px 2px 12px;
		scrollbar-width: thin;
	}

	.market__step--source {
		flex: 0 0 var(--market-card);
		scroll-snap-align: start;
	}

	.market__connector {
		flex: 0 0 132px;
		scroll-snap-align: start;
	}

	.market__step--results {
		flex: none;
	}

	.market__results {
		display: flex;
	}

	.market__results .market__item {
		flex: 0 0 var(--market-card);
		scroll-snap-align: start;
	}
}

@media (max-width: 560px) {
	.market__strip {
		--market-card: 62vw;
	}
}

.split__list {
	margin-top: var(--s-5);
	display: grid;
	gap: var(--s-3);
	list-style: none;
	font-size: var(--fs-sm);
}

.split__list li {
	display: flex;
	gap: 10px;
	align-items: flex-start;
}

.split__list li::before {
	content: '';
	flex: none;
	width: 10px;
	height: 10px;
	margin-top: 8px;
	border-radius: 3px;
	background: var(--accent-tint);
	border: 1.5px solid var(--accent);
}

.split__actions {
	margin-top: var(--s-6);
	display: flex;
	flex-wrap: wrap;
	gap: var(--s-3);
}

/* --- FAQ ---------------------------------------------------------------- */

.faq {
	max-width: 860px;
}

.faq__title {
	margin-bottom: clamp(20px, 3vw, 36px);
}

.faq__list {
	border-top: 1px solid var(--border);
}

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

.faq__question {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: var(--s-4);
	padding: 18px 4px;
	font-weight: 600;
	font-size: var(--fs-h3);
	font-family: var(--font-text);
	cursor: pointer;
	list-style: none;
}

.faq__question::-webkit-details-marker {
	display: none;
}

.faq__question::after {
	content: '';
	flex: none;
	width: 22px;
	height: 22px;
	margin-top: 4px;
	border-radius: 50%;
	border: 2px solid var(--ink);
	background:
		linear-gradient(var(--ink), var(--ink)) center / 10px 2px no-repeat,
		linear-gradient(var(--ink), var(--ink)) center / 2px 10px no-repeat;
}

.faq__item[open] .faq__question::after {
	background: linear-gradient(var(--ink), var(--ink)) center / 10px 2px no-repeat, var(--primary);
}

.faq__question:hover {
	color: var(--accent);
}

.faq__answer {
	padding: 0 48px 22px 4px;
	color: var(--muted);
	max-width: 70ch;
}

.faq__answer p + p {
	margin-top: var(--s-3);
}

/* --- Хлебные крошки ----------------------------------------------------- */

.breadcrumbs__list {
	display: flex;
	flex-wrap: wrap;
	gap: 6px 10px;
	list-style: none;
	font-size: var(--fs-xs);
	color: var(--muted);
}

.breadcrumbs__item + .breadcrumbs__item::before {
	content: '/';
	margin-right: 10px;
	opacity: 0.5;
}

/* --- Финальный призыв --------------------------------------------------- */

.cta {
	position: relative;
	display: grid;
	gap: var(--s-5);
	padding: 40px clamp(28px, 4vw, 48px);
	background: var(--ink);
	color: var(--bg);
	border-radius: var(--r-xl);
	overflow: hidden;
}

@media (min-width: 820px) {
	.cta {
		grid-template-columns: minmax(0, 1fr) auto;
		align-items: center;
		gap: var(--s-7);
	}
}

.cta h2 {
	color: var(--bg);
}

.cta p {
	margin-top: var(--s-4);
	color: #C9CCDD;
	max-width: 52ch;
}

.cta__actions {
	display: flex;
	flex-wrap: wrap;
	gap: var(--s-3);
}

.cta .btn--ghost {
	color: var(--bg);
	border-color: var(--bg);
}

.cta .btn--ghost:hover {
	background: var(--bg);
	color: var(--ink);
}

.cta :focus-visible {
	outline-color: var(--primary);
}

/* --- Подвал ------------------------------------------------------------- */

.site-footer {
	padding-block: 40px var(--s-6);
	border-top: 1px solid var(--border);
	background: var(--surface-alt);
}

.site-footer__top {
	display: grid;
	gap: clamp(28px, 4vw, 56px);
}

@media (min-width: 880px) {
	.site-footer__top {
		grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.6fr);
	}
}

.site-footer__tagline {
	margin-top: var(--s-4);
	color: var(--muted);
	font-size: var(--fs-sm);
	max-width: 42ch;
}

.site-footer__actions {
	display: flex;
	flex-wrap: wrap;
	gap: var(--s-3);
	margin-top: var(--s-5);
}

.site-footer__map {
	display: grid;
	gap: var(--s-5) var(--s-6);
	grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
}

.site-footer__group-title {
	margin: 0 0 var(--s-3);
	font-size: var(--fs-sm);
	font-weight: 600;
	color: var(--ink);
}

.site-footer__group ul {
	list-style: none;
	display: grid;
	gap: 8px;
	font-size: var(--fs-sm);
}

.site-footer__group a {
	color: var(--muted);
	text-decoration: none;
}

.site-footer__group a:hover {
	color: var(--ink);
	text-decoration: underline;
}

.site-footer__copy {
	margin-top: clamp(32px, 4vw, 56px);
	padding-top: var(--s-5);
	border-top: 1px solid var(--border);
	font-size: var(--fs-xs);
	color: var(--muted);
}

/* --- Юридические страницы ----------------------------------------------- */

.legal {
	max-width: 780px;
}

.legal h2 {
	font-size: clamp(1.25rem, 1.1rem + 0.7vw, 1.6rem);
	margin-top: clamp(32px, 4vw, 48px);
}

.legal p,
.legal ul {
	margin-top: var(--s-4);
}

.legal ul {
	padding-left: 22px;
	display: grid;
	gap: 8px;
}

.legal li {
	list-style: disc;
}

.legal__meta {
	margin-top: var(--s-4);
	color: var(--muted);
	font-size: var(--fs-sm);
}

/* --- Страница функции: первый экран ------------------------------------- */

.hero--feature {
	padding-top: clamp(16px, 2.5vw, 28px);
}

.hero--feature .breadcrumbs {
	margin-bottom: clamp(20px, 3vw, 36px);
}

/* Главный пример в рамке, как карточки коллажа на главной */
.feature-visual {
	position: relative;
	justify-self: center;
	width: 100%;
	max-width: 560px;
	padding: clamp(10px, 1.4vw, 14px);
	background: var(--surface);
	border: 2px solid var(--ink);
	border-radius: var(--r-lg);
	box-shadow: 8px 8px 0 var(--primary);
}

/* Шторка и скриншот уже в рамке feature-visual: своя чёрная обводка дала бы двойную рамку */
.feature-visual .compare__frame,
.feature-visual > .bento__shot {
	border: 0;
	border-radius: var(--r);
}

/* Маскот над верхней кромкой рамки снаружи: место под него даёт верхнее поле, пример он не закрывает */
/* Маскот на левом верхнем углу рамки: плашки и подписи кадров внизу, угол кадра обычно фон */
.feature-visual__mascot {
	position: absolute;
	top: -26px;
	left: -26px;
	z-index: 1;
	width: clamp(64px, 7.5vw, 96px);
	height: auto;
	pointer-events: none;
}

.feature-visual--mascot-right .feature-visual__mascot {
	left: auto;
	right: -26px;
}

@media (max-width: 560px) {
	.feature-visual {
		box-shadow: 6px 6px 0 var(--primary);
	}

	.feature-visual__mascot {
		top: -18px;
		left: -8px;
		width: 60px;
	}

	.feature-visual--mascot-right .feature-visual__mascot {
		left: auto;
		right: -8px;
	}
}

/* --- Пара «исходник → результат» ---------------------------------------- */

/* Ширины кадров пропорциональны ratio (--pair-grow = w/h), поэтому высоты в ряду совпадают */
.pair {
	display: flex;
	align-items: center;
	gap: clamp(8px, 1vw, 12px);
}

/* Плашка под своим кадром, а не поверх: кадры и так небольшие */
.pair__side {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	flex: var(--pair-grow, 1) 1 0%;
	min-width: 0;
}

.pair__side .example {
	align-self: stretch;
}

.pair__badge,
.inset__badge,
.compare__badge {
	padding: 2px 10px;
	border: 1px solid var(--border);
	border-radius: 999px;
	background: var(--surface);
	font-size: var(--fs-xs);
	font-weight: 600;
	line-height: 1.45;
	pointer-events: none;
}

.pair__side--result .pair__badge,
.compare__badge--after {
	background: var(--primary);
	border-color: var(--ink);
}

/* Стрелка по центру высоты кадров: нижнее поле равно высоте плашки с зазором */
.pair__arrow {
	position: relative;
	flex: 0 0 20px;
	height: 2px;
	margin-bottom: calc(var(--fs-xs) * 1.45 + 14px);
	background: var(--ink);
}

.pair__arrow::after {
	content: '';
	position: absolute;
	right: 0;
	top: 50%;
	width: 8px;
	height: 8px;
	border-top: 2px solid var(--ink);
	border-right: 2px solid var(--ink);
	transform: translateY(-50%) rotate(45deg);
}

/* Два широких кадра в столбик: рядом они были бы слишком низкими */
.pair--stack {
	flex-direction: column;
	align-items: stretch;
}

.pair--stack .pair__side {
	flex: none;
}

.pair--stack .pair__arrow {
	flex: 0 0 18px;
	align-self: center;
	width: 2px;
	height: auto;
	margin-bottom: 0;
}

.pair--stack .pair__arrow::after {
	top: auto;
	right: auto;
	bottom: 0;
	left: 50%;
	transform: translateX(-50%) rotate(135deg);
}

/* --- Галерея примеров --------------------------------------------------- */

.showcase {
	--showcase-gap: clamp(16px, 2vw, 24px);
	display: grid;
	gap: var(--showcase-gap);
	grid-template-columns: minmax(0, 1fr);
}

.showcase__card {
	display: flex;
	flex-direction: column;
	gap: var(--s-4);
	min-width: 0;
	padding: clamp(14px, 1.6vw, 20px);
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
}

.showcase__caption {
	margin-top: auto;
	font-size: var(--fs-sm);
	font-weight: 600;
	line-height: 1.4;
}

/* Две галереи подряд (горизонтальные и вертикальные ролики): тот же зазор, что внутри сетки */
.showcase + .showcase {
	margin-top: var(--showcase-gap);
}

/* Одиночные работы разной пропорции: карточка по высоте своего кадра, подпись сразу под ним */
.showcase--single {
	align-items: start;
}

.showcase--single .showcase__caption {
	margin-top: 0;
}

/* --- Сценарии ----------------------------------------------------------- */

.usecases {
	display: grid;
	gap: clamp(16px, 2vw, 24px);
	grid-template-columns: minmax(0, 1fr);
	list-style: none;
}

.usecases__card {
	padding: clamp(22px, 2.4vw, 30px);
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
}

.usecases__title-row {
	display: flex;
	align-items: center;
	gap: var(--s-3);
	min-height: 44px;
}

.usecases__icon {
	flex: none;
	width: 44px;
	height: 44px;
	border-radius: 12px;
}

.usecases__mark {
	flex: none;
	width: 12px;
	height: 12px;
	border-radius: 4px;
	background: var(--primary);
	border: 1.5px solid var(--ink);
}

.usecases__text {
	margin-top: var(--s-3);
	color: var(--muted);
	font-size: var(--fs-sm);
}

@media (min-width: 640px) {
	.showcase,
	.usecases {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (min-width: 1000px) {
	.showcase,
	.usecases {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

/* Пары «было → стало»: в карточке два кадра, поэтому не больше двух карточек в ряд, до 820 одна колонка не шире 560 */
.showcase--pair {
	justify-content: center;
}

@media (min-width: 640px) {
	.showcase--pair {
		grid-template-columns: minmax(0, 560px);
	}
}

@media (min-width: 820px) {
	.showcase--pair {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

/*
	Галерея «врезка» и вертикальные ролики (showcase--tall): кадр 9:16 на всю ширину карточки, у врезки исходник миниатюрой в левом нижнем углу.
	Мобильный: одна колонка, результат не шире 320 px по центру. 560-819: по две в ряд, нечётная по центру
	(при трёх колонках кадр был бы уже 200 px). От 820: три равные колонки.
*/
.showcase--inset,
.showcase--tall {
	justify-items: center;
}

.showcase--inset .showcase__card,
.showcase--tall .showcase__card {
	width: 100%;
	max-width: calc(320px + 2 * clamp(14px, 1.6vw, 20px) + 2px);
}

@media (min-width: 560px) {
	.showcase--inset,
	.showcase--tall {
		display: flex;
		flex-wrap: wrap;
		justify-content: center;
	}

	.showcase--inset .showcase__card,
	.showcase--tall .showcase__card {
		width: calc((100% - var(--showcase-gap)) / 2);
		max-width: none;
	}
}

@media (min-width: 820px) {
	.showcase--inset,
	.showcase--tall {
		display: grid;
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}

	.showcase--inset .showcase__card,
	.showcase--tall .showcase__card {
		width: auto;
	}
}

.inset {
	position: relative;
}

.inset__source {
	position: absolute;
	left: 10px;
	bottom: 10px;
	z-index: 1;
	width: 32%;
	padding: 3px;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: 14px;
	box-shadow: 0 12px 24px -12px rgba(27, 35, 64, 0.55);
}

.inset__source .example__media {
	border-radius: 11px;
}

.inset__source .example__media--empty {
	gap: 2px;
	padding: 6px;
	border-width: 1.5px;
}

.inset__source .example__slot {
	font-size: var(--fs-xs);
}

.inset__source .example__slot-file {
	display: none;
}


.sources {
	position: absolute;
	left: 10px;
	bottom: 10px;
	z-index: 1;
	display: flex;
	gap: 3px;
	width: calc(var(--sources-count, 3) * 19% + 6px);
	padding: 3px;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: 14px;
	box-shadow: 0 12px 24px -12px rgba(27, 35, 64, 0.55);
}

/* Плашка миниатюры над её рамкой, а не на кадре исходника */
.inset__source .inset__badge,
.sources .inset__badge {
	position: absolute;
	bottom: calc(100% + 6px);
	left: 0;
	padding: 0 7px;
	font-size: 0.6875rem;
	white-space: nowrap;
}

.sources__item {
	flex: 1 1 0;
	min-width: 0;
	height: auto;
	aspect-ratio: 3 / 4;
	object-fit: cover;
	border-radius: 11px;
}

/* --- Советы ------------------------------------------------------------- */

.tips {
	display: grid;
	gap: var(--s-5) clamp(28px, 4vw, 56px);
}

@media (min-width: 900px) {
	.tips {
		grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
		align-items: start;
	}

	.tips__intro {
		position: sticky;
		top: calc(var(--header-h) + 24px);
	}
}

.tips__intro p {
	margin-top: var(--s-4);
	color: var(--muted);
	font-size: var(--fs-lead);
}

.tips__list {
	padding: 4px clamp(18px, 2.4vw, 28px);
	list-style: none;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
}

.tips__item {
	display: grid;
	grid-template-columns: 36px minmax(0, 1fr);
	gap: var(--s-4);
	padding: 18px 0;
}

.tips__item + .tips__item {
	border-top: 1px solid var(--border);
}

.tips__num {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 11px;
	background: var(--primary-tint);
	border: 2px solid var(--ink);
	font-family: var(--font-display);
	font-weight: 700;
	font-size: 0.95rem;
}

.tips__title {
	font-family: var(--font-text);
	font-size: var(--fs-base);
	font-weight: 600;
	line-height: 1.35;
	letter-spacing: 0;
}

.tips__text {
	margin-top: 4px;
	color: var(--muted);
	font-size: var(--fs-sm);
}

/* --- Смежные страницы --------------------------------------------------- */

.related__title {
	margin-bottom: clamp(24px, 3vw, 40px);
}

.related {
	display: grid;
	gap: clamp(14px, 1.8vw, 20px);
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
	list-style: none;
}

.related__card {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 4px;
	height: 100%;
	padding: 20px 64px 20px 22px;
	background: var(--surface);
	border: 1px solid var(--border);
	border-radius: var(--r-lg);
	color: var(--ink);
	text-decoration: none;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.related__card::after {
	content: '';
	position: absolute;
	top: 50%;
	right: 20px;
	width: 30px;
	height: 30px;
	margin-top: -15px;
	border: 2px solid var(--ink);
	border-radius: 50%;
	transition: background-color 0.15s ease;
}

.related__card::before {
	content: '';
	position: absolute;
	top: 50%;
	right: 33px;
	z-index: 1;
	width: 7px;
	height: 7px;
	margin-top: -4px;
	border-top: 2px solid var(--ink);
	border-right: 2px solid var(--ink);
	transform: rotate(45deg);
}

.related__card:hover {
	color: var(--ink);
	border-color: var(--ink);
	box-shadow: 6px 6px 0 var(--primary);
}

.related__card:hover::after {
	background: var(--primary);
}

.related__label {
	font-weight: 600;
	font-size: var(--fs-h3);
	line-height: 1.3;
}

.related__hint {
	font-size: var(--fs-sm);
	color: var(--muted);
}

/* --- Утилиты ------------------------------------------------------------ */

.lead {
	font-size: var(--fs-lead);
	color: var(--muted);
	max-width: 60ch;
}

.stack-sm > * + * {
	margin-top: var(--s-3);
}

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

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