/* AnnyDental — основные стили. Палитра со старого сайта: #008aff, #f3f6fb, #434343, #2f2f2f,
   акценты — фиолетовый и бирюзовый из звёздочек на фото. */

@font-face {
	font-family: "Onest";
	src: url("../fonts/onest-cyrillic.woff2") format("woff2");
	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.woff2") format("woff2");
	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+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

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

:root {
	--blue: #008aff;
	--blue-400: #3aa6ff;
	--blue-600: #0074db;
	--blue-700: #005db3;
	--blue-50: #e8f3ff;
	--tint: #f3f6fb;
	--ink: #0f1d33;
	--text: #434343;
	--muted: #687384;
	--line: #e7e7e7;
	--line-soft: #e6ecf5;
	--violet: #8b5cf6;
	--teal: #14b8a6;
	--teal-700: #1d7a73;
	--footer: #1b1f26;
	--white: #fff;

	--grad: linear-gradient(120deg, var(--blue) 0%, var(--violet) 55%, var(--teal) 100%);
	--grad-blue: linear-gradient(135deg, var(--blue-400) 0%, var(--blue) 45%, var(--blue-700) 100%);
	--grad-title: linear-gradient(120deg, var(--ink) 10%, var(--blue-700) 65%, var(--blue));

	--font: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
	--radius: 24px;
	--radius-sm: 14px;
	--shadow: 0 1px 2px rgba(15, 29, 51, .04), 0 10px 30px -12px rgba(15, 29, 51, .14);
	--shadow-lg: 0 2px 6px rgba(15, 29, 51, .05), 0 30px 60px -20px rgba(0, 93, 179, .32);
	--glass-bg: rgba(255, 255, 255, .62);
	--glass-border: rgba(255, 255, 255, .85);
	--header-h: 76px;
	--gutter: clamp(16px, 4vw, 32px);
	--ease: cubic-bezier(.22, 1, .36, 1);
}

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

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

body {
	margin: 0;
	background: #f8fafd;
	color: var(--text);
	font: 400 17px/1.65 var(--font);
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
	overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--blue-600); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--blue-700); }
:focus-visible { outline: 3px solid rgba(0, 138, 255, .45); outline-offset: 3px; border-radius: 6px; }
::selection { background: rgba(0, 138, 255, .18); }

h1, h2, h3, h4 { color: var(--ink); line-height: 1.15; letter-spacing: -.025em; margin: 0 0 .5em; font-weight: 700; }
p { margin: 0 0 1em; }

.icon { width: 1.25em; height: 1.25em; flex: none; }

.container { position: relative; width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }
.container--narrow { max-width: 820px; }

.skip-link { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--white); padding: 8px 16px; border-radius: 8px; }
.skip-link:focus { left: 8px; }

.gradient-text {
	background: var(--grad);
	background-size: 200% auto;
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	animation: grad-shift 8s ease-in-out infinite alternate;
}
@keyframes grad-shift { to { background-position: 100% 50%; } }

/* «Стекло» без backdrop-filter: под плашками анимированный canvas, и размытие
   пересчитывалось бы на каждом кадре. Почти непрозрачный фон выглядит так же. */
.glass {
	background: linear-gradient(135deg, rgba(255, 255, 255, .92), rgba(255, 255, 255, .78));
	border: 1px solid var(--glass-border);
	box-shadow: var(--shadow);
}

/* ---------- Живой фон страницы: медленно плывущие пятна света ---------- */
.ambient { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.ambient span {
	position: absolute; width: 60vmax; height: 60vmax; border-radius: 50%;
	opacity: .55; will-change: transform;
}
.ambient span:nth-child(1) { top: -25vmax; left: -15vmax; background: radial-gradient(closest-side, rgba(0, 138, 255, .22), transparent); animation: drift-1 28s ease-in-out infinite alternate; }
.ambient span:nth-child(2) { top: 20vh; right: -25vmax; background: radial-gradient(closest-side, rgba(139, 92, 246, .16), transparent); animation: drift-2 34s ease-in-out infinite alternate; }
.ambient span:nth-child(3) { bottom: -30vmax; left: 10vw; background: radial-gradient(closest-side, rgba(20, 184, 166, .14), transparent); animation: drift-3 40s ease-in-out infinite alternate; }
.ambient span:nth-child(4) { top: 40vh; left: 30vw; width: 40vmax; height: 40vmax; background: radial-gradient(closest-side, rgba(0, 138, 255, .12), transparent); animation: drift-2 46s ease-in-out infinite alternate-reverse; }
@keyframes drift-1 { to { transform: translate3d(30vw, 25vh, 0) scale(1.15); } }
@keyframes drift-2 { to { transform: translate3d(-35vw, -15vh, 0) scale(.9); } }
@keyframes drift-3 { to { transform: translate3d(20vw, -30vh, 0) scale(1.2); } }

.scroll-progress {
	position: fixed; top: 0; left: 0; right: 0; z-index: 60; height: 3px;
	background: var(--grad); transform-origin: 0 50%; transform: scaleX(var(--progress, 0));
}

/* ---------- Кнопки ---------- */
.btn {
	position: relative; overflow: hidden; isolation: isolate;
	display: inline-flex; align-items: center; justify-content: center; gap: .5em;
	min-height: 48px; padding: 12px 24px; border-radius: 999px; border: 1px solid transparent;
	font: 600 16px/1.2 var(--font); text-decoration: none; cursor: pointer; white-space: nowrap;
	transition: background-color .25s, color .25s, border-color .25s, box-shadow .3s, translate .35s var(--ease);
}
.btn .icon { width: 18px; height: 18px; transition: transform .3s var(--ease); }
.btn:hover .icon { transform: translateX(4px); }
.btn--lg { min-height: 58px; padding: 15px 32px; font-size: 17px; }
.btn--sm { min-height: 42px; padding: 9px 20px; font-size: 15px; }
.btn--primary {
	background: var(--grad-blue); color: var(--white);
	box-shadow: 0 10px 24px -10px rgba(0, 138, 255, .85), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.btn--primary::after,
.btn--white::after {
	content: ""; position: absolute; inset: 0; z-index: -1;
	background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .45) 50%, transparent 70%);
	transform: translateX(-120%); transition: transform .8s var(--ease);
}
.btn--primary:hover::after,
.btn--white:hover::after { transform: translateX(120%); }
.btn--primary:hover { color: var(--white); box-shadow: 0 16px 34px -12px rgba(0, 138, 255, .95), inset 0 1px 0 rgba(255, 255, 255, .25); }
.btn--glass, .btn--ghost {
	background: rgba(255, 255, 255, .88); color: var(--blue-700);
	border-color: rgba(0, 138, 255, .28);
}
.btn--glass:hover, .btn--ghost:hover { border-color: var(--blue); background: var(--white); color: var(--blue-700); }
.btn--white { background: var(--white); color: var(--blue-700); box-shadow: 0 12px 30px -12px rgba(0, 0, 0, .35); }
.btn--white::after { background: linear-gradient(110deg, transparent 30%, rgba(0, 138, 255, .14) 50%, transparent 70%); }
.btn--white:hover { color: var(--blue-700); }
.btn--outline-white { color: var(--white); border-color: rgba(255, 255, 255, .55); }
.btn--outline-white:hover { color: var(--white); border-color: var(--white); background: rgba(255, 255, 255, .12); }

