/* Демо: бот записи в салон «Лён» */

:root {
  --linen: #f2eee8;
  --paper: #fbf9f6;
  --ink: #23262d;
  --ink-2: #5d636e;
  --blue: #5b7fa8;
  --blue-soft: #dfe8f2;
  --tg-bg: #c9d9c3;
  --tg-out: #e3f6cf;
  --line: #e2ddd5;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; background: var(--linen); color: var(--ink); font: 400 16px/1.5 "Onest", system-ui, sans-serif; }
h1, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }
button, input { font: inherit; color: inherit; }

.l-wrap { width: min(100% - 40px, 1240px); margin-inline: auto; }
.l-header-bar { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.l-logo { display: inline-flex; align-items: center; gap: 10px; font-size: 24px; font-weight: 700; letter-spacing: -0.04em; }
.l-logo i { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--ink); color: var(--paper); font-style: normal; font-size: 17px; }
.l-logo small { font-size: 14px; font-weight: 400; letter-spacing: 0; color: var(--ink-2); }
.l-pill { padding: 7px 14px; border-radius: 999px; background: var(--blue-soft); color: var(--blue); font-size: 14px; font-weight: 600; }

.l-main { display: grid; grid-template-columns: 1fr 390px 1fr; gap: 32px; align-items: start; padding: 24px 0 110px; }
.l-intro h1 { font-size: clamp(34px, 3.6vw, 52px); line-height: 1.02; letter-spacing: -0.05em; }
.l-lead { margin-top: 18px; color: var(--ink-2); }
.l-steps { display: grid; gap: 10px; margin: 28px 0; counter-reset: step; }
.l-steps li { display: flex; align-items: center; gap: 12px; font-weight: 500; counter-increment: step; }
.l-steps li::before { content: counter(step); display: grid; place-items: center; flex: none; width: 30px; height: 30px; border-radius: 50%;
  background: var(--paper); font-size: 14px; font-weight: 700; }
.l-btn { height: 48px; padding: 0 22px; border: 0; border-radius: 999px; background: var(--ink); color: var(--paper); font-weight: 600; cursor: pointer; }
.l-btn:hover { background: #3a3f49; }

/* Телефон с чатом */
.l-phone { display: flex; flex-direction: column; height: min(720px, calc(100vh - 190px)); min-height: 520px; overflow: hidden;
  border: 10px solid #1d1f24; border-radius: 44px; background: var(--tg-bg); box-shadow: 0 40px 80px -30px rgb(35 38 45 / 0.5); }
.l-phone-top, .l-admin-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: #fff; }
.l-phone-top b, .l-admin-head b { display: block; font-size: 15.5px; }
.l-phone-top small, .l-admin-head small { font-size: 13px; color: var(--ink-2); }
.l-avatar { display: grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--ink); color: var(--paper); font-weight: 700; }
.l-avatar-team { background: var(--blue-soft); }

.l-chat { flex: 1; display: flex; flex-direction: column; gap: 8px; overflow-y: auto; padding: 14px 12px;
  background: radial-gradient(circle at 20% 20%, rgb(255 255 255 / 0.25), transparent 40%), var(--tg-bg); scroll-behavior: smooth; }
.l-msg { max-width: 86%; padding: 9px 12px 7px; border-radius: 16px 16px 16px 4px; background: #fff; font-size: 14.5px; line-height: 1.42;
  white-space: pre-line; box-shadow: 0 1px 1px rgb(0 0 0 / 0.08); animation: l-in 0.25s ease both; }
.l-msg b { font-weight: 700; }
.l-msg time { display: block; margin-top: 2px; font-size: 11px; color: #8a9099; text-align: right; }
.l-msg-out { align-self: flex-end; border-radius: 16px 16px 4px 16px; background: var(--tg-out); }
.l-msg-note { align-self: center; max-width: 92%; padding: 5px 12px; border-radius: 999px; background: rgb(0 0 0 / 0.18); color: #fff;
  font-size: 12.5px; text-align: center; box-shadow: none; }
@keyframes l-in { from { opacity: 0; translate: 0 6px; } }
.l-inline { display: grid; gap: 4px; max-width: 86%; margin-top: -4px; animation: l-in 0.25s ease both; }
.l-inline-row { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; }
.l-inline button { min-height: 38px; padding: 6px 8px; border: 0; border-radius: 10px; background: rgb(255 255 255 / 0.72);
  font-size: 13.5px; font-weight: 500; line-height: 1.2; cursor: pointer; backdrop-filter: blur(4px); }
.l-inline button:hover { background: #fff; }
.l-inline button:disabled { opacity: 0.45; cursor: default; }
.l-typing { align-self: flex-start; padding: 10px 14px; border-radius: 16px; background: #fff; }
.l-typing i { display: inline-block; width: 6px; height: 6px; margin: 0 2px; border-radius: 50%; background: #9aa1ab; animation: l-dot 1s infinite; }
.l-typing i:nth-child(2) { animation-delay: 0.15s; }
.l-typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes l-dot { 50% { translate: 0 -4px; opacity: 0.5; } }

.l-keyboard { display: grid; gap: 6px; padding: 8px; background: #eef0f3; }
.l-keyboard[hidden] { display: none; }
.l-keyboard button { height: 44px; border: 0; border-radius: 10px; background: #fff; font-weight: 500; cursor: pointer; box-shadow: 0 1px 0 rgb(0 0 0 / 0.1); }
.l-input { display: flex; gap: 8px; padding: 8px 10px; background: #fff; }
.l-input input { flex: 1; min-width: 0; height: 40px; padding: 0 14px; border: 0; border-radius: 999px; background: #f1f2f4; font-size: 15px; }
.l-input input:focus { outline: 2px solid var(--blue); }
.l-input input:disabled { opacity: 0.6; }
.l-input button { display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--blue); cursor: pointer; }
.l-input button:disabled { background: #c3cad3; cursor: default; }
.l-input svg { width: 20px; height: 20px; fill: #fff; }

/* Чат администраторов */
.l-admin { overflow: hidden; border-radius: 24px; background: var(--paper); box-shadow: 0 20px 50px -30px rgb(35 38 45 / 0.4); }
.l-admin-head { border-bottom: 1px solid var(--line); }
.l-admin-feed { display: grid; gap: 10px; max-height: 560px; overflow-y: auto; padding: 14px; }
.l-admin-empty { padding: 28px 10px; color: var(--ink-2); font-size: 14.5px; text-align: center; }
.l-card { padding: 14px; border-radius: 16px; background: #fff; font-size: 14px; line-height: 1.5; white-space: pre-line;
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.06); animation: l-in 0.3s ease both; }
.l-card b { font-size: 15px; }
.l-card-status { display: block; margin-top: 8px; padding-top: 8px; border-top: 1px dashed var(--line); color: var(--ink-2); font-size: 13px; }
.l-card-actions { display: flex; gap: 6px; margin-top: 10px; }
.l-card-actions button { flex: 1; height: 36px; border: 0; border-radius: 10px; background: var(--blue-soft); color: var(--blue); font-size: 13.5px; font-weight: 600; cursor: pointer; }
.l-card-actions button:hover { background: #cfdcea; }
.l-card-cancel { background: #fdeaea; }

@media (max-width: 1100px) {
  .l-main { grid-template-columns: 1fr 390px; }
  .l-admin { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .l-wrap { width: min(100% - 32px, 1240px); }
  .l-main { grid-template-columns: 1fr; gap: 24px; }
  .l-phone { height: 640px; border-width: 8px; border-radius: 36px; }
  .l-pill { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
