:root {
  --navy: #111126;
  --text: #25262c;
  --muted: #6f7179;
  --line: #e5e6e9;
  --line-dark: #cfd1d6;
  --soft: #f6f6f7;
  --soft-2: #fafafa;
  --white: #ffffff;
  --orange: #f5a20b;
  --orange-dark: #df8c00;
  --orange-soft: #fff8e9;
  --green: #2bb673;
  --shadow: 0 18px 48px rgba(21, 22, 31, .08);
  --shadow-soft: 0 10px 30px rgba(21, 22, 31, .06);
  --radius-xl: 30px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 12px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  font-family: Montserrat, Arial, sans-serif;
  color: var(--text);
  background: #f4f4f5;
}
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { color: inherit; }
img { display: block; max-width: 100%; }
svg { display: block; }

.ai-app {
  width: min(1500px, calc(100% - 40px));
  margin: 28px auto 72px;
}

.consultant-section,
.value-section,
.popular-section {
  background: var(--white);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
}

.consultant-section {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  min-height: 760px;
  overflow: hidden;
}

.manager-panel {
  padding: 28px;
  border-right: 1px solid var(--line);
  background: var(--white);
}
.manager-heading { margin-bottom: 18px; }
.manager-heading h1,
.manager-heading .manager-main-title {
  margin: 8px 0 0;
  color: var(--navy);
  font-size: 25px;
  line-height: 1.18;
  letter-spacing: -.03em;
}
.manager-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #4a4d55;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.manager-status span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(43,182,115,.12);
}
.manager-photo {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  border-radius: 22px;
  background: #efefef;
}
.manager-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.manager-photo::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 34%;
  background: linear-gradient(180deg, transparent, rgba(12,12,21,.66));
}
.manager-photo-caption {
  position: absolute;
  z-index: 1;
  left: 18px;
  right: 18px;
  bottom: 17px;
  color: #fff;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.manager-photo-caption strong { font-size: 22px; }
.manager-photo-caption span { font-size: 12px; opacity: .9; }
.manager-description { margin-top: 22px; }
.manager-description h2 {
  margin: 0 0 10px;
  color: var(--navy);
  font-size: 20px;
  line-height: 1.25;
}
.manager-description p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}
.manager-benefits {
  display: grid;
  gap: 12px;
  margin: 20px 0 24px;
  padding: 0;
  list-style: none;
}
.manager-benefits li {
  position: relative;
  padding-left: 25px;
  color: #3a3c43;
  font-size: 13px;
  line-height: 1.45;
}
.manager-benefits li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .42em;
  width: 8px;
  height: 8px;
  border: 2px solid var(--orange);
  border-radius: 50%;
}
.manager-contact {
  width: 100%;
  min-height: 50px;
  border: 0;
  border-radius: 12px;
  background: var(--orange);
  color: var(--navy);
  font-weight: 800;
  transition: background .18s ease, transform .18s ease;
}
.manager-contact:hover { background: #ffb51e; transform: translateY(-1px); }

.workspace {
  min-width: 0;
  padding: 30px 32px 26px;
  display: flex;
  flex-direction: column;
}
.workspace-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 20px;
}
.workspace-header h2 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(24px, 2.2vw, 34px);
  line-height: 1.15;
  letter-spacing: -.035em;
}
.workspace-header p {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}
.workspace-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
}
.new-chat-btn {
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  padding: 10px;
}
.new-chat-btn:hover { color: var(--navy); }
.view-switch {
  display: flex;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--soft);
}
.view-btn {
  min-width: 72px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  padding: 10px 15px;
  font-size: 13px;
  font-weight: 800;
}
.view-btn.active {
  background: var(--white);
  color: var(--navy);
  box-shadow: 0 3px 10px rgba(18,18,31,.08);
}

