/* Iris · «Бот для клиентов» — концепт студии Dorvan. Палитра и шрифты — как у демо салона (../350-salon). */

/* ---------- Шрифты (лежат рядом, без внешних запросов) ---------- */
@font-face { font-family: "Playfair Display"; font-style: normal; font-weight: 500; font-display: swap; src: url(fonts/playfair-display-cyrillic-500-normal.woff2) format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Playfair Display"; font-style: normal; font-weight: 500; font-display: swap; src: url(fonts/playfair-display-latin-500-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: "Playfair Display"; font-style: italic; font-weight: 500; font-display: swap; src: url(fonts/playfair-display-cyrillic-500-italic.woff2) format("woff2"); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Playfair Display"; font-style: italic; font-weight: 500; font-display: swap; src: url(fonts/playfair-display-latin-500-italic.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-variations"); 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-variations"); 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 {
  --cream: #fbf5ef; --cream-2: #f6ece3; --blush: #f3e1da; --rose: #e8c6bb; --rose-ink: #9c4a40;
  --plum: #2b1a28; --plum-2: #4d3849; --muted: #6a5662; --gold-soft: #dcc296;
  --line: rgb(43 26 40 / 0.14);
  /* мессенджер: свои цвета, синий оттенок только у пузырьков и кнопок чата */
  --chat: #e3eaf0; --in: #fff; --out: #25628f; --ink-b: #1d4f78; --line-b: #b4cadc; --muted-b: #52606c;
  --focus: #1b4b75;
  --ease: cubic-bezier(0.22, 0.8, 0.24, 1);
  --f-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --f-body: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --vh: 1vh; /* 1% высоты экрана; ниже — «малая» высота без прыгающей адресной строки */
  --ph: clamp(420px, calc(100 * var(--vh) - 226px), 760px); /* высота телефона на узком экране */
}
@supports (height: 100svh) { :root { --vh: 1svh; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-bottom: 88px; } /* когда страница сама прокручивает к кнопке, та не прячется за плашкой студии */
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { margin: 0; background: var(--plum); color: var(--plum); font-family: var(--f-body); font-size: 17px; line-height: 1.6; overflow-x: clip; -webkit-font-smoothing: antialiased; }
h1, h2, h3, p, ul, ol, dl, dd { margin: 0; }
.top, main { background: var(--cream); } /* фон страницы светлый, а за подвалом (под плашкой студии) продолжается тёмный */
ul, ol { padding: 0; list-style: none; }
h1, h2, h3 { font-family: var(--f-display); font-weight: 500; letter-spacing: -0.01em; line-height: 1.12; text-wrap: balance; }
p { text-wrap: pretty; }
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
.h1 em, .h2 em { font-family: var(--f-display); font-style: italic; font-weight: 500; color: var(--rose-ink); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -80px; z-index: 300; background: var(--plum); color: var(--cream); padding: 12px 18px; border-radius: 12px; }
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: 1240px; margin-inline: auto; padding-inline: 16px; }
@media (min-width: 640px) { .wrap { padding-inline: 32px; } }
@media (min-width: 1024px) { .wrap { padding-inline: 48px; } }

.eyebrow { font-size: 13px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--rose-ink); }
.h1 { margin-top: 14px; font-size: clamp(46px, 8vw, 80px); line-height: 1.02; }
.h2 { margin-top: 10px; font-size: clamp(30px, 4.2vw, 52px); line-height: 1.06; }
.lead { margin-top: 18px; max-width: 46ch; font-size: clamp(17px, 1.5vw, 20px); line-height: 1.55; color: var(--plum-2); }