/* ---------- Шапка ---------- */
.site-header {
	position: sticky; top: 0; z-index: 50;
	background: rgba(255, 255, 255, .55);
	-webkit-backdrop-filter: saturate(180%) blur(18px);
	backdrop-filter: saturate(180%) blur(18px);
	border-bottom: 1px solid transparent;
	transition: border-color .3s, box-shadow .3s, background-color .3s;
}
.site-header.is-scrolled { background: rgba(255, 255, 255, .82); border-bottom-color: rgba(15, 29, 51, .06); box-shadow: 0 10px 30px -22px rgba(15, 29, 51, .45); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: var(--header-h); }

.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.brand:hover { color: var(--ink); }
.brand__mark {
	position: relative; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px;
	background: var(--grad-blue); color: var(--white);
	box-shadow: 0 8px 18px -8px rgba(0, 138, 255, .8);
	transition: transform .5s var(--ease);
}
.brand:hover .brand__mark { transform: rotate(-8deg) scale(1.06); }
.brand__mark .icon { width: 24px; height: 24px; }
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name { font-weight: 700; font-size: 18px; letter-spacing: -.01em; color: var(--blue); }
.brand__role { font-size: 13px; color: var(--muted); }
.brand--light .brand__name { color: var(--white); }
.brand--light .brand__role { color: rgba(255, 255, 255, .6); }

.nav { display: flex; align-items: center; gap: 24px; }
.nav__list { display: flex; gap: 2px; list-style: none; margin: 0; padding: 0; }
.nav__list a {
	position: relative; display: block; padding: 8px 13px; border-radius: 999px;
	color: var(--ink); font-weight: 500; font-size: 15px; text-decoration: none;
	transition: color .2s;
}
.nav__list a::after {
	content: ""; position: absolute; left: 13px; right: 13px; bottom: 3px; height: 2px; border-radius: 2px;
	background: var(--grad); transform: scaleX(0); transform-origin: 0 50%; transition: transform .35s var(--ease);
}
.nav__list a:hover, .nav__list a.is-active { color: var(--blue-700); }
.nav__list a:hover::after, .nav__list a.is-active::after { transform: scaleX(1); }
.nav-toggle { display: none; }

@media (max-width: 1140px) {
	.nav__list a { padding: 8px 9px; font-size: 14px; }
	.nav__list a::after { left: 9px; right: 9px; }
	.nav { gap: 12px; }
}
@media (max-width: 1000px) {
	.nav-toggle {
		display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px;
		border: 1px solid var(--line-soft); background: rgba(255, 255, 255, .8); color: var(--ink); cursor: pointer;
	}
	.nav-toggle .icon { width: 24px; height: 24px; }
	.nav-toggle__close, .nav-open .nav-toggle__open { display: none; }
	.nav-open .nav-toggle__close { display: block; }
	.nav {
		position: fixed; inset: var(--header-h) 0 auto 0; z-index: 49;
		flex-direction: column; align-items: stretch; gap: 16px;
		padding: 16px var(--gutter) 24px; background: rgba(255, 255, 255, .96);
		-webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px);
		border-bottom: 1px solid var(--line-soft); box-shadow: 0 24px 40px -24px rgba(15, 29, 51, .35);
		transform: translateY(-8px); opacity: 0; visibility: hidden;
		transition: opacity .25s, transform .35s var(--ease), visibility .25s;
	}
	.nav-open .nav { transform: none; opacity: 1; visibility: visible; }
	.nav__list { flex-direction: column; }
	.nav__list a { padding: 12px 14px; font-size: 17px; }
	.nav__list a::after { display: none; }
	.brand__role { display: none; }
}

