/* АС Дизайн — офлайн-версия
   Основной шрифт: GOST 2.304 (SIL Open Font License 1.1, uprock.ru):
   Regular (type A), Medium (type AU) и Bold (type BU).
   Advent Pro (SIL Open Font License 1.1) — резервный для символов вне ГОСТ.
   Все ресурсы локальные: страница работает без интернета. */

@font-face {
  font-family: 'GOST 2.304';
  src: url('../assets/fonts/gost-2-304-regular.ttf') format('truetype');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'GOST 2.304';
  src: url('../assets/fonts/gost-2-304-medium.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'GOST 2.304';
  src: url('../assets/fonts/gost-2-304-medium.ttf') format('truetype');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'GOST 2.304';
  src: url('../assets/fonts/gost-2-304-bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Advent Pro';
  src: url('../assets/fonts/advent-pro-cyrillic-300.woff2') format('woff2');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Advent Pro';
  src: url('../assets/fonts/advent-pro-latin-300.woff2') format('woff2');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Advent Pro';
  src: url('../assets/fonts/advent-pro-cyrillic-400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Advent Pro';
  src: url('../assets/fonts/advent-pro-latin-400.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Advent Pro';
  src: url('../assets/fonts/advent-pro-cyrillic-500.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Advent Pro';
  src: url('../assets/fonts/advent-pro-latin-500.woff2') format('woff2');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg: #f7f5f0;
  --bg-deep: #e6e2da;
  --ink: #1c1c1a;
  --ink-soft: #2d2b27;
  --muted: #262626;
  --line: rgba(28, 28, 26, .16);
  --line-strong: rgba(28, 28, 26, .38);
  --paper: rgba(250, 248, 244, .46);
  --t-xs: 15px;
  --t-s: 15px;
  --t-m: 16px;
  --t-l: 20px;
  --t-xl: 28px;
  --t-2xl: clamp(30px, 3.3vw, 44px);
  --t-display: clamp(68px, 9.9vw, 152px);
  --max: 1560px;
  --pad: clamp(20px, 3.2vw, 48px);
  --ease: cubic-bezier(.22, .61, .36, 1);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 104px;
}

body {
  margin: 0;
  font-family: 'GOST 2.304', 'Advent Pro', 'Arial Narrow', sans-serif;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  isolation: isolate;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(rgba(247, 245, 240, .82), rgba(247, 245, 240, .9)),
    url('../assets/img/plaster.webp') center / cover no-repeat;
  pointer-events: none;
}

img { max-width: 100%; }
a { color: inherit; }
button { font: inherit; }

svg {
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

.micro {
  font-size: var(--t-xs);
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--bg);
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform .2s;
}
.skip-link:focus { transform: none; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
  font-size: var(--t-m);
}

/* ---------- Header ---------- */

.top {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid transparent;
  transition: background .3s, border-color .3s;
}
.top.is-scrolled,
.top.is-open {
  background: rgba(247, 245, 240, .9);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}

.top__in {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  min-height: 78px;
}

.brand {
  display: flex;
  align-items: center;
  grid-column: 2;
  grid-row: 1;
  justify-self: center;
  text-decoration: none;
  line-height: 1;
}
.brand__name {
  font-family: 'GOST 2.304', 'Advent Pro', 'Arial Narrow', sans-serif;
  font-size: clamp(19px, 1.6vw, 23px);
  font-weight: 400;
  letter-spacing: .04em;
}

.top__menu {
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
}

.top__links {
  display: flex;
  gap: clamp(18px, 2.2vw, 32px);
  width: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  list-style: none;
  white-space: nowrap;
}
.top__links a {
  font-family: 'GOST 2.304', 'Advent Pro', 'Arial Narrow', sans-serif;
  font-size: var(--t-s);
  font-weight: 400;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--muted);
  transition: color .2s;
}
.top__links a:hover,
.top__links a.is-active,
.top__links a[aria-current="page"] { color: var(--ink); }

@media (min-width: 901px) {
  /* Main page: the rail replaces the header links, burger reveals them on hover */
  .has-rail .top__links {
    display: flex;
    width: auto;
    max-width: 0;
    opacity: 0;
    visibility: hidden;
    overflow: hidden;
    transition: max-width .3s ease, opacity .2s ease, visibility .3s;
  }
  .has-rail .top__menu:hover .top__links,
  .has-rail .top__menu:focus-within .top__links {
    max-width: 560px;
    opacity: 1;
    visibility: visible;
  }
  .has-rail .top__menu {
    position: relative;
    min-height: 76px;
    padding: 16px 20px;
    margin: -16px -20px;
  }
  .has-rail .top__menu .top__links { margin-left: calc(24px - var(--pad)); }
  .has-rail .top__menu .burger {
    position: absolute;
    left: 0;
    top: 16px;
    margin-left: calc(44px - var(--pad));
    transition: opacity .2s ease;
  }
  .has-rail .top__menu:hover .burger,
  .has-rail .top__menu:focus-within .burger { opacity: 0; }

  /* Subpages: plain inline menu, burger is mobile-only */
  .top__menu { flex-direction: row; }
  .top__links { width: auto; }
  .top__menu .burger { display: none; }
  .has-rail .top__menu .burger { display: block; }
}

.burger {
  display: block;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  position: relative;
}
.burger span {
  position: absolute;
  left: 7px;
  right: 15px;
  height: 2px;
  background: var(--ink);
  transition: transform .25s, top .25s;
}
.burger span:first-child { top: 16px; }
.burger span:last-child { top: 26px; }
.top.is-open .burger span { left: 5px; right: 15px; }
.top.is-open .burger span:first-child { top: 20px; transform: rotate(45deg); }
.top.is-open .burger span:last-child { top: 20px; transform: rotate(-45deg); }

.mobile-nav {
  display: none;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 8px 31px 26px;
  background: var(--bg);
  box-shadow: 0 22px 36px rgba(28, 28, 26, .08);
}
.mobile-nav.is-open { display: block; }
.mobile-nav nav {
  display: flex;
  flex-direction: column;
}
.mobile-nav nav a {
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  font-family: 'GOST 2.304', 'Advent Pro', 'Arial Narrow', sans-serif;
  font-size: var(--t-l);
  font-weight: 400;
  letter-spacing: .04em;
  text-decoration: none;
}
.mobile-nav__contacts {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 20px;
  font-size: var(--t-s);
  color: var(--muted);
}
.mobile-nav__contacts a { text-decoration: none; }

/* ---------- Hero ---------- */

.hero {
  padding-top: clamp(38px, 5.4vw, 80px);
  padding-bottom: clamp(34px, 4.4vw, 64px);
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.28fr) minmax(300px, .72fr);
  gap: clamp(32px, 4.6vw, 72px);
  align-items: start;
}

.hero__main { min-width: 0; }

.hero h1 {
  margin: 0;
  font-size: var(--t-display);
  font-weight: 300;
  line-height: .84;
  letter-spacing: -.012em;
}

.hero__descriptor {
  margin: 24px 0 0;
  font-size: var(--t-s);
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.hero__rule {
  height: 1px;
  margin: clamp(26px, 3.6vw, 46px) 0 22px;
  background: var(--line);
}

.hero__lead {
  max-width: 560px;
  margin: 0;
  font-size: var(--t-l);
  font-weight: 300;
  line-height: 1.4;
  color: var(--ink-soft);
}

.hero__places {
  max-width: 560px;
  margin: 26px 0 0;
  font-size: var(--t-s);
  line-height: 1.55;
  letter-spacing: .04em;
  color: var(--muted);
}

.hero__cta {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  margin-top: clamp(28px, 3.6vw, 44px);
  padding-bottom: 6px;
  border-bottom: 1px solid var(--line-strong);
  font-size: var(--t-xs);
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  text-decoration: none;
  transition: gap .25s, border-color .25s;
}
.hero__cta:hover { gap: 17px; border-color: var(--ink); }
.hero__cta svg { width: 16px; height: 16px; }

.hero__side {
  display: flex;
  flex-direction: column;
  gap: 22px;
  min-width: 0;
}

.hero__contacts {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
}
.hero__contacts .micro { margin-bottom: 5px; }
.hero__phone {
  font-size: var(--t-l);
  font-weight: 400;
  letter-spacing: .01em;
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: border-color .2s;
}
.hero__phone:hover { border-color: var(--ink); }
.hero__mail {
  font-size: var(--t-s);
  color: var(--muted);
  text-decoration: none;
}
.hero__mail:hover { color: var(--ink); }

.hero__frame {
  position: relative;
  margin: 0;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #dedad2;
}
.hero__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.82) contrast(.97);
}

/* ---------- Intro ---------- */

.intro {
  padding-top: clamp(40px, 4.6vw, 64px);
  padding-bottom: clamp(32px, 4vw, 52px);
  text-align: center;
}
.intro h1 {
  margin: 0 auto;
  font-size: clamp(18px, 3vw, 22px);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: .03em;
  text-transform: uppercase;
}
@media (min-width: 901px) {
  .intro h1 { white-space: nowrap; }
}

/* ---------- Sections ---------- */

.section {
  padding-top: clamp(52px, 6vw, 96px);
  padding-bottom: clamp(52px, 6vw, 96px);
}

.section--first { padding-top: clamp(20px, 2.2vw, 30px); }

.section__grid {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: clamp(30px, 4.4vw, 68px);
  align-items: start;
}

.rail { min-width: 0; }
.rail a {
  display: inline-block;
  color: inherit;
  text-decoration: none;
}

@media (min-width: 901px) {
  .rail { align-self: stretch; position: relative; }

  .rail h1,
  .rail h2 {
    position: absolute;
    top: 0;
    left: 0;
  }

  .rail h1.is-stacked,
  .rail h2.is-stacked {
    position: fixed;
    z-index: 40;
  }
}
.rail a:hover h2,
.rail a:focus-visible h2 {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}
.rail h1,
.rail h2 {
  margin: 0;
  font-family: 'GOST 2.304', 'Advent Pro', 'Arial Narrow', sans-serif;
  font-size: clamp(18px, 3vw, 22px);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: .03em;
  text-transform: uppercase;
}

.section__body { min-width: 0; }

/* ---------- About ---------- */

.person {
  margin: 0;
  font-family: 'GOST 2.304', 'Advent Pro', 'Arial Narrow', sans-serif;
  font-size: clamp(18px, 3vw, 22px);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: .03em;
}
.person + .person { margin-top: 14px; }

.about__text {
  margin: 24px 0 0;
  font-family: 'Arial Narrow', 'GOST 2.304', sans-serif;
  font-size: 17px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--muted);
}
.about__education { margin-top: 34px; }
.about__s { display: block; }

/* ---------- Projects ---------- */

.grid {
  --tile-gap: clamp(24px, 7vw, 104px);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--tile-gap);
}

