/* =========================================================
   Страница «Благодарственное письмо» (в стиле портала 2026)
   Подключается только на /servisy/blagodarstvennoe_pismo/poluchit_pismo
   ========================================================= */

.s2026-main .bp-page.blok_zayavka {
  width: auto !important;
  max-width: 860px !important;
  margin: 0 auto !important;
  padding: clamp(22px, 3.6vw, 42px) !important;
  border: 1px solid var(--line) !important;
  border-radius: 20px !important;
  background: var(--surface) !important;
  box-shadow: var(--shadow-md);
}

/* шапка карточки */
.s2026-main .bp-page .bp-hero { margin: 0 0 26px; }
.s2026-main .bp-page .bp-kicker {
  display: inline-block;
  margin: 0 0 12px;
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--tint-3);
  color: var(--brand-d);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .1em;
  line-height: 1.4;
  text-transform: uppercase;
}
.s2026-main .bp-page .bp-title,
.s2026-main .bp-page .bp-hero h1 {
  margin: 0 0 12px !important;
  color: var(--heading);
  font-size: clamp(27px, 3.6vw, 38px) !important;
  line-height: 1.15;
  text-align: left !important;
}
.s2026-main .bp-page .bp-lead {
  max-width: 62ch;
  margin: 0;
  color: var(--muted);
  font-size: 15.5px;
  line-height: 1.65;
}

/* поля */
.s2026-main .bp-page .bp-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin: 0 0 26px;
}
.s2026-main .bp-page .bp-field { margin: 0; }
.s2026-main .bp-page .bp-label {
  display: block;
  margin: 0 0 8px;
  color: var(--heading) !important;
  font-size: 14px;
  font-weight: 700;
}
.s2026-main .bp-page .bp-req { color: var(--red) !important; }

.s2026-main .bp-page #reg,
.s2026-main .bp-page #reg_fio,
.s2026-main .bp-page #reg_email {
  display: block;
  float: none;
  width: 100%;
  max-width: 100%;
  height: 54px;
  margin: 0;
  padding: 0 16px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--tint-5);
  color: var(--text);
  font-family: var(--font);
  font-size: 16.5px;
  font-style: normal;
  line-height: 52px;
  box-shadow: none;
  transition: border-color .15s, background .15s, box-shadow .15s;
  -webkit-appearance: none;
  appearance: none;
}
.s2026-main .bp-page #reg::placeholder,
.s2026-main .bp-page #reg_fio::placeholder,
.s2026-main .bp-page #reg_email::placeholder { color: var(--muted); font-style: normal; opacity: 1; }
.s2026-main .bp-page #reg:focus,
.s2026-main .bp-page #reg_fio:focus,
.s2026-main .bp-page #reg_email:focus {
  outline: none;
  border-color: var(--brand);
  background: var(--surface);
  box-shadow: 0 0 0 4px rgba(30, 98, 141, .12);
}
html[data-theme="dark"] .s2026-main .bp-page #reg,
html[data-theme="dark"] .s2026-main .bp-page #reg_fio,
html[data-theme="dark"] .s2026-main .bp-page #reg_email {
  border-color: var(--line);
  background: var(--tint-5);
  color: var(--text);
}
html[data-theme="dark"] .s2026-main .bp-page #reg:focus,
html[data-theme="dark"] .s2026-main .bp-page #reg_fio:focus,
html[data-theme="dark"] .s2026-main .bp-page #reg_email:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 4px rgba(79, 168, 220, .18);
}

