/* SolvAI — внутренние страницы: Возможности, Интеграции, Кейсы, База знаний */

.page-hero { position: relative; padding: clamp(32px, 5vw, 68px) 0 clamp(28px, 4vw, 56px); }
.page-hero::before { content: ""; position: absolute; z-index: -1; inset: -120px 0 auto; height: 760px; pointer-events: none; background: radial-gradient(44% 56% at 84% 30%, rgba(37, 224, 124, .22), rgba(37, 224, 124, 0) 72%), radial-gradient(36% 40% at 6% 0%, rgba(255, 255, 255, .95), rgba(255, 255, 255, 0) 70%); }
.page-hero-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: clamp(28px, 4vw, 64px); align-items: center; }
.page-hero-copy { display: grid; gap: 22px; justify-items: start; }
.page-hero-copy h1 { max-width: 13em; }
.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: .875rem; color: var(--ink-3); }
.crumbs a { color: var(--ink-2); text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 4px; }
.crumbs a:hover { color: var(--ink); text-decoration-color: var(--ink); }
.crumbs span::before { content: "/"; margin-right: 8px; color: var(--line); }
.jump { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.jump a { padding: 9px 16px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-size: .875rem; font-weight: 500; color: var(--ink-2); transition: color .2s, border-color .2s; }
.jump a:hover { color: var(--ink); border-color: var(--ink); }
.page-hero-visual { display: grid; place-items: center; }
.page-body { padding-bottom: clamp(24px, 4vw, 56px); }

/* ---------- Ряд «текст + интерфейс» ---------- */
.frow { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); gap: clamp(24px, 4vw, 64px); align-items: center; margin-bottom: 16px; scroll-margin-top: 110px; }
.frow.is-flip .frow-text { order: 2; }
.frow-text { display: grid; gap: 18px; align-content: center; justify-items: start; }
.frow-text h2 { font-size: clamp(1.625rem, 1.2rem + 1.6vw, 2.375rem); letter-spacing: -.03em; line-height: 1.1; }
.frow-text > p { color: var(--ink-2); }
.frow-visual { display: grid; place-items: center; align-content: center; gap: 12px; min-height: 400px; padding: clamp(18px, 3vw, 44px); border-radius: var(--r-l); background: var(--paper); }
.frow-visual > .small { text-align: center; }
.ticks { display: grid; gap: 12px; width: 100%; }
.ticks li { display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 12px; align-items: start; line-height: 1.4; }
.ticks .icon { width: 26px; height: 26px; padding: 5px; border-radius: 50%; background: var(--mint); color: var(--leaf); stroke-width: 2.6; }
.ticks b { display: block; font-weight: 550; }
.ticks span { display: block; margin-top: 2px; font-size: .9375rem; color: var(--ink-2); }
.fact { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 16px; align-items: center; width: 100%; padding-top: 20px; border-top: 1px solid var(--line); }
.fact b { font-size: clamp(2.25rem, 1.8rem + 1.6vw, 3rem); font-weight: 650; letter-spacing: -.045em; line-height: 1; color: var(--ink); white-space: nowrap; }
.fact span { font-size: .875rem; line-height: 1.4; color: var(--ink-2); }

/* ---------- Макет настроек ---------- */
.set { display: grid; gap: 14px; width: min(430px, 100%); padding: 20px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-m); }
.set-row { display: grid; gap: 6px; }
.set-row small { font-size: .75rem; color: var(--ink-3); }
.set-row p { padding: 10px 14px; border-radius: 12px; background: var(--paper); font-size: .875rem; line-height: 1.4; }
.set-swatches { display: flex; align-items: center; gap: 8px; }
.set-swatches i { width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--surface); outline: 1px solid var(--line); }
.set-swatches i.is-on { outline: 2px solid var(--ink); }
.set-swatches span { margin-left: auto; font-size: .75rem; font-weight: 500; padding: 5px 10px; border-radius: 999px; background: var(--mint); color: var(--leaf); }

