  /* Стили для страницы галереи */
  .page-header {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    padding: 60px 40px;
    text-align: center;
  }
  
  .header-container {
    max-width: 1200px;
    margin: 0 auto;
  }
  
  .page-subtitle {
    font-size: 18px;
    color: #0090ff;
    font-weight: 600;
    margin-bottom: 15px;
    display: block;
  }
  
  .page-title {
    font-size: 42px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
    color: #1a1a1a;
  }
  
  .page-description {
    font-size: 18px;
    line-height: 1.6;
    color: #4d4d4d;
    max-width: 800px;
    margin: 0 auto;
  }
  
  /* Фильтры */
  .gallery-filters {
    background: #1b1d22;
    padding: 30px 0;
  }
  
  .gallery-filters .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
  }
  
  .filter-buttons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
  }
  
  .filter-btn {
    background: transparent;
    border: 2px solid #0090ff;
    color: #0090ff;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
    word-wrap: break-word;
  }
  
  .filter-btn:hover, .filter-btn.active {
    background: #0090ff;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 144, 255, 0.3);
  }
  
  /* Галерея */
  .gallery-section {
    padding: 60px 0;
    background: #1b1d22;
  }
  
  /* Детали карточки */
  .card-details {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
    font-size: 14px;
  }
  
  .card-details span {
    display: flex;
    align-items: center;
    gap: 5px;
  }
  
  .card-details i {
    color: #0090ff;
  }
  
  /* Секция призыва к действию */
  .cta-section {
    background: linear-gradient(135deg, #252830 0%, #252830 100%);
    padding: 80px 0;
    text-align: center;
    color: white;
  }
  
  .cta-content h2 {
    font-size: 36px;
    margin-bottom: 15px;
  }
  
  .cta-content p {
    font-size: 18px;
    margin-bottom: 30px;
    opacity: 0.9;
  }
  
  /* Адаптивность */
  @media (max-width: 768px) {
    .page-header {
      padding: 40px 20px;
    }
    
    .page-title {
      font-size: 32px;
    }
    
    .filter-buttons {
      gap: 10px;
    }
    
    .filter-btn {
      padding: 8px 16px;
      font-size: 14px;
    }
    
    .card-details {
      flex-direction: column;
      gap: 8px;
    }
    
    .cta-section {
      padding: 60px 20px;
    }
    
    .cta-content h2 {
      font-size: 28px;
    }
  }

.work-detail {
  padding: 40px 0;
}

.work-header {
  text-align: center;
  margin-bottom: 40px;
}

.work-header h1 {
  font-size: 2.5rem;
  margin-bottom: 10px;
}

.work-category {
  color: #0090ff;
  font-size: 1.1rem;
  margin-bottom: 5px;
}

.work-date {
  color: #666;
  font-size: 0.9rem;
}

.work-main-image {
  margin-bottom: 40px;
}

.work-main-image img {
  width: 100%;
  height: 500px;
  object-fit: cover;
  border-radius: 12px;
}

.work-description {
  margin-bottom: 40px;
}

.work-description h2 {
  margin-bottom: 20px;
  color: #1a1a1a;
}

.description-content {
  line-height: 1.8;
  font-size: 1.1rem;
}

.work-video {
  margin-bottom: 40px;
}

.work-video h2 {
  margin-bottom: 20px;
}

.video-container {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 12px;
}

.work-gallery {
  margin-bottom: 40px;
}

.work-gallery h2 {
  margin-bottom: 20px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}

.gallery-item img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-radius: 8px;
  transition: transform 0.3s ease;
}

.gallery-item img:hover {
  transform: scale(1.05);
}

.work-specs {
  background: #f8f9fa;
  padding: 30px;
  border-radius: 12px;
  margin-bottom: 40px;
}

.work-specs h2 {
  margin-bottom: 20px;
}

.specs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 15px;
}

.spec-item {
  display: flex;
  justify-content: between;
}

.spec-label {
  font-weight: bold;
  margin-right: 10px;
  color: #333;
}

.spec-value {
  color: #666;
}

.related-works {
  background: #1b1d22;
  color: white;
  padding: 60px 0;
}

