/* Сброс стилей */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Montserrat", sans-serif;
  color: #fff;
  line-height: 1.6;
  overflow-x: hidden; /* Чтобы не было гориз. скролла */
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* === HERO С ФОТО-ФОНОМ === */
.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-bg-image {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Фото заполняет весь экран без искажений */
  object-position: center; /* Центрируем фото */
}

/* Затемнение поверх фото (чтобы текст читался) */
.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    to bottom,
    rgba(15, 20, 30, 0.6) 0%,
    rgba(15, 20, 30, 0.4) 50%,
    rgba(15, 20, 30, 0.7) 100%
  );
  z-index: 2;
}

/* Контент поверх фона */
.hero-content {
  position: relative;
  z-index: 3;
  text-align: center;
  color: #fff;
  padding: 0 20px;
}

.hero-content h1 {
  font-size: 3.5rem;
  font-weight: 700;
  margin-bottom: 20px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.hero-content p {
  font-size: 1.3rem;
  margin-bottom: 30px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

/* Адаптив для мобильных */
@media (max-width: 768px) {
  .hero-content h1 {
    font-size: 2.5rem;
  }
  .hero-content p {
    font-size: 1.1rem;
  }
}

/* --- ШАПКА --- */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 40px;
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(5px);
}

.logo {
  font-weight: 600;
  font-size: 1.2rem;
  letter-spacing: 2px;
}

.lang-btn {
  background: transparent;
  border: 1px solid #fff;
  color: #fff;
  padding: 5px 15px;
  cursor: pointer;
  transition: 0.3s;
}

.lang-btn:hover {
  background: #fff;
  color: #000;
}

/* --- ГЛАВНЫЙ ЭКРАН --- */
.hero {
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.hero h1 {
  font-size: 3rem;
  margin-bottom: 20px;
  text-transform: uppercase;
}

.hero p {
  font-size: 1.2rem;
  margin-bottom: 30px;
  opacity: 0.9;
}

.btn {
  display: inline-block;
  padding: 15px 30px;
  background: #fff;
  color: #000;
  text-decoration: none;
  font-weight: 600;
  text-transform: uppercase;
  transition: 0.3s;
}

.btn:hover {
  background: #ddd;
}

/* --- ПОРТФОЛИО --- */
.portfolio {
  padding: 80px 0;
  background: #111; /* Темный фон для секции */
  position: relative;
  z-index: 1;
}

.portfolio h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 2rem;
}

.filter-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 40px;
}

.filter-buttons button {
  background: transparent;
  border: 1px solid #555;
  color: #fff;
  padding: 8px 16px;
  cursor: pointer;
  transition: 0.3s;
}

.filter-buttons button.active,
.filter-buttons button:hover {
  border-color: #fff;
  background: #fff;
  color: #000;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 15px;
}

.photo-item img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  border-radius: 4px;
  transition: transform 0.3s;
}

.photo-item:hover img {
  transform: scale(1.02);
}

/* Класс для скрытия элементов при фильтрации */
.photo-item.hidden {
  display: none;
}

/* --- КОНТАКТЫ --- */
.contacts {
  padding: 80px 0;
  background: #000;
  text-align: center;
  position: relative;
  z-index: 1;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
}

.social-link {
  color: #fff;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: 0.3s;
}

.social-link:hover {
  border-color: #fff;
}

footer {
  padding: 20px 0;
  text-align: center;
  background: #000;
  font-size: 0.8rem;
  color: #777;
  position: relative;
  z-index: 1;
}
/* === МОБИЛЬНАЯ АДАПТАЦИЯ === */
@media (max-width: 768px) {
  /* 1. Шапка */
  .header {
    padding: 15px 20px;
  }

  /* 2. Главный экран: уменьшаем текст */
  .hero h1 {
    font-size: 1.8rem; /* Было 3rem */
    margin-bottom: 15px;
  }
  .hero p {
    font-size: 1rem;
    margin-bottom: 20px;
  }
  .btn {
    padding: 12px 24px;
    font-size: 0.9rem;
  }

  /* 3. Портфолио: 1 колонка на телефонах */
  .portfolio-grid {
    grid-template-columns: 1fr; /* Одна фотография на всю ширину */
    gap: 10px;
  }

  .photo-item img {
    height: 250px; /* Фиксированная высота для аккуратности */
  }

  /* 4. Фильтры: кнопки чуть меньше и плотнее */
  .filter-buttons {
    gap: 8px;
    margin-bottom: 20px;
  }
  .filter-buttons button {
    font-size: 0.85rem;
    padding: 6px 12px;
  }

  /* 5. Контакты: ссылки в столбик или крупнее для пальцев */
  .social-links {
    flex-direction: column;
    gap: 15px;
  }
  .social-link {
    font-size: 1.1rem;
    padding: 10px; /* Увеличиваем зону нажатия */
  }

  /* 6. Видео-фон на мобильных (опционально) */
  /* Если видео слишком затемняет контент, можно чуть осветлить */
  .video-overlay {
    background: rgba(0, 0, 0, 0.4);
  }
}