/* ---------- Воронки ---------- */
.funnel { display: grid; gap: 14px; width: min(450px, 100%); }
.funnel-block { display: grid; gap: 12px; padding: 20px; border-radius: 20px; background: var(--surface); box-shadow: var(--shadow-s); }
.funnel-block small { font-size: .75rem; color: var(--ink-3); line-height: 1.4; }
.funnel-bar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 12px; font-size: .875rem; line-height: 1.3; }
.funnel-bar b { font-weight: 600; }
.funnel-bar i { grid-column: 1 / -1; display: block; height: 12px; width: var(--w); border-radius: 999px; background: var(--signal); transition: width 1.1s var(--ease); }
.funnel-bar.is-base i { background: var(--bar); }
.js [data-viz]:not(.is-in) .funnel-bar i { width: 0; }

/* ---------- Кейсы ---------- */
.case { display: grid; gap: clamp(22px, 3vw, 36px); margin-bottom: 16px; scroll-margin-top: 110px; }
.case-head { display: grid; gap: 16px; max-width: 880px; justify-items: start; }
.case-head h2 { font-size: clamp(1.75rem, 1.3rem + 1.8vw, 2.625rem); }
.case-head p { color: var(--ink-2); max-width: 44em; }
.case-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.case-col { display: grid; gap: 22px; align-content: start; }
.case-col h3, .case-col h4 { font-size: 1.25rem; letter-spacing: -.02em; }
.case-part { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(22px, 3vw, 36px); padding-top: clamp(24px, 3.4vw, 44px); border-top: 1px solid var(--line); scroll-margin-top: 110px; }
.case-part .case-head h3 { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.125rem); letter-spacing: -.03em; line-height: 1.12; }
.stat-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.stat-tile { display: grid; gap: 10px; align-content: start; padding: clamp(18px, 2vw, 24px); border-radius: 20px; background: var(--paper); }
.stat-tile b { font-size: clamp(2rem, 1.4rem + 2vw, 3.25rem); font-weight: 650; letter-spacing: -.05em; line-height: 1; white-space: nowrap; }
.stat-tile span { font-size: .875rem; line-height: 1.4; color: var(--ink-2); }
.stat-tile.is-signal { background: var(--signal); }
.stat-tile.is-signal span { color: var(--mint-ink); }
.insights { display: grid; gap: 14px; }
.insights li { display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 12px; line-height: 1.45; }
.insights .icon { width: 26px; height: 26px; padding: 5px; border-radius: 50%; background: var(--ink); color: var(--signal); stroke-width: 2.6; }
.shots { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.shot { display: block; overflow: hidden; border-radius: 16px; border: 1px solid var(--line); background: #fff; text-align: left; cursor: zoom-in; transition: border-color .2s, transform .25s var(--ease), box-shadow .25s; }
.shot:hover { border-color: var(--ink); transform: translateY(-2px); box-shadow: var(--shadow-m); }
.shot img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; object-position: left top; }
.shot span { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line); font-size: .8125rem; font-weight: 500; }
.shot .icon { width: 16px; height: 16px; color: var(--ink-3); }
.dialog-card { display: flex; flex-direction: column; gap: 8px; padding: 18px; border-radius: 28px; background: var(--paper); }
.dialog-card > small { font-size: .75rem; color: var(--ink-3); margin-bottom: 4px; }
.dialog-card .msg { font-size: .9375rem; }
.dialog-card .msg-ai { background: var(--surface); }
.method { padding-top: 18px; border-top: 1px solid var(--line); }
.method summary { display: flex; align-items: center; gap: 12px; width: fit-content; font-weight: 550; cursor: pointer; list-style: none; }
.method summary::-webkit-details-marker { display: none; }
.method summary::before { content: ""; width: 28px; height: 28px; border-radius: 50%; background: var(--paper) no-repeat center / 12px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M6 1v10M1 6h10' stroke='%230c1811' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E"); transition: transform .3s var(--ease); }
.method[open] summary::before { transform: rotate(45deg); }
.method-body { display: grid; gap: 10px; max-width: 62em; margin-top: 14px; font-size: .9375rem; line-height: 1.55; color: var(--ink-2); }
.method-body ul { display: grid; gap: 10px; }
.method-body b { color: var(--ink); }
.method-body li { padding-left: 18px; position: relative; }
.method-body li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 6px; height: 6px; border-radius: 50%; background: var(--ink-3); }
.data-table { width: 100%; border-collapse: collapse; font-size: .9375rem; }
.data-table th, .data-table td { padding: 12px 10px 12px 0; text-align: left; border-bottom: 1px solid var(--line); line-height: 1.35; }
.data-table thead th { font-size: .8125rem; font-weight: 500; color: var(--ink-3); }
.data-table td.num, .data-table th.num { text-align: right; padding-right: 0; }
.data-table td.num { white-space: nowrap; }
.data-table thead th { vertical-align: bottom; }
.data-table tbody th { font-weight: 550; }
.data-table tr.is-chat td, .data-table tr.is-chat th { background: var(--mint-2); }
.data-table tr.is-chat th { padding-left: 10px; border-radius: 12px 0 0 12px; }
.data-table tr.is-chat td:last-child { padding-right: 10px; border-radius: 0 12px 12px 0; }

