/* --- Навигация --- */
.navbar-nav .nav-link {
  white-space: nowrap;
}

.navbar-collapse {
  display: flex;
  align-items: center;
}

.navbar-nav {
  flex-shrink: 0;
}

/* Вот главное */
.nav-buttons {
  flex: 1;
  display: flex;
  justify-content: space-between; /* элементы по краям */
  align-items: center;
}

.not-in-desktop {
  display: none;
}

/* --- Кнопки авторизации --- */
.auth-btn {
  min-width: 100px;
  text-align: center;
}

.auth-icons .auth-btn {
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-gradient {
  display: inline-block;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  background: linear-gradient(135deg, #0d7a32, #064d1f);
  box-shadow: 0 3px 8px rgba(0, 60, 20, 0.5);
  transition: all 0.25s ease;

  margin-right: 1rem;
}

.btn-gradient:hover {
  background: linear-gradient(135deg, #129c42, #086029);
  box-shadow: 0 5px 12px rgba(0, 60, 20, 0.6);
  transform: translateY(-2px);
}

.btn-gradient:active {
  transform: translateY(0);
  box-shadow: 0 2px 5px rgba(0, 60, 20, 0.4);
}

.btn-outline {
  display: inline-block;
  padding: 6px 16px;
  font-size: 14px;
  font-weight: 600;
  color: #0d7a32;
  text-decoration: none;
  border: 2px solid #0d7a32;
  border-radius: 6px;
  background: transparent;
  transition: all 0.25s ease;

  margin-right: 1rem;
}

.btn-outline:hover {
  background: rgba(13, 122, 50, 0.1);
  box-shadow: 0 0 8px rgba(13, 122, 50, 0.4);
  transform: translateY(-2px);
}

.btn-outline:active {
  transform: translateY(0);
  box-shadow: 0 0 4px rgba(13, 122, 50, 0.3);
}

/* --- Поиск --- */
.search-container {
  position: relative;
}

.search-toggle {
  border-radius: 50%;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.search-toggle i {
  font-size: 1.2rem;
}

.search-form-desktop {
  position: absolute;
  top: 50%;
  right: 70px;
  transform: translateY(-50%);
  display: none;
  background-color: #fff;
  padding: 6px 10px;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  width: 220px;
  z-index: 100;
}

.search-form-desktop input {
  width: 100%;
  border: none;
  outline: none;
}

.search-form-desktop.show {
  display: block;
  animation: fadeIn 0.2s ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-40%); }
  to { opacity: 1; transform: translateY(-50%); }
}

/* --- Иконки --- */
.header-telegram-icon i,
.feedback-icon i {
  font-size: 1.3rem;
  transition: color 0.2s ease;
}

.header-telegram-icon:hover i {
  color: #2AABEE;
}

.feedback-icon:hover i {
  color: #ffcc00;
}

/* --- Кнопка с тремя точками --- */
.toggle-second-floor {
  border-radius: 50%;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: transparent;
  border: 1px solid #fff;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.three-dots {
  font-size: 1.5rem;
  color: #fff;
  transition: color 0.2s ease;
}

/* --- Второй этаж навигации --- */
.second-floor {
  position: absolute;
  top: 56px;
  left: 0;
  width: 100%;
  background-color: rgb(27, 28, 34);
  padding: 10px;
  z-index: 999;
}

.second-floor .nav-link {
  color: #ddd;
  padding: 5px 20px;
  margin-right: 17px;
}

.second-floor .nav-link:hover {
  background-color: #444;
}

.toggle-second-floor:hover {
  background-color: #fff;
}

.toggle-second-floor:hover .three-dots {
  color: #000;
}

/* --- Мобильная версия --- */
@media (max-width: 991.98px) {
  .navbar-collapse {
    flex-direction: column;
    align-items: start !important;
  }

  .second-floor {
    display: none !important;
  }

  .toggle-second-floor {
    display: none;
  }

  .not-in-desktop {
    display: list-item;
  }
}