.tile {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.tile__media {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #d9d5cd;
  border-radius: 6px;
  transition: border-radius .25s var(--ease);
}
.tile:hover .tile__media,
.tile:focus-visible .tile__media {
  border-radius: 0;
}
.tile img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .87;
  filter: saturate(.45) contrast(.98);
  transition: transform .9s var(--ease), filter .45s, opacity .45s;
}
.tile:hover img,
.tile:focus-visible img {
  transform: scale(1.035);
  opacity: 1;
  filter: none;
}
.tile--all .tile__media {
  background: transparent;
}
.tile--all img {
  filter: blur(7px) saturate(.5) contrast(.98);
  opacity: .55;
  transform: scale(1.06);
}
.tile--all:hover img,
.tile--all:focus-visible img {
  opacity: 0;
  transform: scale(1.06);
  filter: blur(7px) saturate(.5) contrast(.98);
}
.tile__all-label {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--ink);
  font-size: clamp(15px, 1.1vw, 18px);
  font-weight: 500;
  pointer-events: none;
}
.tile__title {
  color: var(--ink);
  font-size: clamp(15px, 1.1vw, 18px);
  font-weight: 500;
  line-height: 1.25;
}
@media (hover: hover) and (min-width: 901px) {
  .grid { row-gap: calc(var(--tile-gap) - 30px); }
  .tile__title {
    opacity: 0;
    transform: translateY(4px);
    transition: opacity .25s, transform .25s;
  }
  .tile:hover .tile__title,
  .tile:focus-visible .tile__title {
    opacity: 1;
    transform: none;
  }
}
.tile:focus-visible {
  outline: 1px solid var(--ink);
  outline-offset: 4px;
}
.tile::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid transparent;
  transition: border-color .25s;
  pointer-events: none;
}

