/* ===== HEADER STYLES ===== */
.site-header {
  background-color: rgba(210, 195, 180, 0.45);
  box-shadow: 0 2px 20px rgba(var(--c-brand-rgb), 0.08);
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(var(--c-white-rgb), 0.20);
  color: rgba(var(--c-brand-deep-rgb), 0.92);
  /* 100vw включает скроллбар и вызывает смещение в in-app браузерах */
  width: calc(100% + 40px); /* компенсируем padding .container (20px * 2) */
  margin-left: -20px;
  margin-right: -20px;
  /* safe-area для боковых чёлок (landscape) */
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
}

/* Контейнер шапки - всегда flex */
.container.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 72px;
  padding-top: 8px;
  padding-bottom: 8px;
}

/* Левая колонка */
.header-left {
  flex: 1;
  /* Занимает доступное пространство */
  display: flex;
  align-items: center;
}

/* Центральная колонка (логотип) */
.header-center {
  flex: 1;
  /* Занимает доступное пространство */
  display: flex;
  justify-content: center;
  /* Центрируем логотип */
  align-items: center;
}

/* Правая колонка (телефон + бургер) */
.header-right{
  display: flex;
  align-items: center;
  gap: 16px;               /* расстояние между блоком телефонов и бургером */
}

.phone-text{
  display: inline-block;
  font-variant-numeric: tabular-nums; /* цифры одинаковой ширины */
  letter-spacing: 0.2px;             /* чуть ровнее визуально */
  line-height: 1.1;
}

.header-phones{
  display: flex;
  flex-direction: column;
  gap: 4px;
  align-items: flex-start;

  flex: 0 0 auto;
}

/* чтобы внутри каждой строки иконка+текст были в линию */
.phone-link{
  display: inline-flex;
  align-items: center;
  gap: 6px;
  line-height: 1.1;
  white-space: nowrap;

  /* ключевое */
  flex: 0 0 auto;      /* запрет сжатия внутри flex */
}

/* Стили для текста "Студия пилатес" */
.studio-name {
  font-size: 13px;
  font-weight: 400;
  color: rgba(var(--c-brand-deep-rgb), 0.50);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

/* Стили для логотипа */
.logo a {
  text-decoration: none;
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 600;
  color: rgba(var(--c-brand-deep-rgb), 0.88);
  display: block;
  text-align: center;
  line-height: 1.15;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.logo a:hover {
  color: rgba(170, 120, 75, 0.90);
}

/* Стили для телефона */
.phone-link {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: rgba(var(--c-brand-deep-rgb), 0.72);
  font-weight: 400;
  font-size: 14px;
  letter-spacing: 0.02em;
  transition: color 0.3s ease;
}

.phone-link:hover {
  color: rgba(170, 120, 75, 0.90);
}

.phone-icon {
  font-size: 20px;
}


/* ===== БУРГЕР-МЕНЮ (ВСЕГДА ВИДЕН) ===== */
/* Кнопка бургера - видна на всех устройствах */
.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-between;

  width: 26px;
  height: 44px;
  padding: 12px 0; /* тап-зона по высоте 44 (--tap), полоски визуально 26×20, ширина шапки не меняется */
  box-sizing: border-box;

  background: none;
  border: none;
  cursor: pointer;
  position: relative;
  z-index: 1001;

  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

/* Полоски бургера */
.menu-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background-color: rgba(var(--c-brand-deep-rgb), 0.65);
  transition: all 0.3s ease;
  border-radius: 2px;
  transform-origin: center;
}

/* Расположение полосок */
.menu-toggle span:nth-child(1) {
  transform: translateY(0);
}

.menu-toggle span:nth-child(2) {
  opacity: 1;
}

.menu-toggle span:nth-child(3) {
  transform: translateY(0);
}

/* Когда меню открыто - превращаем в крестик */
.menu-toggle.active span:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
  transform: scale(0);
}

.menu-toggle.active span:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

/* ===== НАВИГАЦИОННОЕ МЕНЮ (ДЕСКТОП) ===== */
.main-nav {
  position: fixed;
  top: 0;
  right: -100%;
  width: 320px;
  height: 100dvh;
  background: linear-gradient(180deg,
      rgba(247, 230, 200, 0.95) 0%,
      rgba(234, 203, 149, 0.95) 50%,
      rgba(201, 138, 85, 0.9) 100%);
  backdrop-filter: blur(25px);
  -webkit-backdrop-filter: blur(25px);
  display: flex;
  flex-direction: column;
  padding: 120px 32px 40px;
  gap: 8px;
  transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1000;
  box-shadow: -10px 0 40px rgba(var(--c-brand-rgb), 0.2);
  overflow-y: auto;
  border-left: 1px solid rgba(var(--c-white-rgb), 0.3);
}

/* Когда меню открыто (на всех устройствах) */
.main-nav.active {
  right: 0;
}

/* Кнопка закрытия меню */
.nav-close {
  display: none;
}

/* Ссылки в меню (общие стили) */
.nav-link {
  text-decoration: none;
  color: var(--c-brand);
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0.03em;
  padding: 14px 20px;
  border-radius: 12px;
  transition: all 0.3s ease;
  border-bottom: none;
  background: rgba(var(--c-white-rgb), 0.15);
  margin-bottom: 4px;
}

.nav-link:hover {
  background: rgba(var(--c-white-rgb), 0.45);
  transform: translateX(6px);
  color: var(--c-brand);
}

/* Специальная кнопка "Записаться" в меню */
.nav-link-cta {
  background: var(--c-brand);
  color: var(--c-white) !important;
  text-align: center;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.05em;
  margin-top: 24px;
  border: none;
  padding: 16px 28px !important;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(var(--c-brand-rgb), 0.35);
  transition: all 0.3s ease;
}

.nav-link-cta:hover {
  background: var(--c-brand-wine);
  transform: translateY(-3px) translateX(0);
  box-shadow: 0 12px 32px rgba(var(--c-brand-rgb), 0.45);
}

