/* Контентные страницы сайта: блог (/blog/), статьи блога и «Связаться» (/contact/).
   Шапка и подвал — общая оболочка (global-shell.css, site-sales-v3.css); здесь только содержимое
   и поправки шапки для этих страниц. Все классы начинаются с cp-. */

:root {
  --cp-ink: #21172f;
  --cp-copy: #4f475b;
  --cp-muted: #675e75;
  --cp-violet: #6b43e3;
  --cp-brand: #7050f5;
  --cp-lilac: #efe8ff;
  --cp-lilac-2: #f6f2ff;
  --cp-line: rgba(68, 42, 111, 0.12);
  --cp-coral: #ff7a4f;
  --cp-mint: #1f9d68;
  --cp-serif: Georgia, "Times New Roman", serif;
  --cp-shadow:
    0 34px 70px -34px rgba(62, 36, 128, 0.34),
    0 12px 26px -18px rgba(40, 22, 80, 0.22);
}

/* ---------- Шапка на этих страницах (как на /ios/) ---------- */

/* Разделы, переключатель продуктов, язык и кнопка по-французски помещаются в строку только от ~1200 px. */
@media (max-width: 1240px) {
  .content-page .mira-page-nav { display: none; }
  .content-page .nav-burger { display: inline-flex; }
  .content-page .mira-shell-actions { margin-left: auto; }
}

@media (max-width: 960px) {
  .content-page header.mira-global-header {
    width: min(calc(100% - 16px), 1280px);
    margin-right: auto;
    margin-left: auto;
    right: auto;
    left: auto;
  }
}

@media (max-width: 900px) {
  .content-page .mira-global-brand > span { display: none; }
}