/* Для совсем маленьких экранов (iPhone SE и т.п.) */
@media (max-width: 400px) {
  .hero h1 {
    font-size: 1.5rem;
  }
}
/* === СТИЛИ ДЛЯ LIGHTBOX === */
.lightbox {
  display: none; /* Скрыто по умолчанию */
  position: fixed;
  z-index: 9999; /* Поверх всего */
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.9); /* Темный фон */
  justify-content: center;
  align-items: center;
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  display: flex;
  justify-content: center;
  align-items: center;
}

#lightbox-img {
  max-width: 100%;
  max-height: 90vh;
  border-radius: 4px;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

/* Кнопка закрытия */
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  z-index: 10000;
}

/* Стрелки навигации */
.lightbox-prev,
.lightbox-next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: auto;
  padding: 16px;
  color: white;
  font-weight: bold;
  font-size: 30px;
  transition: 0.3s;
  user-select: none;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 4px;
}

.lightbox-next {
  right: 10px;
}
.lightbox-prev {
  left: 10px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Адаптив для мобилок */
@media (max-width: 768px) {
  .lightbox-prev,
  .lightbox-next {
    padding: 10px;
    font-size: 20px;
  }
  .lightbox-close {
    top: 10px;
    right: 15px;
    font-size: 30px;
  }
}

/* === НАДЁЖНОЕ ПОРТФОЛИО БЕЗ ABSOLUTE === */

/* Размытые фото */
.photo-item.faded {
  opacity: 0.25;
  filter: blur(4px);
  transition:
    opacity 0.6s ease,
    filter 0.6s ease;
}

/* Скрытые фото */
.photo-item.hidden-photos {
  display: none;
}

/* Оверлей "Показать еще" — обычный элемент сетки на всю ширину */
.overlay-container {
  grid-column: 1 / -1; /* Занимает всю ширину сетки */
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 60px 0;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    rgba(15, 20, 30, 0.95) 40%
  );
  min-height: 250px;
}

.overlay-container .toggle-btn {
  background: transparent;
  border: 2px solid #c9a961;
  color: #c9a961;
  padding: 14px 45px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.overlay-container .toggle-btn:hover {
  background: #c9a961;
  color: #0f1419;
}

/* Кнопка "Скрыть" — обычный элемент сетки на всю ширину */
.hide-btn-container {
  grid-column: 1 / -1;
  text-align: center;
  padding: 30px 0;
}

.hide-btn-container .hide-btn {
  background: transparent;
  border: 2px solid #c9a961;
  color: #c9a961;
  padding: 14px 45px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.hide-btn-container .hide-btn:hover {
  background: #c9a961;
  color: #0f1419;
}
/* === КНОПКА ТЕЛЕФОНА ПОД СОЦСЕТЯМИ === */
.phone-button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 25px;
  padding: 12px 28px;
  background: transparent;
  border: 2px solid #c9a961;
  border-radius: 50px;
  color: #fff;
  text-decoration: none;
  font-size: 1rem;
  font-weight: 600;
  transition: all 0.3s ease;
  animation: phone-pulse 2s infinite;
}

.phone-button:hover {
  background: #c9a961;
  color: #0f1419;
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(201, 169, 97, 0.4);
  animation: none;
}

.phone-icon {
  width: 18px;
  height: 18px;
  stroke: currentColor;
}

@keyframes phone-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(201, 169, 97, 0.6);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(201, 169, 97, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(201, 169, 97, 0);
  }
}

/* Адаптив для мобильных */
@media (max-width: 768px) {
  .phone-button {
    padding: 14px 32px;
    font-size: 1.05rem;
  }

  .phone-icon {
    width: 20px;
    height: 20px;
  }
}
