/* OlimPoint - стиль «Лаванда» (светлая тема, фиолетовый акцент). Прошлый стиль: design-backup/style-v8.css */
:root {
  --bg: #F5F3FF;
  --surface: #FFFFFF;
  --surface-2: #FAF8FF;
  --line: #E4DEFF;
  --line-strong: #CFC6F7;
  --text: #1E1B4B;
  --text-2: #3F3B73;
  --muted: #57538A;
  --accent: #5B3DF5;
  --accent-hover: #4A2DE0;
  --accent-ink: #4C2FE0;
  --on-accent: #FFFFFF;
  --accent-soft: #ECE8FF;
  --hot: #F2663F;
  --hot-text: #B83A17;
  --hot-soft: #FFE3D8;
  --radius: 28px;
  --wrap: 1296px;
  --mono: "JetBrains Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: auto; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Nunito, system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent-ink); text-decoration: none; }
a:hover { color: var(--accent-hover); }
h1, h2, h3 { margin: 0; letter-spacing: -0.02em; }
h2 { font-size: 34px; font-weight: 800; line-height: 1.1; }
p { margin: 0; }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

.wrap { width: 100%; max-width: calc(var(--wrap) + 48px); margin: 0 auto; padding: 0 24px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.mono { font-family: var(--mono); }
.strong { font-weight: 700; }
.accent { color: var(--accent); }
.eyebrow { font-family: var(--mono); font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.eyebrow.dark { color: var(--text); }
.eyebrow.accent { color: var(--accent-ink); }
.eyebrow.warm { color: var(--hot-text); }

/* ---------- кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 16px; border-radius: 12px;
  font-size: 15px; font-weight: 700; cursor: pointer; white-space: nowrap;
  border: 1px solid transparent; background: none; color: var(--text);
}
.btn-lg { min-height: 52px; padding: 0 22px; font-size: 16px; border-radius: 14px; }
.btn-accent { background: var(--accent); color: var(--on-accent); font-weight: 800; }
.btn-accent:hover { background: var(--accent-hover); color: var(--on-accent); }
.btn-ghost { border-color: var(--line-strong); color: var(--text); }
.btn-ghost:hover { border-color: var(--text-2); color: var(--text); }
.btn-dark { background: #FFFFFF; color: #3A22C4; }
.btn-dashed { border: 1px dashed var(--line-strong); color: var(--muted); width: 100%; }

.heart { fill: none; stroke: var(--muted); stroke-width: 2; }
[aria-pressed="true"] .heart, .has-favs .top .heart { fill: var(--hot); stroke: var(--hot); }

/* ---------- шапка ---------- */
.top {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 16px max(24px, calc((100vw - var(--wrap)) / 2));
  background: #F5F3FF;
  border-bottom: 1px solid var(--line);
}
.logo { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 800; font-size: 20px; letter-spacing: -0.02em; }
.logo:hover { color: var(--text); }
.logo-dot { width: 14px; height: 14px; border-radius: 50%; background: var(--accent); }
.menu { display: flex; gap: 4px; padding: 5px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; }
.menu a { padding: 9px 16px; border-radius: 999px; color: var(--text-2); font-size: 15px; font-weight: 500; }
.menu a:hover { color: var(--text); }
.menu a.is-active { background: var(--accent); color: var(--on-accent); }
.top-actions { display: flex; gap: 10px; }

/* ---------- первый экран ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) 460px; gap: 40px; padding-top: 56px; padding-bottom: 48px; }
.hero-main { display: flex; flex-direction: column; gap: 24px; }
.hero h1 { font-size: clamp(44px, 6vw, 76px); font-weight: 900; line-height: 0.98; letter-spacing: -0.045em; }
.lead { font-size: 18px; color: var(--text-2); max-width: 620px; }
.search { display: flex; gap: 10px; max-width: 760px; }
.search-box {
  flex: 1; display: flex; align-items: center; gap: 12px; height: 60px; padding: 0 18px;
  border-radius: 14px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--muted);
}
.search-box:focus-within { border-color: var(--accent); }
.search-box input { flex: 1; border: 0; outline: none; background: transparent; color: var(--text); font-size: 17px; min-width: 0; }
.search .btn { min-height: 60px; }
.selects { display: flex; flex-wrap: wrap; gap: 8px; }
.select select {
  appearance: none; min-height: 44px; padding: 0 34px 0 14px; border-radius: 10px;
  border: 1px solid var(--line-strong); background: var(--surface-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2357538A' stroke-width='3'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center;
  color: var(--text-2); font-size: 14px; font-weight: 600; cursor: pointer;
}
.select select.is-set { border-color: var(--accent); color: var(--accent-ink); background-color: var(--accent-soft); }
.select select option { background: var(--surface); color: var(--text); }

.hero-side { display: flex; flex-direction: column; gap: 14px; }
.countdown {
  display: flex; flex-direction: column; gap: 12px; padding: 28px; border-radius: 26px;
  background: var(--accent); color: var(--on-accent);
}
a.countdown:hover { color: var(--on-accent); background: #4F32EA; }
.countdown-num { display: flex; align-items: baseline; gap: 12px; }
.countdown-num b { font-size: 112px; font-weight: 900; line-height: 0.85; letter-spacing: -0.05em; }
.countdown-num span { font-size: 32px; font-weight: 800; }
.countdown-foot { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; }
.countdown-text { display: flex; flex-direction: column; gap: 3px; }
.countdown-text strong { font-size: 20px; font-weight: 800; line-height: 1.2; }
.countdown-text span { font-size: 15px; }

.panel { display: flex; flex-direction: column; gap: 10px; padding: 16px 22px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); }
.panel-link { font-size: 14px; font-weight: 700; }
.deadlines { list-style: none; margin: 0; padding: 0; }
.deadlines li { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.deadlines li:last-child { border-bottom: 0; }
.dl-date { width: 48px; flex-shrink: 0; display: flex; flex-direction: column; align-items: center; font-family: var(--mono); }
.dl-date b { font-size: 19px; line-height: 1; }
.dl-date span { font-size: 11px; color: var(--muted); margin-top: 3px; }
.dl-text { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.dl-text a { color: var(--text); font-size: 14px; font-weight: 600; }
.dl-text a:hover { color: var(--accent-ink); }
.dl-text span { font-size: 12px; color: var(--muted); }
.deadlines-wide { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 6px 22px; margin-bottom: 14px; }
.deadlines-wide .dl-text a { font-size: 16px; }
.deadlines-wide .dl-text span { font-size: 14px; }

/* ---------- каталог ---------- */
.catalog { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 36px; padding-top: 16px; padding-bottom: 72px; scroll-margin-top: 80px; }
.filters { display: flex; flex-direction: column; gap: 24px; padding-top: 74px; }
.fgroup { display: flex; flex-direction: column; gap: 8px; }
.fbtn {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  min-height: 44px; padding: 8px 14px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--surface); color: var(--text); font-size: 14px; font-weight: 600; text-align: left; cursor: pointer;
}
.fbtn i { font-style: normal; font-family: var(--mono); font-size: 12px; opacity: 0.75; }
.fbtn:hover { border-color: var(--line-strong); }
.fbtn[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }

.results { display: flex; flex-direction: column; gap: 22px; }
.results-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.results-head h2 { font-size: 36px; margin-bottom: 4px; }
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.card { display: flex; flex-direction: column; gap: 14px; padding: 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.card:hover { border-color: var(--line-strong); }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.card-body { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card-title { color: var(--text); font-size: 21px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.2; }
.card-title:hover { color: var(--accent-ink); }
.card-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding-top: 14px; border-top: 1px solid var(--line); }
.next-when { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-family: var(--mono); font-size: 12px; font-weight: 700; padding: 5px 10px; border-radius: 8px; }
.tag-lg { font-size: 13px; padding: 6px 12px; }
.tag-muted { background: #F1EEFF; color: var(--text-2); }
.lv-I { background: var(--text); color: #FFFFFF; }
.lv-II { background: #DCD4FF; color: #2A1C8F; }
.lv-III { background: #FFE3D8; color: #6B2412; }
.lv-new { background: #DBEAFE; color: #1E3A8A; }
.lv-vsosh { background: #D5F5E9; color: #0F5132; }
.fav { width: 44px; height: 44px; flex-shrink: 0; border-radius: 50%; border: 1px solid var(--line-strong); background: transparent; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.fav:hover { border-color: var(--text-2); }
.pill { flex-shrink: 0; font-family: var(--mono); font-size: 12px; font-weight: 700; padding: 5px 9px; border-radius: 8px; white-space: nowrap; }
.pill-hot { background: var(--hot-soft); color: var(--hot-text); }
.pill-ok { background: var(--accent-soft); color: var(--accent-ink); }
.pill-calm { background: #F1EEFF; color: var(--text-2); }
.pill-now { background: var(--accent); color: var(--on-accent); }
.empty { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 40px; border: 1px dashed var(--line-strong); border-radius: var(--radius); color: var(--muted); }

/* ---------- секции ---------- */
.band { background: var(--surface-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 64px 0; scroll-margin-top: 70px; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 22px; }
.section-head h2 { margin-bottom: 6px; }
.sources { padding-top: 64px; padding-bottom: 32px; scroll-margin-top: 70px; }
.tile { display: flex; flex-direction: column; gap: 10px; padding: 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); color: var(--text); }
a.tile:hover { border-color: var(--accent); color: var(--text); box-shadow: 0 10px 28px rgba(91, 61, 245, 0.10); }
.tile strong { font-size: 19px; font-weight: 800; }
.tile-ad { border-style: dashed; border-color: #B9AEF0; }
.tile-ad-head { display: flex; justify-content: space-between; align-items: center; }
.tile-row { flex-direction: row; justify-content: space-between; align-items: center; margin-top: 14px; }
.tile-row > div { display: flex; flex-direction: column; gap: 4px; }
.badge { font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: #F1EEFF; color: var(--text-2); }
.bot { padding: 32px; border-radius: 30px; background: var(--hot-soft); color: var(--text); margin: 32px 0 72px; scroll-margin-top: 80px; }
.bot h2 { margin: 6px 0 10px; }
.bot p { max-width: 720px; font-size: 17px; }

/* ---------- страница олимпиады ---------- */
.crumbs { display: flex; gap: 8px; padding-top: 26px; font-size: 14px; color: var(--muted); flex-wrap: wrap; }
.o-hero { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 40px; padding-top: 22px; padding-bottom: 40px; }
.o-hero-main { display: flex; flex-direction: column; justify-content: flex-end; gap: 18px; }
.o-title { font-size: clamp(48px, 7vw, 84px); font-weight: 900; line-height: 0.95; letter-spacing: -0.045em; }
.o-sub { font-size: 21px; color: var(--text-2); }
.o-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.fav-big[aria-pressed="true"] { background: var(--hot-soft); border-color: #FFC9B5; }
.o-body { display: grid; grid-template-columns: minmax(0, 1fr) 420px; gap: 40px; padding-bottom: 72px; }
.o-main { display: flex; flex-direction: column; gap: 44px; min-width: 0; }
.block { display: flex; flex-direction: column; gap: 16px; }
.block h2 { font-size: 30px; }
.text { font-size: 17px; color: var(--text-2); max-width: 780px; }
.timeline { list-style: none; margin: 0; padding: 6px 26px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); }
.tl-item { display: grid; grid-template-columns: 14px 170px minmax(0, 1fr) auto; align-items: center; gap: 20px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.tl-item:last-child { border-bottom: 0; }
.tl-dot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--line-strong); background: var(--surface); }
.tl-date { font-size: 15px; font-weight: 700; }
.tl-text { display: flex; flex-direction: column; gap: 3px; }
.tl-text strong { font-size: 17px; }
.tl-item.is-done .tl-dot { background: #D9D4F2; border-color: #D9D4F2; }
.tl-item.is-done .tl-date, .tl-item.is-done strong { color: #6E6A9E; }
.tl-item.is-now .tl-dot { background: var(--accent); border-color: var(--accent); }
.tl-item.is-next .tl-dot { border-color: var(--hot); }
.note { display: flex; flex-direction: column; gap: 6px; padding: 20px 22px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); }
.warn { display: flex; gap: 14px; align-items: flex-start; max-width: 780px; padding: 18px 20px; border-radius: 16px; background: #FFF1EB; border: 1px solid #FFC9B5; color: #6B2412; }
.warn svg { flex-shrink: 0; color: var(--hot-text); margin-top: 1px; }
.o-side { display: flex; flex-direction: column; gap: 16px; }
.facts { margin: 0; padding: 6px 24px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); }
.facts > div { padding: 14px 0; border-bottom: 1px solid var(--line); }
.facts > div:last-child { border-bottom: 0; }
.facts dt { font-family: var(--mono); font-size: 11px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 4px 0 0; font-size: 16px; font-weight: 600; }
.checked strong { display: flex; align-items: center; gap: 8px; }
.checked svg { color: var(--accent); }
.checked .btn { align-self: flex-start; }
.similar { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.similar li { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; }
.similar a { color: var(--text); }
.similar a:hover { color: var(--accent-ink); }

/* ---------- подвал и нижнее меню ---------- */
.foot { display: flex; justify-content: space-between; gap: 40px; padding: 40px max(24px, calc((100vw - var(--wrap)) / 2)); border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.foot-text { max-width: 560px; display: flex; flex-direction: column; gap: 6px; }
.foot-text strong { color: var(--text); font-size: 16px; }
.foot-links { display: flex; gap: 28px; flex-wrap: wrap; }
.foot-links a { color: var(--text-2); }
.tabbar { display: none; }

/* ---------- планшет ---------- */
@media (max-width: 1100px) {
  .hero, .o-hero, .o-body { grid-template-columns: minmax(0, 1fr); }
  .catalog { grid-template-columns: minmax(0, 1fr); }
  .filters { display: none; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .menu { display: none; }
}

/* ---------- телефон ---------- */
@media (max-width: 640px) {
  body { padding-bottom: 76px; }
  .wrap { padding: 0 16px; }
  .top { padding: 12px 16px; }
  .logo { font-size: 17px; }
  .hide-sm { display: none; }
  .top-actions .btn { min-height: 40px; padding: 0 12px; font-size: 14px; }
  .hero { padding-top: 24px; gap: 24px; }
  .hero-side { order: -1; }
  .lead { font-size: 16px; }
  .search .btn { display: none; }
  .search-box { height: 52px; }
  .selects { flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 0 16px 4px; }
  .selects .select { flex-shrink: 0; }
  .countdown { padding: 18px; border-radius: 20px; }
  .countdown-num b { font-size: 64px; }
  .countdown-num span { font-size: 20px; }
  .countdown-foot .btn { display: none; }
  .hero-side .panel { display: none; }
  h2, .results-head h2 { font-size: 26px; }
  .grid, .grid-3 { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .card { padding: 16px; gap: 10px; }
  .card-title { font-size: 18px; }
  .o-actions .btn { flex: 1 1 100%; }
  .tl-item { grid-template-columns: 14px minmax(0, 1fr) auto; gap: 12px; }
  .tl-date { grid-column: 2; grid-row: 1; font-size: 13px; }
  .tl-text { grid-column: 2; grid-row: 2; }
  .tl-item .pill { grid-column: 3; grid-row: 1 / span 2; }
  .tl-dot { grid-row: 1 / span 2; }
  .timeline, .facts { padding: 4px 16px; }
  .foot { flex-direction: column; padding: 32px 16px; }
  .tabbar {
    display: grid; grid-template-columns: repeat(4, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
    background: var(--surface-2); border-top: 1px solid var(--line); padding: 6px 6px calc(10px + env(safe-area-inset-bottom));
  }
  .tabbar a { display: flex; align-items: center; justify-content: center; min-height: 52px; color: var(--muted); font-size: 12px; font-weight: 600; }
}

/* правки после проверки в браузере */
.logo { white-space: nowrap; }
.tile { overflow-wrap: anywhere; }
.similar .mono { white-space: nowrap; }
@media (max-width: 640px) {
  .logo-dot { width: 12px; height: 12px; }
  .hero h1 { font-size: 40px; }
}
.badge { white-space: nowrap; }

/* подсказки поиска */
.search { position: relative; }
.suggest {
  position: absolute; left: 0; right: 0; top: calc(100% + 8px); z-index: 15;
  background: var(--surface); border: 1px solid var(--line-strong); border-radius: 16px;
  box-shadow: 0 18px 40px rgba(30, 27, 75, 0.16); overflow: hidden;
}
.suggest-list { list-style: none; margin: 0; padding: 6px; }
.suggest-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: 10px; color: var(--text); }
.suggest-item:hover, .suggest-item:focus-visible { background: var(--accent-soft); color: var(--text); }
.suggest-text { display: flex; flex-direction: column; min-width: 0; }
.suggest-text b { font-size: 15px; }
.suggest-text span { font-size: 13px; color: var(--muted); }
.suggest-empty { padding: 14px 12px; color: var(--muted); font-size: 14px; }
.suggest-all { display: block; width: 100%; min-height: 46px; border: 0; border-top: 1px solid var(--line); background: var(--surface-2); color: var(--accent-ink); font-weight: 700; font-size: 14px; cursor: pointer; }
.suggest-all:hover { background: var(--accent-soft); }
.active-q { display: inline-flex; align-items: center; gap: 8px; margin-top: 8px; padding: 4px 4px 4px 12px; border-radius: 10px; background: var(--accent-soft); color: var(--accent-ink); font-size: 14px; }
.active-q button { width: 32px; height: 32px; border: 0; border-radius: 8px; background: transparent; color: var(--accent-ink); cursor: pointer; }
.active-q button:hover { background: rgba(91, 61, 245, 0.12); }
input[type="search"]::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }
@media (max-width: 640px) { .suggest { max-height: 60vh; overflow-y: auto; } }

/* окно «Сообщить об ошибке» */
.linklike { border: 0; padding: 0; background: none; color: var(--accent-ink); font: inherit; cursor: pointer; }
.linklike:hover { color: var(--accent-hover); }
.modal { width: min(560px, calc(100vw - 32px)); padding: 0; border: 1px solid var(--line-strong); border-radius: 22px; background: var(--surface); color: var(--text); }
.modal::backdrop { background: rgba(30, 27, 75, 0.45); }
.modal-body { display: flex; flex-direction: column; gap: 16px; padding: 24px; }
.modal-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.modal-head h2 { font-size: 24px; }
.modal-x { width: 44px; height: 44px; border: 1px solid var(--line-strong); border-radius: 12px; background: transparent; color: var(--text); cursor: pointer; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; }
.field i { font-style: normal; font-weight: 400; color: var(--muted); }
.field select, .field textarea, .field input {
  width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line-strong);
  background: var(--surface-2); color: var(--text); font-size: 15px; font-weight: 400;
}
.field textarea { resize: vertical; min-height: 96px; }
.field select:focus, .field textarea:focus, .field input:focus { outline: none; border-color: var(--accent); }
.modal-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.modal-note { padding: 12px 14px; border-radius: 12px; background: var(--accent-soft); color: var(--accent-ink); font-size: 14px; }
.field textarea, .field input, .field select { font-family: inherit; }

/* логотип OlimPoint: салатовая точка над «i» */
.logo { font-weight: 900; font-size: 24px; letter-spacing: -0.04em; line-height: 1; color: var(--text); gap: 0; }
.i-dot { position: relative; display: inline-block; }
.i-dot::after {
  content: ""; position: absolute; left: 50%; top: -0.1em; transform: translateX(-50%);
  width: 0.3em; height: 0.3em; border-radius: 50%; background: var(--accent);
}
.logo-sm { font-size: 22px; }
.slogan { color: var(--text-2); font-weight: 600; }
@media (max-width: 640px) { .logo { font-size: 21px; } }
.suggest-parsed { padding: 8px 12px 6px; font-family: var(--mono); font-size: 12px; font-weight: 700; color: var(--accent-ink); }

/* ---------- текстовые страницы: о проекте, политика ---------- */
.doc { max-width: calc(820px + 48px); padding-top: 12px; padding-bottom: 72px; }
.doc h1 { font-size: 48px; font-weight: 900; line-height: 1.05; margin: 12px 0 18px; }
.doc h2 { font-size: 24px; font-weight: 800; margin: 40px 0 12px; }
.doc p, .doc li { font-size: 17px; line-height: 1.6; color: var(--text-2); margin: 0 0 12px; }
.doc b { color: var(--text); }
.doc ul { padding-left: 20px; margin: 0 0 12px; }
.doc li::marker { color: var(--accent); }
.doc a { color: var(--accent-ink); }
.doc .linklike { font-size: inherit; color: var(--accent-ink); }
.doc-lead { font-size: 20px !important; color: var(--text) !important; }
.doc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 28px 0 8px; }
.doc-tile { display: flex; flex-direction: column; gap: 4px; padding: 18px 20px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); }
.doc-tile b { font-family: var(--mono); font-size: 34px; color: var(--accent-ink); }
.doc-tile span { color: var(--muted); font-size: 14px; }
.doc-note { margin: 20px 0; padding: 16px 20px; border-radius: 16px; border: 1px solid #D6CCFF; background: var(--accent-soft); color: #2A1C8F; font-size: 16px; line-height: 1.55; }
@media (max-width: 640px) {
  .doc h1 { font-size: 28px; overflow-wrap: anywhere; }
  .doc h2 { font-size: 21px; margin-top: 32px; }
  .doc p, .doc li { font-size: 16px; }
  .doc-lead { font-size: 18px !important; }
  .doc-grid { grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
  .doc-tile { padding: 12px; }
  .doc-tile b { font-size: 24px; }
  .doc-tile span { font-size: 12px; }
}

/* ---------- «Лаванда»: форма и мелочи ---------- */
.btn { border-radius: 999px; }
.btn-lg { border-radius: 999px; }
.btn-ghost { background: var(--surface); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--accent); color: var(--text); }
.search-box { border-radius: 999px; border-color: var(--line); padding: 0 22px; }
.select select { border-radius: 999px; background-color: var(--surface); border-color: var(--line); }
.countdown { border-radius: 30px; box-shadow: 0 16px 36px rgba(91, 61, 245, 0.22); }
.countdown .eyebrow.dark { color: rgba(255, 255, 255, 0.85); }
.panel, .deadlines-wide, .timeline, .facts, .note { border-radius: 28px; }
.fbtn { border-radius: 999px; border-color: var(--line); padding: 8px 16px; }
.fbtn:hover { border-color: var(--accent); }
.card { box-shadow: 0 8px 24px rgba(91, 61, 245, 0.07); }
.card:hover { border-color: #C9BEFF; box-shadow: 0 12px 30px rgba(91, 61, 245, 0.13); }
.tag, .pill { border-radius: 999px; }
.pill-hot { background: var(--hot); color: var(--text); }
.fav { border-color: var(--line); }
.fav:hover { border-color: var(--hot); }
.tile { box-shadow: 0 8px 24px rgba(91, 61, 245, 0.06); }
.hero h1 { letter-spacing: -0.035em; }
.hero h1 .accent { color: var(--accent); }
.modal { border-radius: 28px; border-color: var(--line); box-shadow: 0 30px 80px rgba(30, 27, 75, 0.25); }
.modal-x { border-radius: 999px; }
.tabbar { background: #FFFFFF; }
.tabbar a:hover { color: var(--accent-ink); }
:focus-visible { outline-color: var(--accent); }

/* логотип «Лаванда»: знак-календарь + надпись */
.logo { gap: 10px; font-weight: 900; letter-spacing: -0.03em; }
.logo-mark { width: 34px; height: 34px; flex-shrink: 0; }
.logo-sm .logo-mark { width: 28px; height: 28px; }
@media (max-width: 640px) { .logo-mark { width: 28px; height: 28px; } }

/* меню: наведение и активный раздел */
.menu a { transition: background-color 0.15s ease, color 0.15s ease; }
.menu a:hover { background: var(--accent-soft); color: var(--accent-ink); }
.menu a.is-active, .menu a.is-active:hover { background: var(--accent); color: var(--on-accent); }
.tabbar a { border-radius: 14px; transition: background-color 0.15s ease, color 0.15s ease; }
.tabbar a.is-active { background: var(--accent-soft); color: var(--accent-ink); }
@media (prefers-reduced-motion: reduce) { .menu a, .tabbar a { transition: none; } }
#catalog, #calendar, #sources, #bot, #ads, #q { scroll-margin-top: 100px; }
@media (max-width: 640px) { #catalog, #calendar, #sources, #bot, #ads { scroll-margin-top: 76px; } }

/* защита от горизонтальной прокрутки на телефоне */
.selects { position: relative; }
html, body { overflow-x: clip; }

.fgroup-subj.is-collapsed .fbtn.is-extra:not([aria-pressed="true"]) { display: none; }
.fmore { margin-top: 2px; padding: 8px 14px; border: 1px dashed var(--line); border-radius: 999px; background: transparent; color: var(--accent-ink); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; text-align: left; }
.fmore:hover { border-color: var(--accent); }

.res th { font-size: 13px; font-weight: 700; color: var(--text); background: var(--bg); }
.res th small { font-weight: 500; color: var(--muted); font-size: 11px; }
.res td:first-child, .res th:first-child { text-align: left; font-weight: 700; }
.res tbody tr:last-child td { border-bottom: 0; }
.res td { font-family: var(--mono); font-weight: 600; }

.res-grades { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 16px; }
.res-chip { min-height: 44px; padding: 8px 18px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--text); font: inherit; font-weight: 700; cursor: pointer; font-variant-numeric: tabular-nums; }
.res-chip:hover { border-color: var(--accent); }
.res-chip[aria-selected="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.res-panel { display: grid; gap: 12px; margin-bottom: 12px; }
.res-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.res-tile { display: flex; flex-direction: column; gap: 6px; padding: 16px 18px; border-radius: 22px; background: var(--surface); border: 1px solid var(--line); min-width: 0; }
.res-tile span { font-size: 13px; font-weight: 600; color: var(--muted); }
.res-tile b { font-family: var(--mono); font-size: 28px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.res-win { border-color: var(--accent); }
.res-win b { color: var(--accent-ink); }
.res-pass { background: var(--accent); border-color: var(--accent); }
.res-pass span, .res-pass b { color: var(--on-accent); }

/* ---------- вход и регистрация ---------- */
.auth { width: min(460px, calc(100vw - 32px)); }
.auth .modal-body { gap: 14px; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border-radius: 999px; background: var(--accent-soft); }
.auth-tabs button { min-height: 40px; border: 0; border-radius: 999px; background: transparent; color: var(--text-2); font: inherit; font-weight: 700; cursor: pointer; }
.auth-tabs button[aria-selected="true"] { background: var(--surface); color: var(--text); box-shadow: 0 1px 4px rgba(30, 27, 75, 0.12); }
.auth-soon { font-size: 14px; color: var(--muted); }
.auth-providers { display: grid; gap: 10px; }
.auth-provider { width: 100%; min-height: 48px; }
.auth-or { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; }
.auth-or::before, .auth-or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.auth-form { display: flex; flex-direction: column; gap: 12px; }
.auth-form .btn { width: 100%; }
.auth-foot, .auth-switch { font-size: 14px; color: var(--muted); text-align: center; }
.auth[data-mode="login"] .only-signup, .auth[data-mode="signup"] .only-login { display: none; }
.menu a { white-space: nowrap; }
@media (max-width: 1200px) { .menu { display: none; } }
.auth { max-height: calc(100dvh - 32px); overflow-y: auto; }
@media (max-width: 640px) { .top-actions { gap: 8px; } }

/* =====================================================================
   Дизайн D (сентябрь 2026): светлый, Onest, неделя + «Мой сезон»
   ===================================================================== */
:root {
  --bg: #F6F5FB; --surface: #FFFFFF; --surface-2: #FBFAFE;
  --line: #ECE9F7; --line-strong: #E3DFF5;
  --text: #1B1840; --text-2: #4A4670; --muted: #6B6790;
  --accent: #5B3DF5; --accent-hover: #4A2DE0; --accent-ink: #4B2FE0; --accent-soft: #EFEBFF;
  --hot: #E0461A; --hot-text: #B8340E; --hot-soft: #FFF1EC;
  --radius: 24px;
  --mono: Onest, system-ui, sans-serif;
}
body { font-family: Onest, system-ui, -apple-system, sans-serif; font-feature-settings: "tnum" 1; }
h2 { font-weight: 800; letter-spacing: -0.025em; }
.eyebrow { font-family: inherit; letter-spacing: 0.06em; }
.btn, .btn-lg { border-radius: 12px; }
.btn-lg { min-height: 50px; }
.btn-ghost { background: var(--surface); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--accent); }
.btn-icon { width: 44px; padding: 0; background: var(--bg); color: var(--text); font-size: 20px; }
.btn-icon:hover { background: var(--accent-soft); color: var(--accent-ink); }
.btn-dark-solid { background: var(--text); color: #FFFFFF; }
.btn-dark-solid:hover { background: #2C2860; color: #FFFFFF; }

/* шапка */
.top { background: #FFFFFF; border-bottom-color: var(--line); padding-top: 14px; padding-bottom: 14px; }
.menu { background: transparent; border: 0; padding: 0; gap: 2px; }
.menu a { font-weight: 500; color: var(--text-2); }
.menu a.is-active, .menu a.is-active:hover { background: var(--accent-soft); color: #3A20C4; font-weight: 700; }
.logo { font-weight: 800; font-size: 22px; }

/* общие карточки */
.card, .tile, .panel, .timeline, .facts, .note, .deadlines-wide { border-radius: var(--radius); border-color: var(--line); box-shadow: none; }
.card:hover { box-shadow: 0 10px 28px rgba(27, 24, 64, 0.08); border-color: var(--line-strong); }
.tag, .pill { font-family: inherit; font-weight: 700; }
.pill-hot { background: var(--hot-soft); color: var(--hot-text); }
.pill-now { background: var(--hot); color: #FFFFFF; }
.pill-ok { background: var(--accent-soft); color: #3A20C4; }
.pill-calm { background: #F2F0FA; color: var(--text-2); }
.lv-I { background: var(--text); }

/* ---------- главная «Мой сезон» ---------- */
.home { display: flex; flex-direction: column; gap: 22px; padding-top: 26px; padding-bottom: 56px; }
.me-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.me-label { color: var(--muted); font-size: 15px; }
.me-chips { display: contents; }
.me-grade select, .me-chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border-radius: 999px;
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--text); font: inherit; font-size: 15px; font-weight: 600; cursor: pointer;
}
.me-grade select { appearance: none; padding-right: 34px; background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%231B1840' stroke-width='3'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 13px center; }
.me-chip-on { background: var(--accent-soft); border-color: #D9D0FF; color: #3A20C4; }
.me-chip-on:hover { border-color: var(--accent); }
.me-chip-muted { color: var(--muted); cursor: default; }
.me-bar { position: relative; }
.me-add { position: static; }
.me-add > summary { list-style: none; border-style: dashed; color: var(--muted); }
.me-add > summary::-webkit-details-marker { display: none; }
.me-add[open] > summary { border-color: var(--accent); color: var(--accent-ink); }
.me-pop {
  position: absolute; z-index: 25; top: calc(100% + 8px); left: 0; width: min(560px, 100%); box-sizing: border-box;
  display: flex; flex-wrap: wrap; gap: 6px; padding: 14px; border-radius: 20px; background: var(--surface);
  border: 1px solid var(--line-strong); box-shadow: 0 20px 50px rgba(27, 24, 64, 0.16);
}
.me-opt { min-height: 38px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font: inherit; font-size: 14px; font-weight: 600; color: var(--text); cursor: pointer; }
.me-opt i { font-style: normal; color: var(--muted); font-weight: 500; margin-left: 2px; }
.me-opt:hover { border-color: var(--accent); }
.me-opt[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #FFFFFF; }
.me-opt[aria-pressed="true"] i { color: #DCD4FF; }

.h-top { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 22px; }
.h-kicker { font-size: 13px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.h-hero {
  display: grid; grid-template-columns: minmax(0, 1fr) 180px; gap: 24px; align-items: center; padding: 34px 36px;
  border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); color: var(--text);
}
.h-hero:hover { color: var(--text); border-color: var(--line-strong); box-shadow: 0 12px 30px rgba(27, 24, 64, 0.08); }
.h-hero-text { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.h-hero .h-kicker { align-self: flex-start; padding: 5px 11px; border-radius: 999px; background: var(--hot-soft); color: var(--hot-text); letter-spacing: 0.04em; font-size: 12px; }
.h-hero-title { font-size: clamp(30px, 3.4vw, 44px); line-height: 1.06; letter-spacing: -0.035em; font-weight: 800; }
.h-hero-title em { font-style: normal; color: var(--hot); white-space: nowrap; }
.h-hero-sub { font-size: 17px; color: var(--text-2); }
.h-hero-actions { display: flex; }

.ring {
  --p: 0%; --ring: var(--accent);
  width: 180px; aspect-ratio: 1; border-radius: 50%;
  background: conic-gradient(var(--ring) 0 var(--p), #F2F0FA var(--p) 100%);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.ring-hot { --ring: var(--hot); }
.ring-in { width: 80%; aspect-ratio: 1; border-radius: 50%; background: var(--surface); display: flex; flex-direction: column; align-items: center; justify-content: center; }
.ring-in b { font-size: 56px; line-height: 1; letter-spacing: -0.04em; color: var(--ring); }
.ring-in span { font-size: 14px; font-weight: 700; color: var(--text-2); }

.h-season { display: flex; flex-direction: column; gap: 16px; padding: 26px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.h-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.h-stat { display: flex; flex-direction: column; padding: 14px 16px; border-radius: 18px; background: var(--bg); color: var(--text); }
a.h-stat:hover { color: var(--text); background: #EEECF7; }
.h-stat b { font-size: 34px; line-height: 1.1; letter-spacing: -0.03em; }
.h-stat span { font-size: 14px; color: var(--muted); }
.h-stat-accent { background: var(--accent-soft); }
.h-stat-accent b { color: var(--accent); }
.h-path { display: flex; flex-direction: column; gap: 8px; }
.h-path-title { font-size: 14px; color: var(--muted); }
.h-path-bar, .h-path-labels { display: grid; gap: 6px; }
.seg { height: 8px; border-radius: 999px; background: var(--line-strong); }
.seg-done { background: #B7A6FF; }
.seg-now { background: var(--accent); }
.h-path-labels { font-size: 12px; color: var(--muted); }
.h-path-labels span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.h-path-labels .is-now { color: var(--text); font-weight: 700; }
.h-season .btn { margin-top: auto; }

.h2s { font-size: 20px; letter-spacing: -0.015em; font-weight: 800; }
.week { display: flex; flex-direction: column; gap: 14px; padding: 22px 24px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.week-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.week-nav { display: flex; align-items: center; gap: 8px; }
.week-nav .btn-icon { width: 40px; min-height: 40px; }
.week-all { font-weight: 600; font-size: 15px; margin-left: 6px; }
.week-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; align-items: start; }
.dh { display: flex; align-items: baseline; gap: 6px; padding: 10px 12px; border-radius: 14px; font-size: 13px; color: var(--muted); }
.dh b { font-size: 20px; color: var(--text); }
.dh.is-past { opacity: 0.5; }
.dh.is-today { background: var(--accent); color: #E6E0FF; }
.dh.is-today b { color: #FFFFFF; }
.dh-today { font-size: 12px; font-weight: 700; }
.ev { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding: 8px 10px; border-radius: 12px; font-size: 13px; line-height: 1.3; color: var(--text); background: #F2F0FA; }
.ev:hover { color: var(--text); box-shadow: inset 0 0 0 1px var(--accent); }
.ev b { font-weight: 700; overflow-wrap: anywhere; }
.ev small { font-size: 12px; color: var(--muted); }
.ev-range { background: var(--accent-soft); }
.ev-main { background: var(--accent); color: #FFFFFF; }
.ev-main:hover { color: #FFFFFF; }
.ev-main small { color: #DCD4FF; }
.ev-hot { background: var(--hot-soft); color: #8A260A; }
.ev-hot small { color: var(--hot-text); }
.ev-past { opacity: 0.5; }
.ev-more { padding: 6px 10px; font-size: 13px; font-weight: 700; }
.week-list { display: none; }

.h-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.h-col { display: flex; flex-direction: column; gap: 12px; padding: 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.h-col-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.h-more { font-size: 14px; font-weight: 600; }
.h-list { display: flex; flex-direction: column; gap: 10px; }
.h-item { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px; border-radius: 18px; background: var(--bg); color: var(--text); }
.h-item:hover { color: var(--text); box-shadow: inset 0 0 0 1px var(--accent); }
.h-item .pill { align-self: flex-start; }
.h-item b { font-size: 16px; line-height: 1.3; }
.h-item .m { font-size: 14px; color: var(--muted); }
.h-item-hot { background: var(--hot-soft); }
.h-item-hot .pill-hot { background: #FFFFFF; }
.h-item-dark { background: var(--text); color: #FFFFFF; }
.h-item-dark:hover { color: #FFFFFF; }
.h-goal-big { display: flex; align-items: baseline; gap: 10px; }
.h-goal-big b { font-size: 44px; line-height: 1; letter-spacing: -0.03em; color: var(--accent); }
.h-none { font-size: 14px; padding: 6px 0; }
.home .bot { margin: 10px 0 0; border-radius: var(--radius); background: var(--text); color: #FFFFFF; }
.home .bot .eyebrow.dark { color: #C9C3F0; }

/* ---------- каталог и календарь ---------- */
.hero-cat { grid-template-columns: minmax(0, 1fr); padding-top: 36px; padding-bottom: 24px; }
.hero-cat h1 { font-size: clamp(36px, 4.4vw, 56px); font-weight: 800; }
.band-page { background: transparent; border: 0; padding: 36px 0 64px; }
.page-h1 { font-size: clamp(32px, 4vw, 48px); font-weight: 800; letter-spacing: -0.035em; margin-bottom: 6px; }

/* ---------- страница олимпиады ---------- */
.o-hero {
  display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 32px; align-items: center;
  margin: 18px 0 32px; padding: 36px 40px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line);
}
.o-title { font-size: clamp(40px, 5.2vw, 64px); font-weight: 800; letter-spacing: -0.04em; line-height: 1; }
.o-sub { font-size: 18px; }
.o-next { display: flex; flex-direction: column; align-items: center; gap: 14px; text-align: center; }
.o-next .ring { width: 220px; }
.o-next .ring-in b { font-size: 72px; }
.o-next-text { display: flex; flex-direction: column; gap: 4px; }
.o-next-text strong { font-size: 17px; line-height: 1.3; }
.o-next-text > span:last-child { color: var(--muted); font-size: 14px; }
.o-next.is-empty { justify-content: center; padding: 24px; border-radius: 20px; background: var(--bg); }

.timeline { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; padding: 0; background: transparent; border: 0; }
.tl-item {
  display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 18px; border-radius: 20px;
  background: var(--surface); border: 1px solid var(--line);
}
.tl-dot { display: none; }
.tl-date { font-size: 13px; color: var(--muted); font-weight: 600; order: 1; }
.tl-text { order: 2; }
.tl-text strong { font-size: 16px; line-height: 1.3; }
.tl-item .pill { order: 3; }
.tl-item.is-done { opacity: 0.55; }
.tl-item.is-now { background: var(--hot-soft); border-color: #FFB9A3; }
.tl-item.is-now .tl-date { color: var(--hot-text); }
.tl-item.is-next { border-color: var(--accent); }
.tl-item:last-child:not(.tl-tbd):not(.is-done):not(.is-now) { background: var(--text); border-color: var(--text); color: #FFFFFF; }
.tl-item:last-child:not(.tl-tbd):not(.is-done):not(.is-now) .tl-date { color: #C9C3F0; }
.tl-item:last-child:not(.tl-tbd):not(.is-done):not(.is-now) strong { color: #FFFFFF; }
.tl-tbd { border-style: dashed; }

.res-tile { border-radius: 20px; background: var(--bg); border: 0; padding: 20px 22px; }
.res-tile b { font-family: inherit; font-size: 40px; letter-spacing: -0.03em; }
.res-win { background: var(--accent); }
.res-win span { color: #DCD4FF; }
.res-win b { color: #FFFFFF; }
.res-chip[aria-selected="true"] { background: var(--text); border-color: var(--text); }

/* ---------- планшет ---------- */
@media (max-width: 1100px) {
  .h-top { grid-template-columns: minmax(0, 1fr); }
  .h-cols { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .h-cols .h-col:last-child { grid-column: 1 / -1; }
  .o-hero { grid-template-columns: minmax(0, 1fr); }
  .o-next { flex-direction: row; text-align: left; justify-content: flex-start; }
  .o-next .ring { width: 150px; }
  .o-next .ring-in b { font-size: 48px; }
}
@media (max-width: 900px) {
  .week-grid { display: none; }
  .week-list { display: flex; flex-direction: column; gap: 8px; }
}
/* ---------- телефон ---------- */
@media (max-width: 640px) {
  .home { gap: 16px; padding-top: 16px; }
  .me-label { width: 100%; font-size: 14px; }
  .h-hero { grid-template-columns: minmax(0, 1fr) 96px; gap: 14px; padding: 20px; }
  .h-hero .ring { width: 96px; }
  .h-hero .ring-in b { font-size: 30px; }
  .h-hero .ring-in span { font-size: 11px; }
  .h-hero-title { font-size: 22px; letter-spacing: -0.02em; }
  .h-hero-sub { font-size: 14px; }
  .h-hero-actions { grid-column: 1 / -1; }
  .h-hero-actions .btn { width: 100%; }
  .h-hero-text { display: contents; }
  .h-hero .h-kicker, .h-hero-title, .h-hero-sub { grid-column: 1; }
  .h-hero .ring { grid-column: 2; grid-row: 1 / span 3; }
  .h-season { padding: 18px; }
  .week { padding: 14px; }
  .week-head .h2s { font-size: 17px; }
  .week-all { display: none; }
  .h-cols { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .h-col { padding: 16px; }
  .o-hero { padding: 22px; margin-top: 10px; gap: 20px; }
  .o-next .ring { width: 104px; }
  .o-next .ring-in b { font-size: 34px; }
  .o-next .ring-in span { font-size: 11px; }
  .timeline { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
  .tl-item { padding: 14px; }
  .tl-item { grid-template-columns: none; }
  .res-tile b { font-size: 30px; }
  .tabbar a { flex-direction: column; gap: 3px; font-size: 11px; }
}
.wl-strip { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.wl-day { display: flex; flex-direction: column; align-items: center; gap: 3px; min-height: 64px; padding: 6px 0; border: 0; border-radius: 12px; background: transparent; color: var(--muted); font: inherit; font-size: 12px; cursor: pointer; }
.wl-day b { font-size: 17px; color: var(--text); }
.wl-day.is-past { opacity: 0.55; }
.wl-day.is-today b { color: var(--accent); }
.wl-day.is-picked { background: var(--accent); color: #E6E0FF; opacity: 1; }
.wl-day.is-picked b { color: #FFFFFF; }
.wl-dot { width: 6px; height: 6px; border-radius: 50%; }
.wl-dot.is-on { background: var(--accent); }
.wl-dot.is-hot { background: var(--hot); }
.wl-day.is-picked .wl-dot.is-on, .wl-day.is-picked .wl-dot.is-hot { background: #FFFFFF; }
.wl-title { font-size: 13px; font-weight: 700; color: var(--muted); padding: 8px 2px 0; }
.wl-none { font-size: 14px; }
.week-list .ev { font-size: 14px; padding: 10px 12px; }
.timeline { grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); }
.res-tile { background: var(--surface); border: 1px solid var(--line); }
.res-win { background: var(--accent); border-color: var(--accent); }
@media (max-width: 640px) { .timeline { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.h-hero-title em.is-calm { color: var(--accent); }
.btn-soft { min-height: 40px; padding: 0 14px; background: var(--bg); color: var(--text); font-size: 14px; }
.btn-soft:hover { background: var(--accent-soft); color: var(--accent-ink); }

/* меню видно на любой ширине: на узком экране - второй строкой шапки */
@media (max-width: 1200px) {
  .menu { display: flex; }
}
@media (max-width: 1060px) {
  .top { flex-wrap: wrap; row-gap: 10px; }
  .menu { order: 3; width: 100%; overflow-x: auto; scrollbar-width: none; margin: 0 -4px; }
  .menu::-webkit-scrollbar { display: none; }
}
@media (max-width: 640px) {
  .menu { display: none; }
}
.week-note { margin-left: 6px; padding: 3px 10px; border-radius: 999px; background: var(--accent-soft); color: #3A20C4; font-size: 12px; font-weight: 700; vertical-align: middle; white-space: nowrap; }
.week-nofav { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 22px; border-radius: 18px; border: 1px dashed var(--line-strong); background: var(--bg); }
.week-nofav b { font-size: 17px; }
/* календарь: фильтры */
.cal-page { display: flex; flex-direction: column; gap: 18px; padding-top: 32px; padding-bottom: 64px; }
.cal-head { display: flex; flex-direction: column; gap: 4px; }
.cal-filters { display: flex; flex-direction: column; gap: 12px; padding: 18px 20px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.cal-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.seg-group { display: inline-flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--bg); flex-wrap: wrap; }
.seg-btn { min-height: 38px; padding: 0 14px; border: 0; border-radius: 999px; background: transparent; color: var(--text-2); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.seg-btn:hover { color: var(--text); }
.seg-btn[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: 0 1px 4px rgba(27, 24, 64, 0.12); }
.cal-fav[aria-pressed="true"] { background: var(--hot-soft); border-color: #FFB9A3; color: var(--hot-text); }
.cal-fav[aria-pressed="true"] .heart { fill: var(--hot); stroke: var(--hot); }
.me-bar.is-off { opacity: 0.45; pointer-events: none; }
.cal-month { display: block !important; padding: 18px 0 6px !important; border-bottom: 0 !important; font-size: 13px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.cal-month:first-child { padding-top: 10px !important; }
@media (max-width: 640px) {
  .cal-page { padding-top: 18px; }
  .cal-filters { padding: 14px; }
  .seg-group { width: 100%; }
  .seg-btn { flex: 1 1 auto; padding: 0 10px; }
}
@media (max-width: 640px) { .seg-group { border-radius: 18px; } }
.reg-status { align-self: flex-start; padding: 8px 14px; border-radius: 12px; font-size: 15px; font-weight: 700; }
.reg-open { background: var(--accent-soft); color: #3A20C4; }
.reg-soon { background: #F2F0FA; color: var(--text-2); }
.reg-closed { background: var(--hot-soft); color: var(--hot-text); border: 1px solid #FFB9A3; font-weight: 600; }
.dl-text .dl-closed { color: var(--hot-text); font-weight: 700; font-size: 12px; }
/* ---------- новости ---------- */
.news-page { display: flex; flex-direction: column; gap: 18px; padding-top: 32px; padding-bottom: 64px; max-width: calc(880px + 48px); }
.news-list { display: flex; flex-direction: column; gap: 14px; }
.news-item { display: flex; flex-direction: column; gap: 10px; padding: 22px 24px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); scroll-margin-top: 100px; }
.news-item:target { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.news-meta { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); }
.news-tag { padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; background: #F2F0FA; color: var(--text-2); }
.news-tag-reg { background: var(--accent-soft); color: #3A20C4; }
.news-tag-sch { background: var(--hot-soft); color: var(--hot-text); }
.news-tag-list { background: var(--text); color: #FFFFFF; }
.news-tag-win { background: #E3F6EA; color: #1B7A43; }
.news-item h3 { font-size: 20px; line-height: 1.25; letter-spacing: -0.015em; }
.news-item p { color: var(--text-2); font-size: 16px; line-height: 1.55; }
.news-links { display: flex; flex-wrap: wrap; gap: 8px 14px; font-size: 14px; font-weight: 600; }
.news-src { color: var(--muted); }
.news-filter { align-self: flex-start; }
.news-auto { display: flex; flex-direction: column; gap: 12px; padding: 20px 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.news-auto-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.news-auto-item { display: flex; flex-direction: column; gap: 6px; padding: 14px; border-radius: 16px; background: var(--bg); color: var(--text); }
.news-auto-item:hover { color: var(--text); box-shadow: inset 0 0 0 1px var(--accent); }
.news-auto-item .pill { align-self: flex-start; }
.news-auto-item b { font-size: 15px; line-height: 1.3; }
.h-news { display: flex; flex-direction: column; gap: 12px; }
.news-list-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.news-list-3 .news-item p { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.o-news a { display: flex; flex-direction: column; gap: 2px; padding: 8px 0; border-top: 1px solid var(--line); color: var(--text); font-weight: 600; font-size: 14px; }
.o-news a:hover { color: var(--accent-ink); }
@media (max-width: 1100px) { .news-list-3 { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 640px) { .news-item { padding: 16px; } .news-item h3 { font-size: 18px; } .news-filter { align-self: stretch; } }

/* ===== Страница «Баллы» ===== */
.sc-page { display: flex; flex-direction: column; gap: 18px; padding-top: 28px; padding-bottom: 48px; }
.sc-hero { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap;
  padding: 28px 30px; border-radius: var(--radius); background: #1B1840; color: #FFFFFF; }
.sc-hero .page-h1 { color: #FFFFFF; margin: 0; }
.sc-lead { margin: 8px 0 0; max-width: 520px; color: #C9C4EE; font-size: 16px; line-height: 1.5; }
.sc-grade { display: flex; flex-direction: column; gap: 8px; }
.sc-grade-label { font-size: 13px; font-weight: 600; color: #C9C4EE; }
.sc-grade-btns { display: flex; gap: 6px; flex-wrap: wrap; }
.sc-g { width: 46px; height: 46px; border-radius: 14px; border: 1px solid rgba(255,255,255,.18); background: rgba(255,255,255,.06);
  color: #FFFFFF; font: inherit; font-size: 17px; font-weight: 700; cursor: pointer; }
.sc-g:hover { background: rgba(255,255,255,.14); }
.sc-g[aria-pressed="true"] { background: #FFFFFF; color: #1B1840; border-color: #FFFFFF; }
.sc-tools { display: flex; flex-direction: column; gap: 12px; }
.sc-subj { display: flex; gap: 8px; flex-wrap: wrap; }
@media (max-width: 760px) { .sc-subj { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; } }
.sc-chip { flex-shrink: 0; min-height: 40px; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface);
  color: var(--text); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.sc-chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #FFFFFF; }
.sc-search input { width: 100%; max-width: 420px; min-height: 44px; padding: 10px 16px; border-radius: 14px; border: 1px solid var(--line-strong);
  background: var(--surface); color: var(--text); font: inherit; font-size: 15px; }
.sc-count { margin: 0; font-weight: 700; color: var(--text); }
.sc-list { display: flex; flex-direction: column; gap: 10px; }
.sc-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 18px; padding: 16px 20px;
  border-radius: 22px; background: var(--surface); border: 1px solid var(--line); }
.sc-row:hover { border-color: var(--line-strong); }
.sc-name { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; min-width: 0; }
.sc-name > a { color: var(--text); text-decoration: none; font-size: 16px; line-height: 1.3; }
.sc-name > a:hover { color: var(--accent); }
.sc-src { color: inherit; }
.sc-nums { display: flex; gap: 8px; }
.sc-num { display: flex; flex-direction: column; gap: 2px; min-width: 104px; padding: 10px 14px; border-radius: 16px; background: var(--bg); }
.sc-num span { font-size: 12px; font-weight: 600; color: var(--muted); }
.sc-num b { font-size: 20px; line-height: 1.1; color: var(--text); font-variant-numeric: tabular-nums; }
.sc-win { background: #EEEAFF; }
.sc-win b { color: #3A20C4; }
.sc-pass { background: #E3F6EA; }
.sc-pass b { color: #1B7A43; }
.sc-foot { max-width: 760px; line-height: 1.5; }
@media (max-width: 760px) {
  .sc-hero { padding: 22px 18px; }
  .sc-row { grid-template-columns: 1fr; gap: 12px; padding: 14px 16px; }
  .sc-nums { flex-wrap: wrap; }
  .sc-num { flex: 1 1 90px; min-width: 0; }
  .sc-g { width: 40px; height: 40px; font-size: 16px; }
}

/* ===== Анимации: мягко и быстро. Кто отключил анимацию в системе - не видит их вовсе ===== */
@property --p { syntax: '<percentage>'; inherits: true; initial-value: 0%; }
@keyframes olp-up { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes olp-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes olp-pop { 0% { transform: scale(1); } 40% { transform: scale(1.3); } 100% { transform: scale(1); } }
@keyframes olp-modal { from { opacity: 0; transform: translateY(14px) scale(.97); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: no-preference) {
  :root { --ease: cubic-bezier(.2, .7, .2, 1); }
  /* элементы списков: появляются при загрузке и заново - когда фильтр их показывает */
  .card, .sc-row, .news-item, .h-item, .deadlines li, .cal-list li, .wl-day { animation: olp-up .38s var(--ease) both; }
  .card:nth-child(2), .sc-row:nth-child(2), .news-item:nth-child(2), .h-item:nth-child(2) { animation-delay: .03s; }
  .card:nth-child(3), .sc-row:nth-child(3), .news-item:nth-child(3), .h-item:nth-child(3) { animation-delay: .06s; }
  .card:nth-child(4), .sc-row:nth-child(4), .news-item:nth-child(4), .h-item:nth-child(4) { animation-delay: .09s; }
  .card:nth-child(5), .sc-row:nth-child(5), .news-item:nth-child(5) { animation-delay: .12s; }
  .card:nth-child(n+6), .sc-row:nth-child(n+6), .news-item:nth-child(n+6) { animation-delay: .15s; }
  /* наведение: карточки чуть приподнимаются */
  .card, .sc-row, .news-item, .h-item, .h-hero, .h-stat, .panel {
    transition: transform .22s var(--ease), box-shadow .22s var(--ease), border-color .2s ease, background-color .2s ease;
  }
  @media (hover: hover) {
    .card:hover, .sc-row:hover, .news-item:hover, .h-item:hover, .h-stat:hover { transform: translateY(-3px); box-shadow: 0 14px 34px rgba(30, 27, 75, .10); }
    .h-hero:hover { transform: translateY(-2px); box-shadow: 0 18px 44px rgba(30, 27, 75, .14); }
  }
  /* кнопки, чипы, переключатели */
  .btn, .seg-btn, .sc-chip, .sc-g, .me-chip, .me-opt, .fbtn, .fav, .auth-tabs button, a {
    transition: background-color .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease, transform .15s var(--ease), opacity .18s ease;
  }
  .btn:active, .seg-btn:active, .sc-chip:active, .sc-g:active, .me-chip:active, .me-opt:active, .fbtn:active, .fav:active { transform: scale(.96); }
  /* сердечко «в избранное» подпрыгивает */
  .fav[aria-pressed="true"] svg, .cal-fav[aria-pressed="true"] svg { animation: olp-pop .35s var(--ease); }
  .heart { transition: fill .2s ease, stroke .2s ease; }
  /* кольцо дедлайна заполняется */
  .ring { transition: --p .9s var(--ease); }
  .ring-in b { animation: olp-fade .5s ease .15s both; }
  /* окна входа и «сообщить об ошибке» */
  .modal[open] { animation: olp-modal .28s var(--ease); }
  .modal[open]::backdrop { animation: olp-fade .25s ease; }
  /* выпадающий список предметов */
  .me-add[open] .me-pop { animation: olp-up .2s var(--ease); }
}

/* поиск: подсказки поверх страницы, без затемнения - страница остаётся светлой и читаемой */
.search { z-index: 30; }
.suggest { z-index: 31; box-shadow: 0 2px 6px rgba(28, 27, 34, .06), 0 16px 36px rgba(28, 27, 34, .14); }
.suggest-list { max-height: min(60vh, 440px); overflow-y: auto; overscroll-behavior: contain; }
@media (prefers-reduced-motion: no-preference) { .suggest:not([hidden]) { animation: olp-up .2s var(--ease); } }
/* анимации карточек - только при открытии страницы; при поиске и фильтрах всё меняется сразу, без мигания */
.anim-done .card, .anim-done .sc-row, .anim-done .news-item, .anim-done .h-item, .anim-done .deadlines li, .anim-done .cal-list li, .anim-done .wl-day { animation: none; }

/* ===== Избранное ===== */
.fav-top { position: relative; }
.fav-top .heart { stroke: currentColor; }
.has-favs .fav-top .heart { fill: var(--hot); stroke: var(--hot); }
.fav-top.is-active { background: var(--accent-soft); }
.fav-badge { position: absolute; top: -5px; right: -5px; min-width: 19px; height: 19px; padding: 0 5px; border-radius: 999px;
  background: var(--hot); color: #FFFFFF; font-size: 11px; font-weight: 800; line-height: 19px; text-align: center; display: none; }
.has-favs .fav-badge { display: block; }
.fv-page { display: flex; flex-direction: column; gap: 18px; padding-top: 28px; padding-bottom: 48px; }
.fv-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; }
.fv-head .page-h1 { margin: 0 0 6px; }
.fv-head p { margin: 0; }
.fv-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.fv-list { display: flex; flex-direction: column; gap: 10px; }
.fv-row { display: grid; grid-template-columns: minmax(0, 1fr) 200px auto; align-items: center; gap: 18px; padding: 16px 18px 16px 20px;
  border-radius: 22px; background: var(--surface); border: 1px solid var(--line); }
.fv-main { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; min-width: 0; color: var(--text); text-decoration: none; }
.fv-main:hover .fv-name { color: var(--accent); }
.fv-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 4px; }
.fv-name { font-size: 17px; line-height: 1.3; }
.fv-reg { font-size: 13px; font-weight: 700; margin-top: 2px; }
.fv-reg-open { color: #1B7A43; }
.fv-reg-soon { color: var(--accent); }
.fv-reg-closed { color: var(--hot); }
.fv-when { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.fv-date { font-size: 20px; line-height: 1.1; }
.fv-empty svg .heart { stroke: var(--line-strong); }
.fv-note { margin: 0; }
@media (max-width: 760px) {
  .fv-row { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "main rm" "when when"; gap: 12px; padding: 14px 14px 14px 16px; }
  .fv-main { grid-area: main; }
  .fv-rm { grid-area: rm; align-self: start; }
  .fv-when { grid-area: when; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px; padding-top: 12px; border-top: 1px solid var(--line); }
  .fv-date { font-size: 16px; }
}
@media (prefers-reduced-motion: no-preference) { .fv-row { animation: olp-up .32s var(--ease) both; } .anim-done .fv-row { animation: none; } }

/* точное время этапа */
.tl-time { display: block; margin-top: 4px; font-size: 13px; font-weight: 600; color: var(--accent); line-height: 1.4; }

/* Вход через Telegram */
.auth-lead { font-size: 15px; line-height: 1.5; color: var(--text-2); }
.auth-lead b { color: var(--text); }
.auth-tg, .auth [data-tg-logout], .auth a.btn { width: 100%; justify-content: center; }
.auth-steps { margin: 0; padding-left: 20px; display: grid; gap: 8px; font-size: 15px; line-height: 1.45; color: var(--text-2); }
.auth .small { font-size: 13px; }
.auth-foot a { color: inherit; text-decoration: underline; }
.tg-ico { flex-shrink: 0; }
.top-actions .btn[data-auth-btn] { gap: 8px; max-width: 170px; }
.top-actions .btn[data-auth-btn] span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-actions .btn[data-auth-btn].is-in { background: var(--accent-soft); color: var(--accent-ink); border-color: transparent; }
.auth [data-auth-view]:not([hidden]) { display: flex; flex-direction: column; gap: 14px; }
.auth .linklike { align-self: center; }

/* =====================================================================
   v10: иконки предметов, красный бейдж, тёмная тема, анимации
   ===================================================================== */

/* ---------- иконки предметов ---------- */
.sico { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.sico-s { width: 16px; height: 16px; margin-right: 6px; vertical-align: -3px; opacity: .8; }
.sico-t { --h: 250; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 14px; flex-shrink: 0;
  background: hsl(var(--h) 80% 94%); color: hsl(var(--h) 55% 36%); }
.sico-lg { width: 40px; height: 40px; border-radius: 12px; }
.card-head .tags { flex: 1; min-width: 0; margin-left: 2px; }
.sico-t[data-s="econ"]{--h:150}
.sico-t[data-s="fin"]{--h:45}
.sico-t[data-s="biz"]{--h:28}
.sico-t[data-s="sec"]{--h:200}
.sico-t[data-s="soc"]{--h:330}
.sico-t[data-s="law"]{--h:260}
.sico-t[data-s="math"]{--h:235}
.sico-t[data-s="phy"]{--h:215}
.sico-t[data-s="inf"]{--h:180}
.sico-t[data-s="bio"]{--h:130}
.sico-t[data-s="chem"]{--h:285}
.sico-t[data-s="hist"]{--h:30}
.sico-t[data-s="rus"]{--h:350}
.sico-t[data-s="lit"]{--h:10}
.sico-t[data-s="eng"]{--h:205}
.sico-t[data-s="ger"]{--h:50}
.sico-t[data-s="fra"]{--h:225}
.sico-t[data-s="spa"]{--h:15}
.sico-t[data-s="chi"]{--h:0}
.sico-t[data-s="ita"]{--h:140}
.sico-t[data-s="geo"]{--h:165}
.sico-t[data-s="astr"]{--h:250}
.sico-t[data-s="ecol"]{--h:110}
.sico-t[data-s="art"]{--h:320}
.sico-t[data-s="tech"]{--h:190}
.sico-t[data-s="jour"]{--h:20}
.sico-t[data-s="psy"]{--h:295}
.sico-t[data-s="obzr"]{--h:355}
.sico-t[data-s="pe"]{--h:35}
.sico-t[data-s="other"]{--h:250}

/* ---------- красный бейдж «не вошла в Перечень» ---------- */
.tag-out { background: #FFE1E1; color: #A4161A; box-shadow: inset 0 0 0 1px #F4A9AB; }
.card-out { border-color: #F4B6B8; }
.card-out .card-title { color: var(--text-2); }
.o-facts dd.is-out, dl dd.is-out { color: #A4161A; font-weight: 700; }

/* ---------- шкала до дедлайна ---------- */
.card-foot { position: relative; flex-wrap: wrap; }
.dl { flex-basis: 100%; height: 4px; border-radius: 4px; background: var(--line); overflow: hidden; display: none; }
.dl.is-on { display: block; }
.dl i { display: block; height: 100%; width: calc(var(--w, 0) * 100%); border-radius: 4px; background: #2FA36B; transition: width .7s cubic-bezier(.2,.8,.2,1); }
.dl.is-warn i { background: #E8A317; }
.dl.is-hot i { background: var(--hot); }
html:not(.js-ready) .card-foot [data-next-date], html:not(.js-ready) .card-foot [data-next-pill], html:not(.js-ready) .card-foot [data-next-label] {
  color: transparent; border-radius: 6px; background: linear-gradient(90deg, var(--line) 25%, var(--surface-2) 50%, var(--line) 75%); background-size: 200% 100%; }

/* ---------- избранное: сердечко, тост, конфетти ---------- */
.fav { position: relative; }
.fav .heart { transition: fill .2s, stroke .2s; transform-origin: 50% 55%; }
.confetti-bit { position: fixed; top: 0; left: 0; width: 9px; height: 14px; border-radius: 2px; pointer-events: none; z-index: 90; will-change: transform, opacity; }
.toast { position: fixed; left: 50%; bottom: 84px; transform: translate(-50%, 20px); z-index: 80; max-width: min(92vw, 420px); padding: 12px 18px; border-radius: 999px;
  background: var(--text); color: var(--bg); font-weight: 700; font-size: 15px; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; text-align: center; }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }
@media (min-width: 900px) { .toast { bottom: 32px; } }

/* ---------- пустые состояния ---------- */
.empty b { color: var(--text); font-size: 20px; }
.empty p { max-width: 380px; text-align: center; }
.empty-ill { color: var(--accent); opacity: .85; }
.fv-empty svg { color: var(--hot); }

/* ---------- кнопка темы ---------- */
.theme-btn .ti-sun { display: none; }
:root[data-theme="dark"] .theme-btn .ti-sun { display: block; }
:root[data-theme="dark"] .theme-btn .ti-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-btn .ti-sun { display: block; }
  :root:not([data-theme="light"]) .theme-btn .ti-moon { display: none; }
}
.swipe-hint { display: none; margin: 0 0 12px; }
@media (pointer: coarse) { .swipe-hint { display: block; } .card { touch-action: pan-y; } }

/* ---------- тёмная тема ---------- */
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #12102B; --surface: #1C1940; --surface-2: #231F4D;
  --line: #2E2A5E; --line-strong: #433E80;
  --text: #F1EFFF; --text-2: #CFCBF2; --muted: #A5A0D6;
  --accent: #7B62FF; --accent-hover: #8E7AFF; --accent-ink: #B2A3FF; --accent-soft: #2B2563;
  --hot: #FF7A55; --hot-text: #FF9F85; --hot-soft: #4A2220;
}
:root[data-theme="dark"] body { background: var(--bg); }
:root[data-theme="dark"] .top, :root[data-theme="dark"] .tabbar { background: var(--surface); }
:root[data-theme="dark"] .menu a.is-active, :root[data-theme="dark"] .menu a.is-active:hover { background: var(--accent-soft); color: #E4DEFF; }
:root[data-theme="dark"] .btn-accent, :root[data-theme="dark"] .menu a.is-active { color: #fff; }
:root[data-theme="dark"] .btn-accent:hover { color: #fff; }
:root[data-theme="dark"] .btn-dark-solid, :root[data-theme="dark"] .h-item-dark, :root[data-theme="dark"] .home .bot,
:root[data-theme="dark"] .news-tag-list, :root[data-theme="dark"] .tl-item:last-child:not(.tl-tbd):not(.is-done):not(.is-now) { background: #2B2563; border-color: #2B2563; color: #fff; }
:root[data-theme="dark"] .lv-I { background: #F1EFFF; color: #1E1B4B; }
:root[data-theme="dark"] .lv-II { background: #3A3290; color: #E4DEFF; }
:root[data-theme="dark"] .lv-III { background: #5A2E26; color: #FFD9CC; }
:root[data-theme="dark"] .lv-new { background: #1E3A6B; color: #D4E5FF; }
:root[data-theme="dark"] .lv-vsosh { background: #16473A; color: #CDF5E6; }
:root[data-theme="dark"] .tag-out { background: #4A1618; color: #FFB4B6; box-shadow: inset 0 0 0 1px #8A2C30; }
:root[data-theme="dark"] .card-out { border-color: #6B2428; }
:root[data-theme="dark"] .card { box-shadow: 0 8px 24px rgba(0, 0, 0, .35); }
:root[data-theme="dark"] .card:hover { border-color: #5A52B0; box-shadow: 0 14px 34px rgba(0, 0, 0, .5); }
:root[data-theme="dark"] .pill-calm, :root[data-theme="dark"] .reg-soon, :root[data-theme="dark"] .news-tag { background: #2A2658; color: var(--text-2); }
:root[data-theme="dark"] .pill-ok, :root[data-theme="dark"] .reg-open, :root[data-theme="dark"] .me-chip-on, :root[data-theme="dark"] .week-note, :root[data-theme="dark"] .news-tag-reg { background: var(--accent-soft); color: #D4CCFF; }
:root[data-theme="dark"] .pill-hot, :root[data-theme="dark"] .h-item-hot .pill-hot { background: var(--hot); color: #1A0F0B; }
:root[data-theme="dark"] .tl-item.is-done .tl-dot { background: #433E80; border-color: #433E80; }
:root[data-theme="dark"] .tl-item.is-done .tl-date, :root[data-theme="dark"] .tl-item.is-done strong { color: #8A85C2; }
:root[data-theme="dark"] .tl-item.is-now, :root[data-theme="dark"] .cal-fav[aria-pressed="true"], :root[data-theme="dark"] .reg-closed { border-color: #8A3F2E; }
:root[data-theme="dark"] .warn { background: #3B2220; border-color: #7A3B2E; }
:root[data-theme="dark"] .doc-note { background: var(--accent-soft); border-color: var(--line-strong); color: var(--text-2); }
:root[data-theme="dark"] .ev-hot { color: #FFD2C4; }
:root[data-theme="dark"] .news-tag-win, :root[data-theme="dark"] .sc-pass { background: #15402C; }
:root[data-theme="dark"] .news-tag-win, :root[data-theme="dark"] .sc-pass b, :root[data-theme="dark"] .fv-reg-open { color: #7FE0A8; }
:root[data-theme="dark"] .sc-win { background: #2B2563; }
:root[data-theme="dark"] .sc-win b { color: #D4CCFF; }
:root[data-theme="dark"] .seg-done { background: #5B4FC4; }
:root[data-theme="dark"] a.h-stat:hover { background: #2A2658; }
:root[data-theme="dark"] .select select option { background: var(--surface); color: var(--text); }
:root[data-theme="dark"] .sico-t { background: hsl(var(--h) 38% 24%); color: hsl(var(--h) 85% 80%); }
:root[data-theme="dark"] .modal { background: var(--surface); color: var(--text); }
:root[data-theme="dark"] .countdown { background: #4B33C8; }
:root[data-theme="dark"] .dl { background: #2E2A5E; }
:root[data-theme="dark"] .toast { background: #F1EFFF; color: #1E1B4B; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #12102B; --surface: #1C1940; --surface-2: #231F4D;
    --line: #2E2A5E; --line-strong: #433E80;
    --text: #F1EFFF; --text-2: #CFCBF2; --muted: #A5A0D6;
    --accent: #7B62FF; --accent-hover: #8E7AFF; --accent-ink: #B2A3FF; --accent-soft: #2B2563;
    --hot: #FF7A55; --hot-text: #FF9F85; --hot-soft: #4A2220;
  }
  :root:not([data-theme="light"]) body { background: var(--bg); }
  :root:not([data-theme="light"]) .top, :root:not([data-theme="light"]) .tabbar { background: var(--surface); }
  :root:not([data-theme="light"]) .menu a.is-active, :root:not([data-theme="light"]) .menu a.is-active:hover { background: var(--accent-soft); color: #E4DEFF; }
  :root:not([data-theme="light"]) .btn-accent { color: #fff; }
  :root:not([data-theme="light"]) .btn-dark-solid, :root:not([data-theme="light"]) .h-item-dark, :root:not([data-theme="light"]) .home .bot,
  :root:not([data-theme="light"]) .news-tag-list, :root:not([data-theme="light"]) .tl-item:last-child:not(.tl-tbd):not(.is-done):not(.is-now) { background: #2B2563; border-color: #2B2563; color: #fff; }
  :root:not([data-theme="light"]) .lv-I { background: #F1EFFF; color: #1E1B4B; }
  :root:not([data-theme="light"]) .lv-II { background: #3A3290; color: #E4DEFF; }
  :root:not([data-theme="light"]) .lv-III { background: #5A2E26; color: #FFD9CC; }
  :root:not([data-theme="light"]) .lv-new { background: #1E3A6B; color: #D4E5FF; }
  :root:not([data-theme="light"]) .lv-vsosh { background: #16473A; color: #CDF5E6; }
  :root:not([data-theme="light"]) .tag-out { background: #4A1618; color: #FFB4B6; box-shadow: inset 0 0 0 1px #8A2C30; }
  :root:not([data-theme="light"]) .card-out { border-color: #6B2428; }
  :root:not([data-theme="light"]) .card { box-shadow: 0 8px 24px rgba(0, 0, 0, .35); }
  :root:not([data-theme="light"]) .card:hover { border-color: #5A52B0; box-shadow: 0 14px 34px rgba(0, 0, 0, .5); }
  :root:not([data-theme="light"]) .pill-calm, :root:not([data-theme="light"]) .reg-soon, :root:not([data-theme="light"]) .news-tag { background: #2A2658; color: var(--text-2); }
  :root:not([data-theme="light"]) .pill-ok, :root:not([data-theme="light"]) .reg-open, :root:not([data-theme="light"]) .me-chip-on, :root:not([data-theme="light"]) .week-note, :root:not([data-theme="light"]) .news-tag-reg { background: var(--accent-soft); color: #D4CCFF; }
  :root:not([data-theme="light"]) .pill-hot, :root:not([data-theme="light"]) .h-item-hot .pill-hot { background: var(--hot); color: #1A0F0B; }
  :root:not([data-theme="light"]) .tl-item.is-done .tl-dot { background: #433E80; border-color: #433E80; }
  :root:not([data-theme="light"]) .tl-item.is-done .tl-date, :root:not([data-theme="light"]) .tl-item.is-done strong { color: #8A85C2; }
  :root:not([data-theme="light"]) .warn { background: #3B2220; border-color: #7A3B2E; }
  :root:not([data-theme="light"]) .doc-note { background: var(--accent-soft); border-color: var(--line-strong); color: var(--text-2); }
  :root:not([data-theme="light"]) .ev-hot { color: #FFD2C4; }
  :root:not([data-theme="light"]) .news-tag-win, :root:not([data-theme="light"]) .sc-pass { background: #15402C; }
  :root:not([data-theme="light"]) .sc-pass b, :root:not([data-theme="light"]) .fv-reg-open { color: #7FE0A8; }
  :root:not([data-theme="light"]) .sc-win { background: #2B2563; }
  :root:not([data-theme="light"]) .sc-win b { color: #D4CCFF; }
  :root:not([data-theme="light"]) .seg-done { background: #5B4FC4; }
  :root:not([data-theme="light"]) a.h-stat:hover { background: #2A2658; }
  :root:not([data-theme="light"]) .sico-t { background: hsl(var(--h) 38% 24%); color: hsl(var(--h) 85% 80%); }
  :root:not([data-theme="light"]) .modal { background: var(--surface); color: var(--text); }
  :root:not([data-theme="light"]) .countdown { background: #4B33C8; }
  :root:not([data-theme="light"]) .dl { background: #2E2A5E; }
  :root:not([data-theme="light"]) .toast { background: #F1EFFF; color: #1E1B4B; }
}

/* ---------- движение (только если человек его не отключил) ---------- */
@media (prefers-reduced-motion: no-preference) {
  /* переходы между страницами: карточка «перетекает» в заголовок олимпиады */
  @view-transition { navigation: auto; }
  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: .22s; }
  ::view-transition-group(*) { animation-duration: .38s; animation-timing-function: cubic-bezier(.2,.8,.2,1); }

  /* появление карточек при прокрутке */
  .js-reveal .card:not(.in) { opacity: 0; transform: translateY(14px); }
  .js-reveal .card { transition: opacity .45s ease, transform .45s cubic-bezier(.2,.8,.2,1), border-color .2s, box-shadow .25s; transition-delay: var(--d, 0ms), var(--d, 0ms), 0s, 0s; }
  .js-reveal .card.in { transition-delay: 0s; }
  .card:hover { transform: translateY(-3px); }
  .card:active { transform: scale(.985); }
  .card-title::after { content: "→"; display: inline-block; margin-left: 6px; opacity: 0; transform: translateX(-6px); transition: opacity .2s, transform .2s; color: var(--accent-ink); }
  .card:hover .card-title::after, .card-title:focus-visible::after { opacity: 1; transform: none; }

  /* сердечко */
  .fav[aria-pressed="true"] .heart { animation: olp-beat .5s cubic-bezier(.3,1.6,.5,1); }
  .fav.burst::after { content: ""; position: absolute; inset: 4px; border-radius: 50%; border: 2px solid var(--hot); animation: olp-ring .55s ease-out forwards; pointer-events: none; }
  @keyframes olp-beat { 0% { transform: scale(.6); } 55% { transform: scale(1.3); } 100% { transform: scale(1); } }
  @keyframes olp-ring { from { transform: scale(.6); opacity: .9; } to { transform: scale(1.9); opacity: 0; } }

  /* заглушки до расчёта дат */
  html:not(.js-ready) .card-foot [data-next-date], html:not(.js-ready) .card-foot [data-next-pill], html:not(.js-ready) .card-foot [data-next-label] { animation: olp-shimmer 1.2s linear infinite; }
  @keyframes olp-shimmer { to { background-position: -200% 0; } }

  /* тема переключается плавно */
  html.theme-fade, html.theme-fade * { transition: background-color .3s, color .3s, border-color .3s !important; }

  /* пустые состояния */
  .empty-ill { animation: olp-float 3.2s ease-in-out infinite; }
  .fv-empty > svg { animation: olp-float 3.2s ease-in-out infinite; }
  @keyframes olp-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }

  /* свайп */
  .card.is-swiping { transition: none !important; }
  .card.swipe-back { transition: transform .25s cubic-bezier(.2,.8,.2,1) !important; transform: none !important; }

  /* лёгкая смена выдачи после фильтра */
  .grid.is-filtering .card { opacity: .5; transition: opacity .1s; }
}

/* правки по итогам проверки v10 */
.fbtn { justify-content: flex-start; gap: 8px; }
.fbtn i { margin-left: auto; }
.fbtn .sico-s { margin: 0; vertical-align: 0; }
.card-head .tags { align-items: center; }
:root[data-theme="dark"] .tag-muted, :root[data-theme="dark"] .tile .tag-muted { background: #2A2658; color: var(--text-2); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tag-muted { background: #2A2658; color: var(--text-2); } }
@media (max-width: 560px) {
  .top { flex-wrap: nowrap; gap: 8px; }
  .top-actions { gap: 6px; }
  .top-actions .btn-icon { min-width: 40px; width: 40px; padding: 0; }
  .logo { font-size: 18px; }
}

/* ---------- подборки, подбор, сравнение, гид ---------- */
.seo-head { display: flex; flex-direction: column; gap: 16px; padding-top: 12px; padding-bottom: 28px; }
.seo-head .lead { max-width: 720px; }
.seo-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.seo-more { display: flex; flex-direction: column; gap: 14px; padding-top: 40px; padding-bottom: 40px; }
.seo-more h2 { font-size: 24px; margin-top: 12px; }
.chips-links { display: flex; flex-wrap: wrap; gap: 8px; }
.chips-links a { display: inline-flex; align-items: center; gap: 6px; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--text); font-weight: 600; font-size: 15px; }
.chips-links a:hover { border-color: var(--accent); color: var(--accent-ink); }
.chips-links .sico-s { margin: 0; }
.guide { display: flex; flex-direction: column; gap: 22px; padding-bottom: 56px; }
.guide h2 { font-size: 26px; margin-top: 14px; }
.guide-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.guide-card { display: flex; flex-direction: column; gap: 10px; padding: 24px; border-radius: 24px; border: 1px solid var(--line); background: var(--surface); }
.guide-card h2 { font-size: 20px; margin: 0; letter-spacing: -0.01em; }
.guide-card p { color: var(--text-2); }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); }
.guide-table { width: 100%; border-collapse: collapse; min-width: 520px; }
.guide-table th, .guide-table td { padding: 14px 18px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.guide-table th { font-size: 13px; color: var(--muted); font-weight: 700; }
.guide-table tr:last-child td { border-bottom: 0; }
.guide-steps { display: flex; flex-direction: column; gap: 12px; margin: 0; padding-left: 24px; max-width: 760px; }
.guide-steps li { color: var(--text-2); padding-left: 4px; }
.guide-steps b { color: var(--text); }
@media (max-width: 760px) { .guide-grid { grid-template-columns: minmax(0, 1fr); } }

/* карточка: сверка, сравнение, ошибка */
.card-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: -2px; }
.vchip { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: #1B7A43; }
.card-tools { display: flex; align-items: center; gap: 4px; }
.cmp-btn, .vflag { border: 0; background: transparent; color: var(--muted); font-size: 12px; font-weight: 700; cursor: pointer; border-radius: 999px; padding: 6px 10px; min-height: 32px; display: inline-flex; align-items: center; }
.cmp-btn:hover, .vflag:hover { background: var(--accent-soft); color: var(--accent-ink); }
.cmp-btn[aria-pressed="true"] { background: var(--accent); color: var(--on-accent); }
.vflag { padding: 6px 8px; }
.cmp-bar { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%); z-index: 70; display: flex; align-items: center; gap: 10px; padding: 8px 10px 8px 18px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line-strong); box-shadow: 0 12px 34px rgba(30, 27, 75, .22); font-weight: 700; white-space: nowrap; max-width: calc(100vw - 24px); }
.cmp-bar .btn { min-height: 38px; }
@media (min-width: 900px) { .cmp-bar { bottom: 28px; } }
:root[data-theme="dark"] .vchip { color: #7FE0A8; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .vchip { color: #7FE0A8; } }

/* подбор */
.match { display: flex; flex-direction: column; gap: 26px; padding-bottom: 56px; }
.match-form { display: grid; grid-template-columns: minmax(0, 260px) minmax(0, 1fr); gap: 22px 28px; padding: 26px; border-radius: 28px; border: 1px solid var(--line); background: var(--surface); }
.m-field { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.m-field-wide { grid-column: 1 / -1; }
.m-label { font-weight: 800; font-size: 16px; }
.m-label small { font-weight: 500; color: var(--muted); font-size: 13px; }
.m-field select { appearance: none; min-height: 48px; padding: 0 16px; border-radius: 14px; border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--text); font-weight: 700; font-size: 16px; }
.m-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.m-chip { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--text); font-weight: 600; font-size: 14px; cursor: pointer; }
.m-chip:hover { border-color: var(--accent); }
.m-chip .sico-s { margin: 0; }
.m-chip[aria-pressed="true"], .m-goal[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.m-goals { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.m-goal { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; padding: 14px 16px; border-radius: 18px; border: 1px solid var(--line); background: var(--surface); color: var(--text); text-align: left; cursor: pointer; }
.m-goal b { font-size: 16px; }
.m-goal span { font-size: 13px; opacity: .8; }
.m-goal:hover { border-color: var(--accent); }
.m-result { display: flex; flex-direction: column; gap: 14px; }
.m-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.m-head h2 { font-size: 26px; }
.m-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.m-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 18px 20px; border-radius: 22px; border: 1px solid var(--line); background: var(--surface); }
.m-row.is-out { border-color: #F4B6B8; }
.m-main { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.m-main > a { color: var(--text); font-weight: 800; font-size: 18px; letter-spacing: -0.01em; line-height: 1.25; }
.m-main > a:hover { color: var(--accent-ink); }
.m-why { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.m-next { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; text-align: right; font-size: 13px; }
.m-more { align-self: flex-start; }
@media (max-width: 760px) {
  .match-form { grid-template-columns: minmax(0, 1fr); padding: 18px; }
  .m-goals { grid-template-columns: minmax(0, 1fr); }
  .m-row { grid-template-columns: auto minmax(0, 1fr); }
  .m-next { grid-column: 1 / -1; flex-direction: row; justify-content: space-between; align-items: center; text-align: left; }
}

/* сравнение */
.compare { display: flex; flex-direction: column; gap: 22px; padding-bottom: 56px; }
.cmp-pick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.cmp-table { min-width: 640px; }
.cmp-table th:first-child, .cmp-table td:first-child { width: 22%; color: var(--muted); font-weight: 700; font-size: 14px; }
.cmp-table th { font-size: 16px; color: var(--text); }
.cmp-table tr.is-diff td:not(:first-child) { background: var(--accent-soft); }
.cmp-table .is-out { color: #A4161A; font-weight: 700; }
:root[data-theme="dark"] .cmp-table .is-out, :root[data-theme="dark"] .o-facts dd.is-out, :root[data-theme="dark"] dl dd.is-out { color: #FFB4B6; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cmp-table .is-out, :root:not([data-theme="light"]) dl dd.is-out { color: #FFB4B6; } }
@media (max-width: 640px) { .cmp-pick { grid-template-columns: minmax(0, 1fr); } }
.cmp-bar .btn.is-disabled { opacity: .45; pointer-events: none; }

.prep-steps { margin: 18px 0 0; padding-left: 22px; display: flex; flex-direction: column; gap: 8px; color: var(--muted); }
.prep-steps b { color: var(--text); }
.prep-links { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 18px; }
.prep-links a { padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); font-weight: 600; font-size: 14px; color: var(--text); }
.prep-links a:hover { border-color: var(--accent); color: var(--accent-ink); }

/* оценки и отзывы */
.rev-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.cmp-revs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.cmp-h2 { font-size: 24px; margin-top: 8px; }
.rev-card { display: flex; flex-direction: column; gap: 12px; padding: 20px; border-radius: 22px; border: 1px solid var(--line); background: var(--surface); min-width: 0; }
.rev-big { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.rev-big b { font-size: 44px; line-height: 1; letter-spacing: -0.03em; }
.rev-big span { color: var(--muted); font-size: 14px; }
.rev-parts, .rev-dist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.rev-parts li { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(60px, 1fr) 24px; gap: 10px; align-items: center; }
.rev-dist li { display: grid; grid-template-columns: 18px minmax(0, 1fr) 24px; gap: 10px; align-items: center; }
.rev-parts b, .rev-dist b { text-align: right; font-variant-numeric: tabular-nums; }
.bar { display: block; height: 8px; border-radius: 999px; background: var(--accent-soft); overflow: hidden; }
.bar u { display: block; height: 100%; border-radius: inherit; background: var(--accent); text-decoration: none; }
.rev-list { list-style: none; margin: 16px 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.rev-item { padding: 14px 16px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); }
.rev-item p { margin: 6px 0 0; overflow-wrap: anywhere; }
.rev-top { display: flex; gap: 10px; align-items: baseline; }
.rev-form { display: flex; flex-direction: column; gap: 14px; padding: 20px; border-radius: 22px; border: 1px solid var(--line-strong); background: var(--surface); margin: 8px 0 12px; }
.rev-scale { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 6px; }
.rev-scale button { min-height: 44px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--text); font-weight: 800; cursor: pointer; }
.rev-scale button:hover { border-color: var(--accent); }
.rev-scale button[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.rev-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.cmp-banner { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 14px 18px; border-radius: 18px; background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; margin: 12px 0; }
@media (max-width: 700px) { .rev-grid, .cmp-revs { grid-template-columns: minmax(0, 1fr); } .rev-scale { grid-template-columns: repeat(5, minmax(0, 1fr)); } }

/* оценки по критериям */
.rev-top-sum { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-bottom: 16px; }
.rev-sum { display: flex; flex-direction: column; gap: 8px; padding: 18px 20px; border-radius: 22px; border: 1px solid var(--line); background: var(--surface); min-width: 0; }
.rev-table { width: 100%; border-collapse: collapse; min-width: 480px; }
.rev-table th, .rev-table td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.rev-table th { font-size: 13px; color: var(--muted); font-weight: 700; }
.rev-table td:first-child { font-weight: 700; width: 34%; }
.rv { display: grid; grid-template-columns: minmax(60px, 1fr) 28px; gap: 10px; align-items: center; }
.rv b { text-align: right; font-variant-numeric: tabular-nums; }
.rev-q { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 14px; }
.rev-q .rev-scale button { min-height: 38px; }
.cmp-heads { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.rev-name { font-weight: 800; font-size: 18px; color: var(--text); line-height: 1.25; }
.rev-sum2 { display: flex; gap: 28px; }
.rev-sum2 > div { display: flex; flex-direction: column; gap: 2px; }
.rev-sum2 b { font-size: 34px; line-height: 1; letter-spacing: -0.02em; }
.cmp-line { display: grid; grid-template-columns: 78px minmax(0, 1fr); gap: 8px; align-items: center; padding: 3px 0; }
.cmp-line small { color: var(--muted); font-size: 12px; font-weight: 600; }
.cmp-table td:first-child { width: 22%; }
.cmp-total td { border-top: 2px solid var(--line-strong); background: var(--accent-soft); font-weight: 800; }
@media (max-width: 700px) { .rev-top-sum, .cmp-heads { grid-template-columns: minmax(0, 1fr); } .cmp-table { min-width: 560px; } }
.cmp-table { table-layout: fixed; }

/* поиск в сравнении */
.cmp-search { position: relative; }
.cmp-search input { min-height: 48px; padding: 0 16px; border-radius: 14px; border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--text); font: inherit; font-weight: 700; font-size: 16px; width: 100%; box-sizing: border-box; }
.cmp-search input:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.cmp-results { position: absolute; z-index: 40; left: 0; right: 0; top: 100%; margin: 6px 0 0; padding: 6px; list-style: none; max-height: 340px; overflow-y: auto; border-radius: 16px; border: 1px solid var(--line-strong); background: var(--surface); box-shadow: 0 18px 40px rgba(20, 16, 60, .18); }
.cmp-results li { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 10px; cursor: pointer; }
.cmp-results li[aria-selected="true"], .cmp-results li:hover { background: var(--accent-soft); }
.cmp-results .cmp-none { cursor: default; color: var(--muted); font-size: 14px; }
.cmp-results .cmp-none:hover { background: transparent; }

/* окно оценки */
.rev-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin: 16px 0; }
.rate-dialog { width: min(640px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); overflow-y: auto; }
.rate-dialog .rev-form { padding: 0; border: 0; margin: 0; background: transparent; }
.rate-dialog .modal-head h2 { font-size: 21px; line-height: 1.25; text-wrap: balance; }
.rev-q-h { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.rev-q-h output { font-weight: 800; color: var(--accent-ink); font-variant-numeric: tabular-nums; }
.rev-ends { display: flex; justify-content: space-between; gap: 10px; font-size: 12px; font-weight: 500; color: var(--muted); }
.rev-more summary { cursor: pointer; font-weight: 700; padding: 6px 0; }
.rev-more[open] { display: flex; flex-direction: column; gap: 12px; }
.rev-mine { display: flex; justify-content: space-between; align-items: baseline; padding: 12px 16px; border-radius: 14px; background: var(--accent-soft); }
.rev-mine b { font-size: 22px; color: var(--accent-ink); }
.rev-actions .btn[disabled] { opacity: .5; cursor: not-allowed; }
@media (max-width: 560px) { .rate-dialog .modal-body { padding: 18px; } .rev-scale { gap: 4px; } }

.m-groups { display: flex; flex-direction: column; gap: 14px; }
.m-group { display: flex; flex-direction: column; gap: 8px; }
.m-group-t { font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }

/* мобильная навигация: 5 вкладок + лист «Ещё» */
.more, .o-dock { display: none; }
@media (max-width: 899px) {
  .tabbar { grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: end; }
  .tabbar > * { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-height: 52px; color: var(--muted); font: inherit; font-size: 11px; font-weight: 600; background: none; border: 0; border-radius: 14px; padding: 0; cursor: pointer; }
  .tabbar > .is-active { background: var(--accent-soft); color: var(--accent-ink); }
  .tabbar > .tab-mid { background: none; color: var(--accent-ink); }
  .tab-disc { display: grid; place-items: center; width: 52px; height: 52px; margin-top: -26px; border-radius: 50%; background: var(--accent); color: var(--on-accent); box-shadow: 0 6px 16px rgba(91,61,245,.4); border: 4px solid var(--surface-2, #fff); box-sizing: content-box; }
  .tab-disc svg { width: 26px; height: 26px; }
  .tab-mid { min-height: 40px; }
  .more:not([hidden]) { display: block; position: fixed; inset: 0; z-index: 80; }
  .more-back { position: absolute; inset: 0; background: rgba(15,10,40,.5); }
  .more-sheet { position: absolute; left: 0; right: 0; bottom: 0; max-height: 88vh; overflow: auto; background: var(--bg, #F5F4FB); border-radius: 24px 24px 0 0; padding: 10px 16px calc(18px + env(safe-area-inset-bottom)); animation: more-up .22s ease-out; }
  @keyframes more-up { from { transform: translateY(40px); opacity: 0; } }
  @media (prefers-reduced-motion: reduce) { .more-sheet { animation: none; } }
  .more-grip { display: block; width: 40px; height: 4px; border-radius: 2px; background: var(--line); margin: 0 auto 10px; }
  .more-sheet h2 { margin: 6px 0 12px; font-size: 20px; }
  .more-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
  .more-grid a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; min-height: 92px; padding: 10px 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; color: var(--text); font-size: 13px; font-weight: 700; text-align: center; }
  .more-grid svg { color: var(--accent-ink); }
  .more-list { margin: 12px 0; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
  .more-list > * { display: flex; width: 100%; min-height: 50px; align-items: center; padding: 0 16px; color: var(--text); font: inherit; font-weight: 600; background: none; border: 0; text-align: left; cursor: pointer; }
  .more-list > * + * { border-top: 1px solid var(--line); }
  .more-auth { width: 100%; justify-content: center; gap: 4px; }
  body.more-on { overflow: hidden; }
  body.more-on .cmp-bar { display: none; }
  .o-dock { display: flex; position: fixed; left: 0; right: 0; bottom: 78px; z-index: 29; gap: 8px; padding: 8px 12px; background: var(--surface); border-top: 1px solid var(--line); }
  .o-dock .btn { flex: 1; min-height: 44px; }
  .o-dock .btn[data-fav] { flex: 0 0 52px; }
  .o-actions [data-rate-open], .o-actions [data-cmp-start], .o-actions .fav-big { display: none; }
  body:has(.o-dock) main { padding-bottom: 70px; }
}

@media (max-width: 420px) { .top-actions .btn[data-auth-btn] { padding: 0 10px; font-size: 13px; } .top-actions .btn[data-auth-btn] .tg-ico { display: none; } .logo { font-size: 18px; } }

/* кнопка «наверх» */
.to-top { position: fixed; right: 16px; bottom: 24px; z-index: 40; display: grid; place-items: center; width: 46px; height: 46px; padding: 0; border: 1px solid var(--line-strong); border-radius: 50%; background: var(--surface); color: var(--accent-ink); box-shadow: 0 8px 22px rgba(27, 24, 64, .18); cursor: pointer; }
.to-top[hidden] { display: none; }
.to-top:hover { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
@media (max-width: 899px) {
  .to-top { bottom: 96px; }
  body:has(.o-dock) .to-top { bottom: 160px; }
  body.more-on .to-top { display: none; }
}

.guide-list{margin:12px 0 0;padding-left:20px;display:grid;gap:10px;line-height:1.55;max-width:75ch}
.guide h2{margin-top:32px}

.h-parents{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0 0 20px;padding:14px 18px;border-radius:16px;background:var(--accent-soft,var(--surface));border:1px solid var(--line,rgba(0,0,0,.08));color:var(--text);text-decoration:none;line-height:1.45}
.h-parents b{color:var(--accent-ink);margin-right:6px}
.h-parents i{font-style:normal;font-weight:700;color:var(--accent-ink);flex:none}
.h-parents:hover{border-color:var(--accent-ink)}

.tgc-wrap{margin-top:28px;margin-bottom:28px}
.tgc{display:flex;align-items:center;gap:16px;padding:18px 20px;border-radius:20px;background:linear-gradient(135deg,#229ED9,#1b7fc0);color:#fff;text-decoration:none;box-shadow:0 8px 24px rgba(34,158,217,.28);transition:transform .15s}
.tgc:hover{transform:translateY(-2px)}
.tgc-ico{display:grid;place-items:center;flex:none;width:48px;height:48px;border-radius:14px;background:rgba(255,255,255,.2)}
.tgc-text{display:grid;gap:3px;flex:1;min-width:0;line-height:1.4}
.tgc-text b{font-size:17px}
.tgc-text span{font-size:14px;opacity:.92}
.tgc-btn{flex:none;padding:10px 18px;border-radius:999px;background:#fff;color:#1b7fc0;font-weight:700;font-size:14px}
@media (max-width:640px){.tgc{flex-wrap:wrap;padding:16px}.tgc-text{flex-basis:calc(100% - 66px)}.tgc-btn{width:100%;text-align:center}}
.week-head .h2s{line-height:1.35}
.week-note{display:inline-block;line-height:1.3}
@media (max-width:640px){.week-note{display:block;width:max-content;margin:6px 0 0}}
@media (max-width:560px){
  .sc-num{padding:8px 9px;flex:1 1 auto}
  .sc-num span{font-size:11px;letter-spacing:-.1px}
  .deadlines-wide{padding:4px 14px}
  .deadlines li{gap:10px}
  .dl-date{width:40px}
  .deadlines-wide .dl-text a{font-size:15px}
}
@media (max-width:380px){
  .top{padding:12px 12px}
  .top-actions{gap:6px}
  .top-actions .btn-icon{width:38px;min-width:38px;padding:0}
}

/* планшеты (641-899 px): та же нижняя навигация, что и на телефоне */
@media (min-width: 641px) and (max-width: 899px) {
  body { padding-bottom: 84px; }
  .menu { display: none; }
  .tabbar {
    display: grid; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
    background: var(--surface-2, var(--surface)); border-top: 1px solid var(--line); padding: 6px 12px calc(10px + env(safe-area-inset-bottom));
  }
  .tabbar > * { font-size: 13px; }
  .more-sheet { left: 50%; right: auto; width: min(560px, 100%); transform: translateX(-50%); border-radius: 24px 24px 0 0; }
  .o-dock { padding: 8px max(12px, calc((100% - 720px) / 2)); }
  .wrap { padding-left: 24px; padding-right: 24px; }
}
@media (min-width: 641px) and (max-width: 1100px) {
  .top { padding-left: 24px; padding-right: 24px; }
}

/* быстрее рисуем длинные списки: карточки вне экрана не отрисовываются, пока до них не докрутили */
.grid > .card { content-visibility: auto; contain-intrinsic-size: auto 260px; }

/* Новый логотип (вариант A) */
.logo .wm { font-family: Poppins, Onest, sans-serif; font-weight: 700; letter-spacing: -0.03em; line-height: 1; color: var(--logo, #4338CA); white-space: nowrap; }
.logo .wm-i { position: relative; display: inline-block; }
.logo .wm-dot { position: absolute; left: 50%; top: .13em; width: .19em; height: .19em; margin-left: -.12em; border-radius: 50%; background: #F2663F; }
.logo { font-size: 26px; }
.logo-sm { font-size: 22px; }
@media (max-width: 640px) { .logo { font-size: 22px; } }
:root[data-theme="dark"] { --logo: #B4ADFF; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* =====================================================================
   Спокойный слой (октябрь 2026): меньше «сгенерированного» вида.
   Нейтральный фон, строже формы, без капс-подписей и цветных теней.
   ===================================================================== */
:root:not([data-theme="dark"]) {
  --bg: #F7F6F3; --surface: #FFFFFF; --surface-2: #FAF9F7;
  --line: #E7E4DD; --line-strong: #D9D5CC;
  --text: #1C1B22; --text-2: #45434F; --muted: #6A6774;
  --accent: #4338CA; --accent-hover: #3730A3; --accent-ink: #3730A3; --accent-soft: #EEEDF6;
  --hot: #C2410C; --hot-text: #9A3412; --hot-soft: #FFF1E8;
}
:root { --radius: 14px; }
h1, h2, h3, h4 { font-weight: 700; letter-spacing: -0.015em; }
.eyebrow, .h-kicker, .facts dt, .cal-month, .m-group-t {
  text-transform: none; letter-spacing: 0; font-size: 14px; font-weight: 600;
}
.h-hero .h-kicker { letter-spacing: 0; text-transform: none; }
.btn, .btn-lg, .modal-x { border-radius: 10px; }
.search-box, .select select { border-radius: 10px; }
.menu { border: 0; background: transparent; padding: 0; border-radius: 0; gap: 2px; }
.menu a { border-radius: 8px; }
.menu a.is-active, .menu a.is-active:hover { background: transparent; color: var(--text); font-weight: 600; box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }
.badge, .tag, .pill, .fbtn, .fmore, .res-chip, .me-opt, .h-hero .h-kicker, .week-note,
.seg-group, .seg-btn, .news-tag, .sc-chip, .chips-links a, .m-chip, .prep-links a,
.cmp-btn, .vflag, .auth-tabs, .auth-tabs button { border-radius: 8px; }
.card, .tile, .panel, .timeline, .facts, .note, .deadlines-wide, .h-hero, .modal { border-radius: 14px; box-shadow: none; }
.card:hover, a.tile:hover, .h-hero:hover { box-shadow: none; border-color: var(--line-strong); }
.countdown { box-shadow: none; }
:root:not([data-theme="dark"]) .badge, :root:not([data-theme="dark"]) .news-tag { background: #F1F0EC; color: var(--text-2); }
:root:not([data-theme="dark"]) .week-note { background: #F1F0EC; color: var(--text-2); }
.me-grade select, .me-chip, .me-add { border-radius: 10px; }
:root:not([data-theme="dark"]) { --accent-soft: #EDEDF3; }
:root:not([data-theme="dark"]) .tag-muted { background: #F1F0EC; color: var(--text-2); }
:root:not([data-theme="dark"]) .lv-II { background: #E3E2F5; color: #2E2A7A; }
:root:not([data-theme="dark"]) .ring { background: conic-gradient(var(--ring) 0 var(--p), #ECEAE4 var(--p) 100%); }

/* =====================================================================
   Карточка олимпиады на телефоне (октябрь 2026): свободнее, одна панель
   ===================================================================== */
@media (max-width: 640px) {
  .crumbs > *:not(:first-child) { display: none; }
  .crumbs > a:first-child { display: inline-flex; align-items: center; min-height: 44px; font-size: 16px; font-weight: 500; color: var(--text); }
  .crumbs > a:first-child::before { content: "‹"; font-size: 22px; line-height: 1; margin-right: 6px; }

  .o-hero { display: flex; flex-direction: column; gap: 16px; margin: 4px 0 28px; padding: 0; background: transparent; border: 0; border-radius: 0; }
  .o-hero-main { display: contents; }
  .o-hero .tags { order: 1; gap: 6px; }
  .o-hero .sico-t { display: none; }
  .o-hero .tag-lg { font-size: 13px; padding: 5px 10px; }
  .o-title { order: 2; font-size: 30px; font-weight: 700; line-height: 1.15; letter-spacing: -0.02em; }
  .o-sub { order: 3; margin-top: -8px; font-size: 15px; color: var(--muted); }

  .o-next { order: 4; flex-direction: row; align-items: center; justify-content: flex-start; gap: 16px; text-align: left;
    padding: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
  .o-next .ring { width: 64px; border-radius: 12px; background: var(--accent-soft); }
  .o-next .ring-in { width: 100%; background: transparent; }
  .o-next .ring-in b { font-size: 24px; letter-spacing: -0.02em; }
  .o-next .ring-in span { font-size: 12px; }
  .o-next-text strong { font-size: 17px; }
  .o-next.is-empty { padding: 16px; }

  .o-hero .reg-status { order: 5; padding: 0; border: 0; background: transparent; font-size: 15px; font-weight: 500; line-height: 1.45; }
  .o-hero .reg-closed { color: var(--hot-text); }
  .o-hero .reg-open { color: var(--accent-ink); }

  .o-actions { order: 6; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; margin: 0; }
  .o-actions .btn { min-height: 48px; padding: 0 12px; font-size: 15px; }
  .o-actions .btn-accent { grid-column: 1 / -1; min-height: 52px; font-size: 16px; }
  .o-actions [data-rate-open], .o-actions [data-cmp-start] { display: inline-flex; justify-content: center; }
  .o-actions .fav-big, .o-actions [data-bot-link], .o-actions [data-share] { display: none; }

  body:has(.o-dock) .tabbar { display: none; }
  body:has(.o-dock) { padding-bottom: 0; }
  body:has(.o-dock) main { padding-bottom: 96px; }
  .o-dock { bottom: 0; gap: 10px; padding: 10px 16px calc(12px + env(safe-area-inset-bottom)); }
  .o-dock .btn { min-height: 48px; }
  .o-dock .o-dock-main { flex: 1; }
  .o-dock .o-dock-ico { flex: 0 0 48px; padding: 0; justify-content: center; }
  body:has(.o-dock) .to-top { bottom: 92px; }

  .o-body .timeline { display: block; padding: 4px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; }
  .o-body .timeline .tl-item { display: grid; grid-template-columns: 12px minmax(0, 1fr) auto; grid-template-areas: "dot date pill" "dot text pill";
    column-gap: 12px; row-gap: 2px; align-items: start; padding: 12px 0; margin: 0; border: 0; border-radius: 0;
    background: transparent !important; color: inherit !important; box-shadow: none; }
  .o-body .timeline .tl-item + .tl-item { border-top: 1px solid var(--line); }
  .o-body .timeline .tl-dot { display: block; grid-area: dot; width: 12px; height: 12px; margin-top: 4px; }
  .o-body .timeline .tl-date { grid-area: date; font-size: 14px; color: var(--muted) !important; }
  .o-body .timeline .tl-text { grid-area: text; }
  .o-body .timeline .tl-text strong { color: var(--text) !important; font-size: 16px; }
  .o-body .timeline .tl-item .pill { grid-area: pill; align-self: center; }
  .o-body .timeline .tl-item.is-now .tl-date { color: var(--hot-text) !important; }
}
@media (max-width: 640px) {
  .o-hero { align-items: stretch; text-align: left; }
  .o-hero .tags { justify-content: flex-start; }
  .o-hero .o-next .ring { background: var(--accent-soft) !important; }
  .o-body .timeline .tl-item + .tl-item { border-top: 1px solid var(--line) !important; }
  .o-body .block > h2 { font-size: 22px; letter-spacing: -0.01em; }
  :root:not([data-theme="dark"]) .o-body .timeline .tl-item.is-done .tl-dot { background: #D9D5CC; border-color: #D9D5CC; }
}
@media (max-width: 899px) {
  .o-actions [data-rate-open], .o-actions [data-cmp-start] { display: inline-flex; justify-content: center; }
  .o-actions .fav-big, .o-actions [data-bot-link], .o-actions [data-share] { display: none; }
}
@media (max-width: 899px) {
  .o-dock .o-dock-ico { flex: 0 0 48px; padding: 0; justify-content: center; }
  .o-dock .o-dock-main { flex: 1; }
}

/* установка на телефон */
.install-ios { margin: 4px 0 14px; padding: 12px 14px; border-radius: 12px; background: var(--accent-soft); color: var(--text); font-size: 15px; line-height: 1.45; }
.install-ios svg { vertical-align: -3px; }
.foot-links .linklike[data-install] { font: inherit; text-align: left; }
.install-ios p { margin: 0; }
.install-ios p + p { margin-top: 8px; }
.install-ios .linklike { font: inherit; font-weight: 600; color: var(--accent-ink); text-decoration: underline; }

/* =====================================================================
   Плавность (октябрь 2026): переходы между страницами и отклик на нажатия.
   Шапка и нижнее меню стоят на месте, меняется только содержимое.
   ===================================================================== */
:root { --ease-out: cubic-bezier(.2, .8, .2, 1); --ease-in: cubic-bezier(.4, 0, 1, 1); --t-enter: .28s; --t-exit: .16s; }
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  .top { view-transition-name: site-header; }
  .tabbar { view-transition-name: site-tabbar; }
  .o-dock { view-transition-name: site-dock; }
  main { view-transition-name: page; }

  ::view-transition-old(root), ::view-transition-new(root) { animation-duration: .2s; }
  ::view-transition-group(site-header), ::view-transition-group(site-tabbar), ::view-transition-group(site-dock) { animation-duration: .2s; }
  ::view-transition-old(page) { animation: pt-out var(--t-exit) var(--ease-in) both; }
  ::view-transition-new(page) { animation: pt-in var(--t-enter) var(--ease-out) .06s both; }
  html:active-view-transition-type(back)::view-transition-old(page) { animation-name: pt-out-back; }
  html:active-view-transition-type(back)::view-transition-new(page) { animation-name: pt-in-back; }
  @keyframes pt-out { to { opacity: 0; transform: translateY(-6px); } }
  @keyframes pt-in { from { opacity: 0; transform: translateY(12px); } }
  @keyframes pt-out-back { to { opacity: 0; transform: translateY(6px); } }
  @keyframes pt-in-back { from { opacity: 0; transform: translateY(-12px); } }

  /* браузеры без переходов между страницами: мягкое появление содержимого */
  html.pt-fallback main { animation: pt-in var(--t-enter) var(--ease-out) both; }

  /* отклик на нажатие */
  .btn, .tag, .me-chip, .me-opt, .seg-btn, .res-chip, .sc-chip, .m-chip, .fbtn, .tabbar > *, .more-grid > a, .more-list > * {
    transition: transform .14s var(--ease-out), background-color .2s, border-color .2s, color .2s, box-shadow .2s;
  }
  .btn:active, .me-chip:active, .me-opt:active, .seg-btn:active, .res-chip:active, .sc-chip:active, .m-chip:active, .fbtn:active, .more-grid > a:active { transform: scale(.97); }
  .tabbar > *:active { transform: scale(.92); }
  .menu a { transition: color .2s, box-shadow .25s var(--ease-out); }
  .card { will-change: auto; }
}