/* ---------- Поиск по базе знаний ---------- */
.retr { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(20px, 3vw, 48px); align-items: start; }
.retr-side { display: grid; gap: 18px; align-content: start; }
.retr-side h2 { font-size: clamp(1.625rem, 1.2rem + 1.6vw, 2.375rem); }
.retr-side > p { color: var(--ink-2); }
.retr-queries { display: grid; gap: 8px; justify-items: end; }
.retr-queries button { padding: 14px 20px; border-radius: 20px 20px 6px 20px; background: var(--surface); border: 1.5px solid var(--line); font-size: 1rem; font-weight: 500; line-height: 1.3; text-align: left; transition: background-color .2s, border-color .2s; }
.retr-queries button:hover { border-color: var(--ink); }
.retr-queries button[aria-pressed="true"] { background: var(--signal); border-color: var(--signal); }
.retr-stage { display: grid; gap: 10px; padding: clamp(16px, 2.6vw, 36px); border-radius: var(--r-l); background: var(--paper); }
.retr-stage .kb { width: 100%; }
.retr-stage .kb-docs li { transition: background-color .3s, border-color .3s, color .3s; }
.retr-stage .kb-docs li small { display: none; }
.retr-stage .kb-docs li.is-hit small { display: block; }
.msg-kb.is-miss { color: var(--cost); }