/* ---------- Первый экран ---------- */
.hero {
	position: relative; overflow: hidden; isolation: isolate;
	min-height: min(860px, calc(100svh - var(--header-h)));
	display: flex; flex-direction: column; justify-content: center;
	padding: clamp(32px, 5vw, 64px) 0 clamp(64px, 7vw, 96px);
}
.hero__canvas {
	position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%;
	/* Под текстом слева частицы почти прозрачные, чтобы не мешать чтению. */
	-webkit-mask-image: linear-gradient(90deg, rgba(0, 0, 0, .18) 0%, rgba(0, 0, 0, .3) 40%, #000 62%);
	mask-image: linear-gradient(90deg, rgba(0, 0, 0, .18) 0%, rgba(0, 0, 0, .3) 40%, #000 62%);
}
@media (max-width: 900px) {
	.hero__canvas { -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 35%, rgba(0, 0, 0, .2) 55%); mask-image: linear-gradient(180deg, #000 0%, #000 35%, rgba(0, 0, 0, .2) 55%); }
}
.hero__aurora { position: absolute; inset: 0; z-index: -2; overflow: hidden; }
.hero__aurora span { position: absolute; border-radius: 50%; will-change: transform; }
.hero__aurora span:nth-child(1) { width: 720px; height: 720px; right: -140px; top: -160px; background: radial-gradient(closest-side, rgba(0, 138, 255, .28), transparent); animation: aurora-1 18s ease-in-out infinite alternate; }
.hero__aurora span:nth-child(2) { width: 520px; height: 520px; left: -160px; bottom: -200px; background: radial-gradient(closest-side, rgba(139, 92, 246, .2), transparent); animation: aurora-2 22s ease-in-out infinite alternate; }
.hero__aurora span:nth-child(3) { width: 460px; height: 460px; left: 40%; top: 30%; background: radial-gradient(closest-side, rgba(20, 184, 166, .14), transparent); animation: aurora-1 26s ease-in-out infinite alternate-reverse; }
@keyframes aurora-1 { to { transform: translate3d(-120px, 80px, 0) scale(1.2); } }
@keyframes aurora-2 { to { transform: translate3d(140px, -60px, 0) scale(1.15); } }

.hero__grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(32px, 5vw, 72px); align-items: center; }
.eyebrow {
	display: inline-flex; align-items: center; gap: 10px; margin-bottom: 22px;
	padding: 8px 16px 8px 12px; border-radius: 999px;
	background: rgba(255, 255, 255, .85); border: 1px solid rgba(0, 138, 255, .18);
	color: var(--blue-700); font-size: 14px; font-weight: 600;
}
.eyebrow__dot { position: relative; width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--teal); }
.eyebrow__dot::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--teal); animation: ping 2s var(--ease) infinite; }
@keyframes ping { from { transform: scale(.6); opacity: 1; } to { transform: scale(1.8); opacity: 0; } }

.hero__title { font-size: clamp(40px, 6vw, 76px); line-height: 1.02; letter-spacing: -.04em; margin-bottom: 24px; }
.hero__lead { font-size: clamp(16px, 1.35vw, 18px); color: var(--text); max-width: 58ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

.stats {
	display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px;
	list-style: none; margin: 44px 0 0; padding: 0;
}
.stats__item { position: relative; padding: 18px 16px; border-radius: var(--radius-sm); }
.stats__num {
	display: block; font-size: 34px; line-height: 1; font-weight: 800; letter-spacing: -.04em;
	background: var(--grad-blue); -webkit-background-clip: text; background-clip: text; color: transparent;
	font-variant-numeric: tabular-nums;
}
.stats__label { display: block; margin-top: 8px; font-size: 13px; line-height: 1.3; color: var(--muted); }

.hero__media { position: relative; max-width: 520px; width: 100%; justify-self: center; aspect-ratio: 1025 / 1210; }
.hero__ring { position: absolute; inset: 15% 2% 1% 2%; }
.hero__ring::before {
	content: ""; position: absolute; inset: 0; border-radius: 50%;
	background: conic-gradient(from var(--angle), var(--blue), var(--violet), var(--teal), var(--blue-400), var(--blue));
	animation: spin 10s linear infinite;
	box-shadow: var(--shadow-lg);
}
.hero__ring::after {
	content: ""; position: absolute; inset: 10px; border-radius: 50%;
	background: radial-gradient(circle at 35% 30%, #ffffff, #e9f4ff 70%);
}
@keyframes spin { to { --angle: 360deg; } }
.hero__pulse { position: absolute; inset: 0; border-radius: 50%; border: 2px solid rgba(0, 138, 255, .35); animation: pulse 4.5s var(--ease) infinite; }
.hero__pulse:nth-child(2) { animation-delay: 1.5s; }
.hero__pulse:nth-child(3) { animation-delay: 3s; }
@keyframes pulse { from { transform: scale(1); opacity: .9; } to { transform: scale(1.35); opacity: 0; } }
.hero__photo-wrap { position: relative; }
.hero__photo { width: 100%; filter: drop-shadow(0 24px 40px rgba(0, 46, 92, .28)); animation: float 7s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-12px); } }

