/* Заголовки */
.container h2 {
  display: flex;
  justify-content: center;
  margin: 40px;
  color: #402e21;
  font-family: "Playfair Display", serif;
  font-size: 40px;
}

/* Батьківський контейнер секції */
.reviews-section .container {
  overflow: hidden;
  position: relative;
  padding: 20px 0;
}

/* Контейнер для відгуків - ГОРИЗОНТАЛЬНА ПРОКРУТКА */
.reviews-container {
  display: flex !important;
  flex-wrap: nowrap !important;
  /* Все в одну лінію */
  gap: 20px;
  padding: 20px;
  overflow-x: auto !important;
  /* Скрол вліво-вправо */
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  /* Ховаємо стандартний скролбар */
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.reviews-container::-webkit-scrollbar {
  height: 8px;
  display: block !important;
}

/* Картка відгуку */
.review-card {
  flex: 0 0 300px !important;
  /* Фіксована ширина, не стискається */
  background: #fff;
  border-radius: 15px;
  padding: 20px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  border: 1px solid #f0e6db;
  width: 300px !important;
  /* Жорстка ширина */
  min-width: 300px !important;
}

/* Інформація про користувача */
.user-info {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 15px;
}

.user-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
}

.user-name {
  margin: 0;
  color: #402e21;
}

.review-text {
  font-style: italic;
  color: #555;
  line-height: 1.5;
}

/* Форма відгуків */
.reviews-form-container {
  max-width: 600px;
  margin: 20px auto;
  background: #fdfaf7;
  padding: 30px;
  border-radius: 20px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
  display: none;
  /* Сховано за замовчуванням */
}

/* Класи для показу форми через JS */
.reviews-form-container.active,
.reviews-form-container.show {
  display: block;
}

/* Кнопки та поля */
.toggle-form-btn {
  display: block;
  margin: 20px auto;
  background-color: #8c6a4a;
  color: white;
  padding: 12px 25px;
  border: none;
  border-radius: 25px;
  cursor: pointer;
  font-weight: bold;
  transition: 0.3s;
}

.toggle-form-btn:hover {
  background-color: #402e21;
}

.form-row {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
}

.form-row input,
textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #d9c5b2;
  border-radius: 10px;
  outline: none;
}

.submit-btn {
  width: 100%;
  background: #402e21;
  color: white;
  padding: 12px;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  font-size: 16px;
}

/* Адмін-панель (Видалення) */
.delete-btn {
  display: none !important;
  position: absolute;
  top: 10px;
  right: 10px;
  cursor: pointer;
}

body.admin-mode .delete-btn {
  display: block !important;
}

/* Зірки */
.star-rating input {
  display: none;
}

.star-rating label {
  filter: contrast(0.001) sepia(2) saturate(2) brightness(1.2);
  cursor: pointer;
  font-size: 25px;
}

.star-rating :checked~ :not(:checked)+label {
  filter: none;
}

/* Ховаємо кнопки видалення для всіх */
.admin-delete-btn {
  display: none;
  position: absolute;
  top: 10px;
  right: 10px;
  background: #ff4d4d;
  color: white;
  border: none;
  border-radius: 50%;
  width: 25px;
  height: 25px;
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

/* Показуємо кнопки ТІЛЬКИ в режимі адміністратора */
body.admin-mode .admin-delete-btn {
  display: block;
}

/* Стиль для картки, щоб кнопка позиціонувалася відносно неї */
.review-card {
  position: relative;
  /* Обов'язково для точного розміщення кнопки */
  padding: 20px;
  /* ваші інші стилі */
}