/* Дом24: каталог проектов (Pinch Studio). Цвета и шрифты темы dom24-2026. */

/* ── Лента вместо рамки с прокруткой ── */
.tema-dom24 #katalog[data-d24p-katalog] .house-grid,
#katalog[data-d24p-katalog] .house-grid {
  max-height: none;
  overflow: visible;
  overscroll-behavior: auto;
  scrollbar-gutter: auto;
}
.d24p-skryt, .d24p-gruppa[hidden], [data-d24p-katalog] [hidden] { display: none !important; }
.d24p-card { display: flex; flex-direction: column; scroll-margin-top: calc(var(--header-h, 82px) + 20px); }
.d24p-card .house-card__body { flex: 1; }
.d24p-card .house-card__name a { color: inherit; text-decoration: none; }
.d24p-card .house-card__name a:hover { text-decoration: underline; text-underline-offset: 3px; }
.d24p-card .house-card__media { display: block; }
.d24p-card__knopki { margin-top: auto; padding-top: 4px; display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; position: relative; z-index: 4; }
.d24p-btn { padding: 11px 18px; font-size: 15px; }
.d24p-btn--big { padding: 15px 26px; font-size: 17px; }
.d24p-podrobnee { font-weight: 800; color: var(--green-deep, #0d5c2a); text-decoration: none; padding: 8px 2px; }
.d24p-podrobnee:hover { text-decoration: underline; text-underline-offset: 3px; }
.d24p-gruppa { scroll-margin-top: calc(var(--header-h, 82px) + 16px); }
.d24p-eshche { display: flex; flex-direction: column; align-items: center; gap: 8px; margin-top: 26px; }
.d24p-eshche .btn { min-width: 240px; justify-content: center; }
.d24p-eshche .note { margin: 0; }

/* ── Панель поиска и фильтров ── */
.d24p-panel {
  position: relative; z-index: 5;
  display: grid; gap: 14px;
  margin: 0 0 30px; padding: 18px;
  border-radius: 22px; background: var(--c-surface, #fff);
  box-shadow: 0 6px 24px rgba(10, 60, 30, .08);
  border: 1px solid var(--c-line, #e3eae5);
}
.d24p-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.d24p-poisk { position: relative; display: block; }
.d24p-poisk svg { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--c-ink-muted, #667); pointer-events: none; }
.d24p-poisk input {
  width: 100%; box-sizing: border-box; height: 52px; padding: 0 16px 0 46px;
  border: 2px solid var(--c-line, #dfe7e1); border-radius: 14px;
  background: var(--c-page, #f7f9f7); color: var(--c-ink, #14211a); font: inherit; font-size: 16px;
}
.d24p-poisk input:focus, .d24p-pole select:focus { outline: none; border-color: var(--green-mid, #228727); box-shadow: 0 0 0 4px var(--green-tint, rgba(34,135,39,.12)); }
.d24p-chipy { display: flex; flex-wrap: wrap; gap: 8px; }
.d24p-chip {
  padding: 9px 16px; border-radius: 999px; cursor: pointer;
  border: 2px solid var(--c-line, #dfe7e1); background: transparent; color: var(--c-ink, #14211a);
  font: inherit; font-weight: 700; font-size: 15px;
}
.d24p-chip:hover { border-color: var(--green-mid, #228727); }
.d24p-chip.is-on { background: var(--green-mid, #228727); border-color: var(--green-mid, #228727); color: #fff; }
.d24p-polya { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.d24p-pole { display: grid; gap: 5px; font-size: 13px; font-weight: 700; color: var(--c-ink-muted, #5a6a60); }
.d24p-pole select {
  width: 100%; height: 46px; padding: 0 34px 0 12px; box-sizing: border-box;
  border: 2px solid var(--c-line, #dfe7e1); border-radius: 12px;
  background: var(--c-page, #f7f9f7) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23667' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 12px center;
  -webkit-appearance: none; appearance: none;
  color: var(--c-ink, #14211a); font: inherit; font-size: 15px; font-weight: 600;
}
.d24p-itog { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.d24p-itog p { margin: 0; font-weight: 800; color: var(--c-headline, #0d3b1f); }
.d24p-sbros { border: 0; background: none; padding: 6px 0; cursor: pointer; font: inherit; font-weight: 700; color: var(--green-deep, #0d5c2a); text-decoration: underline; text-underline-offset: 3px; }
.d24p-filtry { display: none; align-items: center; gap: 8px; margin-left: auto; padding: 10px 16px; border-radius: 999px; border: 2px solid var(--green-mid, #228727); background: transparent; color: var(--green-deep, #0d5c2a); font: inherit; font-weight: 800; cursor: pointer; }
.d24p-filtry b { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: var(--green-mid, #228727); color: #fff; font-size: 13px; }
.d24p-filtry b[hidden] { display: none; }
.d24p-pusto { margin: 10px 0 0; padding: 28px; border-radius: 22px; background: var(--c-surface, #fff); text-align: center; }
.d24p-pusto__knopki { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 14px; }

@media (max-width: 1100px) {
  .d24p-polya { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .d24p-panel { padding: 14px; border-radius: 18px; gap: 12px; margin-bottom: 22px; }
  .d24p-polya { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .d24p-panel:not(.is-otkryt) .d24p-polya { display: none; }
  .d24p-filtry { display: inline-flex; }
  .d24p-itog { order: 9; flex-wrap: wrap; row-gap: 4px; }
  .d24p-itog p { font-size: 15px; flex: 1 1 auto; }
  .d24p-itog .d24p-filtry { order: 2; }
  .d24p-itog .d24p-sbros { order: 3; flex-basis: 100%; text-align: left; padding: 2px 0; }
  .d24p-polya .d24p-pole:last-child { grid-column: 1 / -1; }
  .d24p-chipy { flex-wrap: nowrap; overflow-x: auto; margin: 0 -14px; padding: 0 14px 2px; scrollbar-width: none; }
  .d24p-chipy::-webkit-scrollbar { display: none; }
  .d24p-chip { flex: none; }
  .d24p-card__knopki .d24p-btn { flex: 1; justify-content: center; }
}

/* ── Шапка на телефоне больше не закрывает заголовок каталога ── */
@media (max-width: 760px) {
  /* было 14px: надпись над заголовком уходила под шапку (78px) на 13px */
  .katalog-shapka { padding-top: calc(var(--header-h, 78px) - 26px) !important; }
}
html { scroll-padding-top: calc(var(--header-h, 82px) + 16px); }

/* ── Значок reCAPTCHA скрыт: под формами подпись Google, как требуют их правила ── */
.grecaptcha-badge { visibility: hidden !important; opacity: 0 !important; }
.d24p-okno__recaptcha { margin: 10px 0 0; font-size: 12px; line-height: 1.45; color: var(--c-ink-muted, #6a766f); }
.d24p-okno__recaptcha a { color: inherit; }

/* ── Окно "Узнать цену" ── */
.d24p-okno {
  width: min(480px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); box-sizing: border-box; overflow: auto;
  padding: 26px 24px 22px; border: 0; border-radius: 22px;
  background: var(--c-surface, #fff); color: var(--c-ink, #14211a);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .35);
}
.d24p-okno::backdrop { background: rgba(2, 31, 14, .62); backdrop-filter: blur(4px); }
.d24p-okno__zakryt { position: absolute; right: 12px; top: 10px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--c-page, #f2f5f3); color: inherit; font: 800 24px/1 Arial, sans-serif; cursor: pointer; }
.d24p-okno__metka { margin: 0 0 4px; font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--green-mid, #228727); }
.d24p-okno h3 { margin: 0 48px 6px 0; font-size: 24px; line-height: 1.15; color: var(--c-headline, #0d3b1f); }
.d24p-okno__summa { margin: 0 0 14px; color: var(--c-ink-muted, #5a6a60); }
.d24p-okno__forma { display: grid; gap: 11px; }
.d24p-okno__forma label { display: grid; gap: 5px; font-weight: 700; font-size: 14px; }
.d24p-okno__forma small { font-weight: 500; color: var(--c-ink-muted, #6a766f); }
.d24p-okno__forma input[type="text"], .d24p-okno__forma input[type="tel"], .d24p-okno__forma textarea {
  width: 100%; box-sizing: border-box; padding: 12px 14px; border: 2px solid var(--c-line, #dfe7e1); border-radius: 12px;
  background: var(--c-page, #f7f9f7); color: inherit; font: inherit; font-size: 16px; font-weight: 500;
}
.d24p-okno__forma input:focus, .d24p-okno__forma textarea:focus { outline: none; border-color: var(--green-mid, #228727); }
.d24p-okno__forma .btn { justify-content: center; margin-top: 4px; padding: 15px 20px; font-size: 17px; }
.d24p-okno__soglasie { grid-template-columns: auto 1fr; align-items: start; font-weight: 500 !important; font-size: 13px !important; }
.d24p-okno__soglasie input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--green-mid, #228727); }
.d24p-okno__status { margin: 0; min-height: 1.2em; font-weight: 700; }
.d24p-okno__status.is-oshibka { color: #b42318; }
.d24p-okno__gotovo { padding: 6px 0 2px; }
.d24p-okno__gotovo .btn { margin-top: 8px; }
.d24p-lovushka { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }

/* ── Кнопка в просмотре фото ── */
.d24p-gal-knopka { flex: none; display: flex; align-items: center; justify-content: center; gap: 14px; flex-wrap: wrap; margin-top: 10px; }
.d24p-gal-knopka span { font-weight: 800; color: var(--c-headline, #0d3b1f); }
.d24p-gal-knopka .btn { padding: 12px 22px; }
@media (max-width: 760px) {
  .d24p-gal-knopka { gap: 8px; }
  .d24p-gal-knopka span { font-size: 14px; text-align: center; width: 100%; }
}

/* ── Страница проекта ── */
.d24p-main .d24p-proekt { padding-top: 14px !important; }
.d24p-proekt__foto, .d24p-proekt__info { min-width: 0; }
.d24p-kroshki { display: flex; flex-wrap: wrap; gap: 6px 8px; margin: 0 0 18px; font-size: 14px; color: var(--c-ink-muted, #5a6a60); }
.d24p-kroshki a { color: var(--green-deep, #0d5c2a); font-weight: 700; text-decoration: none; }
.d24p-kroshki a:hover { text-decoration: underline; }
.d24p-proekt__verh { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 34px; align-items: start; }
.d24p-proekt__glavnoe { position: relative; display: block; width: 100%; padding: 0; border: 0; border-radius: 22px; overflow: hidden; cursor: zoom-in; background: var(--c-page, #eef2ef); }
.d24p-proekt__glavnoe img { display: block; width: 100%; aspect-ratio: 4 / 3; height: auto; object-fit: cover; }
.d24p-proekt__lupa { position: absolute; right: 14px; bottom: 14px; padding: 7px 12px; border-radius: 999px; background: rgba(255, 255, 255, .92); color: #0d3b1f; font-weight: 800; font-size: 14px; }
.d24p-proekt__mini { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.d24p-mini { flex: none; width: 88px; height: 66px; padding: 0; border: 3px solid transparent; border-radius: 12px; overflow: hidden; cursor: pointer; background: none; }
.d24p-mini img { display: block; width: 100%; height: 100%; object-fit: cover; }
.d24p-mini.is-on { border-color: var(--acc, #FBB701); }
.d24p-proekt__info h1 { margin: 6px 0 10px; font-size: clamp(30px, 4vw, 48px); line-height: 1.05; color: var(--c-headline, #0d3b1f); }
.d24p-proekt__cena { margin: 0 0 4px; font-size: clamp(26px, 3vw, 36px); font-weight: 900; color: var(--green-mid, #228727); }
.d24p-har { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 18px 0 22px; }
.d24p-har div { padding: 12px 14px; border-radius: 14px; background: var(--c-surface, #fff); border: 1px solid var(--c-line, #e3eae5); }
.d24p-har dt { font-size: 13px; color: var(--c-ink-muted, #5a6a60); }
.d24p-har dd { margin: 2px 0 0; font-size: 19px; font-weight: 800; color: var(--c-headline, #0d3b1f); }
.d24p-proekt__knopki { display: flex; flex-wrap: wrap; gap: 10px; }
.d24p-proekt__sravn { margin: 16px 0 0; }
.d24p-proekt__sravn a { font-weight: 700; color: var(--green-deep, #0d5c2a); }
.d24p-blok .section__head { display: flex; align-items: end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.d24p-plany { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; margin-top: 22px; }
.d24p-plan { display: block; padding: 0; border: 1px solid var(--c-line, #e3eae5); border-radius: 18px; overflow: hidden; background: #fff; cursor: zoom-in; }
.d24p-plan img { display: block; width: 100%; height: auto; }
.d24p-zaglushka { margin-top: 20px; padding: 26px; border-radius: 18px; border: 2px dashed var(--c-line, #cfdad2); text-align: center; }
.d24p-zaglushka p { margin: 0 0 14px; }
.d24p-spisok { margin: 20px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; max-width: 860px; }
.d24p-spisok li { position: relative; padding: 14px 16px 14px 46px; border-radius: 14px; background: var(--c-surface, #fff); border: 1px solid var(--c-line, #e3eae5); line-height: 1.5; }
.d24p-spisok li::before { content: ''; position: absolute; left: 16px; top: 17px; width: 18px; height: 18px; border-radius: 50%; background: var(--green-mid, #228727) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='10'%3E%3Cpath d='M1 5l3.5 3.5L11 1' fill='none' stroke='%23fff' stroke-width='2.2'/%3E%3C/svg%3E") no-repeat center; }
.d24p-grid--poh { grid-template-columns: repeat(4, minmax(0, 1fr)); }

@media (max-width: 1100px) {
  .d24p-grid--poh { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .d24p-proekt__verh { grid-template-columns: minmax(0, 1fr); gap: 20px; }
}
@media (max-width: 760px) {
  .d24p-proekt__glavnoe { border-radius: 16px; }
  .d24p-proekt__knopki .btn { flex: 1 1 auto; justify-content: center; }
  .d24p-proekt__knopki .d24p-btn--big { flex-basis: 100%; }
  .d24p-plany { grid-template-columns: 1fr; }
  .d24p-grid--poh { grid-template-columns: 1fr; }
}