@media (max-width: 760px) {
  .content-page .nav-burger {
    border: 0;
    background: linear-gradient(135deg, #8765ed, #6639d5);
    box-shadow: 0 10px 22px rgba(105, 61, 213, 0.22);
    color: #fff;
  }
}

@media (max-width: 480px) {
  .content-page header.mira-global-header .mira-product-switch { display: none; }
}

.content-page .mira-global-header .button,
.content-page .mira-mobile-menu-cta {
  background: linear-gradient(135deg, #7a5af0, #5a36d6);
}

.content-page .mira-product-switch a:not([aria-current]) {
  color: #655d74;
}

/* ---------- База ---------- */

.cp-main {
  color: var(--cp-ink);
  overflow-x: clip;
}

.cp-wrap {
  width: min(100% - 32px, 1200px);
  margin-inline: auto;
}

.cp-narrow {
  width: min(100% - 32px, 700px);
  margin-inline: auto;
}

.content-page h1,
.content-page h2,
.content-page h3 {
  margin: 0;
  color: var(--cp-ink);
  text-wrap: balance;
}

.content-page h1 em,
.content-page h2 em {
  font-family: var(--cp-serif);
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--cp-violet);
}

.cp-eyebrow {
  margin: 0 0 14px;
  color: var(--cp-violet);
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.cp-h1 {
  font-size: clamp(2.1rem, 1.3rem + 2.6vw, 3.4rem);
  line-height: 1.05;
  letter-spacing: -0.045em;
  font-weight: 850;
  overflow-wrap: break-word;
}

.cp-lead {
  max-width: 40rem;
  margin: 18px 0 0;
  color: var(--cp-copy);
  font-size: clamp(1.04rem, 0.98rem + 0.3vw, 1.18rem);
  line-height: 1.6;
}

.cp-lead a,
.cp-prose a,
.cp-muted-link {
  color: var(--cp-violet);
  font-weight: 700;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

.content-page a:focus-visible,
.content-page button:focus-visible,
.content-page input:focus-visible,
.content-page textarea:focus-visible,
.content-page select:focus-visible {
  outline: 3px solid rgba(107, 67, 227, 0.45);
  outline-offset: 3px;
}

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

.cp-skip {
  position: absolute;
  left: 16px;
  top: 12px;
  z-index: 2000;
  padding: 10px 14px;
  border-radius: 12px;
  background: var(--cp-ink);
  color: #fff;
  font-weight: 800;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 160ms ease;
}

.cp-skip:focus {
  transform: none;
}

.cp-btn {
  min-height: 52px;
  padding: 10px 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  border-radius: 14px;
  background: linear-gradient(135deg, #7a5af0 0%, #5a36d6 100%);
  box-shadow: 0 16px 30px -14px rgba(98, 60, 230, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.22);
  color: #fff;
  font: inherit;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: transform 200ms ease, box-shadow 200ms ease;
}

.cp-btn::after {
  content: "";
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-top: 2.4px solid currentColor;
  border-right: 2.4px solid currentColor;
  transform: rotate(45deg);
}

.cp-btn:hover {
  transform: translateY(-2px);
}

.cp-btn--ghost {
  background: #fff;
  box-shadow: inset 0 0 0 1.5px rgba(107, 67, 227, 0.3);
  color: var(--cp-violet);
}

/* ---------- Блог: список ---------- */

.cp-hero {
  padding-block: clamp(40px, 6vw, 80px) clamp(28px, 4vw, 48px);
}

.cp-posts {
  list-style: none;
  margin: 0;
  padding: 0 0 clamp(64px, 9vw, 110px);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(16px, 2vw, 26px);
}

.cp-post {
  min-width: 0;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--cp-line);
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 30px 60px -48px rgba(62, 36, 128, 0.55);
  overflow: hidden;
  transition: transform 220ms ease, box-shadow 220ms ease;
}

.cp-post:hover {
  transform: translateY(-3px);
  box-shadow: var(--cp-shadow);
}

.cp-post-art {
  position: relative;
  height: 150px;
  display: grid;
  place-items: center;
  background:
    radial-gradient(60% 80% at 20% 10%, rgba(255, 255, 255, 0.7), transparent 60%),
    linear-gradient(140deg, var(--a, #efe8ff) 0%, var(--b, #dccfff) 100%);
  color: var(--c, var(--cp-violet));
}

.cp-post-art svg {
  width: 64px;
  height: 64px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cp-post--photo .cp-post-art { --a: #fff1ea; --b: #ffd9c7; --c: #c2542f; }
.cp-post--diary .cp-post-art { --a: #efe8ff; --b: #d9cbff; --c: #6b43e3; }
.cp-post--health .cp-post-art { --a: #e6f5ee; --b: #c6ead8; --c: #1f7a52; }

.cp-post-body {
  padding: 22px 22px 24px;
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
}

.cp-post-meta {
  margin: 0;
  color: var(--cp-muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.cp-post h2 {
  margin-top: 10px;
  font-size: 1.28rem;
  line-height: 1.25;
  letter-spacing: -0.02em;
  font-weight: 850;
}

.cp-post h2 a {
  color: inherit;
  text-decoration: none;
}

/* Вся карточка кликабельна, но ссылка одна — заголовок. */
.cp-post h2 a::after {
  content: "";
  position: absolute;
  inset: 0;
}

.cp-post {
  position: relative;
}

.cp-post-excerpt {
  margin: 10px 0 0;
  color: var(--cp-copy);
  line-height: 1.6;
}

.cp-post-more {
  margin: auto 0 0;
  padding-top: 18px;
  color: var(--cp-violet);
  font-weight: 800;
}

/* ---------- Статья ---------- */

.cp-article {
  padding-block: clamp(28px, 4vw, 56px) clamp(56px, 8vw, 100px);
}

.cp-crumbs {
  margin: 0 0 22px;
  color: var(--cp-muted);
  font-size: 0.88rem;
  font-weight: 650;
}

.cp-crumbs a {
  color: var(--cp-violet);
  font-weight: 750;
  text-decoration: none;
}

.cp-crumbs a:hover {
  text-decoration: underline;
}

.cp-meta {
  margin: 16px 0 0;
  color: var(--cp-muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.cp-prose {
  margin-top: clamp(28px, 4vw, 40px);
  color: var(--cp-copy);
  font-size: 1.08rem;
  line-height: 1.75;
}

.cp-prose > * + * {
  margin-top: 1.05em;
}

.cp-prose p,
.cp-prose ul,
.cp-prose ol {
  margin-bottom: 0;
}

.cp-prose h2 {
  margin-top: 1.9em;
  font-size: clamp(1.35rem, 1.1rem + 0.8vw, 1.7rem);
  line-height: 1.2;
  letter-spacing: -0.025em;
  font-weight: 850;
}

.cp-prose h2 + * {
  margin-top: 0.7em;
}

.cp-prose ul,
.cp-prose ol {
  padding-left: 1.3em;
}

.cp-prose li + li {
  margin-top: 0.45em;
}

.cp-prose li::marker {
  color: var(--cp-violet);
  font-weight: 800;
}

.cp-prose strong {
  color: var(--cp-ink);
}

/* Сноска: цифра маленькая, а нажимать на неё удобно — поле касания 24×24. */
.cp-prose sup a {
  display: inline-block;
  min-width: 24px;
  min-height: 24px;
  text-align: center;
  text-decoration: none;
}

.cp-callout {
  padding: 18px 20px;
  border: 1px solid var(--cp-line);
  border-left: 4px solid var(--cp-violet);
  border-radius: 16px;
  background: var(--cp-lilac-2);
  color: var(--cp-ink);
}

.cp-callout p {
  margin: 0;
}

.cp-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--cp-line);
  border-radius: 18px;
  background: #fff;
}

.cp-prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.98rem;
  line-height: 1.45;
}

.cp-prose th,
.cp-prose td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--cp-line);
  text-align: left;
  vertical-align: top;
}

.cp-prose thead th {
  background: var(--cp-lilac-2);
  color: var(--cp-ink);
  font-size: 0.86rem;
  font-weight: 800;
}

.cp-prose tbody tr:last-child td {
  border-bottom: 0;
}

.cp-prose td:last-child {
  color: var(--cp-ink);
  font-weight: 800;
  white-space: nowrap;
}

/* Снимок экрана приложения в нейтральной рамке — целиком, без обрезки. */
.cp-figure {
  margin-block: 2em;
  display: grid;
  justify-items: center;
  gap: 12px;
}

.cp-phone {
  width: min(260px, 72vw);
  padding: 8px;
  border-radius: 42px;
  background: linear-gradient(150deg, #3a3150 0%, #17121f 40%, #0d0a13 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.1), var(--cp-shadow);
}

.cp-phone img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 34px;
}

.cp-figure figcaption {
  max-width: 32rem;
  color: var(--cp-muted);
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.5;
  text-align: center;
}

.cp-sources {
  margin-top: 2.4em !important;
  padding-top: 1.4em;
  border-top: 1px solid var(--cp-line);
  font-size: 0.9rem;
  line-height: 1.6;
}

.cp-sources h2 {
  margin: 0;
  font-size: 1rem;
  letter-spacing: 0;
}

.cp-sources ol {
  max-width: 34em;
  margin: 0.8em 0 0;
}

/* Призыв в конце статьи. */
.cp-cta {
  margin-top: clamp(36px, 5vw, 56px);
  padding: clamp(22px, 4vw, 36px);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 22px;
  border: 1px solid var(--cp-line);
  border-radius: 30px;
  background: linear-gradient(135deg, #f4efff 0%, #ffffff 55%, #fff4ee 100%);
  box-shadow: 0 30px 60px -48px rgba(62, 36, 128, 0.6);
}

.cp-cta img {
  width: 76px;
  height: 76px;
  border-radius: 22%;
  box-shadow: 0 20px 40px -18px rgba(80, 48, 200, 0.6);
}

.cp-cta h2 {
  font-size: clamp(1.3rem, 1.1rem + 0.7vw, 1.6rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-weight: 850;
}

.cp-cta p {
  margin: 8px 0 0;
  color: var(--cp-copy);
  line-height: 1.55;
}

.cp-cta-row {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
}

.cp-back {
  margin-top: 28px;
  font-weight: 750;
}

/* ---------- Связаться ---------- */

.cp-contact {
  padding-block: clamp(40px, 6vw, 80px) clamp(64px, 9vw, 110px);
}

.cp-contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: start;
  gap: clamp(28px, 5vw, 72px);
}

.cp-mail {
  margin-top: 28px;
  padding: 20px 22px;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  border: 1px solid var(--cp-line);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 24px 50px -40px rgba(62, 36, 128, 0.5);
}

.cp-mail-ico {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 15px;
  background: var(--cp-lilac);
  color: var(--cp-violet);
}

.cp-mail-ico svg,
.cp-tip svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cp-mail p {
  margin: 0;
  color: var(--cp-muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.cp-mail a {
  color: var(--cp-violet);
  font-size: 1.12rem;
  font-weight: 850;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  overflow-wrap: anywhere;
}

.cp-tips {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.cp-tip {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 12px;
  color: var(--cp-copy);
  line-height: 1.55;
}

.cp-tip svg {
  margin-top: 1px;
  color: var(--cp-violet);
}

.cp-form-card {
  padding: clamp(22px, 3.5vw, 36px);
  border: 1px solid var(--cp-line);
  border-radius: 30px;
  background: #fff;
  box-shadow: var(--cp-shadow);
}

.cp-form-card h2 {
  font-size: 1.4rem;
  letter-spacing: -0.02em;
  font-weight: 850;
}

.cp-form {
  margin-top: 20px;
  display: grid;
  gap: 16px;
}

.cp-field {
  display: grid;
  gap: 7px;
}

.cp-field label {
  color: var(--cp-ink);
  font-size: 0.9rem;
  font-weight: 800;
}

.cp-field input,
.cp-field textarea {
  width: 100%;
  box-sizing: border-box;
  min-height: 50px;
  padding: 12px 14px;
  border: 1.5px solid rgba(68, 42, 111, 0.18);
  border-radius: 14px;
  background: #fbfaff;
  color: var(--cp-ink);
  font: inherit;
  font-size: 1rem;
  line-height: 1.45;
  transition: border-color 160ms ease, background 160ms ease;
}

.cp-field textarea {
  min-height: 150px;
  resize: vertical;
}

.cp-field input:focus,
.cp-field textarea:focus {
  border-color: var(--cp-brand);
  background: #fff;
}

.cp-form[hidden] {
  display: none;
}

.cp-form .cp-btn {
  justify-self: start;
}

.cp-form-note {
  margin: 0;
  color: var(--cp-muted);
  font-size: 0.86rem;
  line-height: 1.5;
}

.cp-form-status {
  margin: 0;
  padding: 12px 14px;
  border-radius: 14px;
  background: #e6f5ee;
  color: #155c3d;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.5;
}

.cp-form-status[hidden] {
  display: none;
}

.cp-form-status.is-error {
  background: #fdecec;
  color: #8c1f1f;
}

.cp-nojs {
  margin: 18px 0 0;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--cp-lilac-2);
  color: var(--cp-ink);
  line-height: 1.55;
}

.cp-company {
  margin-top: 28px;
  padding-top: 20px;
  border-top: 1px solid var(--cp-line);
  color: var(--cp-muted);
  font-size: 0.9rem;
  line-height: 1.6;
}

.cp-company b {
  display: block;
  color: var(--cp-ink);
}

.sales-v3.content-page .site-footer,
.sales-v3.content-page .site-footer a {
  color: #5b5368;
}

.cp-footer .footer-links a {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
}

/* ---------- Адаптив ---------- */

@media (max-width: 960px) {
  .cp-posts {
    grid-template-columns: minmax(0, 1fr);
    max-width: 620px;
  }

  .cp-contact-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 560px) {
  .cp-cta {
    grid-template-columns: minmax(0, 1fr);
  }

  .cp-form .cp-btn {
    justify-self: stretch;
  }

  .cp-prose {
    font-size: 1.04rem;
  }
}

/* Цели касания на телефоне — не меньше 44 px. */
@media (max-width: 760px) {
  .cp-footer .footer-links {
    gap: 0 14px;
  }

  .cp-footer .footer-links a {
    min-width: 44px;
    min-height: 44px;
    justify-content: center;
  }

  .content-page .mira-global-brand img {
    width: 44px;
    height: 44px;
  }

  .content-page .nav-burger,
  .content-page .mira-global-header .lang-select {
    height: 44px;
    min-height: 44px;
  }

  .content-page .nav-burger {
    width: 44px;
  }

  .cp-back .cp-muted-link,
  .cp-cta-row .cp-muted-link,
  .cp-mail a {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cp-post,
  .cp-btn,
  .cp-skip {
    transition: none;
  }
}
