/* ============================================================
   shared-nav.css — общий header.nav для index/catalog/promo/preparate
   Источник: inline CSS index.html L192-L376 (NAV) + responsive
   правила nav из RESPONSIVE-секции L2328-L2402.
   Не дублирует .m-nav (живёт в branch.css).
   ============================================================ */

/* ===== NAV ===== */
.nav, nav.nav, header.nav {
  position: sticky;
  top: var(--promo-h, 0px);
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  transition: top 0.25s ease, box-shadow 0.25s ease;
}
.nav.is-scrolled, nav.is-scrolled, header.nav.is-scrolled {
  box-shadow: 0 6px 24px rgba(0,0,0,0.06);
  background: rgba(255,255,255,0.96);
}
.nav.is-scrolled .nav-inner, nav.is-scrolled .nav-inner { padding-top: 10px; padding-bottom: 10px; }
.nav.is-scrolled .logo-mark, nav.is-scrolled .logo-mark { width: 34px; height: 34px; }
.nav.is-scrolled .logo-name, nav.is-scrolled .logo-name { font-size: 16px; }
.nav.is-scrolled .logo-tag, nav.is-scrolled .logo-tag { opacity: 0; height: 0; margin: 0; overflow: hidden; }
.nav.is-scrolled .nav-cta, nav.is-scrolled .nav-cta { padding-top: 10px; padding-bottom: 10px; font-size: 12px; }
header.nav .logo-mark, header.nav .logo-name, header.nav .logo-tag, header.nav .nav-cta { transition: all 0.25s ease; }

.nav-inner {
  max-width: 1440px;
  margin: 0 auto;
  padding: 20px 40px;
  display: flex;
  align-items: center;
  gap: 32px;
  flex-wrap: nowrap;
}

header.nav .logo {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none !important;
  color: #1A1A1A !important;
  transition: opacity 0.2s;
  flex-shrink: 0;
}
header.nav .logo:hover { opacity: 0.78; }
header.nav .logo-mark { width: 44px; height: 44px; color: #B8945F; flex-shrink: 0; }
header.nav .logo-text { display: flex; flex-direction: column; gap: 3px; line-height: 1; white-space: nowrap; }
header.nav .logo-name {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  font-size: 22px;
  color: #1A1A1A;
  letter-spacing: -0.015em;
}
header.nav .logo-tag {
  font-family: Georgia, 'Times New Roman', serif;
  font-style: italic;
  font-size: 9px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: #8B6F2C;
}
@media (max-width: 540px) {
  header.nav .logo { gap: 10px; }
  header.nav .logo-mark { width: 36px; height: 36px; }
  header.nav .logo-name { font-size: 15px; }
  header.nav .logo-tag { display: none; }
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  font: 500 14px/1 'Manrope', sans-serif;
  color: var(--gray);
  letter-spacing: .04em;
  padding: 8px 0;
  text-decoration: none;
  transition: color 0.15s;
  white-space: nowrap;
}

.nav-links a:hover,
.nav-links a.active { color: var(--gold-deep); }

.nav-right { margin-left: auto; display: flex; align-items: center; gap: 12px; }
.nav-phone {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 500; color: var(--ink);
  padding: 10px 14px; border-radius: 100px;
  transition: all 0.2s; white-space: nowrap; text-decoration: none;
}
.nav-phone:hover { color: var(--gold-deep); background: var(--cream); }
.nav-phone svg { width: 16px; height: 16px; flex-shrink: 0; }
.nav-chips { display: inline-flex; gap: 6px; margin-left: 4px; }
.nav-chip {
  width: 34px; height: 34px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--cream); border: 1px solid var(--line);
  transition: all 0.2s; text-decoration: none; flex-shrink: 0;
}
.nav-chip:hover { transform: translateY(-1px); box-shadow: 0 4px 10px rgba(0,0,0,0.12); }
.nav-chip svg { width: 17px; height: 17px; color: #fff; }
.nav-chip.is-tg { background: #229ED9; border-color: #229ED9; }
.nav-chip.is-tg:hover { background: #1E8BC0; border-color: #1E8BC0; }
.nav-chip.is-wa { background: #25D366; border-color: #25D366; }
.nav-chip.is-wa:hover { background: #1FB458; border-color: #1FB458; }
.nav-chip.is-max { background: #fff; }
.nav-chip.is-max img { width: 20px; height: 20px; border-radius: 5px; transition: transform 0.2s, filter 0.2s; }
.nav-chip.is-max:hover { border-color: #1A1A1A; }
.nav-chip.is-max:hover img { transform: scale(1.08); filter: drop-shadow(0 2px 6px rgba(26,26,26,0.4)); }

@media (max-width: 1500px) { .nav-chips { display: none !important; } }
@media (max-width: 1400px) {
  .nav-phone .num { display: none !important; }
  .nav-phone { padding: 10px; min-width: 44px; justify-content: center; }
  .nav-inner { gap: 24px; }
  .nav-cta { padding: 11px 20px; font-size: 11px; letter-spacing: 0.05em; }
}

/* === Search trigger === */
.search-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: 4px;
  height: 40px;
  padding: 0 14px 0 12px;
  border-radius: 100px;
  background: var(--cream);
  border: 1px solid var(--line);
  color: var(--ink);
  font: 500 13px/1 'Manrope', sans-serif;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s;
  white-space: nowrap;
}
.search-trigger:hover {
  background: #fff;
  border-color: var(--gold);
  color: var(--gold-deep);
  box-shadow: 0 4px 12px rgba(184,148,95,0.12);
}
.search-trigger svg {
  width: 16px; height: 16px;
  color: var(--gold-deep);
  stroke-linecap: round;
  flex-shrink: 0;
}
.search-trigger .st-label { letter-spacing: 0.02em; }
@media (max-width: 1280px) {
  .search-trigger .st-label { display: none; }
  .search-trigger { width: 40px; padding: 0; justify-content: center; }
}

.nav-cta {
  background: var(--ink);
  color: var(--gold-light);
  padding: 12px 22px;
  border-radius: 100px;
  text-decoration: none;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid var(--ink);
  transition: all 0.3s;
  flex-shrink: 0;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.nav-cta:hover {
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: var(--ink);
  border-color: var(--gold);
}

/* ===== RESPONSIVE (только nav-релевантные правила) ===== */
@media (max-width: 1200px) {
  .nav-inner { gap: 28px; }
  .nav-links { gap: 24px; }
}
@media (max-width: 1100px) {
  .nav-links { display: none; }
  .nav-chips { display: none; }
  .nav-phone .num { display: none; }
  .nav-phone { padding: 10px; min-width: 44px; justify-content: center; }
  .nav-inner { padding: 16px 24px; gap: 16px; }
  .nav-right { gap: 8px; }
  .nav-cta { padding: 10px 16px; font-size: 11px; letter-spacing: 0.04em; }
}
@media (max-width: 900px) {
  .nav-inner { padding: 16px 24px; }
  .nav-links { display: none; }
}
@media (max-width: 768px) {
  .nav-chips { display: none !important; }
  .search-trigger { display: none !important; }
  .nav-inner { padding: 12px 16px; gap: 10px; }
  .nav-right { gap: 6px; }
  .nav-cta { padding: 9px 14px; font-size: 10px; letter-spacing: 0.04em; }
  header.nav .logo-tag { display: none; }
  header.nav .logo-mark { width: 38px; height: 38px; }
  header.nav .logo-name { font-size: 16px; }
}