.chip {
	position: absolute; z-index: 2; display: flex; align-items: center; gap: 12px;
	padding: 12px 16px 12px 12px; border-radius: 18px; font-size: 13px; line-height: 1.3; color: var(--muted);
	animation: bob 6s ease-in-out infinite;
}
.chip strong { display: block; color: var(--ink); font-size: 15px; }
.chip--1 { left: -12%; top: 18%; }
.chip--2 { right: -10%; top: 52%; animation-delay: -2s; }
.chip--3 { left: -4%; bottom: 3%; animation-delay: -4s; }
@keyframes bob { 50% { transform: translateY(-10px); } }
.chip__icon { display: grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: 12px; background: var(--grad-blue); color: var(--white); box-shadow: 0 8px 18px -8px rgba(0, 138, 255, .8); }
.chip__icon .icon { width: 22px; height: 22px; }
.chip__icon--violet { background: linear-gradient(135deg, #b18cff, var(--violet)); box-shadow: 0 8px 18px -8px rgba(139, 92, 246, .8); }
.chip__icon--teal { background: linear-gradient(135deg, #4fd8c6, var(--teal-700)); box-shadow: 0 8px 18px -8px rgba(20, 184, 166, .8); }

.hero__scroll {
	position: absolute; left: 50%; bottom: 22px; translate: -50% 0;
	width: 28px; height: 44px; border-radius: 14px; border: 2px solid rgba(15, 29, 51, .25);
}
.hero__scroll span { position: absolute; left: 50%; top: 8px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: var(--blue); animation: wheel 1.8s var(--ease) infinite; }
@keyframes wheel { from { transform: translateY(0); opacity: 1; } to { transform: translateY(14px); opacity: 0; } }

@media (max-width: 1100px) {
	.chip--1 { left: -4%; }
	.chip--2 { right: -2%; }
}
@media (max-width: 900px) {
	.hero { min-height: 0; }
	.hero__grid { grid-template-columns: 1fr; }
	.hero__media { order: -1; max-width: 380px; }
	.hero__scroll { display: none; }
}
@media (max-width: 640px) {
	.stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.hero__actions .btn { flex: 1 1 100%; }
	.chip { padding: 8px 12px 8px 8px; font-size: 11px; border-radius: 14px; gap: 8px; }
	.chip strong { font-size: 13px; }
	.chip__icon { width: 32px; height: 32px; border-radius: 10px; }
	.chip__icon .icon { width: 18px; height: 18px; }
	.chip--1 { left: -2%; top: 14%; }
	.chip--2 { display: none; }
	.chip--3 { left: auto; right: -2%; bottom: 6%; }
}

/* ---------- Секции ---------- */
.section { position: relative; padding: clamp(64px, 9vw, 120px) 0; }
.section--compact { padding: clamp(32px, 5vw, 56px) 0 clamp(56px, 8vw, 96px); }
.section--tint { background: linear-gradient(180deg, rgba(243, 246, 251, 0), rgba(243, 246, 251, .75) 12%, rgba(243, 246, 251, .75) 88%, rgba(243, 246, 251, 0)); }
.section--flush-top { padding-top: clamp(16px, 3vw, 40px); }
.section__head { max-width: 760px; margin: 0 auto clamp(36px, 4.5vw, 56px); text-align: center; }
.section__head--row { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; max-width: none; text-align: left; }
.section__head--row > div { max-width: 680px; }
.section__kicker {
	display: inline-flex; align-items: center; gap: 8px; margin-bottom: 14px;
	padding: 6px 14px; border-radius: 999px; background: rgba(0, 138, 255, .08);
	color: var(--blue-700); font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
}
.section__kicker::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--grad); }
.section__title {
	font-size: clamp(34px, 4.4vw, 56px); letter-spacing: -.035em; margin-bottom: 16px; padding-bottom: .06em;
	background: var(--grad-title); -webkit-background-clip: text; background-clip: text; color: transparent;
}
/* Разбитый на слова заголовок: градиент на каждом слове, иначе сдвинутые слова теряют заливку. */
.section__title.is-split { background: none; color: var(--ink); }
.section__title.is-split .split-word > span { background: var(--grad-title); -webkit-background-clip: text; background-clip: text; color: transparent; }
.section__lead { margin: 0; color: var(--muted); font-size: 18px; }
.section__more { margin-top: 32px; text-align: center; }
@media (max-width: 720px) {
	.section__head--row { flex-direction: column; align-items: flex-start; }
}

.card { background: var(--white); border: 1px solid var(--line-soft); border-radius: var(--radius); box-shadow: var(--shadow); }

/* Наклон и подсветка за курсором: переменные --rx/--ry/--mx/--my ставит main.js. */
[data-tilt] {
	transform: perspective(1000px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
	transition: transform .6s var(--ease), box-shadow .4s, opacity .9s var(--ease), translate .9s var(--ease);
}
[data-tilt].is-tilting { transition: transform .12s linear, box-shadow .4s, opacity .9s var(--ease), translate .9s var(--ease); }
.spot { position: relative; isolation: isolate; }
.spot::before {
	content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
	background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(0, 138, 255, .12), transparent 45%);
	opacity: 0; transition: opacity .4s;
}
.spot::after {
	content: ""; position: absolute; inset: -1px; z-index: 3; border-radius: inherit; padding: 1px; pointer-events: none;
	background: radial-gradient(260px circle at var(--mx, 50%) var(--my, 50%), rgba(0, 138, 255, .9), rgba(139, 92, 246, .5) 40%, transparent 70%);
	-webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
	-webkit-mask-composite: xor; mask-composite: exclude;
	opacity: 0; transition: opacity .4s;
}
.spot:hover::before, .spot:hover::after { opacity: 1; }

/* ---------- О себе ---------- */
.about { display: grid; grid-template-columns: 1.6fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: start; }
.about__text { position: relative; padding: clamp(28px, 4vw, 52px); font-size: 17px; border-radius: 28px; }
.about__quote { position: absolute; top: -20px; left: 36px; width: 48px; height: 48px; padding: 10px; border-radius: 16px; background: var(--grad-blue); color: var(--white); box-shadow: var(--shadow-lg); }
.about__text p:last-of-type { margin-bottom: 0; }
.about__sign { margin-top: 26px !important; padding-top: 22px; border-top: 1px solid var(--line-soft); color: var(--ink); font-weight: 600; }
.about__sign span { display: block; color: var(--muted); font-size: 14px; font-weight: 400; }
.about__photo { margin: 0; position: sticky; top: calc(var(--header-h) + 24px); }
.frame { position: relative; display: block; padding: 6px; border-radius: 30px; isolation: isolate; }
.frame::before {
	content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
	background: conic-gradient(from var(--angle), var(--blue), var(--violet), var(--teal), var(--blue));
	animation: spin 8s linear infinite;
}
.frame::after { content: ""; position: absolute; inset: 18px -18px -18px 18px; z-index: -2; border-radius: inherit; background: var(--grad); opacity: .25; filter: blur(30px); }
.frame img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 24px; }
.about__photo figcaption { margin-top: 16px; text-align: center; font-size: 14px; color: var(--muted); }
@media (max-width: 900px) {
	.about { grid-template-columns: 1fr; }
	.about__photo { position: static; max-width: 420px; margin: 0 auto; order: -1; }
}

.timeline {
	position: relative;
	display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px;
	list-style: none; margin: clamp(48px, 6vw, 72px) 0 0; padding: 0;
}
.timeline::before,
.timeline::after {
	content: ""; position: absolute; left: 24px; right: 24px; top: 24px; height: 2px; border-radius: 2px;
}
.timeline::before { background: rgba(0, 138, 255, .14); }
.timeline::after { background: var(--grad); transform-origin: 0 50%; transform: scaleX(var(--progress, 0)); }
.timeline__item { position: relative; z-index: 1; }
.timeline__item p { margin: 0; font-size: 15px; color: var(--muted); }
.timeline__icon {
	display: grid; place-items: center; width: 50px; height: 50px; margin-bottom: 20px; border-radius: 16px;
	background: var(--white); color: var(--blue); border: 1px solid var(--line-soft); box-shadow: var(--shadow);
	transition: background .5s, color .5s, transform .5s var(--ease);
}
.timeline__item.is-reached .timeline__icon { background: var(--grad-blue); color: var(--white); transform: scale(1.06); border-color: transparent; }
.timeline__icon .icon { width: 24px; height: 24px; }
.timeline__when { display: block; font-size: 13px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--blue); }
.timeline__title { margin: 6px 0 8px; font-size: 20px; }
@media (max-width: 900px) {
	.timeline { grid-template-columns: 1fr; gap: 28px; padding-left: 70px; }
	.timeline::before, .timeline::after { left: 24px; right: auto; top: 24px; bottom: 24px; width: 2px; height: auto; }
	.timeline::after { transform-origin: 50% 0; transform: scaleY(var(--progress, 0)); }
	.timeline__icon { position: absolute; left: -70px; top: 0; margin: 0; }
}