/* ---------- Кнопки ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 26px; border: 1.5px solid transparent; border-radius: 999px; font: 600 16px/1.25 var(--f-body); text-decoration: none; text-align: center; transition: transform 0.2s var(--ease), background-color 0.2s, color 0.2s, border-color 0.2s; }
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.btn:active { transform: scale(0.97); }
.btn--primary { background: var(--plum); color: var(--cream); }
.btn--primary:hover { background: #482743; }
.btn--rose { background: var(--rose); color: var(--plum); }
.btn--rose:hover:not(:disabled) { background: #f0d4ca; }
.btn--ghost { border-color: rgb(43 26 40 / 0.5); color: var(--plum); }
.btn--ghost:hover { background: var(--plum); border-color: var(--plum); color: var(--cream); }
.btn:disabled { background: #efe3dd; color: #6f5c68; cursor: not-allowed; }

/* ---------- Верх и первый экран ---------- */
.top__row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 60px; }
.logo { display: inline-flex; align-items: center; gap: 8px; font: 500 28px/1 var(--f-display); }
.logo svg { color: var(--rose-ink); }
.top__link { display: inline-flex; align-items: center; min-height: 44px; padding: 0 4px; font-size: 15px; font-weight: 600; color: var(--plum-2); text-underline-offset: 4px; }