/* ---------- Шаги и карточки ---------- */
.steps3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.steps3 li { display: grid; gap: 12px; align-content: start; padding: clamp(22px, 2.4vw, 32px); border-radius: var(--r-l); background: var(--surface); }
.steps3 li > span { width: 48px; height: 48px; border-radius: 50%; background: var(--paper); display: grid; place-items: center; font-size: 1.25rem; font-weight: 650; }
.steps3 p { color: var(--ink-2); font-size: 1rem; }
.next { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.next a { display: grid; gap: 10px; align-content: start; padding: clamp(22px, 2.4vw, 30px); border-radius: var(--r-l); background: var(--surface); transition: transform .25s var(--ease), box-shadow .25s; }
.next a:hover { transform: translateY(-3px); box-shadow: var(--shadow-m); }
.next b { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 1.25rem; font-weight: 600; letter-spacing: -.02em; }
.next span { color: var(--ink-2); font-size: .9375rem; line-height: 1.45; }
.next .icon { transition: transform .25s var(--ease); }
.next a:hover .icon { transform: translateX(4px); }
.checklist { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.checklist li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px 14px; align-items: center; align-content: start; padding: clamp(22px, 2.4vw, 30px); border-radius: var(--r-l); background: var(--surface); }
.checklist p { grid-column: 1 / -1; color: var(--ink-2); font-size: 1rem; }

/* ---------- Сводка кейсов, цепочка, макет сайта, список материалов ---------- */
.hero-stats { width: 100%; padding: clamp(20px, 3vw, 36px); border-radius: var(--r-l); }
.hero-stats li { display: grid; grid-template-columns: minmax(0, 132px) minmax(0, 1fr); gap: 16px; align-items: center; padding: 18px 0; border-top: 1px solid var(--line); }
.hero-stats li:first-child { border-top: 0; padding-top: 4px; }
.hero-stats li:last-child { padding-bottom: 4px; }
.hero-stats b { font-size: clamp(2.25rem, 1.6rem + 2vw, 3.25rem); font-weight: 650; letter-spacing: -.05em; line-height: 1; }
.hero-stats span { font-size: .9375rem; line-height: 1.4; color: var(--ink-2); }
.page-hero-visual .loop-flow { width: 100%; padding: clamp(18px, 2.6vw, 32px); border-radius: var(--r-l); }
.topic.is-base .bar-fill { background: var(--bar); }
.chain { display: grid; gap: 8px; width: min(430px, 100%); }
.chain li { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 14px; align-items: center; padding: 14px 16px; border-radius: 20px; background: var(--surface); box-shadow: var(--shadow-s); }
.chain-n { width: 40px; height: 40px; border-radius: 50%; background: var(--paper); display: grid; place-items: center; font-size: 1rem; font-weight: 650; }
.chain b { display: block; font-size: 1rem; line-height: 1.25; }
.chain small { display: block; margin-top: 2px; font-size: .8125rem; line-height: 1.35; color: var(--ink-3); }
.chain li.is-signal { background: var(--signal); }
.chain li.is-signal small { color: var(--mint-ink); }
.chain li.is-signal .chain-n { background: var(--surface); }
.sitemock { position: relative; width: min(460px, 100%); min-height: 330px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-m); overflow: hidden; }
.sitemock-page { display: grid; gap: 12px; width: 58%; padding: 28px 0 0 26px; }
.sitemock-bubble { position: absolute; right: 16px; bottom: 78px; max-width: 220px; padding: 10px 14px; border-radius: 20px 20px 6px 20px; background: var(--paper); font-size: .8125rem; line-height: 1.35; }
.sitemock-launch { position: absolute; right: 16px; bottom: 16px; display: flex; align-items: center; gap: 10px; height: 50px; padding: 0 18px 0 8px; border-radius: 999px; background: var(--ink); color: #fff; font-size: .875rem; font-weight: 550; }
.sitemock-launch .orb { width: 36px; height: 36px; border-radius: 50%; background: var(--signal); display: grid; place-items: center; }
.sitemock-launch .orb svg { width: 20px; height: 20px; }
.files { display: grid; gap: 6px; width: 100%; padding: clamp(16px, 2.4vw, 28px); border-radius: var(--r-l); }
.files li { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; border-radius: 16px; border: 1.5px solid transparent; }
.files .icon { width: 22px; height: 22px; margin-top: 1px; color: var(--ink-3); }
.files b { display: block; font-size: 1rem; line-height: 1.3; }
.files small { display: block; margin-top: 2px; font-size: .8125rem; line-height: 1.35; color: var(--ink-3); }
.files li.is-hit { margin-top: 6px; background: var(--mint); border-color: var(--signal-press); }
.files li.is-hit .icon { color: var(--leaf); }
.files li.is-hit small { color: var(--mint-ink); }
.shot { width: 100%; }
.frow-visual > .shot { max-width: 520px; }

@media (max-width: 1000px) {
  .page-hero-grid, .frow, .case-grid, .retr { grid-template-columns: minmax(0, 1fr); }
  .frow.is-flip .frow-text { order: 0; }
  .frow-visual { min-height: 0; }
  .retr-queries { justify-items: start; }
}
@media (max-width: 760px) {
  .steps3, .next, .checklist { grid-template-columns: minmax(0, 1fr); }
  .stat-tiles { grid-template-columns: minmax(0, 1fr); }
  .stat-tile { grid-template-columns: minmax(0, 40%) minmax(0, 1fr); align-items: center; }
  .data-table { font-size: .875rem; }
}
