* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
    /* ===== ПАЛИТРА ОАО «РЖД» ПО БРЕНДБУКУ =====
       RZD-Red  Pantone 1795C · CMYK 0-94-100-0 · RGB 226-26-26 · RAL 3020
       White                                    · RGB 255-255-255 · RAL 9010
       Black    Process black · CMYK 0-0-0-100  · RGB 0-0-0       · RAL 9017
       Брендбук «Транспортная безопасность» (v.2026.10.15), «Цвета и градиенты»:
         Чёрный #000000 · Серый #4A4A4A · Красный #E21A1A · Светло-серый #D2D2D2 · Белый #FFFFFF.
       Серый текст — фирменный #4A4A4A, светлые линии и подложки — оттенки светло-серого. */
    --red: #e21a1a;
    --red-dark: #a81414;
    /* МЕЛКИЙ текст на светлом: чистый #e21a1a на сером #f5f5f5 даёт
       4.38:1 — ниже нормы WCAG AA. Этот вариант даёт 5.68:1. */
    --red-text: #c11616;
    --black: #000000;
    --gray-80: #4a4a4a;
    --gray-60: #666666;
    --gray-40: #999999;
    --gray-20: #d2d2d2;
    --ink: #1c1c1c;
    --gray: #4a4a4a;
    --line: #e3e3e3;
    --bg: #f5f5f5;
    --white: #ffffff;
    --font-body: 'Rubik', 'Helvetica Neue', Arial, sans-serif;
    --font-head: 'RussianRail G Pro', 'Rubik', Arial, sans-serif;
}
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
section[id] { scroll-margin-top: 96px; }
img { max-width: 100%; }
::selection { background: var(--red); color: #fff; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
body {
    font-family: var(--font-body);
    color: var(--ink);
    background: var(--white);
    line-height: 1.6;
}
h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.2; letter-spacing: -.01em; }
.hero h1 { letter-spacing: -.02em; }
a { text-decoration: none; color: inherit; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* Topbar */
.topbar {
    background: var(--ink);
    color: #cccccc;
    font-size: 13px;
}
.topbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 42px;
    flex-wrap: wrap;
}
.topbar a { color: #cccccc; transition: color .2s; }
.topbar a:hover { color: #fff; }
.topbar-right { display: flex; gap: 24px; align-items: center; }
.topbar-right i { color: var(--red); margin-right: 6px; }

/* Header */
header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(255,255,255,.96);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--line);
}
header .container {
    display: flex; align-items: center; justify-content: space-between;
    gap: 32px; height: 78px;
}
header nav { flex: 1; }
.logo { display: flex; align-items: center; gap: 14px; }
.logo-mark {
    width: 46px; height: 46px; border-radius: 10px;
    background: var(--red); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px; flex-shrink: 0;
}
.rzd-logo {
    width: 92px; height: auto; display: block;
    color: var(--red); flex-shrink: 0; object-fit: contain;
}
.logo-sep { width: 1px; height: 38px; background: var(--line); flex-shrink: 0; }
footer .rzd-logo { color: #fff; width: 84px; }
footer .logo-sep { background: #262626; }
.logo-badge {
    display: inline-flex; align-items: center; justify-content: center;
    background: #fff; padding: 10px 14px; border-radius: 8px;
}
.logo-text b { font-family: var(--font-head); font-size: 15px; font-weight: 700; letter-spacing: -.2px; display: block; }
header .logo-text b { text-transform: uppercase; letter-spacing: .4px; font-size: 14px; white-space: nowrap; }
header .logo { flex-shrink: 0; }
.logo-text span { font-size: 12px; color: var(--gray); }
header nav ul {
    display: grid; grid-auto-flow: column;
    grid-auto-columns: 1fr; gap: 12px;
    list-style: none; align-items: flex-start;
}
header nav li { display: flex; justify-content: center; }
header nav a {
    font-size: 13px; font-weight: 500; color: var(--ink);
    position: relative; padding: 4px 0; transition: color .2s;
    display: flex; flex-direction: column; align-items: center;
    justify-content: flex-start; gap: 7px; text-align: center; line-height: 1.25;
}
header nav a:hover { color: var(--red); }
header nav a::after {
    content: ''; position: absolute; left: 0; bottom: -2px;
    width: 0; height: 2px; background: var(--red); transition: width .25s;
}
header nav a:hover::after { width: 100%; }
header nav a i { color: var(--red); margin-right: 0; font-size: 16px; }
.eyebrow i { margin-right: 7px; font-size: 12px; }
.stat i { display: block; font-size: 17px; color: rgba(226,26,26,.55); margin-bottom: 12px; }
.about-visual h3 i { margin-right: 10px; font-size: 20px; color: #fff; }
.cta h2 i { color: var(--red); margin-right: 12px; }
footer li i { color: var(--red); margin-right: 9px; font-size: 12.5px; width: 14px; text-align: center; }
.footer-bottom i { color: var(--red); margin-right: 8px; }
.footer-bottom a { transition: color .2s; }
.footer-bottom a:hover { color: var(--red); }
form label i { color: var(--red); margin-right: 7px; }
.burger { display: none; font-size: 22px; cursor: pointer; color: var(--ink); background: none; border: none; }
header nav a.active { color: var(--red); }
header nav a.active::after { width: 100%; }
.totop {
    position: fixed; right: 24px; bottom: 24px; z-index: 90;
    width: 48px; height: 48px; border-radius: 50%; border: none;
    background: var(--red); color: #fff; font-size: 16px; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; visibility: hidden; transform: translateY(10px);
    transition: opacity .25s, transform .25s, visibility .25s, background .25s;
    box-shadow: 0 12px 30px -12px rgba(226,26,26,.7);
}
.totop.show { opacity: 1; visibility: visible; transform: translateY(0); }
.totop:hover { background: var(--red-dark); }

/* Hero */
.hero {
    position: relative;
    background: linear-gradient(120deg, #1c1c1c 0%, #2e2e2e 100%);
    color: #fff; overflow: hidden;
}
.hero::before {
    content: ''; position: absolute; inset: 0;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="60" height="60"><path d="M0 30h60M30 0v60" stroke="%23ffffff" stroke-opacity="0.04" stroke-width="1"/></svg>');
}
.hero-accent {
    position: absolute; right: -120px; top: -80px;
    width: 480px; height: 480px; border-radius: 50%;
    background: radial-gradient(circle, rgba(226,26,26,.35), transparent 70%);
}
.hero .container { position: relative; padding: 100px 24px 110px; }
.hero-tag {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(226,26,26,.15); border: 1px solid rgba(226,26,26,.4);
    color: #ff8080; padding: 7px 16px; border-radius: 100px;
    font-size: 13px; font-weight: 600; margin-bottom: 26px;
}
.hero h1 {
    font-size: clamp(32px, 5vw, 56px); font-weight: 800;
    max-width: 820px; letter-spacing: -1px; margin-bottom: 22px;
}
.hero p { font-size: 18px; color: #cccccc; max-width: 620px; margin-bottom: 38px; }
.hero-btns { display: flex; gap: 16px; flex-wrap: wrap; }
.btn {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 15px 30px; border-radius: 10px; font-weight: 600;
    font-size: 15px; cursor: pointer; border: none; transition: all .25s;
}
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-dark); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.3); }
.btn-ghost:hover { background: rgba(255,255,255,.1); }

/* Stats */
.stats {
    display: grid; grid-template-columns: repeat(4,1fr);
    gap: 1px; background: var(--line);
    border: 1px solid var(--line); border-radius: 16px; overflow: hidden;
    margin-top: -55px; position: relative; z-index: 5;
    box-shadow: 0 20px 50px -20px rgba(0,0,0,.25);
}
.stat { background: #fff; padding: 34px 28px; text-align: center; }
.stat b { font-family: var(--font-head); font-size: 36px; font-weight: 700; color: var(--red); display: block; }
.stat span { font-size: 14px; color: var(--gray); }

/* Section */
section.block { padding: 90px 0; }
.head { max-width: 860px; margin-bottom: 54px; }
/* Абзац на всю ширину блока (860px): при выключке по ширине без переносов
   в колонке 640px пробелы растягивались до 30px, в 860px — не больше 16–18px */
.head p { max-width: 860px; }
.eyebrow {
    color: var(--red); font-weight: 700; font-size: 13px;
    letter-spacing: 1.5px; text-transform: uppercase; margin-bottom: 14px;
}
.head h2 { font-size: clamp(28px,3.6vw,40px); font-weight: 800; letter-spacing: -.8px; margin-bottom: 16px; }
.head p { color: var(--gray); font-size: 16.5px; }

/* Services */
.services-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.service {
    background: #fff; border: 1px solid var(--line);
    border-radius: 16px; padding: 34px 30px; transition: all .3s;
}
.service:hover { border-color: var(--red); transform: translateY(-5px); box-shadow: 0 24px 40px -24px rgba(226,26,26,.35); }
.service-icon {
    width: 56px; height: 56px; border-radius: 12px;
    background: rgba(226,26,26,.09); color: var(--red);
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; margin-bottom: 22px;
}
.service h3 { font-size: 19px; font-weight: 700; margin-bottom: 12px; }
.service p { color: var(--gray); font-size: 14.5px; }

/* About */
.about { background: var(--bg); }
.about-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.about ul { list-style: none; margin-top: 26px; }
.about li { display: flex; gap: 14px; margin-bottom: 18px; align-items: flex-start; }
.about li i { color: var(--red); font-size: 18px; margin-top: 3px; }
.about li b { font-family: var(--font-head); display: block; font-size: 15px; font-weight: 600; margin-bottom: 2px; }
.about li span { color: var(--gray); font-size: 14.5px; }

/* Кинологическая служба — направления */
.k9-list { list-style: none; margin-top: 30px; display: grid; gap: 12px; }
.k9-list li {
    display: flex; gap: 18px; align-items: flex-start;
    background: #fff; border: 1px solid var(--line);
    border-left: 3px solid var(--line);
    border-radius: 12px; padding: 20px 24px;
    transition: border-left-color .25s, transform .25s, box-shadow .25s;
}
.k9-list li:hover {
    border-left-color: var(--red); transform: translateX(4px);
    box-shadow: 0 16px 30px -24px rgba(226,26,26,.55);
}
.k9-list li > i {
    width: 40px; height: 40px; flex-shrink: 0; border-radius: 10px;
    background: rgba(226,26,26,.09); color: var(--red);
    display: flex; align-items: center; justify-content: center;
    font-size: 16px; margin-top: 2px;
}
.k9-list li b {
    font-family: var(--font-head); display: block;
    font-size: 15.5px; font-weight: 600; margin-bottom: 4px; color: var(--ink);
}
.k9-list li span { color: var(--gray); font-size: 14.5px; display: block; }
.about-visual {
    background: linear-gradient(140deg, var(--red), var(--red-dark));
    border-radius: 20px; padding: 46px; color: #fff;
    position: relative; overflow: hidden;
}
.about-visual i.bg { position: absolute; right: -30px; bottom: -30px; font-size: 200px; opacity: .1; }
.about-visual h3 { font-size: 26px; font-weight: 800; margin-bottom: 16px; position: relative; }
.about-visual p { color: rgba(255,255,255,.9); position: relative; }

/* Regions / activities strip */
.activities { display: grid; grid-template-columns: repeat(2,1fr); gap: 20px; }
.act {
    display: flex; gap: 20px; padding: 28px;
    border: 1px solid var(--line); border-radius: 14px; background: #fff; transition: border-color .25s;
}
.act:hover { border-color: var(--red); }
.act .num { font-family: var(--font-head); font-size: 30px; font-weight: 700; color: rgba(226,26,26,.25); line-height: 1; }
.act .num i { font-size: 28px; }
.act h4 { font-size: 17px; margin-bottom: 8px; }
.act p { color: var(--gray); font-size: 14.5px; }

/* CTA */
.cta { background: var(--ink); color: #fff; }
.cta .container {
    padding: 66px 24px; display: flex; align-items: center;
    justify-content: space-between; gap: 40px; flex-wrap: wrap;
}
.cta h2 { font-size: 32px; font-weight: 800; margin-bottom: 10px; }
.cta p { color: #cccccc; }

/* Contact */
.contact-wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; }
.contact-info .ci {
    display: flex; gap: 18px; padding: 22px 0; border-bottom: 1px solid var(--line);
}
.contact-info .ci:last-child { border-bottom: none; }
.contact-info .ci i {
    width: 46px; height: 46px; flex-shrink: 0; border-radius: 10px;
    background: rgba(226,26,26,.09); color: var(--red);
    display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.contact-info .ci b { font-family: var(--font-head); font-weight: 600; display: block; margin-bottom: 3px; }
.contact-info .ci span { color: var(--gray); font-size: 14.5px; }
.contact-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 20px; }
.contact-grid .ci {
    display: flex; gap: 18px; align-items: center;
    padding: 26px 28px; border: 1px solid var(--line);
    border-radius: 14px; background: #fff; transition: border-color .25s, transform .25s;
}
.contact-grid a.ci:hover { border-color: var(--red); transform: translateY(-3px); }
.contact-grid .ci i {
    width: 46px; height: 46px; flex-shrink: 0; border-radius: 10px;
    background: rgba(226,26,26,.09); color: var(--red);
    display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.contact-grid .ci b { font-family: var(--font-head); font-weight: 600; display: block; margin-bottom: 3px; color: var(--ink); }
.contact-grid .ci span { color: var(--gray); font-size: 14.5px; }
form { background: var(--bg); border-radius: 18px; padding: 38px; }
form label { font-size: 14px; font-weight: 600; display: block; margin-bottom: 7px; }
form input, form textarea {
    width: 100%; padding: 13px 15px; border: 1px solid var(--line);
    border-radius: 10px; font-family: inherit; font-size: 15px;
    margin-bottom: 18px; background: #fff; transition: border-color .2s;
}
form input:focus, form textarea:focus { outline: none; border-color: var(--red); }
form textarea { resize: vertical; min-height: 110px; }
form select {
    width: 100%; padding: 13px 15px; border: 1px solid var(--line);
    border-radius: 10px; font-family: inherit; font-size: 15px;
    margin-bottom: 18px; background: #fff; color: var(--ink);
    transition: border-color .2s; appearance: none;
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="12" height="8"><path d="M1 1l5 5 5-5" stroke="%235a5f6b" stroke-width="1.6" fill="none" stroke-linecap="round"/></svg>');
    background-repeat: no-repeat; background-position: right 16px center;
}
form select:focus { outline: none; border-color: var(--red); }
.form-msg { display: none; color: #14713b; font-weight: 600; margin-top: 4px; font-size: 14.5px; }
.form-msg.show { display: block; }
.form-msg.is-error { color: var(--red-text); }
.form-msg a { color: inherit; text-decoration: underline; }
.form-privacy { display: flex; gap: 10px; align-items: flex-start; color: var(--gray); font-size: 13.5px; line-height: 1.55; margin: 4px 0 20px; }
.form-privacy i { color: var(--red-text); margin-top: 4px; flex-shrink: 0; }
.form-note { color: var(--gray); font-size: 12.5px; margin-top: 14px; }
.vacancy {
    display: flex; gap: 18px; align-items: flex-start;
    background: #fff; border: 1px solid var(--line); border-radius: 14px;
    padding: 24px 26px; margin-bottom: 16px; transition: border-color .25s, transform .25s;
}
.vacancy:hover { border-color: var(--red); transform: translateY(-3px); }
.vacancy > i {
    width: 46px; height: 46px; flex-shrink: 0; border-radius: 10px;
    background: rgba(226,26,26,.09); color: var(--red);
    display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.vacancy h4 { font-size: 17px; margin-bottom: 6px; }
.vacancy p { color: var(--gray); font-size: 14.5px; }
.vacancy .tag {
    display: inline-block; margin-top: 10px; font-size: 12.5px; font-weight: 600;
    color: var(--red-text); background: rgba(226,26,26,.08);
    padding: 4px 12px; border-radius: 100px;
}
.career-form { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: clamp(22px, 3vw, 38px); min-width: 0; align-self: center; box-shadow: 0 10px 30px rgba(0,0,0,.04); }
.career-form p { text-align: left; color: var(--gray); line-height: 1.65; }
.career-form > .btn { max-width: 100%; white-space: normal; text-align: center; justify-content: center; }

/* Карьера: требование и преимущества (текст с rzd-tb.ru/job/) */
.job-req {
    display: flex; gap: 16px; align-items: flex-start;
    background: #fff; border: 1px solid var(--line); border-left: 3px solid var(--red);
    border-radius: 14px; padding: 22px 26px; margin-bottom: 34px;
}
.job-req i { color: var(--red); font-size: 20px; margin-top: 3px; }
.job-req p { font-size: 16px; color: var(--ink); }
.job-sub { font-size: 20px; font-weight: 700; margin-bottom: 18px; }
.job-perks { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-bottom: 48px; }
.job-perks li {
    display: flex; gap: 12px; align-items: flex-start;
    background: #fff; border: 1px solid var(--line); border-radius: 12px;
    padding: 18px 20px; font-size: 14.5px; color: var(--gray-80);
}
.job-perks li i { color: var(--red); margin-top: 3px; }
@media (max-width: 900px) { .job-perks { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .job-perks { grid-template-columns: 1fr; } }

/* Procurement */
/* столько колонок, сколько карточек (сейчас в «Закупках» две), на телефоне — одна */
.docs { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; }
.doc {
    display: flex; gap: 18px; align-items: flex-start; text-align: left; width: 100%;
    background: #fff; border: 1px solid var(--line); border-radius: 14px;
    padding: 24px 26px; font-family: inherit; color: var(--ink);
    cursor: pointer; transition: border-color .25s, transform .25s;
}
.doc:hover { border-color: var(--red); transform: translateY(-3px); }
.doc > i {
    width: 46px; height: 46px; flex-shrink: 0; border-radius: 10px;
    background: rgba(226,26,26,.09); color: var(--red);
    display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.doc b { font-family: var(--font-head); font-weight: 600; font-size: 16px; display: block; margin-bottom: 5px; }
.doc p { color: var(--gray); font-size: 14.5px; }
.doc .meta { display: block; color: var(--red-text); font-size: 12.5px; font-weight: 600; margin-top: 10px; }
.doc .meta i { margin-right: 7px; }

/* Licenses */
/* Ссылки на сканы. Мелкий красный текст на светлом — только --red-text (WCAG AA). */
.lic-doc { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; margin-top: 16px; font-size: 13.5px; }
.lic-doc a { color: var(--red-text); font-weight: 600; text-decoration: none; }
.lic-doc a:hover { text-decoration: underline; }
.lic-doc a i { margin-right: 7px; }
/* Пометка-заглушка: те же цвета, что в assets/legal.css */
.fill { background: #fdeaea; color: #a81414; padding: 1px 6px; border-radius: 4px; font-size: .92em; }
.lic-note {
    margin-top: 30px; display: flex; gap: 16px; align-items: flex-start;
    background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 24px 28px;
}
.lic-note i { color: var(--red); font-size: 18px; margin-top: 2px; }
.lic-note p { color: var(--gray); font-size: 14.5px; }
/* Modal */
.modal {
    position: fixed; inset: 0; z-index: 200; padding: 24px;
    background: rgba(13,13,13,.62); display: none;
    align-items: center; justify-content: center;
}
.modal.open { display: flex; }
.modal-box {
    background: #fff; border-radius: 18px; width: 100%; max-width: 840px;
    max-height: 86vh; display: flex; flex-direction: column; overflow: hidden;
}
.modal-head {
    display: flex; justify-content: space-between; align-items: flex-start;
    gap: 24px; padding: 26px 30px; border-bottom: 1px solid var(--line);
}
.modal-head h3 { font-size: 20px; }
.modal-head span { display: block; color: var(--gray); font-size: 13px; margin-top: 6px; font-family: var(--font-body); }
.modal-close { background: none; border: none; cursor: pointer; font-size: 20px; color: var(--gray); line-height: 1; transition: color .2s; }
.modal-close:hover { color: var(--red); }
.modal-body { padding: 26px 30px 34px; overflow-y: auto; }
.modal-body h4 { font-size: 16px; margin: 24px 0 8px; }
.modal-body h4:first-child { margin-top: 0; }
.ed-table { width: 100%; border-collapse: collapse; margin: 6px 0 18px; font-size: 14.5px; }
.ed-table th, .ed-table td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line); }
.ed-table th { font-weight: 600; color: var(--gray-80); background: var(--bg); }
.ed-table td { font-variant-numeric: tabular-nums; }
.modal-body a { color: var(--red-text); font-weight: 600; }
.modal-body p, .modal-body li { color: var(--gray); font-size: 14.5px; }
.modal-body ol, .modal-body ul { padding-left: 20px; margin-top: 6px; }
.modal-body li { margin-bottom: 7px; }

/* Deploy / файлы для хостинга */
/* Footer */
footer { background: #0d0d0d; color: #b3b3b3; padding: 60px 0 30px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 44px; }
footer .logo-text b { color: #fff; }
footer .logo-text span { color: #b3b3b3; }
footer p { font-size: 14px; margin-top: 16px; max-width: 340px; }
footer h4 { color: #fff; font-size: 15px; margin-bottom: 18px; }
footer ul { list-style: none; }
footer li { margin-bottom: 11px; }
footer li a { font-size: 14px; transition: color .2s; }
footer li a:hover { color: var(--red); }
.footer-bottom {
    border-top: 1px solid #262626; padding-top: 24px;
    font-size: 13px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px;
}
.holding-note {
    border-top: 1px solid #262626; margin-top: 20px; padding-top: 20px;
    font-size: 12.5px; color: #8c8c8c; line-height: 1.7;
}
.holding-note a { color: #cccccc; font-weight: 600; }
.holding-note a:hover { color: var(--red); }

@media (max-width: 900px) {
    .stats { grid-template-columns: repeat(2,1fr); }
    .services-grid { grid-template-columns: 1fr; }
    .about-wrap, .contact-grid, .contact-wrap, .activities, .footer-grid { grid-template-columns: 1fr; gap: 34px; }
    .docs { grid-template-columns: 1fr; gap: 16px; }
    .modal-body, .modal-head { padding-left: 20px; padding-right: 20px; }
    .topbar-right { gap: 14px; }
    .rzd-logo { width: 74px; }
    .logo-text b { font-size: 14px; }
    header .logo-text b { font-size: 12.5px; letter-spacing: .2px; }
}

/* =====================================================================
   ДОРАБОТКИ: доступность, мобильные платформы, cookie-баннер, 152-ФЗ
   ===================================================================== */

/* --- Доступность --- */
:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; border-radius: 4px; }
.skip-link {
    position: absolute; left: -9999px; top: 0; z-index: 999;
    background: var(--red); color: #fff; padding: 12px 20px; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }
.visually-hidden {
    position: absolute; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* --- Платформенные мелочи --- */
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { overflow-wrap: break-word; -webkit-tap-highlight-color: rgba(226,26,26,.12); }
header { -webkit-backdrop-filter: blur(8px); }   /* Safari без префикса не размывает */
.container {
    padding-left: max(24px, env(safe-area-inset-left));
    padding-right: max(24px, env(safe-area-inset-right));
}
footer { padding-bottom: calc(30px + env(safe-area-inset-bottom)); }
.totop { bottom: calc(24px + env(safe-area-inset-bottom)); }
/* 44x44 — минимальная зона нажатия по рекомендациям Apple и Google */
.burger {
    width: 44px; height: 44px; padding: 0; flex-shrink: 0;
    align-items: center; justify-content: center; margin-right: -10px;
}
footer li a, .footer-legal a { display: inline-block; padding: 3px 0; }
/* iOS иначе рисует свою внутреннюю тень и скругление */
form input, form textarea, form select { -webkit-appearance: none; appearance: none; }

/* --- Согласие на обработку ПДн (152-ФЗ) --- */
.consent {
    display: flex; gap: 10px; align-items: flex-start;
    margin: 4px 0 18px; font-size: 12.5px; color: var(--gray); line-height: 1.45;
}
.consent input { margin-top: 2px; width: 18px; height: 18px; flex-shrink: 0; accent-color: var(--red); }
.consent label { font-weight: 400; font-size: 12.5px; margin: 0; }
.consent a { color: var(--red-text); text-decoration: underline; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn[disabled]:hover { background: var(--red); transform: none; }
.hp { position: absolute; left: -9999px; opacity: 0; }

/* --- Вопросы и ответы --- */
.faq-list { display: grid; gap: 14px; }
.faq-item { border: 1px solid var(--line); border-radius: 14px; background: #fff; overflow: hidden; }
.faq-item summary {
    cursor: pointer; list-style: none; padding: 22px 26px;
    font-family: var(--font-head); font-weight: 700; font-size: 17px;
    display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '\002B'; color: var(--red); font-size: 22px; font-weight: 700; flex-shrink: 0; }
.faq-item[open] summary::after { content: '\2212'; }
.faq-item p { padding: 0 26px 24px; color: var(--gray); font-size: 15px; margin: 0; }

/* --- Реквизиты в подвале --- */
.req {
    margin-top: 22px; display: grid; grid-template-columns: auto 1fr;
    gap: 7px 16px; font-size: 12.5px; max-width: 360px;
}
.req dt { color: #8c8c8c; white-space: nowrap; }
.req dd { color: #cccccc; font-variant-numeric: tabular-nums; margin: 0; }

/* --- Правовые ссылки в подвале --- */
.footer-legal {
    border-top: 1px solid #262626; padding-top: 22px; margin-top: 22px;
    display: flex; flex-wrap: wrap; gap: 8px 26px;
}
.footer-legal a { font-size: 13px; color: #b3b3b3; }
.footer-legal a:hover { color: #ff9999; }

/* --- Cookie-баннер (156-ФЗ / 152-ФЗ) --- */
.cookie {
    position: fixed; left: 50%; transform: translateX(-50%);
    bottom: 16px; bottom: calc(16px + env(safe-area-inset-bottom));
    width: calc(100% - 32px); max-width: 1160px; z-index: 200;
    background: var(--ink); color: #d9d9d9; border: 1px solid #333333;
    border-radius: 14px; padding: 20px 24px; font-size: 13.5px; line-height: 1.5;
    box-shadow: 0 24px 60px -18px rgba(0,0,0,.65);
    display: none; align-items: center; justify-content: space-between;
    gap: 18px 28px; flex-wrap: wrap;
}
.cookie.show { display: flex; }
.cookie p { max-width: 700px; margin: 0; }
.cookie a { color: #ff9999; text-decoration: underline; }
.cookie-btns { display: flex; gap: 10px; flex-wrap: wrap; }
.cookie .btn { padding: 10px 20px; font-size: 14px; }
.btn-line { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.35); }
.btn-line:hover { background: rgba(255,255,255,.1); }

/* --- Мобильные платформы --- */
@media (max-width: 900px) {
    /* КЛЮЧЕВОЕ ДЛЯ iPHONE: Safari принудительно зумит страницу при фокусе
       на поле со шрифтом меньше 16px. Ровно 16px — зума нет. */
    form input, form textarea, form select { font-size: 16px; padding: 14px 15px; }
    .consent input { width: 22px; height: 22px; }
    /* без min-width:0 логотип не сжимается и наезжает на кнопку меню */
    header .logo { min-width: 0; flex: 1 1 auto; padding-right: 10px; }
    header .logo-text { min-width: 0; }
    /* длинное меню на невысоком экране должно прокручиваться */
    header nav {
        max-height: calc(100vh - 78px); max-height: calc(100dvh - 78px);
        overflow-y: auto; -webkit-overflow-scrolling: touch;
    }
    header nav a::after { display: none; }
    .cookie { padding: 18px; gap: 14px; }
    .cookie-btns { width: 100%; }
    .cookie-btns .btn { flex: 1; justify-content: center; }
}

/* Узкие телефоны: iPhone SE, Android 360px */
@media (max-width: 480px) {
    .container { padding: 0 16px; }
    .container {
        padding-left: max(16px, env(safe-area-inset-left));
        padding-right: max(16px, env(safe-area-inset-right));
    }
    .topbar { font-size: 12px; }
    .topbar-hours { display: none; }        /* режим работы продублирован в контактах */
    .topbar .container { justify-content: flex-end; }
    .hero .container { padding: 54px 16px 66px; }
    .hero p { font-size: 16px; }
    .hero-btns .btn { width: 100%; justify-content: center; }
    .stats { margin-top: -34px; }
    .stat { padding: 22px 10px; }
    .stat b { font-size: 30px; }
    .stat span { font-size: 12.5px; }
    section.block { padding: 46px 0; }
    .head { margin-bottom: 34px; }
    .service { padding: 26px 22px; }
    .act { padding: 22px; gap: 14px; }
    .about-visual { padding: 30px 24px; }
    .cta .container { padding: 44px 16px; }
    .cta h2 { font-size: 26px; }
    .cta .btn { width: 100%; justify-content: center; }
    form { padding: 22px 18px; }
    .faq-item summary { padding: 18px 20px; font-size: 15.5px; }
    .faq-item p { padding: 0 20px 20px; }
    .footer-legal { gap: 6px 22px; }
    .totop { right: 16px; width: 44px; height: 44px; }
}

/* На тач-экранах :hover «залипает» после тапа — гасим сдвиги и тени */
@media (hover: none) {
    .service:hover, .btn-primary:hover, .contact-grid a.ci:hover,
    .vacancy:hover, .doc:hover, .k9-list li:hover {
        transform: none; box-shadow: none;
    }
    .btn:active { opacity: .85; }
}

/* Уважение к системной настройке «уменьшить движение» */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* Печать */
@media print {
    .topbar, header, .hero-btns, .cta, form, .burger, .totop, .cookie { display: none !important; }
    body { color: #000; }
    .hero { background: none; color: #000; }
}

/* 11 пунктов меню плиткой требуют места — на средних экранах ужимаем */
@media (max-width: 1400px) {
    header nav ul { gap: 8px; }
    header nav a { font-size: 12.5px; gap: 6px; }
    header nav a i { font-size: 15px; }
    header .logo-text b { font-size: 13px; letter-spacing: .2px; }
    .logo { gap: 10px; }
    .logo-sep { height: 32px; }
}

/* Меню из 11 плиток перестаёт помещаться раньше, чем перестраивается
   сетка контента, поэтому точки переключения разные:
   меню сворачивается в бургер на 1200px, блоки — на 900px. */
@media (max-width: 1200px) {
    header .container { gap: 16px; }
    header nav {
        display: none; position: absolute; top: 78px; left: 0; right: 0;
        background: #fff; border-bottom: 1px solid var(--line); padding: 12px 24px 20px;
        max-height: calc(100vh - 78px); max-height: calc(100dvh - 78px);
        overflow-y: auto; -webkit-overflow-scrolling: touch;
    }
    header nav.open { display: block; }
    header nav ul { grid-auto-flow: row; grid-auto-columns: auto; gap: 4px; }
    header nav li { display: block; }
    header nav a {
        display: flex; flex-direction: row; align-items: center; gap: 10px;
        text-align: left; font-size: 15px; padding: 13px 0;
        border-bottom: 1px solid var(--line);
    }
    header nav a i { font-size: 14px; width: 20px; text-align: center; }
    header nav a::after { display: none; }
    .burger { display: flex; }
    header .logo { min-width: 0; flex: 1 1 auto; padding-right: 10px; }
    header .logo-text { min-width: 0; }
}

/* Навигация в подвале: 13 пунктов в одну колонку тянулись на всю высоту.
   Раскладываем в две колонки и приглушаем стрелки — красными они спорили
   с самими ссылками. */
.footer-grid { grid-template-columns: minmax(240px, 1.15fr) minmax(300px, 1.5fr) minmax(230px, 1.05fr); gap: 30px 48px; }
footer nav ul {
    display: grid; grid-auto-flow: row;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-columns: auto; gap: 0 28px; align-content: start;
}
footer nav li { margin-bottom: 2px; }
footer nav li a { display: flex; flex-direction: row; align-items: center; text-align: left; gap: 8px; padding: 6px 0; font-size: 14px; }
footer nav li a::after { display: none; }
footer nav li i { color: #8c8c8c; margin-right: 0; font-size: 10px; width: 9px; transition: color .2s; }
footer nav li a:hover { color: #ff9999; }
footer nav li a:hover i { color: var(--red); }

/* Независимые колонки: длинное название не оставляет пустоту в соседней. */
footer .footer-grid nav ul { display: block; columns: 2; column-gap: 24px; }
footer .footer-grid nav li { break-inside: avoid; margin: 0 0 12px; }
footer .footer-grid nav li a { display: grid; grid-template-columns: 9px minmax(0, 1fr); align-items: start; gap: 8px; padding: 0; line-height: 1.5; }
footer .footer-grid nav li i { width: 9px; margin: 6px 0 0; }
@media (max-width: 400px) { footer .footer-grid nav ul { columns: 1; } }
footer h4 { letter-spacing: .3px; }

@media (max-width: 900px) {
    .footer-grid { grid-template-columns: 1fr; gap: 34px; }
}
@media (max-width: 520px) {
    /* две колонки сохраняем и на телефоне — иначе 13 строк тянутся
       почти на пол-экрана; ужимаем шрифт, чтобы длинные пункты влезли */
    footer nav ul { gap: 0 12px; }
    footer nav li a { font-size: 12.5px; gap: 5px; padding: 5px 0; }
    footer nav li i { font-size: 9px; width: 8px; }
}
@media (max-width: 330px) {
    footer nav ul { grid-template-columns: 1fr; }
}

/* Реквизиты в подвале: каждая запись со своей строки, ключи выровнены */
/* inline-grid, иначе блочный элемент сбрасывает иконку на строку выше */
.req-lines { display: inline-grid; gap: 3px; vertical-align: top; }
.req-lines > span { display: flex; gap: 8px; font-variant-numeric: tabular-nums; }
.req-key { color: #8c8c8c; min-width: 38px; flex-shrink: 0; }

/* Брендовый блок: колонка шире, чтобы название не рвалось посередине,
   логотип и текст выровнены по верхнему краю */
.footer-grid { grid-template-columns: minmax(300px, 1.4fr) minmax(280px, 1.4fr) minmax(230px, 1.05fr); }
footer .logo { align-items: flex-start; }
footer .logo-sep { align-self: stretch; height: auto; min-height: 40px; }
footer .logo-text b { font-size: 15px; line-height: 1.3; }
footer .logo-text span { display: block; margin-top: 4px; font-size: 12px; line-height: 1.4; }
footer .rzd-logo { margin-top: 2px; }

@media (max-width: 900px) {
    .footer-grid { grid-template-columns: 1fr; }
}

/* Контакты в подвале: иконка и текст в одну строку, у длинных
   значений (адрес, реквизиты) получается висячий отступ */
.footer-contacts li { display: flex; align-items: flex-start; gap: 9px; }
.footer-contacts li > i { margin-right: 0; margin-top: 5px; }

/* Широкая карточка-ссылка вместо повторного блока реквизитов */
.ci-wide {
    grid-column: 1 / -1; display: flex; gap: 18px; align-items: center;
    padding: 24px 28px; border: 1px solid var(--line); border-radius: 14px;
    background: #fff; transition: border-color .25s, transform .25s;
}
.ci-wide:hover { border-color: var(--red); transform: translateY(-3px); }
.ci-wide > i:first-child {
    width: 46px; height: 46px; flex-shrink: 0; border-radius: 10px;
    background: rgba(226,26,26,.09); color: var(--red);
    display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.ci-wide b { font-family: var(--font-head); display: block; margin-bottom: 3px; color: var(--ink); }
.ci-wide span { color: var(--gray); font-size: 14.5px; }
.ci-wide .ci-arrow { margin-left: auto; color: var(--red); flex-shrink: 0; }
@media (max-width: 600px) {
    .ci-wide { padding: 20px; gap: 14px; }
    .ci-wide .ci-arrow { display: none; }
}

/* Блок «О компании»: карточка прижата к верху, а список преимуществ
   вынесен под оба столбца и разложен в две колонки — иначе левая
   колонка вытягивалась на восемь пунктов, а справа зияла пустота. */
.about-wrap { align-items: start; }
.about-facts {
    grid-column: 1 / -1; margin-top: 8px;
    display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px 48px;
}
.about-facts li { margin-bottom: 0; }
.about-facts li span { display: block; }

/* Верхняя панель: обязательная ссылка на раздел о противодействии коррупции */
.topbar .container { justify-content: space-between; }
.topbar-left { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.topbar-anticor { display: inline-flex; align-items: center; gap: 7px; }
.topbar-anticor i { color: #ff8080; }

@media (max-width: 900px) {
    .about-facts { grid-template-columns: 1fr; gap: 18px; }
}
@media (max-width: 620px) {
    /* строка переносится на две — высота по содержимому, иначе вторая строка уходит под шапку */
    .topbar .container { justify-content: center; gap: 4px 18px; padding-top: 7px; padding-bottom: 7px; height: auto; min-height: 42px; }
    .topbar-left { gap: 14px; }
}

/* Шесть показателей вместо четырёх — раскладываем по три в ряд */
.stats { grid-template-columns: repeat(3, 1fr); }
.stat span { display: block; max-width: 260px; margin: 0 auto; }


@media (max-width: 900px) {
    .stats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
    .stats { grid-template-columns: 1fr; }
    .stat span { max-width: none; }
}
/* Выключка по ширине — только там, где строка достаточно длинная.
   Типографский минимум для выключки — 40–45 знаков в строке.
   Вводные абзацы (620–1150px) в него укладываются, а подписи
   в карточках (306–450px) — нет: без переносов пробелы в них
   растягивались до 100px. Поэтому карточки выровнены по левому краю.
   Переносы отключены во всём тексте — слова не разрываются дефисом. */
.head p,
.hero p,
.cta p,
.faq-item p,
.lic-note p,
.modal-body p {
    text-align: justify;
    text-align-last: left;
}
.service p,
.act p,
.doc p,
.vacancy p,
.about-visual p,
.about li span,
.k9-list li span,
footer .footer-desc {
    text-align: left;
}
body { hyphens: none; -webkit-hyphens: none; }

/* На телефоне длинных строк не остаётся вовсе */
@media (max-width: 700px) {
    .head p, .hero p, .cta p, .faq-item p,
    .lic-note p, .modal-body p { text-align: left; }
}

/* --- Типографика заголовков ---
   balance выравнивает длину строк, чтобы в последней не оставалось одно слово;
   pretty убирает «висячее» слово в конце абзаца. Предлоги привязаны к следующему
   слову неразрывными пробелами прямо в тексте. Старые браузеры свойства
   просто игнорируют. */
h1, h2, h3, .stat span { text-wrap: balance; }
p, li { text-wrap: pretty; }
/* «РЖД-Транспортная» не рвётся на дефисе */
.nobr { white-space: nowrap; }

/* Кнопка «Карьера» в шапке — отдельно от меню */
.career-btn {
    display: inline-flex; align-items: center; gap: 8px; flex-shrink: 0;
    padding: 11px 18px; border-radius: 10px;
    background: var(--red); color: #fff; font-size: 14px; font-weight: 600;
    white-space: nowrap; transition: background .2s, transform .2s;
}
.career-btn:hover { background: var(--red-dark); transform: translateY(-1px); }
.career-btn i { font-size: 14px; }
@media (max-width: 1400px) { .career-btn { padding: 10px 14px; font-size: 13px; } }
/* На узком телефоне — только значок, зона нажатия 44x44 */
@media (max-width: 480px) {
    .career-btn { width: 44px; height: 44px; padding: 0; justify-content: center; }
    .career-btn span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
    .career-btn i { font-size: 17px; }
}

/* =====================================================================
   Страница «Карьера» (/career/)
   ===================================================================== */
.btn-outline { background: #fff; color: var(--red-text); border: 1.5px solid var(--red); }
.btn-outline:hover { background: rgba(226,26,26,.06); }
.career-top { padding-bottom: 40px; }
/* серый фон секции без списочных правил .about — они бы протекли в списки */
.block.alt { background: var(--bg); }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 14px; color: var(--gray); margin-bottom: 26px; }
.crumbs a { color: var(--red-text); }
.crumbs a:hover { text-decoration: underline; }
.head h1 { font-size: clamp(30px, 4vw, 46px); font-weight: 800; letter-spacing: -.8px; line-height: 1.12; margin-bottom: 16px; }
.career-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: -20px; }
.req-star { color: var(--red-text); font-weight: 700; }
#conditions .job-perks { margin-bottom: 0; }

.job-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.job-card {
    display: flex; flex-direction: column; align-items: flex-start;
    background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 26px 24px;
    transition: border-color .25s, transform .25s, box-shadow .25s;
}
.job-card:hover { border-color: var(--red); transform: translateY(-4px); box-shadow: 0 24px 40px -26px rgba(226,26,26,.35); }
.job-icon {
    width: 48px; height: 48px; border-radius: 12px; flex-shrink: 0;
    background: rgba(226,26,26,.09); color: var(--red);
    display: flex; align-items: center; justify-content: center; font-size: 20px; margin-bottom: 18px;
}
.job-card h3 { font-size: 17px; font-weight: 700; line-height: 1.3; margin-bottom: 10px; }
.job-card p { color: var(--gray); font-size: 14px; margin-bottom: 16px; }
.job-tags { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 20px; }
.job-tags li {
    font-size: 12.5px; font-weight: 600; color: var(--gray-80);
    background: var(--bg); border-radius: 100px; padding: 4px 11px;
}
/* кнопка всегда внизу карточки — ряды карточек выровнены по кнопкам */
.job-card .btn-apply { margin-top: auto; padding: 11px 20px; font-size: 14px; }
.job-card-other { background: var(--bg); border-style: dashed; }

.hh-card {
    display: flex; align-items: center; gap: 20px; margin-top: 28px;
    background: var(--ink); color: #fff; border-radius: 16px; padding: 24px 28px;
    transition: transform .25s, box-shadow .25s;
}
.hh-card:hover { transform: translateY(-3px); box-shadow: 0 24px 40px -24px rgba(0,0,0,.5); }
.hh-mark {
    width: 52px; height: 52px; border-radius: 50%; flex-shrink: 0;
    background: var(--red); color: #fff; font-weight: 800; font-size: 18px;
    display: flex; align-items: center; justify-content: center; letter-spacing: -.5px;
}
.hh-text { flex: 1; min-width: 0; }
.hh-text b { display: block; font-family: var(--font-head); font-size: 18px; margin-bottom: 4px; }
.hh-text span { color: #cccccc; font-size: 14.5px; }
.hh-go { font-weight: 600; white-space: nowrap; }
.hh-go i { margin-left: 8px; font-size: 13px; }

/* тизер «Карьера» на главной */
.career-teaser { display: flex; flex-wrap: wrap; gap: 14px; }

@media (max-width: 1200px) { .job-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 900px)  { .job-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px)  {
    .job-grid { grid-template-columns: 1fr; }
    .hh-card { flex-wrap: wrap; padding: 22px; }
    .hh-go { width: 100%; }
    .career-actions .btn, .career-teaser .btn { width: 100%; justify-content: center; }
}

/* Узкий телефон: рядом с логотипом теперь две кнопки (Карьера и меню),
   название в одну строку не помещается и уходило под кнопку — переносим на две. */
@media (max-width: 480px) {
    header .logo-text b { white-space: normal; font-size: 11.5px; line-height: 1.2; letter-spacing: .3px; }
}

/* =====================================================================
   Лицензии: общие элементы сведений о документе (номер, даты, статус).
   Сам раздел — «витрина», стили ниже в блоке «Лицензии — витрина».
   ===================================================================== */
.lic-scope { color: var(--gray); font-size: 13.5px; line-height: 1.5; margin: 0 0 16px; }
.lic-num { background: var(--bg); border-radius: 10px; padding: 10px 14px; align-self: start; }
.lic-num span { display: block; font-size: 12px; color: var(--gray); margin-bottom: 2px; }
.lic-num b {
    display: block; font-family: var(--font-head); font-size: 16px; font-weight: 700; color: var(--ink);
    font-variant-numeric: tabular-nums; letter-spacing: .2px; line-height: 1.35;
}
.lic-dl { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 14px 0 16px; }
.lic-dl dt { font-size: 12px; color: var(--gray); margin-bottom: 2px; }
.lic-dl dd { font-size: 14px; font-weight: 500; color: var(--ink); margin: 0; }
/* Статус. Цвета — только серые и красный по брендбуку. */
.lic-status {
    display: inline-flex; align-items: center; gap: 7px;
    font-size: 13px; font-weight: 600; border-radius: 100px; padding: 5px 12px;
    background: var(--bg); color: var(--gray-80);
}
.lic-status i { font-size: 12px; color: var(--red); }
.lic-status.is-soon { background: #fff; color: var(--red-text); box-shadow: inset 0 0 0 1.5px var(--red); }
.lic-status.is-bad, .lic-status.is-check { background: #fdeaea; color: #a81414; }
.lic-status.is-bad i, .lic-status.is-check i { color: #a81414; }

/* Просмотр скана документа поверх страницы */
.doc-viewer {
    border: none; padding: 0; margin: auto; background: transparent;
    width: min(920px, 100vw - 32px); max-height: calc(100dvh - 32px);
}
.doc-viewer::backdrop { background: rgba(0,0,0,.72); }
.doc-viewer-box { background: #fff; border-radius: 16px; overflow: hidden; display: flex; flex-direction: column; max-height: calc(100dvh - 32px); }
.doc-viewer-head { display: flex; align-items: flex-start; gap: 16px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.doc-viewer-head div { flex: 1; min-width: 0; }
.doc-viewer-head b { display: block; font-family: var(--font-head); font-size: 16px; line-height: 1.3; }
.doc-viewer-head span { font-size: 13.5px; color: var(--gray); }
.doc-viewer button { background: none; border: none; cursor: pointer; font: inherit; color: var(--ink); }
.dv-close { width: 40px; height: 40px; border-radius: 10px; font-size: 18px !important; flex-shrink: 0; }
.dv-close:hover { background: var(--bg); }
.doc-viewer-img { flex: 1; min-height: 0; overflow: auto; background: #e9e9e9; display: flex; justify-content: center; }
.doc-viewer-img img { display: block; width: 100%; max-width: 760px; height: auto; background: #fff; }
.doc-viewer-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 20px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.dv-nav { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--gray-80); }
.dv-nav button { width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line) !important; }
.dv-nav button:hover:not(:disabled) { border-color: var(--red) !important; color: var(--red); }
.dv-nav button:disabled { opacity: .35; cursor: default; }
.dv-newtab { font-size: 14px; font-weight: 600; color: var(--red-text); }
.dv-newtab:hover { text-decoration: underline; }
.doc-viewer-head, .doc-viewer-foot { flex-shrink: 0; }
.doc-viewer-img { display: block; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.doc-viewer-img img { max-width: none; height: auto; }
.dv-zoom { display: flex; align-items: center; gap: 4px; }
.dv-zoom button, .dv-nav button, .dv-close { min-width: 44px; min-height: 44px; }
.dv-zoom button { border: 1px solid var(--line); border-radius: 8px; }
.dv-zoom button:disabled { opacity: .35; }
.doc-viewer button:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
@media (max-width: 600px) {
    .doc-viewer { width: calc(100vw - 16px); max-width: none; }
    .doc-viewer-box { max-height: calc(100dvh - 16px); }
    .doc-viewer-head, .doc-viewer-foot { padding: 10px 12px; gap: 8px; }
    .doc-viewer-head b { font-size: 14px; }
    .doc-viewer-head span { font-size: 12px; }
    .dv-nav { gap: 6px; }
    .dv-newtab { width: 100%; text-align: center; }
}

/* =====================================================================
   «Сведения об образовательной организации» (/education/) и
   «Специальная подготовка контролёров-распорядителей» (/education/stewards/)
   ===================================================================== */
.edu-layout { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 40px; align-items: start; }
/* Общая навигация по подразделам на каждой странице раздела — п. 2 приказа № 1493 */
.edu-nav { position: sticky; top: 96px; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px 16px; }
.edu-nav-title { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .6px; color: var(--gray); margin: 0 0 10px 8px; }
.edu-nav ol { list-style: none; margin: 0; padding: 0; counter-reset: edu; }
.edu-nav li { counter-increment: edu; }
.edu-nav a {
    display: flex; gap: 10px; padding: 7px 8px; border-radius: 8px;
    font-size: 14px; line-height: 1.35; color: var(--ink);
}
.edu-nav a::before { content: counter(edu); color: var(--gray-40); font-variant-numeric: tabular-nums; min-width: 20px; flex-shrink: 0; }
.edu-nav a:hover, .edu-nav a.is-current { background: rgba(226,26,26,.07); color: var(--red-text); }
.edu-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; }
.edu-sec { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 28px 30px; scroll-margin-top: 96px; }
.edu-sec h2 { font-size: 22px; font-weight: 800; line-height: 1.25; margin-bottom: 18px; }
.edu-sec p { color: var(--gray-80); font-size: 15px; margin-bottom: 12px; }
.edu-sec a { color: var(--red-text); }
.edu-h3 { font-size: 17px; font-weight: 700; margin: 24px 0 8px; }
.edu-dl { display: grid; margin: 0; }
.edu-dl > div { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 20px; padding: 11px 0; border-top: 1px solid var(--line); }
.edu-dl > div:first-child { border-top: none; padding-top: 0; }
.edu-dl dt { font-size: 14px; color: var(--gray); }
.edu-dl dd { margin: 0; font-size: 15px; color: var(--ink); }
.edu-files { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.edu-files a {
    display: flex; gap: 14px; align-items: flex-start; padding: 14px 16px;
    border: 1px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink);
    transition: border-color .2s, background .2s;
}
.edu-files a:hover { border-color: var(--red); background: #fffafa; }
.edu-files i { color: var(--red); font-size: 20px; margin-top: 2px; flex-shrink: 0; width: 22px; text-align: center; }
.edu-files b { display: block; font-weight: 600; font-size: 15px; line-height: 1.4; }
.edu-files small { display: block; color: var(--gray); font-size: 13px; margin-top: 3px; }
.edu-files-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 10px 0 14px; }
.edu-table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.edu-table th, .edu-table td { text-align: left; vertical-align: top; padding: 11px 12px; border-bottom: 1px solid var(--line); }
.edu-table th { background: var(--bg); color: var(--gray-80); font-weight: 600; font-size: 13.5px; }
.edu-table td:nth-child(2) { white-space: nowrap; font-weight: 600; }
.edu-table td:nth-child(3) { white-space: nowrap; }
.edu-list { margin: 0 0 18px 20px; display: grid; gap: 8px; color: var(--gray-80); font-size: 15px; }
.edu-gallery { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 6px 0 18px; }
.edu-photo { display: block; aspect-ratio: 3 / 4; border-radius: 10px; overflow: hidden; background: var(--bg); }
.edu-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.edu-photo:hover img { transform: scale(1.04); }
.edu-todo { margin-top: 6px; }

.st-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.st-facts > div { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 22px 22px 20px; }
.st-facts b { display: block; font-family: var(--font-head); font-size: 26px; font-weight: 800; color: var(--red-text); margin-bottom: 6px; }
.st-facts span { font-size: 14px; color: var(--gray-80); }
.st-lead { color: var(--gray-80); font-size: 15px; margin-bottom: 14px; }
.st-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.st-list li { position: relative; padding-left: 30px; font-size: 15px; color: var(--gray-80); line-height: 1.5; }
.st-list li::before {
    font-family: 'Font Awesome 7 Free', 'Font Awesome 6 Free'; font-weight: 900;
    position: absolute; left: 0; top: 1px; font-size: 15px; color: var(--red);
}
.st-no li::before { content: '\f05e'; }
.st-yes li::before { content: '\f15b'; }
.st-note { margin-top: 16px; font-size: 14px; color: var(--gray); }
.st-steps { list-style: none; margin: 0 0 28px; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; counter-reset: st; }
.st-steps li {
    counter-increment: st; background: #fff; border: 1px solid var(--line); border-radius: 14px;
    padding: 22px 22px 20px; display: grid; gap: 6px;
}
.st-steps li::before {
    content: counter(st); width: 34px; height: 34px; border-radius: 50%;
    background: var(--red); color: #fff; font-weight: 700; display: flex; align-items: center; justify-content: center; margin-bottom: 6px;
}
.st-steps b { font-family: var(--font-head); font-size: 17px; }
.st-steps span { font-size: 14.5px; color: var(--gray-80); }

@media (max-width: 1100px) {
    .edu-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; }
    /* на узком экране меню подразделов — горизонтальная лента */
    .edu-nav { position: static; padding: 12px; }
    .edu-nav-title { display: none; }
    .edu-nav ol { display: flex; gap: 6px; overflow-x: auto; -webkit-overflow-scrolling: touch; padding-bottom: 4px; }
    .edu-nav a { white-space: nowrap; background: var(--bg); }
    .st-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .st-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
    .edu-sec { padding: 22px 18px; }
    .edu-dl > div { grid-template-columns: 1fr; gap: 3px; }
    .edu-files-grid { grid-template-columns: 1fr; }
    .edu-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .st-steps { grid-template-columns: 1fr; }
    .edu-table td:nth-child(2), .edu-table td:nth-child(3) { white-space: normal; }
}
@media (max-width: 480px) {
    .st-facts { grid-template-columns: 1fr; }
    .topbar-edu { display: none; }   /* на телефоне раздел доступен из меню «Учебный центр» */
}

/* Таблица программ: короткое название + полное официальное название под ним */
.edu-table .prog-name { display: block; font-weight: 600; color: var(--ink); font-size: 15px; line-height: 1.35; }
.edu-table .prog-full { display: block; margin-top: 4px; color: var(--gray); font-size: 13px; line-height: 1.45; }

/* Ссылки внутри вводных абзацев (например, на текст 223-ФЗ) */
.head p a { color: var(--red-text); text-decoration: underline; text-underline-offset: 2px; }
.head p a:hover { text-decoration: none; }
/* Длинный официальный заголовок (страница контролёров-распорядителей) */
.head h1.h1-long { font-size: clamp(21px, 2.8vw, 34px); letter-spacing: -.4px; max-width: 980px; }
/* на самых узких телефонах «контролёров-распорядителей» не влезает в строку — разрешаем перенос по дефису */
@media (max-width: 360px) { .head h1.h1-long .nobr { white-space: normal; } }
/* Короткий подзаголовок раздела (одно предложение): на компьютере помещается
   в одну строку, поэтому ему снято ограничение ширины. При выключке по ширине
   двухстрочный абзац растягивает первую строку — такие абзацы ровняем влево. */
.head p.lead-short { max-width: none; text-align: left; }


/* ==========================================================================
   Лицензии — витрина (25.10.2026)
   Слева список документов, справа предпросмотр выбранного. На телефоне документ
   раскрывается под своей строкой. Разметку собирает build_licenses.py.
   ========================================================================== */
.ld-pane[hidden], .ld-item[hidden], .ld-gt[hidden] { display: none !important; }

/* Вкладки по группам */
.lx-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 26px; }
.lx-tabbtn {
    display: inline-flex; align-items: center; gap: 9px; cursor: pointer; font-family: inherit;
    font-size: 14px; font-weight: 600; line-height: 1; color: var(--gray-80);
    background: #fff; border: 1px solid var(--line); border-radius: 100px; padding: 10px 16px;
    transition: border-color .2s, color .2s, background .2s;
}
.lx-tabbtn small { font-size: 12px; font-weight: 700; color: var(--gray); background: var(--bg); border-radius: 100px; padding: 3px 8px; }
.lx-tabbtn:hover { border-color: #cfcfcf; color: var(--ink); }
.lx-tabbtn[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.lx-tabbtn[aria-pressed="true"] small { background: var(--red); color: #fff; }
.lx-tabbtn:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
.lx-tabs.is-filtered ~ .ld .ld-gt { display: none; }

.ld { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 22px; align-items: start; }
.ld-list { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 8px; position: sticky; top: 110px; max-height: calc(100vh - 140px); overflow: auto; }
.ld-gt { padding: 14px 12px 6px; font-size: 11.5px; font-weight: 700; color: var(--gray); text-transform: uppercase; letter-spacing: .5px; }
.ld-item {
    display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; cursor: pointer;
    background: none; border: 0; border-radius: 10px; padding: 9px 10px; font-family: inherit; color: var(--ink); position: relative;
}
.ld-item:hover { background: var(--bg); }
.ld-item[aria-current="true"] { background: #fdeeee; }
.ld-item[aria-current="true"]::before { content: ''; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: var(--red); }
.ld-item:focus-visible { outline: 2px solid var(--red); outline-offset: -2px; }
.ld-ico { flex-shrink: 0; width: 36px; height: 36px; border-radius: 10px; background: rgba(226,26,26,.09); color: var(--red); display: inline-flex; align-items: center; justify-content: center; font-size: 15px; }
.ld-it b { display: block; font-size: 14px; font-weight: 600; line-height: 1.3; }
.ld-it span { display: block; font-size: 12px; color: var(--gray); margin-top: 2px; }
.ld-chev { display: none; margin-left: auto; font-size: 12px; color: var(--gray); transition: transform .25s; }
.ld-view { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 28px; min-height: 420px; }
.ld-pane { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 30px; align-items: start; perspective: 1000px; }
/* «Документ в руке»: скан наклоняется за курсором, по бумаге скользит блик (логика — site.js) */
.ld-scan {
    position: relative; display: block; aspect-ratio: 210 / 297; border-radius: 6px; background: #fff; overflow: hidden;
    box-shadow: 0 1px 2px rgba(0,0,0,.1), 0 18px 36px -18px rgba(0,0,0,.45);
    transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform .5s cubic-bezier(.2,.8,.2,1), box-shadow .5s;
}
.ld-scan img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }
.ld-scan.is-tilt { transition: transform .08s linear, box-shadow .2s; box-shadow: 0 1px 2px rgba(0,0,0,.1), calc(var(--sx, 0) * 1px) 26px 44px -18px rgba(0,0,0,.5); }
.ld-scan::before {
    content: ''; position: absolute; inset: 0; z-index: 3; pointer-events: none; opacity: 0; transition: opacity .4s;
    background: radial-gradient(circle at var(--gx, 50%) var(--gy, 0%), rgba(255,255,255,.75), rgba(255,255,255,.18) 35%, rgba(255,255,255,0) 65%);
    mix-blend-mode: soft-light;
}
.ld-scan.is-tilt::before { opacity: 1; }
.ld-scan:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
.ld-pages { position: absolute; z-index: 4; left: 10px; bottom: 10px; display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; border-radius: 100px; padding: 4px 10px; background: #fff; color: var(--gray-80); box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.ld-scan.is-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; border: 1px dashed #e8a5a5; box-shadow: none; padding: 20px; text-align: center; font-size: 13px; font-weight: 600; color: #a81414; transform: none; }
.ld-scan.is-empty i { font-size: 30px; color: #e8a5a5; }
.ld-org { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 600; color: var(--gray-80); }
.ld-org i { color: var(--red); }
.ld-title { font-family: var(--font-head); font-size: 23px; font-weight: 800; line-height: 1.25; margin: 10px 0; }
.ld-info .lic-num { display: inline-block; }
.ld-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; border-top: 1px solid var(--line); padding-top: 18px; }
.ld-btn { font-size: 14px; }
.ld + .lic-note { margin-top: 28px; }
@media (max-width: 900px) {
    .ld { grid-template-columns: 1fr; }
    .ld-list { position: static; max-height: none; }
    .ld-view { display: none; }
    .ld-pane { grid-template-columns: 1fr; gap: 16px; }
    .ld-list .ld-pane { padding: 6px 10px 20px 58px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
    .ld-list .ld-title { font-size: 18px; }
    .ld-list .ld-scan { max-width: 190px; }
    .ld-list .ld-scan.is-empty { aspect-ratio: auto; max-width: none; flex-direction: row; padding: 12px 14px; justify-content: flex-start; }
    .ld-list .ld-scan.is-empty i { font-size: 20px; }
    .ld-item { scroll-margin-top: 96px; }
    .ld-chev { display: inline-block; }
    .ld-item[aria-expanded="true"] .ld-chev { transform: rotate(180deg); color: var(--red); }
}
@media (max-width: 600px) {
    .lx-tabs { flex-wrap: nowrap; overflow-x: auto; margin-right: -16px; padding-right: 16px; scrollbar-width: none; }
    .lx-tabbtn { white-space: nowrap; flex-shrink: 0; }
    .ld-list .ld-pane { padding-left: 10px; }
}

/* ==========================================================================
   Эффекты главной (25.10.2026). Каждый включается классом на <html> в index.html:
   fx-history — «История» по прокрутке, fx-count — счётчики, fx-hero — схема путей
   на первом экране, fx-bento — бенто-сетка «Услуг». Убрать класс — эффект выключен.
   При «уменьшении движения» анимаций нет. Логика — site.js.
   ========================================================================== */

/* 3. Схема путей на первом экране */
.fx-tracks { display: none; }
html.fx-hero .fx-tracks {
    display: block; position: absolute; inset: 0 0 0 auto; width: min(64%, 900px); height: 100%; pointer-events: none;
    -webkit-mask-image: linear-gradient(to right, transparent 0, transparent 12%, #000 58%); mask-image: linear-gradient(to right, transparent 0, transparent 12%, #000 58%);
}
html.fx-hero .hero-accent { opacity: .6; }
.fx-tracks .rail { fill: none; stroke: #fff; stroke-opacity: .09; stroke-width: 2; }
.fx-tracks .ties { fill: none; stroke: #fff; stroke-opacity: .05; stroke-width: 9; stroke-dasharray: 1.5 7; }
.fx-tracks .draw {
    fill: none; stroke: var(--red); stroke-opacity: .55; stroke-width: 2; stroke-linejoin: round;
    stroke-dasharray: 1; stroke-dashoffset: 1; animation: fx-draw 2.6s cubic-bezier(.4,0,.2,1) forwards;
}
.fx-tracks .run {
    fill: none; stroke: #ff6b6b; stroke-width: 3.5; stroke-linecap: round;
    stroke-dasharray: 2.5 97.5; stroke-dashoffset: 100; filter: url(#fx-glow); opacity: 0;
    animation: fx-run 7s linear infinite, fx-fade .6s ease forwards;
}
.fx-tracks .run.white { stroke: #fff; stroke-width: 3; }
.fx-tracks .st { fill: #1f1f1f; stroke: var(--red); stroke-width: 2; opacity: 0; animation: fx-fade .5s ease forwards; }
.fx-tracks .st.big { stroke: #fff; stroke-opacity: .7; }
@keyframes fx-draw { to { stroke-dashoffset: 0; } }
@keyframes fx-run { to { stroke-dashoffset: 0; } }
@keyframes fx-fade { to { opacity: 1; } }

/* 2. Счётчики */
html.fx-count .stat b { font-variant-numeric: tabular-nums; }

/* 1. «История» по прокрутке */
html.fx-history #history .activities { display: block; position: relative; max-width: 1000px; margin: 0 auto; padding: 6px 0; }
html.fx-history #history .activities::before,
html.fx-history #history .activities::after { content: ''; position: absolute; left: 50%; top: 0; width: 2px; margin-left: -1px; border-radius: 2px; }
html.fx-history #history .activities::before { bottom: 0; background: var(--line); }
html.fx-history #history .activities::after { height: calc(var(--p, 0) * 100%); background: linear-gradient(var(--red), #ff5a5a); box-shadow: 0 0 12px rgba(226,26,26,.45); }
html.fx-history #history .act {
    position: relative; width: calc(50% - 46px); margin: 0 0 22px;
    opacity: 0; transform: translateY(28px); transition: opacity .6s ease, transform .6s cubic-bezier(.2,.8,.2,1), border-color .25s;
}
html.fx-history #history .act:nth-of-type(odd) { margin-right: auto; }
html.fx-history #history .act:nth-of-type(even) { margin-left: auto; }
html.fx-history #history .act.is-in { opacity: 1; transform: none; }
html.fx-history #history .act::before {
    content: ''; position: absolute; top: 32px; width: 16px; height: 16px; border-radius: 50%;
    background: #fff; border: 3px solid #d9d9d9; box-sizing: border-box; transition: background .35s, border-color .35s, box-shadow .35s;
}
html.fx-history #history .act:nth-of-type(odd)::before { right: -54px; }
html.fx-history #history .act:nth-of-type(even)::before { left: -54px; }
html.fx-history #history .act.is-on::before { background: var(--red); border-color: var(--red); box-shadow: 0 0 0 7px rgba(226,26,26,.14); }
html.fx-history #history .act .num { transition: color .35s; }
html.fx-history #history .act.is-on .num { color: var(--red); }

/* 4. Бенто-сетка «Услуг» */
html.fx-bento #services .services-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px;
    grid-template-areas: "a a b c" "a a d e" "f m g h" "i j k l";
}
html.fx-bento #services .service { padding: 26px 24px; display: flex; flex-direction: column; position: relative; overflow: hidden; }
html.fx-bento #services .service h3 { font-size: 17px; }
html.fx-bento #services .service-icon { width: 48px; height: 48px; font-size: 20px; margin-bottom: 18px; }
html.fx-bento #services .service:nth-child(1) { grid-area: a; background: var(--ink); border-color: var(--ink); color: #fff; padding: 34px 32px; justify-content: flex-end; }
html.fx-bento #services .service:nth-child(1)::before {
    content: ''; position: absolute; inset: 0; opacity: .9;
    background: radial-gradient(circle at 85% 15%, rgba(226,26,26,.45), transparent 55%),
                url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="40" height="40"><path d="M0 20h40M20 0v40" stroke="%23ffffff" stroke-opacity="0.06" stroke-width="1"/></svg>');
}
html.fx-bento #services .service:nth-child(1) > * { position: relative; }
html.fx-bento #services .service:nth-child(1) .service-icon { width: 64px; height: 64px; font-size: 28px; background: var(--red); color: #fff; margin-bottom: auto; }
html.fx-bento #services .service:nth-child(1) h3 { font-size: 28px; margin-top: 60px; }
html.fx-bento #services .service:nth-child(1) p { color: #cfcfcf; font-size: 16px; max-width: 420px; }
html.fx-bento #services .service:nth-child(2) { grid-area: b; }
html.fx-bento #services .service:nth-child(3) { grid-area: c; }
html.fx-bento #services .service:nth-child(4) { grid-area: d; }
html.fx-bento #services .service:nth-child(5) { grid-area: f; background: var(--bg); }
html.fx-bento #services .service:nth-child(12) { grid-area: l; }
html.fx-bento #services .service:nth-child(6) { grid-area: k; background: var(--bg); }
html.fx-bento #services .service:nth-child(7) { grid-area: e; }
html.fx-bento #services .service:nth-child(8) { grid-area: g; background: linear-gradient(160deg, #fff 40%, #fdecec); }
html.fx-bento #services .service:nth-child(9) { grid-area: h; }
html.fx-bento #services .service:nth-child(10) { grid-area: i; }
html.fx-bento #services .service:nth-child(11) { grid-area: j; }
html.fx-bento #services .service:nth-child(5) .service-icon,
html.fx-bento #services .service:nth-child(6) .service-icon { background: #fff; }
html.fx-bento #services .service:nth-child(5)::after,
html.fx-bento #services .service:nth-child(6)::after {
    font: 900 120px/1 'Font Awesome 7 Free'; position: absolute; right: -10px; bottom: -18px; color: rgba(226,26,26,.07); pointer-events: none;
}
html.fx-bento #services .service:nth-child(5)::after { content: '\f03d'; }
html.fx-bento #services .service:nth-child(6)::after { content: '\f568'; }
html.fx-bento #services .service:nth-child(5) p { max-width: 100%; position: relative; }

@media (max-width: 900px) {
    html.fx-history #history .activities::before, html.fx-history #history .activities::after { left: 8px; }
    html.fx-history #history .act { width: auto; margin-left: 34px !important; margin-right: 0 !important; }
    html.fx-history #history .act::before { left: -34px !important; right: auto !important; }
    html.fx-bento #services .services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-areas: "a a" "b c" "d e" "f m" "g h" "i j" "k l"; }
    html.fx-bento #services .service:nth-child(1) h3 { font-size: 24px; margin-top: 36px; }
    html.fx-hero .fx-tracks { width: 100%; opacity: .55; }
}
@media (max-width: 600px) {
    html.fx-bento #services .services-grid { grid-template-columns: 1fr; grid-template-areas: "a" "b" "c" "d" "e" "f" "m" "g" "h" "i" "j" "k" "l"; }
}
@media (prefers-reduced-motion: reduce) {
    .fx-tracks .draw { animation: none; stroke-dashoffset: 0; }
    .fx-tracks .run { display: none; }
    .fx-tracks .st { animation: none; opacity: 1; }
    html.fx-history #history .act { opacity: 1; transform: none; transition: none; }
    .ld-scan { transform: none !important; transition: none; }
}

/* ==========================================================================
   Приёмы «как у Apple» (26.10.2026). Включаются классами на <html> в index.html:
   ap-glass — стеклянная шапка. Логика — site.js.
   ========================================================================== */
/* ---------- 3. Стеклянная шапка ---------- */
html.ap-glass header {
    background: rgba(255,255,255,.62);
    -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
    border-bottom-color: transparent; transition: background .3s, border-color .3s, box-shadow .3s;
}
html.ap-glass header.is-scrolled { background: rgba(255,255,255,.72); border-bottom-color: rgba(0,0,0,.07); box-shadow: 0 10px 30px -22px rgba(0,0,0,.35); }


/* Лицензии — анонс на главной (полный перечень — страница licenses/) */
.lt { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.lt-text h2 { font-size: clamp(28px,3.6vw,40px); font-weight: 800; letter-spacing: -.8px; margin-bottom: 16px; }
.lt-text > p { color: var(--gray); font-size: 16.5px; margin-bottom: 26px; }
.lt-counts { list-style: none; display: flex; flex-wrap: wrap; gap: 28px; margin: 0 0 22px; padding: 0; }
.lt-counts li { display: flex; align-items: baseline; gap: 8px; }
.lt-counts b { font-family: var(--font-head); font-size: 34px; font-weight: 800; color: var(--red); line-height: 1; }
.lt-counts span { font-size: 14px; color: var(--gray-80); font-weight: 600; }
.lt-orgs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 30px; }
.lt-orgs span { background: #fff; border: 1px solid var(--line); border-radius: 100px; padding: 6px 13px; font-size: 13px; font-weight: 600; color: var(--gray-80); }
/* веер из трёх сканов: крайние прижаты к краям колонки, поэтому веер не выходит за экран */
.lt-fan { position: relative; display: block; height: 380px; }
.lt-fan img {
    position: absolute; top: 24px; width: min(220px, 50%); height: auto; aspect-ratio: 210 / 297; object-fit: cover; object-position: top;
    border-radius: 6px; background: #fff; box-shadow: 0 2px 4px rgba(0,0,0,.08), 0 24px 44px -22px rgba(0,0,0,.5);
    transition: transform .5s cubic-bezier(.2,.8,.2,1);
}
.lt-fan img:nth-child(1) { left: 4%; transform: rotate(-8deg); }
.lt-fan img:nth-child(2) { left: 50%; transform: translateX(-50%) translateY(-8px); z-index: 2; }
.lt-fan img:nth-child(3) { right: 4%; transform: rotate(8deg); }
.lt-fan:hover img:nth-child(1) { transform: translateX(-8px) rotate(-11deg); }
.lt-fan:hover img:nth-child(2) { transform: translateX(-50%) translateY(-18px); }
.lt-fan:hover img:nth-child(3) { transform: translateX(8px) rotate(11deg); }
.lt-fan:focus-visible { outline: 2px solid var(--red); outline-offset: 6px; border-radius: 12px; }
@media (max-width: 900px) {
    .lt { grid-template-columns: 1fr; gap: 30px; }
    .lt-fan { height: 300px; order: -1; max-width: 520px; width: 100%; margin: 0 auto; }
    .lt-fan img { width: min(170px, 38%); }
}
@media (max-width: 600px) {
    .lt-fan { height: 236px; }
    .lt-fan img { width: 40%; top: 14px; }
    .lt-counts { gap: 18px; }
    .lt-counts b { font-size: 28px; }
}
@media (prefers-reduced-motion: reduce) { .lt-fan img { transition: none; } }
.career-top + #licenses { padding-top: 56px; }

/* ==========================================================================
   «Матовое стекло» (27.10.2026).
   Цифры — внутри тёмного первого экрана (.gl-stats-wrap), плитки из тёмного стекла.
   glx-light (класс на <html>) — светлое стекло для карточек: за ними мягкие размытые пятна.
   glx-dark  (класс на <html>) — раздел «Услуги» на тёмном фоне, плитки из тёмного стекла.
   Убрать класс — вариант выключен.
   ========================================================================== */

/* Цифры внутри первого экрана: тёмное стекло */
.hero .gl-stats-wrap { position: relative; padding-top: 0; padding-bottom: 84px; }
@media (max-width: 600px) { .hero .gl-stats-wrap { padding-bottom: 48px; } }
.gl-stats-wrap .stats { margin-top: 0; background: transparent; border: none; box-shadow: none; gap: 14px; overflow: visible; }
.gl-stats-wrap .stat {
    border-radius: 16px; color: #fff;
    background: linear-gradient(160deg, rgba(255,255,255,.10), rgba(255,255,255,.03)), rgba(24,24,24,.55);
    -webkit-backdrop-filter: blur(16px) saturate(160%); backdrop-filter: blur(16px) saturate(160%);
    border: 1px solid rgba(255,255,255,.14); box-shadow: inset 0 1px 0 rgba(255,255,255,.1);
}
.gl-stats-wrap .stat b { color: #fff; }
.gl-stats-wrap .stat span { color: #d2d2d2; }
.gl-stats-wrap .stat i { color: #ff7a7a; }
.hero > .container:not(.gl-stats-wrap) { padding-bottom: 56px; }

/* --- glx-light: светлое стекло --- */
/* за карточками — мягкие размытые пятна фирменного красного и серого */
html.glx-light section.block { position: relative; isolation: isolate; }
html.glx-light section.block::before {
    content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
    background:
        radial-gradient(38% 46% at 8% 22%, rgba(226,26,26,.16), transparent 70%),
        radial-gradient(34% 42% at 92% 78%, rgba(226,26,26,.12), transparent 70%),
        radial-gradient(30% 38% at 72% 8%, rgba(0,0,0,.06), transparent 70%);
}
html.glx-light section.block:nth-of-type(even)::before {
    background:
        radial-gradient(36% 44% at 90% 18%, rgba(226,26,26,.15), transparent 70%),
        radial-gradient(34% 44% at 12% 82%, rgba(226,26,26,.11), transparent 70%),
        radial-gradient(28% 36% at 30% 6%, rgba(0,0,0,.06), transparent 70%);
}
html.glx-light :is(.service, .act, .doc, .ci, .ci-wide, .faq-item, .lic-note, .lt-orgs span) {
    background: rgba(255,255,255,.55);
    -webkit-backdrop-filter: blur(16px) saturate(150%); backdrop-filter: blur(16px) saturate(150%);
    border-color: rgba(255,255,255,.85);
    box-shadow: 0 14px 34px -22px rgba(0,0,0,.30), inset 0 1px 0 rgba(255,255,255,.95);
}
/* плитки бенто (кроме большой тёмной) — тоже светлое стекло */
html.glx-light.fx-bento #services .service:not(:nth-child(1)) { background: rgba(255,255,255,.55); }

/* --- glx-dark: «Услуги» на тёмном фоне, плитки из тёмного стекла --- */
html.glx-dark #services { background: linear-gradient(120deg, #1c1c1c 0%, #2e2e2e 100%); color: #fff; position: relative; isolation: isolate; overflow: hidden; }
html.glx-dark #services::before {
    content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
    background:
        radial-gradient(40% 50% at 85% 10%, rgba(226,26,26,.35), transparent 70%),
        radial-gradient(35% 45% at 5% 90%, rgba(226,26,26,.22), transparent 70%),
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="60" height="60"><path d="M0 30h60M30 0v60" stroke="%23ffffff" stroke-opacity="0.04" stroke-width="1"/></svg>');
}
html.glx-dark #services .head h2 { color: #fff; }
html.glx-dark #services .head p { color: #cfcfcf; }
html.glx-dark #services .service,
html.glx-dark.fx-bento #services .service:nth-child(n) {
    background: linear-gradient(160deg, rgba(255,255,255,.10), rgba(255,255,255,.03)), rgba(24,24,24,.45);
    -webkit-backdrop-filter: blur(16px) saturate(160%); backdrop-filter: blur(16px) saturate(160%);
    border: 1px solid rgba(255,255,255,.13); box-shadow: inset 0 1px 0 rgba(255,255,255,.1); color: #fff;
}
html.glx-dark.fx-bento #services .service:nth-child(1) {
    background: radial-gradient(120% 90% at 85% 10%, rgba(226,26,26,.45), transparent 60%), rgba(24,24,24,.5);
}
html.glx-dark #services .service h3 { color: #fff; }
html.glx-dark #services .service p { color: #cfcfcf; }
html.glx-dark #services .service-icon { background: rgba(226,26,26,.20); color: #ff7a7a; }
html.glx-dark.fx-bento #services .service:nth-child(1) .service-icon { background: var(--red); color: #fff; }
html.glx-dark.fx-bento #services .service:nth-child(5) .service-icon,
html.glx-dark.fx-bento #services .service:nth-child(6) .service-icon { background: rgba(226,26,26,.20); color: #ff7a7a; }
html.glx-dark.fx-bento #services .service:nth-child(5)::after,
html.glx-dark.fx-bento #services .service:nth-child(6)::after { color: rgba(255,255,255,.05); }
html.glx-dark #services .service:hover { border-color: rgba(226,26,26,.7); }

/* ==========================================================================
   Фирменный стиль «Транспортная безопасность» (брендбук v.2026.10.15, 28.10.2026)
   ========================================================================== */
/* Фирменный блок в шапке: щит «ТБ» + логотип РЖД + «Транспортная безопасность» */
/* В шапке — фирменный блок в две строки: при высоте 52px надпись читается (в одну строку при той же
   высоте шапки она получалась ~8px). Однострочный вариант оставлен для широких экранов в резерве. */
.brand-lockup { display: none; height: 38px; width: auto; }
.brand-lockup-2 { display: block; height: 52px; width: auto; }
@media (max-width: 1400px) and (min-width: 1201px) { .brand-lockup-2 { height: 46px; } }
@media (max-width: 520px) { .brand-lockup-2 { height: 44px; } }
@media (max-width: 360px) { .brand-lockup-2 { height: 38px; } }

/* Подвал: фирменный блок для тёмного фона и слоган */
.footer-lockup { height: 58px; width: auto; display: block; margin-bottom: 14px; }
.brand-slogan {
    font-family: var(--font-head); font-weight: 800; text-transform: uppercase; letter-spacing: .06em;
    font-size: 13px; color: var(--red); margin: 0 0 16px;
}
footer .brand-slogan { color: #ff5a5a; }

/* Первый экран: слоган и красная линия «защищённого контура» */
.hero-slogan {
    font-family: var(--font-head); font-weight: 800; text-transform: uppercase; letter-spacing: .08em;
    font-size: 15px !important; color: #fff !important; margin: 0 0 14px !important; max-width: none !important;
    display: flex; align-items: center; gap: 14px; text-align: left !important;
}
.hero-slogan::before { content: ''; width: 44px; height: 3px; border-radius: 2px; background: var(--red); flex-shrink: 0; }
.brand-contour { position: absolute; left: 0; top: 18px; width: 100%; height: 120px; pointer-events: none; z-index: 1; }
.brand-contour path { fill: none; stroke: var(--red); stroke-width: 3; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.hero::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--red); z-index: 2; }
@media (max-width: 1200px) { .brand-contour { top: 8px; height: 64px; } }
@media (max-width: 600px) { .brand-contour { top: 6px; height: 40px; } }

/* «О компании»: белый щит-водяной знак и слоган в красной карточке */
.about-visual .bg-sign { position: absolute; right: -40px; bottom: -36px; width: 230px; height: auto; opacity: .12; pointer-events: none; }
.about-visual h3 { line-height: 1.25; }
.about-visual .brand-slogan { color: #fff; opacity: .9; margin: 22px 0 0; position: relative; }

/* «Нужна консультация?»: красный блок с фирменным паттерном */
.cta { background: var(--red) url('brand/pattern-tile.svg') repeat; background-size: 96px 96px; position: relative; }
.cta::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(226,26,26,.96) 0%, rgba(226,26,26,.82) 45%, rgba(226,26,26,.35) 100%); pointer-events: none; }
.cta .container { position: relative; }
.cta h2 i { color: #fff; }
.cta p { color: rgba(255,255,255,.92); }
.cta .btn-primary { background: #fff; color: var(--red-text); }
.cta .btn-primary:hover { background: #fff; color: var(--red-dark); box-shadow: 0 10px 24px -10px rgba(0,0,0,.45); }

/* «Вопросы и ответы»: ответ с перечнем — вводная фраза, список, заключение */
.faq-item p.faq-lead { padding-bottom: 8px; }
.faq-item .faq-ul { list-style: none; margin: 0 26px 14px 28px; padding: 0; color: var(--gray); font-size: 15px; }
.faq-ul li { position: relative; margin: 5px 0; padding-left: 20px; }
.faq-ul li::before { content: ''; position: absolute; left: 4px; top: .62em; width: 6px; height: 6px; border-radius: 50%; background: var(--red); }
@media (max-width: 900px) { .faq-item .faq-ul { margin: 0 20px 12px 22px; } }

/* ==========================================================================
   Слоган «Движение под защитой» на первом экране (29.10.2026)
   Рукописный слоган, мягкий блик каждые пять секунд.
   ========================================================================== */
@font-face {
    font-family: 'Lobster'; src: url('../fonts/Lobster-Regular.ttf') format('truetype');
    font-style: normal; font-weight: 400; font-display: swap;
}
/* Straight regular lettering with a red emphasis panel. */
.hero-motto {
    font-family: "RussianRail G Pro Extended", var(--font-head); font-weight: 400; font-style: normal; text-transform: none;
    font-size: clamp(25px, 5vw, 55px); line-height: 1.25; letter-spacing: normal;
    color: #fff; margin: 30px 0; width: fit-content; max-width: 100%;
    transform: none;
}
.hero-motto .m1, .hero-motto .m2 { display: block; padding: 0; margin: 0; overflow: visible; }
.hero-motto .m1 { margin-bottom: 0; }
.hero-motto .m1 > span, .hero-motto .m2 > span { display: inline-block; transform: none; animation: none; text-shadow: none; }
.hero-motto .m2 > span {
    position: relative; overflow: hidden; color: #fff; background: var(--red);
    padding: 0 12px; margin-left: 0; -webkit-background-clip: border-box; background-clip: border-box;
}
.hero-motto .m2 > span::after {
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background: linear-gradient(105deg, transparent 30%, rgba(255,255,255,.22) 50%, transparent 70%);
    transform: translateX(-120%); animation: motto-panel-sheen 5s ease-in-out infinite;
}
@keyframes motto-panel-sheen { 0% { transform: translateX(-120%); } 36%,100% { transform: translateX(120%); } }
@media (prefers-reduced-motion: reduce) { .hero-motto .m2 > span::after { animation: none; display: none; } }
@keyframes motto-up { to { transform: none; } }
@keyframes motto-sheen {
    0% { background-position: 100% 0; animation-timing-function: ease-in-out; }
    36%, 100% { background-position: 0 0; }
}
@keyframes motto-line { to { transform: scaleX(1); } }
/* заголовок страницы под слоганом — спокойнее и мельче */
.hero h1.hero-sub {
    font-size: clamp(21px, 2.3vw, 32px); font-weight: 700; letter-spacing: -.3px; line-height: 1.25;
    color: #e9e9e9; max-width: 760px; margin-bottom: 16px;
}
@media (prefers-reduced-motion: reduce) {
    .hero-motto .m1 > span, .hero-motto .m2 > span { animation: none; transform: none; background-position: 0 0; }
    .hero-motto .m2::after { animation: none; transform: none; }
}


/* Подвал на ширинах 901–1100: трём колонкам не хватает места (минимум ~954 px) —
   логотип на всю ширину сверху, ниже навигация и контакты */
@media (min-width: 901px) and (max-width: 1100px) {
    .footer-grid { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
    .footer-grid > :first-child { grid-column: 1 / -1; }
}

@media (max-width: 360px) { .career-top .head h1 { font-size: 27px; } }

footer .footer-grid > div:first-child > p:not(.brand-slogan) { text-align: justify; text-align-last: left; hyphens: none; -webkit-hyphens: none; }

.ld-scan.is-empty { border: 1px solid #d2d2d2; background: #f5f5f5; }
.ld-scan.is-empty img.document-placeholder { width: 120px; height: 150px; object-fit: contain; box-shadow: none; }
@media (max-width: 800px) { .ld-scan.is-empty img.document-placeholder { width: 64px; height: 80px; } }

/* Серебряный знак с обложки фирменного стиля. */
.hero-silver { position: absolute; width: 34%; max-width: 400px; height: auto; right: 24px; top: 110px; pointer-events: none; filter: drop-shadow(0 24px 32px rgba(0,0,0,.3)); }
.hero:has(.hero-silver) .hero-sub { max-width: 62%; }
.hero:has(.hero-silver) .hero-sub + p { max-width: 60%; }
.stat-detail { display: block; margin-top: 10px; font-size: 12px; line-height: 1.5; font-weight: 400; }
@media (max-width: 900px) { .hero-silver { position: static; float: right; width: 30%; margin: 0 0 20px 20px; } .hero:has(.hero-silver) .hero-sub, .hero:has(.hero-silver) .hero-sub + p { max-width: 100%; } }
@media (max-width: 600px) { .hero-silver { float: none; position: absolute; top: auto; bottom: 16px; left: calc(50% - 85px); width: 170px; margin: 0; } .hero:has(.hero-silver) > .container:not(.gl-stats-wrap) { padding-bottom: 210px; } }

/* Более широкая рабочая область на больших экранах. */
.container { max-width: 1400px; }
.ld { grid-template-columns: minmax(280px, 30%) minmax(0, 1fr); }
.ld-pane { grid-template-columns: minmax(180px, 36%) minmax(0, 1fr); gap: 24px; }
.ld-info { min-width: 0; }
.ld-info .lic-num { max-width: 100%; overflow-wrap: anywhere; }
.ld-scan img { object-fit: contain; }
@media (min-width: 901px) and (max-width: 1100px) { .ld-view { padding: 20px; } .ld-pane { grid-template-columns: minmax(0, 1fr); } .ld-scan { width: 190px; max-width: 100%; } }
@media (max-width: 900px) { .ld, .ld-pane { grid-template-columns: minmax(0, 1fr); } }

html.fx-bento #services .service-k9 { grid-area: m; }
#services .service-k9 p { max-width: 800px; }
#services .service-k9-link { display: inline-block; margin-top: 18px; color: inherit; text-decoration: underline; text-underline-offset: 4px; }

#k9 > .container > .k9-list { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 32px; gap: 16px; }
#k9 .k9-list li > div { min-width: 0; }
@media (max-width: 600px) { #k9 > .container > .k9-list { grid-template-columns: minmax(0, 1fr); } #k9 .k9-list li { padding: 20px 18px; gap: 14px; } }

/* Touch devices: avoid repainting large SVG blur/filter and glass on every frame. */
@media (hover: none) and (pointer: coarse) {
    .gl-stats-wrap .stat { -webkit-backdrop-filter: none; backdrop-filter: none; background: linear-gradient(135deg,rgba(58,58,58,.94),rgba(33,33,33,.94)); }
    html.ap-glass header { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(255,255,255,.97); }
}

/* Two separate licenses within the shared fire-safety card. */
.ld-license-section { padding: 0; margin-top: 20px; }
.ld-license-section + .ld-license-section { margin-top: 24px; padding-top: 24px; border-top: 1px solid var(--line); }
.ld-license-section .ld-title { margin: 0 0 12px; }
.ld-license-section .lic-scope { margin: 0 0 16px; }
.ld-license-section .lic-dl { margin: 16px 0; }
.ld-license-section .ld-foot { border-top: 0; padding-top: 0; }

.ld-preview { min-width: 0; align-self: start; }
.ld-preview .ld-scan { display: block; }
.ld-scan-hint { margin: 12px 0 0; font-size: 12px; line-height: 1.5; color: var(--gray); text-align: center; }
@media (max-width: 1100px) { .ld-preview { width: 190px; max-width: 100%; } }

/* Brandbook v2026.10.29, p.25: smaller headings use Rubik. */
h4, h5, h6, .ld-info .ld-title { font-family: var(--font-body); }

/* Brandbook v29: responsive hierarchy and restrained protected contours. */
:root { --section-space: clamp(48px, 6.5vw, 96px); --heading-gap: 16px; --content-gap: clamp(28px, 4vw, 48px); }
section.block { padding-block: var(--section-space); }
.head { margin-bottom: var(--content-gap); }
.head h1 { font-size: clamp(32px, 4.4vw, 64px); line-height: 1.19; font-weight: 700; letter-spacing: -.01em; }
.head h2, .lt-text h2 { font-size: clamp(28px, 3.3vw, 48px); line-height: 1.21; font-weight: 700; letter-spacing: -.01em; margin-bottom: var(--heading-gap); }
.head h1.h1-long { font-size: clamp(26px, 3.3vw, 48px); line-height: 1.21; }
.edu-sec h2 { font-size: clamp(24px, 2.2vw, 32px); line-height: 1.25; }
.edu-h3 { font-size: 20px; line-height: 1.4; }
.service h3, .job-card h3 { line-height: 1.35; }
.service p, .job-card p, .act p { line-height: 1.55; }
.eyebrow { color: var(--red-text); }
#services .eyebrow, .hero .eyebrow { color: #ff8a8a; }
#training > .container, #k9 > .container { position: relative; padding-top: 32px; }
#training > .container::before, #k9 > .container::before {
    content: ''; position: absolute; top: 0; left: 24px; width: 88px; height: 24px;
    border-top: 3px solid var(--red); border-left: 3px solid var(--red); border-top-left-radius: 22px; pointer-events: none;
}
.about-visual { border-radius: 28px 12px 28px 12px; }
.cta { background-image: none; isolation: isolate; overflow: hidden; }
.cta::before { content: ''; position: absolute; inset: 0 0 0 auto; width: 27%; background: url('brand/pattern-tile.svg') repeat; background-size: 112px; opacity: .55; z-index: -1; pointer-events: none; }
.cta > .container { position: relative; }
.hh-card { border-left: 4px solid var(--red); }
.edu-gallery img { border-radius: 16px; }
/* Replace former icon-font pseudo-elements too. */
.st-list li::before { content: ''; width: 1em; height: 1em; background: var(--red-text); -webkit-mask: url("data:image/svg+xml,%3C%21--%20%40license%20lucide-static%20v1.73.0%20-%20ISC%20--%3E%0A%3Csvg%0A%20%20class%3D%22lucide%20lucide-file-text%22%0A%20%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0A%20%20width%3D%2224%22%0A%20%20height%3D%2224%22%0A%20%20viewBox%3D%220%200%2024%2024%22%0A%20%20fill%3D%22none%22%0A%20%20stroke%3D%22currentColor%22%0A%20%20stroke-width%3D%222%22%0A%20%20stroke-linecap%3D%22round%22%0A%20%20stroke-linejoin%3D%22round%22%0A%3E%0A%20%20%3Cpath%20d%3D%22M6%2022a2%202%200%200%201-2-2V4a2%202%200%200%201%202-2h8a2.4%202.4%200%200%201%201.704.706l3.588%203.588A2.4%202.4%200%200%201%2020%208v12a2%202%200%200%201-2%202z%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M14%202v5a1%201%200%200%200%201%201h5%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M10%209H8%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M16%2013H8%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M16%2017H8%22%20%2F%3E%0A%3C%2Fsvg%3E%0A") center / contain no-repeat; mask: url("data:image/svg+xml,%3C%21--%20%40license%20lucide-static%20v1.73.0%20-%20ISC%20--%3E%0A%3Csvg%0A%20%20class%3D%22lucide%20lucide-file-text%22%0A%20%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0A%20%20width%3D%2224%22%0A%20%20height%3D%2224%22%0A%20%20viewBox%3D%220%200%2024%2024%22%0A%20%20fill%3D%22none%22%0A%20%20stroke%3D%22currentColor%22%0A%20%20stroke-width%3D%222%22%0A%20%20stroke-linecap%3D%22round%22%0A%20%20stroke-linejoin%3D%22round%22%0A%3E%0A%20%20%3Cpath%20d%3D%22M6%2022a2%202%200%200%201-2-2V4a2%202%200%200%201%202-2h8a2.4%202.4%200%200%201%201.704.706l3.588%203.588A2.4%202.4%200%200%201%2020%208v12a2%202%200%200%201-2%202z%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M14%202v5a1%201%200%200%200%201%201h5%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M10%209H8%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M16%2013H8%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M16%2017H8%22%20%2F%3E%0A%3C%2Fsvg%3E%0A") center / contain no-repeat; }
.st-no li::before { -webkit-mask-image: url("data:image/svg+xml,%3C%21--%20%40license%20lucide-static%20v1.73.0%20-%20ISC%20--%3E%0A%3Csvg%0A%20%20class%3D%22lucide%20lucide-ban%22%0A%20%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0A%20%20width%3D%2224%22%0A%20%20height%3D%2224%22%0A%20%20viewBox%3D%220%200%2024%2024%22%0A%20%20fill%3D%22none%22%0A%20%20stroke%3D%22currentColor%22%0A%20%20stroke-width%3D%222%22%0A%20%20stroke-linecap%3D%22round%22%0A%20%20stroke-linejoin%3D%22round%22%0A%3E%0A%20%20%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M4.929%204.929%2019.07%2019.071%22%20%2F%3E%0A%3C%2Fsvg%3E%0A"); mask-image: url("data:image/svg+xml,%3C%21--%20%40license%20lucide-static%20v1.73.0%20-%20ISC%20--%3E%0A%3Csvg%0A%20%20class%3D%22lucide%20lucide-ban%22%0A%20%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0A%20%20width%3D%2224%22%0A%20%20height%3D%2224%22%0A%20%20viewBox%3D%220%200%2024%2024%22%0A%20%20fill%3D%22none%22%0A%20%20stroke%3D%22currentColor%22%0A%20%20stroke-width%3D%222%22%0A%20%20stroke-linecap%3D%22round%22%0A%20%20stroke-linejoin%3D%22round%22%0A%3E%0A%20%20%3Ccircle%20cx%3D%2212%22%20cy%3D%2212%22%20r%3D%2210%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M4.929%204.929%2019.07%2019.071%22%20%2F%3E%0A%3C%2Fsvg%3E%0A"); }
html.fx-bento #services .service:nth-child(5)::after,
html.fx-bento #services .service:nth-child(6)::after { content: ''; width: 110px; height: 110px; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3C%21--%20%40license%20lucide-static%20v1.73.0%20-%20ISC%20--%3E%0A%3Csvg%0A%20%20class%3D%22lucide%20lucide-video%22%0A%20%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0A%20%20width%3D%2224%22%0A%20%20height%3D%2224%22%0A%20%20viewBox%3D%220%200%2024%2024%22%0A%20%20fill%3D%22none%22%0A%20%20stroke%3D%22currentColor%22%0A%20%20stroke-width%3D%222%22%0A%20%20stroke-linecap%3D%22round%22%0A%20%20stroke-linejoin%3D%22round%22%0A%3E%0A%20%20%3Cpath%20d%3D%22m16%2013%205.223%203.482a.5.5%200%200%200%20.777-.416V7.87a.5.5%200%200%200-.752-.432L16%2010.5%22%20%2F%3E%0A%20%20%3Crect%20x%3D%222%22%20y%3D%226%22%20width%3D%2214%22%20height%3D%2212%22%20rx%3D%222%22%20%2F%3E%0A%3C%2Fsvg%3E%0A") center / contain no-repeat; mask: url("data:image/svg+xml,%3C%21--%20%40license%20lucide-static%20v1.73.0%20-%20ISC%20--%3E%0A%3Csvg%0A%20%20class%3D%22lucide%20lucide-video%22%0A%20%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0A%20%20width%3D%2224%22%0A%20%20height%3D%2224%22%0A%20%20viewBox%3D%220%200%2024%2024%22%0A%20%20fill%3D%22none%22%0A%20%20stroke%3D%22currentColor%22%0A%20%20stroke-width%3D%222%22%0A%20%20stroke-linecap%3D%22round%22%0A%20%20stroke-linejoin%3D%22round%22%0A%3E%0A%20%20%3Cpath%20d%3D%22m16%2013%205.223%203.482a.5.5%200%200%200%20.777-.416V7.87a.5.5%200%200%200-.752-.432L16%2010.5%22%20%2F%3E%0A%20%20%3Crect%20x%3D%222%22%20y%3D%226%22%20width%3D%2214%22%20height%3D%2212%22%20rx%3D%222%22%20%2F%3E%0A%3C%2Fsvg%3E%0A") center / contain no-repeat; }
html.fx-bento #services .service:nth-child(6)::after { -webkit-mask-image: url("data:image/svg+xml,%3C%21--%20%40license%20lucide-static%20v1.73.0%20-%20ISC%20--%3E%0A%3Csvg%0A%20%20class%3D%22lucide%20lucide-drafting-compass%22%0A%20%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0A%20%20width%3D%2224%22%0A%20%20height%3D%2224%22%0A%20%20viewBox%3D%220%200%2024%2024%22%0A%20%20fill%3D%22none%22%0A%20%20stroke%3D%22currentColor%22%0A%20%20stroke-width%3D%222%22%0A%20%20stroke-linecap%3D%22round%22%0A%20%20stroke-linejoin%3D%22round%22%0A%3E%0A%20%20%3Cpath%20d%3D%22m12.99%206.74%201.93%203.44%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M19.136%2012a10%2010%200%200%201-14.271%200%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22m21%2021-2.16-3.84%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22m3%2021%208.02-14.26%22%20%2F%3E%0A%20%20%3Ccircle%20cx%3D%2212%22%20cy%3D%225%22%20r%3D%222%22%20%2F%3E%0A%3C%2Fsvg%3E%0A"); mask-image: url("data:image/svg+xml,%3C%21--%20%40license%20lucide-static%20v1.73.0%20-%20ISC%20--%3E%0A%3Csvg%0A%20%20class%3D%22lucide%20lucide-drafting-compass%22%0A%20%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%0A%20%20width%3D%2224%22%0A%20%20height%3D%2224%22%0A%20%20viewBox%3D%220%200%2024%2024%22%0A%20%20fill%3D%22none%22%0A%20%20stroke%3D%22currentColor%22%0A%20%20stroke-width%3D%222%22%0A%20%20stroke-linecap%3D%22round%22%0A%20%20stroke-linejoin%3D%22round%22%0A%3E%0A%20%20%3Cpath%20d%3D%22m12.99%206.74%201.93%203.44%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22M19.136%2012a10%2010%200%200%201-14.271%200%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22m21%2021-2.16-3.84%22%20%2F%3E%0A%20%20%3Cpath%20d%3D%22m3%2021%208.02-14.26%22%20%2F%3E%0A%20%20%3Ccircle%20cx%3D%2212%22%20cy%3D%225%22%20r%3D%222%22%20%2F%3E%0A%3C%2Fsvg%3E%0A"); }
@media (max-width: 600px) {
    .head h1.h1-long { font-size: 26px; }
    .head h1.h1-long .nobr { white-space: normal; }
    #training > .container::before, #k9 > .container::before { left: 16px; }
    .cta::before { width: 22%; opacity: .25; }
}
