/* Контейнеры, сетки, секции. Мобильный первый, точки: 480, 768, 1024, 1280. */

section {
  padding-block: var(--section-y);
}

section + section {
  border-top: 1px solid var(--c-border);
}

.section-inner > * + * {
  margin-top: var(--s-5);
}

/* Шапка */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--c-bg) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--c-border);
}

.site-header__inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--s-2);
  padding-block: var(--s-2);
}

.site-header__brand {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  font-family: var(--f-head);
  font-weight: 600;
  font-size: 1.25rem;
  text-decoration: none;
  white-space: nowrap;
  margin-right: auto;
}

/* Пока скрыта навигация (< 768px), логотип + текст + значки + кнопка не
   помещаются в одну строку — прячем текстовую часть бренда (логотип
   остаётся кликабельной ссылкой на главную) и переносим CTA на вторую строку. */
@media (max-width: 767px) {
  .site-header__brand-text {
    display: none;
  }

  .site-header__cta {
    flex-basis: 100%;
    margin-left: 0;
  }
}

.site-header__nav {
  display: none;
}

@media (min-width: 768px) {
  .site-header__nav {
    display: flex;
    align-items: center;
    gap: var(--s-4);
  }
}

.site-header__nav a {
  text-decoration: none;
  color: var(--c-text-muted);
  font-size: var(--fs-small);
}

.site-header__nav a:hover {
  color: var(--c-text);
}

.site-header__contacts {
  display: flex;
  align-items: center;
  gap: var(--s-1);
  flex-shrink: 0;
}

.site-header__cta {
  flex-shrink: 0;
  margin-left: var(--s-1);
}

/* Герой */

.hero {
  padding-top: var(--s-6);
}

.hero__grid {
  display: grid;
  gap: var(--s-6);
}

@media (min-width: 1024px) {
  .hero__grid {
    grid-template-columns: 1fr 1fr;
    align-items: center;
  }
}

/* Сетки карточек */

.grid {
  display: grid;
  gap: var(--s-3);
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .grid--2 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 768px) {
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 1024px) {
  .grid--4 { grid-template-columns: repeat(4, 1fr); }
}

/* Секция с картинкой-фоном */

.section-media {
  position: relative;
  background: var(--c-surface);
  overflow: hidden;
}

.section-media__bg {
  position: absolute;
  inset: 0;
  object-fit: cover;
  width: 100%;
  height: 100%;
  opacity: 0.35;
}

.section-media__content {
  position: relative;
  z-index: 1;
}

/* Подвал */

.site-footer {
  padding-block: var(--s-6);
  border-top: 1px solid var(--c-border);
  background: var(--c-surface);
}

.site-footer__grid {
  display: grid;
  gap: var(--s-4);
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .site-footer__grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.site-footer__col h3 {
  font-size: var(--fs-small);
  font-family: var(--f-body);
  font-weight: 600;
  color: var(--c-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: var(--s-2);
}

.site-footer__col ul > * + * {
  margin-top: var(--s-1);
}

.site-footer__col a {
  text-decoration: none;
}

.site-footer__col a:hover {
  color: var(--c-action);
}

.site-footer__bottom {
  margin-top: var(--s-5);
  padding-top: var(--s-3);
  border-top: 1px solid var(--c-border);
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  justify-content: space-between;
  color: var(--c-text-muted);
  font-size: var(--fs-small);
}

/* Cookie-полоса */

.cookie-bar {
  position: fixed;
  left: var(--s-2);
  right: var(--s-2);
  bottom: var(--s-2);
  z-index: 90;
  max-width: 640px;
  margin-inline: auto;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: var(--s-3);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  box-shadow: 0 4px 24px color-mix(in srgb, black 8%, transparent);
}

.cookie-bar[hidden] {
  display: none;
}

.cookie-bar p {
  flex: 1 1 240px;
  font-size: var(--fs-small);
  color: var(--c-text-muted);
}

/* Хлебные крошки */

.breadcrumbs {
  font-size: var(--fs-small);
  color: var(--c-text-muted);
  padding-top: var(--s-3);
}

.breadcrumbs a {
  text-decoration: none;
}

.breadcrumbs a:hover {
  color: var(--c-action);
}