/* ---------- Services ---------- */

.svc-acc__item { border-top: 1px solid var(--line); }
.svc-acc__item:first-child { border-top: 0; }

.svc-acc__btn {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: baseline;
  width: 100%;
  padding: 20px 0;
  border: 0;
  background: none;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}
.svc-acc__name {
  font-size: clamp(18px, 3vw, 22px);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: .03em;
}
.svc-acc__meta {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 14px;
  color: var(--muted);
  white-space: nowrap;
}
.svc-acc__icon {
  position: relative;
  width: 14px;
  height: 14px;
}
.svc-acc__icon::before,
.svc-acc__icon::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 6px;
  height: 1px;
  background: var(--ink);
  transition: transform .3s var(--ease);
}
.svc-acc__icon::after { transform: rotate(90deg); }
.svc-acc__item.is-open .svc-acc__icon::after { transform: rotate(0deg); }
.svc-acc__btn:focus-visible { outline: 1px solid var(--ink); outline-offset: 4px; }

.svc-acc__panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .35s var(--ease);
}
.svc-acc__item.is-open .svc-acc__panel { grid-template-rows: 1fr; }
.svc-acc__clip {
  overflow: hidden;
  visibility: hidden;
  transition: visibility .35s;
}
.svc-acc__item.is-open .svc-acc__clip { visibility: visible; }