/* ---------- Публикации ---------- */
.ticker {
	position: relative; overflow: hidden; margin: 0 calc(50% - 50vw) 36px; padding: 6px 0;
	-webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
	mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.ticker__track { display: flex; gap: 14px; width: max-content; animation: marquee 90s linear infinite; }
.ticker:hover .ticker__track { animation-play-state: paused; }
.ticker__item {
	display: inline-flex; align-items: center; gap: 12px; padding: 10px 18px; border-radius: 999px;
	background: rgba(255, 255, 255, .75); border: 1px solid var(--line-soft); color: var(--ink);
	font-size: 15px; font-weight: 500; white-space: nowrap;
}
.ticker__item::before { content: "✦"; color: var(--violet); }
.ticker__item:nth-child(3n + 2)::before { color: var(--blue); }
.ticker__item:nth-child(3n)::before { color: var(--teal); }
@keyframes marquee { to { transform: translateX(calc(-50% - 7px)); } }

.pubs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; list-style: none; margin: 0; padding: 0; }
.js .pubs--collapsible:not(.is-expanded) .pubs__item--extra { display: none; }
.pubs__link {
	display: flex; align-items: center; gap: 16px; height: 100%;
	padding: 18px 20px; border-radius: 18px; background: rgba(255, 255, 255, .85);
	border: 1px solid var(--line-soft); color: var(--ink); text-decoration: none;
	transition: box-shadow .35s;
}
.pubs__link:hover { color: var(--ink); box-shadow: var(--shadow-lg); }
.pubs__icon { display: grid; place-items: center; width: 46px; height: 46px; flex: none; border-radius: 14px; background: var(--blue-50); color: var(--blue); transition: background .35s, color .35s; }
.pubs__link:hover .pubs__icon { background: var(--grad-blue); color: var(--white); }
.pubs__body { flex: 1; min-width: 0; }
.pubs__title { display: block; font-weight: 600; line-height: 1.35; }
.pubs__source { display: block; margin-top: 4px; font-size: 13px; color: var(--muted); }
.pubs__ext { color: var(--muted); width: 18px; height: 18px; transition: color .3s, transform .3s var(--ease); }
.pubs__link:hover .pubs__ext { color: var(--blue); transform: translate(2px, -2px); }
@media (max-width: 760px) { .pubs { grid-template-columns: 1fr; } }

