/* ════════════════════════════════════════════
   LAYOUT — Header · Ticker · Main · Footer
════════════════════════════════════════════ */

/* ── Site wrapper ── */
.site {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.site-enter {
  animation: site-reveal 0.6s ease both;
}

@keyframes site-reveal {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ── Header ── */
.header {
  position: sticky;
  top: 0;
  z-index: var(--z-sticky-header);
  height: var(--header-h);
  background: rgba(10, 10, 10, 0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.3s;
}

.header.scrolled {
  box-shadow: 0 4px 32px rgba(0, 0, 0, 0.8);
}

.header__inner {
  max-width: var(--content-max);
  margin: 0 auto;
  height: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  padding: 0 var(--content-pad);
  gap: 16px;
}

/* Logo (center) */
.logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-self: center;
  line-height: 1;
  user-select: none;
}

.logo__img {
  height: 80px;
  width: auto;
  display: block;
}

/* Auth buttons (right) */
/* Burger (mobile, right) */
.burger {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  /* Кликабельная область 44×44 (WCAG 2.2 AA), сама иконка остаётся 26px */
  min-width: 44px;
  min-height: 44px;
  justify-self: end;
}

.burger__line {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: transform var(--duration-base), opacity var(--duration-base);
}

.burger[aria-expanded="true"] .burger__line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.burger[aria-expanded="true"] .burger__line:nth-child(2) {
  opacity: 0;
}

.burger[aria-expanded="true"] .burger__line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ── Navbar (внутри header) ── */
.navbar {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100%;
}

.navbar__list {
  display: flex;
  align-items: center;
  height: 100%;
}

.navbar__list--cta {
  display: flex;
  align-items: center;
  height: 100%;
}

/* ── Кнопка «Записаться» справа ── */
.header__cta {
  display: flex;
  align-items: center;
  height: 100%;
}

/* ── Ticker strip ── */
.ticker {
  position: sticky;
  top: var(--header-h);
  z-index: calc(var(--z-sticky-header) - 1);
  background: var(--accent);
  overflow: hidden;
  height: 36px;
  display: flex;
  align-items: center;
}

.ticker__track {
  display: flex;
  align-items: center;
  white-space: nowrap;
  animation: ticker-scroll 30s linear infinite;
  will-change: transform;
}

@keyframes ticker-scroll {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-50%);
  }
}

.ticker__segment {
  display: flex;
  align-items: center;
  gap: 28px;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 15px;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.92);
  padding-right: 28px;
}

.ticker__dot {
  color: rgba(255, 255, 255, 0.38);
  font-size: 9px;
  line-height: 1;
}

/* ── Main content ── */
.main {
  flex: 1;
  max-width: var(--content-max);
  margin: 0 auto;
  width: 100%;
  padding: 0 var(--content-pad) 60px;
}

/* ── Footer ── */
.footer {
  border-top: 1px solid var(--border);
  background: var(--bg-2);
  margin-top: auto;
}

.footer__inner {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 14px var(--content-pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer__logo {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 20px;
  letter-spacing: 0.18em;
  color: var(--blue);
  text-shadow: 0 0 12px var(--blue-glow);
  user-select: none;
}

.footer__copy {
  font-size: 12px;
  color: var(--text-muted);
}

.footer__links {
  display: flex;
  gap: 20px;
}

.footer__links a {
  font-size: 12px;
  color: var(--text-muted);
  transition: color var(--duration-fast);
}

.footer__links a:hover {
  color: var(--text);
}

/* ── Responsive ── */
@media (max-width: 768px) {
  :root {
    --header-h: 56px;
  }

  .header__inner {
    grid-template-columns: 1fr auto 1fr;
  }

  .logo {
    grid-column: 2;
    justify-self: center;
  }

  .burger {
    grid-column: 3;
    justify-self: end;
  }

  .logo__img {
    height: 28px;
  }

  .burger {
    display: flex;
  }

  .navbar {
    display: none;
  }

  .header__cta {
    display: none;
  }

  .ticker {
    height: 30px;
  }

  .main {
    padding: 0 16px 48px;
  }

  .footer__inner {
    flex-direction: column;
    text-align: center;
  }

  .footer__links {
    justify-content: center;
  }
}