/* Общие пропорции внутренних страниц. Содержание остаётся в исходном HTML. */
@media screen {
  main.flex-grow {
    --mp-blue: #175cf0;
    --mp-ink: #183153;
    --mp-line: #dce5f3;
    --mp-paper: #f5f7fb;
    color: var(--mp-ink);
  }
  main.flex-grow :is(.max-w-7xl, .max-w-6xl) { max-width: 1248px; margin-inline: auto; padding-inline: 24px; }
  main.flex-grow :is(.max-w-5xl, .max-w-4xl) { max-width: 1120px; margin-inline: auto; padding-inline: 24px; }
  html[data-mp-page-kind=reference] main.flex-grow .max-w-4xl { max-width: 960px; }
  main.flex-grow :is(section, article)[id] { scroll-margin-top: 145px; }
  main.flex-grow section.text-white:has(h1) {
    padding-block: clamp(32px, 4vw, 56px);
    background: linear-gradient(115deg, #175cf0, #1946d5);
  }
  main.flex-grow h1 { font-size: clamp(28px, 3.1vw, 42px); font-weight: 650; line-height: 1.18; letter-spacing: -.025em; }
  main.flex-grow h2 { font-size: clamp(23px, 2.1vw, 29px); line-height: 1.25; font-weight: 600; color: inherit; }
  main.flex-grow h3 { line-height: 1.4; }
  main.flex-grow :is(.text-gray-900, .text-gray-800) { color: var(--mp-ink); }
  main.flex-grow :is(.text-gray-600, .text-gray-700) { color: #405a7d; }
  main.flex-grow .text-gray-500 { color: #526989; }
  main.flex-grow :is(section.bg-gray-50, div.bg-gray-50) { background-color: var(--mp-paper); }
  main.flex-grow section.bg-gray-900.text-white { background: #1946d5; }
  main.flex-grow :is(section.py-16, section.py-14, section.py-12) { padding-block: 44px; }
  main.flex-grow section.text-white:has(h1) p { max-width: 76ch; }
  main.flex-grow section.text-white:has(h1) :is(p.text-xl, p.text-lg) { font-size: 18px; line-height: 1.65; }
  main.flex-grow :is(.rounded-2xl, .rounded-xl).border { border-color: var(--mp-line); border-radius: 12px; box-shadow: none; }
  main.flex-grow .grid > :is(a, div).border { padding: 20px; }
  main.flex-grow :is(.shadow-lg, .shadow-xl) { box-shadow: 0 8px 28px #1831530b; }
  main.flex-grow :is(a, button).bg-blue-600 { border-radius: 8px; min-height: 44px; }
  main.flex-grow section.text-white:has(h1) .bg-white :is(a, button).bg-blue-600 {
    background: #facc15; color: #142b4e; font-weight: 600;
  }
  main.flex-grow details.group { border: 1px solid var(--mp-line); border-radius: 10px; box-shadow: none; }
  main.flex-grow details.group[open] { border-color: #a9bff0; }
  main.flex-grow details.group > summary { padding: 17px 20px; font-size: 16px; gap: 14px; }
  main.flex-grow details.group[open] > summary { background: #f3f7ff; border-radius: 9px 9px 0 0; }
  main.flex-grow details.group > summary + div { padding: 18px 20px; }
  main.flex-grow details:not(.group) > summary { padding-block: 12px; }
  main.flex-grow :is(input:not([type=checkbox]):not([type=radio]), select, textarea) { border-radius: 8px; }
  main.flex-grow input:not([type=checkbox]):not([type=radio]), main.flex-grow select { min-height: 44px; }
  main.flex-grow table { font-size: 14px; line-height: 1.5; }
  main.flex-grow th { background: #eef3fb; color: #183153; font-weight: 600; }
  main.flex-grow :is(th, td) { padding: 13px 16px; border-color: var(--mp-line); }
  :is(main.mp-experience .mp-table-scroll, main.flex-grow div:has(> table)) { overflow-x: auto; max-width: 100%; overscroll-behavior-inline: contain; }
  html[data-mp-page-kind=reference] main.flex-grow article[id] {
    border: 1px solid var(--mp-line); border-left: 3px solid var(--mp-blue);
    border-radius: 0 12px 12px 0; padding: 22px 24px; background: #fff;
  }
  html[data-mp-page-kind=reference] main.flex-grow article[id] h3 { font-size: 18px; font-weight: 600; margin-bottom: 12px; }
  html[data-mp-page-kind=reference] main.flex-grow article[id] p { line-height: 1.7; }
  html[data-mp-page-kind=article] main.flex-grow article > .max-w-4xl { max-width: 900px; }
  html[data-mp-page-kind=article] main.flex-grow .prose { font-size: 16px; line-height: 1.8; color: var(--mp-ink); }
  html[data-mp-page-kind=article] main.flex-grow .prose h2 { margin-top: 1.8em; margin-bottom: .7em; }
  html[data-mp-page-kind=article] main.flex-grow .prose :is(img, figure) { border-radius: 12px; }
  html[data-mp-page-kind=article] main.flex-grow article > div > .flex { flex-wrap: wrap; gap: 12px 24px; }
  main.mp-experience :is(a, button, summary) { -webkit-tap-highlight-color: #175cf01a; }
  main.mp-experience :is(a, button, summary):focus-visible { outline: 3px solid #175cf0; outline-offset: 4px; }
  main.mp-experience .text-white :is(a, button, summary):focus-visible { outline-color: #facc15; }
  /* Появления ведёт общий наблюдатель, старый CSS не запускает второй эффект. */
  main.mp-experience [data-mp-entrance] { animation: none; }
  main.flex-grow :is(.flex-1, .grid > *) { min-width: 0; }
  main.flex-grow :is(p, h2, h3, li, td, a) { overflow-wrap: anywhere; }
  html[data-mp-page-kind=article] main.flex-grow > div > .bg-gray-50 .flex { flex-wrap: wrap; gap: 8px; }
  html[data-mp-page-kind=article] main.flex-grow > div > .bg-gray-50 a { flex-shrink: 0; }
}
@media screen and (max-width: 760px) {
  main.flex-grow :is(.max-w-7xl, .max-w-6xl, .max-w-5xl, .max-w-4xl) { padding-inline: 20px; }
  main.flex-grow :is(section.py-16, section.py-14, section.py-12, section.py-10) { padding-block: 30px; }
  main.flex-grow section.text-white:has(h1) { padding-block: 28px 32px; }
  main.flex-grow section.text-white:has(h1) :is(p.text-xl, p.text-lg) { font-size: 16px; }
  html[data-mp-page-kind=country] main.flex-grow section:has(h1) .flex:has(> .text-5xl) { display: block; }
  html[data-mp-page-kind=country] main.flex-grow section:has(h1) .text-5xl { display: inline-block; font-size: 22px; margin-bottom: 12px; }
  main.flex-grow .grid > :is(a, div).border { padding: 16px; }
  main.flex-grow details.group > summary { padding: 16px; }
  main.flex-grow details.group > summary + div { padding: 16px; }
  html[data-mp-page-kind=reference] main.flex-grow article[id] { padding: 18px; }
  html[data-mp-page-kind=article] main.flex-grow .prose { line-height: 1.7; }
  html[data-mp-page-kind=article] main.flex-grow > div > .bg-gray-50 .flex > span:last-child { flex-basis: 100%; }
  main.flex-grow :is(th, td) { padding: 11px 12px; }
  main.flex-grow :is(input, select, textarea) { font-size: 16px; }
  main.flex-grow .sticky:not(nav):not([role=navigation]) { max-width: 100%; }
}
@media screen and (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  main.mp-experience :is(a, button) { transition: background-color 160ms ease, border-color 160ms ease, box-shadow 160ms ease; }
  main.flex-grow :is(.grid > a.border, details.group) { transition: border-color 160ms ease, box-shadow 160ms ease; }
  main.flex-grow :is(.grid > a.border, details.group):hover { border-color: #a9bff0; box-shadow: 0 4px 18px #175cf008; }
  main.flex-grow details > summary:hover { color: #175cf0; }
}
@media (prefers-reduced-motion: reduce) {
  main.mp-experience, main.mp-experience * { scroll-behavior: auto !important; animation: none !important; transition: none !important; }
}