.panel { display: none; }
.panel.active { display: block; }
.chat-panel { min-width: 0; }
.chat-shell {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--white);
}
.chat-scroll {
  height: clamp(470px, 58vh, 620px);
  overflow-y: auto;
  padding: 22px 24px;
  background: var(--soft-2);
  scrollbar-width: thin;
  scrollbar-color: #cfd1d6 transparent;
}
.welcome-prompts {
  position: sticky;
  z-index: 4;
  top: 0;
  margin-bottom: 20px;
  padding: 18px;
  border: 1px solid #f2cf87;
  border-radius: 16px;
  background: rgba(255,250,239,.97);
  box-shadow: 0 8px 26px rgba(49,42,27,.07);
  backdrop-filter: blur(10px);
  transition: opacity .22s ease, transform .22s ease, max-height .25s ease, margin .25s ease, padding .25s ease;
}
.welcome-prompts.is-hidden {
  max-height: 0;
  margin: 0;
  padding-top: 0;
  padding-bottom: 0;
  overflow: hidden;
  border-width: 0;
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
}
.welcome-copy {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 13px;
}
.welcome-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 2px solid var(--orange);
  border-radius: 50%;
  color: var(--orange-dark);
  font-size: 19px;
  font-weight: 800;
  flex: 0 0 auto;
}
.welcome-copy strong { color: var(--navy); font-size: 15px; }
.welcome-copy p { margin: 4px 0 0; color: var(--muted); font-size: 12px; }
.starter-chips { display: flex; flex-wrap: wrap; gap: 9px; }
.chip {
  border: 1px solid #d9dadd;
  border-radius: 10px;
  background: var(--white);
  color: #404149;
  padding: 10px 13px;
  font-size: 12px;
  font-weight: 600;
}
.chip:hover { border-color: var(--orange); color: var(--navy); }
.chat-body { display: flex; flex-direction: column; gap: 15px; }
.message {
  max-width: min(76%, 720px);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.message.bot { align-self: flex-start; }
.message.user { align-self: flex-end; }
.message-bubble {
  border-radius: 17px;
  padding: 15px 17px;
  font-size: 14px;
  line-height: 1.58;
}
.message.bot .message-bubble {
  border: 1px solid var(--line);
  border-top-left-radius: 5px;
  background: var(--white);
}
.message.user .message-bubble {
  border-top-right-radius: 5px;
  background: var(--navy);
  color: #fff;
}
.message-meta { color: #999ba2; font-size: 10px; }
.message.user .message-meta { text-align: right; }
.typing-bubble { display: inline-flex; gap: 5px; align-items: center; min-height: 16px; }
.typing-bubble span { width: 6px; height: 6px; border-radius: 50%; background: #a8a9ae; animation: blink 1s infinite alternate; }
.typing-bubble span:nth-child(2) { animation-delay: .15s; }
.typing-bubble span:nth-child(3) { animation-delay: .3s; }
@keyframes blink { to { opacity: .25; transform: translateY(-2px); } }
.message-projects { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; margin-top: 5px; }

.chat-form {
  padding: 16px 18px 13px;
  border-top: 1px solid var(--line);
  background: var(--white);
}
.composer-row {
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  gap: 12px;
  align-items: end;
}
#chatInput {
  width: 100%;
  min-height: 50px;
  max-height: 160px;
  resize: none;
  border: 1px solid var(--line-dark);
  border-radius: 12px;
  outline: none;
  background: var(--white);
  color: var(--text);
  padding: 14px 15px;
  font-size: 14px;
  line-height: 1.5;
}
#chatInput:focus { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(245,162,11,.12); }
.send-btn {
  min-height: 50px;
  border: 0;
  border-radius: 12px;
  background: var(--orange);
  color: var(--navy);
  padding: 0 18px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 800;
}
.send-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.send-btn:disabled { opacity: .55; cursor: wait; }
.composer-footer {
  margin-top: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #999ba2;
  font-size: 10px;
}
.composer-footer > div { display: flex; flex-wrap: wrap; gap: 14px; }
.text-action {
  border: 0;
  background: transparent;
  color: #595b63;
  padding: 0;
  font-size: 11px;
  font-weight: 700;
}
.text-action:hover { color: var(--orange-dark); }
.ai-disclaimer { margin: 11px 4px 0; color: #8b8d94; font-size: 10px; line-height: 1.5; }

.quiz-panel {
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--white);
  padding: 24px;
}
.quiz-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
}
.quiz-header h3 { margin: 0; color: var(--navy); font-size: 25px; letter-spacing: -.02em; }
.quiz-header p { margin: 8px 0 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.quiz-progress { margin-top: 22px; }
.quiz-progress-bar { height: 5px; overflow: hidden; border-radius: 999px; background: #ececef; }
.quiz-progress-bar span { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--orange); transition: width .25s ease; }
.quiz-progress-text { margin-top: 8px; color: var(--muted); font-size: 11px; }
.quiz-card { padding: 28px 0 10px; }
.quiz-question { margin: 0; color: var(--navy); font-size: clamp(24px,2.2vw,33px); line-height: 1.2; letter-spacing: -.035em; }
.quiz-hint { margin: 10px 0 22px; color: var(--muted); font-size: 13px; }
.quiz-options { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.quiz-option {
  min-height: 72px;
  display: flex;
  align-items: center;
  gap: 13px;
  text-align: left;
  border: 1px solid var(--line-dark);
  border-radius: 14px;
  background: var(--white);
  color: #383940;
  padding: 15px 17px;
  font-size: 13px;
  font-weight: 650;
}
.quiz-option-radio {
  width: 18px;
  height: 18px;
  border: 1.5px solid #bfc1c7;
  border-radius: 50%;
  flex: 0 0 auto;
  position: relative;
}
.quiz-option.selected { border-color: var(--orange); box-shadow: inset 0 0 0 1px var(--orange); background: var(--orange-soft); color: var(--navy); }
.quiz-option.selected .quiz-option-radio { border-color: var(--orange); }
.quiz-option.selected .quiz-option-radio::after { content:""; position:absolute; inset:4px; border-radius:50%; background:var(--orange); }
.quiz-footer-actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 22px; }
.primary-btn,
.secondary-btn,
.ghost-btn,
.outline-btn,
.catalog-link {
  min-height: 46px;
  border-radius: 11px;
  padding: 0 17px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: 12px;
  font-weight: 800;
}
.primary-btn { border: 1px solid var(--orange); background: var(--orange); color: var(--navy); }
.secondary-btn { border: 1px solid var(--line-dark); background: var(--white); color: var(--navy); }
.ghost-btn { border: 1px solid var(--line); background: var(--soft); color: #565860; }
.outline-btn { border: 1px solid var(--navy); background: transparent; color: var(--navy); }
.catalog-link { background: var(--orange); color: var(--navy); }
button:disabled { opacity: .45; cursor: not-allowed; }
.full-width { width: 100%; }
.hidden { display: none !important; }

.quiz-result { padding-top: 24px; }
.result-heading {
  display: flex;
  justify-content: space-between;
  gap: 22px;
  align-items: flex-start;
  padding-bottom: 22px;
  border-bottom: 1px solid var(--line);
}
.result-status { color: var(--orange-dark); font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.result-heading h3 { margin: 8px 0 8px; color: var(--navy); font-size: clamp(25px,2.4vw,36px); letter-spacing: -.035em; }
.result-heading p { max-width: 660px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.result-heading-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.answer-summary { display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 18px 0; color: #65676f; font-size: 11px; line-height: 1.5; }
.answer-summary b { color: #42444a; }
.result-projects { margin-top: 2px; }
.result-editor { margin-top: 26px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.result-editor-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  padding: 20px 0;
}
.result-editor-head h4 { margin: 0; color: var(--navy); font-size: 18px; }
.result-editor-head p { margin: 5px 0 0; color: var(--muted); font-size: 12px; }
.result-editor-toggle { border: 1px solid var(--line-dark); border-radius: 10px; background: #fff; padding: 10px 14px; font-size: 11px; font-weight: 800; }
.result-editor-body { display: none; padding: 0 0 22px; }
.result-editor.is-open .result-editor-body { display: grid; gap: 20px; }
.result-edit-question { margin-bottom: 9px; color: #404149; font-size: 12px; font-weight: 800; }
.result-edit-options { display: flex; flex-wrap: wrap; gap: 8px; }
.result-edit-option { border: 1px solid var(--line); border-radius: 9px; background: var(--white); padding: 9px 12px; color: #65676e; font-size: 11px; }
.result-edit-option.selected { border-color: var(--orange); background: var(--orange-soft); color: var(--navy); font-weight: 800; }
.result-next-step { margin-top: 24px; padding: 22px; border-radius: 16px; background: var(--soft); display: flex; justify-content: space-between; gap: 20px; align-items: center; }
.result-next-step h4 { margin: 0 0 7px; color: var(--navy); font-size: 18px; }
.result-next-step p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.55; }

.value-section,
.popular-section { margin-top: 28px; padding: 34px 36px; }
.value-intro { max-width: 760px; }
.value-intro h2,
.popular-header h2 { margin: 0; color: var(--navy); font-size: clamp(28px,3vw,42px); line-height: 1.15; letter-spacing: -.045em; }
.value-intro p,
.popular-header p { margin: 11px 0 0; color: var(--muted); font-size: 14px; line-height: 1.65; }
.value-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); margin-top: 30px; border-top: 1px solid var(--line); }
.value-item { padding: 24px 24px 4px 0; }
.value-item + .value-item { padding-left: 24px; border-left: 1px solid var(--line); }
.value-number { color: var(--orange-dark); font-size: 11px; font-weight: 800; }
.value-item h3 { margin: 12px 0 9px; color: var(--navy); font-size: 17px; }
.value-item p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.65; }

.popular-header { display: flex; justify-content: space-between; gap: 24px; align-items: flex-end; margin-bottom: 28px; }
.popular-header > div:first-child { max-width: 760px; }
.popular-actions { display: flex; flex-wrap: wrap; gap: 10px; flex: 0 0 auto; }
.projects-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 26px; }
.project-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid #ededee;
  border-radius: 27px;
  background: var(--white);
  box-shadow: var(--shadow-soft);
}
.project-image-link { display: block; overflow: hidden; aspect-ratio: 1.48 / 1; background: #e8e8ea; }
.project-image { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.project-card:hover .project-image { transform: scale(1.025); }
.project-card-body { padding: 23px 25px 24px; }
.project-card-title-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.project-title { color: var(--navy); text-decoration: none; font-size: 21px; font-weight: 800; letter-spacing: -.02em; }
.project-chat-button {
  width: 35px;
  height: 35px;
  flex: 0 0 auto;
  border: 2px solid var(--orange);
  border-radius: 50%;
  background: #fff;
  color: var(--orange-dark);
  font-weight: 800;
}
.project-specs { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 14px; color: #55575f; }
.project-specs span { display: inline-flex; align-items: center; gap: 7px; font-size: 11px; white-space: nowrap; }
.project-specs svg { width: 22px; height: 22px; fill: none; stroke: #c3c5ca; stroke-width: 1.3; stroke-linecap: round; stroke-linejoin: round; }
.project-specs b { font-weight: 600; }
.project-summary { min-height: 42px; margin: 16px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }
.project-bottom { display: flex; align-items: flex-end; justify-content: space-between; gap: 15px; margin-top: 20px; }
.project-price { color: #2a2b31; font-size: 19px; font-weight: 800; white-space: nowrap; }
.project-more { color: var(--navy); font-size: 11px; font-weight: 800; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.project-card-compact { border-radius: 18px; box-shadow: none; }
.project-card-compact .project-card-body { padding: 15px; }
.project-card-compact .project-title { font-size: 16px; }
.project-card-compact .project-specs { gap: 8px; }
.project-card-compact .project-specs span:nth-child(2) { display:none; }
.project-card-compact .project-price { font-size: 15px; }

.modal { position: fixed; inset: 0; z-index: 100; display: none; align-items: center; justify-content: center; padding: 18px; }
.modal.open { display: flex; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(12,12,22,.58); backdrop-filter: blur(5px); }
.modal-dialog { position: relative; z-index: 1; width: min(540px,100%); border-radius: 24px; background:#fff; padding: 28px; box-shadow: 0 30px 90px rgba(0,0,0,.28); }
.modal-dialog h3 { margin: 0; color: var(--navy); font-size: 27px; }
.modal-dialog > p { margin: 10px 0 0; color: var(--muted); font-size: 13px; line-height:1.6; }
.modal-close { position:absolute; top:12px; right:15px; border:0; background:transparent; color:#565860; font-size:28px; line-height:1; }
.lead-form { display:grid; gap:11px; margin-top:20px; }
.lead-form input,
.lead-form textarea { width:100%; border:1px solid var(--line-dark); border-radius:11px; outline:none; padding:13px 14px; color:var(--text); background:#fff; font-size:13px; }
.lead-form input:focus,
.lead-form textarea:focus { border-color:var(--orange); box-shadow:0 0 0 3px rgba(245,162,11,.11); }
.form-status { margin-top:12px; color:var(--muted); font-size:12px; line-height:1.5; }

@media (max-width: 1180px) {
  .consultant-section { grid-template-columns: 290px minmax(0,1fr); }
  .manager-panel { padding: 22px; }
  .workspace { padding: 25px; }
  .projects-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .value-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .value-item:nth-child(3) { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); }
  .value-item:nth-child(4) { border-top: 1px solid var(--line); }
}

@media (max-width: 850px) {
  .ai-app { width: min(100% - 20px, 760px); margin-top: 10px; }
  .consultant-section { grid-template-columns: 1fr; }
  .manager-panel { border-right: 0; border-bottom: 1px solid var(--line); }
  .manager-photo { aspect-ratio: 16 / 10; }
  .manager-photo img { object-position: center 25%; }
  .manager-benefits { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .workspace-header,
  .popular-header,
  .result-heading,
  .result-next-step { flex-direction: column; align-items: stretch; }
  .workspace-actions { justify-content: space-between; }
  .popular-actions { flex: 1; }
  .popular-actions > * { flex: 1; }
  .value-section,
  .popular-section { padding: 28px 24px; }
}

@media (max-width: 620px) {
  .ai-app { width: 100%; margin: 0 0 36px; }
  .consultant-section,
  .value-section,
  .popular-section { border-radius: 0; box-shadow: none; }
  .manager-panel,
  .workspace { padding: 18px; }
  .manager-benefits { grid-template-columns: 1fr; }
  .workspace-header { gap: 15px; }
  .workspace-actions { align-items: stretch; flex-direction: column-reverse; }
  .view-switch { width:100%; }
  .view-btn { flex:1; }
  .chat-scroll { height: 510px; padding: 15px; }
  .welcome-prompts { padding: 14px; }
  .message { max-width: 90%; }
  .message-projects,
  .projects-grid,
  .quiz-options,
  .value-grid { grid-template-columns: 1fr; }
  .composer-row { grid-template-columns: 1fr; }
  .send-btn { width:100%; justify-content:center; }
  .composer-footer { align-items:flex-start; flex-direction:column; }
  .quiz-panel { border-radius: 16px; padding: 18px; }
  .quiz-header { flex-direction:column; }
  .quiz-footer-actions { position:sticky; bottom:0; z-index:4; padding:12px 0 2px; background:#fff; }
  .value-section,
  .popular-section { margin-top:10px; padding:26px 18px; }
  .value-item,
  .value-item + .value-item,
  .value-item:nth-child(3) { padding:20px 0; border-left:0; border-top:1px solid var(--line); }
  .popular-actions { flex-direction:column; }
  .project-card { border-radius:22px; }
  .project-card-body { padding:20px; }
  .project-specs { gap:11px; }
  .project-summary { min-height:0; }
  .project-bottom { align-items:flex-start; flex-direction:column; }
  .answer-summary { flex-direction:column; }
  .result-heading-actions { flex-direction:column; }
  .result-heading-actions > * { width:100%; }
}

.result-reasons {
  margin: 18px 0 4px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--orange-soft);
}
.result-reasons h4 {
  margin: 0 0 10px;
  color: var(--navy);
  font-size: 16px;
}
.result-reasons ul {
  margin: 0;
  padding-left: 18px;
  color: #3e4148;
  line-height: 1.55;
}

/* Полезные баннеры под блоком консультанта */
.resource-banners-section {
  margin-top: 28px;
  padding: 30px;
  background: var(--white);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
}
.resource-banners-header {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
}
.resource-banners-header h2 {
  margin: 0;
  color: var(--navy);
  font-size: clamp(24px, 2vw, 34px);
  letter-spacing: -.03em;
}
.resource-banners-header p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.55;
}
.resource-banners-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.resource-banner-card {
  display: block;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #fff;
  color: inherit;
  text-decoration: none;
  box-shadow: var(--shadow-soft);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.resource-banner-card:hover {
  transform: translateY(-3px);
  border-color: #f2c56d;
  box-shadow: 0 16px 38px rgba(21, 22, 31, .12);
}
.resource-banner-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.resource-banner-caption {
  padding: 15px 17px 17px;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.resource-banner-caption strong {
  color: var(--navy);
  font-size: 16px;
}
.resource-banner-caption span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

/* Улучшения мобильной версии */
@media (max-width: 980px) {
  .resource-banners-grid { grid-template-columns: 1fr; }
  .resource-banner-card {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(220px, .65fr);
    align-items: center;
  }
  .resource-banner-card img { height: 100%; aspect-ratio: 16 / 9; }
}

@media (max-width: 700px) {
  body { background: #fff; }
  .ai-app {
    width: 100%;
    margin: 0;
  }
  .consultant-section,
  .value-section,
  .popular-section,
  .resource-banners-section {
    border-radius: 0;
    box-shadow: none;
  }
  .manager-panel {
    padding: 18px 16px 16px;
  }
  .manager-photo {
    max-height: 430px;
    aspect-ratio: 4 / 5;
  }
  .manager-description { margin-top: 16px; }
  .manager-benefits { margin: 16px 0 18px; }
  .workspace {
    padding: 20px 14px 18px;
  }
  .workspace-header {
    flex-direction: column;
    gap: 14px;
  }
  .workspace-actions {
    width: 100%;
    justify-content: space-between;
  }
  .view-switch { margin-left: auto; }
  .chat-scroll {
    min-height: 360px;
    max-height: 58vh;
  }
  .message {
    max-width: 92%;
  }
  .message-bubble {
    padding: 13px 14px;
    font-size: 14px;
  }
  .composer-row {
    align-items: flex-end;
  }
  .send-btn {
    min-width: 48px;
    width: 48px;
    padding: 0;
    justify-content: center;
  }
  .send-btn span { display: none; }
  .composer-footer {
    align-items: flex-start;
    gap: 8px;
    flex-direction: column;
  }
  .composer-footer > div {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
  }
  .resource-banners-section { padding: 24px 14px; }
  .resource-banners-grid { gap: 14px; }
  .resource-banner-card { display: block; border-radius: 18px; }
  .resource-banner-card img { aspect-ratio: 16 / 9; }
  .value-section,
  .popular-section { padding-left: 14px; padding-right: 14px; }
  .projects-grid { grid-template-columns: 1fr; }
  .quiz-card { padding: 18px 14px; }
  .quiz-options { grid-template-columns: 1fr; }
  .result-heading,
  .result-next-step {
    flex-direction: column;
    align-items: stretch;
  }
  .result-heading-actions { width: 100%; }
  .result-heading-actions button { flex: 1; }
  .modal-dialog {
    width: calc(100% - 20px);
    max-height: calc(100vh - 20px);
    overflow: auto;
    border-radius: 20px;
    padding: 22px 16px;
  }
}

/* v5: cache-safe assets, clearer lead status and compact mobile layout */
.form-status.is-success {
  color: #176c45;
  font-weight: 700;
}
.form-status.is-error {
  color: #a52a2a;
  font-weight: 700;
}
.form-privacy {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}
.manager-photo img,
.resource-banner-card img {
  background: #f3f3f3;
}

@media (max-width: 700px) {
  .manager-panel {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    grid-template-areas:
      "heading heading"
      "photo description"
      "benefits benefits"
      "contact contact";
    column-gap: 14px;
    align-items: start;
  }
  .manager-heading { grid-area: heading; margin-bottom: 12px; }
  .manager-photo {
    grid-area: photo;
    width: 112px;
    height: 150px;
    max-height: none;
    aspect-ratio: auto;
    border-radius: 16px;
  }
  .manager-photo img { object-position: center 34%; }
  .manager-photo::after { height: 48%; }
  .manager-photo-caption {
    left: 10px;
    right: 10px;
    bottom: 10px;
  }
  .manager-photo-caption strong { font-size: 16px; }
  .manager-photo-caption span { font-size: 9px; line-height: 1.25; }
  .manager-description {
    grid-area: description;
    margin-top: 0;
  }
  .manager-description h2 { font-size: 18px; }
  .manager-description p { font-size: 12px; line-height: 1.52; }
  .manager-benefits {
    grid-area: benefits;
    gap: 8px;
    margin-top: 15px;
  }
  .manager-benefits li { font-size: 12px; }
  .manager-contact { grid-area: contact; min-height: 48px; }

  .workspace-header h2 { font-size: 24px; }
  .workspace-header p { font-size: 13px; }
  .chat-scroll {
    height: min(58vh, 520px);
    min-height: 380px;
    padding: 12px;
  }
  .starter-chips {
    display: grid;
    grid-template-columns: 1fr;
  }
  .chip { width: 100%; text-align: left; }
  .chat-form { padding: 12px; }
  .composer-row { grid-template-columns: minmax(0,1fr) 48px; }
  #chatInput { min-height: 50px; max-height: 130px; }
  .send-btn { height: 48px; border-radius: 12px; }
  .ai-disclaimer { font-size: 10px; line-height: 1.45; }

  .resource-banners-header h2,
  .popular-header h2,
  .value-intro h2 { font-size: 24px; }
  .resource-banner-caption { padding: 13px 14px 15px; }
  .resource-banner-caption strong { font-size: 15px; }

  .popular-section .projects-grid {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(82vw, 1fr);
    grid-template-columns: none;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 8px;
  }
  .popular-section .project-card { scroll-snap-align: start; }

  .modal {
    align-items: flex-end;
    padding: 0;
  }
  .modal-dialog {
    width: 100%;
    max-height: 92vh;
    border-radius: 22px 22px 0 0;
    padding: 24px 16px calc(18px + env(safe-area-inset-bottom));
  }
}


/* v7: раскрытие каталога, заметное подтверждение заявки, загрузка проекта */
.show-more-projects-wrap { display:flex; justify-content:center; margin-top:28px; }
.show-more-projects-btn { min-width:240px; }
.message-lead-success { max-width:min(92%,760px); }
.message-lead-success .message-bubble {
  border:1px solid #9fd7b7;
  background:linear-gradient(135deg,#effbf4,#fff8e9);
  color:#124b31;
  font-size:16px;
  font-weight:700;
  line-height:1.55;
  box-shadow:0 12px 30px rgba(23,108,69,.12);
}
.lead-file-group { display:grid; gap:8px; padding:13px; border:1px dashed #e6a33e; border-radius:12px; background:#fffaf1; }
.lead-file-group label { display:flex; flex-direction:column; gap:4px; color:var(--navy); font-size:12px; }
.lead-file-group label span { color:var(--muted); font-size:10px; line-height:1.4; }
.lead-file-group input[type=file] { padding:10px; background:#fff; }
.result-projects.projects-grid { grid-template-columns:repeat(3,minmax(0,1fr)); }
@media (max-width: 1280px) {
  .result-projects.projects-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width: 760px) {
  .result-projects.projects-grid { grid-template-columns:1fr; }
  .show-more-projects-btn { width:100%; }
}

/* v8: фильтр каталога и надёжный переход к подбору дома */
.quiz-panel { scroll-margin-top: 18px; }
.popular-section { scroll-margin-top: 18px; }
.catalog-filter-panel {
  margin: -4px 0 24px;
  padding: 16px 18px;
  border: 1px solid #e6e8ec;
  border-radius: 18px;
  background: linear-gradient(135deg, #f8fafc 0%, #fffaf1 100%);
}
.catalog-filter-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 13px;
}
.catalog-filter-heading > div {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.catalog-filter-heading strong {
  color: var(--navy);
  font-size: 15px;
  line-height: 1.35;
}
.catalog-filter-heading span,
.catalog-result-count {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}
.catalog-filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}
.catalog-filter-btn,
.catalog-filter-reset {
  appearance: none;
  border: 1px solid #cfd5de;
  border-radius: 999px;
  background: #fff;
  color: var(--navy);
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: border-color .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.catalog-filter-btn {
  min-height: 40px;
  padding: 0 15px;
}
.catalog-filter-btn:hover,
.catalog-filter-reset:hover {
  border-color: #f0a535;
  transform: translateY(-1px);
}
.catalog-filter-btn.is-active {
  border-color: #f58220;
  background: #f58220;
  color: #fff;
  box-shadow: 0 7px 18px rgba(245, 130, 32, .22);
}
.catalog-filter-reset {
  flex: 0 0 auto;
  padding: 9px 12px;
  color: #8b4a12;
  border-color: #f1c78f;
  background: #fff8ed;
}
.catalog-filter-reset[hidden] { display: none; }
.catalog-result-count {
  margin-top: 12px;
  font-weight: 600;
}
.catalog-empty {
  grid-column: 1 / -1;
  min-height: 210px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 30px;
  border: 1px dashed #d7dbe2;
  border-radius: 20px;
  background: #fbfcfd;
  text-align: center;
}
.catalog-empty strong { color: var(--navy); font-size: 20px; }
.catalog-empty span { color: var(--muted); font-size: 13px; }

@media (max-width: 700px) {
  .catalog-filter-panel {
    margin-bottom: 18px;
    padding: 14px;
    border-radius: 16px;
  }
  .catalog-filter-heading {
    gap: 10px;
    align-items: center;
  }
  .catalog-filter-heading strong { font-size: 14px; }
  .catalog-filter-heading span { font-size: 11px; }
  .catalog-filter-buttons {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }
  .catalog-filter-btn {
    width: 100%;
    min-height: 42px;
    padding: 8px 10px;
    line-height: 1.2;
  }
  .popular-section .projects-grid.is-catalog-mode {
    display: grid;
    grid-auto-flow: row;
    grid-auto-columns: auto;
    grid-template-columns: 1fr;
    overflow: visible;
    scroll-snap-type: none;
    padding-bottom: 0;
  }
  .popular-section .projects-grid.is-catalog-mode .project-card {
    scroll-snap-align: none;
  }
}

@media (max-width: 420px) {
  .catalog-filter-heading {
    align-items: flex-start;
  }
  .catalog-filter-reset {
    padding: 8px 9px;
    font-size: 11px;
  }
  .catalog-filter-buttons { grid-template-columns: 1fr; }
}
.show-more-projects-wrap[hidden] { display: none !important; }

/* v9: управляемые CTA в сообщениях, квалификация заявки и улучшенная форма */
.message-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 2px;
}
.message-action-primary,
.message-action-secondary {
  min-height: 42px;
  border-radius: 11px;
  padding: 10px 14px;
  font-size: 12px;
  font-weight: 800;
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
}
.message-action-primary {
  border: 1px solid var(--orange);
  background: var(--orange);
  color: var(--navy);
}
.message-action-secondary {
  border: 1px solid var(--line-dark);
  background: #fff;
  color: var(--navy);
}
.message-action-primary:hover,
.message-action-secondary:hover { transform: translateY(-1px); }
.message-action-secondary:hover { border-color: var(--orange); }
.message-lead-success .message-actions { margin-top: 4px; }
.message-lead-success .message-action-secondary { background: rgba(255,255,255,.72); }

.lead-extra-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.lead-extra-grid input,
.lead-extra-grid select {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line-dark);
  border-radius: 11px;
  background: #fff;
  color: var(--text);
  padding: 11px 12px;
  font-size: 12px;
  outline: none;
}
.lead-extra-grid input:focus,
.lead-extra-grid select:focus {
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(245,162,11,.12);
}
.form-honeypot {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

@media (max-width: 680px) {
  .message-actions { display: grid; grid-template-columns: 1fr; width: 100%; }
  .message-action-primary,
  .message-action-secondary { width: 100%; }
  .lead-extra-grid { grid-template-columns: 1fr; }
}


/* v10: отдельный дизайн карточек результата подбора */
.quiz-result-projects { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:18px; margin-top:18px; }
.quiz-project-card { display:flex; flex-direction:column; min-width:0; overflow:hidden; border:1px solid #e6eaf0; border-radius:20px; background:#fff; box-shadow:0 12px 34px rgba(15,27,51,.08); }
.quiz-project-image-wrap { aspect-ratio:16/10; overflow:hidden; background:#f4f6f8; }
.quiz-project-image { width:100%; height:100%; object-fit:cover; display:block; transform:none!important; }
.quiz-project-card-body { display:flex; flex:1; flex-direction:column; justify-content:space-between; gap:18px; padding:20px; }
.quiz-project-card h4 { margin:0 0 12px; color:var(--navy); font-size:20px; }
.quiz-project-card p { margin:14px 0 0; color:var(--muted); font-size:13px; line-height:1.55; }
.quiz-project-actions { display:flex; flex-direction:column; gap:12px; align-items:stretch; }
.quiz-project-actions .primary-btn { width:100%; }
.quiz-project-page-link { color:var(--navy); font-size:13px; font-weight:700; text-align:center; text-decoration:underline; text-underline-offset:4px; }
.quiz-project-page-link:hover { color:var(--orange); }
@media (max-width:1050px) { .quiz-result-projects { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media (max-width:680px) { .quiz-result-projects { grid-template-columns:1fr; } }


/* v13: inline-заявки, маска телефона и подсказки комплектаций */
.inline-lead-form {
  width: min(520px, 100%);
  display: grid;
  gap: 11px;
  padding: 15px;
  border: 1px solid #e4e8ee;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(15,27,51,.08);
}
.inline-lead-copy { display:grid; gap:4px; }
.inline-lead-copy strong { color:var(--navy); font-size:14px; }
.inline-lead-copy span { color:var(--muted); font-size:12px; line-height:1.45; }
.inline-lead-fields {
  display:grid;
  grid-template-columns:minmax(120px,.8fr) minmax(190px,1.15fr) auto;
  gap:9px;
  align-items:stretch;
}
.inline-lead-fields input {
  width:100%;
  min-height:44px;
  border:1px solid var(--line-dark);
  border-radius:10px;
  padding:10px 12px;
  background:#fff;
  color:var(--text);
  font-size:13px;
  outline:none;
}
.inline-lead-fields input:focus {
  border-color:var(--orange);
  box-shadow:0 0 0 3px rgba(245,162,11,.12);
}
.inline-lead-fields .message-action-primary { min-height:44px; white-space:nowrap; }
.inline-lead-form > small { color:#777b84; font-size:10px; line-height:1.4; }
.inline-lead-status:empty { display:none; }
.inline-lead-status { margin:0; }

.quiz-option-wrap {
  min-width:0;
  border-radius:14px;
}
.quiz-option-row {
  display:grid;
  grid-template-columns:minmax(0, 1fr) 36px;
  gap:9px;
  align-items:center;
}
.quiz-option-wrap .quiz-option {
  width:100%;
}
.quiz-help-button {
  width:32px;
  height:32px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border:1px solid #cfd4dc;
  border-radius:50%;
  background:#f7f8fa;
  color:var(--navy);
  font-size:14px;
  font-weight:800;
  line-height:1;
  cursor:pointer;
  transition:border-color .16s ease, background .16s ease, transform .16s ease;
}
.quiz-help-button:hover,
.quiz-help-button:focus-visible,
.quiz-option-wrap.is-tooltip-open .quiz-help-button {
  border-color:var(--orange);
  background:var(--orange-soft);
  outline:none;
  transform:scale(1.04);
}
.quiz-option-details {
  max-height:0;
  margin:0;
  padding:0 14px;
  overflow:hidden;
  border:0 solid #e1e5eb;
  border-radius:12px;
  background:#fffaf3;
  color:#43464d;
  box-shadow:none;
  opacity:0;
  transform:translateY(-4px);
  transition:max-height .24s ease, margin .2s ease, padding .2s ease, opacity .18s ease, transform .18s ease, border-width .2s ease;
}
.quiz-option-wrap.is-tooltip-open .quiz-option-details {
  max-height:520px;
  margin-top:9px;
  padding:13px 14px 14px;
  border-width:1px;
  opacity:1;
  transform:translateY(0);
}
.quiz-option-details-head {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
  margin-bottom:7px;
}
.quiz-option-details-head strong {
  color:var(--navy);
  font-size:12px;
  line-height:1.4;
}
.quiz-option-details p {
  margin:0;
  font-size:12px;
  line-height:1.6;
}
.quiz-tooltip-close {
  flex:0 0 auto;
  width:27px;
  height:27px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border:0;
  border-radius:50%;
  background:#fff;
  color:#6c7079;
  font-size:20px;
  line-height:1;
  cursor:pointer;
  box-shadow:0 1px 4px rgba(15,27,51,.12);
}
.quiz-tooltip-close:hover,
.quiz-tooltip-close:focus-visible {
  background:var(--orange-soft);
  color:var(--navy);
  outline:2px solid rgba(245,162,11,.22);
}
.quiz-option-radio {
  width:18px;
  height:18px;
  border:1.5px solid #bfc1c7;
  border-radius:50%;
  flex:0 0 auto;
  position:relative;
}

@media (max-width: 820px) {
  .inline-lead-fields { grid-template-columns:1fr 1fr; }
  .inline-lead-fields .message-action-primary { grid-column:1 / -1; width:100%; }
}
@media (max-width: 560px) {
  .inline-lead-form { padding:13px; }
  .inline-lead-fields { grid-template-columns:1fr; }
  .inline-lead-fields .message-action-primary { grid-column:auto; }
}


/* v16: адаптивная форма заявки внутри сообщения */
.message-actions,
.inline-lead-form,
.inline-lead-fields {
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}
.message-actions { width: 100%; }
.inline-lead-form {
  width: 100%;
  overflow: hidden;
}
.inline-lead-fields {
  width: 100%;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: stretch;
}
.inline-lead-fields input {
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}
.inline-lead-fields .message-action-primary {
  grid-column: 1 / -1;
  width: 100%;
  min-width: 0;
  white-space: normal;
  overflow-wrap: anywhere;
}
@media (max-width: 620px) {
  .inline-lead-form { padding: 12px; }
  .inline-lead-fields { grid-template-columns: minmax(0, 1fr); }
  .inline-lead-fields .message-action-primary { grid-column: auto; }
}


/* v17: заявка и каталог после результата подбора */
.result-next-step {
  margin-top: 6px;
  padding: 22px;
  border: 1px solid #f0d8bd;
  border-radius: 18px;
  background: linear-gradient(135deg, #fff8ef 0%, #ffffff 72%);
  display: flex;
  justify-content: space-between;
  gap: 22px;
  align-items: center;
}
.result-next-step-copy { min-width: 0; }
.result-next-step-copy h4 { margin: 0 0 7px; color: var(--navy); font-size: 19px; line-height: 1.25; }
.result-next-step-copy p { max-width: 700px; margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.result-next-step-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; flex: 0 0 auto; }
.result-next-step-actions .primary-btn,
.result-next-step-actions .outline-btn { min-height: 46px; text-align: center; white-space: normal; }
@media (max-width: 860px) {
  .result-next-step { align-items: stretch; flex-direction: column; }
  .result-next-step-actions { justify-content: flex-start; }
}
@media (max-width: 560px) {
  .result-next-step { padding: 18px; }
  .result-next-step-actions { display: grid; grid-template-columns: 1fr; width: 100%; }
  .result-next-step-actions > * { width: 100%; }
}


/* v19: увеличение изображений проектов */
.project-image-button {
  position: relative;
  width: 100%;
  padding: 0;
  border: 0;
  color: inherit;
  text-align: inherit;
  cursor: zoom-in;
  appearance: none;
}
.project-image-button:focus-visible {
  outline: 3px solid rgba(241, 125, 28, .45);
  outline-offset: 3px;
}
.project-image-zoom-label {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(15, 27, 51, .82);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  opacity: 0;
  transform: translateY(5px);
  transition: opacity .2s ease, transform .2s ease;
  pointer-events: none;
}
.project-image-button:hover .project-image-zoom-label,
.project-image-button:focus-visible .project-image-zoom-label {
  opacity: 1;
  transform: translateY(0);
}
.project-image-modal { z-index: 180; }
.project-image-dialog {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  width: min(1120px, 96vw);
  max-height: 94vh;
  padding: 14px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 34px 110px rgba(0, 0, 0, .36);
}
.project-image-dialog img {
  display: block;
  width: 100%;
  max-height: calc(94vh - 76px);
  object-fit: contain;
  border-radius: 14px;
  background: #f2f4f7;
}
.project-image-caption {
  margin: 10px 40px 0 4px;
  color: var(--navy);
  font-size: 15px;
  font-weight: 800;
}
.project-image-dialog .modal-close {
  top: 17px;
  right: 19px;
  z-index: 3;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(15, 27, 51, .88);
  color: #fff;
  font-size: 25px;
}
.project-chat-button.is-active {
  transform: scale(.94);
  background: var(--orange);
  color: #fff;
}
@media (max-width: 680px) {
  .project-image-zoom-label { opacity: 1; transform: none; }
  .project-image-dialog { width: calc(100vw - 20px); padding: 8px; border-radius: 17px; }
  .project-image-dialog img { max-height: calc(92vh - 68px); border-radius: 11px; }
  .project-image-caption { margin: 8px 40px 2px 4px; font-size: 13px; }
}


/* v23: компактный блок преимуществ над полезными разделами */
.value-section {
  margin-top: 18px;
  padding: 22px 26px 20px;
}
.value-intro { max-width: 900px; }
.value-intro h2 {
  font-size: clamp(22px, 2.2vw, 30px);
  line-height: 1.15;
  letter-spacing: -.035em;
}
.value-intro p {
  margin-top: 7px;
  font-size: 12px;
  line-height: 1.45;
}
.value-grid {
  margin-top: 17px;
}
.value-item {
  padding: 15px 18px 1px 0;
}
.value-item + .value-item {
  padding-left: 18px;
}
.value-number { font-size: 10px; }
.value-item h3 {
  margin: 7px 0 5px;
  font-size: 15px;
  line-height: 1.25;
}
.value-item p {
  font-size: 11px;
  line-height: 1.48;
}
.resource-banners-section { margin-top: 18px; }

@media (max-width: 1180px) {
  .value-section { padding: 20px 22px; }
  .value-item { padding-top: 14px; padding-bottom: 4px; }
}
@media (max-width: 620px) {
  .value-section { margin-top: 8px; padding: 20px 18px; }
  .value-grid { margin-top: 13px; }
  .value-item,
  .value-item + .value-item,
  .value-item:nth-child(3) {
    padding: 13px 0;
  }
  .value-item h3 { margin-top: 5px; }
  .resource-banners-section { margin-top: 8px; }
}


/* ===== First screen v25 ===== */
.ai-app {
  width: min(1500px, calc(100% - 40px));
  margin: 20px auto 72px;
}

.hero-v25 {
  position: relative;
  min-height: clamp(780px, calc(100svh - 40px), 940px);
  overflow: hidden;
  border-radius: 34px;
  margin-bottom: 22px;
  background: #faf9f6;
  box-shadow: 0 18px 60px rgba(24, 31, 49, .12);
  isolation: isolate;
}
.hero-v25__background {
  position: absolute;
  inset: 0;
  z-index: -3;
  background: url("../images/hero/hero-house-v25.jpg?v=20260816-36") right center / cover no-repeat;
}
.hero-v25__fade {
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(90deg,
      rgba(255,255,255,.99) 0%,
      rgba(255,255,255,.97) 24%,
      rgba(255,255,255,.79) 39%,
      rgba(255,255,255,.33) 55%,
      rgba(255,255,255,.06) 70%,
      rgba(255,255,255,0) 84%);
  pointer-events: none;
}
.hero-v25__content {
  position: relative;
  z-index: 4;
  width: 43%;
  min-width: 525px;
  padding: clamp(64px, 8vh, 92px) 0 48px clamp(50px, 5vw, 78px);
}
.hero-v25__title {
  max-width: 650px;
  margin: 0;
  color: #10203f;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(54px, 4.8vw, 77px);
  font-weight: 500;
  line-height: .99;
  letter-spacing: -.035em;
}
.hero-v25__subtitle {
  max-width: 560px;
  margin: 28px 0 0;
  color: #424b5f;
  font-size: clamp(18px, 1.55vw, 25px);
  font-weight: 500;
  line-height: 1.55;
}
.hero-v25__actions {
  display: flex;
  gap: 16px;
  margin-top: 40px;
  flex-wrap: wrap;
}
.hero-v25__button {
  min-height: 64px;
  padding: 0 28px;
  border-radius: 14px;
  border: 1.5px solid transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  font-size: 18px;
  font-weight: 600;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.hero-v25__button svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.hero-v25__button:hover {
  transform: translateY(-2px);
}
.hero-v25__button--primary {
  min-width: 230px;
  background: #102653;
  color: #fff;
  box-shadow: 0 14px 30px rgba(16, 38, 83, .18);
}
.hero-v25__button--primary:hover { background: #0d1f47; }
.hero-v25__button--secondary {
  min-width: 210px;
  color: #19223a;
  background: rgba(255,255,255,.76);
  border-color: #ef7f1a;
  box-shadow: 0 12px 24px rgba(24,31,49,.08);
  backdrop-filter: blur(12px);
}
.hero-v25__benefits {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  width: min(660px, 100%);
  margin-top: 48px;
}
.hero-v25__benefit {
  min-height: 86px;
  padding: 0 17px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  gap: 10px;
  color: #293248;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.35;
  position: relative;
}
.hero-v25__benefit:first-child { padding-left: 0; }
.hero-v25__benefit:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 8px;
  right: 0;
  width: 1px;
  height: 68px;
  background: rgba(16,32,63,.11);
}
.hero-v25__benefit-icon {
  color: #f27d12;
}
.hero-v25__benefit-icon svg {
  width: 30px;
  height: 30px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.hero-v25__audience {
  width: min(555px, 100%);
  margin-top: 44px;
  padding: 18px 22px;
  display: flex;
  align-items: center;
  gap: 18px;
  background: rgba(255,255,255,.67);
  border: 1px solid rgba(16,32,63,.09);
  border-radius: 18px;
  box-shadow: 0 16px 34px rgba(29,36,54,.08);
  backdrop-filter: blur(16px);
}
.hero-v25__audience-icon {
  width: 50px;
  height: 50px;
  flex: 0 0 50px;
  display: grid;
  place-items: center;
  color: #646d7e;
}
.hero-v25__audience-icon svg {
  width: 38px;
  height: 38px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.hero-v25__audience strong {
  display: block;
  color: #273149;
  font-size: 17px;
  line-height: 1.35;
}
.hero-v25__audience small {
  display: block;
  margin-top: 5px;
  color: #777e8e;
  font-size: 13px;
  line-height: 1.4;
}

.hero-v25__visual {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}
.hero-v25__nina {
  position: absolute;
  right: -1.2%;
  bottom: 0;
  z-index: 2;
  height: 74%;
  width: auto;
  max-width: none;
  object-fit: contain;
  object-position: right bottom;
  filter: drop-shadow(0 28px 34px rgba(17,26,44,.16));
}
.hero-v25__float {
  position: absolute;
  z-index: 3;
  background: rgba(255,255,255,.83);
  border: 1px solid rgba(255,255,255,.7);
  border-radius: 20px;
  box-shadow: 0 18px 44px rgba(32,42,62,.13);
  backdrop-filter: blur(18px);
}
.hero-v25__float-title {
  display: block;
  margin-bottom: 11px;
  color: #2b3243;
  font-size: 13px;
  font-weight: 700;
}
.hero-v25__float-title span { color: #f27d12; }
.hero-v25__projects {
  top: 8.5%;
  left: 46.8%;
  width: min(460px, 32vw);
  padding: 17px;
}
.hero-v25__project-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 9px;
}
.hero-v25__project {
  min-width: 0;
  padding: 8px;
  background: rgba(255,255,255,.7);
  border-radius: 12px;
}
.hero-v25__project img {
  width: 100%;
  aspect-ratio: 1.35 / 1;
  object-fit: cover;
  border-radius: 8px;
  background: #e7e8e9;
}
.hero-v25__project strong {
  display: block;
  margin-top: 7px;
  color: #2a3142;
  font-size: 11px;
  line-height: 1.2;
}
.hero-v25__project span {
  display: block;
  margin-top: 3px;
  color: #72798a;
  font-size: 9px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hero-v25__chat-card {
  top: 37%;
  left: 49%;
  width: min(300px, 21vw);
  padding: 15px 17px;
  display: grid;
  grid-template-columns: 43px minmax(0,1fr);
  gap: 11px;
  align-items: start;
}
.hero-v25__nina-avatar,
.hero-v25__prompt-avatar {
  overflow: hidden;
  border-radius: 50%;
  background: #edf0f3;
}
.hero-v25__nina-avatar {
  width: 43px;
  height: 43px;
  border: 2px solid rgba(255,255,255,.95);
}
.hero-v25__nina-avatar img,
.hero-v25__prompt-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 61% 23%;
  transform: scale(1.62);
}
.hero-v25__chat-card strong {
  display: block;
  color: #303747;
  font-size: 12px;
}
.hero-v25__chat-card strong span {
  color: #89909d;
  font-size: 9px;
  font-weight: 500;
}
.hero-v25__chat-card p {
  margin: 6px 0 0;
  color: #4d5566;
  font-size: 9.5px;
  line-height: 1.45;
}
.hero-v25__recommendation {
  top: 55%;
  left: 43%;
  width: min(360px, 25vw);
  padding: 14px;
}
.hero-v25__recommendation-main {
  display: grid;
  grid-template-columns: 98px minmax(0,1fr);
  gap: 10px;
  align-items: center;
}
.hero-v25__recommendation-main > img {
  width: 98px;
  height: 72px;
  object-fit: cover;
  border-radius: 9px;
  background: #e7e8e9;
}
.hero-v25__recommendation-main strong {
  display: block;
  color: #2e3545;
  font-size: 11px;
}
.hero-v25__recommendation-main span {
  display: block;
  margin-top: 4px;
  color: #737a8b;
  font-size: 9px;
  line-height: 1.35;
}
.hero-v25__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 7px;
}
.hero-v25__tags i {
  padding: 4px 7px;
  border-radius: 999px;
  background: rgba(26,37,63,.055);
  color: #697184;
  font-size: 7.5px;
  font-style: normal;
}
.hero-v25__fake-button {
  display: block;
  margin-top: 10px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #ef7f1a;
  color: white;
  text-align: center;
  font-size: 9.5px;
  font-weight: 700;
}
.hero-v25__prompt {
  left: 46.5%;
  bottom: 7%;
  width: min(350px, 24vw);
  padding: 9px 10px;
  display: grid;
  grid-template-columns: 30px minmax(0,1fr) 22px;
  gap: 9px;
  align-items: center;
}
.hero-v25__prompt-avatar {
  width: 30px;
  height: 30px;
}
.hero-v25__prompt > span:nth-child(2) {
  min-width: 0;
  color: #747b89;
  font-size: 9px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hero-v25__prompt svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: #ef7f1a;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* First-screen adaptive behavior */
@media (max-width: 1320px) {
  .hero-v25__content { width: 48%; min-width: 500px; padding-left: 48px; }
  .hero-v25__projects { left: 48%; width: 390px; }
  .hero-v25__chat-card { left: 50.5%; width: 260px; }
  .hero-v25__recommendation { left: 46%; width: 320px; }
  .hero-v25__prompt { left: 50%; width: 300px; }
  .hero-v25__nina { right: -3%; height: 72%; width: auto; }
}
@media (max-width: 1120px) {
  .hero-v25 { min-height: 840px; }
  .hero-v25__content { width: 54%; min-width: 0; padding: 58px 0 38px 42px; }
  .hero-v25__title { font-size: clamp(50px, 6vw, 66px); }
  .hero-v25__subtitle { max-width: 500px; font-size: 18px; }
  .hero-v25__projects { left: 57%; top: 8%; width: 310px; }
  .hero-v25__project-grid { grid-template-columns: repeat(2,1fr); }
  .hero-v25__project:nth-child(3) { display: none; }
  .hero-v25__chat-card { left: 57%; top: 34%; width: 255px; }
  .hero-v25__recommendation { display: none; }
  .hero-v25__prompt { left: 56%; bottom: 7%; width: 285px; }
  .hero-v25__nina { right: -5%; height: 66%; width: auto; }
}
@media (max-width: 860px) {
  .ai-app { width: min(100% - 20px, 1500px); margin-top: 10px; }
  .hero-v25 {
    min-height: auto;
    padding-bottom: 0;
    border-radius: 24px;
  }
  .hero-v25__background {
    background-position: 66% center;
  }
  .hero-v25__fade {
    background:
      linear-gradient(180deg,
        rgba(255,255,255,.99) 0%,
        rgba(255,255,255,.97) 50%,
        rgba(255,255,255,.78) 72%,
        rgba(255,255,255,.50) 100%);
  }
  .hero-v25__content {
    width: 100%;
    padding: 42px 28px 0;
  }
  .hero-v25__title {
    max-width: 700px;
    font-size: clamp(42px, 9vw, 62px);
  }
  .hero-v25__subtitle {
    max-width: 650px;
    margin-top: 18px;
  }
  .hero-v25__actions { margin-top: 28px; }
  .hero-v25__benefits {
    width: 100%;
    max-width: 640px;
    margin-top: 34px;
  }
  .hero-v25__audience {
    margin-top: 30px;
  }
  .hero-v25__visual {
    display: none;
  }
  .hero-v25__projects,
  .hero-v25__chat-card,
  .hero-v25__recommendation,
  .hero-v25__prompt,
  .hero-v25__nina {
    display: none;
  }
}
@media (max-width: 620px) {
  .hero-v25__content { padding: 32px 20px 0; }
  .hero-v25__title { font-size: clamp(38px, 11.7vw, 54px); line-height: 1.02; }
  .hero-v25__subtitle { font-size: 16px; line-height: 1.5; }
  .hero-v25__actions { display: grid; grid-template-columns: 1fr; gap: 11px; }
  .hero-v25__button { width: 100%; min-width: 0; min-height: 57px; font-size: 16px; }
  .hero-v25__benefits {
    grid-template-columns: repeat(2,1fr);
    gap: 18px 8px;
  }
  .hero-v25__benefit {
    min-height: 62px;
    padding: 0 12px 0 0;
    flex-direction: row;
    align-items: center;
    gap: 10px;
  }
  .hero-v25__benefit:not(:last-child)::after { display: none; }
  .hero-v25__benefit-icon svg { width: 25px; height: 25px; }
  .hero-v25__audience {
    padding: 14px 15px;
    margin-top: 26px;
  }
  .hero-v25__audience-icon { width: 40px; height: 40px; flex-basis: 40px; }
  .hero-v25__audience-icon svg { width: 31px; height: 31px; }
  .hero-v25__audience strong { font-size: 14px; }
  .hero-v25__audience small { font-size: 11px; }
}
@media (prefers-reduced-motion: no-preference) {
  .hero-v25__projects { animation: heroFloat 5.8s ease-in-out infinite; }
  .hero-v25__chat-card { animation: heroFloat 6.4s ease-in-out .4s infinite; }
  .hero-v25__recommendation { animation: heroFloat 6.1s ease-in-out .8s infinite; }
}
@keyframes heroFloat {
  0%,100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

.consultant-section { scroll-margin-top: 20px; }


/* v27: resource banners keep full image height on tablet/mobile */
@media (max-width: 980px) {
  .resource-banner-card {
    overflow: hidden;
  }
  .resource-banner-card img {
    display: block;
    width: 100%;
    height: auto;
    min-height: 0;
    aspect-ratio: 16 / 9;
    object-fit: contain;
    object-position: center;
  }
}

@media (max-width: 700px) {
  .resource-banner-card {
    display: block;
  }
  .resource-banner-card img {
    width: 100%;
    height: auto;
    min-height: 0;
    max-height: none;
    aspect-ratio: auto;
    object-fit: contain;
  }
}


/* v30 */
.hero-v25__nina {
  object-fit: contain;
  object-position: center bottom;
}
.hero-v25__nina-avatar,
.hero-v25__prompt-avatar {
  overflow: hidden;
  border-radius: 999px;
  background: #fff;
}
.hero-v25__nina-avatar img,
.hero-v25__prompt-avatar img,
.hero-v25__avatar-img,
.hero-v25__prompt-avatar-img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover !important;
  object-position: center 18% !important;
  transform: none !important;
}


/* v31: approved Nina image with stone countertop */
.hero-v25__nina {
  right: -1.5%;
  bottom: 0;
  height: 80%;
  width: auto;
  max-width: none;
  object-fit: contain;
  object-position: right bottom;
  filter: drop-shadow(0 24px 34px rgba(17,26,44,.14));
}

.hero-v25__nina-avatar img,
.hero-v25__prompt-avatar img {
  object-position: center 20% !important;
  transform: none !important;
}

@media (max-width: 1320px) and (min-width: 1121px) {
  .hero-v25__nina {
    right: -3%;
    height: 78%;
  }
}

@media (max-width: 1120px) and (min-width: 861px) {
  .hero-v25__nina {
    right: -5%;
    height: 74%;
  }
}

@media (max-width: 860px) {
  .hero-v25__nina { display: none !important; }
}


/* v32: более удобный чат на телефоне */
@media (max-width: 700px) {
  /* На телефоне карточка консультанта превращается в компактную строку,
     чтобы основную высоту экрана занимала переписка. */
  .manager-panel {
    padding: 10px 14px 9px;
    min-height: 54px;
    border-bottom: 1px solid var(--line);
  }
  .manager-heading {
    margin: 0;
  }
  .manager-heading .manager-main-title {
    margin: 3px 0 0;
    font-size: 16px;
    line-height: 1.15;
  }
  .manager-status {
    gap: 6px;
    font-size: 9px;
    letter-spacing: .07em;
  }
  .manager-status span {
    width: 6px;
    height: 6px;
    box-shadow: 0 0 0 3px rgba(43,182,115,.10);
  }
  .manager-photo,
  .manager-description,
  .manager-benefits,
  .manager-contact {
    display: none !important;
  }

  .workspace {
    padding: 10px 10px 12px;
  }
  .workspace-header {
    gap: 8px;
    margin-bottom: 9px;
  }
  .workspace-header h2 {
    font-size: 18px;
    line-height: 1.15;
  }
  .workspace-header p {
    display: none;
  }
  .workspace-actions {
    width: 100%;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
  }
  .new-chat-btn {
    padding: 7px 5px;
    font-size: 11px;
    white-space: nowrap;
  }
  .view-switch {
    margin-left: auto;
    padding: 3px;
    border-radius: 10px;
  }
  .view-btn {
    min-width: 0;
    padding: 8px 10px;
    font-size: 11px;
  }

  .chat-shell {
    display: flex;
    flex-direction: column;
    height: clamp(500px, calc(100dvh - 185px), 720px);
    border-radius: 16px;
  }
  .chat-scroll {
    flex: 1 1 auto;
    height: auto;
    min-height: 0;
    max-height: none;
    padding: 12px 10px;
  }

  /* Популярные вопросы остаются доступными, но больше не съедают
     значительную часть первого экрана чата. */
  .welcome-prompts {
    position: static;
    margin-bottom: 10px;
    padding: 0 0 7px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
  }
  .welcome-copy {
    margin: 0 0 7px;
    gap: 0;
  }
  .welcome-mark,
  .welcome-copy p {
    display: none;
  }
  .welcome-copy strong {
    font-size: 12px;
  }
  .starter-chips {
    display: flex;
    flex-wrap: nowrap;
    gap: 7px;
    overflow-x: auto;
    padding-bottom: 3px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .starter-chips::-webkit-scrollbar {
    display: none;
  }
  .chip {
    flex: 0 0 auto;
    max-width: 210px;
    padding: 8px 10px;
    border-radius: 9px;
    font-size: 10.5px;
    white-space: nowrap;
  }

  .chat-body {
    gap: 11px;
  }
  .message {
    max-width: 94%;
  }
  .message-bubble {
    padding: 11px 12px;
    font-size: 13.5px;
    line-height: 1.52;
  }

  .chat-form {
    flex: 0 0 auto;
    padding: 9px 9px 8px;
  }
  .composer-row {
    grid-template-columns: minmax(0,1fr) 44px;
    gap: 7px;
    align-items: end;
  }
  #chatInput {
    min-height: 44px;
    max-height: 120px;
    padding: 11px 12px;
    border-radius: 10px;
    font-size: 13px;
  }
  .send-btn {
    width: 44px;
    min-width: 44px;
    min-height: 44px;
    padding: 0;
    border-radius: 10px;
    justify-content: center;
  }
  .send-btn span {
    display: none;
  }
  .composer-footer {
    margin-top: 6px;
    flex-direction: row;
    align-items: center;
    gap: 8px;
  }
  .composer-footer > span {
    display: none;
  }
  .composer-footer > div {
    width: 100%;
    justify-content: space-between;
    gap: 8px;
  }
  .text-action {
    font-size: 10px;
  }
  .ai-disclaimer {
    display: none;
  }
}

@media (max-width: 380px) {
  .workspace-header h2 {
    font-size: 16px;
  }
  .view-btn {
    padding-left: 8px;
    padding-right: 8px;
  }
  .chat-shell {
    height: clamp(470px, calc(100dvh - 175px), 660px);
  }
}


/* v33: навигация по длинной странице */
.page-section-nav {
  margin: 0 0 18px;
  scroll-margin-top: 16px;
}
.page-section-nav__inner {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px;
  overflow-x: auto;
  border: 1px solid rgba(20, 34, 63, .09);
  border-radius: 16px;
  background: rgba(255,255,255,.92);
  box-shadow: 0 10px 30px rgba(21, 31, 52, .06);
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.page-section-nav__inner::-webkit-scrollbar { display: none; }
.page-section-nav__item {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 0 15px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: #3d4452;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
  transition: background .18s ease, color .18s ease, border-color .18s ease;
}
.page-section-nav__item:hover,
.page-section-nav__item.is-active {
  border-color: rgba(239,127,26,.28);
  background: #fff7ef;
  color: var(--navy);
}
#consultantApp,
#valueSection,
#resourceBanners,
#popularProjectsSection { scroll-margin-top: 16px; }

/* v33: компактная горизонтальная карточка проекта внутри чата */
.message-projects {
  display: block;
  width: min(100%, 540px);
}
.chat-project-card {
  display: grid;
  grid-template-columns: 132px minmax(0,1fr);
  min-height: 104px;
  overflow: hidden;
  border-radius: 14px;
  box-shadow: none;
}
.chat-project-card .project-image-link {
  width: 132px;
  height: 100%;
  min-height: 104px;
  aspect-ratio: auto;
}
.chat-project-card .project-image {
  width: 100%;
  height: 100%;
  min-height: 104px;
  object-fit: cover;
}
.chat-project-card .project-image-zoom-label {
  right: 7px;
  bottom: 7px;
  padding: 4px 6px;
  font-size: 8px;
}
.chat-project-card .project-card-body {
  min-width: 0;
  padding: 11px 12px 10px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
}
.chat-project-card .project-title {
  font-size: 15px;
  line-height: 1.18;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chat-project-specs {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 10px;
  color: var(--muted);
  font-size: 10.5px;
  font-weight: 600;
}
.chat-project-card .project-bottom {
  margin-top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.chat-project-card .project-price {
  font-size: 12px;
  line-height: 1.2;
}
.chat-project-card .project-more {
  font-size: 10.5px;
  white-space: nowrap;
}

/* v33: фотография проекта всегда открывается по центру экрана */
.project-image-modal {
  align-items: center !important;
  justify-content: center !important;
  padding: 10px !important;
}

@media (max-width: 700px) {
  .page-section-nav {
    margin: 0 0 10px;
    padding: 0 10px;
  }
  .page-section-nav__inner {
    gap: 6px;
    padding: 7px;
    border-radius: 13px;
  }
  .page-section-nav__item {
    min-height: 34px;
    padding: 0 11px;
    font-size: 10.5px;
  }

  .message-projects { width: 100%; }
  .chat-project-card {
    grid-template-columns: 108px minmax(0,1fr);
    min-height: 88px;
    border-radius: 12px;
  }
  .chat-project-card .project-image-link {
    width: 108px;
    min-height: 88px;
  }
  .chat-project-card .project-image { min-height: 88px; }
  .chat-project-card .project-card-body {
    padding: 8px 9px;
    gap: 5px;
  }
  .chat-project-card .project-title { font-size: 13px; }
  .chat-project-specs { gap: 4px 8px; font-size: 9.5px; }
  .chat-project-card .project-price { font-size: 10.5px; }
  .chat-project-card .project-more { font-size: 9.5px; }
  .chat-project-card .project-image-zoom-label { display: none; }

  .project-image-modal {
    align-items: center !important;
    justify-content: center !important;
    padding: 10px !important;
  }
  .project-image-modal .project-image-dialog {
    width: min(100%, 680px);
    max-height: calc(100dvh - 20px);
    margin: auto;
    border-radius: 17px;
    padding: 8px;
  }
  .project-image-modal .project-image-dialog img {
    max-height: calc(100dvh - 86px);
    object-fit: contain;
  }

  .composer-footer {
    justify-content: flex-start;
  }
}

/* v33: один результат подбора занимает удобную ширину */
.quiz-result-projects {
  grid-template-columns: minmax(0, 560px) !important;
  justify-content: start;
}
@media (max-width: 680px) {
  .quiz-result-projects { grid-template-columns: 1fr !important; }
}


/* v34: точечные UX-правки чата и навигации */
:root {
  /* Когда позже появится основное меню сайта, сюда можно передать его высоту. */
  --page-section-nav-top: 0px;
  --page-section-nav-offset: 70px;
}

/* Якорное меню остаётся видно при прокрутке длинной страницы. */
.page-section-nav {
  position: sticky;
  top: var(--page-section-nav-top);
  z-index: 90;
  margin-bottom: 18px;
  padding-top: 4px;
  padding-bottom: 4px;
  background: rgba(255,255,255,.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.page-section-nav__inner {
  box-shadow: 0 8px 28px rgba(21,31,52,.09);
}
#consultantApp,
#valueSection,
#resourceBanners,
#popularProjectsSection {
  scroll-margin-top: calc(var(--page-section-nav-top) + var(--page-section-nav-offset));
}

/* Граница рабочей области чата: видно, где начинается и заканчивается диалог. */
.chat-shell {
  border: 2px solid #8eb4e8;
  box-shadow: 0 0 0 3px rgba(70,125,196,.055), 0 12px 30px rgba(31,66,112,.07);
}

/* В компактной карточке проекта вся правая часть выровнена строго влево. */
.chat-project-card .project-card-body {
  align-items: flex-start;
  text-align: left;
}
.chat-project-card .project-title,
.chat-project-card .chat-project-specs,
.chat-project-card .project-bottom,
.chat-project-card .project-price,
.chat-project-card .project-more {
  text-align: left !important;
}
.chat-project-card .chat-project-specs {
  justify-content: flex-start;
  width: 100%;
}
.chat-project-card .project-bottom {
  width: 100%;
  justify-content: flex-start;
  align-items: baseline;
  gap: 12px;
}

@media (max-width: 860px) {
  .hero-v25__content {
    padding-bottom: 28px;
  }
  .hero-v25__audience {
    margin-bottom: 10px;
  }
}

@media (max-width: 700px) {
  :root { --page-section-nav-offset: 58px; }
  .page-section-nav {
    margin: 0 0 10px;
    padding: 4px 10px;
  }
  .page-section-nav__inner {
    padding: 6px;
    border-radius: 13px;
  }
  .chat-project-card .project-bottom {
    gap: 9px;
  }
}

@media (max-width: 620px) {
  .hero-v25__content {
    padding-bottom: 32px;
  }
  .hero-v25__audience {
    margin-bottom: 14px;
  }
}