/* ---------- Запись ---------- */
.section--consult { padding: clamp(40px, 6vw, 80px) 0; }
.consult {
	position: relative; overflow: hidden; isolation: isolate;
	display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: center;
	padding: clamp(36px, 5.5vw, 72px); border-radius: 32px; color: rgba(255, 255, 255, .92);
	background: linear-gradient(120deg, #0a7bf0, var(--blue) 30%, #5b6cff 60%, var(--blue-700) 100%);
	background-size: 220% 220%;
	animation: consult-bg 14s ease-in-out infinite alternate;
	box-shadow: 0 40px 80px -30px rgba(0, 93, 179, .55);
}
@keyframes consult-bg { to { background-position: 100% 100%; } }
.consult::before {
	content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
	background: radial-gradient(500px circle at var(--mx, 70%) var(--my, 20%), rgba(255, 255, 255, .22), transparent 50%);
}
.consult__orb { position: absolute; z-index: -1; border-radius: 50%; pointer-events: none; }
.consult__orb--1 { width: 340px; height: 340px; right: -110px; bottom: -150px; border: 2px solid rgba(255, 255, 255, .22); animation: spin-slow 30s linear infinite; }
.consult__orb--1::after { content: ""; position: absolute; top: 18%; left: 8%; width: 14px; height: 14px; border-radius: 50%; background: #fff; box-shadow: 0 0 18px #fff; }
.consult__orb--2 { width: 220px; height: 220px; left: -80px; top: -90px; background: radial-gradient(closest-side, rgba(139, 92, 246, .55), transparent); animation: bob 8s ease-in-out infinite; }
.consult__orb--3 { width: 160px; height: 160px; left: 46%; bottom: -70px; background: radial-gradient(closest-side, rgba(20, 184, 166, .5), transparent); animation: bob 10s ease-in-out infinite reverse; }
@keyframes spin-slow { to { transform: rotate(360deg); } }
.consult__title { color: var(--white); font-size: clamp(32px, 4vw, 52px); letter-spacing: -.035em; }
.consult__main p { font-size: 18px; margin: 0; }
.consult__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin-top: 26px; }
.consult__email { display: inline-flex; align-items: center; gap: 8px; color: var(--white); font-weight: 500; }
@media (max-width: 860px) { .consult { grid-template-columns: 1fr; } }

/* ---------- Статьи ---------- */
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(18px, 2.4vw, 30px); }
@media (max-width: 1024px) { .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .post-grid { grid-template-columns: 1fr; } }
.post-card {
	position: relative; display: flex; flex-direction: column; overflow: hidden;
	background: rgba(255, 255, 255, .9); border: 1px solid var(--line-soft); border-radius: var(--radius);
	box-shadow: var(--shadow);
}
.post-card:hover { box-shadow: var(--shadow-lg); }
.post-card__media { position: relative; display: block; aspect-ratio: 1 / 1; overflow: hidden; background: var(--tint); }
.post-card__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(15, 29, 51, .28)); opacity: 0; transition: opacity .5s; }
.post-card:hover .post-card__media::after { opacity: 1; }
.post-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.post-card:hover .post-card__media img { transform: scale(1.07); }
.post-card__placeholder { display: grid; place-items: center; height: 100%; color: var(--blue); }
.post-card__placeholder .icon { width: 64px; height: 64px; }
.post-card__body { display: flex; flex-direction: column; flex: 1; padding: 22px 24px 26px; }
.post-card__meta { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 10px; font-size: 13px; color: var(--muted); }
.post-card__meta span { display: inline-flex; align-items: center; gap: 5px; }
.post-card__meta .icon { width: 15px; height: 15px; }
.post-card__title { font-size: 19px; line-height: 1.3; margin-bottom: 10px; }
.post-card__title a { color: var(--ink); text-decoration: none; }
.post-card__title a::after { content: ""; position: absolute; inset: 0; z-index: 2; }
.post-card:hover .post-card__title a { color: var(--blue-700); }
.post-card__excerpt { font-size: 15px; color: var(--muted); margin-bottom: 16px; }
.post-card__more { display: inline-flex; align-items: center; gap: 6px; margin-top: auto; color: var(--blue); font-weight: 600; font-size: 15px; }
.post-card__more .icon { width: 16px; height: 16px; transition: transform .35s var(--ease); }
.post-card:hover .post-card__more .icon { transform: translateX(5px); }

/* ---------- Сертификаты ---------- */
.certs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(18px, 2.4vw, 30px); list-style: none; margin: 0; padding: 0; }
@media (max-width: 1024px) { .certs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .certs { grid-template-columns: 1fr; } }
.certs__link {
	display: flex; flex-direction: column; height: 100%; padding: 12px;
	border-radius: var(--radius); background: rgba(255, 255, 255, .9); border: 1px solid var(--line-soft);
	color: var(--ink); text-decoration: none; box-shadow: var(--shadow);
}
.certs__link:hover { color: var(--ink); box-shadow: var(--shadow-lg); }
.certs__img { position: relative; display: block; aspect-ratio: 3245 / 2297; overflow: hidden; border-radius: var(--radius-sm); background: var(--tint); }
.certs__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease); }
.certs__img::after {
	content: ""; position: absolute; top: -50%; bottom: -50%; left: -60%; width: 40%;
	background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .75), transparent);
	transform: skewX(-20deg); transition: transform 1s var(--ease);
}
.certs__link:hover .certs__img::after { transform: skewX(-20deg) translateX(420%); }
.certs__link:hover .certs__img img { transform: scale(1.04); }
.certs__title { display: flex; align-items: flex-start; gap: 10px; padding: 14px 6px 4px; font-weight: 600; line-height: 1.35; }
.certs__title .icon { color: var(--blue); margin-top: 1px; }