.s2026-main .bp-page .bp-hint {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

/* согласие с политикой (выводит chekbox.php) */
.s2026-main .bp-page .bp-consent {
  margin: 4px 0 0;
  padding: 12px 14px;
  border: 1px solid var(--line-2);
  border-radius: 10px;
  background: var(--tint-5);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}
.s2026-main .bp-page .bp-consent label {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  margin: 0;
  color: var(--muted) !important;
  font-size: 13px !important;
  line-height: 1.55 !important;
}
.s2026-main .bp-page .bp-consent input[type="checkbox"] {
  flex: none;
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  accent-color: var(--brand);
}
.s2026-main .bp-page .bp-consent a {
  color: var(--brand) !important;
  text-decoration: underline;
}

.s2026-main .bp-page .bp-submit[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 54px;
  margin: 2px 0 0;
  padding: 12px 24px !important;
  border: 0 !important;
  border-radius: 12px !important;
  background: var(--brand-bg) !important;
  background-image: linear-gradient(180deg, #2f7aa8, var(--brand-bg)) !important;
  color: #fff !important;
  font-family: var(--font) !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  letter-spacing: .01em;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(30, 98, 141, .22);
  transition: filter .15s, transform .05s;
}
.s2026-main .bp-page .bp-submit[type="submit"]:hover { filter: brightness(0.98); }
.s2026-main .bp-page .bp-submit[type="submit"]:active { transform: translateY(1px); }
html[data-theme="dark"] .s2026-main .bp-page .bp-submit[type="submit"] {
  background: var(--brand-bg) !important;
  background-image: linear-gradient(180deg, #2f7ba8, var(--brand-bg)) !important;
  color: #fff !important;
  box-shadow: 0 6px 16px rgba(0, 0, 0, .4);
}

@media (max-width: 640px) {
  .s2026-main .bp-page.blok_zayavka { border-radius: 16px !important; }
  .s2026-main .bp-page .bp-title,
  .s2026-main .bp-page .bp-hero h1 { font-size: 26px !important; }
  .s2026-main .bp-page .bp-submit[type="submit"] { font-size: 15px !important; }
}

/* карточка на тёмной теме должна отличаться от фона main */
html[data-theme="dark"] .s2026-main .bp-page.blok_zayavka {
  background: var(--tint-2) !important;
}

/* сбрасываем старую рамку/ширину у контейнера, когда внутри карточки */
.s2026-main .blok_zayavka:has(> .bp-results) {
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: none !important;
  box-shadow: none !important;
}

/* =========================================================
   Результат поиска: выдача благодарственных писем карточками
   ========================================================= */

.s2026-main .bp-results {
  width: auto !important;
  max-width: 1040px !important;
  margin: 0 auto !important;
  padding: clamp(20px, 3.2vw, 34px) !important;
  border: 1px solid var(--line) !important;
  border-radius: 20px !important;
  background: var(--surface) !important;
  box-shadow: var(--shadow-md);
}

.s2026-main .bp-results__head { margin: 0 0 20px; }
.s2026-main .bp-results__head h1 {
  margin: 10px 0 8px !important;
  color: var(--heading);
  font-size: clamp(24px, 3vw, 32px) !important;
  line-height: 1.2;
  text-align: left !important;
}
.s2026-main .bp-results__lead {
  max-width: 70ch;
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.6;
}

.s2026-main .bp-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}

.s2026-main .bp-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--tint-5);
  box-shadow: var(--shadow-sm);
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.s2026-main .bp-card:hover {
  border-color: var(--brand);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.s2026-main .bp-card__top { display: flex; align-items: center; gap: 10px; }
.s2026-main .bp-card__icon {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: var(--tint-3);
  color: var(--brand-d);
}
.s2026-main .bp-card__icon svg { display: block; width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.s2026-main .bp-card__badge {
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--tint-3);
  color: var(--brand-d);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .05em;
  line-height: 1.4;
  text-transform: uppercase;
}

.s2026-main .bp-card__title {
  margin: 2px 0 0 !important;
  color: var(--heading) !important;
  font-size: 17px !important;
  font-weight: 700 !important;
  line-height: 1.35 !important;
}
.s2026-main .bp-card__meta {
  display: grid;
  gap: 3px;
  margin: 0 !important;
  color: var(--muted) !important;
  font-size: 13.5px;
  line-height: 1.55;
}
.s2026-main .bp-card__meta b { color: var(--text); font-weight: 600; }

.s2026-main .bp-card__participant {
  padding: 9px 12px;
  border-radius: 10px;
  background: var(--tint-4);
  color: var(--muted) !important;
  font-size: 13px;
  line-height: 1.5;
}
.s2026-main .bp-card__participant span {
  display: block;
  margin: 0 0 1px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  opacity: .8;
}
.s2026-main .bp-card__participant b { color: var(--text); font-weight: 600; }

.s2026-main .bp-card__date {
  margin: 0 !important;
  color: var(--muted) !important;
  font-size: 12.5px;
  line-height: 1.45;
}

.s2026-main .bp-card__actions {
  display: grid;
  gap: 8px;
  margin-top: auto;
}

.s2026-main .bp-card__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--brand-bg);
  color: #fff !important;
  font-size: 14.5px;
  font-weight: 700;
  text-decoration: none !important;
  box-shadow: 0 4px 12px rgba(30, 98, 141, .18);
  transition: background-color .15s, border-color .15s, color .15s, transform .05s;
}
.s2026-main .bp-card__btn:hover { background: var(--brand-bg-hover); color: #fff !important; }
.s2026-main .bp-card__btn:active { transform: translateY(1px); }
.s2026-main .bp-card__btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.s2026-main .bp-card__btn--ghost {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--brand-d) !important;
  box-shadow: none;
}
.s2026-main .bp-card__btn--ghost:hover {
  border-color: var(--brand);
  background: var(--tint-4);
  color: var(--brand) !important;
}

.s2026-main .bp-empty {
  padding: 26px;
  border: 1px dashed var(--line);
  border-radius: 14px;
  text-align: center;
  color: var(--muted);
}

html[data-theme="dark"] .s2026-main .bp-results { background: var(--tint-2) !important; }
html[data-theme="dark"] .s2026-main .bp-card { background: var(--tint-2); }

@media (max-width: 640px) {
  .s2026-main .bp-results { border-radius: 16px !important; }
  .s2026-main .bp-cards { grid-template-columns: 1fr; }
}