.related-works h2 {
  text-align: center;
  margin-bottom: 40px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.related-card {
  background: #252830;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.related-card:hover {
  transform: translateY(-5px);
}

.related-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.related-info {
  padding: 20px;
}

.related-info h3 {
  margin-bottom: 10px;
  font-size: 1.1rem;
}

.related-info p {
  color: #0090ff;
  font-size: 0.9rem;
}

.work-cta {
  background: linear-gradient(135deg, #0090ff 0%, #0066cc 100%);
  color: white;
  padding: 80px 0;
  text-align: center;
}

.work-cta h2 {
  margin-bottom: 20px;
  font-size: 2rem;
}

.work-cta p {
  margin-bottom: 30px;
  font-size: 1.1rem;
  opacity: 0.9;
}

.cta-button {
  background: white;
  color: #0090ff;
  border: none;
  padding: 15px 40px;
  border-radius: 8px;
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
}

.cta-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Адаптивность */
@media (max-width: 768px) {
  .work-header h1 {
    font-size: 2rem;
  }
  
  .work-main-image img {
    height: 300px;
  }
  
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  
  .specs-grid {
    grid-template-columns: 1fr;
  }
}
/* Стили для пагинации */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 50px;
    gap: 10px;
}

.pagination-item {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    border: 2px solid #0090ff;
    border-radius: 8px;
    color: #0090ff;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.pagination-item:hover,
.pagination-item.active {
    background: #0090ff;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 144, 255, 0.3);
}

.pagination-item.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    border-color: #666;
    color: #666;
}

.pagination-item.disabled:hover {
    background: transparent;
    transform: none;
    box-shadow: none;
}

/* Центрирование контента галереи */
.gallery-section .container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.works-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr)); 
    gap: 30px;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    justify-items: center; 
}

.work-card {
    height: 350px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
    width: 100%; /* Добавили ширину 100% */
    max-width: 400px; /* Добавили максимальную ширину */
}

/* Описание скрыто по умолчанию и появляется при наведении */
.card-description {
    font-size: 0.9rem;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
    margin-bottom: 35px;
    line-height: 1.5;
    text-align: center;
    display: -webkit-box;
    -webkit-line-clamp: 3; /* Ограничение до 3 строк */
    -webkit-box-orient: vertical;
}

.work-card:hover .card-description {
    opacity: 1;
    max-height: 80px; /* Максимальная высота для описания */
}


/* Адаптивность для сетки 4×3 */
@media (max-width: 1200px) {
    .works-grid {
        grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
        gap: 25px;
        max-width: 1000px;
    }
}

@media (max-width: 900px) {
    .works-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: 20px;
        max-width: 700px;
    }
}

@media (max-width: 600px) {
    .works-grid {
        grid-template-columns: 1fr;
        gap: 15px;
        max-width: 400px;
    }
    
    .work-card {
        height: 300px;
        max-width: 100%; /* На мобильных занимает всю ширину */
    }
}

/* Сообщение об отсутствии работ */
.no-works {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: #ccc;
    font-size: 18px;
}

.no-works p {
    margin-bottom: 20px;
}

/* Счетчик работ */
.works-count {
    text-align: center;
    color: #ccc;
    margin-bottom: 30px;
    font-size: 16px;
}
/* Добавьте эти стили в конец файла style_gallery_works.css */

/* Мобильная версия - отступы */
@media (max-width: 768px) {
  .gallery-section {
    padding: 40px 20px; /* Добавляем отступы по бокам */
  }
  
  .works-grid {
    padding: 0 15px; /* Отступы для сетки работ */
  }
  
  .pagination {
    margin-top: 30px; /* Уменьшаем отступ пагинации */
    padding: 0 15px; /* Добавляем отступы для пагинации */
  }
}

@media (max-width: 480px) {
  .gallery-section {
    padding: 30px 15px; /* Увеличиваем отступы для очень маленьких экранов */
  }
  
  .works-grid {
    gap: 20px; /* Увеличиваем промежутки между карточками */
    padding: 0 10px;
  }
  
  .work-card {
    margin-bottom: 10px; /* Добавляем отступ снизу каждой карточки */
  }
  
  .pagination {
    gap: 8px; /* Уменьшаем промежутки между элементами пагинации */
  }
  
  .pagination-item {
    min-width: 35px;
    height: 35px;
    font-size: 14px;
  }
}

/* Для контейнера с фильтрами также добавим отступы */
@media (max-width: 768px) {
  .gallery-filters .container {
    padding: 0 20px;
  }
  
  .filter-buttons {
    gap: 10px;
    justify-content: center;
  }
  
  .filter-btn {
    margin: 5px;
    flex: 1;
    min-width: 120px;
    text-align: center;
  }
}

/* Улучшаем внешний вид для мобильных устройств */
@media (max-width: 600px) {
  .work-card {
    border-radius: 10px;
    height: 280px;
  }
  
  .card-overlay {
    padding: 20px 15px 15px;
  }
  
  .card-title {
    font-size: 1.2rem;
    margin-bottom: 8px;
  }
  
  .card-button {
    padding: 8px 16px;
    font-size: 13px;
  }
}
@media (max-width: 768px) {
    .works-grid {
        padding: 0 15px;
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
}

@media (max-width: 480px) {
    .works-grid {
        gap: 20px;
        padding: 0 10px;
        grid-template-columns: 1fr;
    }
    
    .work-card {
        margin-bottom: 10px;
        max-width: 100%;
    }
}