/* skip-link */
.skip-link {
  position: absolute;
  left: 16px;
  top: 0;
  z-index: 100;
  padding: 12px 20px;
  background: var(--c-black);
  color: var(--c-white);
  font-weight: var(--weight-ui);
  border-radius: 0 0 12px 12px;
  transform: translateY(-120%);
}
.skip-link:focus { transform: none; }

.btn--dark { background: var(--c-black); color: var(--c-white); }
.btn--dark span { font-size: 1.4em; line-height: 0.7; }

/* header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: var(--c-white);
  transition: transform 250ms ease;
}
.site-header.is-hidden { transform: translateY(-100%); }

.site-header__inner {
  position: relative;
  display: flex;
  align-items: center;
  gap: 24px;
  height: 100%;
}
.site-header__logo { display: block; flex: none; width: 172px; margin-right: auto; }
.site-header__logo img { width: 172px; height: auto; }

.site-nav { position: absolute; left: 50%; transform: translateX(-50%); }
.site-nav ul { display: flex; gap: 42px; white-space: nowrap; }
.site-nav a {
  font-weight: var(--weight-ui);
  font-size: 16px;
  text-decoration: none;
}
.site-nav a:hover { text-decoration: underline; text-underline-offset: 4px; }
.site-nav__cta, .site-header__burger { display: none; }

.site-header__cta { padding: 0.95em 1.5em; white-space: nowrap; }

.lang-switch { font-weight: var(--weight-ui); font-size: 16px; white-space: nowrap; }
.lang-switch a { text-decoration: none; }
.lang-switch a:hover { text-decoration: underline; text-underline-offset: 4px; }
.lang-switch [aria-current] { color: var(--c-pink); }

@media (min-width: 901px) and (max-width: 1200px) {
  .site-header__inner { gap: 16px; }
  .site-header__logo, .site-header__logo img { width: 140px; }
  .site-nav ul { gap: 20px; }
  .site-nav a { font-size: 14px; }
  .site-header__cta { padding: 0.8em 1.1em; font-size: 14px; }
}

html.is-locked { overflow: hidden; }

/* компактная шапка: <= 900px (тот же порог в base.css и header.js) */
@media (max-width: 900px) {
  .site-header__inner { gap: 16px; }
  .site-header__logo, .site-header__logo img { width: 132px; }
  .site-header__cta { display: none; }

  .site-header__burger {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin-right: -8px;
    padding: 0 9px;
    border: 0;
    background: transparent;
    cursor: pointer;
  }
  .site-header__burger-lines { display: flex; flex-direction: column; gap: 5px; }
  .site-header__burger-lines span {
    display: block;
    width: 26px;
    height: 2px;
    border-radius: 2px;
    background: var(--c-black);
    transition: transform 150ms ease, opacity 150ms ease;
  }
  .site-header__burger[aria-expanded="true"] .site-header__burger-lines span:first-child { transform: translateY(7px) rotate(45deg); }
  .site-header__burger[aria-expanded="true"] .site-header__burger-lines span:nth-child(2) { opacity: 0; }
  .site-header__burger[aria-expanded="true"] .site-header__burger-lines span:last-child { transform: translateY(-7px) rotate(-45deg); }

  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    transform: none;
    height: calc(100vh - var(--header-h));
    height: calc(100dvh - var(--header-h));
    overflow-y: auto;
    padding: 8px var(--page-gutter) 32px;
    background: var(--c-white);
    border-top: 1px solid var(--c-gray);
  }
  .site-header.is-menu-open .site-nav { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; }
  .site-nav li { border-bottom: 1px solid var(--c-gray); }
  .site-nav a { display: block; padding: 18px 4px; font-size: 22px; }
  .site-nav__cta { display: inline-flex; width: 100%; margin-top: 28px; }
}

/* footer */
.site-footer { border-top: 1px solid var(--c-gray); }
.site-footer__inner {
  display: flex;
  align-items: center;
  gap: 24px;
  padding-block: 32px;
  font-size: 13px;
}
.site-footer__brand { display: flex; flex-direction: column; gap: 10px; flex: none; }
.site-footer__brand b { font-weight: var(--weight-ui); letter-spacing: 0.24em; white-space: nowrap; }
.site-footer__brand span { opacity: 0.65; white-space: nowrap; }
.site-footer__contacts {
  display: flex;
  flex: none;
  gap: 20px;
  margin: 0;
  padding-inline: 20px;
  border-inline: 1px solid var(--c-gray);
}
.site-footer__contacts dt { margin-bottom: 6px; font-weight: var(--weight-ui); }
.site-footer__contacts dd { margin: 0; white-space: nowrap; opacity: 0.65; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { text-decoration: underline; text-underline-offset: 3px; }
.site-footer__legal {
  display: flex;
  flex: 1;
  justify-content: space-between;
  gap: 16px;
  opacity: 0.65;
  white-space: nowrap;
}

@media (min-width: 761px) and (max-width: 1279px) {
  .site-footer__inner { gap: 8px; font-size: 12px; }
  .site-footer__brand b { letter-spacing: 0.16em; }
  .site-footer__contacts { gap: 8px; padding-inline: 10px; }
  .site-footer__legal { gap: 8px; }
}

/* 761–1279: ссылки в одну строку не помещаются — вторая строка на всю ширину сетки, ссылки равномерно */
@media (min-width: 761px) and (max-width: 1279px) {
  .site-footer__inner { flex-wrap: wrap; row-gap: 20px; }
  .site-footer__legal { flex-basis: 100%; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; }
}

@media (max-width: 760px) {
  .site-footer__inner { flex-direction: column; align-items: stretch; gap: 24px; padding-block: 32px; }
  .site-footer__contacts { flex-direction: column; gap: 16px; padding: 20px 0; border-inline: 0; border-block: 1px solid var(--c-gray); }
  .site-footer__legal { flex-direction: column; flex-wrap: nowrap; gap: 4px; }
  .site-footer__legal a { display: block; padding: 8px 0; font-size: 15px; }
}