/* ---------- Подвал ---------- */
.site-footer { position: relative; overflow: hidden; background: var(--footer); color: rgba(255, 255, 255, .72); padding-top: clamp(56px, 7vw, 88px); font-size: 15px; isolation: isolate; }
.site-footer::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px; background: var(--grad); opacity: .8; }
.site-footer::after { content: ""; position: absolute; z-index: -1; top: -260px; left: 50%; width: 900px; height: 520px; translate: -50% 0; background: radial-gradient(closest-side, rgba(0, 138, 255, .22), transparent); }
.site-footer a { color: rgba(255, 255, 255, .85); text-decoration: none; transition: color .2s; }
.site-footer a:hover { color: var(--white); }
.site-footer__grid { display: grid; grid-template-columns: 1.3fr 1fr .8fr 1.2fr; gap: 40px; padding-bottom: 48px; }
.site-footer__about p { margin: 16px 0 0; max-width: 32ch; }
.site-footer__title { margin-bottom: 18px; color: var(--white); font-size: 17px; letter-spacing: 0; }
.site-footer__list { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 10px; }
.site-footer__list a { display: inline-flex; align-items: center; gap: 8px; word-break: break-word; }
.site-footer__list .icon { width: 18px; height: 18px; color: #5cb6ff; }
.site-footer__list--articles a { display: block; line-height: 1.4; }
.site-footer .btn--primary { color: var(--white); }
.socials { display: flex; gap: 10px; list-style: none; margin: 20px 0 0; padding: 0; }
.socials a { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: rgba(255, 255, 255, .08); }
.socials a:hover { background: var(--blue); }
.site-footer__bottom {
	display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
	padding-top: 24px; padding-bottom: 24px; border-top: 1px solid rgba(255, 255, 255, .1);
	font-size: 13px; color: rgba(255, 255, 255, .5);
}
.site-footer__bottom p { margin: 0; }
@media (max-width: 960px) { .site-footer__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .site-footer__grid { grid-template-columns: 1fr; gap: 32px; } }

/* ---------- Лайтбокс ---------- */
.lightbox {
	width: 100vw; height: 100vh; max-width: none; max-height: none; margin: 0; padding: 0;
	border: 0; background: rgba(10, 16, 28, .88); color: var(--white);
	-webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
}
.lightbox::backdrop { background: transparent; }
.lightbox[open] { display: grid; place-items: center; animation: fade-in .3s ease; }
@keyframes fade-in { from { opacity: 0; } }
.lightbox__figure { margin: 0; padding: 64px 72px; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; }
.lightbox__img { max-width: min(1200px, 100%); max-height: calc(100vh - 160px); width: auto; border-radius: 10px; box-shadow: 0 30px 80px rgba(0, 0, 0, .5); animation: zoom-in .45s var(--ease); }
@keyframes zoom-in { from { transform: scale(.92); opacity: 0; } }
.lightbox__caption { margin-top: 16px; font-weight: 600; text-align: center; }
.lightbox__btn {
	position: fixed; display: grid; place-items: center; width: 48px; height: 48px;
	border: 0; border-radius: 50%; background: rgba(255, 255, 255, .12); color: var(--white); cursor: pointer;
	transition: background .2s;
}
.lightbox__btn:hover { background: rgba(255, 255, 255, .24); }
.lightbox__close { top: 16px; right: 16px; }
.lightbox__prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lightbox__next { right: 16px; top: 50%; transform: translateY(-50%); }
@media (max-width: 640px) {
	.lightbox__figure { padding: 72px 12px; }
	.lightbox__prev, .lightbox__next { top: auto; bottom: 16px; transform: none; }
}

/* ---------- Страницы и статьи ---------- */
.page-head { padding: clamp(40px, 6vw, 72px) 0 clamp(24px, 3vw, 40px); }
.page-head__title { font-size: clamp(34px, 4.8vw, 58px); letter-spacing: -.035em; margin-bottom: 12px; }
.page-head__lead { color: var(--muted); font-size: 18px; max-width: 64ch; }
.page-head__lead p:last-child { margin: 0; }
.page-head--404 { text-align: left; padding-bottom: clamp(56px, 8vw, 104px); }
.page-head__code {
	margin: 0; font-size: clamp(88px, 14vw, 180px); font-weight: 800; line-height: 1; letter-spacing: -.06em;
	background: var(--grad); background-size: 200% auto; -webkit-background-clip: text; background-clip: text; color: transparent;
	animation: grad-shift 6s ease-in-out infinite alternate;
}

.breadcrumbs { margin-bottom: 20px; font-size: 14px; color: var(--muted); }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--blue); }
.breadcrumbs .breadcrumb_last { color: var(--ink); }