.svc-acc__list {
  margin: 0;
  padding: 0 0 18px;
  list-style: none;
}
.svc-acc__list li {
  display: grid;
  grid-template-columns: minmax(200px, 300px) minmax(0, 1fr);
  gap: 6px 26px;
  padding: 11px 0 12px;
  border-top: 1px solid var(--line);
}
.svc-acc__item-name {
  font-family: 'Arial Narrow', 'GOST 2.304', sans-serif;
  font-size: 17px;
  font-weight: 400;
  -webkit-text-stroke: .2px currentColor;
  line-height: 1.5;
}
.svc-acc__list p {
  max-width: 62ch;
  margin: 0;
  font-family: 'Arial Narrow', 'GOST 2.304', sans-serif;
  font-size: 17px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--muted);
}

@media (max-width: 900px) {
  .svc-acc__list li { grid-template-columns: minmax(180px, 240px) minmax(0, 1fr); }
}

@media (max-width: 640px) {
  .svc-acc__name { font-size: 18px; }
  .svc-acc__meta { font-size: 13px; gap: 10px; }
  .svc-acc__list li { grid-template-columns: 1fr; gap: 3px; }
}

@media (prefers-reduced-motion: reduce) {
  .svc-acc__panel,
  .svc-acc__icon::before,
  .svc-acc__icon::after { transition: none; }
}

/* ---------- Contacts ---------- */

.contacts__row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 28px;
}

.contacts__phone,
.contacts__mail,
.contacts__links a {
  font-family: 'Arial Narrow', 'GOST 2.304', sans-serif;
}

.contacts__phone {
  display: inline-block;
  padding-bottom: 7px;
  border-bottom: 1px solid transparent;
  font-size: clamp(16px, 2vw, 17px);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: .03em;
  text-transform: uppercase;
  text-decoration: none;
  transition: border-color .2s;
}
.contacts__phone:hover { border-color: var(--ink); }

.contacts__mail {
  display: inline-block;
  padding-bottom: 7px;
  border-bottom: 1px solid transparent;
  font-size: clamp(16px, 2vw, 17px);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: .03em;
  color: var(--muted);
  text-decoration: none;
  transition: border-color .2s, color .2s;
}
.contacts__mail:hover { color: var(--ink); border-color: var(--ink); }

.contacts__links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 20px;
  margin-top: 20px;
}
.contacts__links a {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  transition: opacity .2s;
}
.contacts__links a:hover { opacity: .65; }
.contacts__links svg { flex: none; width: auto; height: 26px; fill: currentColor; stroke: none; }
.contacts__links .soc-vk { height: 21px; }

/* ---------- Footer ---------- */

.footer {
  padding: 22px 0 30px;
  font-size: var(--t-xs);
  letter-spacing: .05em;
  color: var(--muted);
}
.footer__in {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px 24px;
}
.footer a { text-decoration: none; }
.footer a:hover { color: var(--ink); }

/* ---------- Responsive ---------- */

@media (max-width: 1180px) {
  .section__grid { grid-template-columns: 160px minmax(0, 1fr); gap: 34px; }
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hero__grid { grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr); }
}

@media (max-width: 900px) {
  .top__links { display: none; }
  .top__in { min-height: 66px; }

  .hero { padding-top: 34px; }
  .hero__grid { grid-template-columns: 1fr; gap: 34px; }
  .hero__side {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: end;
    gap: 24px;
  }
  .hero__contacts { order: 1; padding-bottom: 4px; }
  .hero__frame { order: 2; max-width: 420px; }
  .hero__contacts .micro { margin-bottom: 3px; }

  .section__grid { grid-template-columns: 1fr; gap: 22px; }
  .rail { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 14px; }
  .rail__idx { margin: 0; }
  .rail__note { max-width: none; flex-basis: 100%; margin: 2px 0 0; }

  .person { font-size: var(--t-l); }
}

@media (max-width: 640px) {
  html { scroll-padding-top: 84px; }

  .hero h1 { font-size: clamp(58px, 19vw, 86px); }
  .hero__descriptor { margin-top: 18px; font-size: var(--t-xs); letter-spacing: .13em; }
  .hero__lead { font-size: 16px; }
  .hero__places { font-size: var(--t-s); }
  .hero__side { grid-template-columns: 1fr; gap: 20px; }
  .hero__contacts { order: 1; }
  .hero__frame { order: 2; max-width: none; }

  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .footer__in { flex-direction: column; align-items: flex-start; gap: 8px; }
}

@media (hover: none) {
  .tile:not(.tile--all) img { opacity: 1; filter: none; }
  .tile__title { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
  }
}
