/* ==========================================================================
   V4 — единая бежевая тема порталов, ссылки в чате, состояние play, фиксы
   ========================================================================== */

/* карточка портала: не обрезать длинные слова (Беззаботность) */
.portal-btn__name {
  font-size: clamp(.72rem, 2.4vw, .8rem);
  letter-spacing: 0;
  hyphens: auto;
  overflow-wrap: anywhere;
  word-break: normal;
}

/* ---------- единая бежевая тема с разлиновкой (для всех порталов) ---------- */
.chat-stage[data-theme="paper"] {
  background-color: var(--c-cream);
  background-image: var(--paper-cream);
  background-size: 900px;
  --stage-ink: var(--c-dark);
  --stage-accent: var(--c-terracotta);
  --bubble-in: rgba(255, 255, 255, .74);
  --bubble-out: var(--c-terracotta);
  --bubble-out-ink: var(--c-cream);
  --kbtn-bg: rgba(28, 24, 20, .05);
  --kbtn-border: rgba(28, 24, 20, .18);
}
.chat-stage[data-theme="paper"] .stage-guest {
  background: repeating-linear-gradient(to bottom, transparent 0 27px, rgba(28, 24, 20, .09) 27px 28px);
  opacity: 1;
}
.chat-stage[data-theme="paper"] .chat-head {
  background: rgba(28, 24, 20, .82);
}
.chat-stage[data-theme="paper"] .chat-head__meta b { color: #fff; }
.chat-stage[data-theme="paper"] .kb__btn:hover { background: rgba(28, 24, 20, .1); }
.chat-stage[data-theme="paper"] .msg--audio .audio-slot { background: rgba(255, 255, 255, .8); }
.chat-stage[data-theme="paper"] .audio-slot__label { color: var(--c-dark); }

/* ссылки на места внутри сообщений чата */
.msg a {
  color: var(--stage-accent);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1.5px;
}
.msg a:hover { opacity: .75; }

/* ---------- состояние play: явная обратная связь ---------- */
.audio-slot.is-playing {
  box-shadow: 0 0 0 2px var(--portal-accent, var(--c-terracotta)), 0 0 18px rgba(196, 74, 12, .35);
}
.audio-slot.is-playing .audio-play {
  animation: audioPulse 1.6s ease-in-out infinite;
}
.audio-slot.is-playing .audio-slot__label::after {
  content: " · играет";
  opacity: .7;
}
@keyframes audioPulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(244, 166, 35, .5); }
  50% { transform: scale(1.06); box-shadow: 0 0 0 7px rgba(244, 166, 35, 0); }
}
/* эквалайзер-иконка «звучит» слева от подписи в бежевой теме */
.chat-stage[data-theme="paper"] .audio-slot.is-playing { box-shadow: 0 0 0 2px var(--c-terracotta); }

/* ---------- statement-блок «это не путеводитель» ---------- */
.statement { text-align: center; max-width: 20ch; margin: 0 auto; }
.statement .eyebrow { justify-content: center; margin-bottom: 1.4rem; }
.statement__line {
  font-family: "Unbounded", sans-serif;
  font-weight: 800;
  text-transform: uppercase;
  line-height: 1.12;
  font-size: clamp(1.5rem, 4.4vw, 2.7rem);
  margin: 0;
  color: var(--c-dark);
}
.statement__line span { color: var(--c-terracotta); }
.statement__line + .statement__line { margin-top: .25em; }

/* ---------- оффер: карточки ценности вместо полотна ---------- */
.value-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: clamp(2rem, 5vw, 3rem);
}
.value-card {
  background: rgba(241, 232, 213, .1);
  border: 1px solid rgba(241, 232, 213, .22);
  border-radius: 16px;
  padding: 1.4rem 1.4rem 1.5rem;
  transition: transform .35s var(--ease), background .35s, border-color .35s;
}
.value-card:hover {
  transform: translateY(-5px);
  background: rgba(241, 232, 213, .16);
  border-color: rgba(244, 166, 35, .5);
}
.value-card__ico {
  font-size: 1.7rem;
  display: block;
  margin-bottom: .7rem;
}
.value-card h3 {
  font-family: "Unbounded", sans-serif;
  font-size: .96rem;
  text-transform: none;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.2;
  margin: 0 0 .4em;
  color: var(--c-cream);
}
.value-card p {
  margin: 0;
  font-size: .9rem;
  line-height: 1.45;
  color: rgba(241, 232, 213, .82);
}

/* прайс-карта по центру под сеткой ценностей */
.offer-card--center {
  max-width: 460px;
  margin: 0 auto;
  position: static;
  text-align: center;
}
.offer-card--center .price-tag,
.offer-card--center .pay-methods { justify-content: center; }
.offer-card--center .offer-card__deadline { margin-left: auto; margin-right: auto; }

@media (max-width: 860px) {
  .value-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 520px) {
  .value-grid { grid-template-columns: 1fr; }
}

/* картинка-сообщение в чате портала */
.msg--img {
  padding: 0;
  background: none;
  max-width: 88%;
  flex: 0 0 auto;
}
.msg--img img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 16px;
  border-bottom-left-radius: 5px;
}
