/* Шрифты лежат на нашем сервере: быстрее, чем с Google, и работают без него */
@font-face{font-family:"Jura";font-style:normal;font-weight:300 700;font-display:swap;src:url(fonts/jura-cyrillic-wght-normal.woff2) format("woff2");unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;}
@font-face{font-family:"Jura";font-style:normal;font-weight:300 700;font-display:swap;src:url(fonts/jura-latin-wght-normal.woff2) format("woff2");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+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;}
@font-face{font-family:"Manrope";font-style:normal;font-weight:200 800;font-display:swap;src:url(fonts/manrope-cyrillic-wght-normal.woff2) format("woff2");unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116;}
@font-face{font-family:"Manrope";font-style:normal;font-weight:200 800;font-display:swap;src:url(fonts/manrope-latin-wght-normal.woff2) format("woff2");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+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;}
:root {
  --bg: #ffffff;
  --ink: #111827;
  --ink-soft: #4b5563;
  --ink-faint: #9ca3af;
  --line: #e5e7eb;
  --violet: #6E57E5;
  --indigo: #3F3A9E;
  --lavender: #C4B5FD;
  --mint: #86E3C3;
  --graphite: #2B2F36;
  --header-h: 72px;
  --cat-w: min(88vw, 50vh, 500px);   /* в 1.5 раза крупнее прежнего */
  --t: 3s;
}

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

