/* ===== Базовый сброс — замена bootstrap.min.css =====
   Bootstrap на сайте использовался только как нормализатор: ни одного его компонента
   в разметке не осталось (сетка, alert'ы и кнопки были на трёх страницах, все переписаны
   в стиле сайта). Но его Reboot задавал базу, на которую вёрстка опирается: border-box,
   нулевые поля у body, наследование шрифта у полей ввода. Здесь ровно эта база — 227 КБ
   ради неё грузить не за чем.

   Значения повторяют Reboot Bootstrap 5, чтобы вид не поехал; расхождения проверены
   поэлементным сравнением геометрии до и после замены. */

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

body {
    margin: 0;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.5;
    text-align: var(--bs-body-text-align, left);
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

/* Заголовки. Размеры у сайта свои почти везде, но обнулённый верхний отступ
   и нижний в .5rem — то, от чего отсчитывает существующая вёрстка. */
h1, h2, h3, h4, h5, h6 {
    margin-top: 0;
    margin-bottom: .5rem;
    font-weight: 500;
    line-height: 1.2;
}
h1 { font-size: calc(1.375rem + 1.5vw); }
h2 { font-size: calc(1.325rem + .9vw); }
h3 { font-size: calc(1.3rem + .6vw); }
h4 { font-size: calc(1.275rem + .3vw); }
h5 { font-size: 1.25rem; }
h6 { font-size: 1rem; }

@media (min-width: 1200px) {
    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    h3 { font-size: 1.75rem; }
    h4 { font-size: 1.5rem; }
}

p { margin-top: 0; margin-bottom: 1rem; }

ul, ol { padding-left: 2rem; margin-top: 0; margin-bottom: 1rem; }
ul ul, ol ul, ul ol, ol ol { margin-bottom: 0; }

dl, dd { margin-top: 0; margin-bottom: 1rem; }
dt { font-weight: 700; }

hr {
    margin: 1rem 0;
    color: inherit;
    border: 0;
    border-top: 1px solid;
    opacity: .25;
}

b, strong { font-weight: bolder; }
small { font-size: .875em; }

a { color: #0d6efd; text-decoration: underline; }
a:not([href]):not([class]),
a:not([href]):not([class]):hover { color: inherit; text-decoration: none; }

/* Моноширинные: у сайта свои семейства, важна только базовая нормализация размера */
code, kbd, pre, samp { font-size: 1em; }
pre { margin-top: 0; margin-bottom: 1rem; overflow: auto; }

img, svg { vertical-align: middle; }

table { caption-side: bottom; border-collapse: collapse; }
th { text-align: inherit; text-align: -webkit-match-parent; }
thead, tbody, tfoot, tr, td, th { border-color: inherit; border-style: solid; border-width: 0; }

/* Поля ввода: без этого браузер подставляет им свой системный шрифт вместо шрифта сайта */
button, input, optgroup, select, textarea {
    margin: 0;
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
}
button, select { text-transform: none; }
button,
[type="button"],
[type="reset"],
[type="submit"] { -webkit-appearance: button; }
button:not(:disabled),
[type="button"]:not(:disabled),
[type="reset"]:not(:disabled),
[type="submit"]:not(:disabled) { cursor: pointer; }
textarea { resize: vertical; }
[role="button"] { cursor: pointer; }

fieldset { min-width: 0; padding: 0; margin: 0; border: 0; }
legend { float: left; width: 100%; padding: 0; margin-bottom: .5rem; line-height: inherit; font-size: calc(1.275rem + .3vw); }
@media (min-width: 1200px) { legend { font-size: 1.5rem; } }

label { display: inline-block; }

::-webkit-datetime-edit-fields-wrapper,
::-webkit-datetime-edit-text,
::-webkit-datetime-edit-minute,
::-webkit-datetime-edit-hour-field,
::-webkit-datetime-edit-day-field,
::-webkit-datetime-edit-month-field,
::-webkit-datetime-edit-year-field { padding: 0; }
::-webkit-inner-spin-button { height: auto; }
[type="search"] { outline-offset: -2px; -webkit-appearance: textfield; }
::-webkit-search-decoration { -webkit-appearance: none; }
::-webkit-color-swatch-wrapper { padding: 0; }
::file-selector-button { font: inherit; -webkit-appearance: button; }

summary { display: list-item; cursor: pointer; }
[hidden] { display: none !important; }
