/* «Итоги встречи» — общие стили сайта.
 *
 * Здесь только то, что нужно всем страницам: токены, типографика, кнопки, формы, карточки, подвал.
 * Лендинг (B2) кладёт свои секции в site/css/landing.css и подключает вторым файлом — базу не правит,
 * чтобы /pay и /upload не разъехались с главной. Правило одно: никаких тяжёлых картинок и шрифтов,
 * страница должна открываться с телефона за 2–3 секунды.
 */

@font-face {
  font-family: "Commissioner";
  src: url("/fonts/commissioner-cyrillic.woff2") format("woff2");
  font-weight: 300 700;
  font-display: swap;
  unicode-range: U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Commissioner";
  src: url("/fonts/commissioner-latin.woff2") format("woff2");
  font-weight: 300 700;
  font-display: swap;
  unicode-range: U+0000-00FF, U+2000-206F, U+20B0-20BF;
}

:root {
  --bg: #ffffff;
  --bg-soft: #f5f4f1;
  --fg: #16181d;
  --muted: #5c6270;
  --accent: #1f5fd8;
  --accent-dark: #17489f;
  --accent-soft: #eaf0fd;
  --ok: #1a7f52;
  --warn: #9a4a12;
  --border: #dfe1e6;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(20, 24, 34, 0.06), 0 8px 24px rgba(20, 24, 34, 0.06);
  --wrap: 980px;
  --font: "Commissioner", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { line-height: 1.2; margin: 0 0 0.5em; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: clamp(28px, 5vw, 42px); }
h2 { font-size: clamp(22px, 3.6vw, 30px); }
h3 { font-size: 20px; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.2em; }
li { margin-bottom: 0.4em; }
a { color: var(--accent); }
a:hover { color: var(--accent-dark); }
small, .small { font-size: 15px; color: var(--muted); }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.section { padding: 40px 0; }
.lead { font-size: 19px; color: var(--muted); }
.muted { color: var(--muted); }
.center { text-align: center; }

.skip {
  position: absolute; left: -9999px; top: 0; background: var(--fg); color: #fff;
  padding: 10px 14px; border-radius: 0 0 var(--radius) 0; z-index: 10;
}
.skip:focus { left: 0; }

/* --- шапка и подвал --- */
.top { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: baseline; padding-top: 18px; padding-bottom: 18px; }
.brand { font-weight: 700; font-size: 19px; color: var(--fg); text-decoration: none; }
.top-note { margin: 0; color: var(--muted); font-size: 15px; }

.footer {
  margin-top: 48px; padding: 28px 0 40px; border-top: 1px solid var(--border);
  color: var(--muted); font-size: 15px; background: var(--bg-soft);
}
.footer a { color: var(--muted); }
.footer ul { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 18px; }

/* --- кнопки --- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 22px; border-radius: var(--radius); border: 1px solid transparent;
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer;
  min-height: 48px; transition: background-color 0.15s ease, border-color 0.15s ease;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }
.btn-secondary { background: #fff; color: var(--fg); border-color: var(--border); }
.btn-secondary:hover { border-color: var(--muted); color: var(--fg); }
.btn-wide { width: 100%; }
.btn[disabled] { opacity: 0.6; cursor: progress; }

.price { font-weight: 700; font-size: 20px; }
.price-note { color: var(--muted); font-size: 15px; }

/* --- карточки --- */
.card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow);
}
.card + .card { margin-top: 16px; }
.lead + .card { margin-top: 20px; } /* /pay и /upload: карточка не прилипает к подзаголовку (landing.css обнуляет margin у p) */
.cards { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.note { background: var(--accent-soft); border-radius: var(--radius); padding: 14px 16px; }
.note-warn { background: #fdf1e6; }

/* --- формы --- */
.field { margin-bottom: 16px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; }
.field .hint { display: block; color: var(--muted); font-size: 15px; margin-bottom: 6px; }
input[type="text"], input[type="email"], input[type="url"], input[type="file"] {
  width: 100%; padding: 13px 14px; font: inherit; color: var(--fg);
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius); min-height: 48px;
}
input:focus-visible, .btn:focus-visible, a:focus-visible {
  outline: 3px solid var(--accent); outline-offset: 2px;
}
.error { color: #b3261e; font-weight: 600; }
.ok { color: var(--ok); font-weight: 600; }

/* --- QR перевода --- */
.qr { display: flex; flex-wrap: wrap; gap: 20px; align-items: center; }
.qr img { width: 220px; height: auto; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; }
.qr-side { flex: 1 1 260px; }
/* /pay: номер получателя крупно + «Скопировать»; запасной путь (ссылка Сбера, QR) — свёрнут */
.pay-phone-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin: 0 0 16px; }
.pay-phone { font-size: 28px; letter-spacing: 0.02em; font-variant-numeric: tabular-nums; }
.btn-small { padding: 8px 14px; font-size: 15px; }
.pay-alt { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--border); }
.pay-alt summary { cursor: pointer; color: var(--muted); font-size: 15px; }
.pay-alt .qr { margin-top: 14px; }
/* сумма перевода — отдельной выделенной строкой: её вводят руками, ошибка в сумме = возврат (оферта п. 3.1) */
.pay-amount { margin: 0 0 16px; padding: 12px 16px; background: var(--accent-soft); border-radius: var(--radius); font-size: 17px; }
.pay-amount strong { font-size: 24px; color: var(--accent-dark); white-space: nowrap; }
/* блок «не удалось загрузить реквизиты» и экран после заявки */
.note p:last-child { margin-bottom: 0; }
#pay-no-qr, #pay-info-fail { margin-bottom: 16px; }
.pay-done-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.steps { counter-reset: step; list-style: none; padding: 0; }
.steps li { counter-increment: step; position: relative; padding-left: 38px; margin-bottom: 12px; }
.steps li::before {
  content: counter(step); position: absolute; left: 0; top: 1px;
  width: 26px; height: 26px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-dark);
  font-weight: 700; font-size: 15px; display: flex; align-items: center; justify-content: center;
}

/* --- баннер согласия на cookie (js/consent.js) --- */
.cookie-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center; justify-content: space-between;
  padding: 14px 20px; background: #fff; border-top: 1px solid var(--border); box-shadow: var(--shadow);
}
.cookie-bar p { margin: 0; font-size: 15px; }
.cookie-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.cookie-actions .btn { padding: 10px 16px; min-height: 40px; }

[hidden] { display: none !important; }

@media (max-width: 560px) {
  body { font-size: 16px; }
  .section { padding: 28px 0; }
  .btn { width: 100%; }
  .qr img { width: 100%; max-width: 260px; }
}
