/* Стартовый набор сайтов Batele: основа, на которой модель пишет свой дизайн (styles.css важнее).
   Сброс, системные шрифты с ң ө ү, поля ввода под палец, видимый фокус, плашка Batele. */

*,
*::before,
*::after {
  box-sizing: border-box;
}

/* Шкала скруглений: её задаёт стиль (theme.css), без стиля — 8, 12 и 20 px. Слабее любого :root. */
:where(:root) {
  --bt-radius-sm: 8px;
  --bt-radius-md: 12px;
  --bt-radius-lg: 20px;
  --bt-radius: var(--bt-radius-md);
}

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

body {
  margin: 0;
  min-height: 100svh;
  font-family:
    system-ui,
    -apple-system,
    'Segoe UI',
    Roboto,
    'Noto Sans',
    'Helvetica Neue',
    Arial,
    sans-serif;
  font-size: 16px;
  /* Текст чуть плотнее обычного: тонкие начертания на сайтах Batele не нужны (запрет «Тонкие
     начертания»). У шрифта без 450 браузер берёт ближайшее — 500 или 400. */
  font-weight: 450;
  line-height: 1.5;
  overflow-wrap: anywhere;
  -webkit-font-smoothing: antialiased;
}

/* Заголовки — полужирные. Нет такого начертания у шрифта — остаётся своё, поддельный жирный браузер
   не рисует (у рукописных и одноначертательных он некрасивый). */
h1,
h2,
h3 {
  font-weight: 600;
  font-synthesis-weight: none;
}

h1,
h2,
h3,
h4,
p,
figure,
blockquote,
ul,
ol {
  margin: 0;
}

img,
svg,
video,
picture {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

/* 16px — iPhone не увеличивает страницу при фокусе; 44px — под палец. Флажки, переключатели и
   ползунки — своего размера (их нажимают вместе с подписью), :where — чтобы класс сайта был сильнее. */
input:where(:not([type='checkbox'], [type='radio'], [type='range'], [type='color'])),
textarea,
select {
  font-size: max(16px, 1em);
  min-height: 44px;
}

button:where(:not([role='checkbox'], [role='radio'], [role='switch'])),
[role='button'] {
  min-height: 44px;
}

button,
[role='button'] {
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

[hidden] {
  display: none !important;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* QR-код: <bt-qr> превращается в SVG; тёмный на белом в любой теме — так его читают все сканеры. */
.bt-qr {
  width: 100%;
  max-width: 220px;
  height: auto;
  border-radius: var(--bt-radius);
}

/* Состояние формы: kit.js показывает [data-bt-ok] или [data-bt-error] и ставит data-state. */
form[data-state='sending'] button[type='submit'] {
  opacity: 0.6;
  pointer-events: none;
}

/* Ловушка для ботов: человек её не видит. */
.bt-trap {
  position: absolute !important;
  left: -10000px !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Плашка «Сделано на Batele» — на тарифах без её снятия. */
.bt-badge {
  display: block;
  width: fit-content;
  margin: 32px auto 24px;
  padding: 6px 14px;
  border-radius: 999px;
  font:
    500 13px/1.4 system-ui,
    -apple-system,
    'Segoe UI',
    Roboto,
    sans-serif;
  color: #1f1d1a;
  background: #f6f3ec;
  text-decoration: none;
  border: 1px solid #ded8cc;
}

/* Презентация: data-bt="deck", внутри <section> — слайды. kit.js показывает один слайд и ставит
   навигацию; без скрипта и при печати видны все слайды подряд, каждый — страница 16:9. */
.bt-deck {
  position: relative;
  min-height: 100dvh;
}

.bt-deck > section {
  display: none;
  min-height: 100dvh;
  padding: clamp(20px, 5vw, 64px);
  flex-direction: column;
  justify-content: center;
}

.bt-deck > section.bt-slide-active {
  display: flex;
}

.bt-deck-nav {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  background: rgb(0 0 0 / 0.55);
  color: #fff;
  font-size: 14px;
  backdrop-filter: blur(8px);
}

.bt-deck-nav button {
  min-width: 44px;
  min-height: 44px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: inherit;
  font-size: 20px;
}

.bt-deck-nav button:disabled {
  opacity: 0.35;
  cursor: default;
}

.bt-deck-counter {
  min-width: 56px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

@media print {
  @page {
    size: 1280px 720px;
    margin: 0;
  }

  .bt-deck {
    min-height: 0;
  }

  .bt-deck > section {
    display: flex !important;
    width: 1280px;
    height: 720px;
    min-height: 0;
    overflow: hidden;
    break-after: page;
  }

  .bt-deck-nav,
  .bt-badge {
    display: none !important;
  }
}
