.navbar {
  position: relative;
  background: transparent;
  padding: 1rem 0;
  z-index: 100;
}

.navbar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* === Левая часть === */
.navbar-start {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.logo {
  font-size: 1.6rem;
  font-weight: 700;
  text-decoration: none;
  color: var(--fg);
}

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

.nav-links a {
  text-decoration: none;
  color: var(--fg);
  font-weight: 500;
  font-size: 1.05rem;
  transition: color 0.2s;
}
.nav-links a:hover {
  color: var(--accent);
}

/* === Правая часть === */
.navbar-end {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.phone {
  text-decoration: none;
  color: var(--fg);
  font-weight: 500;
  white-space: nowrap;
}
.phone:hover {
  color: var(--accent);
}

/* === Гамбургер === */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 16px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.hamburger span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--fg);
  border-radius: 2px;
  transition: 0.3s;
}
/* === Мобильное меню === */
.mobile-nav {
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: white;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
  overflow: hidden;
  z-index: 99;

  /* Анимация: плавное появление */
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-nav.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.mobile-nav ul {
  list-style: none;
  margin: 0;
  padding: 1.25rem var(--container-padding);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Пункты меню */
.mobile-nav li {
  margin: 0;
}

.mobile-nav a,
.mobile-nav .callback-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  font-size: 1.125rem;
  font-weight: 500;
  color: var(--fg);
  text-decoration: none;
  border-radius: 12px;
  transition: all 0.2s ease;
  background: #fafbff;
}

.mobile-nav a:hover,
.mobile-nav .callback-btn:hover {
  background: #f0f4ff;
  color: var(--accent);
  transform: translateY(-1px);
}

.mobile-nav a:active,
.mobile-nav .callback-btn:active {
  transform: translateY(0);
  background: #e8ecff;
}

/* Иконки (Font Awesome) */
.mobile-nav a::before {
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: 1.1rem;
  width: 1.25rem;
  text-align: center;
  flex: 0 0 auto;
}

.mobile-nav a[href="#courses"]::before { content: "\f0c0"; color: #5e72e4; }      /* users */
.mobile-nav a[href="#pricing"]::before { content: "\f0d6"; color: #2e7d32; }     /* ruble-sign */
.mobile-nav a[href="#teachers"]::before { content: "\f507"; color: #d32f2f; }     /* user-graduate */

/* Отделитель перед контактами */
.nav-contact {
  margin-top: 0.75rem;
  padding-top: 1.25rem;
  border-top: 1px solid #edf0f5;
}

.nav-contact a {
  font-size: 1.15rem;
  font-weight: 600;
  background: #fff9f9;
  color: #d32f2f;
}
.nav-contact a:hover {
  background: #fff0f0;
  color: #c62828;
}

.nav-contact .callback-btn {
  background: var(--accent);
  color: white;
  font-weight: 600;
  margin-top: 0.5rem;
}
.nav-contact .callback-btn:hover {
  background: #4a5dcc;
  transform: translateY(-1px);
}

/* === Адаптив === */
@media (max-width: 768px) {
  .navbar-start {
    gap: 1rem;
  }

  .nav-links,
  .phone {
    display: none;
  }

  .hamburger {
    display: flex;
  }

  .mobile-nav.active {
    display: block;
  }

  .hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .hamburger.active span:nth-child(2) { opacity: 0; }
  .hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}
