/* ============================================================
   Кванториум — Дом пионеров · дизайн-система
   Палитра из логотипа: синий, оранжевый, красный, зелёный, голубой
   ============================================================ */
:root {
  --blue: #1B3C87;
  --navy: #0F2357;
  --navy-deep: #0A1838;
  --orange: #F26522;
  --red: #D93A2B;
  --green: #2BA84A;
  --cyan: #29A8DF;
  --yellow: #FFC93C;

  --bg: #F6F9FE;
  --surface: #FFFFFF;
  --ink: #13223F;
  --ink-soft: #4A5A78;
  --line: #E3EAF4;

  --font-head: 'Unbounded', system-ui, sans-serif;
  --font-body: 'Manrope', system-ui, sans-serif;

  --radius: 20px;
  --radius-sm: 12px;
  --shadow: 0 10px 30px rgba(19, 34, 63, .08);
  --shadow-lift: 0 18px 44px rgba(19, 34, 63, .14);
  --container: 1200px;

  --dur: .25s;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: clip; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--orange); }
:focus-visible { outline: 3px solid var(--cyan); outline-offset: 3px; border-radius: 4px; }
button { font: inherit; cursor: pointer; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.section { padding: 96px 0; }
.section-dark { background: linear-gradient(160deg, var(--navy) 0%, var(--navy-deep) 100%); color: #EAF1FF; }
.section-tint { background: linear-gradient(180deg, #EEF4FC 0%, var(--bg) 100%); }
.nowrap { white-space: nowrap; }

/* ---------- Типографика секций ---------- */
.section-kicker {
  font-weight: 800; font-size: 14px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--orange); margin: 0 0 12px;
}
.section-title {
  font-family: var(--font-head); font-weight: 700;
  font-size: clamp(26px, 4.2vw, 44px); line-height: 1.15;
  margin: 0 0 18px; letter-spacing: -.01em;
}
.section-dark .section-title { color: #fff; }
.section-sub { max-width: 640px; color: var(--ink-soft); margin: 0 0 40px; }
.section-dark .section-sub { color: #B9C7E4; }
.amp { color: var(--orange); }
.grad-text {
  background: linear-gradient(90deg, var(--orange) 0%, var(--red) 40%, var(--cyan) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 26px; border-radius: 999px;
  font-weight: 800; font-size: 16px; border: 2px solid transparent;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), background var(--dur), color var(--dur);
  touch-action: manipulation; user-select: none;
}
.btn:active { transform: scale(.97); }
.btn-primary {
  background: linear-gradient(135deg, var(--orange), var(--red));
  color: #fff; box-shadow: 0 8px 22px rgba(242, 101, 34, .35);
}
.btn-primary:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 12px 28px rgba(242, 101, 34, .45); }
.btn-ghost { background: transparent; border-color: var(--blue); color: var(--blue); }
.btn-ghost:hover { background: var(--blue); color: #fff; }
.section-dark .btn-ghost { border-color: #7E96CC; color: #EAF1FF; }
.section-dark .btn-ghost:hover { background: #ffffff14; }
.btn-lg { min-height: 56px; padding: 16px 34px; font-size: 17px; }
.btn-sm { min-height: 42px; padding: 8px 18px; font-size: 15px; }
.btn[disabled] { opacity: .55; pointer-events: none; }

.link-arrow {
  display: inline-flex; align-items: center; gap: 6px; font-weight: 800; font-size: 15px;
  min-height: 44px;
}
.link-arrow::after { content: '→'; transition: transform var(--dur) var(--ease); }
.link-arrow:hover::after { transform: translateX(5px); }

/* ============================================================
   ШАПКА
   ============================================================ */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur), box-shadow var(--dur);
}
.site-header.is-scrolled { border-color: var(--line); box-shadow: 0 4px 24px rgba(19, 34, 63, .07); }
.header-inner { display: flex; align-items: center; gap: 28px; min-height: 74px; }
.logo { display: flex; align-items: center; gap: 12px; margin-right: auto; }
.logo-mark { width: 42px; height: 42px; flex: none; }
.logo-mark svg { animation: logoSpin 24s linear infinite; }
@keyframes logoSpin { to { transform: rotate(360deg); } }
.logo-text { display: flex; flex-direction: column; line-height: 1.15; }
.logo-text b { font-family: var(--font-head); font-size: 17px; font-weight: 700; color: var(--navy); letter-spacing: .02em; }
.logo-text i { font-style: normal; font-size: 12px; color: var(--ink-soft); font-weight: 600; }
.main-nav { display: flex; gap: 4px; }
.main-nav a {
  padding: 10px 14px; border-radius: 999px; font-weight: 700; font-size: 15px; color: var(--ink);
  transition: background var(--dur), color var(--dur);
}
.main-nav a:hover, .main-nav a.is-active { background: #E9F0FB; color: var(--blue); }
.burger { display: none; }

/* ============================================================
   ГЕРОЙ
   ============================================================ */
.hero { position: relative; overflow: hidden; padding: 70px 0 0; }
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.blob { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .5; }
.blob-1 { width: 480px; height: 480px; background: #CFE3FF; top: -140px; left: -120px; }
.blob-2 { width: 420px; height: 420px; background: #FFE1CE; top: 30%; right: -140px; }
.blob-3 { width: 360px; height: 360px; background: #D3F3DC; bottom: -120px; left: 30%; }
.float-shape { position: absolute; width: 44px; opacity: .8; }
.fs-1 { top: 18%; left: 6%; }
.fs-2 { top: 64%; left: 12%; width: 34px; }
.fs-3 { top: 14%; right: 10%; }
.fs-4 { top: 58%; right: 5%; width: 54px; }

.hero-inner {
  position: relative; display: grid; grid-template-columns: 1.1fr .9fr;
  gap: 48px; align-items: center; padding-top: 40px; padding-bottom: 60px;
}
.hero-kicker { font-weight: 800; font-size: 14px; letter-spacing: .1em; text-transform: uppercase; color: var(--cyan); margin: 0 0 16px; }
.hero h1 {
  font-family: var(--font-head); font-weight: 900;
  font-size: clamp(30px, 5.2vw, 56px); line-height: 1.12; letter-spacing: -.015em;
  color: var(--navy); margin: 0 0 20px;
}
.hero-sub { font-size: clamp(17px, 2vw, 20px); color: var(--ink-soft); max-width: 520px; margin: 0 0 24px; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 30px; }
.badge {
  display: inline-flex; align-items: center; min-height: 38px; padding: 6px 16px;
  border-radius: 999px; font-weight: 800; font-size: 14px;
}
.badge-green { background: #E2F6E8; color: #187A33; }
.badge-blue { background: #E5EEFC; color: var(--blue); }
.badge-orange { background: #FFEADD; color: #C24A0D; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; }
.hero-art { position: relative; }
.building-svg { width: 100%; height: auto; filter: drop-shadow(0 24px 40px rgba(19, 34, 63, .16)); }
.building-svg .bw { transition: opacity .4s; }

/* Бегущая строка */
.marquee {
  position: relative; overflow: hidden; padding: 16px 0;
  background: var(--navy); transform: rotate(-1.2deg) scale(1.02); margin-top: 10px;
}
.marquee-track { display: flex; gap: 26px; width: max-content; animation: mq 36s linear infinite; align-items: center; }
@keyframes mq { to { transform: translateX(-50%); } }
.mq-item { font-family: var(--font-head); font-weight: 700; font-size: 15px; color: #fff; white-space: nowrap; }
.mq-item.c0 { color: #FFB88A; } .mq-item.c1 { color: #8FD9FF; } .mq-item.c2 { color: #9BE8B0; }
.mq-item.c3 { color: #FFD97A; } .mq-item.c4 { color: #FF9E93; }
.mq-dot { color: #46609F; font-size: 12px; }

/* ============================================================
   ПРИЁМ / ТАЙМЕР
   ============================================================ */
.admission { padding: 70px 0 20px; }
.admission-card {
  display: flex; flex-wrap: wrap; gap: 32px; align-items: center; justify-content: space-between;
  background: linear-gradient(120deg, var(--orange) 0%, var(--red) 100%);
  border-radius: 28px; padding: 40px 48px; color: #fff;
  box-shadow: 0 20px 50px rgba(217, 58, 43, .3);
  position: relative; overflow: hidden;
}
.admission-card::after {
  content: ''; position: absolute; right: -60px; top: -60px; width: 220px; height: 220px;
  border: 30px solid rgba(255, 255, 255, .14); border-radius: 50%;
}
.admission-kicker { font-weight: 800; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; opacity: .85; margin: 0 0 8px; }
.admission-left h2 { font-family: var(--font-head); font-weight: 700; font-size: clamp(22px, 3vw, 34px); margin: 0 0 10px; }
.admission-left p { margin: 0; max-width: 480px; opacity: .95; }
.admission-timer { display: flex; gap: 12px; position: relative; z-index: 1; }
.timer-cell {
  background: rgba(255, 255, 255, .16); border-radius: 16px; padding: 12px 8px;
  min-width: 76px; text-align: center; backdrop-filter: blur(4px);
}
.timer-cell b { display: block; font-family: var(--font-head); font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; }
.timer-cell span { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; opacity: .85; }

/* ============================================================
   ДВА МИРА
   ============================================================ */
.worlds-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-bottom: 40px; }
.world-card {
  background: var(--surface); border-radius: var(--radius); padding: 36px;
  box-shadow: var(--shadow); border-top: 6px solid var(--cyan);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.world-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }
.world-dom { border-top-color: var(--orange); }
.world-icon { width: 84px; margin-bottom: 18px; }
.world-card h3 { font-family: var(--font-head); font-weight: 700; font-size: 24px; margin: 0 0 12px; color: var(--navy); }
.world-card p { color: var(--ink-soft); margin: 0 0 18px; }
.history {
  display: flex; gap: 28px; align-items: center; background: var(--surface);
  border-radius: var(--radius); padding: 30px 36px; box-shadow: var(--shadow);
}
.history-year {
  font-family: var(--font-head); font-weight: 900; font-size: clamp(38px, 5vw, 58px);
  background: linear-gradient(180deg, var(--cyan), var(--blue));
  -webkit-background-clip: text; background-clip: text; color: transparent; flex: none;
}
.history p { margin: 0; color: var(--ink-soft); }

/* ============================================================
   ШАГИ
   ============================================================ */
.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; counter-reset: step; }
.step-card {
  position: relative; background: #16295C; border: 1px solid #26407F;
  border-radius: var(--radius); padding: 66px 24px 24px;
  transition: transform var(--dur) var(--ease), border-color var(--dur);
}
.step-card:hover { transform: translateY(-6px); border-color: var(--cyan); }
.step-num {
  position: absolute; top: 20px; left: 24px; width: 44px; height: 44px;
  display: grid; place-items: center; border-radius: 14px;
  font-family: var(--font-head); font-weight: 700; font-size: 20px; color: #fff;
}
.step-card:nth-child(1) .step-num { background: var(--cyan); }
.step-card:nth-child(2) .step-num { background: var(--orange); }
.step-card:nth-child(3) .step-num { background: var(--green); }
.step-card:nth-child(4) .step-num { background: var(--red); }
.step-card h3 { font-size: 19px; font-weight: 800; margin: 0 0 10px; color: #fff; }
.step-card p { font-size: 15px; color: #B9C7E4; margin: 0 0 16px; }
.step-card .link-arrow { color: #8FD9FF; }
.step-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.warn-strip { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 34px; }
.warn-item {
  display: flex; gap: 14px; align-items: center; background: #ffffff10;
  border: 1px dashed #4C66A8; border-radius: var(--radius-sm); padding: 16px 20px;
  color: #D7E2F8; font-size: 15px;
}
.warn-ico {
  flex: none; width: 38px; height: 38px; display: grid; place-items: center;
  background: var(--yellow); color: var(--navy); font-weight: 900; border-radius: 12px; font-size: 17px;
}

/* ============================================================
   ДОКУМЕНТЫ
   ============================================================ */
.docs-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.doc-card {
  background: var(--surface); border-radius: var(--radius); padding: 28px;
  box-shadow: var(--shadow);
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.doc-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lift); }
.doc-ico { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 16px; margin-bottom: 16px; }
.doc-ico svg { width: 28px; height: 28px; }
.doc-ico-blue { background: #E5EEFC; color: var(--blue); }
.doc-ico-orange { background: #FFEADD; color: var(--orange); }
.doc-ico-green { background: #E2F6E8; color: var(--green); }
.doc-ico-cyan { background: #E0F3FC; color: var(--cyan); }
.doc-ico-red { background: #FBE3E0; color: var(--red); }
.doc-ico-yellow { background: #FFF3D1; color: #B98600; }
.doc-card h3 { font-size: 18px; font-weight: 800; margin: 0 0 8px; color: var(--navy); }
.doc-card p { font-size: 15px; color: var(--ink-soft); margin: 0; }
.doc-card-note { background: #FFFBEE; border: 1px dashed #EAD48A; box-shadow: none; }
.doc-links { display: flex; flex-direction: column; gap: 4px; margin-top: 14px; }
.link-dl { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; font-size: 15px; min-height: 40px; }
.link-dl::before { content: '⤓'; color: var(--orange); font-size: 18px; }

/* ============================================================
   СНИЛС
   ============================================================ */
.snils-inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.snils-note { font-size: 15px; color: var(--ink-soft); }
.snils-note code { background: #E9F0FB; border-radius: 6px; padding: 2px 8px; font-size: 14px; }
.snils-box {
  background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow-lift);
  padding: 34px; border-top: 6px solid var(--cyan);
}
.field-label { display: block; font-weight: 800; margin-bottom: 10px; }
.snils-row { display: flex; gap: 12px; }
.snils-row input {
  flex: 1; min-width: 0; min-height: 52px; padding: 12px 18px;
  border: 2px solid var(--line); border-radius: 14px;
  font: inherit; font-size: 18px; font-weight: 700; letter-spacing: .06em;
  color: var(--ink); background: #FAFCFF;
  transition: border-color var(--dur);
}
.snils-row input:focus { outline: none; border-color: var(--cyan); }
.snils-row input.is-error { border-color: var(--red); }
.field-hint { font-size: 14px; color: var(--ink-soft); margin: 10px 0 0; }
.snils-result { margin-top: 18px; border-radius: 14px; font-size: 15px; }
.snils-result:not(:empty) { padding: 16px 18px; }
.snils-result.ok { background: #E2F6E8; color: #14602A; }
.snils-result.none { background: #E5EEFC; color: var(--navy); }
.snils-result.err { background: #FBE3E0; color: #8E2015; }
.snils-result b.email { font-size: 17px; letter-spacing: .02em; }

/* ============================================================
   НАПРАВЛЕНИЯ
   ============================================================ */
.prog-filters { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; justify-content: space-between; margin-bottom: 34px; }
.chip-row { display: flex; flex-wrap: wrap; gap: 10px; }
.chip {
  min-height: 44px; padding: 8px 20px; border-radius: 999px;
  border: 2px solid var(--line); background: var(--surface);
  font-weight: 800; font-size: 15px; color: var(--ink-soft);
  transition: all var(--dur) var(--ease);
}
.chip:hover { border-color: var(--cyan); color: var(--blue); }
.chip.is-active { background: var(--navy); border-color: var(--navy); color: #fff; }
.chip-kvant.is-active { background: var(--blue); border-color: var(--blue); }
.chip-dom.is-active { background: var(--orange); border-color: var(--orange); }
.section-dark .chip { background: #16295C; border-color: #26407F; color: #B9C7E4; }
.section-dark .chip:hover { border-color: var(--cyan); color: #fff; }
.section-dark .chip.is-active { background: var(--cyan); border-color: var(--cyan); color: var(--navy-deep); }
.age-filter { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 15px; color: var(--ink-soft); }
.age-filter select {
  min-height: 44px; padding: 8px 14px; border-radius: 12px; border: 2px solid var(--line);
  font: inherit; font-weight: 700; color: var(--ink); background: var(--surface);
}
.age-filter-light { color: #B9C7E4; }
.age-filter-light select { background: #16295C; border-color: #26407F; color: #fff; }

.prog-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.prog-card {
  background: var(--surface); border-radius: var(--radius); padding: 24px;
  box-shadow: var(--shadow); cursor: pointer; position: relative;
  display: flex; flex-direction: column; gap: 10px;
  border: 2px solid transparent;
  transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease), border-color var(--dur);
}
.prog-card:hover { transform: translateY(-6px) scale(1.01); box-shadow: var(--shadow-lift); }
.prog-card.cat-kvant:hover { border-color: #BFD4F5; }
.prog-card.cat-dom:hover { border-color: #FBD0B5; }
.prog-card.is-hidden { display: none; }
.prog-art { width: 88px; height: 88px; margin-bottom: 4px; }
.prog-art svg { width: 100%; height: 100%; }
.prog-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.prog-age {
  font-weight: 800; font-size: 13px; background: #E9F0FB; color: var(--blue);
  border-radius: 999px; padding: 4px 12px;
}
.prog-tag { font-weight: 800; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; }
.tag-kvant { color: var(--cyan); }
.tag-dom { color: var(--orange); }
.prog-card h3 { font-size: 18px; font-weight: 800; margin: 0; color: var(--navy); line-height: 1.3; }
.prog-card p {
  font-size: 14px; color: var(--ink-soft); margin: 0;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.prog-more { margin-top: auto; font-weight: 800; font-size: 14px; color: var(--orange); }
.prog-more::after { content: ' →'; }
.prog-empty { text-align: center; color: var(--ink-soft); padding: 40px 0; }

/* ============================================================
   РАСПИСАНИЕ
   ============================================================ */
.sched-filters { display: flex; flex-wrap: wrap; gap: 18px; align-items: center; justify-content: space-between; margin-bottom: 34px; }
.sched-list { display: flex; flex-direction: column; gap: 30px; }
.sched-prog h3 {
  font-family: var(--font-head); font-weight: 700; font-size: 20px; color: #fff; margin: 0 0 6px;
}
.sched-prog .sched-teacher { font-size: 14px; color: #8CA2D4; margin: 0 0 14px; }
.sched-groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.group-card {
  background: #16295C; border: 1px solid #26407F; border-radius: var(--radius-sm);
  padding: 16px 18px; display: flex; flex-direction: column; gap: 8px;
  transition: border-color var(--dur), transform var(--dur) var(--ease);
}
.group-card:hover { border-color: #3D5CA6; transform: translateY(-3px); }
.group-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.group-code { font-weight: 800; color: #fff; font-size: 15px; }
.group-status { font-size: 12px; font-weight: 800; padding: 3px 10px; border-radius: 999px; }
.group-status.open { background: #123F24; color: #7BE39A; }
.group-status.full { background: #4A1610; color: #FF9E93; }
.group-age { font-size: 13px; color: #8CA2D4; }
.group-times { display: flex; flex-direction: column; gap: 4px; }
.group-time { display: flex; gap: 10px; font-size: 14px; color: #D7E2F8; font-variant-numeric: tabular-nums; }
.group-time b { color: var(--yellow); min-width: 26px; font-weight: 800; }
.group-room { font-size: 12px; color: #6E86BC; }
.group-card.is-full { opacity: .6; }
.sched-footnote { margin-top: 30px; font-size: 14px; color: #8CA2D4; }
.sched-empty { color: #8CA2D4; }

/* ============================================================
   ИНКЛЮЗИЯ / АВТОБУС
   ============================================================ */
.inclusion { padding-bottom: 0; overflow: hidden; }
.inclusion-inner { max-width: 760px; }
.road-scene { position: relative; height: 190px; margin-top: 30px; }
.road-line {
  position: absolute; left: 0; right: 0; bottom: 28px; height: 10px;
  background: repeating-linear-gradient(90deg, var(--navy) 0 60px, transparent 60px 90px);
  opacity: .18; border-radius: 5px;
}
.road-scene::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 20px; height: 4px;
  background: var(--navy); opacity: .25; border-radius: 2px;
}
.bus-wrap { position: absolute; bottom: 30px; left: 0; width: min(300px, 60vw); will-change: transform; }
.bus-svg { width: 100%; height: auto; filter: drop-shadow(0 14px 20px rgba(19, 34, 63, .2)); }

/* ============================================================
   КОНТАКТЫ / ФУТЕР
   ============================================================ */
.contacts-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.contact-card { background: var(--surface); border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); }
.contact-card h3 { font-family: var(--font-head); font-weight: 700; font-size: 18px; margin: 0 0 12px; color: var(--navy); }
.contact-card p { margin: 0 0 12px; color: var(--ink-soft); }
.contact-big { font-size: 22px; font-weight: 800; color: var(--navy); font-variant-numeric: tabular-nums; }
.contact-big:hover { color: var(--orange); }
.hours { display: flex; flex-direction: column; gap: 6px; }
.hours b { color: var(--ink); display: inline-block; min-width: 64px; }
.site-footer { background: var(--navy-deep); color: #8CA2D4; padding: 34px 0; }
.footer-inner { display: flex; flex-wrap: wrap; gap: 10px; justify-content: space-between; font-size: 14px; }
.footer-inner p { margin: 0; }

/* ============================================================
   МОДАЛКА
   ============================================================ */
.modal { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 20px; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(10, 24, 56, .55); backdrop-filter: blur(4px); }
.modal-dialog {
  position: relative; background: var(--surface); border-radius: 24px;
  max-width: 640px; width: 100%; max-height: 86vh; overflow: auto;
  padding: 36px; box-shadow: 0 30px 80px rgba(10, 24, 56, .4);
  animation: modalIn .28s var(--ease);
}
@keyframes modalIn { from { opacity: 0; transform: translateY(24px) scale(.97); } }
.modal-close {
  position: sticky; top: 0; float: right; margin: -20px -20px 0 0;
  width: 44px; height: 44px; border-radius: 50%; border: none;
  background: #EEF3FB; color: var(--ink); font-size: 16px; font-weight: 700;
}
.modal-close:hover { background: var(--red); color: #fff; }
.modal-content h3 { font-family: var(--font-head); font-weight: 700; font-size: 24px; color: var(--navy); margin: 0 0 6px; padding-right: 30px; }
.modal-prog-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.help-list { padding-left: 20px; display: flex; flex-direction: column; gap: 10px; color: var(--ink-soft); margin: 16px 0 22px; }
.modal-groups { margin-top: 20px; }
.modal-groups h4 { font-size: 16px; font-weight: 800; margin: 0 0 12px; color: var(--navy); }
.modal-group {
  display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center;
  border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; margin-bottom: 8px; font-size: 14px;
}
.modal-group b { color: var(--navy); }
.modal-group .full-mark { color: var(--red); font-weight: 800; }
.modal-group .open-mark { color: var(--green); font-weight: 800; }
.modal-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }

/* ============================================================
   АНИМАЦИИ ПОЯВЛЕНИЯ (включаются только при наличии JS+GSAP)
   ============================================================ */
body.gsap-on .anim-up, body.gsap-on .anim-card { opacity: 0; }

/* ============================================================
   АДАПТИВ
   ============================================================ */
@media (max-width: 1024px) {
  .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .prog-grid { grid-template-columns: repeat(3, 1fr); }
  .docs-grid { grid-template-columns: repeat(2, 1fr); }
  .main-nav { display: none; }
  .header-cta { margin-left: auto; }
  .burger {
    display: flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 48px; height: 48px; padding: 10px; border: none; background: transparent;
  }
  .burger span { height: 3px; border-radius: 2px; background: var(--navy); transition: transform var(--dur), opacity var(--dur); }
  .burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
  .main-nav.is-open {
    display: flex; flex-direction: column; position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; border-bottom: 1px solid var(--line); padding: 12px 24px 20px;
    box-shadow: 0 24px 40px rgba(19, 34, 63, .12);
  }
  .main-nav.is-open a { min-height: 48px; display: flex; align-items: center; }
}
@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; gap: 30px; padding-top: 20px; }
  .hero-art { max-width: 460px; }
  .snils-inner { grid-template-columns: 1fr; gap: 30px; }
  .worlds-grid { grid-template-columns: 1fr; }
  .warn-strip { grid-template-columns: 1fr; }
  .admission-card { padding: 30px; }
  .contacts-grid { grid-template-columns: 1fr; }
  .history { flex-direction: column; align-items: flex-start; gap: 8px; padding: 26px; }
}
@media (max-width: 640px) {
  .section { padding: 64px 0; }
  .container { padding: 0 18px; }
  .steps-grid { grid-template-columns: 1fr; }
  .prog-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .prog-card { padding: 16px; }
  .prog-art { width: 64px; height: 64px; }
  .prog-card h3 { font-size: 15px; }
  .prog-card p { display: none; }
  .docs-grid { grid-template-columns: 1fr; }
  .header-cta { display: none; }
  .timer-cell { min-width: 62px; }
  .timer-cell b { font-size: 24px; }
  .admission-timer { flex-wrap: wrap; }
  .snils-row { flex-direction: column; }
  .snils-row .btn { width: 100%; }
  .prog-filters, .sched-filters { flex-direction: column; align-items: flex-start; }
  .modal-dialog { padding: 24px; }
  .logo-text i { display: none; }
}