html { background: var(--bg); scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

body {
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-weight: 400;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}

a { color: inherit; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.br-m { display: none; }

/* ───────── Кот: оригинальный цветной логотип ───────── */
.brand {
  position: fixed;
  z-index: 60;
  left: 50%;
  top: 50%;
  width: var(--cat-w);
  transform: translate(-50%, -50%);
  mix-blend-mode: multiply;   /* белый фон файла сливается с белой страницей */
  animation: fly 1.5s cubic-bezier(0.65, 0, 0.35, 1) var(--t) forwards;
}

.wob { display: block; transform-origin: 50% 88%; }
.brand.docked:hover .wob, .brand.docked:focus-visible .wob { animation: cat-wobble 1.1s cubic-bezier(0.36, 0.07, 0.19, 0.97) 1; }
.cat {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  transform-origin: 50% 55%;
  opacity: 0;
  animation: fadeIn 1.6s ease 0.1s forwards, pulse 6s ease-in-out 0.1s infinite;
}

/* ───────── Шапка ───────── */
.topbar {
  position: fixed;
  z-index: 50;
  inset: 0 0 auto 0;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(16px, 3vw, 36px) 0 clamp(84px, 9vw, 108px);
  background: rgba(255, 255, 255, 0.82);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
  opacity: 0;
  animation: fadeIn 1s ease calc(var(--t) + 0.6s) forwards;
}

.wordmark { font-family: "Jura", sans-serif; font-weight: 500; font-size: 0.82rem; letter-spacing: 0.3em; }

.nav-link {
  position: relative;
  overflow: hidden;
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: #fff;
  padding: 11px 22px;
  border-radius: 10px;
  background: linear-gradient(120deg, #8672F1 0%, #6E57E5 34%, #6E57E5 66%, #7F6AEE 100%);
  background-size: 220% 100%;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 4px 14px rgba(110, 87, 229, 0.25);
  transition: background-position .7s ease, box-shadow .4s ease, transform .4s ease;
}
.nav-link:hover, .nav-link:focus-visible {
  background-position: 100% 0;
  transform: translateY(-1px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 8px 22px rgba(110, 87, 229, 0.4);
  outline: none;
}

/* ───────── Экран 1 ───────── */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(var(--header-h) + 16px) 24px 96px;
}

.hero-ui {
  width: 100%;
  max-width: 640px;
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 20px;
  opacity: 0;
  transform: translateY(16px);
  filter: blur(8px);
  animation: emerge 1.8s ease calc(var(--t) + 0.3s) forwards;
}

.title {
  font-family: "Jura", "Montserrat", sans-serif;
  font-style: normal;
  font-weight: 500;
  font-size: clamp(1.7rem, 5.2vw, 3.5rem);
  line-height: 1.1;
  letter-spacing: 0.3em;
  padding-left: 0.3em;         /* оптический центр при разреженном трекинге */
  white-space: nowrap;
  color: var(--ink);
}

.subtitle {
  max-width: 29rem;
  font-size: clamp(0.92rem, 2.1vw, 1.02rem);
  font-weight: 300;
  line-height: 1.75;
  color: var(--ink-soft);
}

.auth {
  width: 100%;
  max-width: 400px;
  margin-top: 14px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: left;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.04), 0 16px 40px rgba(17, 24, 39, 0.05);
  transform-origin: 50% 60%;
  transition: box-shadow .8s ease, transform .6s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.auth:hover {
  transform: translateY(-6px);
  box-shadow: 0 2px 4px rgba(17, 24, 39, 0.05), 0 30px 70px rgba(17, 24, 39, 0.14), 0 10px 24px rgba(17, 24, 39, 0.07);
  animation: gentle-wobble 1.4s cubic-bezier(0.37, 0, 0.25, 1) 1 forwards;
}

.auth h2 { font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.05rem; letter-spacing: 0.08em; }
.auth form { display: flex; flex-direction: column; gap: 10px; }

.auth input {
  width: 100%;
  height: 50px;
  padding: 0 16px;
  font: 400 0.95rem "Manrope", sans-serif;
  color: var(--ink);
  background: rgba(17, 24, 39, 0.025);
  border: 1px solid #d1d5db;
  border-radius: 12px;
  outline: none;
  transition: border-color .3s ease, background .3s ease, box-shadow .3s ease;
}
.auth input::placeholder { color: var(--ink-faint); }
.auth input:focus { background: #fff; border-color: var(--violet); box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.14); }

.or { display: flex; align-items: center; gap: 12px; font-size: 0.78rem; letter-spacing: 0.1em; color: var(--ink-faint); }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* ───────── Кнопки ───────── */
.btn {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  padding: 0 28px;
  border: 0;
  border-radius: 12px;
  font: 500 0.95rem "Manrope", sans-serif;
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* лазерный градиент: при наведении оттенок плавно перетекает */
.btn-primary {
  color: #fff;
  background: linear-gradient(120deg, #8672F1 0%, #6E57E5 34%, #6E57E5 66%, #7F6AEE 100%);
  background-size: 220% 100%;
  background-position: 0% 0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.28), 0 6px 18px rgba(110, 87, 229, 0.22);
  transition: background-position .7s ease, box-shadow .4s ease, transform .4s ease;
}
.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 -60%;
  width: 40%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-20deg);
  pointer-events: none;
}
.btn-primary:hover, .btn-primary:focus-visible {
  background-position: 100% 0;
  transform: translateY(-1px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 10px 28px rgba(110, 87, 229, 0.38);
  outline: none;
}
.btn-primary:hover::after, .btn-primary:focus-visible::after { animation: sheen 1s ease forwards; }
.btn-primary:active { transform: scale(0.985); }

.btn-line { color: var(--ink); background: transparent; border: 1px solid #d1d5db; transition: border-color .3s ease, background .3s ease; }
.btn-line:hover { border-color: var(--ink); background: rgba(17, 24, 39, 0.03); }

.btn-disabled { color: var(--ink-faint); background: #f3f4f6; cursor: not-allowed; }

/* ───────── Сакральная геометрия на фоне первого экрана ───────── */
.geo {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0;
  -webkit-mask-image: radial-gradient(ellipse 72% 78% at 50% 50%, #000 30%, transparent 100%);
          mask-image: radial-gradient(ellipse 72% 78% at 50% 50%, #000 30%, transparent 100%);
  animation: fadeIn 2.4s ease var(--t) forwards;
}
.geo svg { width: 100%; height: 100%; display: block; overflow: visible; }
.geo .layer-a { will-change: transform; }
.geo .layer-a { animation: cosmic-drift 28s ease-in-out infinite alternate; }

/* Маленькие матовые элементы: ромбы, оси, астрономические точки */
.fx {
  position: absolute;
  z-index: 0;
  display: block;
  pointer-events: none;
  opacity: 0;
  animation:
    fadeIn 2s ease calc(var(--t) + 0.5s) forwards,
    float-particle var(--d, 12s) ease-in-out var(--dl, 0s) infinite alternate;
}

/* Разноцветные полупрозрачные ромбы (opacity: 0.25) */
.dia, .dia2 {
  --c: var(--violet);
  border: 1.5px solid var(--c);
  background: color-mix(in srgb, var(--c) 22%, transparent);
  transform: rotate(45deg);
  animation:
    fadeInDia 2s ease calc(var(--t) + 0.5s) forwards,
    float-particle var(--d, 12s) ease-in-out var(--dl, 0s) infinite alternate;
}
.dia  { width: 20px; height: 20px; }
.dia2 { width: 34px; height: 34px; }
.dia2::after { content: ""; position: absolute; inset: 7px; border: 1.5px solid var(--c); }
.c-violet { --c: var(--violet); }
.c-indigo { --c: var(--indigo); }
.c-lav    { --c: var(--lavender); }
.c-mint   { --c: var(--mint); }

.dot  { width: 5px; height: 5px; border-radius: 50%; background: rgba(17, 24, 39, 0.4); }
.dot.v { background: rgba(110, 87, 229, 0.75); }
.cross {
  width: 22px; height: 22px;
  background:
    linear-gradient(rgba(17, 24, 39, 0.32), rgba(17, 24, 39, 0.32)) center / 1px 100% no-repeat,
    linear-gradient(rgba(17, 24, 39, 0.32), rgba(17, 24, 39, 0.32)) center / 100% 1px no-repeat;
}
.axis {
  width: 46px; height: 9px;
  border-inline: 1px solid rgba(17, 24, 39, 0.32);
  background: linear-gradient(rgba(17, 24, 39, 0.32), rgba(17, 24, 39, 0.32)) center / 100% 1px no-repeat;
}

/* ───────── Подсказка скролла ───────── */
.scroll-hint {
  position: absolute;
  left: 50%;
  bottom: max(24px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-soft);
  opacity: 0;
  animation: fadeIn 1.2s ease calc(var(--t) + 1.1s) forwards;
}
.scroll-hint svg { width: 24px; height: 24px; animation: bounce 1.6s ease-in-out infinite; }

/* ───────── Экраны экспертов ───────── */
.expert {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  padding: calc(var(--header-h) + 28px) clamp(20px, 5vw, 72px) 56px;
  border-top: 1px solid var(--line);
}

.expert-inner {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: clamp(36px, 6vw, 96px);
}

/* вертикальная прямоугольная карточка, фото без белых полей */
.leonardo-card {
  overflow: hidden;
  width: 100%;
  max-width: 460px;
  justify-self: end;
  aspect-ratio: 4 / 5;
  border: 1px solid var(--graphite);
  border-radius: 16px;
  background: #fff;
  transition: transform .5s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow .5s ease;
}
.leonardo-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .7s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.leonardo-card:hover { transform: translateY(-5px); box-shadow: 0 20px 44px rgba(17, 24, 39, 0.12); }
.leonardo-card:hover img { transform: scale(1.04); }
.leonardo-card { margin: 0; }

.expert-text { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 14px; max-width: 500px; }

.badge {
  padding: 6px 14px;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
  background: var(--c, #f3f4f6);
  border-radius: 8px;
}
.badge-premium { background: #f3f4f6; border: 1px solid var(--ink); letter-spacing: 0.18em; }

.idx { position: absolute; top: 6px; right: 0; font-family: "Jura", sans-serif; font-size: 0.85rem; letter-spacing: 0.2em; color: var(--ink-faint); }

.expert-text h2 { font-family: "Jura", sans-serif; font-weight: 500; font-size: clamp(2rem, 4vw, 2.9rem); line-height: 1.1; letter-spacing: 0.12em; text-transform: uppercase; }
.role { font-size: 1rem; font-weight: 500; letter-spacing: 0.04em; color: var(--violet); }
.lead { font-size: 1.05rem; font-weight: 500; line-height: 1.6; }

.group { padding-top: 14px; border-top: 1px solid var(--line); width: 100%; }
.group h3 { margin-bottom: 6px; font-size: 0.74rem; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink); }
.group p { font-size: 0.94rem; font-weight: 300; line-height: 1.75; color: var(--ink-soft); }

.expert-text .btn { margin-top: 10px; }

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

/* ───────── Анимации ───────── */
@keyframes pulse { 0%, 100% { transform: scale(0.96); } 50% { transform: scale(1.04); } }
@keyframes fly { to { left: clamp(16px, 3vw, 36px); top: 10px; width: 50px; transform: translate(0, 0); } }
@keyframes emerge { to { opacity: 1; transform: translateY(0); filter: blur(0); } }
@keyframes fadeIn { to { opacity: 1; } }
@keyframes sheen { to { left: 130%; } }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(7px); } }
@keyframes rise { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }

@supports (animation-timeline: view()) {
  .expert-text, .leonardo-card { animation: rise linear both; animation-timeline: view(); animation-range: entry 0% entry 40%; }
}

/* ───────── Смартфоны: фото сверху, текст под ним ───────── */
@media (max-width: 820px) {
  :root { --header-h: 64px; --cat-w: min(86vw, 46vh, 460px); }
  .br-m { display: inline; }
  .title { font-size: clamp(2rem, 10vw, 2.8rem); white-space: normal; }
  .wordmark { font-size: 0.72rem; letter-spacing: 0.22em; }
  @keyframes fly { to { left: 16px; top: 7px; width: 44px; transform: translate(0, 0); } }

  .expert { align-items: flex-start; padding: calc(var(--header-h) + 20px) 20px 44px; }
  .expert-inner { grid-template-columns: 1fr; gap: 26px; }
  .leonardo-card { max-width: none; justify-self: stretch; }
  .expert-text { max-width: none; }
  .expert-text .btn { width: 100%; }
}

@media (max-height: 640px) and (min-width: 821px) {
  .hero-ui { gap: 12px; }
  .scroll-hint { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .cat { animation-duration: 0.01s, 12s; }
  .scroll-hint svg { animation: none; }
  .expert-text, .leonardo-card { animation: none; }
}

@keyframes float-particle {
  0%   { translate: 0 0;                                                         rotate: 0deg;                          scale: 1; }
  25%  { translate: calc(var(--dx, 12px) * -0.7) calc(var(--dy, -26px) * 0.6);   rotate: calc(var(--r, 14deg) * -0.8);   scale: 1.12; }
  50%  { translate: var(--dx, 12px) var(--dy, -26px);                            rotate: var(--r, 14deg);               scale: 0.92; }
  75%  { translate: calc(var(--dx, 12px) * -0.5) calc(var(--dy, -26px) * 0.2);   rotate: calc(var(--r, 14deg) * -0.5);   scale: 1.08; }
  100% { translate: calc(var(--dx, 12px) * 0.4) calc(var(--dy, -26px) * -0.8);   rotate: calc(var(--r, 14deg) * 0.3);    scale: 1; }
}
@keyframes cosmic-drift {
  0%   { transform: translate3d(-26px, 14px, 0) scale(1.00); }
  50%  { transform: translate3d(18px, -22px, 0) scale(1.03); }
  100% { transform: translate3d(30px, 16px, 0) scale(1.05); }
}
@keyframes breathe { 0%, 100% { scale: 0.985; } 50% { scale: 1.015; } }
@keyframes cat-wobble {
  0%   { transform: rotate(0deg) scale(1); }
  15%  { transform: rotate(-12deg) scale(1.08); }
  32%  { transform: rotate(9deg) scale(1.08); }
  48%  { transform: rotate(-6deg) scale(1.05); }
  64%  { transform: rotate(4deg) scale(1.03); }
  80%  { transform: rotate(-2deg) scale(1.01); }
  100% { transform: rotate(0deg) scale(1); }
}
@keyframes fadeInDia { to { opacity: 0.25; } }
@keyframes gentle-wobble {
  0%   { transform: translateY(0) rotate(0deg); }
  18%  { transform: translateY(-4px) rotate(-1.1deg); }
  38%  { transform: translateY(-6px) rotate(0.9deg); }
  58%  { transform: translateY(-6px) rotate(-0.55deg); }
  78%  { transform: translateY(-6px) rotate(0.25deg); }
  100% { transform: translateY(-6px) rotate(0deg); }
}

@media (max-width: 820px) {
  .fx:nth-of-type(n+9) { display: none; }
  .fx { transform-origin: center; scale: 0.85; }
}

@media (prefers-reduced-motion: reduce) {
  .fx { animation: none; opacity: 1; }
  .dia, .dia2 { animation: none; opacity: 0.25; }
  .geo .layer-a { animation: none; }
  .auth:hover { animation: none; }
  .brand.docked:hover .wob { animation: none; }
}

/* ───────── «Живая мимика» Майи: слои внутри неподвижной рамки ───────── */
.leonardo-card.mimic:hover { transform: none; box-shadow: none; }   /* рамка статична */
.mimic-stack {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform .7s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.mimic:hover .mimic-stack { transform: scale(1.04); }
.leonardo-card.mimic img, .leonardo-card.mimic:hover img { transform: none; }

.mimic-layer { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity .9s ease; }
.mimic-base  { z-index: 1; opacity: 1; }
.mimic-smile { z-index: 2; opacity: 0; will-change: opacity; }
.mimic-blink { z-index: 3; opacity: 0; will-change: opacity; }

.leonardo-card.mimic .mimic-blink { transition-duration: .08s; }
/* улыбка проявляется плавно и тепло */
.leonardo-card.mimic.is-smile .mimic-smile { opacity: 1; transition-duration: .75s; }
/* моргание: быстрый слой поверх улыбки */
.leonardo-card.mimic.is-blink .mimic-blink { opacity: 1; transition-duration: .06s; }
/* авто-возврат через 2.5 с: медленно и мягко */
.leonardo-card.mimic.is-returning .mimic-smile, .leonardo-card.mimic.is-returning .mimic-blink { transition-duration: 1s; }
/* уход курсора: быстрый мягкий сброс */
.leonardo-card.mimic.is-fast .mimic-smile, .leonardo-card.mimic.is-fast .mimic-blink { transition-duration: .3s; }

@media (prefers-reduced-motion: reduce) {
  .mimic-stack { transition: none; }
  .mimic:hover .mimic-stack { transform: none; }
  .leonardo-card.mimic .mimic-layer { transition-duration: .01s !important; }
}

/* ───────── Слайдер текста Майи ───────── */
.text-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; }

.slider-nav { display: inline-flex; align-items: center; gap: 10px; }
.slider-count { min-width: 3.1em; text-align: center; font-family: "Jura", sans-serif; font-size: 0.85rem; letter-spacing: 0.2em; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.slider-count b { font-weight: 600; color: var(--ink); }

.nav-arrow {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  color: #111827;                              /* графит в покое */
  background: #fff;
  background-image: linear-gradient(120deg, rgba(110, 87, 229, 0.03) 0%, rgba(110, 87, 229, 0.18) 45%, rgba(143, 124, 243, 0.08) 100%);
  background-size: 240% 100%;
  background-position: 0% 0;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: color .45s ease, border-color .45s ease, background-position .8s ease, box-shadow .45s ease, transform .35s ease;
}
.nav-arrow svg { position: relative; z-index: 1; width: 22px; height: 22px; transition: transform .45s cubic-bezier(0.2, 0.7, 0.2, 1); }
.nav-arrow::after {                             /* глянцевый блик */
  content: "";
  position: absolute;
  inset: 0 auto 0 -70%;
  width: 45%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.75), transparent);
  transform: skewX(-20deg);
  pointer-events: none;
}
.nav-arrow:hover, .nav-arrow:focus-visible {
  color: #6E57E5;                               /* фирменный фиолетовый */
  border-color: #6E57E5;
  background-position: 100% 0;
  box-shadow: 0 6px 18px rgba(110, 87, 229, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.7);
  outline: none;
}
.nav-arrow:hover::after, .nav-arrow:focus-visible::after { animation: sheen-nav 1s ease forwards; }
.nav-arrow[data-dir="1"]:hover svg,  .nav-arrow[data-dir="1"]:focus-visible svg  { transform: translateX(3px); }
.nav-arrow[data-dir="-1"]:hover svg, .nav-arrow[data-dir="-1"]:focus-visible svg { transform: translateX(-3px); }
.nav-arrow:active { transform: scale(0.94); }
@keyframes sheen-nav { to { left: 140%; } }

/* все слайды лежат в одной ячейке сетки: высота блока = самый высокий слайд,
   поэтому кнопка «Начать диалог» остаётся на месте при любом переключении */
.slider { display: grid; width: 100%; outline: none; }
.slider:focus-visible { outline: 2px solid rgba(110, 87, 229, 0.35); outline-offset: 6px; border-radius: 12px; }
.slide {
  grid-area: 1 / 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  min-width: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateX(var(--shift, 22px));
  transition: opacity .38s ease, transform .5s cubic-bezier(0.4, 0, 0.2, 1), visibility 0s linear .5s;
}
.slide.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity .55s ease .2s, transform .7s cubic-bezier(0.2, 0.7, 0.2, 1) .2s, visibility 0s;
}
.slide.no-t { transition: none !important; }

.lead-strong { padding-left: 14px; border-left: 3px solid var(--violet); font-weight: 600; line-height: 1.6; }
.slide-title { font-family: "Jura", sans-serif; font-size: 1.25rem; font-weight: 600; letter-spacing: 0.04em; line-height: 1.35; }

.books { list-style: none; display: flex; flex-direction: column; gap: 7px; }
.books li { position: relative; padding-left: 18px; font-size: 0.9rem; font-weight: 300; line-height: 1.55; color: var(--ink-soft); }
.books li::before { content: ""; position: absolute; left: 1px; top: 0.62em; width: 6px; height: 6px; border: 1px solid var(--violet); transform: rotate(45deg); }
.books li b { font-weight: 600; color: var(--ink); }

@media (max-width: 820px) {
  .slider-count { font-size: 0.78rem; letter-spacing: 0.14em; }
  .nav-arrow { width: 42px; height: 42px; }
}
@media (prefers-reduced-motion: reduce) {
  .slide, .slide.is-active { transition-duration: .01s, .01s, 0s; transition-delay: 0s; }
  .nav-arrow, .nav-arrow svg { transition-duration: .01s; }
  .nav-arrow:hover::after, .nav-arrow:focus-visible::after { animation: none; }
}

/* ───────── Волны перед подвалом ───────── */
.footer-waves {
  position: relative;
  height: clamp(120px, 15vw, 190px);
  overflow: hidden;
  background: #fff;
  /* сверху волны растворяются в белом фоне страницы */
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 42%);
          mask-image: linear-gradient(to bottom, transparent 0%, #000 42%);
  pointer-events: none;
}
.wave {
  position: absolute;
  top: 0;
  left: 0;
  width: 200%;                 /* два одинаковых периода: сдвиг на -50% бесшовный */
  height: 100%;
  display: block;
  will-change: transform;
}
.wave-back  { animation: wave-drift 52s linear infinite,          wave-bob 11s ease-in-out infinite alternate; }
.wave-mid   { animation: wave-drift 38s linear infinite reverse,  wave-bob 8.5s ease-in-out -3s infinite alternate; }
.wave-front { animation: wave-drift 66s linear infinite,          wave-bob 13s ease-in-out -6s infinite alternate; }

@keyframes wave-drift { from { transform: translate3d(0, 0, 0); } to { transform: translate3d(-50%, 0, 0); } }
@keyframes wave-bob   { from { translate: 0 -8px; } to { translate: 0 10px; } }

/* ───────── Подвал ───────── */
.footer {
  position: relative;
  overflow: hidden;
  padding: clamp(48px, 7vw, 72px) 20px max(40px, env(safe-area-inset-bottom));
  text-align: center;
  background: #fff;
  border-top: 0;
}
.footer-inner { position: relative; z-index: 1; }
.footer p { font-size: 0.76rem; font-weight: 500; letter-spacing: 0.24em; color: var(--ink-soft); }
.footer small { display: block; margin-top: 14px; font-size: 0.74rem; font-weight: 300; color: var(--ink-faint); }

/* частицы подвала стартуют сразу (без задержки заставки) */
.footer .fx { animation-delay: 0s, var(--dl, 0s); }
.footer .fx.dia, .footer .fx.dia2 { animation-delay: 0s, var(--dl, 0s); }

/* подпись разработчика */
.footer .dev {
  margin-top: 12px;
  font-family: "Jura", sans-serif;
  font-size: 0.78rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  color: #111827;
}
.footer .dev a {
  position: relative;
  color: #111827;
  text-decoration: none;
  font-weight: 500;
  transition: color .45s ease;
}
.footer .dev a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .5s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.footer .dev a:hover, .footer .dev a:focus-visible { color: #6E57E5; outline: none; }
.footer .dev a:hover::after, .footer .dev a:focus-visible::after { transform: scaleX(1); }

@media (max-width: 820px) {
  .footer .fx:nth-of-type(n+7) { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .wave { animation: none; }
}

/* скрытые слайды при переключении сдвигаются на ~22px: не даём им создавать горизонтальную прокрутку */
.expert { overflow-x: clip; }

/* ───────── Юридический блок в подвале ───────── */
.footer .disclaimer {
  max-width: 760px;
  margin: 18px auto 0;
  font-size: 0.72rem;
  font-weight: 400;
  letter-spacing: 0.01em;
  line-height: 1.75;
  color: #6B7280;
  text-align: center;
}
.footer .disclaimer strong { font-weight: 600; color: #6B7280; }

.legal-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 14px;
  margin-top: 16px;
  font-family: "Jura", sans-serif;
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.06em;
}
.legal-links a {
  position: relative;
  color: #4B5563;
  text-decoration: none;
  transition: color .45s ease;
}
.legal-links a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -3px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .5s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.legal-links a:hover, .legal-links a:focus-visible { color: #6E57E5; outline: none; }
.legal-links a:hover::after, .legal-links a:focus-visible::after { transform: scaleX(1); }
.legal-links .sep { color: #D1D5DB; font-weight: 300; }

/* ───────── Модальное окно документов ───────── */
.legal-lock { overflow: hidden; }
.legal-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(14px, 4vw, 40px);
}
.legal-modal[hidden] { display: none; }
.legal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 24, 39, 0.38);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity .38s ease;
}
.legal-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 720px;
  max-height: min(86vh, 760px);
  max-height: min(86dvh, 760px);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 2px 6px rgba(17, 24, 39, 0.06), 0 40px 90px rgba(17, 24, 39, 0.25);
  outline: none;
  opacity: 0;
  transform: translateY(18px) scale(0.97);
  transition: opacity .38s ease, transform .5s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.legal-modal.is-open .legal-backdrop { opacity: 1; }
.legal-modal.is-open .legal-panel { opacity: 1; transform: none; }

.legal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 26px 16px;
  border-bottom: 1px solid var(--line);
}
.legal-head h2 { font-family: "Jura", sans-serif; font-weight: 600; font-size: clamp(1.1rem, 2.6vw, 1.35rem); letter-spacing: 0.06em; }
.legal-x {
  flex: none;
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  color: #111827;
  background: #fff;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  cursor: pointer;
  transition: color .4s ease, border-color .4s ease, background .4s ease;
}
.legal-x svg { width: 18px; height: 18px; }
.legal-x:hover, .legal-x:focus-visible { color: #6E57E5; border-color: #6E57E5; background: rgba(110, 87, 229, 0.06); outline: none; }

.legal-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 20px 26px 8px;
  scrollbar-width: thin;
  scrollbar-color: #d1d5db transparent;
}
.legal-doc[hidden] { display: none; }
.legal-meta { margin-bottom: 14px; font-size: 0.78rem; letter-spacing: 0.08em; color: var(--ink-faint); }
.legal-doc h3 { margin: 18px 0 6px; font-size: 0.78rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink); }
.legal-doc p, .legal-doc li { font-size: 0.92rem; font-weight: 300; line-height: 1.75; color: var(--ink-soft); }
.legal-doc ul { list-style: none; display: flex; flex-direction: column; gap: 5px; margin-top: 4px; }
.legal-doc li { position: relative; padding-left: 18px; }
.legal-doc li::before { content: ""; position: absolute; left: 1px; top: 0.7em; width: 6px; height: 6px; border: 1px solid var(--violet); transform: rotate(45deg); }

.legal-foot {
  display: flex;
  justify-content: flex-end;
  padding: 16px 26px max(22px, env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
}

@media (max-width: 820px) {
  .legal-head { padding: 18px 18px 14px; }
  .legal-body { padding: 16px 18px 6px; }
  .legal-foot { padding: 14px 18px max(18px, env(safe-area-inset-bottom)); }
  .legal-foot .btn { width: 100%; }
  .footer .disclaimer { font-size: 0.7rem; }
}
@media (prefers-reduced-motion: reduce) {
  .legal-backdrop, .legal-panel { transition-duration: .01s; }
  .legal-panel { transform: none; }
}

/* ───────── Тихие парящие ромбы на страницах экспертов ───────── */
.expert { position: relative; }
.expert-inner { position: relative; z-index: 1; }
/* частицы экспертов стартуют сразу, движутся мягче и медленнее, чем на первом экране */
.expert > .fx, .expert > .fx.dia, .expert > .fx.dia2 { animation-delay: 0s, var(--dl, 0s); }
.expert > .fx.dia  { width: 16px; height: 16px; }
.expert > .fx.dia2 { width: 26px; height: 26px; }
.expert > .fx.dia2::after { inset: 5px; }

@media (max-width: 820px) {
  .expert > .fx:nth-of-type(n+3) { display: none; }   /* на телефоне только две частицы, текст важнее */
}

/* на средних и узких экранах поля маленькие: частицы жмутся к самому краю, чтобы не задевать текст и фото */
@media (max-width: 1240px) {
  .expert > .fx:nth-of-type(odd)  { left: 1.2% !important; right: auto !important; }
  .expert > .fx:nth-of-type(even) { right: 1.2% !important; left: auto !important; }
}
@media (max-width: 820px) {
  .expert > .fx:nth-of-type(odd)  { left: 0.5% !important; }
  .expert > .fx:nth-of-type(even) { right: 0.5% !important; }
  .expert > .fx.dia  { width: 12px; height: 12px; }
  .expert > .fx.dia2 { width: 18px; height: 18px; }
  .expert > .fx.dia2::after { inset: 4px; }
}

/* ═════════════════════════════════════════════════════════════
   ЛИЧНЫЙ КАБИНЕТ (dashboard.html): сайдбар + хай-тек чат
   ═════════════════════════════════════════════════════════════ */
.dash { height: 100vh; height: 100dvh; overflow: hidden; background: #fff; }
.dash-noscroll { overflow: hidden; }

.dash-app {
  display: grid;
  grid-template-columns: clamp(300px, 25vw, 400px) minmax(0, 1fr);
  height: 100vh;
  height: 100dvh;
  background: #fff;
}

/* ───────── Левая панель ───────── */
.dash-side {
  position: relative;
  z-index: 5;
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: #fff;
  border-right: 1px solid #E5E7EB;
}
.dash-side-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 18px 20px 14px; }
.dash-brand { display: flex; align-items: center; gap: 12px; min-width: 0; text-decoration: none; color: var(--ink); }
.dash-cat { flex: none; width: 40px; height: 48px; display: block; mix-blend-mode: multiply; }
.dash-wordmark { font-family: "Jura", sans-serif; font-weight: 500; font-size: 0.86rem; letter-spacing: 0.26em; white-space: nowrap; }
.dash-close { display: none; }

.dash-side-label { padding: 6px 22px 10px; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-faint); }

.dash-contacts {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 2px 14px 12px;
  scrollbar-width: thin;
  scrollbar-color: #d1d5db transparent;
}

.dash-contact {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 7px 11px 7px 7px;
  text-align: left;
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 1px solid transparent;
  border-radius: 14px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: border-color .35s ease, background .35s ease, box-shadow .35s ease, transform .35s ease;
}
.dash-contact:hover { background: #FAFAFC; border-color: #E5E7EB; }
.dash-contact:focus-visible { outline: none; border-color: rgba(110, 87, 229, 0.55); }
.dash-contact.is-active {
  background: rgba(110, 87, 229, 0.05);
  border-color: #6E57E5;
  box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.1);
}

.dash-ava {
  flex: none;
  width: 40px;
  height: 50px;
  overflow: hidden;
  border: 1px solid #d1d5db;
  border-radius: 10px;
  background: #fff;
  transition: border-color .35s ease;
}
.dash-ava img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 12%; }
.dash-contact.is-active .dash-ava { border-color: #6E57E5; }

.dash-contact-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.dash-contact-name { font-size: 0.98rem; font-weight: 600; letter-spacing: 0.01em; }
.dash-contact-name .emo { margin-right: 7px; font-size: 0.95rem; }
.dash-contact-role { font-size: 0.75rem; font-weight: 400; line-height: 1.4; color: var(--ink-soft); }

.dash-soon {
  align-self: flex-start;
  margin-top: 3px;
  padding: 2px 8px;
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  background: #F3F4F6;
  border-radius: 6px;
}
.dash-lock { margin-left: auto; flex: none; width: 20px; height: 20px; color: var(--ink-faint); }
.dash-lock svg { display: block; width: 100%; height: 100%; }
.dash-contact.is-locked { cursor: pointer; }
.dash-contact.is-locked .dash-ava img { filter: grayscale(0.85); opacity: 0.55; }
.dash-contact.is-locked .dash-contact-name, .dash-contact.is-locked .dash-contact-role { opacity: 0.6; }
.dash-contact.is-locked:hover { background: #fff; border-color: #E5E7EB; }

.dash-side-bottom { flex: none; display: flex; flex-direction: column; gap: 12px; padding: 14px 18px max(18px, env(safe-area-inset-bottom)); border-top: 1px solid #E5E7EB; background: #fff; }
.dash-limit { padding: 13px 14px; background: #FAFAFC; border: 1px solid #E5E7EB; border-radius: 14px; }
.dash-limit-text { font-size: 0.82rem; line-height: 1.5; color: var(--ink-soft); }
.dash-limit-text b { font-weight: 700; color: var(--ink); }
.dash-limit-bar { height: 5px; margin-top: 10px; overflow: hidden; background: #E5E7EB; border-radius: 99px; }
.dash-limit-bar span { display: block; height: 100%; width: 93%; background: linear-gradient(90deg, #8f7cf3, #6E57E5); border-radius: 99px; transition: width .7s cubic-bezier(0.2, 0.7, 0.2, 1); }
.dash-limit.is-low .dash-limit-bar span { background: linear-gradient(90deg, #f59e8b, #e5654d); }
.dash-upgrade { width: 100%; min-height: 50px; padding: 0 18px; }

.dash-overlay { display: none; }

/* ───────── Окно чата ───────── */
.dash-chat { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: #fff; }

.dash-head {
  flex: none;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px clamp(18px, 3vw, 40px);
  background: rgba(255, 255, 255, 0.92);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid #E5E7EB;
}
.dash-burger { display: none; }
.dash-head-title { flex: 1 1 auto; min-width: 0; }
.dash-head-title h1 { font-family: "Jura", sans-serif; font-weight: 500; font-size: clamp(1.5rem, 2.6vw, 2.1rem); line-height: 1.1; letter-spacing: 0.16em; text-transform: uppercase; }
.dash-head-sub { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-top: 6px; font-size: 0.84rem; color: var(--ink-soft); }
.dash-dot { width: 8px; height: 8px; border-radius: 50%; background: #2FBF8F; box-shadow: 0 0 0 3px rgba(47, 191, 143, 0.18); }
.dash-sep { color: var(--ink-faint); }
.dash-online { font-weight: 500; color: #1f9d75; }

.dash-head-actions { flex: none; display: flex; align-items: center; gap: 10px; }
.dash-tool {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 0 16px;
  font: 500 0.84rem "Manrope", sans-serif;
  letter-spacing: 0.02em;
  color: #111827;
  background: #fff;
  border: 1px solid #d1d5db;
  border-radius: 12px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: color .35s ease, border-color .35s ease, background .35s ease, box-shadow .35s ease;
}
.dash-tool:hover, .dash-tool:focus-visible { color: #6E57E5; border-color: #6E57E5; background: rgba(110, 87, 229, 0.05); outline: none; }
.dash-sos { border-color: #111827; }

/* ───────── Переписка ───────── */
.dash-feed { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 28px clamp(16px, 3vw, 40px) 12px; scrollbar-width: thin; scrollbar-color: #d1d5db transparent; background: #fff; }
.dash-feed-inner { display: flex; flex-direction: column; gap: 22px; width: 100%; max-width: 860px; margin: 0 auto; }
.dash-feed-inner.is-swap { animation: dash-fade .5s ease both; }

.dash-msg { display: flex; align-items: flex-end; gap: 12px; animation: dash-in .5s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.dash-msg-wrap { display: flex; flex-direction: column; gap: 6px; max-width: min(78%, 640px); min-width: 0; }
.dash-msg time { font-size: 0.7rem; letter-spacing: 0.06em; color: var(--ink-faint); }
.dash-msg.is-user { justify-content: flex-end; }
.dash-msg.is-user .dash-msg-wrap { align-items: flex-end; }

.dash-bubble { display: flex; flex-direction: column; gap: 12px; padding: 15px 19px; font-size: 0.96rem; line-height: 1.7; overflow-wrap: anywhere; }
.dash-bubble p { margin: 0; }
.dash-msg.is-user .dash-bubble { color: #fff; background: #6E57E5; border-radius: 20px 20px 6px 20px; box-shadow: 0 8px 22px rgba(110, 87, 229, 0.22); }
.dash-msg.is-ai .dash-bubble { color: #111827; background: #F9F9FB; border: 1px solid #F0F1F5; border-radius: 20px 20px 20px 6px; }

.dash-ava-s { flex: none; align-self: flex-start; width: 34px; height: 42px; overflow: hidden; border: 1px solid #d1d5db; border-radius: 9px; background: #fff; }
.dash-ava-s img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 12%; }

.dash-sys { align-self: center; padding: 5px 14px; font-size: 0.74rem; letter-spacing: 0.1em; color: var(--ink-soft); background: #F3F4F6; border-radius: 99px; animation: dash-in .4s ease both; }

.dash-dots { flex-direction: row; align-items: center; gap: 6px; padding: 17px 20px; }
.dash-dots i { width: 7px; height: 7px; border-radius: 50%; background: #6E57E5; opacity: 0.35; animation: dash-dot 1.1s ease-in-out infinite; }
.dash-dots i:nth-child(2) { animation-delay: .15s; }
.dash-dots i:nth-child(3) { animation-delay: .3s; }

/* ───────── Панель ввода ───────── */
.dash-input { flex: none; padding: 10px clamp(16px, 3vw, 40px) max(18px, env(safe-area-inset-bottom)); background: #fff; }
.dash-input-wrap { position: relative; width: 100%; max-width: 860px; margin: 0 auto; }
.dash-input textarea {
  display: block;
  width: 100%;
  min-height: 62px;
  max-height: 180px;
  padding: 19px 74px 19px 22px;
  font: 400 0.97rem/1.55 "Manrope", sans-serif;
  color: var(--ink);
  background: #fff;
  border: 1px solid #d1d5db;
  border-radius: 20px;
  outline: none;
  resize: none;
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.04), 0 14px 34px rgba(17, 24, 39, 0.05);
  transition: border-color .3s ease, box-shadow .3s ease;
}
.dash-input textarea::placeholder { color: var(--ink-faint); }
.dash-input textarea:focus { border-color: #6E57E5; box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.14), 0 14px 34px rgba(17, 24, 39, 0.05); }
.dash-input textarea:disabled { background: #FAFAFC; cursor: not-allowed; }

.dash-send {
  position: absolute;
  right: 10px;
  bottom: 9px;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: linear-gradient(120deg, #8F7CF3 0%, #6E57E5 45%, #6E57E5 100%);
  border: 0;
  border-radius: 14px;
  cursor: pointer;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 6px 16px rgba(110, 87, 229, 0.3);
  -webkit-tap-highlight-color: transparent;
  transition: transform .35s ease, box-shadow .35s ease, opacity .3s ease, background .3s ease;
}
.dash-send svg { width: 22px; height: 22px; transition: transform .4s cubic-bezier(0.2, 0.7, 0.2, 1); }
.dash-send:hover:not(:disabled), .dash-send:focus-visible:not(:disabled) { transform: translateY(-1px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 10px 24px rgba(110, 87, 229, 0.4); outline: none; }
.dash-send:hover:not(:disabled) svg { transform: translateX(3px); }
.dash-send:active:not(:disabled) { transform: scale(0.94); }
.dash-send:disabled { cursor: not-allowed; background: #E5E7EB; box-shadow: none; color: #9ca3af; }

.dash-note { max-width: 860px; margin: 10px auto 0; text-align: center; font-size: 0.72rem; line-height: 1.6; color: var(--ink-faint); }
.dash-note a { color: var(--ink-soft); text-decoration: none; font-weight: 600; transition: color .3s ease; }
.dash-note a:hover { color: #6E57E5; }

/* ───────── Всплывающее окно и уведомление ───────── */
.dash-modal { position: fixed; inset: 0; z-index: 200; display: flex; align-items: center; justify-content: center; padding: 20px; }
.dash-modal[hidden] { display: none; }
.dash-modal-backdrop { position: absolute; inset: 0; background: rgba(17, 24, 39, 0.38); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); opacity: 0; transition: opacity .32s ease; }
.dash-modal-panel {
  position: relative;
  width: 100%;
  max-width: 460px;
  padding: 28px;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 16px;
  box-shadow: 0 2px 6px rgba(17, 24, 39, 0.06), 0 40px 90px rgba(17, 24, 39, 0.25);
  outline: none;
  opacity: 0;
  transform: translateY(16px) scale(0.97);
  transition: opacity .32s ease, transform .45s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.dash-modal.is-open .dash-modal-backdrop { opacity: 1; }
.dash-modal.is-open .dash-modal-panel { opacity: 1; transform: none; }
.dash-modal-panel h2 { margin-bottom: 12px; font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.3rem; letter-spacing: 0.06em; }
.dash-modal-body { display: flex; flex-direction: column; gap: 10px; }
.dash-modal-body p { font-size: 0.92rem; font-weight: 300; line-height: 1.7; color: var(--ink-soft); }
.dash-modal-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; margin-top: 22px; }

.dash-toast {
  position: fixed;
  left: 50%;
  bottom: max(26px, env(safe-area-inset-bottom));
  z-index: 300;
  max-width: calc(100vw - 32px);
  padding: 12px 20px;
  font-size: 0.86rem;
  color: #fff;
  background: #111827;
  border-radius: 12px;
  box-shadow: 0 14px 36px rgba(17, 24, 39, 0.3);
  opacity: 0;
  transform: translate(-50%, 14px);
  pointer-events: none;
  transition: opacity .35s ease, transform .45s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.dash-toast.is-on { opacity: 1; transform: translate(-50%, 0); }

@keyframes dash-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes dash-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes dash-dot { 0%, 100% { opacity: 0.3; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-3px); } }

/* ───────── Смартфоны и планшеты: сайдбар прячется в гамбургер ───────── */
@media (max-width: 820px) {
  .dash-app { grid-template-columns: minmax(0, 1fr); }

  .dash-side {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 90;
    width: min(86vw, 340px);
    box-shadow: 0 0 60px rgba(17, 24, 39, 0.18);
    transform: translateX(-104%);
    visibility: hidden;
    transition: transform .5s cubic-bezier(0.2, 0.7, 0.2, 1), visibility 0s linear .5s;
  }
  .menu-open .dash-side { transform: none; visibility: visible; transition: transform .5s cubic-bezier(0.2, 0.7, 0.2, 1), visibility 0s; }

  .dash-overlay { display: block; position: fixed; inset: 0; z-index: 80; background: rgba(17, 24, 39, 0.38); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); opacity: 0; pointer-events: none; transition: opacity .4s ease; }
  .dash-overlay.is-on { opacity: 1; pointer-events: auto; }

  .dash-close, .dash-burger {
    display: inline-flex; align-items: center; justify-content: center;
    flex: none; width: 42px; height: 42px; padding: 0;
    color: #111827; background: #fff; border: 1px solid #d1d5db; border-radius: 12px; cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: color .3s ease, border-color .3s ease, background .3s ease;
  }
  .dash-close svg, .dash-burger svg { width: 20px; height: 20px; }
  .dash-close:hover, .dash-burger:hover, .dash-burger:focus-visible, .dash-close:focus-visible { color: #6E57E5; border-color: #6E57E5; background: rgba(110, 87, 229, 0.05); outline: none; }

  .dash-head { gap: 12px; padding: 12px 14px; padding-top: max(12px, env(safe-area-inset-top)); }
  .dash-head-title h1 { font-size: 1.35rem; letter-spacing: 0.12em; }
  .dash-head-sub { flex-wrap: nowrap; align-items: flex-start; gap: 7px; font-size: 0.74rem; line-height: 1.4; margin-top: 4px; }
  .dash-head-sub .dash-dot { flex: none; margin-top: 4px; }
  .dash-head-sub .dash-sep, .dash-head-sub .dash-online { display: none; }
  .dash-head-actions { gap: 8px; }
  .dash-tool { width: 42px; padding: 0; justify-content: center; }
  .dash-tool .t { display: none; }

  .dash-feed { padding: 18px 14px 8px; }
  .dash-feed-inner { gap: 18px; }
  .dash-msg-wrap { max-width: 88%; }
  .dash-ava-s { width: 28px; height: 36px; border-radius: 8px; }
  .dash-bubble { padding: 13px 16px; font-size: 0.94rem; }

  .dash-input { padding: 8px 12px max(14px, env(safe-area-inset-bottom)); }
  .dash-input textarea { min-height: 74px; padding: 15px 66px 15px 18px; font-size: 16px; border-radius: 18px; }   /* 16px: iOS не приближает экран при вводе */
  .dash-input textarea::placeholder { font-size: 13.5px; line-height: 1.5; }
  .dash-send { right: 8px; bottom: 8px; width: 44px; height: 44px; }
  .dash-note { font-size: 0.68rem; }

  .dash-modal-panel { padding: 22px; }
  .dash-modal-actions .btn { flex: 1 1 100%; }
}

@media (prefers-reduced-motion: reduce) {
  .dash-msg, .dash-sys, .dash-feed-inner.is-swap { animation: none; }
  .dash-dots i { animation: none; opacity: 0.7; }
  .dash-side, .dash-overlay, .dash-modal-backdrop, .dash-modal-panel, .dash-toast, .dash-limit-bar span { transition-duration: .01s; }
}

/* состояния: собеседник «в разработке» (чат заблокирован) */
.dash-contact.is-locked.is-active, .dash-contact.is-locked.is-active:hover { background: rgba(110, 87, 229, 0.05); border-color: #6E57E5; }
.dash-head.is-soon .dash-dot { background: #9ca3af; box-shadow: 0 0 0 3px rgba(156, 163, 175, 0.22); }
.dash-head.is-soon .dash-online { color: var(--ink-soft); }
.dash-tool:disabled { opacity: 0.45; cursor: not-allowed; pointer-events: none; }

/* ═════════════════════════════════════════════════════════════
   ВНУТРЕННИЕ СТРАНИЦЫ: навигация, профиль (profile.html), подписки (billing.html)
   ═════════════════════════════════════════════════════════════ */

/* ссылки-собеседники в сайдбаре (на страницах профиля и подписок) */
a.dash-contact { text-decoration: none; color: inherit; }

/* навигация по разделам кабинета */
.dash-nav { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 0 14px 14px; }
.dash-nav-link {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  min-height: 40px; padding: 0 6px;
  font-size: 0.8rem; font-weight: 500; letter-spacing: 0.01em;
  text-decoration: none; color: var(--ink);
  background: #fff; border: 1px solid #E5E7EB; border-radius: 12px;
  -webkit-tap-highlight-color: transparent;
  transition: color .35s ease, border-color .35s ease, background .35s ease, box-shadow .35s ease;
}
.dash-nav-link svg { flex: none; width: 17px; height: 17px; }
.dash-nav-link:hover, .dash-nav-link:focus-visible { color: #6E57E5; border-color: #6E57E5; outline: none; }
.dash-nav-link[aria-current="page"] { color: #6E57E5; border-color: #6E57E5; background: rgba(110, 87, 229, 0.06); box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.08); }
a.dash-upgrade { text-decoration: none; }

/* общий каркас страницы */
.pg-inner { width: 100%; max-width: 860px; margin: 0 auto; padding-bottom: 8px; }
.pg-inner.pg-wide { max-width: 1080px; }
.pg-foot { margin-top: 36px; padding: 22px 0 max(8px, env(safe-area-inset-bottom)); text-align: center; border-top: 1px solid #E5E7EB; font-size: 0.74rem; font-weight: 500; letter-spacing: 0.24em; color: var(--ink-soft); }

/* ───────── Профиль ───────── */
.pf-form { display: flex; flex-direction: column; gap: 20px; }
.pf-disclaimer {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 16px 18px;
  font-size: 0.92rem; line-height: 1.65; color: var(--ink);
  background: rgba(110, 87, 229, 0.05);
  border: 1px solid rgba(110, 87, 229, 0.28);
  border-radius: 16px;
}
.pf-disclaimer svg { flex: none; width: 22px; height: 22px; margin-top: 2px; color: #6E57E5; }

.pf-card { display: flex; flex-direction: column; gap: 22px; padding: clamp(18px, 3vw, 30px); background: #fff; border: 1px solid #E5E7EB; border-radius: 16px; box-shadow: 0 1px 2px rgba(17, 24, 39, 0.03), 0 16px 40px rgba(17, 24, 39, 0.04); }
.pf-field { display: flex; flex-direction: column; gap: 8px; min-width: 0; margin: 0; padding: 0; border: 0; }
.pf-field label, .pf-fieldset legend { padding: 0; font-size: 0.74rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink); }
.pf-field input[type="text"], .pf-field input[type="number"] {
  width: 100%; height: 52px; padding: 0 16px;
  font: normal 400 0.98rem "Manrope", sans-serif; font-style: normal;
  color: var(--ink); background: #fff;
  border: 1px solid #2B2F36; border-radius: 12px; outline: none;
  -moz-appearance: textfield; appearance: none;
  transition: border-color .3s ease, box-shadow .3s ease;
}
.pf-field input::-webkit-outer-spin-button, .pf-field input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.pf-field input::placeholder { font-style: normal; color: var(--ink-faint); }
.pf-field input:focus { border-color: #6E57E5; box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.14); }
.pf-field input[aria-invalid="true"] { border-color: #e5654d; box-shadow: 0 0 0 3px rgba(229, 101, 77, 0.12); }
.pf-hint { font-size: 0.8rem; line-height: 1.55; color: var(--ink-soft); }
.pf-error { font-size: 0.82rem; font-weight: 500; color: #d24a32; }
.pf-error[hidden] { display: none; }

/* Пол: строгий сегментированный выбор */
.pf-seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.pf-seg label { position: relative; display: block; margin: 0; letter-spacing: normal; text-transform: none; font-weight: 500; }
.pf-seg input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.pf-seg span { display: flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 10px; font-size: 0.92rem; text-align: center; color: var(--ink); background: #fff; border: 1px solid #2B2F36; border-radius: 12px; transition: color .3s ease, border-color .3s ease, background .3s ease, box-shadow .3s ease; }
.pf-seg label:hover span { border-color: #6E57E5; color: #6E57E5; }
.pf-seg input:checked + span { color: #6E57E5; border-color: #6E57E5; background: rgba(110, 87, 229, 0.07); box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.12); font-weight: 600; }
.pf-seg input:focus-visible + span { box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.3); }

/* Аватар */
.pf-av-head { display: flex; align-items: center; gap: 18px; }
.pf-av-head h2 { margin-bottom: 4px; font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.15rem; letter-spacing: 0.08em; text-transform: uppercase; }
.pf-av-head p { font-size: 0.86rem; line-height: 1.6; color: var(--ink-soft); }
.pf-av-preview, .pf-av-tile {
  --c: #6E57E5; --bg: #F1EEFD;
  position: relative; display: flex; align-items: center; justify-content: center;
  color: var(--c); background: var(--bg); border: 1px solid #2B2F36; border-radius: 16px;
}
.pf-av-preview { flex: none; width: 92px; height: 92px; box-shadow: 0 10px 26px rgba(17, 24, 39, 0.08); }
.pf-av-preview svg { width: 62%; height: 62%; }

.pf-avatars { display: grid; grid-template-columns: repeat(7, 1fr); gap: 12px; margin: 0; padding: 0; border: 0; min-width: 0; }
.pf-av { position: relative; display: block; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.pf-av input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.pf-av-tile { width: 100%; aspect-ratio: 1; border-color: #D1D5DB; transition: transform .4s cubic-bezier(0.2, 0.7, 0.2, 1), border-color .3s ease, box-shadow .4s ease; }
.pf-av-tile > svg { width: 58%; height: 58%; transition: transform .5s cubic-bezier(0.2, 0.7, 0.2, 1); }
.pf-av:hover .pf-av-tile { transform: translateY(-3px); border-color: var(--c); box-shadow: 0 12px 26px rgba(17, 24, 39, 0.1); }
.pf-av:hover .pf-av-tile > svg { transform: scale(1.08) rotate(-3deg); }
.pf-av input:checked + .pf-av-tile { border-color: #6E57E5; box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.22), 0 12px 26px rgba(110, 87, 229, 0.18); }
.pf-av input:focus-visible + .pf-av-tile { box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.4); }
.pf-check { position: absolute; top: -7px; right: -7px; display: flex; align-items: center; justify-content: center; width: 22px; height: 22px; color: #fff; background: #6E57E5; border: 2px solid #fff; border-radius: 50%; opacity: 0; transform: scale(0.5); transition: opacity .25s ease, transform .35s cubic-bezier(0.2, 0.9, 0.3, 1.4); }
.pf-check svg { width: 12px; height: 12px; }
.pf-av input:checked + .pf-av-tile .pf-check { opacity: 1; transform: scale(1); }

.pf-actions { display: flex; justify-content: flex-end; }
#pfSave { min-width: 240px; }
#pfSave.is-done { background: #2FA383; background-image: none; box-shadow: 0 6px 18px rgba(47, 163, 131, 0.3); }

/* ───────── Подписки ───────── */
.bl-toggle {
  position: relative;
  display: grid; grid-template-columns: 1fr 1fr;
  width: 100%; max-width: 860px; margin: 0 auto;
  padding: 5px;
  background: #F9F9FB; border: 1px solid #E5E7EB; border-radius: 16px;
}
.bl-thumb {
  position: absolute; top: 5px; bottom: 5px; left: 5px;
  width: calc(50% - 5px);
  background: #fff; border: 1px solid #6E57E5; border-radius: 12px;
  box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.1), 0 10px 24px rgba(110, 87, 229, 0.16);
  transition: transform .55s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.bl-toggle[data-pkg="ultra"] .bl-thumb { transform: translateX(100%); }
.bl-opt {
  position: relative; z-index: 1;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 60px; padding: 14px 14px 8px;
  font: 500 0.88rem/1.35 "Manrope", sans-serif; text-align: center;
  color: var(--ink-soft); background: transparent; border: 0; border-radius: 12px; cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: color .4s ease;
}
.bl-opt:hover { color: var(--ink); }
.bl-opt.is-on { color: #6E57E5; font-weight: 600; }
.bl-opt:focus-visible { outline: 2px solid rgba(110, 87, 229, 0.45); outline-offset: 2px; }
.bl-up { position: absolute; top: 6px; right: 8px; padding: 2px 7px; font-size: 0.64rem; font-weight: 700; letter-spacing: 0.06em; color: #6E57E5; background: rgba(110, 87, 229, 0.1); border-radius: 99px; }
.bl-toggle-note { margin: 10px 0 26px; text-align: center; font-size: 0.8rem; color: var(--ink-faint); }

.bl-stage { display: grid; }
.bl-stage > * { grid-area: 1 / 1; }
.bl-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; opacity: 0.7; }

.bl-card {
  position: relative;
  display: flex; flex-direction: column; gap: 14px;
  min-height: 565px;
  padding: 30px 20px 22px;
  background: #fff; border: 1px solid #2B2F36; border-radius: 16px;
}
.bl-term { font-size: 0.74rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink); }
.bl-price { display: flex; align-items: baseline; gap: 6px; margin-top: 4px; font-family: "Jura", sans-serif; font-weight: 600; color: var(--ink); }
.bl-num { font-size: clamp(2rem, 3.2vw, 2.7rem); line-height: 1; font-variant-numeric: tabular-nums; letter-spacing: 0.01em; transition: color .3s ease; }
.bl-num.is-rolling { color: #6E57E5; }
.bl-cur { font-size: 1.2rem; color: var(--ink-soft); }
.bl-limit { font-size: 0.84rem; line-height: 1.55; color: var(--ink-soft); }
.bl-limit-text { display: inline-block; transition: opacity .16s ease, transform .16s ease; }
.bl-limit-text.is-swap { opacity: 0; transform: translateY(4px); }
.bl-plus { color: #6E57E5; font-weight: 600; }
.bl-btn { width: 100%; margin-top: auto; min-height: 48px; padding: 0 12px; font-size: 0.86rem; }
.bl-btn:disabled { cursor: not-allowed; }

.bl-badge { position: absolute; top: -12px; left: 50%; transform: translateX(-50%); width: max-content; max-width: calc(100% - 12px); padding: 5px 12px; text-align: center; line-height: 1.25; font-size: 0.66rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: #3F3A9E; background: #ECEBF7; border: 1px solid rgba(110, 87, 229, 0.35); border-radius: 99px; }
.bl-badge.is-max { color: #fff; background: linear-gradient(110deg, #8F7CF3, #6E57E5 40%, #5A43D6 70%, #8F7CF3); background-size: 220% 100%; border-color: transparent; box-shadow: 0 6px 18px rgba(110, 87, 229, 0.4); animation: bl-shine 3.4s linear infinite; }
.bl-card.is-best { border-color: #6E57E5; box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.1); }
@keyframes bl-shine { to { background-position: -220% 0; } }

/* плашка заморозки поверх карточек */
.bl-freeze { z-index: 2; display: flex; align-items: flex-end; justify-content: center; padding: 0 14px 16px; pointer-events: none; }
.bl-manifest {
  position: relative; width: 100%; max-width: 100%; padding: clamp(22px, 3vw, 32px);
  text-align: center;
  background: rgba(255, 255, 255, 0.86);
  -webkit-backdrop-filter: blur(9px); backdrop-filter: blur(9px);
  border: 1px solid #E5E7EB; border-radius: 16px;
  box-shadow: 0 2px 6px rgba(17, 24, 39, 0.05), 0 30px 70px rgba(17, 24, 39, 0.14);
}
.bl-manifest::before { content: ""; position: absolute; top: 0; left: 24px; right: 24px; height: 2px; background: linear-gradient(90deg, transparent, #6E57E5, transparent); border-radius: 2px; }
.bl-snow { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; margin-bottom: 12px; color: #6E57E5; background: rgba(110, 87, 229, 0.08); border-radius: 12px; }
.bl-snow svg { width: 24px; height: 24px; }
.bl-manifest h2 { margin-bottom: 14px; font-family: "Jura", sans-serif; font-weight: 600; font-size: clamp(1.05rem, 2.3vw, 1.5rem); line-height: 1.3; letter-spacing: 0.1em; color: #6E57E5; }
.bl-manifest p { font-size: clamp(0.88rem, 1.6vw, 0.97rem); line-height: 1.75; color: var(--ink); }

@media (max-width: 1100px) {
  .bl-grid { grid-template-columns: repeat(2, 1fr); gap: 18px 14px; }
}
@media (max-width: 820px) {
  .pf-avatars { grid-template-columns: repeat(5, 1fr); gap: 10px; }
  .pf-av-head { align-items: flex-start; }
  .pf-av-preview { width: 76px; height: 76px; }
  .pf-seg span { min-height: 48px; font-size: 0.86rem; }
  #pfSave { width: 100%; }

  .bl-toggle { grid-template-columns: 1fr; }
  .bl-thumb { width: calc(100% - 10px); height: calc(50% - 5px); bottom: auto; }
  .bl-toggle[data-pkg="ultra"] .bl-thumb { transform: translateY(100%); }
  .bl-opt { min-height: 54px; padding: 10px 14px; font-size: 0.86rem; }
  .bl-up { position: static; flex: none; }

  .bl-stage { display: flex; flex-direction: column; gap: 18px; }
  .bl-freeze { order: -1; padding: 0; }
  .bl-card { min-height: 0; padding: 26px 14px 16px; gap: 10px; }
  .bl-term { font-size: 0.66rem; letter-spacing: 0.08em; }
  .bl-btn { min-height: 44px; font-size: 0.78rem; }
}
@media (max-width: 420px) {
  .pf-avatars { gap: 8px; }
  .pf-seg { gap: 6px; }
  .pf-seg span { font-size: 0.8rem; padding: 0 6px; }
  .bl-grid { gap: 20px 10px; }
  .bl-card { padding: 24px 12px 14px; }
  .bl-num { font-size: 1.7rem; }
}
@media (prefers-reduced-motion: reduce) {
  .bl-badge.is-max { animation: none; }
  .bl-thumb, .pf-av-tile, .pf-av-tile > svg, .pf-check { transition-duration: .01s; }
}

/* ───────── Меню справа от «Начать» ───────── */
.topbar-right { display: flex; align-items: center; gap: clamp(14px, 2.4vw, 32px); }
.topnav { display: flex; align-items: center; gap: clamp(14px, 2vw, 28px); }
.topnav a { text-decoration: none; font-size: 0.84rem; font-weight: 500; letter-spacing: 0.02em; color: var(--ink-soft, #4B5563); padding: 6px 0; border-bottom: 1px solid transparent; transition: color .3s ease, border-color .3s ease; white-space: nowrap; }
.topnav a:hover, .topnav a:focus-visible, .topnav a[aria-current="page"] { color: #6E57E5; border-bottom-color: #6E57E5; outline: none; }
.topnav-burger { display: none; width: 40px; height: 40px; padding: 8px; color: #111827; background: #fff; border: 1px solid #E5E7EB; border-radius: 10px; cursor: pointer; }
.topnav-burger svg { width: 100%; height: 100%; display: block; }
@media (max-width: 1180px) {
  .topbar-right { position: relative; flex-direction: row; gap: 10px; }
  .topnav-burger { display: block; }
  .topnav { position: absolute; top: calc(100% + 12px); right: 0; flex-direction: column; align-items: stretch; gap: 0; min-width: 220px; padding: 8px; background: #fff; border: 1px solid #E5E7EB; border-radius: 16px; box-shadow: 0 16px 40px rgba(17,24,39,.12); opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .25s ease, transform .25s ease, visibility .25s; }
  .topnav.is-open { opacity: 1; visibility: visible; transform: none; }
  .topnav a { padding: 12px 14px; border: 0; border-radius: 10px; }
  .topnav a:hover, .topnav a[aria-current="page"] { background: #F1EEFD; }
}

/* ───────── Чат: имя и аватар пользователя ───────── */
.dash-ava-u { flex: none; align-self: flex-start; display: grid; place-items: center; width: 34px; height: 34px; padding: 5px; border: 1px solid #E5E7EB; border-radius: 10px; }
.dash-ava-u svg { width: 100%; height: 100%; display: block; }
.dash-uname { font-size: 0.74rem; font-weight: 600; letter-spacing: 0.04em; color: var(--ink-soft, #4B5563); }
@media (max-width: 640px) { .dash-ava-u { width: 28px; height: 28px; padding: 4px; border-radius: 8px; } }

/* ───────── Публичные страницы (без меню чата) ───────── */
body.pub { min-height: 100vh; background: #fff; color: #111827; overflow-y: auto; }
.pub-head { position: sticky; top: 0; z-index: 40; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px clamp(16px, 3vw, 36px); background: rgba(255,255,255,.88); -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); border-bottom: 1px solid #E5E7EB; }
.pub-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: inherit; }
.pub-main { padding: clamp(28px, 5vw, 56px) clamp(16px, 3vw, 36px) 40px; }
.pub-title-wrap { max-width: 1080px; margin: 0 auto 28px; }
.pub-title { margin: 0; font-family: "Jura", sans-serif; font-weight: 500; font-size: clamp(1.8rem, 4vw, 2.6rem); letter-spacing: .04em; }
.pub-sub { margin: 8px 0 0; color: #4B5563; }
.faq-list { display: grid; gap: 12px; max-width: 860px; }
.faq-item { border: 1px solid #E5E7EB; border-radius: 16px; padding: 16px 20px; background: #fff; }
.faq-item summary { cursor: pointer; font-weight: 600; }
.faq-item p { margin: 12px 0 0; line-height: 1.7; color: #4B5563; }
.mat-soon { max-width: 860px; padding: 28px; border: 1px solid #E5E7EB; border-radius: 16px; }
.mat-soon a { color: #6E57E5; }

/* «Начать» — крайняя справа, после пунктов меню */
.topbar-right .nav-link { order: 3; }
.topbar-right .topnav { order: 1; }
.topbar-right .topnav-burger { order: 2; }

/* Аватар пользователя в чате — крупнее и контрастнее */
.dash-ava-u { width: 50px; height: 50px; padding: 7px; border: 1px solid rgba(110, 87, 229, 0.28); border-radius: 14px; }
.dash-uname { font-size: 0.8rem; color: #374151; }
@media (max-width: 640px) { .dash-ava-u { width: 40px; height: 40px; padding: 5px; border-radius: 11px; } }

/* Плавающие цветные ромбы на публичных страницах */
.pub-fx { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.pub-head, .pub-main { position: relative; z-index: 1; }
.pub-head { position: sticky; }
@media (max-width: 640px) { .pub-fx .fx:nth-of-type(n+7) { display: none; } }

/* ───────── Страница «Правила платформы» ───────── */
.rules-list { display: grid; gap: 20px; max-width: 860px; }
.rule-card {
  padding: clamp(22px, 3.2vw, 36px);
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid #E5E7EB;
  border-radius: 16px;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.9) inset, 0 10px 30px rgba(17, 24, 39, 0.04);
  font-style: normal;
  transition: border-color .4s ease, box-shadow .4s ease, transform .4s ease;
}
.rule-card:hover { border-color: rgba(110, 87, 229, 0.45); box-shadow: 0 14px 38px rgba(110, 87, 229, 0.1); transform: translateY(-2px); }
.rule-title {
  margin: 0 0 16px;
  padding-left: 16px;
  border-left: 3px solid #6E57E5;
  font-family: "Jura", sans-serif;
  font-weight: 600;
  font-style: normal;
  font-size: clamp(1.15rem, 2.4vw, 1.55rem);
  line-height: 1.3;
  letter-spacing: 0.04em;
  color: #1F2937;
}
.rule-text { margin: 0; font-style: normal; font-size: 1.02rem; line-height: 1.85; color: #374151; }
.rule-text a { color: #6E57E5; font-weight: 600; text-decoration: none; border-bottom: 1px solid rgba(110, 87, 229, 0.4); transition: border-color .3s ease; }
.rule-text a:hover, .rule-text a:focus-visible { border-bottom-color: #6E57E5; outline: none; }
@media (max-width: 640px) { .rules-list { gap: 14px; } .rule-text { font-size: 0.98rem; line-height: 1.75; } }
@media (prefers-reduced-motion: reduce) { .rule-card { transition: none; } .rule-card:hover { transform: none; } }

/* Выделенные цифры в правилах */
.rule-num { font-style: normal; font-weight: 700; font-size: 1.12em; color: #6E57E5; }

/* ───────── Страница «Донаты» ───────── */
.don-manifest { max-width: 860px; margin: 0 0 28px; padding: clamp(24px, 3.4vw, 40px); background: rgba(255, 255, 255, 0.92); border: 1px solid #E5E7EB; border-radius: 16px; box-shadow: 0 10px 30px rgba(17, 24, 39, 0.04); font-style: normal; }
.don-title { margin: 0 0 18px; padding-left: 16px; border-left: 3px solid #6E57E5; font-family: "Jura", sans-serif; font-weight: 600; font-style: normal; font-size: clamp(1.2rem, 2.6vw, 1.7rem); line-height: 1.3; letter-spacing: 0.04em; color: #1F2937; }
.don-manifest p { margin: 0 0 16px; font-style: normal; font-size: 1.02rem; line-height: 1.85; color: #374151; }
.don-manifest p:last-child { margin-bottom: 0; }
.don-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; max-width: 1080px; }
.don-card { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; min-height: 160px; padding: 22px 20px; text-align: left; font: inherit; color: #1F2937; background: #FFFFFF; border: 1px solid #E5E7EB; border-radius: 12px; cursor: pointer; -webkit-tap-highlight-color: transparent; transition: transform .35s ease, border-color .35s ease, color .35s ease, box-shadow .35s ease; }
.don-card:hover, .don-card:focus-visible { transform: translateY(-4px); border-color: #6E57E5; color: #6E57E5; box-shadow: 0 14px 32px rgba(110, 87, 229, 0.14); outline: none; }
.don-emoji { font-size: 1.6rem; line-height: 1; }
.don-name { font-weight: 600; font-size: 1rem; line-height: 1.4; }
.don-sum { margin-top: auto; font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.25rem; letter-spacing: 0.03em; }
.don-modal[hidden] { display: none; }
.don-modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 20px; }
.don-backdrop { position: absolute; inset: 0; background: rgba(17, 24, 39, 0.38); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.don-dialog { position: relative; width: min(440px, 100%); padding: 32px 28px 26px; text-align: center; background: #fff; border: 1px solid #E5E7EB; border-radius: 16px; box-shadow: 0 24px 60px rgba(17, 24, 39, 0.2); outline: none; animation: dash-in .35s ease both; }
.don-dialog p { margin: 0 0 22px; font-size: 1.05rem; line-height: 1.7; color: #1F2937; }
body.don-lock { overflow: hidden; }
@media (max-width: 960px) { .don-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .don-grid { grid-template-columns: 1fr; gap: 12px; } .don-card { min-height: 0; } .don-manifest p { font-size: 0.98rem; line-height: 1.75; } }
@media (prefers-reduced-motion: reduce) { .don-card, .don-dialog { transition: none; animation: none; } .don-card:hover { transform: none; } }

/* ───────── Иллюстрации на страницах «Правила» и «Донаты» ───────── */
.pub-title-wrap.has-art { display: flex; align-items: center; justify-content: space-between; gap: clamp(20px, 5vw, 64px); }
.pub-title-text { min-width: 0; flex: 1 1 auto; }
.pub-art { flex: none; width: clamp(240px, 30vw, 360px); height: auto; display: block; animation: gentle-wobble 9s ease-in-out infinite alternate; }
.rule-head { display: flex; align-items: center; gap: 16px; margin-bottom: 16px; }
.rule-head .rule-title { margin: 0; padding-left: 0; border-left: 0; }
.rule-ico { flex: none; display: grid; place-items: center; width: 52px; height: 52px; color: #6E57E5; background: #F1EEFD; border: 1px solid rgba(110, 87, 229, 0.22); border-radius: 14px; }
.rule-ico svg { width: 30px; height: 30px; display: block; }
@media (max-width: 760px) {
  .pub-title-wrap.has-art { flex-direction: column-reverse; align-items: flex-start; gap: 8px; }
  .pub-art { width: min(260px, 70%); align-self: center; }
  .rule-ico { width: 44px; height: 44px; border-radius: 12px; }
  .rule-ico svg { width: 25px; height: 25px; }
  .rule-head { gap: 12px; align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) { .pub-art { animation: none; } }

/* Иллюстрации страниц меню — вдвое компактнее */
.pub-art { width: clamp(120px, 15vw, 180px); }
@media (max-width: 760px) { .pub-art { width: min(140px, 40%); } }

/* Невесомость: иллюстрации постоянно парят и чуть вращаются */
@keyframes pub-zero-g {
  0%   { transform: translate3d(0, 0, 0) rotate(0deg); }
  25%  { transform: translate3d(6px, -12px, 0) rotate(2.2deg); }
  50%  { transform: translate3d(0, -20px, 0) rotate(0deg); }
  75%  { transform: translate3d(-6px, -10px, 0) rotate(-2.2deg); }
  100% { transform: translate3d(0, 0, 0) rotate(0deg); }
}
.pub-art { animation: pub-zero-g 7s ease-in-out infinite; will-change: transform; }
@media (max-width: 760px) { .pub-art { animation-duration: 6s; } }
@media (prefers-reduced-motion: reduce) { .pub-art { animation: none; } }

/* Донаты: карточки сверху, иллюстрации вместо эмодзи, акценты в манифесте */
.don-grid { margin-bottom: 28px; }
.don-ico { display: grid; place-items: center; width: 64px; height: 64px; color: #1F2937; background: #F6F4FE; border: 1px solid rgba(110, 87, 229, 0.18); border-radius: 14px; transition: background .35s ease, border-color .35s ease; }
.don-ico svg { width: 48px; height: 48px; display: block; }
.don-card:hover .don-ico, .don-card:focus-visible .don-ico { background: #F1EEFD; border-color: rgba(110, 87, 229, 0.5); }
.don-mark { padding: 1px 6px; font-weight: 700; color: #6E57E5; background: rgba(110, 87, 229, 0.09); border-radius: 6px; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.don-manifest p.don-accent { margin-top: 20px; padding: 18px 22px; color: #3F3A9E; background: #F1EEFD; border: 1px solid rgba(110, 87, 229, 0.22); border-left: 3px solid #6E57E5; border-radius: 12px; }
@media (max-width: 520px) { .don-card { flex-direction: row; align-items: center; gap: 14px; } .don-sum { margin: 0 0 0 auto; white-space: nowrap; } .don-ico { width: 54px; height: 54px; } .don-ico svg { width: 40px; height: 40px; } }
.don-ico { width: 72px; height: 72px; }
.don-ico svg { width: 54px; height: 54px; }
.don-card { min-width: 0; }
@media (max-width: 520px) {
  .don-card { overflow: hidden; }
  .don-name { min-width: 0; flex: 1 1 auto; }
  .don-sum { flex: none; white-space: normal; max-width: 38%; text-align: right; font-size: 1.05rem; }
  .don-ico { width: 54px; height: 54px; flex: none; }
  .don-ico svg { width: 40px; height: 40px; }
}

/* Шапка с меню всегда поверх контента: страницы листаются до неё и не заходят под неё */
.pub-head { position: sticky; top: 0; z-index: 100; background: #FFFFFF; -webkit-backdrop-filter: none; backdrop-filter: none; }
.pub-main { position: relative; z-index: 1; }
.topbar { background: #FFFFFF; -webkit-backdrop-filter: none; backdrop-filter: none; }

/* Главная: кнопка «Начать» в шапке появляется только после формы входа */
.nav-start { opacity: 0; visibility: hidden; transform: translateY(-4px); pointer-events: none; transition: opacity .4s ease, transform .4s ease, visibility .4s, background-position .7s ease, box-shadow .4s ease; }
.nav-start.is-on { opacity: 1; visibility: visible; transform: none; pointer-events: auto; }
.nav-start.is-on:hover, .nav-start.is-on:focus-visible { transform: translateY(-1px); }

/* ───────── Тренажёр дыхания 4×4 ───────── */
.br { max-width: 860px; margin: 0 0 28px; }
.br-note { margin-bottom: 20px; padding: 18px 24px; background: #FFFFFF; border: 1px solid #E5E7EB; border-left: 3px solid #6E57E5; border-radius: 14px; }
.br-note p { margin: 0; font-weight: 300; font-style: normal; font-size: 1.02rem; line-height: 1.8; color: #4B5563; }
.br-card { padding: clamp(22px, 3.4vw, 40px); text-align: center; background: #FFFFFF; border: 1px solid #E5E7EB; border-radius: 20px; box-shadow: 0 18px 50px rgba(17, 24, 39, 0.05); }
.br-title { margin: 0; font-family: "Jura", sans-serif; font-weight: 600; font-style: normal; font-size: clamp(1.2rem, 2.6vw, 1.6rem); letter-spacing: 0.12em; color: #1F2937; }
.br-sub { margin: 8px 0 0; font-weight: 300; font-size: 0.95rem; color: #6B7280; }
.br-stage { display: grid; place-items: center; margin: clamp(10px, 2vw, 22px) 0 6px; }
.br-svg { width: min(420px, 100%); height: auto; display: block; overflow: visible; }
.br-outer { stroke: #E5E7EB; stroke-width: 1.5; }
.br-live { will-change: transform; }
#brRing { stroke: #6E57E5; stroke-width: 4; }
.br-dot { fill: #6E57E5; opacity: 0; filter: drop-shadow(0 0 6px rgba(110, 87, 229, 0.55)); }
.br-label { font-family: "Jura", sans-serif; font-weight: 700; font-style: normal; font-size: 21px; letter-spacing: 0.16em; fill: #1F2937; opacity: 0; paint-order: stroke; stroke: rgba(255, 255, 255, 0.85); stroke-width: 6px; stroke-linejoin: round; }
.br-idle { font-size: 19px; fill: #4B5563; }
.br-status { min-height: 1.6em; margin: 4px 0 16px; font-weight: 400; font-size: 0.92rem; letter-spacing: 0.04em; color: #4B5563; }
.br-actions { display: flex; justify-content: center; }
.br-btn { min-width: 220px; }
@media (max-width: 520px) { .br-note { padding: 14px 16px; } .br-note p { font-size: 0.98rem; line-height: 1.7; } .br-label { font-size: 22px; } }
.br-idle { font-size: 16px; letter-spacing: 0.1em; }

/* ───────── Полезные материалы: вкладки, аватар Майи, режимы ───────── */
.mat-tabs { display: flex; flex-wrap: wrap; gap: 10px; max-width: 1080px; margin: 0 0 24px; }
.mat-tab { padding: 13px 22px; font: inherit; font-weight: 600; font-size: 0.82rem; letter-spacing: 0.1em; color: #1F2937; background: #FFFFFF; border: 1px solid #E5E7EB; border-radius: 12px; cursor: pointer; -webkit-tap-highlight-color: transparent; transition: color .3s ease, border-color .3s ease, background .3s ease, transform .3s ease, box-shadow .3s ease; }
.mat-tab:hover, .mat-tab:focus-visible { color: #6E57E5; border-color: #6E57E5; transform: translateY(-2px); outline: none; }
.mat-tab.is-on { color: #6E57E5; background: #F1EEFD; border-color: #6E57E5; box-shadow: 0 8px 22px rgba(110, 87, 229, 0.14); }
.mat-tab-empty { min-width: 96px; letter-spacing: 0.3em; }
.mat-panel[hidden] { display: none; }
.br-note { display: flex; align-items: center; gap: 16px; }
.br-ava { flex: none; width: 52px; height: 52px; overflow: hidden; border-radius: 50%; border: 2px solid #FFFFFF; box-shadow: 0 0 0 1.5px #6E57E5, 0 6px 16px rgba(110, 87, 229, 0.2); background: #F1EEFD; }
.br-ava img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 14%; }
.br-modes { display: inline-flex; gap: 6px; margin: 14px 0 0; padding: 4px; background: #F6F4FE; border: 1px solid #E5E7EB; border-radius: 12px; }
.br-mode { padding: 9px 16px; font: inherit; font-weight: 500; font-size: 0.84rem; letter-spacing: 0.04em; color: #4B5563; background: transparent; border: 0; border-radius: 9px; cursor: pointer; transition: color .3s ease, background .3s ease, box-shadow .3s ease; }
.br-mode:hover, .br-mode:focus-visible { color: #6E57E5; outline: none; }
.br-mode.is-on { color: #6E57E5; background: #FFFFFF; box-shadow: 0 2px 10px rgba(110, 87, 229, 0.16); }
.br-hint { max-width: 460px; margin: 6px auto 0; font-weight: 300; font-size: 0.88rem; line-height: 1.6; color: #6B7280; }
@media (max-width: 520px) { .mat-tab { flex: 1 1 100%; text-align: center; } .mat-tab-empty { flex: 1 1 100%; } .br-ava { width: 44px; height: 44px; } .br-modes { width: 100%; } .br-mode { flex: 1; padding: 9px 8px; font-size: 0.8rem; } }

/* ───────── Галерея раскрасок-антистресс (сетка 5×2) ───────── */
.gal { max-width: 1080px; text-align: center; }
.gal-sub { max-width: 640px; margin: 10px auto 26px; font-weight: 300; font-size: 0.98rem; line-height: 1.7; color: #4B5563; }
.gal-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; }
.gal-card { display: flex; flex-direction: column; margin: 0; background: #FFFFFF; border: 1px solid #E5E7EB; border-radius: 14px; overflow: hidden; transition: transform .35s ease, border-color .35s ease, box-shadow .35s ease; }
.gal-card:hover { transform: translateY(-4px); border-color: #6E57E5; box-shadow: 0 14px 32px rgba(110, 87, 229, 0.14); }
.gal-thumb { display: block; padding: 0; background: #FFFFFF; border: 0; border-bottom: 1px solid #F0F1F5; cursor: zoom-in; }
.gal-thumb img { display: block; width: 100%; height: auto; aspect-ratio: 420 / 594; object-fit: cover; }
.gal-thumb:focus-visible { outline: 2px solid #6E57E5; outline-offset: -2px; }
.gal-card figcaption { display: flex; flex-direction: column; gap: 10px; padding: 12px 10px 14px; flex: 1; }
.gal-name { margin: 0; flex: 1; font-family: "Jura", sans-serif; font-weight: 600; font-size: 0.84rem; line-height: 1.35; letter-spacing: 0.06em; color: #1F2937; }
.gal-dl { display: inline-flex; align-items: center; justify-content: center; padding: 9px 12px; font-size: 0.82rem; text-decoration: none; }
.gal-modal[hidden] { display: none; }
.gal-modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 16px; }
.gal-dialog { position: relative; display: flex; flex-direction: column; align-items: center; gap: 14px; max-height: 100%; padding: 14px; background: #fff; border: 1px solid #E5E7EB; border-radius: 16px; box-shadow: 0 24px 60px rgba(17, 24, 39, 0.25); outline: none; }
.gal-dialog img { display: block; max-width: min(86vw, 560px); max-height: calc(100vh - 150px); width: auto; height: auto; border-radius: 8px; }
.gal-x { position: absolute; top: 8px; right: 10px; width: 36px; height: 36px; font-size: 1.5rem; line-height: 1; color: #1F2937; background: rgba(255, 255, 255, 0.92); border: 1px solid #E5E7EB; border-radius: 50%; cursor: pointer; }
.gal-x:hover { color: #6E57E5; border-color: #6E57E5; }
@media (max-width: 1000px) { .gal-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 560px) { .gal-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; } .gal-name { font-size: 0.78rem; } }
@media (prefers-reduced-motion: reduce) { .gal-card { transition: none; } .gal-card:hover { transform: none; } }

/* Окна поверх шапки: пока открыто модальное окно, шапка уходит под затемнение */
body.don-lock .pub-head { z-index: 0; }
.gal-dialog img { max-height: calc(100vh - 170px); }

/* ───────── Игра «ЧПОК-ЧПОК» ───────── */
.pop { max-width: 860px; margin: 0 0 28px; }
.pop-card { padding: clamp(18px, 3vw, 32px); background: #FFFFFF; border: 1px solid #E5E7EB; border-radius: 16px; box-shadow: 0 18px 50px rgba(17, 24, 39, 0.05); }
.pop-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.pop-headtext .br-title { text-align: left; }
.pop-count { margin: 6px 0 0; font-weight: 400; font-size: 0.9rem; letter-spacing: 0.04em; color: #4B5563; }
.pop-reset { flex: none; padding: 10px 18px; font: inherit; font-weight: 500; font-size: 0.86rem; letter-spacing: 0.02em; color: #fff; background: linear-gradient(120deg, #8672F1 0%, #6E57E5 40%, #6E57E5 70%, #7F6AEE 100%); border: 0; border-radius: 10px; cursor: pointer; box-shadow: inset 0 1px 0 rgba(255,255,255,.28), 0 4px 14px rgba(110, 87, 229, 0.25); transition: transform .3s ease, box-shadow .3s ease; }
.pop-reset:hover, .pop-reset:focus-visible { transform: translateY(-1px); box-shadow: inset 0 1px 0 rgba(255,255,255,.4), 0 8px 22px rgba(110, 87, 229, 0.4); outline: none; }
.pop-field { --pop-cursor: url("data:image/svg+xml,%3Csvg%20xmlns=%27http://www.w3.org/2000/svg%27%20width=%2732%27%20height=%2732%27%20viewBox=%270%200%2032%2032%27%3E%3Cpath%20d=%27M12%203.5c1.4%200%202.5%201.1%202.5%202.5v8.2l1.2-.5c1.2-.5%202.6.1%203.1%201.3l.3.7%201.4-.4c1.2-.3%202.4.4%202.7%201.6l.2.9%20.9-.2c1.1-.2%202.2.5%202.5%201.6.5%202.4.2%205-.8%207.2-.9%202-2.6%203.6-4.7%204.2H15c-1.7%200-3.3-.8-4.3-2.1L5.4%2022c-.8-1-.7-2.4.2-3.2%201-.9%202.4-.8%203.3.1L9.5%2019.600V6c0-1.400%201.100-2.500%202.500-2.500z%27%20fill=%27white%27%20stroke=%27%236E57E5%27%20stroke-width=%271.600%27%20stroke-linejoin=%27round%27/%3E%3Ccircle%20cx=%2712%27%20cy=%273.500%27%20r=%270%27%20/%3E%3C/svg%3E") 12 3, pointer; display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: clamp(8px, 1.6vw, 16px); padding: clamp(14px, 2.4vw, 26px); background: #FBFAFF; border: 1px solid #E5E7EB; border-radius: 16px; cursor: var(--pop-cursor); touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.pop-b { position: relative; aspect-ratio: 1; width: 100%; padding: 0; border-radius: 50%; border: 1px solid #6E57E5; background: radial-gradient(circle at 34% 28%, rgba(255,255,255,0.95) 0 9%, rgba(255,255,255,0) 22%), radial-gradient(circle at 50% 52%, rgba(110,87,229,0.10) 0%, rgba(110,87,229,0.22) 100%); box-shadow: inset 0 -5px 10px rgba(110, 87, 229, 0.22), inset 0 3px 6px rgba(255, 255, 255, 0.9), 0 3px 8px rgba(110, 87, 229, 0.18); cursor: var(--pop-cursor); -webkit-tap-highlight-color: transparent; transition: background .3s ease, border-color .3s ease, box-shadow .3s ease, transform .3s ease, opacity .3s ease; }
.pop-b:hover { transform: scale(1.04); }
.pop-b:focus-visible { outline: 2px solid #6E57E5; outline-offset: 2px; }
.pop-b:active { transform: scale(0.96); }
.pop-b.popped { background: rgba(156, 163, 175, 0.12); border-color: rgba(156, 163, 175, 0.45); box-shadow: none; opacity: 0.6; transform: scale(0.94); pointer-events: none; cursor: default; }
.pop-done { margin: 18px 0 0; text-align: center; font-weight: 400; font-size: 0.98rem; color: #6E57E5; }
.pop-done[hidden] { display: none; }
@media (max-width: 640px) { .pop-field { grid-template-columns: repeat(5, minmax(0, 1fr)); } .pop-head { flex-direction: column; align-items: stretch; } .pop-reset { align-self: flex-start; } }
@media (prefers-reduced-motion: reduce) { .pop-b, .pop-reset { transition: none; } }

/* ───────── ИИ-карта дня: 12 карт (сетка 6×2) ───────── */
.tcards { max-width: 1080px; }
.tcards-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.tcards-headtext .br-title { text-align: left; font-size: clamp(1.05rem, 2.2vw, 1.45rem); }
.tcards-sub { max-width: 680px; margin: 10px 0 0; font-weight: 300; font-size: 0.95rem; line-height: 1.7; color: #4B5563; }
.tcards-reset { align-self: flex-start; }
.tgrid.shuffling .tcard { pointer-events: none; transition: none; }
.tcards-who { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.tcards-ava { width: 64px; height: 64px; border-radius: 50%; overflow: hidden; border: 1px solid rgba(110, 87, 229, 0.45); box-shadow: 0 6px 18px rgba(110, 87, 229, 0.18); flex: none; }
.tcards-ava img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tcards-whoname { font-family: "Jura", sans-serif; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; font-size: 0.85rem; color: #6E57E5; }
.tgrid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; }
.tcard { position: relative; aspect-ratio: 2 / 3; perspective: 1000px; transition: transform .35s ease, opacity .5s ease, filter .5s ease; }
.tcard-in { position: relative; display: block; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: pointer; transform-style: preserve-3d; transition: transform .9s cubic-bezier(.3, .7, .2, 1); -webkit-tap-highlight-color: transparent; }
.tcard.is-flipped .tcard-in { transform: rotateY(180deg); cursor: default; }
.tface { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; background: #FFFFFF; border: 1px solid #E5E7EB; border-radius: 14px; -webkit-backface-visibility: hidden; backface-visibility: hidden; transition: border-color .35s ease, box-shadow .35s ease; }
.tback svg { width: 82%; height: 82%; display: block; }
.tfront { transform: rotateY(180deg); gap: 6px; padding: 10px 9px; text-align: center; border-color: rgba(110, 87, 229, 0.55); box-shadow: 0 10px 30px rgba(110, 87, 229, 0.16); }
.tfront-ico { display: block; width: 48%; max-width: 74px; flex: none; }
.tfront-ico svg { width: 100%; height: auto; display: block; }
.tfront-lbl { font-family: "Jura", sans-serif; font-weight: 600; font-size: 0.62rem; letter-spacing: 0.18em; color: #6E57E5; }
.tfront-txt { font-weight: 400; font-style: normal; font-size: clamp(0.62rem, 1vw, 0.76rem); line-height: 1.4; color: #1F2937; overflow-wrap: anywhere; }
.tgrid:not(.has-pick) .tcard:hover { transform: translateY(-5px); z-index: 2; }
.tgrid:not(.has-pick) .tcard:hover .tback, .tgrid:not(.has-pick) .tcard-in:focus-visible .tback { border-color: #6E57E5; box-shadow: 0 0 0 1px rgba(110, 87, 229, 0.75), 0 0 22px rgba(110, 87, 229, 0.45); }
.tcard-in:focus-visible { outline: none; }
.tgrid.has-pick .tcard:not(.is-picked) { opacity: 0.3; pointer-events: none; filter: saturate(.6); }
.tres { display: none; }
@media (max-width: 900px) { .tgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; } .tfront-txt { font-size: clamp(0.72rem, 2vw, 0.86rem); } .tfront-lbl { font-size: 0.7rem; } .tcards-head { flex-direction: column; } }
@media (max-width: 640px) {
  .tgrid { gap: 10px; }
  .tfront-txt, .tfront-lbl { display: none; }
  .tfront-ico { width: 62%; }
  .tres:not([hidden]) { display: flex; flex-direction: column; align-items: center; gap: 8px; margin-top: 18px; padding: 20px 18px; text-align: center; background: #FFFFFF; border: 1px solid rgba(110, 87, 229, 0.45); border-radius: 16px; box-shadow: 0 10px 30px rgba(110, 87, 229, 0.12); }
  .tres-ico { width: 72px; display: block; }
  .tres-ico svg { width: 100%; height: auto; display: block; }
  .tres-lbl { font-family: "Jura", sans-serif; font-weight: 600; font-size: 0.72rem; letter-spacing: 0.18em; color: #6E57E5; }
  .tres-txt { font-size: 1rem; line-height: 1.6; color: #1F2937; }
}
@media (prefers-reduced-motion: reduce) { .tcard, .tcard-in { transition: none; } .tgrid:not(.has-pick) .tcard:hover { transform: none; } }

/* Вкладки в одну линию */
.mat-tabs { flex-wrap: nowrap; gap: 8px; max-width: 1080px; }
.mat-tab { flex: 1 1 auto; min-width: 0; padding: 13px 12px; font-size: 0.74rem; letter-spacing: 0.06em; text-align: center; white-space: nowrap; }
@media (max-width: 960px) { .mat-tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); } .mat-tab { white-space: normal; } }
@media (max-width: 520px) { .mat-tab { flex: none; padding: 12px 8px; font-size: 0.7rem; } }

/* Лимит вытягивания карт */
.tcards-left { margin: -6px 0 18px; font-weight: 400; font-size: 0.9rem; letter-spacing: 0.03em; color: #6E57E5; }
.tcards-reset:disabled, .tcards-reset.is-off { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: none; }
.tgrid.is-locked .tcard { opacity: 0.3; pointer-events: none; filter: saturate(.6); }

/* Чат: широкая кнопка «Полезные материалы» под тремя кнопками */
.dash-nav-wide { grid-column: 1 / -1; }

/* Кнопка «Назад в чат» */
.pub-back-wrap { max-width: 1080px; margin: 0 auto 6px; }
.pub-back { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px 10px 14px; font-weight: 500; font-size: 0.86rem; letter-spacing: 0.03em; text-decoration: none; color: #1F2937; background: #FFFFFF; border: 1px solid #E5E7EB; border-radius: 10px; transition: color .3s ease, border-color .3s ease, transform .3s ease, box-shadow .3s ease; }
.pub-back svg { width: 18px; height: 18px; flex: none; transition: transform .3s ease; }
.pub-back:hover, .pub-back:focus-visible { color: #6E57E5; border-color: #6E57E5; box-shadow: 0 8px 22px rgba(110, 87, 229, 0.14); outline: none; }
.pub-back:hover svg, .pub-back:focus-visible svg { transform: translateX(-3px); }

/* Закрытые разделы «Полезных материалов» */
.mat-panel.is-locked > :not(.mat-lock) { display: none !important; }
.mat-lock { max-width: 560px; margin: 26px auto 10px; padding: 34px 28px; text-align: center; background: #FFFFFF; border: 1px solid rgba(110, 87, 229, 0.35); border-radius: 18px; box-shadow: 0 14px 40px rgba(110, 87, 229, 0.12); }
.mat-lock-ico { font-size: 1.8rem; display: block; margin-bottom: 8px; }
.mat-lock-t { margin: 0 0 10px; font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.2rem; line-height: 1.35; color: #1F2937; }
.mat-lock-p { margin: 0 0 20px; font-weight: 300; line-height: 1.7; color: #4B5563; }
.mat-lock-btn { display: inline-block; padding: 13px 26px; border-radius: 14px; background: linear-gradient(135deg, #7C68EE, #6E57E5); color: #FFFFFF; font-weight: 600; text-decoration: none; box-shadow: 0 10px 26px rgba(110, 87, 229, 0.3); }
.mat-lock-btn:hover { transform: translateY(-2px); }
.mat-tab.is-lock::after { content: " 🔒"; font-size: 0.8em; }
.tcards-trial { margin: 0 0 6px; font-size: 0.88rem; color: #6E57E5; }

.bl-perks { list-style: none; margin: 10px 0 14px; padding: 10px 0 0; border-top: 1px solid #EEF0F4; text-align: left; font-size: 0.8rem; line-height: 1.5; color: #4B5563; }
.bl-perks li { position: relative; padding-left: 16px; margin-top: 6px; }
.bl-perks li::before { content: "✦"; position: absolute; left: 0; color: #6E57E5; }
.bl-perks b { color: #1F2937; font-weight: 600; }

/* Вход на главной */
.auth-note { margin: 0 0 4px; font-size: 0.88rem; line-height: 1.55; color: var(--ink-soft); text-align: center; }
.auth #authIn, .auth #authDone { display: flex; flex-direction: column; gap: 14px; }
.auth-code { letter-spacing: 10px; text-align: center; font-size: 1.3rem !important; font-weight: 700 !important; }
.auth-link { background: none; border: 0; color: var(--violet); font: 500 0.82rem "Manrope", sans-serif; padding: 4px; cursor: pointer; }
.auth-link:disabled { opacity: .6; cursor: default; }
.auth-tg { display: flex; justify-content: center; min-height: 44px; font-size: 0.88rem; color: var(--ink-soft); text-align: center; align-items: center; }
.auth-msg { margin: 0; min-height: 0; font-size: 0.82rem; color: #b3261e; text-align: center; }
.auth-msg:empty { display: none; }
.auth form[hidden], .auth [hidden] { display: none !important; }

/* Ссылки в правом верхнем углу кабинета (профиль, чат) */
.dash-head-links { flex: none; display: flex; align-items: center; gap: 4px 20px; }
.dash-head-links a { font-weight: 500; font-size: 0.86rem; letter-spacing: 0.02em; color: #4B5563; text-decoration: none; padding: 6px 2px; border-bottom: 1px solid transparent; transition: color .25s ease, border-color .25s ease; white-space: nowrap; }
.dash-head-links a:hover, .dash-head-links a:focus-visible { color: #6E57E5; border-bottom-color: #6E57E5; outline: none; }
.dash-nav-mob { display: none !important; }
@media (max-width: 1100px) { .dash-head-links { gap: 4px 14px; } .dash-head-links a { font-size: 0.8rem; } }
@media (max-width: 920px) { .dash-head-links { display: none; } .dash-nav-mob { display: flex !important; } }

/* В чате шапка узкая: ссылки сверху только на широких экранах, иначе они в боковом меню */
#chat .dash-head-links { display: none; }
@media (min-width: 1400px) and (min-width: 921px) { #chat .dash-head-links { display: flex; } }
.dash-nav-mob-chat { display: none !important; }
@media (max-width: 1399px) { .dash-nav-mob-chat { display: flex !important; } }

/* форма пробного доступа к премиуму */
.pf { display: flex; flex-direction: column; gap: 12px; text-align: left; }
.pf-p { margin: 0; color: var(--ink-soft, #5b5675); line-height: 1.55; }
.pf-steps { margin: 0; padding-left: 20px; color: var(--ink-soft, #5b5675); line-height: 1.6; font-size: 14px; }
.pf-row { display: flex; flex-wrap: wrap; gap: 10px; }
.pf-row .btn { flex: 1 1 180px; text-align: center; justify-content: center; }
.pf-msg { margin: 0; min-height: 20px; font-size: 14px; color: #6E57E5; }
.pf-link { display: flex; justify-content: center; }
.mat-lock .pf { max-width: 460px; margin: 0 auto; }
.dash-soon.is-prem { color: #6E57E5; }
.dash-soon[hidden], .dash-lock[hidden] { display: none !important; }

/* эффекты при выборе Шайи (дым) и Евы (сердца) */
.fx-layer { position: fixed; inset: 0; z-index: 150; pointer-events: none; overflow: hidden; }
.fx-smoke { position: absolute; border-radius: 50%; filter: blur(34px); opacity: 0;
  background: radial-gradient(circle, rgba(150,130,200,.75) 0%, rgba(110,87,229,.35) 45%, rgba(110,87,229,0) 70%);
  animation: fxSmoke var(--d, 2.4s) ease-in-out forwards; animation-delay: var(--dl, 0s); }
@keyframes fxSmoke {
  0% { opacity: 0; transform: translate(0, 40px) scale(.5); }
  35% { opacity: .85; }
  60% { opacity: .7; transform: translate(calc(var(--dx, 0px) * .5), -10px) scale(1.1); }
  100% { opacity: 0; transform: translate(var(--dx, 0px), -90px) scale(1.7); }
}
.fx-heart { position: absolute; line-height: 1; opacity: 0; color: #f6a6c1; text-shadow: 0 2px 10px rgba(246,166,193,.5);
  animation: fxHeart var(--d, 2.2s) cubic-bezier(.3,.8,.3,1) forwards; animation-delay: var(--dl, 0s); }
@keyframes fxHeart {
  0% { opacity: 0; transform: scale(0) rotate(var(--r, 0deg)); }
  30% { opacity: .95; transform: scale(1) rotate(var(--r, 0deg)); }
  70% { opacity: .9; transform: scale(1.08) rotate(var(--r, 0deg)); }
  88% { opacity: .9; transform: scale(1.4) rotate(var(--r, 0deg)); }
  100% { opacity: 0; transform: scale(0) rotate(var(--r, 0deg)); }
}
@media (prefers-reduced-motion: reduce) { .fx-layer { display: none; } }

/* подвал внутренних страниц */
.site-foot { text-align: center; padding: 28px 16px 36px; margin-top: 24px; border-top: 1px solid #EEF0F4; }
.site-foot .dev { margin: 6px 0 0; font-family: "Jura", sans-serif; font-size: 0.8rem; letter-spacing: 0.08em; color: #6B7280; overflow-wrap: anywhere; }
.site-foot .dev a { color: #111827; text-decoration: none; font-weight: 500; border-bottom: 1px solid transparent; transition: color .3s, border-color .3s; }
.site-foot .dev a:hover, .site-foot .dev a:focus-visible { color: #6E57E5; border-color: currentColor; outline: none; }
.dash-dev { margin-top: 2px; font-size: 0.72rem; }
.dash-dev a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.footer .dev + .dev { margin-top: 4px; }

/* мобильная доводка: сетки не растягиваются шире экрана, длинные слова переносятся */
.rules-list { grid-template-columns: minmax(0, 1fr); }
.rule-card, .bl-card { min-width: 0; overflow-wrap: anywhere; }
.bl-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1100px) { .bl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 380px) { .bl-grid { grid-template-columns: minmax(0, 1fr); } .bl-card { min-height: 0; } }
img, svg, video { max-width: 100%; }
@media (max-width: 420px) { .rule-head .rule-title { font-size: 1.02rem; letter-spacing: 0.02em; overflow-wrap: break-word; hyphens: auto; } }

/* ───────── Узкая прямоугольная рамка-«переплетение» вокруг аватара (пока только Майя) ───────── */
.leonardo-card.orbit { position: relative; overflow: visible; aspect-ratio: 4 / 5; border: 0; border-radius: 0; background: transparent; }
.leonardo-card.orbit:hover { transform: none; box-shadow: none; }
.orbit .mimic-stack { position: absolute; inset: 2.8% 3.5%; width: auto; height: auto; border-radius: 14px; overflow: hidden; background: #fff; }
.leonardo-card.orbit:hover .mimic-stack { transform: none; }
.orbit-ring { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 2; overflow: visible; pointer-events: none; filter: drop-shadow(0 0 4px rgba(var(--glow, 110, 87, 229), 0.45)); transition: filter .5s ease; }
.leonardo-card.orbit:hover .orbit-ring { filter: drop-shadow(0 0 7px rgba(var(--glow, 110, 87, 229), 0.75)) saturate(1.25); }
@media (prefers-reduced-motion: reduce) { .orbit-ring animateTransform { display: none; } }


/* волны подвала шире экрана (200%) — не ограничивать общим правилом svg{max-width:100%} */
.footer-waves .wave { max-width: none; }

/* ───────── Вариант 1: тонкая фиолетовая линия с бегущим бликом (пробно у Майи) ───────── */
@property --a { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
.leonardo-card.orbit-line { position: relative; overflow: visible; aspect-ratio: 4 / 5; border: 0; border-radius: 0; background: transparent; }
.leonardo-card.orbit-line:hover { transform: none; box-shadow: none; }
.orbit-line .mimic-stack { position: absolute; inset: 10px; width: auto; height: auto; border-radius: 14px; overflow: hidden; background: #fff; }
.leonardo-card.orbit-line:hover .mimic-stack { transform: none; }
.orbit-line::before {
  content: ""; position: absolute; inset: 0; z-index: 2; border-radius: 22px; padding: 1.5px; pointer-events: none;
  background: conic-gradient(from var(--a), rgba(var(--glow, 110, 87, 229), .6) 0deg, rgba(var(--glow, 110, 87, 229), .6) 250deg, var(--lh, #C9BDFF) 300deg, #fff 330deg, var(--lh, #C9BDFF) 345deg, rgba(var(--glow, 110, 87, 229), .6) 360deg);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  animation: lineRun 9s linear infinite;
}
.orbit-line::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: 22px; pointer-events: none; box-shadow: 0 0 22px rgba(var(--glow, 110, 87, 229), .14); }
@keyframes lineRun { to { --a: 360deg; } }
@media (prefers-reduced-motion: reduce) { .orbit-line::before { animation: none; } }

/* согласия при регистрации */
.consent { display: flex; flex-direction: column; gap: 9px; text-align: left; padding: 2px 2px 4px; border-radius: 12px; }
.consent[hidden] { display: none !important; }
.consent .chk { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; font-size: 0.78rem; line-height: 1.45; color: var(--ink-soft); }
.consent .chk input { flex: none; appearance: auto; -webkit-appearance: checkbox; width: 18px !important; height: 18px; min-height: 0; margin: 1px 0 0; padding: 0 !important; accent-color: #6E57E5; box-shadow: none !important; background: transparent; border-radius: 4px; cursor: pointer; }
.consent .chk a { color: var(--violet); text-decoration: underline; text-underline-offset: 2px; }
.consent.is-bad { animation: consentShake .45s ease; box-shadow: 0 0 0 2px rgba(179, 38, 30, .35); padding: 8px; }
@keyframes consentShake { 20% { transform: translateX(-5px); } 40% { transform: translateX(5px); } 60% { transform: translateX(-3px); } 80% { transform: translateX(3px); } }
.auth-tg-wrap { position: relative; }
.auth-tg-lock { position: absolute; inset: 0; z-index: 2; background: transparent; border: 0; padding: 0; cursor: pointer; }
.auth-tg-lock[hidden] { display: none !important; }
@media (prefers-reduced-motion: reduce) { .consent.is-bad { animation: none; } }

/* согласия — мелким шрифтом под кнопками входа */
.consent { margin-top: 2px; gap: 7px; }
.consent .chk { font-size: 0.68rem; line-height: 1.4; gap: 8px; color: var(--ink-faint, #7b7894); }
.consent .chk input { width: 15px !important; height: 15px; }
.auth #authGo:disabled { opacity: .45; cursor: not-allowed; }
.auth-tg-wrap { transition: opacity .25s ease; }
/* кнопка Telegram всегда яркая: по нажатию до согласия открывается окно с галочками */

/* компактный блок согласий */
.auth #authIn { gap: 10px; }
.consent { margin-top: 0; gap: 4px; padding: 0 2px; }
.consent .chk { font-size: 0.64rem; line-height: 1.3; gap: 7px; align-items: center; }
.consent .chk input { width: 13px !important; height: 13px; margin: 0; }
.consent.is-bad { padding: 5px; }
.auth-tg { min-height: 40px; }

/* окно согласий при регистрации */
.cm { position: fixed; inset: 0; z-index: 150; display: flex; align-items: center; justify-content: center; padding: 20px; }
.cm[hidden] { display: none; }
.cm-back { position: absolute; inset: 0; background: rgba(23, 20, 44, .45); backdrop-filter: blur(3px); }
.cm-card { position: relative; width: 100%; max-width: 440px; max-height: calc(100vh - 40px); overflow: auto; padding: 26px 24px 18px; border-radius: 22px; background: #fff; box-shadow: 0 24px 70px rgba(30, 20, 80, .28); display: flex; flex-direction: column; gap: 12px; animation: cmIn .28s ease; }
@keyframes cmIn { from { opacity: 0; transform: translateY(10px) scale(.98); } to { opacity: 1; transform: none; } }
.cm-card h3 { margin: 0; font: 600 1.15rem "Jura", sans-serif; letter-spacing: .06em; color: #1a1530; }
.cm-lead { margin: 0 0 2px; font-size: .85rem; color: var(--ink-soft); }
.cm-chk { display: flex; gap: 11px; align-items: flex-start; cursor: pointer; font-size: .82rem; line-height: 1.45; color: #3a3556; text-align: left; }
.cm-chk input { flex: none; appearance: auto; -webkit-appearance: checkbox; width: 18px; height: 18px; margin: 1px 0 0; accent-color: #6E57E5; cursor: pointer; }
.cm-chk a { color: var(--violet); text-decoration: underline; text-underline-offset: 2px; }
.cm-card .btn:disabled { opacity: .45; cursor: not-allowed; }
.cm-card .auth-link { align-self: center; }
@media (prefers-reduced-motion: reduce) { .cm-card { animation: none; } }

/* компактный подвал внутренних страниц: две строки, плотный интервал */
.site-foot { display: block; padding: 10px 16px 12px; margin-top: 8px; }
.site-foot .dev { margin: 0; font-size: 0.74rem; line-height: 1.45; }
.site-foot .dev + .dev { margin-top: 0; }
@media (max-width: 640px) { .site-foot { padding: 9px 14px 11px; } .site-foot .dev { font-size: 0.7rem; } }

/* строки разработчика идут сразу после «Анонимно • Конфиденциально • 24/7», без разделительной линии */
.pg-foot { padding-bottom: 6px; }
.site-foot { border-top: 0; margin-top: 0; padding-top: 0; }
.pg-inner:has(.pg-foot) { padding-bottom: 0; }
.dash-feed:has(.pg-foot) { padding-bottom: 0; }
.pg-foot { padding-bottom: 2px; }

/* «AI» в названии */
.wm-ai { color: inherit; font: inherit; letter-spacing: inherit; margin-left: 0; }
.title .title-ai { color: inherit; font: inherit; letter-spacing: inherit; vertical-align: baseline; margin-left: 0; white-space: nowrap; }

/* фиолетовая кнопка «Войти через Telegram» поверх невидимого виджета */
.tg-skin { position: relative; display: block !important; min-height: 48px !important; width: 100%; overflow: hidden; border-radius: 14px; }
.tg-skin-btn { display: flex; align-items: center; justify-content: center; gap: 10px; height: 48px; width: 100%; border-radius: 14px; background: linear-gradient(135deg, #7d68ee, #6E57E5 55%, #5d47d4); color: #fff; font-weight: 600; font-size: .98rem; letter-spacing: .01em; box-shadow: 0 10px 24px rgba(110, 87, 229, .28); pointer-events: none; transition: transform .2s ease, box-shadow .2s ease, filter .2s ease; }
.tg-skin:hover .tg-skin-btn { transform: translateY(-1px); filter: brightness(1.06); box-shadow: 0 14px 30px rgba(110, 87, 229, .34); }
.tg-skin:active .tg-skin-btn { transform: scale(.985); }
.tg-skin iframe { position: absolute !important; left: 0; top: 0; opacity: 0; transform-origin: 0 0; border: 0; z-index: 1; cursor: pointer; }
.auth-msg.is-ok { color: var(--violet, #6E57E5); font-weight: 500; }

button.tg-skin-btn { pointer-events: auto; border: 0; cursor: pointer; font-family: inherit; font-weight: 600; font-size: .98rem; }
button.tg-skin-btn:focus-visible { outline: 2px solid #6E57E5; outline-offset: 3px; }

/* Меню на телефоне: кнопка строго в правом верхнем углу, невидимая «Начать» не занимает место */
@media (max-width: 860px) {
  .topbar { padding-right: 16px; }
  .topbar-right { margin-left: auto; flex: 0 0 auto; }
  .topbar-right .nav-start { display: none; }
  .topnav-burger { margin-left: auto; }
}

/* Мобильная версия: высота слайда = высота активного текста, без лишнего отступа до кнопки */
@media (max-width:820px){
  .slider{display:block}
  .slide{display:none;opacity:1;visibility:visible;transform:none}
  .slide.is-active{display:flex;animation:slideIn .35s ease both}
  .expert-text .btn{margin-top:6px}
}
@keyframes slideIn{from{opacity:0;transform:translateX(var(--shift,14px))}to{opacity:1;transform:none}}

/* SEO-тексты */
.seo-text{max-width:760px;margin:0 auto 8px;color:var(--ink,#1F2937);line-height:1.65}
.seo-text h2,.seo-block h2{font-family:'Jura',sans-serif;font-size:1.35rem;margin:28px 0 10px}
.seo-lead{font-size:1.1rem}
.seo-text ul{padding-left:1.2em;margin:0 0 18px}.seo-text li{margin:4px 0}
.seo-note,.seo-others{max-width:760px;margin:18px auto;font-size:.9rem;opacity:.75;line-height:1.55}
.seo-others a{color:var(--violet,#6E57E5)}
.seo-block{max-width:860px;margin:0 auto;padding:56px 20px 8px;line-height:1.65}
.seo-block p{margin:0 0 14px}
.seo-block .seo-links{display:flex;flex-wrap:wrap;gap:10px;margin-top:14px}
.seo-block .seo-links a{padding:8px 14px;border:1px solid rgba(110,87,229,.35);border-radius:999px;color:var(--violet,#6E57E5);text-decoration:none;font-weight:500}

.footer-about{margin:6px 0 10px;text-align:center}.footer-about a{color:inherit;opacity:.85;text-decoration:underline;text-underline-offset:3px}

.auth-about{margin:10px 0 0;text-align:center;font-size:.92rem}.auth-about a{color:var(--violet,#6E57E5);text-decoration:none;opacity:.9}.auth-about a:hover{text-decoration:underline}

.seo-back{display:block !important;margin-bottom:14px}

/* кнопки-ссылки на странице «О платформе» и страницах собеседников; единая ширина колонки */
.seo-links{display:flex;flex-wrap:wrap;gap:10px;margin-top:14px}
.seo-links a{padding:8px 16px;border:1px solid rgba(110,87,229,.35);border-radius:999px;color:var(--violet,#6E57E5);text-decoration:none;font-weight:500;background:#fff;transition:border-color .2s,box-shadow .2s}
.seo-links a:hover,.seo-links a:focus-visible{border-color:#6E57E5;box-shadow:0 6px 18px rgba(110,87,229,.14);outline:none}
.seo-text + .faq-list{max-width:760px;margin-left:auto;margin-right:auto}
.seo-text p{margin:0 0 14px}
.seo-others-wrap{margin-top:8px}

.auth-promo { margin: -4px 0 12px; font-size: 0.78rem; line-height: 1.5; color: var(--ink-soft); }

/* всплывающее окно через 30 секунд */
.promo-pop { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 16px; opacity: 0; transition: opacity .25s ease; }
.promo-pop[hidden] { display: none; }
.promo-pop.is-open { opacity: 1; }
.promo-pop__back { position: absolute; inset: 0; background: rgba(17, 24, 39, 0.38); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.promo-pop__card { position: relative; width: 100%; max-width: 420px; padding: 36px 28px 26px; text-align: center; background: #fff; border: 1px solid var(--line); border-radius: 24px; box-shadow: 0 24px 60px rgba(110, 87, 229, 0.22); transform: translateY(14px) scale(.97); transition: transform .3s ease; overflow: hidden; }
.promo-pop__card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: linear-gradient(90deg, #8b78f0, var(--violet), #5340c9); }
.promo-pop.is-open .promo-pop__card { transform: none; }
.promo-pop__card h2 { margin: 0 0 12px; font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.35rem; line-height: 1.3; color: var(--ink); }
.promo-pop__card p { margin: 0 0 22px; font-size: 0.95rem; line-height: 1.6; color: var(--ink-soft); }
.promo-pop__card .btn { width: 100%; }
.promo-pop__note { display: block; margin-top: 14px; font-size: 0.82rem; color: var(--ink-faint); }
.promo-pop__x { position: absolute; top: 10px; right: 12px; width: 36px; height: 36px; border: 0; background: transparent; font-size: 1.6rem; line-height: 1; color: var(--ink-faint); cursor: pointer; border-radius: 50%; }
.promo-pop__x:hover { color: var(--ink); background: #f3f4f6; }
@media (prefers-reduced-motion: reduce) { .promo-pop, .promo-pop__card { transition: none; } }

/* разделитель категории и премиум-плашки */
.cat-divider { padding: 64px clamp(20px, 5vw, 72px) 0; border-top: 1px solid var(--line); text-align: center; }
.cat-divider h2 { margin: 0 auto; max-width: 900px; font-family: "Jura", sans-serif; font-weight: 500; font-size: clamp(1.4rem, 3.2vw, 2.1rem); line-height: 1.3; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink); }
.cat-divider h2::after { content: ""; display: block; width: 72px; height: 3px; margin: 18px auto 0; border-radius: 3px; background: linear-gradient(90deg, #f3d98b, #e0b24a, #f3d98b); }
#shaya.expert, #eva.expert { border-top: 0; }
#shaya.expert { padding-top: calc(var(--header-h) - 20px); }

.badge-premium {
  color: #4a3410;
  background: linear-gradient(135deg, #fff1c2 0%, #f3cf6e 48%, #e6b64d 100%);
  border: 1px solid #e0b24a;
  letter-spacing: 0.12em;
  box-shadow: 0 0 0 0 rgba(224, 178, 74, 0.45), 0 4px 14px rgba(224, 178, 74, 0.28);
  animation: premPulse 2.8s ease-in-out infinite;
  will-change: transform;
}
@keyframes premPulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(224, 178, 74, 0.40), 0 4px 14px rgba(224, 178, 74, 0.26); }
  50% { transform: scale(1.025); box-shadow: 0 0 0 7px rgba(224, 178, 74, 0), 0 6px 18px rgba(224, 178, 74, 0.42); }
}
@media (prefers-reduced-motion: reduce) { .badge-premium { animation: none; } }
@media (max-width: 480px) { .badge-premium { font-size: 0.62rem; letter-spacing: 0.04em; padding-left: 8px; padding-right: 8px; white-space: nowrap; } }

/* ===== База знаний: articles.html и article-*.html ===== */
.kb-search { position: relative; display: flex; align-items: center; max-width: 560px; margin: 0 auto 18px; }
.kb-search input { width: 100%; height: 52px; padding: 0 46px 0 48px; font: inherit; font-size: 1rem; color: var(--ink); background: #fff; border: 1px solid var(--line); border-radius: 16px; outline: none; transition: border-color .25s ease, box-shadow .25s ease; -webkit-appearance: none; appearance: none; }
.kb-search input::-webkit-search-cancel-button { display: none; }
.kb-search input:focus { border-color: var(--violet); box-shadow: 0 0 0 3px rgba(110, 87, 229, 0.14); }
.kb-search-ico { position: absolute; left: 6px; top: 6px; width: 40px; height: 40px; padding: 9px; border: 0; background: transparent; color: var(--ink-faint); cursor: default; border-radius: 12px; }
.kb-search-ico svg { width: 100%; height: 100%; display: block; }
.kb-clear { position: absolute; right: 8px; top: 8px; width: 36px; height: 36px; border: 0; background: transparent; font-size: 1.4rem; line-height: 1; color: var(--ink-faint); cursor: pointer; border-radius: 50%; }
.kb-clear:hover { color: var(--ink); background: #f3f4f6; }
.kb-tabs { display: flex; gap: 10px; margin: 0 0 18px; padding: 4px 2px 10px; overflow-x: auto; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.kb-tab { flex: none; display: inline-flex; flex-direction: column; align-items: flex-start; gap: 1px; padding: 9px 16px; font: inherit; font-size: 0.9rem; font-weight: 500; color: var(--ink-soft); background: #fff; border: 1px solid var(--line); border-radius: 14px; cursor: pointer; white-space: nowrap; transition: color .25s ease, border-color .25s ease, background .25s ease, box-shadow .25s ease; }
.kb-tab small { font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-faint); }
.kb-tab:hover { color: var(--violet); border-color: var(--violet); }
.kb-tab.is-active { color: #fff; background: linear-gradient(135deg, #7C68EC, #5B45D6); border-color: transparent; box-shadow: 0 8px 20px rgba(110, 87, 229, 0.25); }
.kb-tab.is-active small { color: rgba(255, 255, 255, 0.8); }
.kb-count { min-height: 1.3em; margin: 0 0 10px; font-size: 0.88rem; color: var(--ink-soft); text-align: center; }
.kb-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.kb-grid[hidden], .kb-empty[hidden] { display: none; }
.kb-card { position: relative; display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: 20px; overflow: hidden; transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease; }
.kb-card:hover, .kb-card:focus-within { transform: translateY(-4px); border-color: var(--pc, var(--violet)); box-shadow: 0 16px 36px rgba(110, 87, 229, 0.16); }
.kb-card-link { position: absolute; inset: 0; z-index: 2; border-radius: 20px; }
.kb-card-link:focus-visible { outline: 2px solid var(--violet); outline-offset: -2px; }
.kb-cover { aspect-ratio: 16 / 9; background: #f3f4f6; overflow: hidden; }
.kb-cover img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.kb-card:hover .kb-cover img { transform: scale(1.04); }
.kb-card-body { display: flex; flex-direction: column; flex: 1; gap: 10px; padding: 18px 20px 18px; }
.kb-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.kb-tag { display: inline-block; padding: 4px 10px; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--pc, var(--violet)); background: color-mix(in srgb, var(--pc, #6E57E5) 11%, #fff); border-radius: 8px; }
.kb-time { font-size: 0.8rem; color: var(--ink-soft); white-space: nowrap; }
.kb-card-title { margin: 0; font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.15rem; line-height: 1.35; color: var(--ink); }
.kb-card-text { margin: 0; font-size: 0.92rem; line-height: 1.55; color: var(--ink-soft); }
.kb-rec-row { display: flex; align-items: center; gap: 10px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); font-size: 0.82rem; color: var(--ink-soft); }
.kb-rec-row img { width: 36px; height: 36px; flex: none; border-radius: 50%; object-fit: cover; object-position: 50% 18%; border: 2px solid var(--pc, var(--violet)); background: #f3f4f6; }
.kb-empty { max-width: 560px; margin: 24px auto; padding: 28px 24px; text-align: center; background: #fff; border: 1px dashed #c9c2f5; border-radius: 20px; }
.kb-empty p { margin: 0 0 18px; line-height: 1.6; color: var(--ink-soft); }
@media (max-width: 1000px) { .kb-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  .kb-grid { grid-template-columns: 1fr; gap: 16px; }
  .kb-search { max-width: 52px; margin-left: auto; margin-right: 0; transition: max-width .3s ease; }
  .kb-search input { opacity: 0; pointer-events: none; padding-left: 48px; }
  .kb-search-ico { cursor: pointer; width: 52px; height: 52px; left: 0; top: 0; padding: 14px; border: 1px solid var(--line); border-radius: 16px; background: #fff; color: var(--violet); z-index: 1; }
  .kb-search.is-open { max-width: none; margin-right: auto; }
  .kb-search.is-open input { opacity: 1; pointer-events: auto; }
  .kb-search.is-open .kb-search-ico { border-color: transparent; background: transparent; }
}
@media (min-width: 641px) { .kb-search-ico { pointer-events: none; } }
@media (prefers-reduced-motion: reduce) { .kb-card, .kb-cover img { transition: none; } .kb-card:hover { transform: none; } }

.kb-back-wrap { max-width: 760px; }
.kb-article { max-width: 760px; margin: 0 auto; }
.kb-art-meta { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 12px; }
.kb-art-title { margin: 0 0 12px; font-family: "Jura", sans-serif; font-weight: 500; font-size: clamp(1.7rem, 4vw, 2.4rem); line-height: 1.2; letter-spacing: 0.02em; }
.kb-art-lead { margin: 0 0 20px; font-size: 1.08rem; line-height: 1.6; color: var(--ink-soft); }
.kb-art-cover { display: block; width: 100%; height: auto; margin: 0 0 24px; border-radius: 20px; border: 1px solid var(--line); }
.kb-art-body { font-size: 1.02rem; line-height: 1.75; color: #1f2937; }
.kb-art-body h2 { margin: 28px 0 10px; font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.3rem; letter-spacing: 0.02em; color: var(--ink); }
.kb-art-body p { margin: 0 0 14px; }
.kb-art-body ul, .kb-art-body ol { margin: 0 0 16px; padding-left: 1.3em; }
.kb-art-body li { margin-bottom: 8px; }
.kb-rec { display: grid; grid-template-columns: 64px 1fr; gap: 6px 16px; align-items: center; margin: 32px 0 16px; padding: 20px; background: color-mix(in srgb, var(--pc, #6E57E5) 7%, #fff); border: 1px solid color-mix(in srgb, var(--pc, #6E57E5) 28%, #fff); border-radius: 20px; }
.kb-rec img { grid-row: span 2; width: 64px; height: 64px; border-radius: 50%; object-fit: cover; object-position: 50% 18%; border: 2px solid var(--pc, var(--violet)); }
.kb-rec p { margin: 4px 0 0; font-size: 0.92rem; line-height: 1.5; color: var(--ink-soft); }
.kb-rec .btn { grid-column: 2; justify-self: start; }
.kb-rec .btn + .btn { margin-top: 2px; }
.kb-disc { margin: 12px 0 8px; font-size: 0.82rem; line-height: 1.55; color: var(--ink-faint); }
@media (max-width: 520px) { .kb-rec { grid-template-columns: 1fr; } .kb-rec img { grid-row: auto; } .kb-rec .btn { grid-column: auto; width: 100%; } }
.kb-search input { min-width: 0; }
@media (max-width: 640px) { .kb-search:not(.is-open) { overflow: hidden; } }
.kb-art-body h3 { margin: 22px 0 8px; font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.1rem; color: var(--ink); }
.kb-cta { margin: 26px 0; padding: 22px 22px 20px; background: linear-gradient(135deg, #F5F2FF, #FFFFFF); border: 1px solid #d9d2fa; border-left: 4px solid var(--pc, var(--violet)); border-radius: 18px; }
.kb-cta p { margin: 0 0 12px; }
.kb-cta-title { font-family: "Jura", sans-serif; font-weight: 600; font-size: 1.15rem; color: var(--ink); }
.kb-cta .btn { display: inline-flex; max-width: 100%; text-align: center; white-space: normal; height: auto; padding-top: 12px; padding-bottom: 12px; }
.kb-note { margin: 18px 0; padding: 14px 16px; font-size: 0.92rem; line-height: 1.6; color: var(--ink-soft); background: #FAF8FF; border: 1px solid #e4defa; border-radius: 14px; }
.kb-cta-label { display: inline-block; margin: 0 0 10px; padding: 3px 10px; font-size: 0.7rem; font-weight: 600; letter-spacing: 0.1em; color: #4a3410; background: linear-gradient(135deg, #fff1c2, #f3cf6e); border: 1px solid #e0b24a; border-radius: 8px; }
.kb-cta-note { margin: 10px 0 0 !important; font-size: 0.82rem; color: var(--ink-faint); }

/* Выравнивание по ширине в текстах публичных страниц */
.seo-text p, .faq-item p { text-align: justify; text-justify: inter-word; -webkit-hyphens: auto; hyphens: auto; }
@media (max-width: 480px) { .seo-text p, .faq-item p { text-align: left; -webkit-hyphens: manual; hyphens: manual; } .auth-promo { font-size: 0.76rem; } }

.cat-divider h2 .cat-ico { display: block; width: 40px; height: 40px; margin: 0 auto 14px; }

/* Иконка разделителя: «невесомость» и переливание */
.cat-divider h2 .cat-ico { overflow: visible; animation: catFloat 7s ease-in-out infinite, catGlow 4.5s ease-in-out infinite; will-change: transform, filter; }
.cat-ico .ci-star { transform-box: fill-box; transform-origin: center; animation: catPulse 5s ease-in-out infinite; }
.cat-ico .ci-dia { transform-box: fill-box; transform-origin: center; animation: catSpin 14s linear infinite, catDrift 6s ease-in-out infinite; }
.cat-ico .ci-dot { animation: catDrift 5s ease-in-out infinite reverse; }
@keyframes catFloat { 0%,100% { transform: translate(0,0) rotate(-4deg); } 25% { transform: translate(3px,-7px) rotate(3deg); } 50% { transform: translate(-2px,-12px) rotate(6deg); } 75% { transform: translate(-4px,-5px) rotate(-2deg); } }
@keyframes catGlow { 0%,100% { filter: drop-shadow(0 0 2px rgba(110,87,229,.25)) hue-rotate(0deg); } 50% { filter: drop-shadow(0 0 9px rgba(134,227,195,.6)) hue-rotate(-28deg); } }
@keyframes catPulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.1); } }
@keyframes catSpin { to { transform: rotate(360deg); } }
@keyframes catDrift { 0%,100% { translate: 0 0; } 50% { translate: 2px -3px; } }
@media (prefers-reduced-motion: reduce) { .cat-divider h2 .cat-ico, .cat-ico .ci-star, .cat-ico .ci-dia, .cat-ico .ci-dot { animation: none; } }