.hero { position: relative; overflow: clip; padding: 12px 0 56px; }
.hero::before { content: ""; position: absolute; right: -12%; top: -10%; width: 70%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(closest-side, rgb(232 198 187 / 0.45), transparent); pointer-events: none; }
.hero__grid { position: relative; display: grid; gap: 36px; align-items: center; }
.plaque { display: flex; align-items: flex-start; gap: 12px; margin-top: 22px; max-width: 520px; padding: 14px 16px; border: 1.5px solid var(--gold-soft); border-radius: 16px; background: #fff; font-size: 15px; line-height: 1.45; }
.plaque svg { flex: none; width: 24px; height: 24px; margin-top: 1px; fill: none; stroke: var(--rose-ink); stroke-width: 1.9; stroke-linecap: round; }
.hero .btn { margin-top: 26px; }
.hero__art { display: none; position: relative; }
.hero__art::before { content: ""; position: absolute; inset: -16px -26px 20px 26px; z-index: -1; border: 1.5px solid var(--gold-soft); border-radius: 999px 999px 0 0; opacity: 0.8; }
.mini { width: min(100%, 340px); margin-inline: auto; overflow: hidden; border: 9px solid var(--plum); border-radius: 40px; background: var(--chat); box-shadow: 0 40px 70px -40px rgb(43 26 40 / 0.55); }
.mini__log { display: flex; flex-direction: column; gap: 6px; padding: 12px 10px 16px; }
@media (min-width: 900px) {
  .hero { padding: 20px 0 80px; }
  .hero__grid { grid-template-columns: 1.15fr 0.85fr; gap: 56px; }
  .hero__art { display: block; }
}

/* ---------- Блок с чатом ---------- */
.demo { padding: 36px 0 48px; background: var(--cream-2); }
.demo__grid { display: grid; gap: 18px; }
.demo__head .h2 { font-size: clamp(28px, 2.4vw, 34px); }
.demo__sub { margin-top: 8px; font-size: 15px; color: var(--muted); }

.steps { display: grid; gap: 6px; margin-top: 14px; counter-reset: st; }
.steps li { display: flex; align-items: flex-start; gap: 12px; padding: 8px 12px; border-radius: 14px; background: rgb(255 255 255 / 0.5); font-size: 14.5px; line-height: 1.4; color: var(--plum-2); counter-increment: st; }
.steps li::before { content: counter(st); flex: none; display: grid; place-items: center; width: 26px; height: 26px; border: 1.5px solid rgb(43 26 40 / 0.4); border-radius: 50%; font-size: 13px; font-weight: 700; }
.steps li.is-done { color: var(--muted); }
.steps li.is-done::before { content: "\2713"; border-color: #3f7a56; background: #3f7a56; color: #fff; }
.steps li[aria-current="step"] { background: #fff; color: var(--plum); font-weight: 600; box-shadow: inset 0 0 0 1.5px var(--rose-ink); }
.steps li[aria-current="step"]::before { border-color: var(--rose-ink); background: var(--rose-ink); color: #fff; }

.stage { scroll-margin-top: 10px; }
.seg { display: flex; gap: 4px; max-width: 430px; margin: 0 auto 10px; padding: 4px; border: 1.5px solid var(--line); border-radius: 999px; background: #fff; }
.seg__b { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; border-radius: 999px; font-size: 15px; font-weight: 600; color: var(--plum-2); }
.seg__b[aria-pressed="true"] { background: var(--plum); color: var(--cream); }
.seg__n { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--rose-ink); color: #fff; font-size: 12.5px; font-weight: 700; }

.phones { display: grid; justify-items: center; }
.phone { width: 100%; max-width: 430px; }
.phone__cap { display: none; }
.frame { display: flex; flex-direction: column; height: var(--ph); overflow: hidden; border: 1px solid rgb(43 26 40 / 0.25); border-radius: 26px; background: var(--chat); box-shadow: 0 24px 50px -30px rgb(43 26 40 / 0.5); }
@media (max-width: 899.98px) {
  .phones[data-view="client"] .phone[data-who="owner"], .phones[data-view="owner"] .phone[data-who="client"] { display: none; }
}

.head, .mini__head { flex: none; display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid #d5dee6; background: #fff; }
.ava { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--plum); color: var(--rose); }
.who { display: grid; min-width: 0; line-height: 1.25; }
.who b { font-size: 16px; font-weight: 700; }
.who small { font-size: 13px; color: var(--muted-b); }

.log { position: relative; flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 6px; padding: 12px 10px 14px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; background: var(--chat); }
.log:focus-visible { outline-offset: -3px; border-radius: 0; }

.bar { flex: none; padding: 8px 10px; border-top: 1px solid #d5dee6; background: #fff; }
.startbtn { width: 100%; min-height: 48px; border-radius: 12px; background: var(--out); color: #fff; font-size: 15px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; transition: background-color 0.15s; }
.startbtn:hover { background: #1d5278; }
.fake { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; padding: 0 14px; border-radius: 22px; background: #eef2f5; color: #566470; font-size: 14.5px; }
.fake i { font-style: normal; font-size: 12.5px; text-align: right; }

/* сообщения */
.msg { display: grid; gap: 5px; min-width: 0; max-width: 92%; }
.msg--bot { align-self: flex-start; width: fit-content; }
.msg--me { align-self: flex-end; width: fit-content; max-width: 80%; }
.msg--wide { width: 92%; }
.bubble { position: relative; min-width: 68px; padding: 8px 13px 21px; border-radius: 18px 18px 18px 6px; background: var(--in); box-shadow: 0 1px 2px rgb(43 26 40 / 0.12); font-size: 15.5px; line-height: 1.42; }
.msg--me .bubble { border-radius: 18px 18px 6px 18px; background: var(--out); color: #fff; }
.bubble__text { white-space: pre-line; overflow-wrap: anywhere; }
.bubble__note { margin-top: 8px; font-size: 13px; line-height: 1.35; color: var(--muted-b); }
.bubble__time { position: absolute; right: 10px; bottom: 4px; font-size: 11.5px; line-height: 1; color: var(--muted-b); }
.msg--me .bubble__time { color: #dbe9f5; }

.chip { align-self: center; margin: 6px 0 2px; padding: 3px 12px; border-radius: 999px; background: #5a4a5a; color: #fff; font-size: 12.5px; font-weight: 600; }
.intro { align-self: center; display: grid; justify-items: center; gap: 6px; max-width: 92%; margin: 6px 0; padding: 16px 16px 14px; border-radius: 18px; background: rgb(255 255 255 / 0.75); text-align: center; font-size: 14.5px; line-height: 1.4; color: var(--plum-2); }
.intro .ava { width: 56px; height: 56px; }
.intro b { font-size: 16px; color: var(--plum); }
.typing { align-self: flex-start; display: flex; gap: 4px; padding: 12px 14px; border-radius: 18px 18px 18px 6px; background: var(--in); box-shadow: 0 1px 2px rgb(43 26 40 / 0.12); }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: #7a8895; animation: blink 1s infinite ease-in-out; }
.typing i:nth-child(2) { animation-delay: 0.15s; }
.typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes blink { 0%, 60%, 100% { opacity: 0.35; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }
@keyframes pop { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: no-preference) { .log .msg.is-new { animation: pop 0.22s var(--ease); } } /* только у только что пришедших, чтобы при переключении телефонов старые не «подпрыгивали» */

/* кнопки под сообщением (inline-кнопки) */
.kb { display: grid; gap: 5px; }
.kb__row { display: flex; flex-wrap: wrap; gap: 5px; }
.kbtn { flex: 1 1 0; display: inline-flex; align-items: center; justify-content: center; min-width: min-content; min-height: 44px; padding: 8px 10px; border: 1.5px solid var(--line-b); border-radius: 12px; background: rgb(255 255 255 / 0.94); color: var(--ink-b); font: 600 14.5px/1.2 var(--f-body); text-align: center; overflow-wrap: break-word; transition: background-color 0.15s, transform 0.15s; }
button.kbtn:hover { background: #eef5fb; }
button.kbtn:active { transform: scale(0.98); }
.kb.is-used { pointer-events: none; }
.kb.is-used .kbtn { border-color: #cddae5; background: #e9eff4; color: #4e5d6a; }
.kb.is-used .kbtn.is-picked { border-color: var(--out); background: var(--out); color: #fff; }
.kbtn.is-picked::before { content: "\2713"; margin-right: 6px; }

/* карточки внутри сообщения: отчёт, база клиентов, рассылка */
.dl { margin-top: 8px; display: grid; }
.dl div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0 14px; padding: 6px 0; border-top: 1px solid #e3e9ee; font-size: 14.5px; }
.dl dt { color: var(--muted-b); }
.dl dd { margin-left: auto; font-weight: 700; text-align: right; white-space: nowrap; }
.people { margin-top: 8px; display: grid; }
.people li { display: grid; grid-template-columns: 1fr auto; gap: 0 10px; padding: 8px 0; border-top: 1px solid #e3e9ee; font-size: 14.5px; line-height: 1.35; }
.people span { font-size: 13.5px; color: var(--muted-b); }
.people .r { text-align: right; }
.tag { display: inline-block; margin-left: 2px; padding: 1px 8px; border-radius: 999px; background: var(--blush); color: #7d3a31; font-size: 11.5px; font-weight: 700; vertical-align: 1px; }
.compose { margin-top: 8px; display: grid; gap: 8px; }
.compose label { font-size: 14.5px; font-weight: 700; }
.compose textarea { width: 100%; min-height: 96px; resize: vertical; padding: 10px 12px; border: 1.5px solid var(--line-b); border-radius: 12px; background: #fff; color: var(--plum); font: 16px/1.4 var(--f-body); }
.compose__c { font-size: 13px; text-align: right; color: var(--muted-b); }
.compose__e { font-size: 13.5px; font-weight: 600; color: #a02d2d; }
.compose__e:empty { display: none; }
.compose__b { min-height: 48px; padding: 8px 12px; border-radius: 12px; background: var(--out); color: #fff; font: 700 15px/1.25 var(--f-body); }
.compose__b:hover { background: #1d5278; }
.compose.is-sent textarea { background: #f3f6f8; }
.compose.is-sent .compose__b { background: #e9eff4; color: #4e5d6a; cursor: default; }

/* кнопки под телефоном */
.actions { display: flex; flex-wrap: wrap; gap: 10px; }
.actions .btn { min-height: 56px; border-radius: 28px; }
#rewind { flex: 1 1 260px; flex-direction: column; gap: 2px; padding: 8px 18px; }
#rewind small { font-size: 12.5px; font-weight: 600; }
.actions .btn span { text-wrap: balance; }
#reset { flex: 0 0 auto; }
@media (max-width: 899.98px) { /* на телефоне обе кнопки в один ряд, чтобы помещались под чатом */
  .actions { flex-wrap: nowrap; }
  #rewind { flex: 1 1 0; min-width: 0; padding: 8px 12px; font-size: 14px; }
  #reset { padding: 0 16px; }
}

/* ---------- Что умеет, как работает ---------- */
.section { padding: 64px 0; }
.section--blush { background: var(--cream-2); }
.section__head { max-width: 62ch; margin-bottom: 32px; }
.section__head .lead { margin-top: 14px; }
.feats { display: grid; gap: 14px; }
.feats li { padding: 22px; border-radius: 22px; background: #fff; box-shadow: 0 20px 40px -32px rgb(43 26 40 / 0.5); }
.feats svg { width: 30px; height: 30px; fill: none; stroke: var(--rose-ink); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.feats h3, .how h3 { font: 700 19px/1.25 var(--f-body); letter-spacing: 0; } /* мелкие заголовки — без тонких засечек (у «е» пропадает перекладина) */
.feats h3 { margin-top: 12px; }
.feats p { margin-top: 6px; font-size: 15.5px; line-height: 1.5; color: var(--plum-2); }
.how { display: grid; gap: 12px; counter-reset: s; }
.how li { position: relative; padding: 20px 20px 20px 72px; border-radius: 22px; background: #fff; counter-increment: s; }
.how li::before { content: counter(s); position: absolute; left: 20px; top: 20px; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: var(--plum); color: var(--cream); font: 500 20px/1 var(--f-display); }
.how p { margin-top: 4px; font-size: 15.5px; line-height: 1.5; color: var(--plum-2); }
.honest { margin-top: 22px; font-weight: 600; }

.foot { background: var(--plum); color: var(--cream); }
.foot__row { display: flex; flex-direction: column; gap: 4px; padding-block: 18px; font-size: 14.5px; }
.foot a { display: inline-flex; align-items: center; min-height: 44px; color: #fff; text-underline-offset: 4px; }
.foot :focus-visible { outline-color: #fff; }

/* ---------- Широкие экраны ---------- */
@media (min-width: 640px) { .feats { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) {
  .demo { padding: 64px 0 72px; }
  .demo__grid { gap: 28px; }
  .seg { display: none; }
  .phones { grid-template-columns: repeat(2, minmax(0, 364px)); gap: 28px; justify-content: center; }
  .phone { max-width: none; }
  .phone__cap { display: block; margin-bottom: 10px; font: 700 13px/1.2 var(--f-body); letter-spacing: 0.12em; text-align: center; text-transform: uppercase; color: var(--muted); }
  .frame { height: min(700px, calc(100 * var(--vh) - 200px)); min-height: 520px; border: 9px solid var(--plum); border-radius: 44px; box-shadow: 0 40px 70px -40px rgb(43 26 40 / 0.55); }
  .actions { justify-content: center; }
  .actions .btn { flex: 0 1 auto; }
  #rewind { flex: 0 1 420px; }
  .section { padding: 96px 0; }
  .how { grid-template-columns: repeat(3, 1fr); }
  .how li { padding: 76px 22px 24px; }
  .how li::before { left: 22px; top: 22px; }
  .foot__row { flex-direction: row; align-items: center; justify-content: space-between; }
}
@media (min-width: 1000px) { .feats { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1240px) {
  .frame { height: min(700px, calc(100 * var(--vh) - 110px)); min-height: 560px; }
  .demo__grid { grid-template-columns: 330px auto; grid-template-areas: "head stage" "actions stage"; grid-template-rows: auto 1fr; justify-content: center; column-gap: 48px; }
  .demo__head { grid-area: head; }
  .stage { grid-area: stage; }
  .actions { grid-area: actions; align-self: start; justify-content: stretch; }
  .actions .btn { flex: 1 1 100%; }
}

/* пока список шагов не помещается слева от телефонов, виден только текущий шаг */
@media (max-width: 1239.98px) { .steps li:not([aria-current]) { display: none; } }
@media (max-width: 420px) { .logo { font-size: 26px; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