.article__head { padding: clamp(40px, 6vw, 64px) 0 clamp(20px, 3vw, 32px); }
.article__title { font-size: clamp(32px, 4.6vw, 54px); line-height: 1.08; letter-spacing: -.035em; margin-bottom: 26px; }
.article__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; font-size: 14px; color: var(--muted); }
.article__meta > span { display: inline-flex; align-items: center; gap: 6px; }
.article__meta .icon { width: 17px; height: 17px; }
.article__author { gap: 10px !important; }
.article__author a { display: block; color: var(--ink); font-weight: 600; text-decoration: none; }
.article__author small { display: block; font-size: 13px; }
.article__avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 2px var(--white), 0 0 0 4px rgba(0, 138, 255, .4); }
.article__cover { margin: 8px 0 clamp(28px, 4vw, 44px); }
.article__cover img { width: 100%; max-width: 640px; margin: 0 auto; border-radius: var(--radius); box-shadow: var(--shadow-lg); }
.article__content { padding: clamp(24px, 4vw, 48px); border-radius: 28px; background: rgba(255, 255, 255, .88); border: 1px solid var(--line-soft); box-shadow: var(--shadow); }

.entry-content { font-size: 18px; line-height: 1.75; color: #333; }
.entry-content > * { margin-top: 0; margin-bottom: 1.1em; }
.entry-content > *:last-child { margin-bottom: 0; }
.entry-content h2 { font-size: clamp(24px, 2.6vw, 30px); margin: 1.8em 0 .6em; }
.entry-content h3 { font-size: clamp(20px, 2.2vw, 24px); margin: 1.6em 0 .5em; }
.entry-content h4 { font-size: 19px; margin: 1.4em 0 .5em; }
.entry-content ul, .entry-content ol { padding-left: 1.4em; }
.entry-content li { margin-bottom: .45em; }
.entry-content ul li::marker { color: var(--blue); }
.entry-content blockquote { margin: 1.6em 0; padding: 20px 24px; border-left: 4px solid var(--blue); background: var(--tint); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.entry-content img { border-radius: var(--radius-sm); }
.entry-content figure { margin: 1.6em 0; }
.entry-content figcaption { font-size: 14px; color: var(--muted); text-align: center; margin-top: 8px; }
.entry-content table { width: 100%; border-collapse: collapse; font-size: 16px; }
.entry-content th, .entry-content td { padding: 10px 12px; border: 1px solid var(--line); }
.entry-content .alignwide, .entry-content .alignfull { margin-left: 0; margin-right: 0; }

.tags { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 28px 0 0; padding: 0; }
.tags li { padding: 6px 12px; border-radius: 999px; background: rgba(255, 255, 255, .8); border: 1px solid var(--line-soft); color: var(--muted); font-size: 13px; }

.author-box { display: flex; gap: 20px; margin-top: 32px; padding: 24px; }
.author-box__photo { width: 80px; height: 80px; border-radius: 50%; object-fit: cover; flex: none; box-shadow: 0 0 0 3px var(--white), 0 0 0 5px rgba(0, 138, 255, .4); }
.author-box p { margin: 0 0 6px; font-size: 15px; }
.author-box__label { font-size: 13px !important; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--blue); }
.author-box__name { font-size: 19px !important; font-weight: 700; color: var(--ink); }
.author-box__note { margin-top: 10px !important; font-size: 13px !important; color: var(--muted); }
@media (max-width: 520px) { .author-box { flex-direction: column; } }

.cta-inline {
	position: relative; overflow: hidden;
	display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
	margin: 24px 0 clamp(48px, 7vw, 80px); padding: 26px 30px; border-radius: var(--radius);
	background: linear-gradient(120deg, #0a7bf0, var(--blue) 35%, #5b6cff 70%, var(--blue-700));
	background-size: 220% 220%; animation: consult-bg 12s ease-in-out infinite alternate;
	color: rgba(255, 255, 255, .9);
}
.cta-inline p { margin: 0; }
.cta-inline__title { color: var(--white); font-size: 20px; font-weight: 700; }
.cta-inline .btn--primary { background: var(--white); color: var(--blue-700); box-shadow: none; }

.pagination { margin-top: 40px; }
.pagination .nav-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.pagination .page-numbers { display: grid; place-items: center; min-width: 44px; height: 44px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--white); color: var(--ink); text-decoration: none; }
.pagination .page-numbers.current { background: var(--blue); border-color: var(--blue); color: var(--white); }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.empty { text-align: center; color: var(--muted); }

/* ---------- Появление при прокрутке (атрибуты и классы ставит main.js) ---------- */
.js [data-anim] { opacity: 0; transition: opacity .9s var(--ease), translate .9s var(--ease), scale .9s var(--ease), filter .9s var(--ease), transform .6s var(--ease), box-shadow .4s; transition-delay: var(--delay, 0s); }
.js [data-anim="fade-up"] { translate: 0 36px; }
.js [data-anim="fade-left"] { translate: 48px 0; }
.js [data-anim="fade-right"] { translate: -48px 0; }
.js [data-anim="zoom"] { scale: .92; filter: blur(6px); }
.js [data-anim].is-visible { opacity: 1; translate: 0 0; scale: 1; filter: none; }
.js [data-anim].is-visible.is-tilting { transition: opacity .9s var(--ease), translate .9s var(--ease), transform .12s linear, box-shadow .4s; transition-delay: 0s; }

.split-word { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 .02em .12em; margin: 0 -.02em -.12em; }
.split-word > span { display: inline-block; translate: 0 110%; transition: translate 1s var(--ease); transition-delay: var(--delay, 0s); }
.split-word.is-visible > span { translate: 0 0; }

/* ---------- Без анимаций для тех, кто их отключил ---------- */
@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
	.js [data-anim], .split-word > span { opacity: 1 !important; translate: none !important; scale: none !important; filter: none !important; }
}
